/* ============================================================
   DUWIQ - marketing site
   Brand: ruby #7d0e18 on warm white #f7f5f2. Helvetica-grotesque
   type to match the wordmark. Light theme with a dark-mode token
   override. One accent (ruby), one radius scale (14px / pill CTAs).
   ============================================================ */

:root {
  /* brand */
  --ruby:        #7d0e18;
  --ruby-hover:  #5f0a12;
  --chip:        #241c1d;
  --tint:        #c2858b;

  /* semantic tokens (light) */
  --bg:          #f7f5f2;
  --bg-elev:     #ffffff;
  --bg-sunken:   #f1ede8;
  --ink:         #1a1a1a;
  --ink-soft:    #544f49;
  --ink-faint:   #6f665d;
  --line:        #e7e2dc;
  --line-strong: #d8d0c6;

  --accent:      var(--ruby);
  --accent-ink:  #ffffff;

  --radius:      14px;
  --radius-sm:   10px;
  --shell:       1200px;
  --ease:        cubic-bezier(.16, 1, .3, 1);

  --shadow-sm:   0 1px 2px rgba(60, 30, 20, .05), 0 4px 14px rgba(90, 20, 25, .05);
  --shadow-md:   0 4px 10px rgba(60, 30, 20, .06), 0 20px 50px rgba(90, 20, 25, .10);

  --font-sans: "Helvetica Neue", Helvetica, Inter, Arial, "Segoe UI", system-ui, sans-serif;
  --font-mono: ui-monospace, "SF Mono", SFMono-Regular, Menlo, monospace;
}

@media (prefers-color-scheme: dark) {
  :root {
    --bg:          #141110;
    --bg-elev:     #1d1917;
    --bg-sunken:   #100d0c;
    --ink:         #f4efe9;
    --ink-soft:    #c3bab1;
    --ink-faint:   #948a80;
    --line:        #2e2825;
    --line-strong: #3a332f;
    --accent:      #d98a92;      /* lifted ruby keeps AA on dark */
    --accent-ink:  #1a1a1a;
    --shadow-sm:   0 1px 2px rgba(0,0,0,.4);
    --shadow-md:   0 10px 40px rgba(0,0,0,.5);
  }
}

/* ---------- reset-ish ---------- */
*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; }
@media (prefers-reduced-motion: reduce) { html { scroll-behavior: auto; } }

body {
  margin: 0;
  font-family: var(--font-sans);
  color: var(--ink);
  background: var(--bg);
  line-height: 1.55;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
  overflow-x: hidden;
}

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

.shell { width: 100%; max-width: var(--shell); margin: 0 auto; padding-inline: 24px; }

/* ---------- skip link & focus ---------- */
.skip-link {
  position: fixed; top: 10px; left: 10px; z-index: 200;
  background: var(--ruby); color: #fff; padding: 10px 16px;
  border-radius: var(--radius-sm); transform: translateY(-160%);
  transition: transform .2s var(--ease); text-decoration: none; font-weight: 600;
}
.skip-link:focus { transform: translateY(0); }

:where(a, button, [tabindex]):focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 3px;
  border-radius: 6px;
}

/* ---------- type ---------- */
h1, h2, h3 { margin: 0; font-weight: 700; letter-spacing: -0.02em; line-height: 1.05; }
h1 { font-size: clamp(2.4rem, 5.2vw, 4.1rem); }
h2 { font-size: clamp(1.7rem, 3.4vw, 2.6rem); line-height: 1.08; }
h3 { font-size: 1.18rem; letter-spacing: -0.01em; }
p  { margin: 0; }

.eyebrow {
  font-size: .72rem; font-weight: 700; text-transform: uppercase;
  letter-spacing: .18em; color: var(--accent); margin: 0 0 18px;
}

