/* ============================================================
   DANS DEVELOPMENT — dark cinematic portfolio
   ============================================================ */

:root {
  --bg: #0b0b0c;
  --bg-2: #0f0f11;
  --panel: #141416;
  --text: #edeae3;
  --muted: #a39e93;
  --gold: #c9a961;
  --gold-2: #e4c57c;
  --line: rgba(237, 234, 227, 0.09);
  --line-strong: rgba(237, 234, 227, 0.16);
  --font-display: "Space Grotesk", system-ui, sans-serif;
  --font-serif: "Playfair Display", Georgia, serif;
  --font-body: "Inter", system-ui, sans-serif;
  --font-mono: "JetBrains Mono", ui-monospace, monospace;
  --ease-out: cubic-bezier(0.16, 1, 0.3, 1);
  --container: 1200px;
}

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

html { scroll-behavior: smooth; }

body {
  background: var(--bg);
  color: var(--text);
  font-family: var(--font-body);
  font-size: 1.0625rem;
  line-height: 1.65;
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}

::selection { background: var(--gold); color: #151005; }

img { max-width: 100%; display: block; }

a { color: inherit; text-decoration: none; }

:focus-visible {
  outline: 2px solid var(--gold);
  outline-offset: 3px;
  border-radius: 2px;
}

.container {
  width: min(var(--container), 100% - 3rem);
  margin-inline: auto;
}

.gold { color: var(--gold); }

.serif {
  font-family: var(--font-serif);
  font-style: italic;
  font-weight: 500;
  background: linear-gradient(120deg, var(--gold-2), var(--gold) 70%);
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
  padding-right: 0.06em; /* italic overhang clip fix */
}

/* ---------- atmosphere: grain + glow ---------- */

.grain {
  position: fixed;
  inset: -50%;
  width: 200%;
  height: 200%;
  pointer-events: none;
  z-index: 2000;
  opacity: 0.055;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='240' height='240'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.9' numOctaves='2'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)'/%3E%3C/svg%3E");
  animation: grain-shift 9s steps(6) infinite;
}

@keyframes grain-shift {
  0%, 100% { transform: translate(0, 0); }
  20% { transform: translate(-3%, 2%); }
  40% { transform: translate(2%, -3%); }
  60% { transform: translate(-2%, -2%); }
  80% { transform: translate(3%, 3%); }
}

.glow {
  position: fixed;
  width: 60vw;
  height: 60vw;
  border-radius: 50%;
  filter: blur(120px);
  pointer-events: none;
  z-index: 0;
  opacity: 0.5;
}

.glow-a {
  top: -25vw;
  right: -20vw;
  background: radial-gradient(circle, rgba(201, 169, 97, 0.14), transparent 65%);
  animation: drift-a 26s ease-in-out infinite alternate;
}

.glow-b {
  bottom: -30vw;
  left: -22vw;
  background: radial-gradient(circle, rgba(120, 110, 90, 0.10), transparent 65%);
  animation: drift-b 32s ease-in-out infinite alternate;
}

@keyframes drift-a { to { transform: translate(-6vw, 8vh); } }
@keyframes drift-b { to { transform: translate(7vw, -6vh); } }

main { position: relative; z-index: 1; }

/* ---------- nav ---------- */

.nav {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 100;
  transition: background 0.4s ease, border-color 0.4s ease, backdrop-filter 0.4s ease;
  border-bottom: 1px solid transparent;
}

.nav.scrolled {
  background: rgba(11, 11, 12, 0.72);
  -webkit-backdrop-filter: blur(14px);
  backdrop-filter: blur(14px);
  border-bottom-color: var(--line);
}

.nav-inner {
  width: min(var(--container), 100% - 3rem);
  margin-inline: auto;
  display: flex;
  align-items: center;
  gap: 2.5rem;
  padding-block: 1.1rem;
}

.logo {
  font-family: var(--font-display);
  font-weight: 700;
  font-size: 1.02rem;
  letter-spacing: 0.14em;
  white-space: nowrap;
}

.logo-thin { font-weight: 500; color: var(--muted); }

.nav-links {
  display: flex;
  gap: 1.9rem;
  margin-left: auto;
}

.nav-links a {
  font-size: 0.92rem;
  font-weight: 500;
  color: var(--muted);
  transition: color 0.25s ease;
  position: relative;
}

.nav-links a::after {
  content: "";
  position: absolute;
  left: 0;
  bottom: -6px;
  width: 100%;
  height: 1px;
  background: var(--gold);
  transform: scaleX(0);
  transform-origin: left;
  transition: transform 0.3s var(--ease-out);
}

.nav-links a:hover,
.nav-links a.active { color: var(--text); }

.nav-links a:hover::after,
.nav-links a.active::after { transform: scaleX(1); }

.nav-cta .cta-short { display: none; }

.burger {
  display: none;
  background: none;
  border: 0;
  width: 48px;
  height: 48px;
  cursor: pointer;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  gap: 7px;
}

.burger span {
  display: block;
  width: 24px;
  height: 2px;
  background: var(--text);
  transition: transform 0.35s var(--ease-out), opacity 0.3s ease;
}

.burger.open span:first-child { transform: translateY(4.5px) rotate(45deg); }
.burger.open span:last-child { transform: translateY(-4.5px) rotate(-45deg); }

.mobile-menu {
  position: fixed;
  inset: 0;
  z-index: 90;
  background: rgba(11, 11, 12, 0.96);
  -webkit-backdrop-filter: blur(18px);
  backdrop-filter: blur(18px);
  display: grid;
  place-items: center;
  opacity: 0;
  visibility: hidden;
  /* visibility flips only after the fade-out; instantly on open (focusability) */
  transition: opacity 0.35s ease, visibility 0s linear 0.35s;
}

.mobile-menu.open {
  opacity: 1;
  visibility: visible;
  transition: opacity 0.35s ease;
}

@media (min-width: 821px) {
  .mobile-menu { display: none; }
}

.mobile-menu nav {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 1.1rem;
}

.mobile-menu a:not(.btn) {
  font-family: var(--font-display);
  font-size: 1.7rem;
  font-weight: 600;
  color: var(--text);
  padding-block: 0.45rem;
}

.mobile-menu .btn { margin-top: 1rem; }

/* ---------- buttons ---------- */

.btn {
  display: inline-flex;
  align-items: center;
  gap: 0.6rem;
  font-family: var(--font-display);
  font-weight: 600;
  font-size: 0.98rem;
  padding: 0.85rem 1.7rem;
  border-radius: 999px;
  border: 1px solid transparent;
  cursor: pointer;
  transition: transform 0.3s var(--ease-out), background 0.3s ease,
    border-color 0.3s ease, color 0.3s ease, box-shadow 0.3s ease;
  will-change: transform;
}

.btn-primary {
  background: linear-gradient(120deg, var(--gold-2), var(--gold));
  color: #171204;
  box-shadow: 0 6px 24px rgba(201, 169, 97, 0.22);
}

.btn-primary:hover {
  transform: translateY(-2px);
  box-shadow: 0 10px 32px rgba(201, 169, 97, 0.32);
}

.btn-ghost {
  border-color: var(--line-strong);
  color: var(--text);
}

.btn-ghost:hover {
  border-color: var(--gold);
  color: var(--gold-2);
  transform: translateY(-2px);
}

.btn-small { padding: 0.6rem 1.25rem; font-size: 0.88rem; }
.btn-big { padding: 1.05rem 2.1rem; font-size: 1.05rem; }

/* ---------- shared section bits ---------- */

.section { padding-block: clamp(6rem, 12vw, 9.5rem); position: relative; }

.section-alt {
  background: linear-gradient(180deg, transparent, rgba(255, 255, 255, 0.03) 18%, rgba(255, 255, 255, 0.03) 82%, transparent);
}

.kicker {
  font-family: var(--font-mono);
  font-size: 0.78rem;
  font-weight: 500;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  color: var(--gold);
  margin-bottom: 1.4rem;
}

.section-title {
  font-family: var(--font-display);
  font-weight: 600;
  font-size: clamp(2rem, 4.6vw, 3.4rem);
  line-height: 1.08;
  letter-spacing: -0.02em;
  margin-bottom: 1.2rem;
  text-wrap: balance;
}

.section-sub {
  color: var(--muted);
  max-width: 34rem;
  margin-bottom: clamp(2.5rem, 6vw, 4.5rem);
}

/* ---------- hero ---------- */

.hero {
  min-height: 100vh;
  min-height: 100svh;
  display: flex;
  align-items: center;
  padding-top: 6rem;
  padding-bottom: 4rem;
  position: relative;
  overflow: hidden;
}

/* cursor spotlight (JS feeds --mx/--my; desktop only).
   Hidden while the WebGL canvas is live — the opaque canvas would occlude it anyway. */
.hero:has(.hero-canvas.is-live)::before { content: none !important; }

@media (pointer: fine) {
  .hero::before {
    content: "";
    position: absolute;
    inset: 0;
    z-index: 0;
    background: radial-gradient(
      560px circle at var(--mx, 70%) var(--my, 40%),
      rgba(201, 169, 97, 0.055),
      transparent 70%
    );
    pointer-events: none;
  }
}

.hero-content { position: relative; z-index: 2; }

/* liquid-gold shader canvas */
.hero-canvas {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  z-index: 0;
  display: block;
  opacity: 0;
  transition: opacity 1.4s ease;
}

.hero-canvas.is-live { opacity: 1; }

/* right-side visual counterweight — floating 3D stage */
.hero-visual {
  position: absolute;
  z-index: 1;
  right: clamp(1rem, 2.5vw, 3.5rem);
  top: 50%;
  transform: translateY(-50%) rotate(3.5deg);
  width: clamp(480px, 40vw, 680px);
  pointer-events: none;
  perspective: 1100px;
  animation: hero-float 9s ease-in-out infinite alternate;
}

@keyframes hero-float {
  to { transform: translateY(calc(-50% - 14px)) rotate(3.5deg); }
}

.hero-tilt {
  display: grid;
  transform-style: preserve-3d;
  will-change: transform;
}

/* showcase slides — depth swap: old sinks away, new rises in.
   Inactive slides are visibility:hidden so they never paint (avoids
   z-fighting between coplanar layers in the 3D context). */
.hero-slide {
  grid-area: 1 / 1;
  position: relative;
  opacity: 0;
  visibility: hidden;
  transform: translateY(32px) scale(0.97);
  /* no filter here: blur on 3D-composited layers breaks rasterization on some GPUs */
  transition: opacity 1.05s var(--ease-out), transform 1.05s var(--ease-out),
    visibility 0s linear 1.05s;
  pointer-events: none;
}

.hero-slide.is-active {
  opacity: 1;
  visibility: visible;
  transform: none;
  transform-style: preserve-3d;
  transition: opacity 1.05s var(--ease-out), transform 1.05s var(--ease-out);
}

.hero-slide.is-leaving {
  opacity: 0;
  visibility: visible;
  transform: translateY(-30px) scale(0.955);
}

.hero-shot {
  position: relative;
  border: 1px solid rgba(201, 169, 97, 0.26);
  border-radius: 14px;
  overflow: hidden;
  background: var(--panel);
  box-shadow: 0 40px 110px rgba(0, 0, 0, 0.6), 0 0 52px rgba(201, 169, 97, 0.10);
}

.hero-shot img { width: 100%; height: auto; }

/* moving specular sheen, driven by --shn from the tilt loop */
.hero-shot::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(115deg, transparent 42%, rgba(255, 255, 255, 0.055) 50%, transparent 58%);
  transform: translateX(calc(var(--shn, 0) * 34%));
  pointer-events: none;
}

