/* ============================================================================
   The Rose Room — tokens, reset, typography
   ----------------------------------------------------------------------------
   Art direction: "Golden hour to last call."
   Warm grounds (never #fff, never #000), one hot accent per mode, light-weight
   display type at large sizes, uppercase mono micro-labels, real photography
   graded per mode. Mode is set on <html data-mode="...">.
   ========================================================================= */

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

* { margin: 0; }

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

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
}

img, svg, video { display: block; max-width: 100%; }
button, input, select, textarea { font: inherit; color: inherit; }
button { background: none; border: 0; cursor: pointer; }
a { color: inherit; text-decoration: none; }
ul, ol { list-style: none; padding: 0; }

/* The hidden attribute must beat component display rules (.form__ok, .menu__panel…). */
[hidden] { display: none !important; }

/* ---------------------------------------------------------------- structure */
:root {
  --maxw: 1440px;
  --gutter: clamp(20px, 4.5vw, 76px);
  --section-y: clamp(80px, 12vh, 180px);
  --nav-h: 68px;

  --radius: 2px;
  --radius-lg: 4px;

  /* Motion — anime.js reads these for its defaults. */
  --ease-out: cubic-bezier(0.16, 1, 0.3, 1);
  --ease-in-out: cubic-bezier(0.65, 0, 0.35, 1);
  --ease: cubic-bezier(0.22, 0.61, 0.36, 1);
  --dur-fast: 0.22s;
  --dur: 0.42s;
  --dur-slow: 0.8s;

  --font-body: "Inter Tight", "Inter", -apple-system, BlinkMacSystemFont, "Segoe UI", Helvetica, Arial, sans-serif;
  --font-mono: "JetBrains Mono", ui-monospace, "SF Mono", Menlo, monospace;

  /* Editorial scale — the top two steps are deliberately enormous. */
  --step--2: clamp(0.63rem, 0.61rem + 0.08vw, 0.68rem);
  --step--1: clamp(0.72rem, 0.7rem + 0.1vw, 0.79rem);
  --step-0: clamp(1rem, 0.97rem + 0.16vw, 1.1rem);
  --step-1: clamp(1.15rem, 1.08rem + 0.34vw, 1.38rem);
  --step-2: clamp(1.5rem, 1.3rem + 0.9vw, 2.2rem);
  --step-3: clamp(2rem, 1.55rem + 2vw, 3.4rem);
  --step-4: clamp(2.6rem, 1.5rem + 4.4vw, 5.6rem);
  --step-5: clamp(3.1rem, 1.1rem + 8.6vw, 10rem);

  --grain: 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='4' stitchTiles='stitch'/%3E%3CfeColorMatrix type='saturate' values='0'/%3E%3C/filter%3E%3Crect width='160' height='160' filter='url(%23n)' opacity='0.55'/%3E%3C/svg%3E");
}

/* ============================================================ MODE: WEDDINGS
   "Golden hour." Warm bone ground, burnt coral, wheat gold. Light serif. */
:root[data-mode="weddings"] {
  --bg: #f7f2e9;
  --bg-2: #f0e7d8;
  --bg-3: #e7dbc7;
  --surface: #fffdf8;
  --surface-2: #faf5ec;
  --ink: #2a1f18;
  --ink-2: #6f5c4e;
  --ink-3: #a08d7c;
  --line: rgba(42, 31, 24, 0.14);
  --line-2: rgba(42, 31, 24, 0.07);
  --accent: #d14e2a;
  --accent-2: #b8862f;
  --accent-ink: #fffdf8;
  --deep: #5c2e22;
  --shadow: 0 1px 2px rgba(42, 31, 24, 0.05), 0 14px 36px -14px rgba(42, 31, 24, 0.2);
  --shadow-lg: 0 2px 4px rgba(42, 31, 24, 0.06), 0 40px 80px -28px rgba(42, 31, 24, 0.3);

  --font-display: "Instrument Serif", "Cormorant Garamond", Didot, Georgia, serif;
  --display-weight: 400;
  --display-tracking: -0.02em;
  --display-leading: 0.94;
  --display-transform: none;
  --display-style: normal;

  --ease: cubic-bezier(0.25, 0.6, 0.3, 1);
  --dur: 0.5s;

  /* Photography grade — warm, luminous, slightly lifted. */
  --photo-filter: saturate(1.06) contrast(1.02) brightness(1.03);
  --photo-tint: #d14e2a;
  --photo-tint-op: 0.1;
  --photo-blend: soft-light;
  --photo-veil: linear-gradient(180deg, rgba(42, 31, 24, 0) 30%, rgba(42, 31, 24, 0.55) 100%);


  --sc-day: #ffe9c4;
  --sc-gold: #f6a94f;
  --sc-dusk: #d97a3c;
  --sc-night: #241a14;
  --sc-ceil: #7a563c;
  --sc-ceil2: #523724;
  --sc-beam: #3d2718;
  --sc-beam2: #573824;
  --sc-wall: #fbf6ec;
  --sc-wall2: #ded1bb;
  --sc-floor: #cfc6b8;
  --sc-floor2: #b0a492;
  --sc-steel: #6f6b66;
  --sc-bar: #8a6440;
  --sc-bar2: #b28c5e;
  --sc-glass: #cfe2e6;
  --sc-glow: #ffd9a0;
  --sc-bulb: #ffe8bd;
  --sc-star: #fff6e2;
  --sc-ink: #3a2a30;
  --sc-accent: #d14e2a;
  --sc-accent2: #b8862f;
  --sc-deep: #2a1a12;
}

