/* Page CSS the HTML prototype keeps in per-page <style> blocks, extracted during
   the NextJS build. Despite its old name (next-overrides.css) almost none of this
   is NextJS-specific: it is the only source of the pricing, accounting and
   journeys page styles, plus a handful of rules that override landing.css.

   Loaded globally, after landing.css, exactly as the NextJS site loaded it —
   several rules here (.page-head padding, .nav-actions gap) intentionally apply
   site-wide, so scoping them per page would change the cascade.

   Dropped from the original: the .locale-switch block, for a language switcher
   that no markup ever used (the shipped nav uses the .lang dropdown). */
.nav-actions { display: flex; align-items: center; gap: 14px; }


/* ---- pricing: billing-row layout ---- */
.billing-row { display: flex; align-items: center; justify-content: space-between; gap: 18px 32px; flex-wrap: wrap; margin-top: 30px; }
.billing-row .billing { margin: 0; }
.price-controls { display: flex; align-items: center; gap: 14px; flex-wrap: wrap; }

/* ---- currency switcher ---- */
.curr { position: relative; display: inline-flex; align-items: center; gap: 8px; font-family: var(--sans); font-size: 14px; color: var(--ink-3); }
.curr-label { color: var(--ink-3); }
.curr-btn { display: inline-flex; align-items: center; gap: 6px; padding: 8px 13px; border: 1px solid var(--line); border-radius: 999px; background: var(--bg-raised); color: var(--ink); font: inherit; font-weight: 600; line-height: 1; cursor: pointer; transition: border-color .15s, background .15s; }
.curr-btn:hover { border-color: var(--line-strong); }
.curr-btn .chev { width: 12px; height: 12px; color: var(--ink-4); transition: transform .2s var(--ease); }
.curr-btn[aria-expanded="true"] .chev { transform: rotate(180deg); }
.curr-menu { position: absolute; top: calc(100% + 7px); right: 0; min-width: 132px; background: var(--bg-raised); border: 1px solid var(--line); border-radius: var(--radius); box-shadow: var(--shadow-lg); padding: 5px; opacity: 0; transform: translateY(-6px); pointer-events: none; transition: opacity .15s var(--ease), transform .18s var(--ease); z-index: 30; }
.curr-menu.open { opacity: 1; transform: none; pointer-events: auto; }
.curr-menu button { display: flex; width: 100%; align-items: center; gap: 8px; padding: 9px 12px; border: 0; background: transparent; border-radius: 8px; font: inherit; font-size: 14px; font-weight: 500; color: var(--ink-2); cursor: pointer; text-align: left; }
.curr-menu button:hover { background: var(--bg-sunken); color: var(--ink); }
.curr-menu button .tick { margin-left: auto; opacity: 0; color: var(--ink); }
.curr-menu button[aria-checked="true"] { color: var(--ink); font-weight: 600; }
.curr-menu button[aria-checked="true"] .tick { opacity: 1; }

/* ---- book-a-demo CTA ---- */
.demo-cta { display: inline-flex; align-items: center; gap: 16px; text-decoration: none; color: var(--ink-3); font-family: var(--sans); }
.demo-cta .demo-cta-text { font-size: 13.5px; line-height: 1.4; max-width: 34ch; text-align: right; }
.demo-cta .demo-cta-text strong { display: block; color: var(--ink); font-weight: 600; font-size: 14.5px; }
.demo-cta .btn { flex-shrink: 0; }

/* ---- 3-plan showcase grid ---- */
.showcase { display: grid; grid-template-columns: repeat(3, 1fr); gap: 20px; align-items: stretch; margin-top: 26px; }
.showcase .plan { margin-top: 0; }
.showcase .plan-feats { flex: 1 0 auto; }

@media (max-width: 900px) {
  .showcase { grid-template-columns: 1fr; max-width: 460px; margin-inline: auto; gap: 18px; }
  .showcase .plan, .showcase .plan--s2, .showcase .plan--s3 { margin-top: 0; }
  .showcase .plan-blurb, .showcase .plan-note { min-height: 0; }
}

@media (max-width: 760px) {
  .billing-row { flex-direction: column; align-items: flex-start; gap: 18px; }
  .demo-cta { width: 100%; justify-content: space-between; gap: 14px; border-top: 1px solid var(--line); padding-top: 20px; }
  .demo-cta .demo-cta-text { text-align: left; max-width: none; }
}

