/* ============================================================
   DUBI•AI — shared brand styles
   Tokens sourced from the DUBI-AI design system.
   ============================================================ */

:root {
  /* Surfaces */
  --black: #000000;
  --ink: #0a0a0a;
  --ink-2: #131313;
  --ink-3: #1c1c1c;
  --line: #2a2a2a;
  --line-2: #3a3a3a;

  /* Accents */
  --gold: #c9a96a;
  --gold-deep: #a88a4f;
  --red: #c8102e;
  --red-deep: #9a0c23;

  /* Text */
  --white: #ffffff;
  --soft: #c5c5c5;
  --mute: #8a8a8a;

  /* Type */
  --display: 'Saira', 'Eurostile', -apple-system, sans-serif;
  --body: 'Inter', -apple-system, BlinkMacSystemFont, sans-serif;
  --mono: 'JetBrains Mono', ui-monospace, monospace;

  /* Motion */
  --ease: cubic-bezier(0.22, 1, 0.36, 1);
}

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

html {
  -webkit-text-size-adjust: 100%;
  scroll-behavior: smooth;
}

body {
  background: var(--ink);
  color: var(--soft);
  font-family: var(--body);
  font-weight: 400;
  line-height: 1.65;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  text-rendering: optimizeLegibility;
  min-height: 100vh;
  overflow-x: hidden;
}

a {
  color: var(--gold);
  text-decoration: none;
  transition: color 0.25s var(--ease);
}
a:hover { color: var(--white); }

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

/* Faint film-grain overlay for atmosphere */
.grain {
  position: fixed;
  inset: 0;
  z-index: 1;
  pointer-events: none;
  opacity: 0.04;
  mix-blend-mode: overlay;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='160' height='160'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.8' numOctaves='2' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)'/%3E%3C/svg%3E");
}

/* Brand dot pair — red + gold, echoing the logo */
.dot-pair {
  display: inline-flex;
  align-items: center;
  gap: 7px;
}
.dot-pair i {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  display: block;
}
.dot-pair i.r { background: var(--red); box-shadow: 0 0 10px rgba(200, 16, 46, 0.6); }
.dot-pair i.g { background: var(--gold); box-shadow: 0 0 10px rgba(201, 169, 106, 0.55); }

/* ============================================================
   COMING SOON  (body.page-home)
   ============================================================ */

.page-home {
  display: grid;
  place-items: center;
  text-align: center;
  /* luminous: subtly lit centre over near-black */
  background:
    radial-gradient(120% 90% at 50% 38%, rgba(201, 169, 106, 0.10), transparent 60%),
    radial-gradient(140% 120% at 50% 120%, rgba(200, 16, 46, 0.06), transparent 55%),
    var(--ink);
}

#particles {
  position: fixed;
  inset: 0;
  z-index: 0;
  pointer-events: none;
}

.stage {
  position: relative;
  z-index: 2;
  padding: 40px 24px;
  width: 100%;
  max-width: 720px;
}

.pill {
  display: inline-flex;
  align-items: center;
  gap: 9px;
  font-family: var(--mono);
  font-size: 11px;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  color: var(--mute);
  border: 1px solid var(--line);
  border-radius: 999px;
  padding: 7px 16px;
  background: rgba(255, 255, 255, 0.015);
  backdrop-filter: blur(2px);
  opacity: 0;
  animation: rise 0.9s var(--ease) 0.1s forwards;
}
.pill .live {
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: var(--gold);
  box-shadow: 0 0 0 0 rgba(201, 169, 106, 0.5);
  animation: ping 2.4s ease-out infinite;
}