.hero-shot-phone {
  position: absolute;
  left: -0.75rem; /* stays clear of the headline/glass — fully visible phone */
  bottom: -3rem;
  width: 27%;
  border: 1px solid rgba(201, 169, 97, 0.22);
  border-radius: 20px;
  overflow: hidden;
  background: var(--panel);
  box-shadow: 0 30px 70px rgba(0, 0, 0, 0.65), 0 0 36px rgba(201, 169, 97, 0.08);
  transform: rotate(-4deg) translateZ(52px);
}

.hero-shot-phone img { width: 100%; height: auto; }

.hero-title {
  font-family: var(--font-display);
  font-weight: 600;
  font-size: clamp(2.6rem, 8.2vw, 6.6rem);
  line-height: 1.02;
  letter-spacing: -0.03em;
  margin-bottom: 1.8rem;
}

.hero-title > span { display: block; }

.hero-title .serif { font-size: 1.04em; }

/* rotating headline word */
.rot-word {
  display: inline-block;
  transition: transform 0.5s var(--ease-out), opacity 0.4s ease, filter 0.4s ease;
}

.rot-word.rot-out {
  transform: translateY(-0.5em);
  opacity: 0;
  filter: blur(7px);
}

.rot-word.rot-prep {
  transition: none;
  transform: translateY(0.5em);
  opacity: 0;
  filter: blur(7px);
}

.hero-sub {
  font-size: clamp(1.05rem, 1.6vw, 1.25rem);
  color: var(--muted);
  max-width: 34rem;
  margin-bottom: 2.6rem;
}

.hero-cta { display: flex; gap: 1rem; flex-wrap: wrap; margin-bottom: 1.1rem; }

.hero-price {
  font-family: var(--font-mono);
  font-size: 0.82rem;
  letter-spacing: 0.06em;
  color: var(--muted);
}

/* ---------- marquee ---------- */

.marquee {
  border-block: 1px solid var(--line);
  overflow: hidden;
  padding-block: 1.05rem;
  position: relative;
  z-index: 1;
}

.marquee-track {
  display: flex;
  align-items: center;
  width: max-content;
  animation: marquee 32s linear infinite;
}

.marquee:hover .marquee-track { animation-play-state: paused; }

.marquee-track span,
.marquee-track i {
  margin-right: 2.6rem;
}

.marquee-track span {
  font-family: var(--font-display);
  font-weight: 500;
  font-size: 0.95rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--muted);
  white-space: nowrap;
}

.marquee-track i {
  font-style: normal;
  color: var(--gold);
  font-size: 0.7rem;
}

@keyframes marquee { to { transform: translateX(-50%); } }

/* ---------- projects ---------- */

.project {
  display: grid;
  grid-template-columns: 1.15fr 0.85fr;
  gap: clamp(2rem, 5vw, 4.5rem);
  align-items: center;
  padding-block: clamp(3rem, 6vw, 5rem);
}

.project + .project { border-top: 1px solid var(--line); }

.project-flip .project-media { order: 2; }
.project-flip .project-info { order: 1; }

.project-media { position: relative; }

.browser-frame {
  border: 1px solid var(--line-strong);
  border-radius: 14px;
  overflow: hidden;
  background: var(--panel);
  box-shadow: 0 30px 80px rgba(0, 0, 0, 0.55);
  transition: transform 0.5s var(--ease-out), box-shadow 0.5s ease;
}

.project-media:hover .browser-frame {
  transform: translateY(-6px);
  box-shadow: 0 44px 100px rgba(0, 0, 0, 0.65);
}

.browser-bar {
  display: flex;
  gap: 6px;
  padding: 10px 14px;
  border-bottom: 1px solid var(--line);
  background: rgba(255, 255, 255, 0.02);
}

.browser-bar i {
  width: 9px;
  height: 9px;
  border-radius: 50%;
  background: var(--line-strong);
}

.browser-frame img { width: 100%; height: auto; }

/* skeleton shimmer while screenshots load (JS adds .ldd on load) */
.browser-frame img:not(.ldd),
.phone-frame img:not(.ldd) {
  background: linear-gradient(110deg, #141416 30%, #1d1d21 45%, #141416 60%);
  background-size: 220% 100%;
  animation: shimmer 1.7s linear infinite;
}

@keyframes shimmer {
  from { background-position: 120% 0; }
  to { background-position: -120% 0; }
}

.phone-frame {
  position: absolute;
  right: -1.2rem;
  bottom: -2rem;
  width: clamp(84px, 22%, 170px);
  border: 1px solid var(--line-strong);
  border-radius: 22px;
  overflow: hidden;
  background: var(--panel);
  box-shadow: 0 24px 60px rgba(0, 0, 0, 0.65);
  transition: transform 0.5s var(--ease-out);
}

.project-media:hover .phone-frame { transform: translateY(-8px) rotate(-1.5deg); }

.phone-frame img { width: 100%; height: auto; }

.project-num {
  font-family: var(--font-serif);
  font-style: italic;
  font-size: clamp(3rem, 5vw, 4.4rem);
  line-height: 1;
  color: transparent;
  -webkit-text-stroke: 1px rgba(201, 169, 97, 0.5);
  margin-bottom: 1rem;
}

.project-kicker {
  font-family: var(--font-mono);
  font-size: 0.74rem;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--gold);
  margin-bottom: 0.7rem;
}

.project-info h3 {
  font-family: var(--font-display);
  font-weight: 600;
  font-size: clamp(1.7rem, 3vw, 2.4rem);
  letter-spacing: -0.02em;
  margin-bottom: 1rem;
}

.project-desc { color: var(--muted); margin-bottom: 1.1rem; }

.project-proof {
  font-size: 0.95rem;
  margin-bottom: 1.4rem;
}

.tags {
  list-style: none;
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
  margin-bottom: 1.6rem;
}

.tags li {
  font-family: var(--font-mono);
  font-size: 0.74rem;
  letter-spacing: 0.04em;
  color: var(--muted);
  border: 1px solid var(--line);
  border-radius: 999px;
  padding: 0.32rem 0.75rem;
  transition: border-color 0.3s ease, color 0.3s ease;
}

.project:hover .tags li { border-color: var(--line-strong); }