/* =========================================================== MODE: CORPORATE
   "The offsite." Cool bone ground, electric blue, signal amber. Tight sans. */
:root[data-mode="corporate"] {
  --bg: #f1f2f0;
  --bg-2: #e6e8e5;
  --bg-3: #d8dbd8;
  --surface: #ffffff;
  --surface-2: #f7f8f7;
  --ink: #0d1620;
  --ink-2: #4e5a66;
  --ink-3: #8a949e;
  --line: rgba(13, 22, 32, 0.14);
  --line-2: rgba(13, 22, 32, 0.06);
  --accent: #1a5fd6;
  --accent-2: #e0a92e;
  --accent-ink: #ffffff;
  --deep: #0a1e33;
  --shadow: 0 1px 2px rgba(13, 22, 32, 0.06), 0 12px 28px -14px rgba(13, 22, 32, 0.22);
  --shadow-lg: 0 2px 4px rgba(13, 22, 32, 0.07), 0 34px 64px -30px rgba(13, 22, 32, 0.34);

  --font-display: "Archivo", "Inter Tight", -apple-system, "Helvetica Neue", sans-serif;
  --display-weight: 600;
  --display-tracking: -0.042em;
  --display-leading: 0.98;
  --display-transform: none;
  --display-style: normal;

  --ease: cubic-bezier(0.3, 0.7, 0.2, 1);
  --dur: 0.42s;

  /* Photography grade — crisp, cool, high clarity. */
  --photo-filter: saturate(0.94) contrast(1.08) brightness(1.01);
  --photo-tint: #1a5fd6;
  --photo-tint-op: 0.12;
  --photo-blend: soft-light;
  --photo-veil: linear-gradient(180deg, rgba(10, 30, 51, 0) 35%, rgba(10, 30, 51, 0.6) 100%);


  --sc-day: #eef4fb;
  --sc-gold: #f0d9a8;
  --sc-dusk: #c9a06a;
  --sc-night: #16202c;
  --sc-ceil: #5c4c40;
  --sc-ceil2: #3e332b;
  --sc-beam: #2e2620;
  --sc-beam2: #453b33;
  --sc-wall: #ffffff;
  --sc-wall2: #dde3e8;
  --sc-floor: #c8ccd0;
  --sc-floor2: #a6acb2;
  --sc-steel: #7d858e;
  --sc-bar: #8a6a48;
  --sc-bar2: #ab8c64;
  --sc-glass: #d8e6f2;
  --sc-glow: #f2dcb4;
  --sc-bulb: #fff2d6;
  --sc-star: #eef4fb;
  --sc-ink: #16283a;
  --sc-accent: #1a5fd6;
  --sc-accent2: #e0a92e;
  --sc-deep: #0a1622;
}

/* ============================================================= MODE: PRIVATE
   "After dark." Warm black, hot coral, amber. Soft serif, low light. */