.logo-wrap {
  position: relative;
  display: inline-block;
  margin: 38px 0 30px;
  opacity: 0;
  animation: rise 1.1s var(--ease) 0.25s forwards;
}
/* pulsing gold glow behind the mark */
.logo-wrap::before {
  content: "";
  position: absolute;
  inset: -40% -20%;
  z-index: -1;
  background: radial-gradient(closest-side, rgba(201, 169, 106, 0.28), transparent 72%);
  filter: blur(14px);
  animation: breathe 5.5s ease-in-out infinite;
}
.logo-wrap img {
  width: min(420px, 78vw);
  height: auto;
  display: block;
  filter: drop-shadow(0 8px 40px rgba(0, 0, 0, 0.6));
}

.headline {
  font-family: var(--display);
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.42em;
  font-size: clamp(1.5rem, 5.5vw, 2.9rem);
  color: var(--white);
  padding-left: 0.42em; /* offset trailing letter-spacing for optical centre */
  text-shadow: 0 0 34px rgba(255, 255, 255, 0.12);
  opacity: 0;
  animation: rise 1s var(--ease) 0.5s forwards;
}

.underline {
  width: 0;
  height: 2px;
  margin: 22px auto 0;
  border-radius: 2px;
  background: linear-gradient(
    90deg,
    transparent,
    var(--gold-deep),
    var(--gold),
    var(--white),
    var(--gold),
    var(--gold-deep),
    transparent
  );
  background-size: 220% 100%;
  animation:
    grow 1.1s var(--ease) 0.7s forwards,
    sheen 4.5s linear 1.8s infinite;
}

.tagline {
  margin: 30px auto 0;
  max-width: 460px;
  font-size: clamp(0.92rem, 2.4vw, 1.06rem);
  color: var(--soft);
  line-height: 1.7;
  opacity: 0;
  animation: rise 1s var(--ease) 0.9s forwards;
}

.divider {
  margin: 34px auto 0;
  opacity: 0;
  animation: rise 1s var(--ease) 1.05s forwards;
}

.home-footer {
  margin-top: 40px;
  display: flex;
  flex-direction: column;
  gap: 12px;
  align-items: center;
  font-family: var(--mono);
  font-size: 11.5px;
  letter-spacing: 0.08em;
  color: var(--mute);
  opacity: 0;
  animation: rise 1s var(--ease) 1.2s forwards;
}
.home-footer nav {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  align-items: center;
  gap: 10px 14px;
  text-transform: uppercase;
  letter-spacing: 0.16em;
}
.home-footer nav span { color: var(--line-2); }
.home-footer a { color: var(--soft); }
.home-footer a:hover { color: var(--gold); }
.home-footer .copy { color: var(--mute); opacity: 0.8; }

/* ============================================================
   LEGAL PAGES  (body.page-legal)
   ============================================================ */

.page-legal {
  background:
    radial-gradient(120% 60% at 50% -10%, rgba(201, 169, 106, 0.07), transparent 55%),
    var(--ink);
}

.legal-header {
  position: sticky;
  top: 0;
  z-index: 10;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 18px clamp(20px, 5vw, 56px);
  background: rgba(10, 10, 10, 0.72);
  backdrop-filter: blur(12px);
  border-bottom: 1px solid var(--line);
}
.legal-header .brand img {
  height: 30px;
  width: auto;
  display: block;
  transition: opacity 0.25s var(--ease);
}
.legal-header .brand:hover img { opacity: 0.8; }
.legal-header .tag {
  font-family: var(--mono);
  font-size: 11px;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  color: var(--mute);
}

.legal-main {
  max-width: 760px;
  margin: 0 auto;
  padding: clamp(48px, 8vw, 96px) clamp(20px, 5vw, 32px) 80px;
  position: relative;
  z-index: 2;
}

.legal-main .eyebrow {
  font-family: var(--mono);
  font-size: 12px;
  letter-spacing: 0.28em;
  text-transform: uppercase;
  color: var(--gold);
  display: block;
  margin-bottom: 16px;
}
.legal-main h1 {
  font-family: var(--display);
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  font-size: clamp(2rem, 6vw, 3.1rem);
  color: var(--white);
  line-height: 1.05;
}
.legal-main .updated {
  margin-top: 14px;
  font-family: var(--mono);
  font-size: 12.5px;
  color: var(--mute);
  letter-spacing: 0.04em;
}
.legal-main .intro {
  margin-top: 28px;
  font-size: 1.05rem;
  color: var(--soft);
}