/* ---------- buttons ---------- */
.btn {
  --pad-y: .72em; --pad-x: 1.3em;
  display: inline-flex; align-items: center; justify-content: center; gap: .5em;
  padding: var(--pad-y) var(--pad-x);
  font: inherit; font-weight: 600; line-height: 1; white-space: nowrap;
  border-radius: 999px; border: 1.5px solid transparent;
  text-decoration: none; cursor: pointer;
  transition: transform .18s var(--ease), background .18s var(--ease),
              border-color .18s var(--ease), color .18s var(--ease);
}
.btn--lg { --pad-y: .95em; --pad-x: 1.7em; font-size: 1.02rem; }
.btn--solid { background: var(--ruby); color: #fff; }
.btn--solid:hover { background: var(--ruby-hover); transform: translateY(-2px); }
.btn--solid:active { transform: translateY(0) scale(.98); }
.btn--ghost { background: transparent; color: var(--ink); border-color: var(--line-strong); }
.btn--ghost:hover { border-color: var(--accent); color: var(--accent); transform: translateY(-2px); }
.btn--ghost:active { transform: translateY(0) scale(.98); }
@media (prefers-color-scheme: dark) {
  .btn--solid { background: var(--ruby); color: #fff; }
  .btn--solid:hover { background: #94131f; }
}

/* ============================================================
   NAV
   ============================================================ */
.nav {
  position: sticky; top: 0; z-index: 100;
  background: color-mix(in srgb, var(--bg) 82%, transparent);
  backdrop-filter: saturate(160%) blur(14px);
  -webkit-backdrop-filter: saturate(160%) blur(14px);
  border-bottom: 1px solid transparent;
  transition: border-color .3s var(--ease), background .3s var(--ease);
}
.nav.is-stuck { border-color: var(--line); background: color-mix(in srgb, var(--bg) 92%, transparent); }
.nav__inner { display: flex; align-items: center; gap: 24px; height: 72px; }
.nav__brand { display: inline-flex; margin-right: auto; }
.nav__brand img { height: 30px; width: auto; }
@media (prefers-color-scheme: dark) { .nav__brand img { filter: brightness(0) invert(1); } }

.nav__links { display: flex; gap: 30px; }
.nav__links a {
  font-size: .95rem; font-weight: 500; color: var(--ink-soft);
  text-decoration: none; position: relative; padding: 4px 0;
  transition: color .18s var(--ease);
}
.nav__links a::after {
  content: ""; position: absolute; left: 0; bottom: -2px; width: 100%; height: 1.5px;
  background: var(--accent); transform: scaleX(0); transform-origin: left;
  transition: transform .24s var(--ease);
}
.nav__links a:hover { color: var(--ink); }
.nav__links a:hover::after { transform: scaleX(1); }
.nav__cta { padding: .6em 1.15em; font-size: .92rem; }

.nav__menu { display: none; }
.nav__mobile { display: none; }

/* ============================================================
   HERO
   ============================================================ */
.hero { padding: clamp(48px, 8vw, 88px) 0 clamp(56px, 9vw, 104px); }
.hero__grid {
  display: grid; grid-template-columns: 1.05fr .95fr;
  gap: clamp(32px, 5vw, 72px); align-items: center;
}
.hero__copy { max-width: 36rem; }
.hero h1 { margin-bottom: 22px; }
.hero__lead {
  font-size: clamp(1.05rem, 1.6vw, 1.22rem); color: var(--ink-soft);
  max-width: 34rem; margin-bottom: 32px;
}
.hero__actions { display: flex; flex-wrap: wrap; gap: 14px; margin-bottom: 44px; }

.hero__facts {
  display: grid; grid-template-columns: repeat(3, auto); gap: 30px;
  margin: 0; padding-top: 26px; border-top: 1px solid var(--line);
}
.hero__facts dt { font-size: .78rem; color: var(--ink-faint); margin-bottom: 6px; }
.hero__facts dd { margin: 0; font-size: 1.02rem; font-weight: 700; letter-spacing: -.01em; }

/* hero visual: duotone brand panel */
.hero__panel {
  position: relative; border-radius: 20px; overflow: hidden;
  aspect-ratio: 4 / 5; box-shadow: var(--shadow-md);
  border: 1px solid var(--line);
}
.hero__photo { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }
.hero__wash {
  position: absolute; inset: 0;
  background:
    linear-gradient(150deg, rgba(125,14,24,.88), rgba(86,9,15,.94) 60%, rgba(36,28,29,.96)),
    radial-gradient(120% 80% at 25% 8%, rgba(194,133,139,.5), transparent 55%);
  mix-blend-mode: multiply;
}
.hero__panel::after {   /* keep the ruby saturated even over a bright photo */
  content: ""; position: absolute; inset: 0;
  background: linear-gradient(150deg, rgba(125,14,24,.55), rgba(36,28,29,.35));
}
.hero__mark {
  position: absolute; top: 30px; left: 30px; width: clamp(64px, 12vw, 104px);
  height: auto; z-index: 2; opacity: .96;
}
.hero__chip {
  position: absolute; left: 22px; right: 22px; bottom: 22px; z-index: 2;
  display: flex; align-items: center; gap: 10px;
  padding: 13px 16px; border-radius: 12px;
  background: rgba(255,255,255,.12); border: 1px solid rgba(255,255,255,.22);
  backdrop-filter: blur(8px); -webkit-backdrop-filter: blur(8px);
  color: #fff; font-size: .86rem; font-weight: 500; letter-spacing: .01em;
}
.hero__chip .dot { width: 8px; height: 8px; border-radius: 50%; background: #6ee39a; flex: none; box-shadow: 0 0 0 4px rgba(110,227,154,.25); }
@media (prefers-reduced-transparency: reduce) {
  .hero__chip { background: rgba(36,28,29,.85); backdrop-filter: none; }
}

/* ============================================================
   SECTION scaffolding
   ============================================================ */
.section { padding: clamp(64px, 9vw, 116px) 0; }
.section__head { max-width: 44rem; margin-bottom: clamp(38px, 5vw, 60px); }
.section__head h2 { margin-bottom: 16px; }
.section__sub { font-size: 1.08rem; color: var(--ink-soft); max-width: 40rem; }

/* ============================================================
   PRODUCTS
   ============================================================ */
.products { background: var(--bg-sunken); border-block: 1px solid var(--line); }
.prod__grid { display: grid; grid-template-columns: repeat(2, 1fr); gap: 24px; }

.prod {
  display: flex; flex-direction: column;
  background: var(--bg-elev); border: 1px solid var(--line);
  border-radius: var(--radius); padding: clamp(26px, 3vw, 40px);
  box-shadow: var(--shadow-sm);
  transition: transform .25s var(--ease), box-shadow .25s var(--ease), border-color .25s var(--ease);
}
.prod:hover { transform: translateY(-4px); box-shadow: var(--shadow-md); border-color: var(--line-strong); }
.prod--live { border-top: 3px solid var(--ruby); }
.prod__top { display: flex; align-items: center; justify-content: space-between; margin-bottom: 22px; }
.prod__icon {
  display: grid; place-items: center; width: 52px; height: 52px; border-radius: 13px;
  background: color-mix(in srgb, var(--ruby) 10%, var(--bg-elev)); color: var(--ruby);
}
@media (prefers-color-scheme: dark) { .prod__icon { color: var(--accent); background: color-mix(in srgb, var(--accent) 16%, transparent); } }
.prod__icon svg { width: 26px; height: 26px; }
.prod h3 { margin-bottom: 12px; font-size: 1.5rem; }
.prod__desc { color: var(--ink-soft); margin-bottom: 22px; }

.tag {
  display: inline-flex; align-items: center; gap: 7px;
  font-size: .74rem; font-weight: 700; letter-spacing: .03em;
  padding: 6px 12px; border-radius: 999px;
}
.tag--live { background: color-mix(in srgb, #1f7a3d 14%, transparent); color: #1f7a3d; }
.tag--live .dot { width: 7px; height: 7px; border-radius: 50%; background: #1f9d4c; }
.tag--soon { background: color-mix(in srgb, var(--ink-faint) 18%, transparent); color: var(--ink-soft); }
@media (prefers-color-scheme: dark) { .tag--live { color: #6ee39a; } }

.prod__list { list-style: none; margin: 0 0 28px; padding: 0; display: grid; gap: 12px; }
.prod__list li { position: relative; padding-left: 26px; color: var(--ink-soft); font-size: .96rem; }
.prod__list li::before {
  content: ""; position: absolute; left: 0; top: .5em; width: 12px; height: 7px;
  border-left: 2px solid var(--accent); border-bottom: 2px solid var(--accent);
  transform: rotate(-45deg);
}
.prod__link {
  display: inline-flex; align-items: center; gap: 8px; margin-top: auto;
  font-weight: 600; color: var(--accent); text-decoration: none; font-size: 1.02rem;
}
.prod__link svg { width: 20px; height: 20px; transition: transform .2s var(--ease); }
.prod__link:hover svg { transform: translateX(4px); }
.prod__url { margin-top: 8px; font-family: var(--font-mono); font-size: .8rem; color: var(--ink-faint); }

/* ============================================================
   CAPABILITIES / BENTO
   ============================================================ */
.bento {
  display: grid; grid-template-columns: repeat(3, 1fr);
  gap: 18px; grid-auto-rows: 1fr;
}
.bento__cell {
  background: var(--bg-elev); border: 1px solid var(--line);
  border-radius: var(--radius); padding: clamp(24px, 2.4vw, 34px);
  display: flex; flex-direction: column;
}
.bento__cell--wide { grid-column: span 2; }
.bento__cell--ruby {
  background: linear-gradient(155deg, var(--ruby), var(--ruby-hover) 70%, var(--chip));
  color: #fff; border-color: var(--chip);
}
.bento__cell--ruby p { color: rgba(255,255,255,.9); }
.bento__cell--tint {
  background: linear-gradient(155deg, color-mix(in srgb, var(--tint) 24%, var(--bg-elev)), var(--bg-elev));
}
.bento__icon {
  display: grid; place-items: center; width: 46px; height: 46px; border-radius: 12px;
  background: color-mix(in srgb, var(--ruby) 9%, transparent); color: var(--ruby);
  margin-bottom: 18px;
}
.bento__cell--ruby .bento__icon { background: rgba(255,255,255,.16); color: #fff; }
.bento__cell--tint .bento__icon { background: rgba(125,14,24,.12); color: var(--ruby); }
@media (prefers-color-scheme: dark) {
  .bento__icon { color: var(--accent); background: color-mix(in srgb, var(--accent) 15%, transparent); }
  .bento__cell--tint { background: linear-gradient(155deg, color-mix(in srgb, var(--tint) 12%, var(--bg-elev)), var(--bg-elev)); }
}
.bento__icon svg { width: 24px; height: 24px; }
.bento__cell h3 { margin-bottom: 10px; }
.bento__cell p { color: var(--ink-soft); font-size: .98rem; }

/* ============================================================
   FIRM STATEMENT
   ============================================================ */
.firm { background: linear-gradient(160deg, var(--ruby), var(--ruby-hover) 65%, var(--chip)); color: #fff; }
.firm__grid {
  display: grid; grid-template-columns: 1.3fr .7fr; gap: clamp(36px, 6vw, 80px);
  align-items: center; padding-block: clamp(64px, 9vw, 112px);
}
.firm__copy { max-width: 40rem; }
.firm__copy h2 { margin-bottom: 24px; }
.firm__copy p { color: rgba(255,255,255,.85); font-size: 1.08rem; margin-bottom: 16px; }
.firm__stats { list-style: none; margin: 0; padding: 0; display: grid; gap: 22px; }
.firm__stats li {
  padding: 20px 24px; border-radius: var(--radius);
  background: rgba(255,255,255,.08); border: 1px solid rgba(255,255,255,.16);
}
.firm__num { display: block; font-size: 2.3rem; font-weight: 700; letter-spacing: -.03em; line-height: 1; }
.firm__num sup { font-size: .5em; vertical-align: super; }
.firm__lbl { display: block; margin-top: 8px; color: rgba(255,255,255,.8); font-size: .92rem; }

/* ============================================================
   ACCESS / CTA
   ============================================================ */
.access { background: var(--bg-sunken); border-top: 1px solid var(--line); }
.access__card {
  max-width: 46rem; margin-inline: auto; text-align: center;
  background: var(--bg-elev); border: 1px solid var(--line);
  border-radius: 20px; padding: clamp(38px, 5vw, 64px);
  box-shadow: var(--shadow-md);
}
.access__card h2 { margin-bottom: 16px; }
.access__card > p { color: var(--ink-soft); font-size: 1.08rem; max-width: 38rem; margin: 0 auto 30px; }
.access__actions { display: flex; flex-wrap: wrap; gap: 14px; justify-content: center; }
.access__note { margin-top: 26px; font-size: .9rem; color: var(--ink-faint); }
.access__note a { color: var(--accent); text-decoration: none; font-weight: 600; }
.access__note a:hover { text-decoration: underline; }

/* ============================================================
   FOOTER
   ============================================================ */
.foot { background: var(--chip); color: #efe8e4; padding-top: clamp(56px, 7vw, 84px); }
.foot__grid {
  display: grid; grid-template-columns: 2fr 1fr 1fr 1fr; gap: 40px;
  padding-bottom: 48px;
}
.foot__brand img { height: 32px; width: auto; margin-bottom: 18px; }
.foot__brand p { color: rgba(239,232,228,.72); font-size: .92rem; }
.foot__col { display: flex; flex-direction: column; gap: 12px; }
.foot__col h2 { font-size: .78rem; text-transform: uppercase; letter-spacing: .14em; color: rgba(239,232,228,.5); font-weight: 700; margin-bottom: 4px; }
.foot__col a, .foot__col span { color: rgba(239,232,228,.82); text-decoration: none; font-size: .95rem; transition: color .18s var(--ease); }
.foot__col a:hover { color: #fff; }
.foot__base {
  display: flex; justify-content: space-between; gap: 16px; flex-wrap: wrap;
  padding: 22px 24px; border-top: 1px solid rgba(255,255,255,.1);
  font-size: .84rem; color: rgba(239,232,228,.66);
}

/* ============================================================
   REVEAL ANIMATION
   ============================================================ */
.js [data-reveal] { opacity: 0; transform: translateY(22px); transition: opacity .7s var(--ease), transform .7s var(--ease); }
.js [data-reveal].is-in { opacity: 1; transform: none; }
.js [data-reveal="off"] { opacity: 1; transform: none; }
@media (prefers-reduced-motion: reduce) {
  [data-reveal] { opacity: 1 !important; transform: none !important; transition: none; }
}

/* ============================================================
   RESPONSIVE
   ============================================================ */
@media (max-width: 940px) {
  .hero__grid { grid-template-columns: 1fr; }
  .hero__visual { max-width: 520px; width: 100%; }
  .hero__panel { aspect-ratio: 16 / 11; }
  .firm__grid { grid-template-columns: 1fr; }
  .bento { grid-template-columns: repeat(2, 1fr); }
  .bento__cell--wide { grid-column: span 2; }
  .foot__grid { grid-template-columns: 1fr 1fr; }
  .foot__brand { grid-column: 1 / -1; }
}

@media (max-width: 760px) {
  .nav__links, .nav__cta { display: none; }
  .nav__menu {
    display: inline-flex; flex-direction: column; justify-content: center; gap: 5px;
    width: 44px; height: 44px; padding: 0; border: 1px solid var(--line-strong);
    border-radius: 10px; background: transparent; cursor: pointer;
  }
  .nav__menu span { display: block; width: 20px; height: 2px; background: var(--ink); margin-inline: auto; transition: transform .25s var(--ease), opacity .2s var(--ease); }
  .nav__menu[aria-expanded="true"] span:first-child { transform: translateY(3.5px) rotate(45deg); }
  .nav__menu[aria-expanded="true"] span:last-child { transform: translateY(-3.5px) rotate(-45deg); }
  .nav__mobile {
    display: flex; flex-direction: column; gap: 4px; padding: 12px 24px 20px;
    border-top: 1px solid var(--line); background: var(--bg);
  }
  .nav__mobile a { padding: 12px 0; color: var(--ink); text-decoration: none; font-weight: 500; border-bottom: 1px solid var(--line); }
  .nav__mobile a.btn { border: none; margin-top: 10px; justify-content: center; color: #fff; }
  .nav__mobile[hidden] { display: none; }

  .prod__grid { grid-template-columns: 1fr; }
  .bento { grid-template-columns: 1fr; }
  .bento__cell--wide { grid-column: auto; }
  .hero__facts { grid-template-columns: 1fr 1fr; gap: 20px; }
}

@media (max-width: 460px) {
  .shell { padding-inline: 18px; }
  .foot__grid { grid-template-columns: 1fr; }
  .foot__base { flex-direction: column; gap: 6px; }
}
