/* =================================================================
   kundeservice-outlet.css

   Sykkeloutlet kundeservice page. Storefront-store aesthetic:
     - Assistant font (light + clean)
     - Blue link colour, green "deal" accent
     - White background, light borders, paper for cards
     - Sticky sidebar TOC layout (240px left rail) instead of horizontal
       category tabs
     - Eyebrow + section-h2 + section-sub typography pattern for
       major sections (order tracking, help band)

   Class prefix `so-*` so it can never collide with Cube's `cs-*` or
   Unaas's `ks-*` prefixes, or with the Shopify storefront's own
   utility classes.
   ================================================================= */

/* ----- Tokens -------------------------------------------------- */
.so-shell {
  --so-bg:          #ffffff;
  --so-ink:         #222222;
  --so-ink-soft:    #3d3d3d;
  --so-muted:       #6b7280;
  --so-line:        #e5e5e5;
  --so-line-strong: #d0d0d0;
  --so-paper:       #fafafa;
  --so-paper-2:     #f3f4f6;

  --so-blue:        #1d6bbd;
  --so-blue-deep:   #155591;
  --so-blue-soft:   #e9f1f9;

  --so-green:       #2bb19a;
  --so-green-deep:  #1f9682;

  /* The branding override (--so-accent) wins when the template inlines
     a primaryColor on .so-shell. Fall back to Sykkeloutlet's own blue. */
  --so-link: var(--so-accent, var(--so-blue));
  --so-link-deep: var(--so-accent-deep, var(--so-blue-deep));

  font-family: 'Assistant', -apple-system, BlinkMacSystemFont, 'Helvetica Neue', Arial, sans-serif;
  color: var(--so-ink);
  background: var(--so-bg);
  font-size: 15px;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}

/* Reset the shell's children box-sizing so inherited storefront styles
   don't fight the layout (Shopify themes set various conflicting box
   models on the proxy region). */
.so-shell * { box-sizing: border-box; }

.so-shell a { color: var(--so-link); }
.so-shell a:hover { color: var(--so-link-deep); }

.so-wrap {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 22px;
}

/* Eyebrow / heading typography shared by Order tracking, FAQ heading
   and the Help band. Eyebrow has a short blue line before it. */
.so-eyebrow {
  font-size: 11px;
  color: var(--so-link);
  text-transform: uppercase;
  letter-spacing: .1em;
  font-weight: 700;
  margin: 0 0 10px;
  display: inline-flex;
  align-items: center;
  gap: 8px;
}
.so-eyebrow::before {
  content: "";
  width: 18px;
  height: 2px;
  background: var(--so-link);
}
.so-section-h2 {
  font-size: 22px;
  font-weight: 600;
  letter-spacing: -.005em;
  margin: 0;
  line-height: 1.2;
  color: var(--so-ink);
}
.so-section-sub {
  color: var(--so-ink-soft);
  margin: 8px 0 0;
  font-size: 14.5px;
  line-height: 1.55;
  max-width: 48ch;
}

/* ----- Page top: split hero (left = heading + search, right = lookup) -- */
.so-page-top { padding: 42px 0 12px; }
.so-page-grid {
  display: grid;
  grid-template-columns: 1.2fr 1fr;
  gap: 56px;
  align-items: start;
}
.so-page-left { min-width: 0; }
.so-page-right { min-width: 0; }
.so-crumb {
  font-size: 13px;
  color: var(--so-muted);
  margin-bottom: 18px;
}
.so-crumb a {
  color: var(--so-muted);
  text-decoration: none;
}
.so-crumb a:hover { text-decoration: underline; color: var(--so-ink); }
.so-crumb .so-sep { margin: 0 6px; opacity: .6; }
.so-page-title {
  font-size: 36px;
  font-weight: 600;
  letter-spacing: -.005em;
  margin: 0 0 10px;
  color: var(--so-ink);
  line-height: 1.1;
}
.so-page-sub {
  font-size: 15px;
  color: var(--so-muted);
  margin: 0;
  max-width: 60ch;
}