/* ---- hero entrance: pure CSS slide-in so LCP is immediate (no JS dependency) ---- */
@keyframes heroSlideIn {
  from { transform: translateY(14px); }
  to   { transform: none; }
}
.hero-headline { animation: heroSlideIn .5s var(--ease, ease-out) backwards; }
.hero-visual   { animation: heroSlideIn .75s var(--ease, ease-out) .07s backwards; }
@media (prefers-reduced-motion: reduce) {
  .hero-headline, .hero-visual { animation: none; }
}

/* The floating CTA renders as a <button> when it opens the Cal overlay; .peek sets
   no border and buttons don't get the anchor's pointer cursor, so reset both.
   Cal's modal brings its own chrome, so there is no overlay styling to define. */
button.peek { border: 0; cursor: pointer; }

/* ---- Accounting / regnskap page ---- */

/* Hero: the unbillable hour recedes (JS sets animation directly after reveal). */
@keyframes ss-recede { to { color: var(--line-strong); } }
.page-head { padding-bottom: clamp(24px, 2.8vw, 34px); }
.page-head .lp-head { margin-bottom: 0; }

/* Day ledger snap helper — applied during initial set() to prevent transition flash */
.ledger.no-anim .lr-fill,
.ledger.no-anim .lr-val,
.ledger.no-anim .ledger-pct { transition: none !important; }