:root[data-mode="private"] {
  --bg: #0f0b0a;
  --bg-2: #171110;
  --bg-3: #201715;
  --surface: #1a1311;
  --surface-2: #241a17;
  --ink: #f8f0e4;
  --ink-2: #b8a493;
  --ink-3: #8a7666;
  --line: rgba(248, 240, 228, 0.16);
  --line-2: rgba(248, 240, 228, 0.07);
  --accent: #ff5a36;
  --accent-2: #ffc247;
  --accent-ink: #140806;
  --deep: #070403;
  --shadow: 0 1px 2px rgba(0, 0, 0, 0.5), 0 16px 38px -14px rgba(0, 0, 0, 0.8);
  --shadow-lg: 0 2px 6px rgba(0, 0, 0, 0.6), 0 40px 80px -28px rgba(0, 0, 0, 0.95);

  --font-display: "Fraunces", "Instrument Serif", Georgia, serif;
  --display-weight: 400;
  --display-tracking: -0.028em;
  --display-leading: 0.96;
  --display-transform: none;
  --display-style: normal;

  --ease: cubic-bezier(0.34, 0.7, 0.24, 1);
  --dur: 0.52s;

  /* Photography grade — deep, saturated, glowing highlights. */
  --photo-filter: saturate(1.22) contrast(1.14) brightness(0.92);
  --photo-tint: #ff5a36;
  --photo-tint-op: 0.16;
  --photo-blend: overlay;
  --photo-veil: linear-gradient(180deg, rgba(7, 4, 3, 0.15) 0%, rgba(7, 4, 3, 0.82) 100%);


  --sc-day: #4e3c52;
  --sc-gold: #e08a3c;
  --sc-dusk: #a8452a;
  --sc-night: #0b0708;
  --sc-ceil: #2c1e1a;
  --sc-ceil2: #180f0d;
  --sc-beam: #120a08;
  --sc-beam2: #261814;
  --sc-wall: #f0e2d2;
  --sc-wall2: #a88c78;
  --sc-floor: #6a5a52;
  --sc-floor2: #463832;
  --sc-steel: #8a7a70;
  --sc-bar: #5a3a24;
  --sc-bar2: #7c5438;
  --sc-glass: #3a2a34;
  --sc-glow: #ffb066;
  --sc-bulb: #ffd9a0;
  --sc-star: #fff0d8;
  --sc-ink: #1a0f0c;
  --sc-accent: #ff5a36;
  --sc-accent2: #ffc247;
  --sc-deep: #050303;
}

/* ========================================================= MODE: PRODUCTIONS
   "The set." Near-black, cyan, tungsten. Heavy condensed caps. */
:root[data-mode="productions"] {
  --bg: #0a0b0d;
  --bg-2: #101317;
  --bg-3: #161a1f;
  --surface: #13171c;
  --surface-2: #191e24;
  --ink: #eef2f6;
  --ink-2: #8b98a6;
  --ink-3: #5f6b78;
  --line: rgba(238, 242, 246, 0.15);
  --line-2: rgba(238, 242, 246, 0.06);
  --accent: #3ddad7;
  --accent-2: #ffb020;
  --accent-ink: #04100f;
  --deep: #050607;
  --shadow: 0 1px 2px rgba(0, 0, 0, 0.6), 0 16px 38px -16px rgba(0, 0, 0, 0.9);
  --shadow-lg: 0 2px 6px rgba(0, 0, 0, 0.7), 0 40px 80px -30px rgba(0, 0, 0, 1);

  --font-display: "Archivo", "Inter Tight", -apple-system, "Helvetica Neue", sans-serif;
  --display-weight: 800;
  --display-tracking: -0.025em;
  --display-leading: 0.9;
  --display-transform: uppercase;
  --display-style: normal;

  --ease: cubic-bezier(0.2, 0.8, 0.2, 1);
  --dur: 0.38s;

  /* Photography grade — cool, technical, crushed blacks. */
  --photo-filter: saturate(0.82) contrast(1.18) brightness(0.94);
  --photo-tint: #3ddad7;
  --photo-tint-op: 0.14;
  --photo-blend: overlay;
  --photo-veil: linear-gradient(180deg, rgba(5, 6, 7, 0.2) 0%, rgba(5, 6, 7, 0.85) 100%);


  --sc-day: #dceaf2;
  --sc-gold: #f0c88a;
  --sc-dusk: #b08a5a;
  --sc-night: #0c1014;
  --sc-ceil: #3c3c3e;
  --sc-ceil2: #24262a;
  --sc-beam: #1a1c20;
  --sc-beam2: #2e3238;
  --sc-wall: #eef2f6;
  --sc-wall2: #bfc7cf;
  --sc-floor: #9aa2aa;
  --sc-floor2: #737b83;
  --sc-steel: #9aa4ae;
  --sc-bar: #5a5a5c;
  --sc-bar2: #7c7c7e;
  --sc-glass: #b8ccd8;
  --sc-glow: #cfe8f0;
  --sc-bulb: #e8f4ff;
  --sc-star: #eef2f6;
  --sc-ink: #0e1216;
  --sc-accent: #3ddad7;
  --sc-accent2: #ffb020;
  --sc-deep: #050607;
}

/* ================================================================ base type */
body {
  background: var(--bg);
  color: var(--ink);
  font-family: var(--font-body);
  font-size: var(--step-0);
  line-height: 1.6;
  font-feature-settings: "kern" 1, "liga" 1;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  overflow-x: hidden;
  transition: background-color var(--dur-slow) var(--ease), color var(--dur-slow) var(--ease);
}

