/* enklasidan.se – EnklaSidan's brand (docs/enklasidan-brand): navy for
   structure and text, blue for what you press. Buttons and links use a
   darker shade of the brand blue so white text and links keep a contrast of
   at least 4.5:1; the brand blue itself is for accents. */
@font-face {
  font-family: "Inter";
  src: url("/static/fonts/InterVariable.woff2") format("woff2");
  font-weight: 100 900;
  font-style: normal;
  font-display: swap;
}

:root {
  --navy: #172B46;      /* brand: marinblå */
  --navy-deep: #0f1f35;  /* dark areas: contact block, footer */
  --blue: #397BE5;       /* brand: klarblå, accents */
  --action: #1F5FCC;     /* buttons and links (brand blue, darker for contrast) */
  --action-hover: #0750B8; /* brand: djupblå */
  --bright: #168BFF;     /* brand: focus rings */
  --light: #79B9F5;      /* brand: ljusblå */
  --text: #26364A;
  --muted: #68788C;
  --line: #DCE5F0;
  --tint: #EAF3FF;       /* brand: mycket ljus blå */
  --bg: #ffffff;
  --radius: 14px;
  color-scheme: light;
}

* { box-sizing: border-box; }

html { scroll-behavior: smooth; }
@media (prefers-reduced-motion: reduce) { html { scroll-behavior: auto; } }

body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font: 17px/1.6 "Inter", -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
  -webkit-font-smoothing: antialiased;
}

img { display: block; max-width: 100%; height: auto; }
a { color: var(--action); }
a:hover { color: var(--action-hover); }

.wrap { width: min(1080px, 100% - 32px); margin-inline: auto; }

h1, h2, h3 { color: var(--navy); line-height: 1.2; margin: 0 0 .5em; }
h1 { font-size: clamp(2rem, 5vw, 3.1rem); letter-spacing: -.02em; max-width: 20ch; }
h2 { font-size: clamp(1.6rem, 3.5vw, 2.1rem); letter-spacing: -.01em; }
h3 { font-size: 1.2rem; }
p { margin: 0 0 1em; }

/* Header */
.site-header {
  position: sticky; top: 0; z-index: 10;
  background: rgba(255, 255, 255, .92);
  backdrop-filter: saturate(1.4) blur(8px);
  border-bottom: 1px solid var(--line);
}
.header-row { display: flex; align-items: center; justify-content: space-between; gap: 16px; min-height: 72px; }