.legal-main h2 {
  font-family: var(--display);
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  font-size: 1.18rem;
  color: var(--gold);
  margin: 48px 0 14px;
  padding-top: 28px;
  border-top: 1px solid var(--line);
  display: flex;
  align-items: baseline;
  gap: 14px;
}
.legal-main h2 .num {
  font-family: var(--mono);
  font-size: 12px;
  color: var(--gold-deep);
  letter-spacing: 0;
}
.legal-main h3 {
  font-family: var(--body);
  font-weight: 600;
  color: var(--white);
  font-size: 1rem;
  margin: 26px 0 8px;
}
.legal-main p { margin: 0 0 16px; color: var(--soft); }
.legal-main ul { margin: 0 0 16px; padding-left: 22px; }
.legal-main li { margin-bottom: 8px; color: var(--soft); }
.legal-main li::marker { color: var(--gold-deep); }
.legal-main strong { color: var(--white); font-weight: 600; }

.legal-main .contact-card {
  margin-top: 22px;
  padding: 22px 24px;
  border: 1px solid var(--line);
  border-radius: 12px;
  background: linear-gradient(180deg, rgba(255, 255, 255, 0.02), transparent);
}
.legal-main .contact-card p { margin: 0; }

.site-footer {
  border-top: 1px solid var(--line);
  padding: 34px clamp(20px, 5vw, 56px);
  position: relative;
  z-index: 2;
  display: flex;
  flex-wrap: wrap;
  gap: 14px 24px;
  align-items: center;
  justify-content: space-between;
  font-family: var(--mono);
  font-size: 11.5px;
  letter-spacing: 0.08em;
  color: var(--mute);
}
.site-footer nav {
  display: flex;
  align-items: center;
  gap: 14px;
  text-transform: uppercase;
  letter-spacing: 0.16em;
}
.site-footer nav span { color: var(--line-2); }
.site-footer a { color: var(--soft); }
.site-footer a:hover { color: var(--gold); }

/* ============================================================
   Keyframes
   ============================================================ */

@keyframes rise {
  from { opacity: 0; transform: translateY(16px); }
  to   { opacity: 1; transform: translateY(0); }
}
@keyframes grow {
  to { width: min(260px, 60vw); }
}
@keyframes sheen {
  0%   { background-position: 120% 0; }
  100% { background-position: -120% 0; }
}
@keyframes breathe {
  0%, 100% { opacity: 0.55; transform: scale(0.96); }
  50%      { opacity: 1;    transform: scale(1.06); }
}
@keyframes ping {
  0%   { box-shadow: 0 0 0 0 rgba(201, 169, 106, 0.5); }
  70%  { box-shadow: 0 0 0 9px rgba(201, 169, 106, 0); }
  100% { box-shadow: 0 0 0 0 rgba(201, 169, 106, 0); }
}

/* ============================================================
   Small screens
   ============================================================ */

@media (max-width: 600px) {
  .headline {
    letter-spacing: 0.22em;
    padding-left: 0.22em;
    font-size: clamp(1.3rem, 8.5vw, 2rem);
  }
  .stage { padding: 32px 18px; }
  .logo-wrap { margin: 30px 0 26px; }
}

/* ============================================================
   Reduced motion — disable all motion, show final state
   ============================================================ */

@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    animation-duration: 0.001ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.001ms !important;
    scroll-behavior: auto !important;
  }
  .pill, .logo-wrap, .headline, .tagline, .divider, .home-footer { opacity: 1 !important; }
  .underline { width: min(260px, 60vw); }
  #particles { display: none; }
}