.project-link {
  font-family: var(--font-display);
  font-weight: 600;
  color: var(--gold-2);
  position: relative;
  display: inline-block;
  padding: 0.6rem 0;
}

.project-link::after {
  content: "";
  position: absolute;
  left: 0;
  bottom: 2px;
  width: 100%;
  height: 1px;
  background: var(--gold);
  transform: scaleX(0.35);
  transform-origin: left;
  transition: transform 0.35s var(--ease-out);
}

.project-link:hover::after { transform: scaleX(1); }

.projects-outro {
  border-top: 1px solid var(--line);
  margin-top: clamp(1.5rem, 3vw, 2.5rem);
  padding-top: 2.2rem;
  color: var(--muted);
  font-size: 0.98rem;
  max-width: 44rem;
}

/* ---------- services ---------- */

.services {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 1px;
  background: var(--line);
  border: 1px solid var(--line);
  border-radius: 18px;
  overflow: hidden;
}

.service {
  background: var(--bg);
  padding: 2.2rem 1.8rem 2.5rem;
  transition: background 0.35s ease;
  position: relative;
}

.service:hover { background: #121214; }

.service::before {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 2px;
  background: linear-gradient(90deg, var(--gold-2), var(--gold));
  transform: scaleX(0);
  transform-origin: left;
  transition: transform 0.45s var(--ease-out);
}

.service:hover::before { transform: scaleX(1); }

.service-num {
  font-family: var(--font-mono);
  font-size: 0.78rem;
  color: var(--gold);
  margin-bottom: 2.6rem;
}

.service h3 {
  font-family: var(--font-display);
  font-weight: 600;
  font-size: 1.28rem;
  margin-bottom: 0.7rem;
}

.service p { font-size: 0.95rem; color: var(--muted); }

/* ---------- why ---------- */

.why {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: clamp(2rem, 4vw, 3.5rem) clamp(2.5rem, 5vw, 5rem);
  margin-top: clamp(2.5rem, 5vw, 4rem);
}

.why-item {
  border-left: 1px solid var(--line-strong);
  padding-left: 1.6rem;
  transition: border-color 0.35s ease;
}

.why-item:hover { border-left-color: var(--gold); }

.why-item h3 {
  font-family: var(--font-display);
  font-weight: 600;
  font-size: 1.22rem;
  margin-bottom: 0.55rem;
}

.why-item p { color: var(--muted); font-size: 0.98rem; }

/* ---------- proces: scroll story (Twilio-style sticky stage) ---------- */

.story { position: relative; }

html.js .story-track { height: 420vh; }

.story-sticky {
  display: flex;
  flex-direction: column;
  padding: 6rem 0 2rem;
  gap: 1.5rem;
}

html.js .story-sticky {
  position: sticky;
  top: 0;
  height: 100vh;
  height: 100svh;
  justify-content: space-between;
  overflow: hidden;
}

.story-head .section-title { margin-bottom: 0; }

.story-stage {
  display: grid;
  grid-template-columns: 0.9fr 1.1fr;
  gap: clamp(2rem, 5vw, 4.5rem);
  align-items: center;
  flex: 1;
  min-height: 0;
  width: min(var(--container), 100% - 3rem);
}

/* panels (left) */
html.js .story-panels { position: relative; height: 100%; min-height: 240px; }

.story-panel { max-width: 26rem; }

html.js .story-panel {
  position: absolute;
  inset: 0;
  display: flex;
  flex-direction: column;
  justify-content: center;
  opacity: 0;
  transform: translateY(26px);
  transition: opacity 0.55s var(--ease-out), transform 0.55s var(--ease-out);
  pointer-events: none;
}

html.js .story-panel.is-active { opacity: 1; transform: none; pointer-events: auto; }

html:not(.js) .story-panel + .story-panel { margin-top: 3rem; }

.story-num {
  font-family: var(--font-serif);
  font-style: italic;
  font-size: 2.8rem;
  line-height: 1;
  color: transparent;
  -webkit-text-stroke: 1px rgba(201, 169, 97, 0.5);
  margin-bottom: 1.1rem;
}

.story-panel h3 {
  font-family: var(--font-display);
  font-weight: 600;
  font-size: clamp(1.5rem, 2.6vw, 2.1rem);
  letter-spacing: -0.02em;
  margin-bottom: 0.7rem;
}

.story-panel p { color: var(--muted); }

.story-panel em { color: var(--gold-2); font-style: italic; }

/* visuals (right) */
html.js .story-visuals { position: relative; height: 100%; min-height: 300px; }

html.js .story-visual {
  position: absolute;
  inset: 0;
  display: grid;
  place-items: center;
  opacity: 0;
  transform: scale(0.96) translateY(16px);
  transition: opacity 0.55s var(--ease-out), transform 0.55s var(--ease-out);
}

html.js .story-visual.is-active { opacity: 1; transform: none; }

html:not(.js) .story-visual { margin-top: 2rem; }

.story-card {
  width: min(100%, 500px);
  border: 1px solid var(--line-strong);
  border-radius: 20px;
  background: linear-gradient(160deg, #17171a, #101013);
  box-shadow: 0 30px 80px rgba(0, 0, 0, 0.5);
  padding: clamp(1.4rem, 2.5vw, 2rem);
}

/* 0 — chat */
.chat-bubble {
  max-width: 86%;
  padding: 0.85rem 1.1rem;
  font-size: 0.94rem;
  line-height: 1.5;
}

.cb-in {
  background: #1d1d21;
  border: 1px solid var(--line);
  border-radius: 14px 14px 14px 4px;
}

.cb-out {
  background: linear-gradient(120deg, var(--gold-2), var(--gold));
  color: #171204;
  border-radius: 14px 14px 4px 14px;
  margin: 1rem 0 0 auto;
}

.cb-who {
  display: block;
  font-family: var(--font-mono);
  font-size: 0.66rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  opacity: 0.65;
  margin-bottom: 0.3rem;
}

.chat-meta {
  font-family: var(--font-mono);
  font-size: 0.72rem;
  color: var(--muted);
  text-align: right;
  margin-top: 1rem;
}

/* 1 — design */
.design-row {
  display: grid;
  grid-template-columns: 1fr auto 1fr;
  gap: 1rem;
  align-items: center;
}

.design-pane {
  aspect-ratio: 4 / 3.2;
  border: 1px solid var(--line);
  border-radius: 10px;
  padding: 0.8rem;
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
}

.design-pane i { display: block; border-radius: 4px; }

.design-wire i { background: #232327; }
.dw-bar { width: 62%; height: 11px; }
.dw-line { width: 90%; height: 6px; }
.dw-line.short { width: 55%; }
.dw-img { flex: 1; border: 1px dashed #2e2e33; background: transparent !important; }
.dw-btn { width: 38%; height: 13px; border-radius: 999px !important; }

.design-final { background: linear-gradient(160deg, rgba(201, 169, 97, 0.07), transparent); }
.design-final i { background: rgba(201, 169, 97, 0.4); }
.df-bar { width: 62%; height: 11px; background: linear-gradient(90deg, var(--gold-2), var(--gold)) !important; }
.df-line { width: 90%; height: 6px; opacity: 0.5; }
.df-line.short { width: 55%; opacity: 0.5; }
.df-img { flex: 1; background: linear-gradient(140deg, rgba(201, 169, 97, 0.25), rgba(201, 169, 97, 0.06)) !important; }
.df-btn { width: 38%; height: 13px; border-radius: 999px !important; background: linear-gradient(90deg, var(--gold-2), var(--gold)) !important; }

.design-arrow { color: var(--gold); font-size: 1.3rem; }

.design-chips {
  display: flex;
  align-items: center;
  gap: 0.55rem;
  margin-top: 1.1rem;
}

.chip { width: 18px; height: 18px; border-radius: 50%; border: 1px solid var(--line-strong); }
.chip-gold { background: linear-gradient(120deg, var(--gold-2), var(--gold)); }
.chip-dark { background: #0b0b0c; }
.chip-cream { background: #edeae3; }

.chip-aa {
  font-family: var(--font-serif);
  font-style: italic;
  color: var(--gold-2);
  font-size: 1.05rem;
  margin-left: 0.2rem;
}

.design-note {
  margin-left: auto;
  font-family: var(--font-mono);
  font-size: 0.7rem;
  color: var(--muted);
  letter-spacing: 0.06em;
}

/* 2 — code */
.code-lines {
  background: #131316;
  border: 1px solid var(--line);
  border-radius: 10px;
  padding: 1rem 1.1rem;
}

.code-lines i {
  display: block;
  height: 9px;
  border-radius: 4px;
  background: #26262b;
  margin: 9px 0;
}

.code-lines .cl-gold { background: rgba(201, 169, 97, 0.5); }

.code-preview {
  position: relative;
  margin-top: 1rem;
  border: 1px solid var(--line);
  border-radius: 10px;
  overflow: hidden;
}

.code-preview img { width: 100%; height: auto; }

.cp-label {
  position: absolute;
  top: 0.6rem;
  right: 0.6rem;
  font-family: var(--font-mono);
  font-size: 0.66rem;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--gold-2);
  background: rgba(11, 11, 12, 0.85);
  border: 1px solid rgba(201, 169, 97, 0.4);
  border-radius: 999px;
  padding: 0.25rem 0.65rem;
}

/* 3 — launch */
.launch-bar {
  display: flex;
  align-items: center;
  gap: 0.4rem;
  font-family: var(--font-mono);
  font-size: 0.9rem;
  background: #131316;
  border: 1px solid var(--line);
  border-radius: 999px;
  padding: 0.65rem 1.2rem;
}

.lb-https { color: var(--muted); }

.lb-ok {
  margin-left: auto;
  font-size: 0.72rem;
  color: #7dc98a;
  letter-spacing: 0.08em;
}

.launch-spark {
  display: block;
  width: 100%;
  height: 84px;
  margin: 1.4rem 0 1.1rem;
}

.launch-tags { display: flex; flex-wrap: wrap; gap: 0.5rem; }

.launch-tags span {
  font-family: var(--font-mono);
  font-size: 0.72rem;
  letter-spacing: 0.05em;
  color: var(--muted);
  border: 1px solid var(--line);
  border-radius: 999px;
  padding: 0.3rem 0.75rem;
}

/* rail */
.story-rail { padding-bottom: 0.4rem; }

html:not(.js) .story-rail { display: none; }

.rail-stops {
  position: relative;
  display: flex;
  justify-content: space-between;
}

.rail-line {
  position: absolute;
  left: 0;
  right: 0;
  top: calc(0.4rem + 6px);
  height: 1px;
  background: var(--line-strong);
}

.rail-fill {
  position: absolute;
  left: 0;
  top: -0.5px;
  height: 2px;
  width: 0%;
  background: linear-gradient(90deg, var(--gold-2), var(--gold));
}

.rail-stop {
  position: relative;
  background: none;
  border: 0;
  cursor: pointer;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.7rem;
  padding: 0.4rem 0.4rem 0.2rem;
  font-family: var(--font-display);
  font-weight: 500;
  font-size: 0.85rem;
  color: var(--muted);
  transition: color 0.3s ease;
}

.rail-stop i {
  width: 12px;
  height: 12px;
  background: var(--bg);
  border: 1px solid var(--line-strong);
  transform: rotate(45deg);
  transition: background 0.3s ease, border-color 0.3s ease, box-shadow 0.3s ease, transform 0.3s ease;
}

.rail-stop:hover { color: var(--text); }

.rail-stop.is-passed i {
  background: rgba(201, 169, 97, 0.35);
  border-color: rgba(201, 169, 97, 0.6);
}

.rail-stop.is-active { color: var(--text); }

.rail-stop.is-active i {
  background: linear-gradient(120deg, var(--gold-2), var(--gold));
  border-color: var(--gold);
  box-shadow: 0 0 16px rgba(201, 169, 97, 0.55);
  transform: rotate(45deg) scale(1.3);
}

/* ---------- pricing ---------- */

.pricing {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1.4rem;
  align-items: stretch;
}

.price-card {
  border: 1px solid var(--line);
  border-radius: 20px;
  padding: 2.4rem 2rem;
  display: flex;
  flex-direction: column;
  background: linear-gradient(180deg, rgba(255, 255, 255, 0.015), transparent);
  transition: border-color 0.35s ease, transform 0.4s var(--ease-out);
  position: relative;
}

.price-card:hover { border-color: var(--line-strong); transform: translateY(-4px); }

.price-featured {
  border-color: rgba(201, 169, 97, 0.55);
  background: linear-gradient(180deg, rgba(201, 169, 97, 0.06), transparent 45%);
}

.price-featured:hover { border-color: var(--gold); }

.price-badge {
  position: absolute;
  top: -0.8rem;
  left: 50%;
  transform: translateX(-50%);
  font-family: var(--font-mono);
  font-size: 0.68rem;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: #171204;
  background: linear-gradient(120deg, var(--gold-2), var(--gold));
  padding: 0.3rem 0.9rem;
  border-radius: 999px;
  white-space: nowrap;
}

.price-card h3 {
  font-family: var(--font-display);
  font-weight: 600;
  font-size: 1.25rem;
  margin-bottom: 0.9rem;
}

.price {
  font-family: var(--font-display);
  font-weight: 700;
  font-size: 2rem;
  letter-spacing: -0.02em;
  margin-bottom: 1.6rem;
}

.price-od {
  font-family: var(--font-mono);
  font-weight: 400;
  font-size: 0.85rem;
  color: var(--muted);
  margin-right: 0.3rem;
}

.price-card ul {
  list-style: none;
  margin-bottom: 2rem;
  flex-grow: 1;
}

.price-card li {
  font-size: 0.95rem;
  color: var(--muted);
  padding: 0.5rem 0 0.5rem 1.5rem;
  position: relative;
}

.price-card li + li { border-top: 1px solid var(--line); }

.price-card li::before {
  content: "→";
  position: absolute;
  left: 0;
  color: var(--gold);
}

.price-card .btn { justify-content: center; }

.pricing-note {
  text-align: center;
  color: var(--muted);
  font-size: 0.98rem;
  margin-top: 2.4rem;
}

.pricing-note a {
  color: var(--gold-2);
  border-bottom: 1px solid rgba(201, 169, 97, 0.45);
  transition: color 0.25s ease, border-color 0.25s ease;
}

.pricing-note a:hover { color: var(--gold); border-bottom-color: var(--gold); }

/* ---------- faq ---------- */

.faq-wrap { max-width: 46rem; }

.faq {
  border-top: 1px solid var(--line-strong);
  margin-top: clamp(2rem, 4vw, 3rem);
}

.faq details {
  border-bottom: 1px solid var(--line);
}

.faq summary {
  font-family: var(--font-display);
  font-weight: 600;
  font-size: 1.08rem;
  padding: 1.15rem 0.2rem;
  cursor: pointer;
  list-style: none;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  transition: color 0.25s ease;
}

.faq summary::-webkit-details-marker { display: none; }

.faq summary:hover { color: var(--gold-2); }

.faq-icon {
  font-family: var(--font-mono);
  font-weight: 400;
  font-size: 1.1rem;
  color: var(--gold);
  transition: transform 0.3s var(--ease-out);
  flex-shrink: 0;
}

.faq details[open] .faq-icon { transform: rotate(45deg); }

.faq details p {
  color: var(--muted);
  font-size: 0.98rem;
  padding: 0 2.4rem 1.3rem 0.2rem;
  max-width: 40rem;
}

/* ---------- about ---------- */

.about {
  display: grid;
  grid-template-columns: auto 1fr;
  gap: clamp(2.5rem, 6vw, 5.5rem);
  align-items: center;
}

.about-logo {
  width: clamp(6.5rem, 15vw, 11rem);
  height: auto;
  user-select: none;
  opacity: 0.95;
  filter: drop-shadow(0 8px 30px rgba(0, 0, 0, 0.35));
}

.about-text p:not(.kicker) { color: var(--muted); max-width: 38rem; }

/* ---------- contact ---------- */

.contact { text-align: center; }

.contact .section-sub { margin-inline: auto; }

.contact-title {
  font-family: var(--font-display);
  font-weight: 600;
  font-size: clamp(2.4rem, 6.5vw, 5rem);
  line-height: 1.06;
  letter-spacing: -0.025em;
  margin-bottom: 1.4rem;
  text-wrap: balance;
  max-width: 20ch;
  margin-inline: auto;
}

.contact-actions {
  display: flex;
  gap: 1.1rem;
  justify-content: center;
  flex-wrap: wrap;
  margin-bottom: 2rem;
}

.contact-note {
  font-family: var(--font-mono);
  font-size: 0.82rem;
  color: var(--muted);
  letter-spacing: 0.06em;
}

/* ---------- footer ---------- */

.footer {
  border-top: 1px solid var(--line);
  padding-block: 2rem;
  position: relative;
  z-index: 1;
}

.footer-inner {
  display: flex;
  justify-content: space-between;
  gap: 1rem;
  flex-wrap: wrap;
}

.footer p {
  font-family: var(--font-mono);
  font-size: 0.78rem;
  color: var(--muted);
}

/* ---------- entrance animations ---------- */

/* hero: pure CSS entrance, runs with or without JS */
.rise {
  opacity: 0.01;
  animation: rise-in 0.85s var(--ease-out) forwards;
  animation-delay: var(--r, 0s);
}

@keyframes rise-in {
  from { opacity: 0.01; transform: translateY(26px); }
  to { opacity: 1; transform: none; }
}

.r1 { --r: 0.05s; }
.r2 { --r: 0.12s; }
.r3 { --r: 0.2s; }
.r4 { --r: 0.3s; }
.r5 { --r: 0.4s; }
.r6 { --r: 0.5s; }

.hero-visual { opacity: 0; animation: visual-in 1.2s var(--ease-out) 0.35s forwards, hero-float 9s ease-in-out 1.55s infinite alternate; }

@keyframes visual-in {
  from { opacity: 0; transform: translateY(calc(-50% + 30px)) rotate(3.5deg); }
  to { opacity: 1; transform: translateY(-50%) rotate(3.5deg); }
}

/* below-fold: JS-gated scroll reveals (no-JS users see everything) */
html.js .reveal {
  opacity: 0;
  transform: translateY(26px);
  transition: opacity 0.9s var(--ease-out), transform 0.9s var(--ease-out);
  transition-delay: var(--d, 0s);
}

html.js .reveal.in { opacity: 1; transform: none; }

.d1 { --d: 0.08s; }
.d2 { --d: 0.16s; }
.d3 { --d: 0.24s; }

/* ---------- responsive ---------- */

@media (max-width: 1280px) {
  .hero-visual { width: clamp(400px, 37vw, 540px); }
}

/* below 1100px: the stage moves into the flow, under the hero text */
@media (max-width: 1100px) {
  .hero-canvas { display: none; }
  .hero { flex-direction: column; justify-content: center; }
  .hero-content { order: 1; }
  .hero-visual {
    order: 2;
    position: relative;
    right: auto;
    top: auto;
    width: min(100% - 3rem, 460px);
    margin: 3.2rem auto 0;
    animation: visual-in-m 1s var(--ease-out) 0.3s forwards;
    opacity: 0;
    transform: none;
  }
  .hero-shot-phone { left: -0.4rem; bottom: -1.4rem; border-radius: 14px; }
}

@keyframes visual-in-m {
  from { opacity: 0; transform: translateY(24px); }
  to { opacity: 1; transform: none; }
}

@media (max-width: 1024px) {
  .services { grid-template-columns: repeat(2, 1fr); }
  .project { grid-template-columns: 1fr; gap: 2.5rem; }
  .project-flip .project-media { order: 0; }
  .project-flip .project-info { order: 0; }
  .phone-frame { right: 0.5rem; bottom: -1.5rem; }
}

@media (max-width: 820px) {
  .nav-inner { gap: 1rem; }
  .nav-links { display: none; }
  .nav-cta { margin-left: auto; }
  .nav-cta .cta-long { display: none; }
  .nav-cta .cta-short { display: inline; }
  .burger { display: flex; }
  .pricing { grid-template-columns: 1fr; max-width: 30rem; margin-inline: auto; }
  /* natural order on mobile: Landing → Firemní → Aplikace (danek's call) */
  .phone-frame { border-radius: 14px; } /* 22px looks too round at phone-frame's mobile size */
  .why { grid-template-columns: 1fr; }
  .about { grid-template-columns: 1fr; text-align: left; }
  .about-logo { display: none; }
  .glow { filter: blur(70px); }
  .grain { animation: none; }
}

@media (max-width: 820px) {
  .story-sticky { padding: 5.4rem 0 1rem; gap: 0.8rem; }
  .story-head .kicker { margin-bottom: 0.6rem; }
  .story-head .section-title { font-size: clamp(1.4rem, 5.5vw, 1.9rem); }
  html.js .story-stage {
    grid-template-columns: 1fr;
    grid-template-rows: auto minmax(0, 1fr);
    gap: 1rem;
    align-items: start;
    overflow: hidden;
  }
  html:not(.js) .story-stage { grid-template-columns: 1fr; }
  html.js .story-visuals { order: -1; min-height: 0; height: min(30svh, 300px); }
  html.js .story-panels { min-height: 0; height: 100%; }
  html.js .story-panel { justify-content: flex-start; }
  .story-card { padding: 0.9rem; width: min(100%, 420px); max-height: 100%; overflow: hidden; }
  .story-num { font-size: 1.8rem; margin-bottom: 0.5rem; }
  .story-panel h3 { font-size: 1.25rem; }
  .story-panel p { font-size: 0.92rem; }
  .chat-bubble { font-size: 0.82rem; padding: 0.55rem 0.8rem; }
  .cb-out { margin-top: 0.6rem; }
  .chat-meta { margin-top: 0.6rem; font-size: 0.66rem; }
  .design-chips { margin-top: 0.7rem; }
  /* Vývoj card on phones: drop the fake editor bars, show the site preview
     uncropped — cropping read as a broken image */
  .sc-code .code-lines { display: none; }
  .code-preview { margin-top: 0; }
  .code-preview img { max-height: none; }
  .launch-spark { height: 44px; margin: 0.8rem 0 0.7rem; }
  .launch-tags span { font-size: 0.64rem; padding: 0.22rem 0.55rem; }
  .rail-stop { font-size: 0.72rem; gap: 0.5rem; }
}

/* short viewports (landscape phones, small desktop windows): the sticky stage
   can't fit — fall back to the plain stacked layout, same as no-JS */
@media (max-height: 640px) {
  html.js .story-track { height: auto; }
  html.js .story-sticky {
    position: static;
    height: auto;
    overflow: visible;
    justify-content: flex-start;
  }
  html.js .story-stage { display: block; overflow: visible; }
  html.js .story-panels,
  html.js .story-visuals { position: static; height: auto; min-height: 0; order: 0; }
  html.js .story-panel {
    position: static;
    opacity: 1;
    transform: none;
    pointer-events: auto;
    margin-top: 2.5rem;
  }
  html.js .story-visual {
    position: static;
    opacity: 1;
    transform: none;
    margin-top: 1.2rem;
    place-items: start;
  }
  html.js .story-card { max-height: none; }
  .story-rail { display: none; }
}

@media (max-width: 560px) {
  body { font-size: 1rem; }
  .section { padding-block: 4.5rem; }
  .services { grid-template-columns: 1fr; }
  .hero { padding-top: 7rem; }
  .hero-cta .btn { width: 100%; justify-content: center; }
  .contact-actions .btn { width: 100%; justify-content: center; }
  .phone-frame { bottom: -1rem; width: 24%; }
}

@media (max-width: 360px) {
  .btn-big { font-size: 0.92rem; padding-inline: 1.3rem; }
  .hero-title { font-size: 2.25rem; } /* longest rotating word must fit one line */
}

/* ---------- print ---------- */

@media print {
  html.js .reveal { opacity: 1 !important; transform: none !important; }
  html.js .story-track { height: auto !important; }
  html.js .story-sticky { position: static !important; height: auto !important; overflow: visible !important; }
  html.js .story-stage { display: block !important; }
  html.js .story-panels, html.js .story-visuals { position: static !important; height: auto !important; }
  html.js .story-panel, html.js .story-visual { position: static !important; opacity: 1 !important; transform: none !important; }
  .grain, .glow, .hero-canvas, .hero-visual, .marquee, .nav, .mobile-menu, .story-rail, .sky-bg, .theme-toggle, .chat-root { display: none !important; }
  body { background: #fff; color: #000; }
  .hero-title, .section-title, .contact-title, h3, .hero-sub, .project-desc, .why-item p, .step p, .story-panel p, .price-card li, .faq details p { color: #000 !important; }
  .serif {
    background: none;
    -webkit-text-fill-color: currentColor;
    color: #000;
  }
}

/* ============================================================
   SKY / LIQUID GLASS THEME (in-dev — toggled via [data-theme])
   ============================================================ */

/* sky video background */
.sky-bg {
  position: fixed;
  inset: 0;
  z-index: 0;
  display: none;
  /* static gradient shows before video loads / for reduced-motion */
  background: linear-gradient(180deg, #7aa3c8 0%, #a8c4dc 55%, #cbdae8 100%);
}

[data-theme="sky"] .sky-bg { display: block; }

.sky-v {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  opacity: 0;
  transition: opacity 1.3s ease; /* cross-fade between clips */
}

.sky-v.sky-on { opacity: 1; }

.sky-scrim {
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg, rgba(10, 30, 52, 0.46), rgba(10, 30, 52, 0.30) 42%, rgba(10, 30, 52, 0.48));
}

/* dev theme switcher pill */
.theme-toggle {
  position: fixed;
  bottom: 1.1rem;
  right: 1.1rem;
  z-index: 300;
  font-family: var(--font-mono);
  font-size: 0.74rem;
  letter-spacing: 0.06em;
  color: var(--text);
  background: rgba(20, 20, 24, 0.62);
  border: 1px solid var(--line-strong);
  border-radius: 999px;
  padding: 0.5rem 0.95rem;
  cursor: pointer;
  -webkit-backdrop-filter: blur(12px);
  backdrop-filter: blur(12px);
  transition: border-color 0.25s ease, background 0.25s ease;
}

.theme-toggle:hover { border-color: var(--gold); }

/* --- token swap --- */
[data-theme="sky"] {
  --text: #ffffff;
  --muted: rgba(255, 255, 255, 0.92);
  --line: rgba(255, 255, 255, 0.28);
  --line-strong: rgba(255, 255, 255, 0.46);
  --panel: rgba(255, 255, 255, 0.14);
  --glass: rgba(255, 255, 255, 0.13);
  /* azure accent system — replaces gold in the sky theme */
  --sky-hi: #bfe0ff;
  --sky-mid: #6ab5f5;
  --sky-deep: #2e7cd0;
}

[data-theme="sky"] ::selection { background: var(--sky-mid); color: #06263f; }

[data-theme="sky"] body {
  background: #7aa3c8;
  color: var(--text);
}

/* atmosphere: no glows/shader, lighter grain */
[data-theme="sky"] .glow { display: none; }
[data-theme="sky"] .hero-canvas { display: none !important; }
[data-theme="sky"] .hero::before { content: none !important; }
[data-theme="sky"] .grain { opacity: 0.035; }

/* readable type over bright sky — tight dark shadow + wide soft halo */
[data-theme="sky"] .hero-title,
[data-theme="sky"] .section-title,
[data-theme="sky"] .contact-title,
[data-theme="sky"] .story-panel h3,
[data-theme="sky"] .project-info h3 {
  text-shadow: 0 1px 3px rgba(6, 22, 40, 0.5), 0 4px 30px rgba(6, 22, 40, 0.6);
}

[data-theme="sky"] .hero-sub,
[data-theme="sky"] .section-sub,
[data-theme="sky"] .kicker,
[data-theme="sky"] .project-kicker,
[data-theme="sky"] .project-desc,
[data-theme="sky"] .project-proof,
[data-theme="sky"] .why-item p,
[data-theme="sky"] .why-item h3,
[data-theme="sky"] .story-panel p,
[data-theme="sky"] .projects-outro,
[data-theme="sky"] .about-text p,
[data-theme="sky"] .hero-price,
[data-theme="sky"] .contact-note,
[data-theme="sky"] .pricing-note {
  text-shadow: 0 1px 2px rgba(6, 22, 40, 0.45), 0 2px 16px rgba(6, 22, 40, 0.5);
}

/* --- azure replaces gold across the sky theme --- */
[data-theme="sky"] .gold { color: var(--sky-hi); }
[data-theme="sky"] .kicker,
[data-theme="sky"] .project-kicker,
[data-theme="sky"] .service-num { color: var(--sky-hi); }

/* over photography, color-in-type loses — the serif goes white and the
   italic contrast + azure period carry the accent */
[data-theme="sky"] .serif {
  background: none;
  color: #ffffff;
  -webkit-text-fill-color: #ffffff;
}

/* sky hero headline is static ("Web, podle vašich představ.") so the glass
   sheet never resizes; the rotator only runs in the dark theme */
.ht-sky, .ht-sky-serif { display: none; }
[data-theme="sky"] .ht-dark { display: none; }
[data-theme="sky"] .rot-word { display: none; }
[data-theme="sky"] .ht-sky { display: inline; }
[data-theme="sky"] .ht-sky-serif { display: inline-block; }

/* the static phrase is long — scale it so the glass sheet shares the fold
   with the device stage instead of swallowing it */
[data-theme="sky"] .hero-title { font-size: clamp(2.3rem, 6vw, 4.9rem); }

/* sky: anchor the stage next to the glass card (fixed gutter), not to the
   viewport edge — on wide monitors it stays near the middle, no dead gap */
@media (min-width: 1101px) {
  [data-theme="sky"] .hero-visual {
    width: clamp(420px, 36vw, 600px);
    right: auto;
    left: calc((100% - min(1200px, 100% - 3rem)) / 2 + 42rem);
  }
}

@media (min-width: 1281px) {
  [data-theme="sky"] .hero-visual {
    left: calc((100% - min(1200px, 100% - 3rem)) / 2 + 45rem);
  }
}

/* ghost numerals: solid white fill reads on every shade of blue */
[data-theme="sky"] .project-num,
[data-theme="sky"] .story-num {
  color: #ffffff;
  -webkit-text-fill-color: #ffffff;
  -webkit-text-stroke: 0;
  opacity: 0.95;
  text-shadow: 0 2px 14px rgba(6, 22, 40, 0.4);
}

[data-theme="sky"] .about-logo {
  opacity: 1;
  filter: drop-shadow(0 8px 26px rgba(6, 22, 40, 0.4));
}

[data-theme="sky"] .btn-primary {
  background: linear-gradient(120deg, var(--sky-mid), var(--sky-deep));
  color: #ffffff;
  box-shadow: 0 6px 24px rgba(46, 124, 208, 0.42);
}

[data-theme="sky"] .btn-primary:hover { box-shadow: 0 10px 32px rgba(46, 124, 208, 0.55); }

[data-theme="sky"] .nav-links a::after { background: var(--sky-hi); }
[data-theme="sky"] .theme-toggle:hover { border-color: var(--sky-hi); }

[data-theme="sky"] .project-link { color: var(--sky-hi); }
[data-theme="sky"] .project-link::after { background: var(--sky-mid); }

[data-theme="sky"] .service::before { background: linear-gradient(90deg, #ffffff, var(--sky-mid)); }
[data-theme="sky"] .why-item:hover { border-left-color: var(--sky-hi); }

[data-theme="sky"] .rail-fill { background: linear-gradient(90deg, #ffffff, var(--sky-mid)); }
[data-theme="sky"] .rail-stop.is-active i {
  background: linear-gradient(120deg, #ffffff, var(--sky-mid));
  border-color: var(--sky-hi);
  box-shadow: 0 0 16px rgba(169, 214, 255, 0.7);
}
[data-theme="sky"] .rail-stop.is-passed i {
  background: rgba(169, 214, 255, 0.4);
  border-color: rgba(190, 220, 255, 0.7);
}

[data-theme="sky"] .price-badge {
  background: linear-gradient(120deg, var(--sky-mid), var(--sky-deep));
  color: #ffffff;
}
[data-theme="sky"] .price-featured { border-color: rgba(169, 214, 255, 0.9); }
[data-theme="sky"] .price-featured:hover { border-color: var(--sky-hi); }
[data-theme="sky"] .price-card li::before { color: var(--sky-hi); }

[data-theme="sky"] .faq-icon { color: var(--sky-hi); }
[data-theme="sky"] .faq summary:hover { color: var(--sky-hi); }
[data-theme="sky"] .pricing-note a {
  color: var(--sky-hi);
  border-bottom-color: rgba(169, 214, 255, 0.6);
}
[data-theme="sky"] .pricing-note a:hover { color: #ffffff; border-bottom-color: #ffffff; }

[data-theme="sky"] .cb-out {
  background: linear-gradient(120deg, var(--sky-mid), var(--sky-deep));
  color: #ffffff;
}
[data-theme="sky"] .code-lines .cl-gold { background: rgba(120, 180, 240, 0.8); }
[data-theme="sky"] .cp-label { color: var(--sky-hi); border-color: rgba(169, 214, 255, 0.5); }
[data-theme="sky"] .design-arrow { color: var(--sky-hi); }
[data-theme="sky"] .design-final i { background: rgba(120, 180, 240, 0.55); }
[data-theme="sky"] .df-bar,
[data-theme="sky"] .df-btn { background: linear-gradient(90deg, #ffffff, var(--sky-mid)) !important; }
[data-theme="sky"] .chip-gold { background: linear-gradient(120deg, var(--sky-mid), var(--sky-deep)); }
[data-theme="sky"] .chip-aa { color: var(--sky-hi); }
[data-theme="sky"] .launch-spark polyline { stroke: url(#sparkb); }

[data-theme="sky"] .story-panel em { color: var(--sky-hi); }
[data-theme="sky"] .btn-ghost:hover { color: #ffffff; }
[data-theme="sky"] .nav-links a:hover,
[data-theme="sky"] .nav-links a.active { color: #ffffff; }
[data-theme="sky"] .marquee-track i { color: var(--sky-hi); }
[data-theme="sky"] .tags li { color: rgba(255, 255, 255, 0.9); }

/* nav + mobile menu → glass */
[data-theme="sky"] .nav.scrolled {
  background: rgba(255, 255, 255, 0.14);
  border-bottom-color: rgba(255, 255, 255, 0.28);
}

[data-theme="sky"] .mobile-menu {
  background: rgba(52, 82, 110, 0.55);
}

/* glass panels */
[data-theme="sky"] .service,
[data-theme="sky"] .price-card,
[data-theme="sky"] .story-card,
[data-theme="sky"] .faq details {
  background: var(--glass);
  -webkit-backdrop-filter: blur(22px) saturate(1.4);
  backdrop-filter: blur(22px) saturate(1.4);
}

[data-theme="sky"] .services {
  background: rgba(255, 255, 255, 0.24);
  border-color: rgba(255, 255, 255, 0.34);
}

[data-theme="sky"] .service:hover { background: rgba(255, 255, 255, 0.22); }

[data-theme="sky"] .price-card {
  border-color: rgba(255, 255, 255, 0.38);
  box-shadow: 0 18px 50px rgba(15, 40, 65, 0.25);
}

[data-theme="sky"] .price-featured {
  background: linear-gradient(180deg, rgba(255, 255, 255, 0.24), rgba(255, 255, 255, 0.10) 45%);
  border-color: rgba(228, 197, 124, 0.85);
}

[data-theme="sky"] .faq details { border: 1px solid rgba(255, 255, 255, 0.3); border-radius: 12px; margin-bottom: 0.6rem; padding-inline: 1rem; }
[data-theme="sky"] .faq { border-top: 0; }

/* device frames → glass rims, softer daylight shadows */
[data-theme="sky"] .browser-frame,
[data-theme="sky"] .hero-shot {
  background: rgba(255, 255, 255, 0.12);
  border-color: rgba(255, 255, 255, 0.5);
  box-shadow: 0 30px 70px rgba(15, 40, 65, 0.35);
}

[data-theme="sky"] .phone-frame,
[data-theme="sky"] .hero-shot-phone {
  background: rgba(255, 255, 255, 0.12);
  border-color: rgba(255, 255, 255, 0.5);
  box-shadow: 0 22px 50px rgba(15, 40, 65, 0.4);
}

[data-theme="sky"] .browser-bar {
  background: rgba(255, 255, 255, 0.16);
  border-bottom-color: rgba(255, 255, 255, 0.25);
}

[data-theme="sky"] .browser-bar i { background: rgba(255, 255, 255, 0.55); }

/* skeleton shimmer in daylight */
[data-theme="sky"] .browser-frame img:not(.ldd),
[data-theme="sky"] .phone-frame img:not(.ldd) {
  background: linear-gradient(110deg, rgba(255, 255, 255, 0.12) 30%, rgba(255, 255, 255, 0.24) 45%, rgba(255, 255, 255, 0.12) 60%);
  background-size: 220% 100%;
}

/* ghost numerals + about mark → white strokes */
[data-theme="sky"] .project-num,
[data-theme="sky"] .story-num {
  -webkit-text-stroke: 1px rgba(255, 255, 255, 0.75);
}


/* story mocks in daylight */
[data-theme="sky"] .cb-in {
  background: rgba(255, 255, 255, 0.22);
  border-color: rgba(255, 255, 255, 0.32);
}

[data-theme="sky"] .code-lines,
[data-theme="sky"] .launch-bar {
  background: rgba(14, 34, 56, 0.35);
  border-color: rgba(255, 255, 255, 0.28);
}

[data-theme="sky"] .code-lines i { background: rgba(255, 255, 255, 0.28); }
[data-theme="sky"] .code-lines .cl-gold { background: rgba(228, 197, 124, 0.75); }

[data-theme="sky"] .cp-label { background: rgba(14, 34, 56, 0.7); }

[data-theme="sky"] .design-pane { border-color: rgba(255, 255, 255, 0.32); }
[data-theme="sky"] .design-wire i { background: rgba(255, 255, 255, 0.38); }
[data-theme="sky"] .dw-img { border-color: rgba(255, 255, 255, 0.45); }
[data-theme="sky"] .design-final { background: linear-gradient(160deg, rgba(255, 255, 255, 0.14), transparent); }

/* rail + section striping */
[data-theme="sky"] .rail-stop i { background: rgba(255, 255, 255, 0.25); }
[data-theme="sky"] .section-alt { background: none; }
[data-theme="sky"] .service { background: var(--glass); } /* .service uses solid --bg in dark */

/* buttons */
[data-theme="sky"] .btn-ghost {
  border-color: rgba(255, 255, 255, 0.55);
}

[data-theme="sky"] .btn-ghost:hover {
  border-color: #fff;
  color: #fff;
  background: rgba(255, 255, 255, 0.14);
}

[data-theme="sky"] .theme-toggle {
  background: rgba(255, 255, 255, 0.2);
  border-color: rgba(255, 255, 255, 0.45);
}

/* --- LIQUID_GLASS_MODE (js/sky.js bool): bright sky, glass behind all text --- */

/* much brighter sky — the glass sheets carry readability instead of the scrim */
[data-theme="sky"][data-glass="on"] .sky-scrim {
  background: linear-gradient(180deg, rgba(10, 30, 52, 0.18), rgba(10, 30, 52, 0.08) 42%, rgba(10, 30, 52, 0.20));
}

/* glass sheet recipe */
[data-theme="sky"][data-glass="on"] .hero-glass,
[data-theme="sky"][data-glass="on"] .project-info,
[data-theme="sky"][data-glass="on"] .why-item,
[data-theme="sky"][data-glass="on"] .projects-outro,
[data-theme="sky"][data-glass="on"] .kicker,
[data-theme="sky"][data-glass="on"] .section-title,
[data-theme="sky"][data-glass="on"] .section-sub,
[data-theme="sky"][data-glass="on"] .contact-title,
[data-theme="sky"][data-glass="on"] .contact-note,
[data-theme="sky"][data-glass="on"] .pricing-note,
[data-theme="sky"][data-glass="on"] .about-text > p:not(.kicker),
[data-theme="sky"][data-glass="on"] .story-panel h3,
[data-theme="sky"][data-glass="on"] .story-panel > p,
[data-theme="sky"][data-glass="on"] .hero-price {
  background: rgba(255, 255, 255, 0.16);
  /* brightness() darkens what's behind the glass so white text pops */
  -webkit-backdrop-filter: blur(18px) saturate(1.5) brightness(0.86);
  backdrop-filter: blur(18px) saturate(1.5) brightness(0.86);
  border: 1px solid rgba(255, 255, 255, 0.32);
  box-shadow: 0 10px 36px rgba(15, 40, 65, 0.18);
}

/* the hero cluster becomes one big sheet — its children stay bare */
[data-theme="sky"][data-glass="on"] .hero-glass {
  width: fit-content;
  max-width: 100%;
  padding: clamp(1.5rem, 3vw, 2.4rem);
  border-radius: 24px;
}

[data-theme="sky"][data-glass="on"] .hero-glass .kicker,
[data-theme="sky"][data-glass="on"] .hero-glass .hero-price {
  background: none;
  border: 0;
  box-shadow: none;
  -webkit-backdrop-filter: none;
  backdrop-filter: none;
  padding: 0;
}

/* header + paragraph chips */
[data-theme="sky"][data-glass="on"] .kicker {
  width: fit-content;
  padding: 0.4rem 0.85rem;
  border-radius: 10px;
}

[data-theme="sky"][data-glass="on"] .section-title {
  width: fit-content;
  padding: 0.55rem 1.1rem;
  border-radius: 16px;
}

[data-theme="sky"][data-glass="on"] .section-sub {
  width: fit-content;
  max-width: 34rem;
  padding: 0.7rem 1.1rem;
  border-radius: 14px;
}

[data-theme="sky"][data-glass="on"] .contact-title {
  width: fit-content;
  padding: 0.7rem 1.4rem;
  border-radius: 20px;
}

[data-theme="sky"][data-glass="on"] .contact-note,
[data-theme="sky"][data-glass="on"] .pricing-note {
  width: fit-content;
  margin-inline: auto;
  padding: 0.55rem 1rem;
  border-radius: 999px;
}

[data-theme="sky"][data-glass="on"] .project-info {
  padding: clamp(1.4rem, 2.5vw, 2rem);
  border-radius: 20px;
}

[data-theme="sky"][data-glass="on"] .why-item {
  padding: 1.3rem 1.6rem;
  border-radius: 16px;
}

[data-theme="sky"][data-glass="on"] .projects-outro {
  padding: 1.2rem 1.5rem;
  border-radius: 16px;
  border-top: 1px solid rgba(255, 255, 255, 0.32);
}

[data-theme="sky"][data-glass="on"] .about-text > p:not(.kicker) {
  padding: 1.2rem 1.5rem;
  border-radius: 16px;
}

[data-theme="sky"][data-glass="on"] .story-panel h3 {
  width: fit-content;
  padding: 0.4rem 0.9rem;
  border-radius: 12px;
}

[data-theme="sky"][data-glass="on"] .story-panel > p {
  padding: 0.9rem 1.1rem;
  border-radius: 14px;
}

[data-theme="sky"][data-glass="on"] .story-panel > .story-num {
  width: fit-content;
  padding: 0.5rem 0.9rem;
  border-radius: 12px;
}

/* marquee + footer become glass strips */
[data-theme="sky"][data-glass="on"] .marquee,
[data-theme="sky"][data-glass="on"] .footer {
  background: rgba(255, 255, 255, 0.12);
  -webkit-backdrop-filter: blur(14px) saturate(1.4);
  backdrop-filter: blur(14px) saturate(1.4);
}

/* glass carries contrast now — shadows soften to a whisper */
[data-theme="sky"][data-glass="on"] .hero-title,
[data-theme="sky"][data-glass="on"] .section-title,
[data-theme="sky"][data-glass="on"] .contact-title,
[data-theme="sky"][data-glass="on"] .story-panel h3,
[data-theme="sky"][data-glass="on"] .project-info h3,
[data-theme="sky"][data-glass="on"] .hero-sub,
[data-theme="sky"][data-glass="on"] .section-sub,
[data-theme="sky"][data-glass="on"] .kicker,
[data-theme="sky"][data-glass="on"] .project-kicker,
[data-theme="sky"][data-glass="on"] .project-desc,
[data-theme="sky"][data-glass="on"] .project-proof,
[data-theme="sky"][data-glass="on"] .why-item p,
[data-theme="sky"][data-glass="on"] .why-item h3,
[data-theme="sky"][data-glass="on"] .story-panel p,
[data-theme="sky"][data-glass="on"] .projects-outro,
[data-theme="sky"][data-glass="on"] .about-text p,
[data-theme="sky"][data-glass="on"] .hero-price,
[data-theme="sky"][data-glass="on"] .contact-note,
[data-theme="sky"][data-glass="on"] .pricing-note {
  text-shadow: 0 1px 3px rgba(6, 22, 40, 0.45), 0 2px 18px rgba(6, 22, 40, 0.4);
}

/* ============================================================
   CHAT CONCIERGE (scripted dialog tree)
   ============================================================ */

.chat-root {
  position: fixed;
  right: 1.1rem;
  bottom: 4.4rem; /* stacked above the theme toggle */
  z-index: 320;
  display: flex;
  flex-direction: column;
  align-items: flex-end;
  gap: 0.8rem;
}

/* the display rules below would defeat the `hidden` attribute — never let them */
.chat-root [hidden] { display: none !important; }

/* launcher */
.chat-launcher {
  position: relative;
  width: 54px;
  height: 54px;
  border-radius: 50%;
  border: 0;
  cursor: pointer;
  display: grid;
  place-items: center;
  background: linear-gradient(120deg, var(--gold-2), var(--gold));
  color: #171204;
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.4), 0 0 24px rgba(201, 169, 97, 0.25);
  transition: transform 0.3s var(--ease-out), box-shadow 0.3s ease;
}

.chat-launcher:hover { transform: translateY(-2px); }

.chat-launcher.is-open svg { transform: scale(0.9); }

.chat-badge {
  position: absolute;
  top: 2px;
  right: 2px;
  width: 12px;
  height: 12px;
  border-radius: 50%;
  background: #e05656;
  border: 2px solid var(--bg);
}

/* notification nudge */
.chat-nudge {
  display: flex;
  align-items: flex-start;
  gap: 0.7rem;
  width: min(17rem, calc(100vw - 2.5rem));
  padding: 0.85rem 2.1rem 0.9rem 0.9rem;
  border-radius: 16px;
  background: var(--panel);
  border: 1px solid var(--line-strong);
  box-shadow: 0 18px 50px rgba(0, 0, 0, 0.45);
  cursor: pointer;
  position: relative;
  opacity: 0;
  transform: translateY(14px);
  transition: opacity 0.5s var(--ease-out), transform 0.5s var(--ease-out);
}

.chat-nudge.in { opacity: 1; transform: none; }

.chat-nudge-avatar,
.chat-avatar {
  flex-shrink: 0;
  width: 34px;
  height: 34px;
  border-radius: 50%;
  display: grid;
  place-items: center;
  background: linear-gradient(120deg, var(--gold-2), var(--gold));
}

.chat-nudge-body strong,
.chat-head-txt strong {
  font-family: var(--font-display);
  font-size: 0.9rem;
  display: block;
}

.chat-nudge-body p {
  font-size: 0.88rem;
  color: var(--muted);
  margin-top: 0.1rem;
}

.chat-nudge-close,
.chat-close {
  position: absolute;
  top: 0.4rem;
  right: 0.55rem;
  background: none;
  border: 0;
  color: var(--muted);
  font-size: 1.15rem;
  line-height: 1;
  cursor: pointer;
  padding: 0.2rem;
}

.chat-nudge-close:hover,
.chat-close:hover { color: var(--text); }

/* panel */
.chat-panel {
  width: min(21.5rem, calc(100vw - 2.2rem));
  max-height: min(30rem, calc(100vh - 10rem));
  display: flex;
  flex-direction: column;
  border-radius: 18px;
  overflow: hidden;
  background: var(--panel);
  border: 1px solid var(--line-strong);
  box-shadow: 0 24px 70px rgba(0, 0, 0, 0.5);
}

.chat-head {
  position: relative;
  display: flex;
  align-items: center;
  gap: 0.7rem;
  padding: 0.85rem 1rem;
  border-bottom: 1px solid var(--line);
  background: rgba(255, 255, 255, 0.02);
}

.chat-head-txt span {
  font-family: var(--font-mono);
  font-size: 0.66rem;
  letter-spacing: 0.05em;
  color: var(--muted);
}

.chat-close { position: static; margin-left: auto; font-size: 1.35rem; }

.chat-msgs {
  flex: 1;
  overflow-y: auto;
  padding: 1rem;
  display: flex;
  flex-direction: column;
  gap: 0.55rem;
  min-height: 8rem;
}

.chat-m {
  max-width: 85%;
  padding: 0.6rem 0.85rem;
  font-size: 0.9rem;
  line-height: 1.5;
  border-radius: 13px;
}

.chat-m-bot {
  background: #1d1d21;
  border: 1px solid var(--line);
  border-bottom-left-radius: 4px;
  align-self: flex-start;
}

.chat-m-me {
  background: linear-gradient(120deg, var(--gold-2), var(--gold));
  color: #171204;
  border-bottom-right-radius: 4px;
  align-self: flex-end;
}

.chat-typing { display: flex; gap: 4px; padding: 0.75rem 0.9rem; }

.chat-typing i {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--muted);
  animation: chat-dot 1s ease-in-out infinite;
}

.chat-typing i:nth-child(2) { animation-delay: 0.15s; }
.chat-typing i:nth-child(3) { animation-delay: 0.3s; }

@keyframes chat-dot {
  0%, 60%, 100% { transform: translateY(0); opacity: 0.5; }
  30% { transform: translateY(-4px); opacity: 1; }
}

.chat-opts {
  display: flex;
  flex-wrap: wrap;
  gap: 0.45rem;
  padding: 0 1rem 1rem;
}

.chat-opt {
  font-family: var(--font-display);
  font-weight: 500;
  font-size: 0.84rem;
  color: var(--text);
  background: none;
  border: 1px solid var(--line-strong);
  border-radius: 999px;
  padding: 0.45rem 0.9rem;
  cursor: pointer;
  transition: border-color 0.25s ease, color 0.25s ease, background 0.25s ease;
}

.chat-opt:hover {
  border-color: var(--gold);
  color: var(--gold-2);
}

/* --- sky theme: liquid glass chat --- */
[data-theme="sky"] .chat-launcher {
  background: linear-gradient(120deg, var(--sky-mid), var(--sky-deep));
  color: #ffffff;
  box-shadow: 0 10px 30px rgba(15, 40, 65, 0.35), 0 0 24px rgba(106, 181, 245, 0.35);
}

[data-theme="sky"] .chat-badge { border-color: #ffffff; }

[data-theme="sky"] .chat-nudge,
[data-theme="sky"] .chat-panel {
  background: rgba(255, 255, 255, 0.16);
  -webkit-backdrop-filter: blur(20px) saturate(1.5) brightness(0.86);
  backdrop-filter: blur(20px) saturate(1.5) brightness(0.86);
  border-color: rgba(255, 255, 255, 0.4);
  box-shadow: 0 18px 50px rgba(15, 40, 65, 0.3);
}

[data-theme="sky"] .chat-head { background: rgba(255, 255, 255, 0.08); }

[data-theme="sky"] .chat-nudge-avatar,
[data-theme="sky"] .chat-avatar {
  background: linear-gradient(120deg, var(--sky-mid), var(--sky-deep));
}

[data-theme="sky"] .chat-m-bot {
  background: rgba(255, 255, 255, 0.18);
  border-color: rgba(255, 255, 255, 0.3);
}

[data-theme="sky"] .chat-m-me {
  background: linear-gradient(120deg, var(--sky-mid), var(--sky-deep));
  color: #ffffff;
}

[data-theme="sky"] .chat-opt:hover {
  border-color: #ffffff;
  color: #ffffff;
  background: rgba(255, 255, 255, 0.14);
}

/* ---------- reduced motion ---------- */

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .grain, .glow-a, .glow-b, .marquee-track { animation: none; }
  .rise, .hero-visual { opacity: 1; animation: none; }
  .rise { transform: none; }
  html.js .reveal {
    opacity: 1;
    transform: none;
    transition: none;
  }
  *, *::before, *::after {
    transition-duration: 0.01ms !important;
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
  }
}
