/* Cautana AG — site styles
   Palette: midnight blue corporate format (white content, blue swish, gradient cover). */

@font-face { font-family: "Schibsted Grotesk"; src: url("fonts/schibsted-grotesk-latin-500-normal.woff2") format("woff2"); font-weight: 500; font-display: swap; }
@font-face { font-family: "Schibsted Grotesk"; src: url("fonts/schibsted-grotesk-latin-600-normal.woff2") format("woff2"); font-weight: 600; font-display: swap; }
@font-face { font-family: "Source Serif 4"; src: url("fonts/source-serif-4-latin-400-normal.woff2") format("woff2"); font-weight: 400; font-display: swap; }
@font-face { font-family: "Source Serif 4"; src: url("fonts/source-serif-4-latin-400-italic.woff2") format("woff2"); font-weight: 400; font-style: italic; font-display: swap; }
@font-face { font-family: "Source Serif 4"; src: url("fonts/source-serif-4-latin-600-normal.woff2") format("woff2"); font-weight: 600; font-display: swap; }

:root {
  --midnight: #0f1e45;
  --deep: #1c3a7a;
  --blue: #2a63b8;
  --swish: #9cc0ee;
  --mist: #eef3fb;
  --paper: #ffffff;
  --text: #24304b;
  --muted: #56617d;
  --rule: #d5dff0;

  --sans: "Schibsted Grotesk", system-ui, sans-serif;
  --serif: "Source Serif 4", Georgia, serif;

  --wrap: 72rem;
  --gutter: clamp(1.25rem, 4vw, 2.5rem);
}

*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; scroll-padding-top: 5rem; }
@media (prefers-reduced-motion: reduce) { html { scroll-behavior: auto; } }