/* Day ledger */
.ledger { max-width: 820px; }
.ledger-rows { margin-top: 24px; border-top: 1px solid var(--line); }
.ledger-row { display: flex; align-items: center; gap: 24px; padding: 15px 0; border-bottom: 1px solid var(--line); }
.lr-main { flex: 1 1 auto; min-width: 0; }
.lr-label { display: block; font-family: var(--sans); font-size: 15.5px; line-height: 1.3; color: var(--ink-2); }
.lr-bar { display: block; position: relative; height: 9px; margin-top: 9px; background: var(--bg-sunken); border-radius: 2px; overflow: hidden; }
.lr-fill { position: absolute; left: 0; top: 0; bottom: 0; border-radius: 2px; background: var(--line-strong); transition: width .62s var(--ease, ease-out), background .4s var(--ease, ease-out); }
.lr-val { flex: 0 0 76px; text-align: right; font-size: 13px; color: var(--ink-3); transition: color .4s var(--ease, ease-out); }
.ledger-row.is-key .lr-fill { background: var(--ink); }
.ledger-row.is-key .lr-val { color: var(--ink); }
.ledger-row.is-zero .lr-val { color: var(--ink-4); }
.ledger-foot { display: flex; align-items: baseline; justify-content: space-between; gap: 16px; flex-wrap: wrap; padding-top: 20px; }
.ledger-total { display: inline-flex; align-items: baseline; gap: 12px; }
.ledger-sum { font-size: clamp(20px, 2.6vw, 28px); font-weight: 500; letter-spacing: -0.02em; color: var(--ink); }
.ledger-pct { font-size: 14px; font-weight: 500; color: var(--ink-3); transition: color .4s var(--ease, ease-out); }
.ledger.is-soft .ledger-pct { color: #2c9e63; }

/* Integrations list */
@keyframes ss-live { 0%, 100% { opacity: 1; } 50% { opacity: .4; } }
.intg { max-width: 940px; margin-top: clamp(30px, 4vw, 44px); }
.intg-row { display: flex; flex-wrap: wrap; align-items: baseline; gap: 6px 24px; padding: 22px 2px; border-top: 1px solid var(--line); }
.intg-end { border-top: 1px solid var(--line); }
.intg-name { flex: 0 0 170px; font-family: var(--sans); font-weight: 600; font-size: 20px; letter-spacing: -0.02em; color: var(--ink); }
.intg-what { flex: 1 1 320px; min-width: 0; font-family: var(--sans); font-size: 16px; line-height: 1.5; color: var(--ink-3); max-width: 48ch; margin: 0; }
.intg-state { flex: 0 0 auto; display: inline-flex; align-items: center; gap: 8px; font-size: 10.5px; letter-spacing: 0.14em; text-transform: uppercase; color: var(--ink-2); }
.intg-state i { display: block; width: 6px; height: 6px; border-radius: 50%; background: #2c9e63; animation: ss-live 3.4s var(--ease, ease-out) infinite; }
.intg-row.is-soon .intg-name,
.intg-row.is-soon .intg-what,
.intg-row.is-soon .intg-state { color: var(--ink-4); }
.intg-row.is-soon .intg-state i { background: none; border: 1px solid var(--ink-4); animation: none; }
.intg-note { margin: 22px 0 0; font-size: 15px; line-height: 1.6; color: var(--ink-4); max-width: 56ch; }
.intg-note p { margin: 0; }
.intg-note a { color: var(--ink-3); text-decoration: underline; text-underline-offset: 3px; text-decoration-color: var(--line-strong); }

/* "The answer is yes" two-column checklist */
.yes-intro { font-family: var(--sans); font-size: clamp(18px, 2vw, 22px); color: var(--ink-3); margin: 0 0 16px; }
.yeslist { list-style: none; margin: clamp(30px, 4vw, 44px) 0 0; padding: 0; column-width: 380px; column-gap: 64px; max-width: 1020px; }
.yeslist li { break-inside: avoid; position: relative; font-family: var(--sans); font-size: clamp(17px, 1.7vw, 19px); line-height: 1.4; color: var(--ink-2); padding: 18px 0 18px 32px; border-bottom: 1px solid var(--line); }
.yeslist li::before { content: "✓"; position: absolute; left: 0; top: 18px; color: #2c9e63; font-weight: 700; font-size: 16px; }

@media (prefers-reduced-motion: reduce) {
  .lr-fill, .lr-val, .ledger-pct { transition: none; }
  .intg-state i { animation: none; }
}

/* ---- journeys page ---- */
.page-head--tight .lp { max-width: none; }
.page-head--tight .lp-head { max-width: 660px; }
.page-head--tight .lp-head:has(+ .paths) { margin-bottom: clamp(16px, 2vw, 26px); }

/* horizontal scrollable row of path-choice cards */
.paths { margin-top: 20px; }
.paths-nav {
  display: flex; gap: 14px;
  overflow-x: auto; overscroll-behavior-x: contain;
  scroll-snap-type: x proximity;
  padding: 6px 2px 18px; margin: 0 -2px;
  -webkit-overflow-scrolling: touch;
}
.paths-nav::-webkit-scrollbar { height: 0; }

.pcard {
  flex: 1 1 0; min-width: 158px; max-width: 230px;
  scroll-snap-align: start;
  background: var(--bg-raised); border: 1px solid var(--line);
  border-radius: var(--radius-lg); box-shadow: var(--shadow-xs);
  padding: 20px 16px 18px; cursor: pointer; text-align: center;
  outline: 1.5px solid transparent; outline-offset: -1.5px;
  transition: transform .22s var(--ease), box-shadow .22s var(--ease), border-color .22s, outline-color .22s;
  -webkit-appearance: none; appearance: none; font: inherit; color: inherit;
}
.pcard:hover { transform: translateY(-3px); box-shadow: var(--shadow); border-color: var(--line-strong); }
.pcard.is-active { outline-color: var(--accent); border-color: var(--accent); box-shadow: var(--shadow); }

/* extra bottom padding so the SoftSync end-node that overflows the mini svg clears the label */
.pcard .pmini { height: 150px; position: relative; display: grid; justify-items: center; padding-bottom: 18px; }
.pcard .pmini svg { height: 150px; width: auto; overflow: visible; }
.pcard .plabel { display: block; font-size: 14px; font-weight: 600; color: var(--ink-2); margin-top: 34px; line-height: 1.25; }

/* dotted trail (shared mini + big) */
.trail { fill: none; stroke: var(--ink-4); stroke-linecap: round; stroke-linejoin: round; }
.pmini .trail { stroke-width: 4.5; stroke-dasharray: 0.5 11; }
.pbig  .trail { stroke-width: 2.5; stroke-dasharray: 0.5 9; }

/* logo bubbles plotted onto the curves */
.ppoints { position: absolute; inset: 0; pointer-events: none; overflow: visible; }
.ppt { position: absolute; transform: translate(-50%, -50%); }
.pbub { display: grid; place-items: center; border-radius: 50%; background: var(--bg-raised); border: 1px solid var(--line); box-shadow: var(--shadow-sm); }
.pbub img { object-fit: contain; }
.pbub svg { color: var(--ink-3); display: block; }
.ppt--end .pbub { background: var(--accent); border-color: var(--accent); box-shadow: var(--shadow); }
.ppt--end .pbub img { filter: brightness(0) invert(1); }

.pmini .pbub { width: 33px; height: 33px; }
.pmini .pbub img, .pmini .pbub svg { width: 19px; height: 19px; }
.pmini .ppt--end .pbub { width: 38px; height: 38px; }
.pmini .ppt--end .pbub img { width: 21px; height: 21px; }

/* the chosen path played out large, below the nav row */
.pfeature { max-width: 820px; margin-left: auto; margin-right: auto; margin-top: clamp(18px, 2.6vw, 36px); scroll-margin-top: clamp(14px, 5vh, 40px); }

.paper {
  position: relative; z-index: 2;
  background: #fff; border-radius: 20px;
  padding: clamp(64px, 10vh, 132px) clamp(20px, 5vw, 56px) clamp(34px, 5vw, 56px);
  box-shadow: 0 32px 64px -26px rgba(61, 32, 32, .24), 0 3px 10px rgba(61, 32, 32, .05);
}
.paper::before, .paper::after {
  content: ''; position: absolute; inset: 0; z-index: -1;
  background: #fff; border-radius: inherit;
  box-shadow: 0 20px 44px -24px rgba(61, 32, 32, .2);
}
.paper::before { transform: rotate(-1.5deg); }
.paper::after  { transform: rotate(1.9deg); }

.paper-body { transition: opacity .3s var(--ease), transform .3s var(--ease); }
.paper-body.swap { opacity: 0; transform: translateY(10px); }

.pfeature-head { text-align: left; max-width: 34ch; margin: 0 0 6px; }
.pfeature-head h2 { font-size: clamp(24px, 3vw, 34px); letter-spacing: -0.03em; line-height: 1.1; margin: 0; }
.pfeature-head p { color: var(--ink-3); margin: 12px 0 0; font-size: clamp(15px, 1.6vw, 17px); line-height: 1.55; max-width: 46ch; text-wrap: pretty; }

.pbig { position: relative; display: grid; justify-content: center; margin-top: clamp(8px, 2vw, 18px); }
.pbig-stage { position: relative; }
.pbig-stage svg { height: clamp(600px, 72vw, 820px); width: auto; overflow: visible; display: block; }

.pbig .pbub { width: 58px; height: 58px; }
.pbig .pbub img { width: 32px; height: 32px; }
.pbig .pbub svg { width: 30px; height: 30px; }

.pcap { position: absolute; top: 50%; transform: translateY(-50%); width: 150px; }
.pcap--right { left: calc(100% + 16px); text-align: left; }
.pcap--left  { right: calc(100% + 16px); text-align: right; }
.pcap .pcap-name { display: block; font-weight: 600; font-size: 14.5px; color: var(--ink); line-height: 1.2; }
.pcap .pcap-sub  { display: block; font-size: 12.5px; color: var(--ink-4); margin-top: 3px; line-height: 1.35; }

/* SoftSync destination — overlaps the trail's end with negative margin */
.pfeature-foot { position: relative; z-index: 1; display: grid; justify-items: center; text-align: center; gap: 7px; margin-top: -34px; }
.pfeature-foot .ss-mark { width: 60px; height: 60px; border-radius: 50%; background: var(--accent); display: grid; place-items: center; box-shadow: var(--shadow); }
.pfeature-foot .ss-mark img { width: 32px; height: 32px; filter: brightness(0) invert(1); }
.pfeature-foot .ss-name { font-weight: 600; font-size: 14.5px; color: var(--ink); line-height: 1.25; margin-top: 5px; }
.pfeature-foot .ss-sub  { font-size: 12.5px; color: var(--ink-4); line-height: 1.35; }

@media (max-width: 600px) {
  .paper { border-radius: 16px; padding: 34px 15px 36px; }
  .pfeature-head h2 { font-size: clamp(25px, 6.6vw, 31px); }
  .pfeature-head p { margin-top: 13px; }
  .pbig { margin-top: 18px; }
  .pcap { width: 98px; }
  .pcap--right { left: calc(100% + 9px); }
  .pcap--left  { right: calc(100% + 9px); }
  .pcap .pcap-name { font-size: 12px; }
  .pcap .pcap-sub  { font-size: 10.5px; }
  .pbig .pbub { width: 46px; height: 46px; }
  .pbig .pbub img { width: 25px; height: 25px; }
  .pbig .pbub svg { width: 24px; height: 24px; }
  .pbig-stage svg { height: clamp(500px, 124vw, 600px); }
}