.so-search-wrap { margin: 30px 0 0; max-width: 640px; }
.so-search { position: relative; }
.so-search input {
  width: 100%;
  padding: 14px 18px 14px 46px;
  border: 1px solid var(--so-line-strong);
  border-radius: 4px;
  font-family: inherit;
  font-size: 14.5px;
  background: #fff;
  color: var(--so-ink);
  outline: none;
  transition: border-color .15s, box-shadow .15s;
}
.so-search input:focus {
  border-color: var(--so-link);
  box-shadow: 0 0 0 3px rgba(29, 107, 189, .12);
}
.so-search .so-search-ic {
  position: absolute;
  left: 18px;
  top: 50%;
  transform: translateY(-50%);
  color: var(--so-muted);
  display: inline-flex;
  align-items: center;
}

/* Typeahead suggestions panel — kept on the same DOM contract as Cube
   (kundeservice-outlet.js fills it on input). Visual: dropdown card
   under the input, floating with a soft shadow. */
.so-suggestions {
  position: absolute;
  left: 0;
  right: 0;
  top: calc(100% + 6px);
  background: #fff;
  border: 1px solid var(--so-line);
  border-radius: 4px;
  box-shadow: 0 8px 24px rgba(0, 0, 0, .08);
  z-index: 5;
  max-height: 360px;
  overflow-y: auto;
}
.so-suggestion {
  display: block;
  width: 100%;
  text-align: left;
  background: none;
  border: 0;
  padding: 12px 16px;
  font-family: inherit;
  font-size: 14px;
  color: var(--so-ink);
  cursor: pointer;
  border-bottom: 1px solid var(--so-line);
  line-height: 1.4;
}
.so-suggestion:last-child { border-bottom: 0; }
.so-suggestion:hover,
.so-suggestion:focus { background: var(--so-paper); color: var(--so-link); outline: none; }
.so-suggestion-cat {
  font-size: 11px;
  color: var(--so-muted);
  text-transform: uppercase;
  letter-spacing: .06em;
  font-weight: 600;
  margin-bottom: 3px;
}
.so-suggestion-q { font-size: 14px; font-weight: 500; }
.so-suggestion-q mark { background: #fff7c2; color: var(--so-ink); padding: 1px 2px; }
.so-suggestion-empty {
  padding: 14px 16px;
  font-size: 13.5px;
  color: var(--so-muted);
}

/* ----- Quick action cards (conditional row of 4 max) ----------- */
.so-actions { padding: 28px 0 8px; }
.so-actions-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 12px;
}
.so-qa-card {
  display: flex;
  align-items: center;
  gap: 14px;
  padding: 16px 18px;
  background: #fff;
  border: 1px solid var(--so-line);
  border-radius: 4px;
  text-decoration: none;
  color: inherit;
  transition: border-color .15s, transform .15s;
}
.so-qa-card:hover {
  border-color: var(--so-link);
  transform: translateY(-1px);
}
.so-qa-ic {
  width: 38px; height: 38px;
  border-radius: 4px;
  background: var(--so-blue-soft);
  color: var(--so-link);
  display: grid; place-items: center;
  flex-shrink: 0;
}
.so-qa-ic svg { width: 20px; height: 20px; }
.so-qa-body { flex: 1; min-width: 0; }
.so-qa-ttl {
  font-size: 14px;
  font-weight: 600;
  color: var(--so-ink);
  line-height: 1.3;
}
.so-qa-desc {
  font-size: 12.5px;
  color: var(--so-muted);
  line-height: 1.4;
  margin-top: 2px;
}
.so-qa-arrow {
  color: var(--so-muted);
  transition: color .12s, transform .12s;
  flex-shrink: 0;
}
.so-qa-arrow svg { width: 16px; height: 16px; display: block; }
.so-qa-card:hover .so-qa-arrow {
  color: var(--so-link);
  transform: translateX(2px);
}