/* Buttons */
.button {
  display: inline-block;
  padding: .8em 1.4em;
  border-radius: 999px;
  background: var(--action);
  color: #fff;
  font-weight: 600;
  text-decoration: none;
  border: 0;
  transition: background-color .15s ease;
}
.button:hover { background: var(--action-hover); color: #fff; }
.button:focus-visible { outline: 3px solid var(--bright); outline-offset: 3px; }
.button-small { padding: .55em 1.1em; font-size: .9rem; }
.button-ghost { background: transparent; color: var(--navy); box-shadow: inset 0 0 0 2px var(--line); }
.button-ghost:hover { background: transparent; color: var(--navy); box-shadow: inset 0 0 0 2px var(--action); }
.button-light { background: #fff; color: var(--navy); overflow-wrap: anywhere; }
.button-light:hover { background: var(--tint); color: var(--navy); }

/* Hero */
.hero {
  padding: clamp(56px, 10vw, 120px) 0 clamp(48px, 8vw, 96px);
  background: var(--tint);
}
.eyebrow { color: var(--action); font-weight: 600; font-size: .85rem; letter-spacing: .08em; text-transform: uppercase; }
.lead { font-size: 1.15rem; color: var(--muted); max-width: 60ch; }
.actions { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 28px; }

/* Sections */
.section { padding: clamp(56px, 8vw, 96px) 0; }
.section-tinted { background: var(--tint); }
.section[id] { scroll-margin-top: 40px; } /* keep headings clear of the sticky header */

.cards { display: grid; grid-template-columns: repeat(auto-fit, minmax(260px, 1fr)); gap: 20px; margin-top: 28px; }
.card {
  background: #fff;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 28px;
  transition: border-color .15s ease, box-shadow .15s ease;
}
.card:hover { border-color: rgba(31, 95, 204, .35); box-shadow: 0 12px 30px rgba(23, 43, 70, .08); }
.card p { color: var(--muted); margin: 0; }
.icon {
  width: 48px; height: 48px; border-radius: 12px; margin-bottom: 18px;
  display: grid; place-items: center;
  background: var(--tint);
}
.icon svg { width: 26px; height: 26px; fill: none; stroke: var(--blue); stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round; }

.about { display: grid; grid-template-columns: 1.3fr 1fr; gap: 48px; align-items: start; }
.about p { color: var(--muted); }
.points { list-style: none; margin: 0; padding: 0; display: grid; gap: 14px; }
.points li {
  background: #fff; border-radius: var(--radius); padding: 18px 20px;
  border-left: 4px solid var(--blue); color: var(--muted);
}
.points strong { display: block; color: var(--navy); }
@media (max-width: 760px) { .about { grid-template-columns: 1fr; gap: 24px; } }

/* Contact */
.contact {
  text-align: center;
  color: #d6e4f5;
  background:
    var(--navy-deep);
}
.contact h2 { color: #fff; }
.contact p { max-width: 50ch; margin: 0 auto 28px; }

/* Footer */
.site-footer { background: var(--navy-deep); color: #8fa3bd; font-size: .9rem; border-top: 1px solid rgba(255, 255, 255, .08); }
.footer-row { display: flex; flex-wrap: wrap; justify-content: space-between; gap: 8px 24px; padding: 22px 0; }
.site-footer a { color: #8fa3bd; text-decoration: none; }
.site-footer a:hover { color: #fff; }

/* 404 */
.notfound { min-height: 55vh; }

/* Text pages (privacy policy) */
.prose .wrap { max-width: 760px; }
.prose h1 { margin-bottom: .2em; }
.prose h2 { font-size: 1.4rem; margin-top: 1.8em; }
.prose h3 { font-size: 1.1rem; margin-top: 1.4em; }
.prose p, .prose li { color: var(--text); }
.prose ul, .prose ol { padding-left: 1.3em; margin: 0 0 1em; }
.prose li { margin-bottom: .4em; }
.prose h2[id] { scroll-margin-top: 90px; }
.muted { color: var(--muted); }
.footer-links { display: flex; flex-wrap: wrap; gap: 8px 20px; }


/* EnklaSidan: example screenshots, steps and prices */
.shots { display: grid; grid-template-columns: repeat(2, 1fr); gap: 28px; margin-top: 28px; }
.swipe-hint { display: none; }
/* On phones the examples become a swipeable carousel; the next card peeks in. */
@media (max-width: 640px) {
  .shots {
    display: flex; gap: 14px; overflow-x: auto; scroll-snap-type: x mandatory;
    margin-inline: -16px; padding: 0 16px 8px; scroll-padding-inline: 16px;
    scrollbar-width: none; -webkit-overflow-scrolling: touch;
  }
  .shots::-webkit-scrollbar { display: none; }
  .shot { flex: 0 0 84%; scroll-snap-align: start; }
  .swipe-hint { display: block; margin: 0; font-size: .9rem; font-weight: 600; color: var(--action); }
}
.shot { margin: 0; }
.shot a { display: block; text-decoration: none; }
.shot-frame, .shot img { border: 1px solid var(--line); }
.shot-frame {
  display: flex; gap: 6px; padding: 10px 12px;
  background: var(--tint); border-bottom: 0; border-radius: var(--radius) var(--radius) 0 0;
}
.shot-frame span { width: 10px; height: 10px; border-radius: 50%; background: #cbd5e1; }
.shot img { border-radius: 0 0 var(--radius) var(--radius); transition: box-shadow .15s ease; }
.shot a:hover img { box-shadow: 0 12px 30px rgba(23, 43, 70, .12); }
.shot figcaption { margin-top: 10px; font-weight: 600; color: var(--navy); display: flex; align-items: center; gap: 10px; }
.tag {
  font-size: .75rem; font-weight: 600; letter-spacing: .04em; text-transform: uppercase;
  color: var(--action); background: var(--tint); padding: .2em .7em; border-radius: 999px;
}

.steps { list-style: none; margin: 28px 0 0; padding: 0; display: grid; grid-template-columns: repeat(auto-fit, minmax(240px, 1fr)); gap: 20px; counter-reset: step; }
.steps li { background: #fff; border-radius: var(--radius); padding: 24px; color: var(--muted); counter-increment: step; }
.steps li::before {
  content: counter(step); display: grid; place-items: center; width: 34px; height: 34px; margin-bottom: 14px;
  border-radius: 50%; background: var(--action); color: #fff; font-weight: 700;
}
.steps strong { display: block; color: var(--navy); font-size: 1.1rem; margin-bottom: 4px; }

.prices { display: grid; grid-template-columns: repeat(auto-fit, minmax(280px, 1fr)); gap: 20px; margin-top: 28px; max-width: 760px; }
.price { border: 1px solid var(--line); border-radius: var(--radius); padding: 28px; }
.price:first-child { border: 2px solid var(--blue); }
.amount { font-size: 2.1rem; font-weight: 700; color: var(--navy); line-height: 1.1; margin-bottom: 18px; }
.amount span { font-size: 1rem; font-weight: 500; color: var(--muted); }
.amount small { font-size: 1rem; font-weight: 500; color: var(--muted); }
.price ul { list-style: none; margin: 0; padding: 0; display: grid; gap: 8px; color: var(--muted); }
.price li { padding-left: 26px; position: relative; }
.price li::before { content: "✓"; position: absolute; left: 0; color: var(--blue); font-weight: 700; }
.price-note { margin-top: 20px; }

/* EnklaSidan: banner back to a stored profile */
.profile-banner { background: var(--navy); color: #fff; }
.profile-banner-row { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 10px 20px; padding: 12px 0; font-weight: 600; }
.profile-banner .button { box-shadow: none; }
.contact .contact-alt { margin: 22px auto 0; font-size: .95rem; line-height: 1.5; }
.contact-alt a { color: #fff; }

/* EnklaSidan: inquiry form */
.form-wrap { max-width: 760px; }
.inquiry { margin-top: 32px; display: grid; gap: 28px; }
.inquiry fieldset { border: 1px solid var(--line); border-radius: var(--radius); padding: 22px 24px 8px; margin: 0; }
.inquiry legend { font-weight: 700; color: var(--navy); padding: 0 8px; margin-left: -8px; font-size: 1.1rem; }
.field { display: grid; gap: 6px; margin-bottom: 18px; font-weight: 600; color: var(--navy); font-size: .95rem; }
.field-row { display: grid; grid-template-columns: 1fr 1fr; gap: 0 16px; }
@media (max-width: 600px) { .field-row { grid-template-columns: 1fr; } }
.field input, .field textarea {
  font: inherit; font-weight: 400; color: var(--text); width: 100%;
  padding: 11px 13px; border: 1px solid #cbd5e1; border-radius: 10px; background: #fff;
}
.field input[type=file] { padding: 10px; background: var(--tint); }
.field textarea { resize: vertical; }
.field input:focus, .field textarea:focus { outline: 3px solid rgba(22, 139, 255, .3); border-color: var(--blue); }
.req { color: var(--blue); }
.hint { font-size: .88rem; font-weight: 400; color: var(--muted); margin: 0 0 14px; }
.field .hint { margin: 0; }
.choices { display: flex; flex-wrap: wrap; gap: 10px; margin-bottom: 18px; }

.choice span {
  display: inline-block; padding: .55em 1.1em; border-radius: 999px; cursor: pointer;
  border: 2px solid var(--line); color: var(--navy); font-weight: 600; font-size: .95rem;
}
.choice input:checked + span { background: var(--action); border-color: var(--action); color: #fff; }
.choice input:focus-visible + span { outline: 3px solid var(--bright); outline-offset: 2px; }
.form-error { background: #fdecec; color: #8a1c1c; border-radius: 10px; padding: 14px 18px; font-weight: 600; margin: 0; }
.form-actions { display: grid; gap: 12px; justify-items: start; }
.form-actions .button { border: 0; font: inherit; font-weight: 600; cursor: pointer; font-size: 1.05rem; padding: .85em 2.2em; }
.hp { position: absolute; left: -10000px; width: 1px; height: 1px; overflow: hidden; }

/* EnklaSidan: a customer's profile */
.received { background: #e9f8ef; border-radius: var(--radius); padding: 22px 26px; margin-bottom: 32px; }
.received h2 { font-size: 1.35rem; margin-bottom: .3em; }
.received p { margin: 0; color: var(--text); }
.link-note { background: var(--tint); border-left: 4px solid var(--blue); border-radius: 8px; padding: 14px 18px; margin: 18px 0 8px; color: var(--muted); font-size: .95rem; }
.link-note strong { color: var(--navy); display: block; }
.profile-block { margin-top: 34px; }
.profile-block h2 { font-size: 1.3rem; }
.answers { margin: 0; display: grid; grid-template-columns: minmax(180px, 1fr) 2fr; gap: 10px 20px; }
.answers dt { color: var(--muted); font-size: .95rem; }
.answers dd { margin: 0; }
@media (max-width: 600px) { .answers { grid-template-columns: 1fr; gap: 2px; } .answers dd { margin-bottom: 12px; } }
.pre { white-space: pre-line; }
.comment { border-left: 4px solid var(--blue); padding: 4px 0 4px 16px; margin-bottom: 16px; }
.comment p { margin: 0; }
.files { list-style: none; padding: 0; margin: 0; display: grid; grid-template-columns: repeat(auto-fill, minmax(150px, 1fr)); gap: 16px; }
.files a { display: grid; gap: 6px; text-decoration: none; color: var(--navy); }
.files img, .file-icon { width: 100%; aspect-ratio: 4 / 3; object-fit: cover; border-radius: 10px; border: 1px solid var(--line); background: var(--tint); }
.file-icon { display: grid; place-items: center; font-size: 2rem; }
.file-name { font-size: .9rem; font-weight: 600; overflow-wrap: anywhere; }
.files .muted { font-size: .8rem; }
.profile-change { margin-top: 34px; }

/* EnklaSidan: booking system follow-up (shown for Boka tid and Beställa) */
.goal-follow, .for-boka, .for-bestalla { display: none; }
.inquiry:has(input[name=goal][value=boka]:checked) .goal-follow,
.inquiry:has(input[name=goal][value=bestalla]:checked) .goal-follow { display: block; }
.inquiry:has(input[name=goal][value=boka]:checked) .for-boka,
.inquiry:has(input[name=goal][value=bestalla]:checked) .for-bestalla { display: inline; }
.goal-follow { border-top: 1px dashed var(--line); padding-top: 16px; }
.follow-q { font-weight: 600; color: var(--navy); margin-bottom: 10px; }

/* EnklaSidan: color palettes */
.palettes { display: grid; grid-template-columns: repeat(auto-fill, minmax(150px, 1fr)); gap: 10px; margin-top: 4px; }

.palette-card {
  display: grid; gap: 8px; height: 100%; padding: 10px; border-radius: 12px; cursor: pointer;
  border: 2px solid var(--line); background: #fff; font-weight: 600;
}
.palette input:checked + .palette-card { border-color: var(--blue); background: var(--tint); box-shadow: inset 0 0 0 1px var(--blue); }
.palette input:focus-visible + .palette-card { outline: 3px solid var(--bright); outline-offset: 2px; }
.palette-none { align-content: center; text-align: center; }
.palette-none .hint { font-size: .8rem; }
.palette-name { font-size: .9rem; color: var(--navy); }
.swatches { display: flex; height: 34px; border-radius: 8px; overflow: hidden; border: 1px solid var(--line); }
.swatches i { flex: 1; }
.swatches-inline { display: inline-flex; width: 96px; height: 20px; vertical-align: middle; margin-right: 6px; }

/* Radio buttons hidden behind their pill or card, anchored so they never widen the page. */
.choice, .palette { position: relative; }
.choice input, .palette input { position: absolute; top: 0; left: 0; width: 1px; height: 1px; margin: 0; opacity: 0; pointer-events: none; }
.liked { list-style: none; margin: 0; padding: 0; display: grid; gap: 4px; }
.liked a { overflow-wrap: anywhere; }
.liked-inputs { display: grid; gap: 8px; }
.add-row {
  justify-self: start; margin-top: 2px; padding: .5em 1em; border-radius: 999px; cursor: pointer;
  font: inherit; font-size: .9rem; font-weight: 600; color: var(--action); background: transparent;
  border: 2px dashed var(--light);
}
.add-row:hover { border-color: var(--action); }
.add-row[hidden] { display: none; }

/* EnklaSidan: changing a profile */
.received.neutral { background: var(--tint); padding: 14px 20px; }
.locked { background: #fff6e0; border-left: 4px solid #e0a100; border-radius: 8px; padding: 14px 18px; margin: 18px 0 8px; color: var(--text); }
.locked strong { display: block; color: var(--navy); }
.edit-files { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(auto-fill, minmax(140px, 1fr)); gap: 12px; }
.edit-files li { display: grid; gap: 6px; font-weight: 400; }
.edit-files img, .edit-files .file-icon { width: 100%; aspect-ratio: 4 / 3; object-fit: cover; border-radius: 10px; border: 1px solid var(--line); background: var(--tint); }
.edit-files li:has(input:checked) img, .edit-files li:has(input:checked) .file-icon, .edit-files li:has(input:checked) .file-name { opacity: .35; text-decoration: line-through; }
.remove { font-size: .9rem; color: var(--muted); display: flex; gap: 6px; align-items: center; cursor: pointer; }
.form-buttons { display: flex; flex-wrap: wrap; gap: 12px; }
.field .remove input { width: auto; padding: 0; margin: 0; }
.button:disabled { opacity: .45; cursor: not-allowed; transform: none; box-shadow: none; }

/* EnklaSidan: a field with a problem */
.field input.invalid, .field textarea.invalid { border-color: #c62828; background: #fff7f7; }
.field input.invalid:focus { outline-color: rgba(198, 40, 40, .3); border-color: #c62828; }
.field-error { color: #b71c1c; font-size: .88rem; font-weight: 600; }
.field input { scroll-margin-top: 110px; }
.field { align-content: start; }

/* Logo: docs/enklasidan-brand/logo/enklasidan-logo.png, scaled to 96 px
   high (static/logo.png) and shown at 38 px, so it's sharp on retina. */
.brand { display: inline-flex; align-items: center; text-decoration: none; }
.brand img { width: auto; height: 38px; }
.site-footer a { text-decoration: underline; text-underline-offset: 2px; }

/* The privacy dialog next to the form */
.privacy {
  width: min(640px, 100% - 24px); max-height: min(85vh, 760px); padding: 0;
  border: 0; border-radius: var(--radius); color: var(--text);
  box-shadow: 0 24px 70px rgba(23, 43, 70, .3);
}
.privacy::backdrop { background: rgba(15, 31, 53, .55); }
.privacy[open] { display: flex; flex-direction: column; }
.privacy-head { display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 18px 22px; border-bottom: 1px solid var(--line); }
.privacy-head h2 { font-size: 1.25rem; margin: 0; }
.privacy-head form { margin: 0; }
.privacy-close { font: inherit; font-size: 1.1rem; width: 40px; height: 40px; border-radius: 50%; border: 0; background: var(--tint); color: var(--navy); cursor: pointer; }
.privacy-close:hover { background: var(--line); }
.privacy-body { padding: 18px 22px 4px; overflow-y: auto; font-size: .95rem; }
.privacy-foot { padding: 14px 22px 20px; border-top: 1px solid var(--line); margin: 0; display: flex; justify-content: flex-end; }

/* Chosen files, before sending */
.chosen-files { list-style: none; margin: 0; padding: 0; display: grid; gap: 8px; }
.chosen-files li {
  display: grid; grid-template-columns: 48px 1fr auto auto; align-items: center; gap: 12px;
  padding: 8px 10px; border: 1px solid var(--line); border-radius: 10px; font-weight: 400; background: #fff;
}
.chosen-files img, .chosen-files .file-icon { width: 48px; height: 48px; object-fit: cover; border-radius: 6px; background: var(--tint); display: grid; place-items: center; font-size: 1.3rem; aspect-ratio: auto; border: 0; }
.chosen-files .file-name { font-size: .92rem; color: var(--navy); overflow-wrap: anywhere; font-weight: 600; }
.chosen-files .file-size { font-size: .85rem; color: var(--muted); white-space: nowrap; }
.file-remove { font: inherit; font-size: .85rem; font-weight: 600; color: var(--action); background: none; border: 0; padding: 6px 4px; cursor: pointer; }
.file-remove:hover { color: var(--action-hover); text-decoration: underline; }
@media (max-width: 480px) {
  .chosen-files li { grid-template-columns: 44px 1fr auto; }
  .chosen-files .file-size { grid-column: 2; grid-row: 2; }
  .chosen-files .file-remove { grid-column: 3; grid-row: 1 / span 2; }
}
