/* solidlab-web UI kit — marketing site
   Dark-mode default (Sort base + Antikkhvit fg + Oslo accent)
*/
@import url('./colors_and_type.css');

* { box-sizing: border-box; margin: 0; padding: 0; }

html, body {
  background: var(--sort);
  color: var(--antikkhvit);
  font-family: var(--font-sans);
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

.shell { max-width: 1280px; margin: 0 auto; padding: 0 48px; }

/* ---------- Header ---------- */
.sl-header {
  position: sticky; top: 0; z-index: 10;
  background: rgba(10,10,10,0.92);
  border-bottom: 1px solid var(--border-dark);
}
.sl-header__inner {
  display: flex; align-items: center; justify-content: space-between;
  height: 72px;
}
/* =============================================================
   WORDMARK — solid (700) + lab (400) + .ai (Oslo blue)
   The weight contrast IS the brand mark.
   ============================================================= */
.sl-wm {
  font-family: var(--font-sans);
  font-size: 22px;
  letter-spacing: -0.02em;
  color: var(--antikkhvit);
  text-decoration: none;
  display: inline-flex;
  align-items: baseline;
  line-height: 1;
}
.sl-wm__solid { font-weight: 700; }
.sl-wm__lab   { font-weight: 300; }
.sl-wm__ai    {
  font-weight: 300;
  margin-left: 0.5px;
  color: #6B8290;  /* Nordic Breeze — dark mode default */
}

/* Light mode: .ai uses Oslo blue (darker, better contrast on Antikkhvit) */
html[data-theme="light"] .sl-wm__ai {
  color: #4A5A62;
}

/* Footer variant — inherits size, .ai slightly dimmed */
.sl-wm--footer {
  font-size: inherit;
  display: inline;
}
.sl-wm--footer .sl-wm__ai {
  opacity: 0.7;
}
.sl-nav { display: flex; gap: 32px; }
.sl-nav a {
  font-family: var(--font-mono); font-size: 12px; letter-spacing: 0.08em;
  text-transform: uppercase; color: var(--mist); text-decoration: none;
  transition: color 150ms ease;
}
.sl-nav a:hover, .sl-nav a.active { color: var(--antikkhvit); }
.sl-nav a.active { color: var(--oslo); }

/* ---------- Slash label ---------- */
.sl-slash {
  font-family: var(--font-mono); font-size: 12px; letter-spacing: 0.08em;
  text-transform: uppercase; color: var(--mist); font-weight: 500;
}
.sl-slash--accent { color: var(--oslo); }

/* ---------- Hero ---------- */
.sl-hero {
  padding: 120px 0 100px;
  border-bottom: 1px solid var(--border-dark);
}
.sl-hero__eyebrow { margin-bottom: 32px; }
.sl-hero__title {
  font-size: 88px; line-height: 1.0; letter-spacing: -0.03em;
  font-weight: 400; color: var(--antikkhvit);
  max-width: 900px; text-wrap: balance;
}
.sl-hero__light { font-weight: 400; }
.sl-hero__bold  { font-weight: 700; }
.sl-hero__title em {
  font-style: normal; color: var(--oslo);
}
.sl-hero__title--stacked { display: flex; flex-direction: column; gap: 20px; }
.sl-hero__tagline {
  display: block;
  line-height: 1.1;
  margin-top: 20px;
  color: var(--oslo);
  font-weight: 500;
  font-style: normal;
}
.sl-hero__tagline em {
  font-style: normal;
  color: var(--oslo);
  font-weight: 500;
}
.sl-hero__tagline--32 { font-size: 32px; }
.sl-hero__tagline--40 { font-size: 40px; }
.sl-hero__title--compact { font-size: 64px !important; }

/* Side-by-side compare view */
.sl-hero-compare { display: flex; flex-direction: column; background: var(--sort); }
.sl-hero-compare__band { position: relative; border-top: 1px solid var(--border-dark); }
.sl-hero-compare__band:first-child { border-top: 0; }
.sl-hero-compare__tag {
  position: absolute; top: 24px; right: 32px; z-index: 2;
  color: var(--oslo);
}
.sl-hero-compare__gap { height: 1px; background: var(--oslo); opacity: 0.35; }
.sl-hero--compact { padding: 80px 0 64px !important; min-height: 0 !important; }
.sl-hero__sub {
  font-size: 18px; line-height: 1.6; color: var(--alvesolv);
  max-width: 560px; margin-top: 32px; text-wrap: pretty;
}
.sl-hero__cta { display: flex; gap: 12px; margin-top: 40px; }

/* ---------- Button ---------- */
.sl-btn {
  display: inline-flex; align-items: center; gap: 8px;
  font-family: var(--font-sans); font-size: 14px; font-weight: 500;
  line-height: 1; padding: 14px 20px;
  border-radius: 0; border: 1px solid transparent; cursor: pointer;
  transition: all 150ms ease; text-decoration: none;
}
.sl-btn--primary { background: var(--oslo); color: var(--antikkhvit); }
.sl-btn--primary:hover { background: var(--nordic-breeze); }
.sl-btn--ghost {
  background: transparent; color: var(--antikkhvit);
  border-color: var(--border-dark);
}
.sl-btn--ghost:hover { border-color: var(--antikkhvit); }

/* ---------- Section ---------- */
.sl-section { padding: 120px 0; border-bottom: 1px solid var(--border-dark); }
.sl-section__head { display: flex; justify-content: space-between; align-items: flex-end; margin-bottom: 64px; gap: 48px; flex-wrap: wrap; }
.sl-section__title { font-size: 48px; line-height: 1.1; letter-spacing: -0.02em; font-weight: 700; max-width: 700px; text-wrap: balance; }
.sl-section__intro { font-size: 16px; line-height: 1.6; color: var(--alvesolv); max-width: 380px; }

/* ---------- Three-column (What we do) ---------- */
.sl-cols-3 { display: grid; grid-template-columns: 1fr 1fr 1fr; gap: 24px; }
.sl-col {
  padding: 32px 28px; border: 1px solid var(--border-dark);
  display: flex; flex-direction: column; gap: 12px; min-height: 280px;
  transition: border-color 150ms ease;
}
.sl-col:hover { border-color: var(--oslo); }
.sl-col__num { color: var(--oslo); }
.sl-col__title { font-size: 24px; font-weight: 600; letter-spacing: -0.01em; color: var(--antikkhvit); margin-top: 4px; }
.sl-col__body { font-size: 15px; line-height: 1.6; color: var(--alvesolv); }

/* ---------- Work grid ---------- */
.sl-work { display: grid; grid-template-columns: 1fr 1fr; gap: 2px; background: var(--border-dark); border: 1px solid var(--border-dark); }
.sl-work__item {
  background: var(--sort); padding: 48px;
  display: flex; flex-direction: column; gap: 16px; min-height: 360px;
  cursor: pointer; transition: background 200ms ease;
  text-decoration: none; color: inherit;
}
.sl-work__item:hover { background: #141414; }
.sl-work__item:hover .sl-work__arrow { color: var(--oslo); transform: translateX(4px); }
.sl-work__head { display: flex; justify-content: space-between; align-items: center; }
.sl-work__meta { font-family: var(--font-mono); font-size: 11px; letter-spacing: 0.08em; text-transform: uppercase; color: var(--mist); }
.sl-work__arrow { font-family: var(--font-mono); color: var(--mist); transition: all 200ms ease; }
.sl-work__title { font-size: 40px; font-weight: 600; letter-spacing: -0.02em; color: var(--antikkhvit); margin-top: auto; }
.sl-work__kicker { font-size: 15px; color: var(--alvesolv); line-height: 1.6; max-width: 420px; }
.sl-work__thumb {
  width: 100%; aspect-ratio: 16/9; margin-top: 16px;
  background: var(--border-dark); position: relative; overflow: hidden;
}
.sl-work__thumb.a { background: linear-gradient(180deg, #1a2428 0%, #0f1518 100%); }
.sl-work__thumb.b { background: #141414; }
.sl-work__thumb.c { background: #1a1a1a; }
.sl-work__thumb.d { background: #0A0A0A; }
.sl-work__thumb svg { position: absolute; inset: 0; width: 100%; height: 100%; }

/* ---------- About (warm) ---------- */
.sl-about { background: var(--sort); }
.sl-about__inner { display: grid; grid-template-columns: 1fr 1fr; gap: 80px; align-items: start; }
.sl-about__title { font-size: 48px; line-height: 1.1; letter-spacing: -0.02em; font-weight: 700; text-wrap: balance; }
.sl-about__body { display: flex; flex-direction: column; gap: 24px; color: var(--alvesolv); font-size: 17px; line-height: 1.65; }
.sl-about__body strong { color: var(--antikkhvit); font-weight: 500; }
.sl-values { display: grid; grid-template-columns: 1fr 1fr; gap: 2px; background: var(--border-dark); border: 1px solid var(--border-dark); margin-top: 64px; }
.sl-value { background: var(--sort); padding: 28px; }
.sl-value__num { font-family: var(--font-mono); font-size: 11px; letter-spacing: 0.08em; color: var(--oslo); text-transform: uppercase; }
.sl-value__title { font-size: 18px; font-weight: 600; color: var(--antikkhvit); margin-top: 12px; }
.sl-value__body { font-size: 14px; color: var(--alvesolv); margin-top: 8px; line-height: 1.55; }

/* ---------- Contact ---------- */
.sl-contact { padding: 120px 0; }
.sl-contact__grid { display: grid; grid-template-columns: 2fr 1fr; gap: 80px; align-items: start; }
.sl-contact__title { font-size: 64px; line-height: 1.05; letter-spacing: -0.03em; font-weight: 700; text-wrap: balance; }
.sl-contact__title em { font-style: normal; color: var(--oslo); }
.sl-contact__meta { display: flex; flex-direction: column; gap: 20px; font-family: var(--font-mono); font-size: 14px; color: var(--alvesolv); }
.sl-contact__meta a { color: var(--antikkhvit); text-decoration: none; border-bottom: 1px solid transparent; transition: border 150ms; }
.sl-contact__meta a:hover { border-bottom-color: var(--oslo); }
.sl-contact__label { font-size: 10px; color: var(--mist); letter-spacing: 0.08em; text-transform: uppercase; display: block; margin-bottom: 6px; }

/* ---------- Footer ---------- */
.sl-footer {
  border-top: 1px solid var(--border-dark);
  padding: 48px 0; font-family: var(--font-mono); font-size: 12px;
  color: var(--mist); letter-spacing: 0.04em;
}
.sl-footer__inner { display: flex; justify-content: space-between; align-items: center; gap: 24px; flex-wrap: wrap; }
.sl-footer__right { display: flex; gap: 24px; }
.sl-footer__right a { color: var(--mist); text-decoration: none; transition: color 150ms; }
.sl-footer__right a:hover { color: var(--antikkhvit); }

/* ---------- Detail page (product case study) ---------- */
.sl-detail { padding: 80px 0 120px; }
.sl-detail__back { font-family: var(--font-mono); font-size: 12px; color: var(--mist); text-transform: uppercase; letter-spacing: 0.08em; text-decoration: none; transition: color 150ms; display: inline-flex; gap: 8px; }
.sl-detail__back:hover { color: var(--antikkhvit); }
.sl-detail__title { font-size: 72px; line-height: 1.05; letter-spacing: -0.03em; font-weight: 700; margin-top: 24px; text-wrap: balance; }
.sl-detail__meta { display: grid; grid-template-columns: repeat(4, 1fr); gap: 24px; margin: 48px 0; padding: 32px 0; border-top: 1px solid var(--border-dark); border-bottom: 1px solid var(--border-dark); }
.sl-detail__meta div span { display: block; font-family: var(--font-mono); font-size: 10px; letter-spacing: 0.08em; text-transform: uppercase; color: var(--mist); margin-bottom: 8px; }
.sl-detail__meta div strong { font-family: var(--font-sans); font-weight: 500; font-size: 16px; color: var(--antikkhvit); }
.sl-detail__body { max-width: 720px; font-size: 18px; line-height: 1.7; color: var(--alvesolv); display: flex; flex-direction: column; gap: 24px; }
.sl-detail__body strong { color: var(--antikkhvit); font-weight: 500; }

/* Clickable indicator */
.is-clickable { cursor: pointer; }

/* View toggle (for demo) */
.view { display: none; }
.view.active { display: block; }

/* =============================================================
   LIGHT MODE — Antikkgrå-based Nordic theme
   Activated by <html data-theme="light">
   Strategy: swap the dark-ground (#0A0A0A) to Antikkgrå (#D5CFC2),
   but ALSO give cards/buttons a SEPARATE surface-color so they
   remain visually distinct from the page background.
   ============================================================= */

html[data-theme="light"] {
  /* Flip the core tokens */
  --sort:          #D5CFC2;  /* Antikkgrå becomes the "ground" */
  --antikkhvit:    #0A0A0A;  /* Text becomes near-black */
  --border-dark:   rgba(10, 10, 10, 0.12);
  --fog:           #5A5A5A;
  --mist:          #8A8A8A;
  --alvesolv:      #5A5A5A;

  /* Semantic surface for cards/elevated elements — slightly lighter than bg */
  --surface-elev:  #E8E4DB;  /* Border-light shade, warmer than pure */
  --surface-hover: #DCD7CB;  /* Between bg and surface-elev */
}

/* Dark mode defaults for surface tokens (defined globally for consistency) */
:root {
  --surface-elev:  #141414;
  --surface-hover: #1a1a1a;
}

/* Smooth theme transitions */
html, body, .sl-header {
  transition: background 300ms ease, color 300ms ease, border-color 300ms ease;
}

/* ---------- LIGHT MODE OVERRIDES ---------- */

/* Cards and surfaces that use var(--sort) as background */
html[data-theme="light"] .sl-work__item,
html[data-theme="light"] .sl-about,
html[data-theme="light"] .sl-value,
html[data-theme="light"] .sl-value-card,
html[data-theme="light"] .sl-hero-compare {
  background: var(--surface-elev);
}

/* Hover states */
html[data-theme="light"] .sl-work__item:hover,
html[data-theme="light"] .sl-wwd__card:hover,
html[data-theme="light"] .sl-work__card:hover,
html[data-theme="light"] .sl-value-card:hover {
  background: var(--surface-hover);
}

/* Work thumbnails with hardcoded dark colors */
html[data-theme="light"] .sl-work__thumb,
html[data-theme="light"] .sl-work__thumb.b,
html[data-theme="light"] .sl-work__thumb.c,
html[data-theme="light"] .sl-work__thumb.d {
  background: var(--surface-elev);
}

/* Tweaks toolbar */
html[data-theme="light"] .sl-tweaks {
  background: var(--surface-elev);
}

/* Header becomes translucent Antikkgrå in light */
html[data-theme="light"] .sl-header {
  background: rgba(213, 207, 194, 0.92);
}

/* Footer text/dividers */
html[data-theme="light"] .sl-footer {
  color: var(--fog);
}

/* ---------- Theme toggle button ---------- */
.sl-theme-toggle {
  background: transparent;
  border: 1px solid var(--border-dark);
  color: var(--mist);
  font-family: var(--font-mono);
  font-size: 11px;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  padding: 8px 14px;
  cursor: pointer;
  transition: all 150ms ease;
  display: inline-flex;
  align-items: center;
  gap: 8px;
  line-height: 1;
  margin-left: 16px;
}
.sl-theme-toggle:hover {
  border-color: var(--antikkhvit);
  color: var(--antikkhvit);
}

/* =============================================================
   BUTTON FIX — Primary button always has light text
   regardless of theme, because Oslo background is dark in both modes.
   ============================================================= */
.sl-btn--primary {
  color: #F4F1EA !important;  /* Always Antikkhvit text on Oslo */
}
.sl-btn--primary:hover {
  color: #F4F1EA !important;
}

/* Ghost button in light mode gets proper border/text */
html[data-theme="light"] .sl-btn--ghost {
  border-color: var(--antikkhvit);  /* now #0A0A0A, which is correct */
  color: var(--antikkhvit);
}
html[data-theme="light"] .sl-btn--ghost:hover {
  background: var(--surface-elev);
  border-color: var(--antikkhvit);
}

/* =============================================================
   TYPEWRITER — cycles through words with a typing animation.
   Used in the hero title. Blinking cursor in Oslo blue matches
   the /-monospace vocabulary of the brand.
   ============================================================= */
.sl-typewriter {
  display: inline-flex;
  align-items: baseline;
  color: var(--antikkhvit);
  /* Keep min-width so layout doesn't jump between short/long words */
  min-width: 1ch;
}

.sl-typewriter__text {
  white-space: pre;
}

.sl-typewriter__cursor {
  display: inline-block;
  color: var(--oslo);
  font-weight: 400;
  margin-left: 4px;
  animation: sl-cursor-blink 1.1s step-end infinite;
}

@keyframes sl-cursor-blink {
  0%, 50% { opacity: 1; }
  50.01%, 100% { opacity: 0; }
}

/* Reduced motion — no blinking, no typing (word is shown fully) */
@media (prefers-reduced-motion: reduce) {
  .sl-typewriter__cursor {
    animation: none;
    opacity: 0;
  }
}

/* =============================================================
   .sl-sect — generic section layout used by Investors page
   (separate from legacy .sl-section to avoid conflicts)
   ============================================================= */

.sl-sect {
  padding: 120px 0;
  border-bottom: 1px solid var(--border-dark);
}

.sl-sect__eyebrow {
  font-family: var(--font-mono);
  font-size: 12px;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--mist);
  margin-bottom: 24px;
}

.sl-sect__title {
  font-size: 56px;
  font-weight: 700;
  letter-spacing: -0.02em;
  line-height: 1.1;
  color: var(--antikkhvit);
  margin-bottom: 24px;
  max-width: 800px;
  text-wrap: balance;
}

.sl-sect__sub {
  font-size: 18px;
  line-height: 1.6;
  color: var(--alvesolv);
  max-width: 720px;
  margin-bottom: 40px;
}

.sl-sect__sub:last-child {
  margin-bottom: 0;
}

/* ---------- Alt-variant section (warmer tone) ---------- */
.sl-sect--alt {
  background: rgba(255, 255, 255, 0.015);
}
html[data-theme="light"] .sl-sect--alt {
  background: var(--surface-elev);
}