/* ----- Order lookup card (lives in the right column of the hero) ---- */
.so-lookup-card {
  background: var(--so-paper);
  border: 1px solid var(--so-line);
  border-radius: 4px;
  padding: 22px;
  display: flex;
  flex-direction: column;
  gap: 6px;
  /* Vertical-rhythm trick so the input lines up with the search bar
     across the gutter on the left. The hero adds margin above the
     search; matching it here keeps the two entry points eye-aligned. */
  margin-top: 18px;
}
.so-field-label {
  font-size: 12px;
  color: var(--so-muted);
  font-weight: 600;
  letter-spacing: .04em;
  text-transform: uppercase;
}
.so-lookup-card input[type="text"] {
  padding: 12px 14px;
  border: 1px solid var(--so-line-strong);
  border-radius: 3px;
  font: inherit;
  font-size: 14.5px;
  color: var(--so-ink);
  background: #fff;
  outline: none;
  transition: border-color .15s, box-shadow .15s;
}
.so-lookup-card input[type="text"]:focus {
  border-color: var(--so-link);
  box-shadow: 0 0 0 3px rgba(29, 107, 189, .12);
}
.so-lookup-card button {
  margin-top: 8px;
  width: 100%;
  padding: 13px 22px;
  background: var(--so-link);
  color: #fff;
  border: 0;
  border-radius: 3px;
  font-family: inherit;
  font-weight: 600;
  cursor: pointer;
  font-size: 14.5px;
  letter-spacing: .01em;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  transition: background .15s;
}
.so-lookup-card button:hover { background: var(--so-link-deep); }
.so-lookup-card button:disabled { opacity: .5; cursor: wait; }
.so-lookup-hint {
  font-size: 12.5px;
  color: var(--so-muted);
  margin-top: 8px;
  text-align: center;
}
.so-lookup-hint a { color: var(--so-link); text-decoration: underline; }

.so-order-loading {
  display: none;
  align-items: center;
  gap: 6px;
  font-size: 13.5px;
  color: var(--so-muted);
  margin-top: 14px;
  justify-content: center;
}
.so-order-loading.on { display: flex; }
.so-order-loading .so-dot {
  width: 6px; height: 6px;
  background: var(--so-link);
  border-radius: 50%;
  animation: so-bounce 1.2s infinite ease-in-out both;
}
.so-order-loading .so-dot:nth-child(2) { animation-delay: .15s; }
.so-order-loading .so-dot:nth-child(3) { animation-delay: .3s; }
@keyframes so-bounce {
  0%, 80%, 100% { transform: scale(.5); opacity: .4; }
  40%           { transform: scale(1);  opacity: 1; }
}

/* Order/service result card (HTML written by kundeservice-outlet.js).
   Same DOM contract as Cube — class names so-result-*, so-tl-*, etc.
   The JS doesn't change; this restyle just gives it a lighter look. */