body {
  margin: 0;
  background: var(--paper);
  color: var(--text);
  font-family: var(--serif);
  font-size: 1.125rem;
  line-height: 1.65;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

h1, h2, h3, h4 {
  font-family: var(--sans);
  font-weight: 600;
  color: var(--midnight);
  line-height: 1.12;
  letter-spacing: -0.02em;
  margin: 0;
}
h2 { font-size: clamp(1.9rem, 3.6vw, 2.65rem); max-width: 22ch; }
h3 { font-size: 1.35rem; letter-spacing: -0.01em; line-height: 1.25; }
p { margin: 0 0 1em; max-width: 64ch; }
a { color: var(--blue); text-underline-offset: 0.18em; text-decoration-thickness: 1px; }
a:hover { color: var(--deep); }
:focus-visible { outline: 3px solid var(--blue); outline-offset: 3px; border-radius: 2px; }

.wrap { width: 100%; max-width: var(--wrap); margin: 0 auto; padding: 0 var(--gutter); }
.skip { position: absolute; left: -999px; top: 0.5rem; background: var(--midnight); color: #fff; padding: 0.5rem 1rem; z-index: 50; }
.skip:focus { left: 0.5rem; }
.nowrap { white-space: nowrap; }
@media (max-width: 860px) { .wide-only { display: none; } }

/* ---------- Header ---------- */
.site-header {
  position: sticky; top: 0; z-index: 20;
  background: rgba(255, 255, 255, 0.92);
  backdrop-filter: saturate(1.4) blur(10px);
  border-bottom: 1px solid transparent;
  transition: border-color 0.2s;
}
.site-header.scrolled { border-bottom-color: var(--rule); }
.site-header .wrap { display: flex; align-items: center; justify-content: space-between; height: 4.25rem; }
.brand { display: inline-flex; align-items: center; gap: 0.55rem; text-decoration: none; color: var(--midnight); font-family: var(--sans); font-weight: 600; font-size: 1.3rem; letter-spacing: -0.01em; }
.brand svg { width: 1.9rem; height: auto; }
.site-nav { display: flex; gap: clamp(1rem, 2.4vw, 2rem); font-family: var(--sans); font-weight: 500; font-size: 0.98rem; }
.site-nav a { color: var(--text); text-decoration: none; padding: 0.4rem 0; }
.site-nav a:hover { color: var(--blue); }
.site-nav .nav-contact { color: var(--blue); }
@media (max-width: 760px) {
  .site-nav a:not(.nav-contact) { display: none; }
}

/* ---------- Hero: corporate cover — light at the top, midnight at the bottom ---------- */
.hero {
  position: relative;
  overflow: hidden;
  min-height: min(92vh, 52rem);
  display: flex; flex-direction: column;
  background: linear-gradient(180deg, #f6f9fe 0%, #e7effb 42%, #9fbbe3 64%, var(--deep) 82%, var(--midnight) 100%);
  color: var(--midnight);
}
.hero-swish { position: absolute; inset: auto 0 0 0; width: 100%; height: 52%; pointer-events: none; }
.hero-copy { position: relative; padding-top: clamp(3.5rem, 11vh, 7.5rem); }
.hero h1 {
  font-size: clamp(2.7rem, 7vw, 5.4rem);
  line-height: 1.02;
  letter-spacing: -0.035em;
  max-width: 13ch;
}
.hero .lead { font-size: clamp(1.15rem, 1.8vw, 1.35rem); max-width: 40ch; margin-top: 1.5rem; color: var(--text); }
.actions { display: flex; flex-wrap: wrap; gap: 0.85rem; margin-top: 2rem; }
.btn {
  display: inline-block; font-family: var(--sans); font-weight: 600; font-size: 1rem;
  padding: 0.85rem 1.4rem; border-radius: 999px; text-decoration: none; transition: background 0.15s, color 0.15s;
}
.btn-primary { background: var(--midnight); color: #fff; }
.btn-primary:hover { background: var(--deep); color: #fff; }
.btn-quiet { color: var(--midnight); box-shadow: inset 0 0 0 1.5px var(--midnight); }
.btn-quiet:hover { background: var(--midnight); color: #fff; }
.hero-foot { position: relative; margin-top: auto; padding-bottom: 2.25rem; padding-top: 4rem; }
.hero-foot p { margin: 0; color: #dbe6f7; font-family: var(--sans); font-weight: 500; font-size: 1.05rem; }

/* ---------- Sections ---------- */
.section { padding: clamp(4.5rem, 10vw, 7.5rem) 0; }
.section + .section { padding-top: 0; }
.section-mist { background: var(--mist); padding: clamp(4.5rem, 10vw, 7.5rem) 0; }
.section-mist + .section { padding-top: clamp(4.5rem, 10vw, 7.5rem); }
.intro { display: grid; grid-template-columns: minmax(0, 5fr) minmax(0, 6fr); gap: clamp(1.5rem, 5vw, 5rem); align-items: start; }
.intro p:last-child { margin-bottom: 0; }
@media (max-width: 860px) { .intro { grid-template-columns: 1fr; } }

.big-figure { font-family: var(--sans); font-weight: 600; color: var(--midnight); font-size: clamp(3.5rem, 9vw, 6.5rem); line-height: 0.95; letter-spacing: -0.045em; display: block; }
.cite { font-size: 0.88rem; color: var(--muted); }

.causes { list-style: none; padding: 0; margin: 1.25rem 0 0; display: flex; flex-wrap: wrap; gap: 0.5rem 0.6rem; }
.causes li { font-family: var(--sans); font-size: 0.95rem; font-weight: 500; color: var(--deep); background: var(--paper); border: 1px solid var(--rule); border-radius: 999px; padding: 0.3rem 0.85rem; }

/* ---------- Journey diagram (the signature element) ---------- */
.journeys { margin-top: clamp(3rem, 6vw, 4.5rem); }
.journeys > h3 { margin-bottom: 0.4rem; }
.journeys > .cite { margin-bottom: 2.25rem; }
.journey { display: grid; grid-template-columns: 11rem minmax(0, 1fr); gap: 1.5rem; align-items: start; padding: 1.75rem 0; border-top: 1px solid var(--rule); }
.journey:last-of-type { border-bottom: 1px solid var(--rule); }
.place { font-family: var(--sans); font-weight: 600; color: var(--midnight); line-height: 1.3; }
.place small { display: block; font-weight: 500; color: var(--muted); font-size: 0.88rem; margin-top: 0.2rem; }

.track { display: flex; align-items: flex-start; }
.stop { flex: 0 0 auto; width: 0; position: relative; }
.stop::before { content: ""; position: absolute; top: 2.75rem; left: -6px; width: 12px; height: 12px; border-radius: 50%; background: var(--paper); border: 2.5px solid var(--midnight); }
.stop span { position: absolute; top: 3.8rem; left: 0; transform: translateX(-50%); white-space: nowrap; font-family: var(--sans); font-size: 0.85rem; font-weight: 500; color: var(--text); }
.stop:first-child span { transform: none; left: -6px; }
.leg { position: relative; height: 5.3rem; min-width: 3.5rem; }
.leg::after {
  content: ""; position: absolute; left: 6px; right: 6px; top: calc(2.75rem + 5px); height: 2px;
  background: var(--midnight); transform-origin: left center; transition: transform 0.9s cubic-bezier(.4,0,.2,1);
}
.leg span { position: absolute; top: 0.3rem; left: 50%; transform: translateX(-50%); white-space: nowrap; font-family: var(--sans); font-size: 0.82rem; color: var(--muted); text-align: center; line-height: 1.25; }
.journey.far .leg::after { background: repeating-linear-gradient(90deg, var(--midnight) 0 8px, transparent 8px 13px); }
.result { flex: 0 0 auto; margin-left: 2.4rem; margin-top: 1.95rem; padding: 0.55rem 0.9rem; border-radius: 10px; background: var(--paper); border: 1px solid var(--rule); font-family: var(--sans); font-size: 0.88rem; line-height: 1.35; color: var(--muted); }
.result strong { display: block; color: var(--midnight); font-size: 1.05rem; font-weight: 600; }
.journey.goal .result { background: var(--midnight); border-color: var(--midnight); color: #c9d8f1; }
.journey.goal .result strong { color: #fff; }
.journey.goal .stop::before { background: var(--midnight); }

/* Draw-in, once, when the diagram enters view */
.js .journeys:not(.drawn) .leg::after { transform: scaleX(0); }
.journeys.drawn .journey:nth-of-type(2) .leg::after { transition-delay: 0.6s; }
.journeys.drawn .journey:nth-of-type(3) .leg::after { transition-delay: 1.2s; }
@media (prefers-reduced-motion: reduce) { .leg::after { transition: none !important; } .js .journeys:not(.drawn) .leg::after { transform: none; } }

@media (max-width: 860px) {
  .journey { grid-template-columns: 1fr; gap: 1rem; }
  .track { flex-direction: column; align-items: stretch; padding-left: 0.5rem; }
  .stop { width: auto; height: 0; }
  .stop::before { top: -6px; left: -6px; }
  .stop span, .stop:first-child span { top: -0.75rem; left: 1rem; transform: none; }
  .leg { height: auto; min-height: 3.25rem; min-width: 0; flex: 0 0 auto !important; }
  .leg::after { left: -1px; right: auto; top: 10px; bottom: 10px; width: 2px; height: auto; transform-origin: center top; }
  .journey.far .leg::after { background: repeating-linear-gradient(180deg, var(--midnight) 0 8px, transparent 8px 13px); }
  .js .journeys:not(.drawn) .leg::after { transform: scaleY(0); }
  .leg span { position: static; display: block; transform: none; text-align: left; padding: 1.1rem 0 1.1rem 1rem; white-space: normal; }
  .result { margin: 1.25rem 0 0; align-self: flex-start; }
}

/* ---------- Platform: a real sequence, so numbered ---------- */
.steps { list-style: none; padding: 0; margin: clamp(2.5rem, 5vw, 3.5rem) 0 0; display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 0; counter-reset: step; }
.steps li { counter-increment: step; padding: 0 clamp(1rem, 2.5vw, 2rem) 0 0; position: relative; }
.steps li + li { padding-left: clamp(1rem, 2.5vw, 2rem); border-left: 1px solid var(--rule); }
.steps li::before { content: counter(step); display: block; font-family: var(--sans); font-weight: 600; font-size: 3rem; line-height: 1; color: var(--swish); margin-bottom: 1rem; letter-spacing: -0.03em; }
.steps h3 { margin-bottom: 0.25rem; }
.steps .role { font-family: var(--sans); font-weight: 500; font-size: 0.95rem; color: var(--blue); margin-bottom: 0.9rem; }
.steps p { font-size: 1.05rem; }
@media (max-width: 860px) {
  .steps { grid-template-columns: 1fr; gap: 2.25rem; }
  .steps li, .steps li + li { padding: 0 0 0 0; border-left: 0; }
}

.targets { margin-top: clamp(2.5rem, 5vw, 3.5rem); padding-top: 2rem; border-top: 1px solid var(--rule); display: grid; grid-template-columns: minmax(0, 4fr) minmax(0, 7fr); gap: clamp(1.5rem, 5vw, 5rem); }
.targets ul { margin: 0; padding: 0; list-style: none; columns: 2; column-gap: 2.5rem; }
.targets li { break-inside: avoid; padding: 0.15rem 0 0.75rem 1.1rem; position: relative; font-size: 1.05rem; }
.targets li::before { content: ""; position: absolute; left: 0; top: 0.72em; width: 6px; height: 6px; border-radius: 50%; background: var(--blue); }
@media (max-width: 860px) { .targets { grid-template-columns: 1fr; } .targets ul { columns: 1; } }

/* ---------- Applications ---------- */
.apps { margin-top: clamp(2.5rem, 5vw, 3.5rem); display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 1.25rem; }
.app { background: var(--paper); border-radius: 14px; padding: 1.6rem 1.5rem 1.4rem; }
.app .stage { font-family: var(--sans); font-weight: 500; font-size: 0.92rem; color: var(--blue); margin-bottom: 0.6rem; }
.app h3 { margin-bottom: 0.7rem; }
.app p { font-size: 1.02rem; margin: 0; }
.app.first { background: var(--midnight); }
.app.first h3 { color: #fff; }
.app.first p { color: #d3def2; }
.app.first .stage { color: var(--swish); }
@media (max-width: 860px) { .apps { grid-template-columns: 1fr; } }

/* ---------- Markets ---------- */
.markets { display: grid; grid-template-columns: minmax(0, 5fr) minmax(0, 6fr); gap: clamp(1.5rem, 5vw, 5rem); }
.market-list { margin: 0; display: grid; grid-template-columns: auto 1fr; gap: 0.9rem 1.5rem; align-content: start; }
.market-list dt { font-family: var(--sans); font-weight: 600; color: var(--midnight); }
.market-list dd { margin: 0; }
@media (max-width: 860px) { .markets { grid-template-columns: 1fr; } }

/* ---------- Team ---------- */
.people { margin-top: clamp(2.5rem, 5vw, 3.5rem); display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 2rem; }
.person { border-top: 2px solid var(--midnight); padding-top: 1rem; }
.person h3 { font-size: 1.25rem; }
.person .title { font-family: var(--sans); font-weight: 500; color: var(--blue); font-size: 0.98rem; margin: 0.2rem 0 0.6rem; }
.person p { font-size: 1rem; color: var(--muted); }
.advisors { margin-top: 2.5rem; }
.advisors h3 { font-size: 1.05rem; margin-bottom: 0.8rem; }
.advisors ul { list-style: none; padding: 0; margin: 0; display: flex; flex-wrap: wrap; gap: 0.5rem 2.5rem; }
.advisors li { font-size: 1.02rem; }
.advisors li span { color: var(--muted); }
@media (max-width: 860px) { .people { grid-template-columns: 1fr; gap: 1.5rem; } }

/* ---------- Notice ---------- */
.notice { border-left: 3px solid var(--blue); padding: 0.2rem 0 0.2rem 1.25rem; font-size: 1rem; color: var(--muted); max-width: 64ch; }
.notice strong { color: var(--midnight); font-family: var(--sans); font-weight: 600; }

/* ---------- Contact / footer: second appearance of the swish ---------- */
.contact { position: relative; overflow: hidden; background: linear-gradient(180deg, var(--deep) 0%, var(--midnight) 70%); color: #d8e3f5; padding: clamp(3.5rem, 8vw, 5.5rem) 0 2.5rem; }
.contact h2 { color: #fff; }
.contact .swish { position: absolute; right: -10%; top: -30%; width: 75%; height: 120%; pointer-events: none; opacity: 0.55; }
.contact .wrap { position: relative; }
.contact-grid { display: grid; grid-template-columns: minmax(0, 6fr) minmax(0, 5fr); gap: clamp(1.5rem, 5vw, 5rem); margin-top: 2rem; }
.contact p { color: #d8e3f5; }
.contact a { color: #fff; }
.foot-name { font-family: var(--sans); font-weight: 600; font-size: clamp(1.8rem, 4vw, 2.6rem); color: #fff; letter-spacing: -0.02em; margin: 0 0 0.75rem; }
.contact .mail { font-family: var(--sans); font-weight: 600; font-size: clamp(1.4rem, 3vw, 2rem); letter-spacing: -0.02em; text-decoration-thickness: 2px; }
.contact address { font-style: normal; line-height: 1.6; }
.footer-bar { margin-top: clamp(3.5rem, 7vw, 5rem); padding-top: 1.5rem; border-top: 1px solid rgba(255, 255, 255, 0.18); display: flex; flex-wrap: wrap; justify-content: space-between; gap: 1rem; font-family: var(--sans); font-size: 0.92rem; color: #aebfdc; }
.footer-bar a { color: #d8e3f5; }
@media (max-width: 860px) { .contact-grid { grid-template-columns: 1fr; } }

/* ---------- Legal page ---------- */
.legal { padding: clamp(3rem, 7vw, 5rem) 0 clamp(4rem, 8vw, 6rem); }
.legal h1 { font-size: clamp(2.2rem, 5vw, 3.2rem); margin-bottom: 0.5rem; }
.legal h2 { font-size: 1.6rem; margin: 3rem 0 1rem; max-width: none; }
.legal h3 { font-size: 1.15rem; margin: 1.75rem 0 0.5rem; }
.legal dl { display: grid; grid-template-columns: 13rem 1fr; gap: 0.5rem 1.5rem; margin: 0; }
.legal dt { font-family: var(--sans); font-weight: 600; color: var(--midnight); }
.legal dd { margin: 0; }
.legal ul { padding-left: 1.2rem; max-width: 64ch; }
.legal li { margin-bottom: 0.4rem; }
.placeholder { background: #fff3c4; padding: 0 0.25rem; border-radius: 3px; }
@media (max-width: 640px) { .legal dl { grid-template-columns: 1fr; } .legal dd { margin-bottom: 0.75rem; } }