h1, h2, h3, h4 {
  font-family: var(--font-display);
  font-weight: var(--display-weight);
  letter-spacing: var(--display-tracking);
  line-height: var(--display-leading);
  text-transform: var(--display-transform);
  font-style: var(--display-style);
  text-wrap: balance;
}

h1 { font-size: var(--step-5); }
h2 { font-size: var(--step-4); }
h3 { font-size: var(--step-2); }
h4 { font-size: var(--step-1); }

/* The italic accent word inside a headline. */
h1 em, h2 em, h3 em, .accent-word {
  font-style: italic;
  color: var(--accent);
}

p { text-wrap: pretty; }

::selection { background: var(--accent); color: var(--accent-ink); }

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

/* Fixed nav means every in-page anchor needs an offset (WCAG 2.4.11). */
:target,
section[id],
[id][data-anchor] { scroll-margin-top: calc(var(--nav-h) + 16px); }

/* ------------------------------------------------------------- primitives */
.eyebrow {
  font-family: var(--font-mono);
  font-size: var(--step--2);
  letter-spacing: 0.24em;
  text-transform: uppercase;
  color: var(--accent);
  display: flex;
  align-items: center;
  gap: 0.85em;
}

.eyebrow::before {
  content: "";
  width: clamp(18px, 3vw, 44px);
  height: 1px;
  background: currentColor;
  opacity: 0.6;
  flex: none;
}

.lede {
  font-size: var(--step-1);
  color: var(--ink-2);
  max-width: 60ch;
  line-height: 1.55;
}

.muted { color: var(--ink-2); }
.mono { font-family: var(--font-mono); font-size: var(--step--1); letter-spacing: 0.08em; }

/* Numbers should never jitter as they count up. */
.tnum { font-variant-numeric: tabular-nums; }

.rule { height: 1px; background: var(--line); border: 0; }

/* --------------------------------------------------------------- film grain */
.grain {
  position: fixed;
  inset: 0;
  pointer-events: none;
  z-index: 900;
  opacity: 0.04;
  background-image: var(--grain);
  background-size: 160px 160px;
  mix-blend-mode: multiply;
}

:root[data-mode="private"] .grain,
:root[data-mode="productions"] .grain {
  opacity: 0.055;
  mix-blend-mode: overlay;
}

/* ------------------------------------------------------------- photography */
/* Every photo is wrapped so it can be graded, veiled and Ken-Burns'd without
   touching the <img> itself. */
.ph {
  position: relative;
  overflow: hidden;
  background: var(--bg-2);
  isolation: isolate;
}

.ph__img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  filter: var(--photo-filter);
  transition: filter var(--dur-slow) var(--ease), transform 1.2s var(--ease-out);
}

/* Blur-up placeholder sits under the real image and fades out on load. */
.ph__lqip {
  position: absolute;
  inset: 0;
  background-size: cover;
  background-position: center;
  filter: blur(18px) saturate(1.2);
  transform: scale(1.12);
  transition: opacity 0.6s var(--ease-out);
}

.ph.is-ready .ph__lqip { opacity: 0; }

/* Mode tint + veil, drawn over the photo. */
.ph::after {
  content: "";
  position: absolute;
  inset: 0;
  background: var(--photo-tint);
  opacity: var(--photo-tint-op);
  mix-blend-mode: var(--photo-blend);
  pointer-events: none;
  z-index: 2;
}

.ph--veil::before {
  content: "";
  position: absolute;
  inset: 0;
  background: var(--photo-veil);
  pointer-events: none;
  z-index: 3;
}

/* Slow drift so stills never read as dead. */
@media (prefers-reduced-motion: no-preference) {
  .ph--drift .ph__img { animation: ph-drift 26s var(--ease-in-out) infinite alternate; }
  @keyframes ph-drift {
    from { transform: scale(1.02) translate3d(0, 0, 0); }
    to   { transform: scale(1.09) translate3d(-1.2%, -1.6%, 0); }
  }
}

.sr-only {
  position: absolute;
  width: 1px; height: 1px;
  padding: 0; margin: -1px;
  overflow: hidden;
  clip: rect(0 0 0 0);
  white-space: nowrap;
  border: 0;
}

.skip {
  position: fixed;
  top: 8px; left: 8px;
  z-index: 2000;
  padding: 10px 16px;
  background: var(--accent);
  color: var(--accent-ink);
  transform: translateY(-200%);
  transition: transform 0.2s;
}
.skip:focus { transform: none; }