.so-order-result {
  display: none;
  margin-top: 14px;
  border: 1px solid var(--so-line);
  border-radius: 4px;
  background: #fff;
  overflow: hidden;
}
.so-order-result.on { display: block; }
.so-result-head {
  padding: 14px 18px;
  background: var(--so-blue-soft);
  border-bottom: 1px solid var(--so-line);
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  flex-wrap: wrap;
}
.so-result-titles { min-width: 0; }
.so-result-kicker {
  font-size: 12px;
  color: var(--so-muted);
  text-transform: uppercase;
  letter-spacing: .06em;
  font-weight: 600;
  margin-bottom: 3px;
}
.so-result-kicker .so-ref {
  font-family: ui-monospace, SFMono-Regular, Menlo, monospace;
  color: var(--so-ink);
  font-weight: 600;
  text-transform: none;
  letter-spacing: 0;
  margin-left: 4px;
}
.so-result-status {
  font-size: 15.5px;
  font-weight: 600;
  color: var(--so-ink);
  line-height: 1.3;
}
.so-status-dot {
  width: 10px;
  height: 10px;
  border-radius: 50%;
  flex-shrink: 0;
}
.so-status-dot--wait   { background: var(--so-muted); }
.so-status-dot--active { background: var(--so-link); box-shadow: 0 0 0 3px rgba(29, 107, 189, .15); }
.so-status-dot--done   { background: var(--so-green); }
.so-status-dot--error  { background: #c0392b; }

.so-result-meta {
  display: flex;
  gap: 24px;
  flex-wrap: wrap;
  padding: 12px 18px;
  border-bottom: 1px solid var(--so-line);
  font-size: 13px;
}
.so-result-meta > div { display: flex; flex-direction: column; gap: 2px; }
.so-result-meta span:first-child {
  color: var(--so-muted);
  font-size: 11.5px;
  text-transform: uppercase;
  letter-spacing: .04em;
  font-weight: 600;
}
.so-result-meta span:last-child { color: var(--so-ink); font-weight: 500; }

/* Vertical step timeline. The right column of the hero is narrow on
   most desktop sizes, so a horizontal "Mottatt → Klargjøres → Sendt"
   row gets cramped and the dots become hard to read. Vertical layout
   gives each step its own row, and we render the step number inside
   the dot (or a checkmark when done) so every step is visible
   regardless of state — none of this depends on a hairline border
   surviving the storefront's CSS reset.

   The connecting line is drawn with a ::before pseudo-element on each
   step (except the last). It runs from below the current step's dot
   down to the next step's dot. */
.so-timeline {
  list-style: none;
  margin: 0;
  padding: 16px 18px 18px;
  background: #fff;
  display: flex;
  flex-direction: column;
  gap: 0;
}
.so-tl-step {
  display: grid;
  grid-template-columns: 28px 1fr;
  gap: 14px;
  padding: 6px 0;
  align-items: center;
  position: relative;
}
.so-tl-step:not(:last-child)::before {
  content: "";
  position: absolute;
  left: 13px;          /* matches the centre of the 28px dot (14 - 1px line) */
  top: 34px;           /* just below the dot */
  bottom: -6px;        /* extends down to the next step's dot */
  width: 2px;
  background: var(--so-line);
}
.so-tl-step--done:not(:last-child)::before { background: var(--so-link); }
.so-tl-dot {
  width: 28px;
  height: 28px;
  border-radius: 50%;
  background: #fff;
  border: 2px solid var(--so-line-strong);
  color: var(--so-muted);
  font-size: 12px;
  font-weight: 700;
  display: grid;
  place-items: center;
  z-index: 1;
  font-variant-numeric: tabular-nums;
}
.so-tl-dot svg { width: 12px; height: 12px; display: block; }
.so-tl-step--done .so-tl-dot {
  background: var(--so-link);
  border-color: var(--so-link);
  color: #fff;
}
.so-tl-step--now .so-tl-dot {
  border-color: var(--so-link);
  color: var(--so-link);
  box-shadow: 0 0 0 4px rgba(29, 107, 189, .15);
}
.so-tl-label {
  font-size: 14px;
  font-weight: 500;
  color: var(--so-muted);
  line-height: 1.3;
}
.so-tl-step--done .so-tl-label,
.so-tl-step--now .so-tl-label {
  color: var(--so-ink);
  font-weight: 600;
}

.so-result-track {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  margin: 14px 18px 18px;
  padding: 10px 14px;
  background: var(--so-paper);
  border: 1px solid var(--so-line);
  border-radius: 3px;
  text-decoration: none;
  color: var(--so-link);
  font-size: 13.5px;
  font-weight: 600;
  transition: border-color .15s, color .15s;
}
.so-result-track:hover { border-color: var(--so-link); color: var(--so-link-deep); }
.so-pill-btn {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 11px 18px;
  background: var(--so-link);
  color: #fff;
  border-radius: 3px;
  font-size: 14px;
  text-decoration: none;
  font-weight: 600;
  transition: background .15s;
}
.so-pill-btn:hover { background: var(--so-link-deep); color: #fff; }

/* ----- Layout: sidebar TOC + content --------------------------- */
.so-layout {
  display: grid;
  grid-template-columns: 240px 1fr;
  gap: 60px;
  padding: 32px 0 60px;
  border-top: 1px solid var(--so-line);
  margin-top: 40px;
}

.so-toc {
  position: sticky;
  top: 24px;
  align-self: start;
}
.so-toc-label {
  font-size: 11px;
  color: var(--so-muted);
  text-transform: uppercase;
  letter-spacing: .08em;
  margin-bottom: 14px;
  font-weight: 600;
}
.so-toc ul {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  flex-direction: column;
  gap: 0;
}
.so-toc li a {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 9px 0;
  text-decoration: none;
  color: var(--so-ink-soft);
  font-size: 14px;
  font-weight: 400;
  border-bottom: 1px solid var(--so-line);
  transition: color .12s;
  gap: 12px;
}
.so-toc li:last-child a { border-bottom: 0; }
.so-toc li a:hover { color: var(--so-link); }
.so-toc li a.active {
  color: var(--so-link);
  font-weight: 600;
}
.so-toc .so-count {
  font-size: 12px;
  color: var(--so-muted);
  font-weight: 400;
  flex-shrink: 0;
}

.so-content-head { margin-bottom: 24px; }

/* ----- Category sections --------------------------------------- */
.so-cat {
  scroll-margin-top: 24px;
  margin-bottom: 48px;
}
.so-cat:last-of-type { margin-bottom: 0; }
.so-cat-head {
  padding: 0 0 14px;
  margin-bottom: 0;
  border-bottom: 2px solid var(--so-ink);
}
.so-cat-title {
  font-size: 22px;
  font-weight: 600;
  letter-spacing: -.005em;
  margin: 0;
  line-height: 1.15;
  color: var(--so-ink);
}

/* ----- Accordion items (clean, plain) -------------------------- */
.so-q { border-bottom: 1px solid var(--so-line); }
.so-q[hidden] { display: none; }
.so-q summary {
  list-style: none;
  cursor: pointer;
  padding: 18px 0;
  display: flex;
  gap: 18px;
  align-items: flex-start;
}
.so-q summary::-webkit-details-marker { display: none; }
.so-q summary:hover .so-qtxt { color: var(--so-link); }
.so-qtxt {
  flex: 1;
  font-weight: 500;
  font-size: 15.5px;
  line-height: 1.45;
  color: var(--so-ink);
  transition: color .12s;
}
.so-chev {
  color: var(--so-muted);
  flex-shrink: 0;
  transition: transform .25s, color .12s;
  margin-top: 1px;
}
.so-chev svg { width: 14px; height: 14px; display: block; }
.so-q[open] .so-chev { transform: rotate(180deg); color: var(--so-link); }
.so-ans {
  padding: 0 0 22px 0;
  color: var(--so-ink-soft);
  font-size: 14.5px;
  line-height: 1.7;
  max-width: 72ch;
}
.so-ans p { margin: 0 0 12px; }
.so-ans p:last-child { margin-bottom: 0; }
.so-ans a { color: var(--so-link); text-decoration: underline; }
.so-ans a:hover { color: var(--so-link-deep); }
.so-ans ul, .so-ans ol { margin: 8px 0 14px; padding-left: 20px; }
.so-ans li { margin-bottom: 5px; }
.so-ans strong { color: var(--so-ink); font-weight: 600; }
.so-ans mark { background: #fff7c2; color: var(--so-ink); padding: 1px 2px; }

/* Optional GOD DEAL sticker — author can use <span class="so-deal-tag"> */
.so-deal-tag {
  display: inline-block;
  background: var(--so-green);
  color: #fff;
  font-weight: 800;
  font-size: 12px;
  padding: 3px 10px;
  border-radius: 3px;
  letter-spacing: .04em;
  text-transform: uppercase;
  font-style: italic;
  transform: rotate(-2deg);
  margin: 0 4px;
  box-shadow: 1px 1px 0 rgba(0, 0, 0, .08);
}

/* ----- Empty state -------------------------------------------- */
.so-empty {
  display: none;
  padding: 48px 0;
  text-align: center;
}
.so-empty.on { display: block; }
.so-empty h3 {
  font-size: 20px;
  font-weight: 600;
  margin: 0 0 8px;
  color: var(--so-ink);
}
.so-empty p {
  color: var(--so-muted);
  margin: 0 auto 18px;
  max-width: 42ch;
  font-size: 14.5px;
}
.so-empty-actions {
  display: flex;
  justify-content: center;
  gap: 10px;
  flex-wrap: wrap;
}
.so-btn {
  display: inline-block;
  padding: 11px 22px;
  background: var(--so-link);
  color: #fff;
  border-radius: 3px;
  font-size: 14px;
  text-decoration: none;
  font-weight: 600;
  transition: background .15s;
}
.so-btn:hover { background: var(--so-link-deep); color: #fff; }
.so-btn--outline {
  background: #fff;
  color: var(--so-ink);
  border: 1px solid var(--so-line-strong);
}
.so-btn--outline:hover {
  background: #fff;
  color: var(--so-link);
  border-color: var(--so-link);
}

/* ----- Help band (paper background, split layout) ------------- */
.so-help-band {
  background: var(--so-paper);
  border-top: 1px solid var(--so-line);
  padding: 48px 0;
  margin-top: 0;
}
.so-help-grid {
  display: grid;
  grid-template-columns: 1fr 1.2fr;
  gap: 48px;
  align-items: start;
  max-width: 1156px;
  margin: 0 auto;
  padding: 0 22px;
}
.so-channels {
  display: flex;
  flex-direction: column;
  gap: 0;
}
.so-channel {
  padding: 22px 24px;
  background: #fff;
  border: 1px solid var(--so-line);
  text-decoration: none;
  color: inherit;
  display: flex;
  align-items: center;
  gap: 18px;
  transition: border-color .12s;
}
.so-channel + .so-channel { border-top: 0; }
.so-channel:hover { border-color: var(--so-link); }
.so-ch-icon {
  width: 42px; height: 42px;
  border-radius: 4px;
  background: var(--so-blue-soft);
  color: var(--so-link);
  display: grid;
  place-items: center;
  flex-shrink: 0;
}
.so-ch-icon svg { width: 20px; height: 20px; }
.so-ch-body { flex: 1; min-width: 0; }
.so-ch-label {
  font-size: 11.5px;
  color: var(--so-muted);
  text-transform: uppercase;
  letter-spacing: .06em;
  font-weight: 600;
  margin-bottom: 2px;
}
.so-ch-value {
  font-size: 15.5px;
  font-weight: 600;
  color: var(--so-ink);
}
.so-ch-hint {
  font-size: 13px;
  color: var(--so-muted);
  margin-left: auto;
  flex-shrink: 0;
}

/* ----- Responsive --------------------------------------------- */
@media (max-width: 900px) {
  .so-layout { grid-template-columns: 1fr; gap: 30px; }
  .so-toc { position: static; display: none; }
  .so-page-grid { grid-template-columns: 1fr; gap: 28px; }
  .so-lookup-card { margin-top: 0; }
  .so-help-grid { grid-template-columns: 1fr; gap: 24px; }
}
@media (max-width: 680px) {
  .so-page-title { font-size: 28px; }
  .so-page-top { padding-top: 28px; }
  .so-actions-grid { grid-template-columns: 1fr 1fr; }
  .so-result-meta { gap: 14px; padding: 12px 14px; }
  .so-timeline { padding: 14px; }
  .so-channel { padding: 16px 18px; gap: 14px; }
  .so-ch-hint { display: none; }
}
