/* ==========================================================================
   Sugarcube Creatives - shared base styles (Direction A: Liquid Glass)
   Owned by the Overall session. Page sessions: do not edit, see DESIGN.md.
   ========================================================================== */

/* ---------- Tokens ---------- */
:root {
  /* colour */
  --bg: #0b0b0c;          /* brand black */
  --bg-2: #141416;
  --ink: #f5f5f7;
  --dim: rgba(245, 245, 247, .62);
  --faint: rgba(245, 245, 247, .38);
  --line: rgba(255, 255, 255, .12);
  --pink: #ff7bac;
  --pink-deep: #f2478f;   /* brand deep pink */
  --pink-soft: #ffb3cf;
  /* Brand palette only: pink, white, black. No other hues. */
  --grad-text: linear-gradient(90deg, #fff, var(--pink-soft) 45%, var(--pink));

  /* type */
  --font: 'Open Sauce One', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
  --fs-hero: clamp(44px, 7.4vw, 108px);
  --fs-h1: clamp(40px, 6vw, 84px);
  --fs-h2: clamp(32px, 4.6vw, 64px);
  --fs-h3: clamp(20px, 2vw, 26px);
  --fs-lede: clamp(17px, 1.6vw, 21px);
  --fs-body: 16px;
  --fs-small: 13px;
  --fs-eyebrow: 12px;

  /* spacing (4px base) */
  --s-1: 4px;  --s-2: 8px;  --s-3: 12px; --s-4: 16px; --s-5: 24px;
  --s-6: 32px; --s-7: 48px; --s-8: 64px; --s-9: 96px; --s-10: 128px;
  --gutter: clamp(16px, 4vw, 32px);
  --section: clamp(80px, 12vw, 140px);
  --max: 1200px;
  --max-text: 68ch;

  /* shape */
  --r-sm: 14px;
  --r-md: 20px;
  --r-lg: 28px;
  --r-pill: 999px;

  /* motion */
  --ease: cubic-bezier(.2, .8, .2, 1);       /* default: Apple-like soft settle */
  --ease-in-out: cubic-bezier(.65, 0, .35, 1);
  --t-fast: .25s;
  --t-med: .5s;
  --t-slow: 1.1s;

  --nav-h: 56px;
  color-scheme: dark;
}

/* ---------- Reset ---------- */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html { -webkit-text-size-adjust: 100%; text-size-adjust: 100%; scroll-padding-top: 96px; }
@media (prefers-reduced-motion: no-preference) { html { scroll-behavior: smooth; } }
body {
  background: var(--bg);
  color: var(--ink);
  font-family: var(--font);
  font-size: var(--fs-body);
  line-height: 1.55;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  overflow-x: clip;
  min-height: 100svh;
}
img, video, svg { display: block; max-width: 100%; height: auto; }
a { color: inherit; text-decoration: none; }
button { font: inherit; color: inherit; background: none; border: 0; cursor: pointer; }
:focus-visible { outline: 2px solid var(--pink); outline-offset: 3px; border-radius: 6px; }
::selection { background: var(--pink); color: #000; }

.skip-link { position: absolute; left: 16px; top: -100px; z-index: 200; padding: 10px 16px; border-radius: var(--r-pill); background: var(--ink); color: #000; font-weight: 600; }
.skip-link:focus { top: 16px; }
.visually-hidden { position: absolute !important; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }

/* ---------- Aurora: moving colour behind everything ---------- */
/* Uses soft radial gradients (no filter: blur) so it stays cheap on phones. */
.aurora { position: fixed; inset: 0; z-index: 0; pointer-events: none; overflow: hidden; opacity: .8; }
.aurora span {
  position: absolute; border-radius: 50%;
  will-change: transform;
  animation: aurora-drift 24s var(--ease-in-out) infinite alternate;
}
.aurora span:nth-child(1) { width: 70vmax; height: 70vmax; left: -5vmax; top: -25vmax; background: radial-gradient(closest-side, rgba(242, 71, 143, .5), transparent); }
.aurora span:nth-child(2) { width: 60vmax; height: 60vmax; right: -20vmax; top: 5vmax; background: radial-gradient(closest-side, rgba(255, 123, 172, .32), transparent); animation-duration: 30s; animation-delay: -8s; }
.aurora span:nth-child(3) { width: 55vmax; height: 55vmax; left: 15vmax; bottom: -30vmax; background: radial-gradient(closest-side, rgba(255, 255, 255, .09), transparent); animation-duration: 36s; animation-delay: -16s; }
@keyframes aurora-drift { to { transform: translate3d(8vw, -6vh, 0) scale(1.15); } }
/* Fine grain on top so the gradients don't band */
.aurora::after { content: ""; position: absolute; inset: 0; opacity: .05; 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 baseFrequency='.9' numOctaves='2' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)'/%3E%3C/svg%3E"); }
/* Quieter variant for reading-heavy pages: <div class="aurora aurora--calm"> */
.aurora--calm { opacity: .5; }

/* Everything else sits above the aurora */
.site-main, .site-footer { position: relative; z-index: 1; }

/* ---------- Liquid glass material ---------- */
.glass {
  background: linear-gradient(180deg, rgba(255, 255, 255, .14), rgba(255, 255, 255, .05));
  -webkit-backdrop-filter: blur(24px) saturate(190%);
  backdrop-filter: blur(24px) saturate(190%);
  border: 1px solid rgba(255, 255, 255, .16);
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, .45),
    inset 0 -1px 0 rgba(255, 255, 255, .06),
    0 20px 50px rgba(0, 0, 0, .35);
}
/* Thicker glass for things over busy images (labels on photos, menus) */
.glass--strong {
  background: linear-gradient(180deg, rgba(30, 30, 36, .62), rgba(20, 20, 24, .5));
  -webkit-backdrop-filter: blur(30px) saturate(200%);
  backdrop-filter: blur(30px) saturate(200%);
}
/* Flat glass: no drop shadow, for small chips and inner panels */
.glass--flat { box-shadow: inset 0 1px 0 rgba(255, 255, 255, .3); }
/* Fallback where backdrop-filter isn't supported */
@supports not ((backdrop-filter: blur(1px)) or (-webkit-backdrop-filter: blur(1px))) {
  .glass { background: rgba(28, 28, 34, .92); }
}

/* ---------- Layout ---------- */
.container { width: 100%; max-width: var(--max); margin-inline: auto; padding-inline: var(--gutter); }
.section { padding-block: var(--section); }
.section--tight { padding-block: calc(var(--section) * .6); }
.stack > * + * { margin-top: var(--s-5); }

/* ---------- Type ---------- */
.eyebrow { font-size: var(--fs-eyebrow); font-weight: 600; letter-spacing: .18em; text-transform: uppercase; color: var(--pink); }
.h-hero, .h1, .h2, .h3 { font-weight: 700; color: var(--ink); text-wrap: balance; }
.h-hero { font-size: var(--fs-hero); line-height: .98; letter-spacing: -.045em; }
.h1 { font-size: var(--fs-h1); line-height: 1; letter-spacing: -.04em; }
.h2 { font-size: var(--fs-h2); line-height: 1.02; letter-spacing: -.035em; }
.h3 { font-size: var(--fs-h3); line-height: 1.15; letter-spacing: -.02em; }
.grad { background: var(--grad-text); -webkit-background-clip: text; background-clip: text; color: transparent; font-style: normal; }
.lede { font-size: var(--fs-lede); line-height: 1.45; color: var(--dim); max-width: 40ch; text-wrap: pretty; }
.muted { color: var(--dim); }
.small { font-size: var(--fs-small); }
.prose { max-width: var(--max-text); color: var(--dim); }
.prose > * + * { margin-top: 1em; }
.prose strong, .prose b { color: var(--ink); font-weight: 600; }
.prose a { color: var(--ink); text-decoration: underline; text-decoration-color: var(--pink); text-underline-offset: 3px; }
.prose ul { padding-left: 1.2em; }
.prose li + li { margin-top: .4em; }
.prose li::marker { color: var(--pink); }

/* ---------- Buttons & chips ---------- */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  min-height: 48px; padding: 14px 24px; border-radius: var(--r-pill);
  font-size: 15px; font-weight: 600; line-height: 1; white-space: nowrap;
  transition: transform var(--t-med) var(--ease), background var(--t-fast), color var(--t-fast);
}
.btn:hover { transform: scale(1.04); }
.btn:active { transform: scale(.98); }
/* Holly: no white buttons, every button is liquid glass.
   .btn--solid = main action: glass with a soft pink tint. .btn--glass = plain clear glass. */
.btn--solid, .btn--glass {
  color: var(--ink);
  -webkit-backdrop-filter: blur(24px) saturate(190%);
  backdrop-filter: blur(24px) saturate(190%);
  border: 1px solid rgba(255, 255, 255, .18);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, .45), inset 0 -1px 0 rgba(255, 255, 255, .06), 0 12px 30px rgba(0, 0, 0, .3);
}
.btn--glass { background: linear-gradient(180deg, rgba(255, 255, 255, .14), rgba(255, 255, 255, .05)); }
.btn--solid {
  background: linear-gradient(180deg, rgba(255, 123, 172, .34), rgba(242, 71, 143, .14));
  border-color: rgba(255, 123, 172, .45);
}
.btn--solid:hover { background: linear-gradient(180deg, rgba(255, 123, 172, .46), rgba(242, 71, 143, .22)); }
.btn--glass:hover { background: linear-gradient(180deg, rgba(255, 255, 255, .2), rgba(255, 255, 255, .08)); }
@supports not ((backdrop-filter: blur(1px)) or (-webkit-backdrop-filter: blur(1px))) {
  .btn--glass { background: rgba(40, 40, 46, .92); }
  .btn--solid { background: rgba(120, 40, 76, .92); }
}
.btn--sm { min-height: 38px; padding: 10px 16px; font-size: 13px; }
.btn-row { display: flex; flex-wrap: wrap; gap: var(--s-3); }

.chip {
  display: inline-flex; align-items: center; padding: 6px 12px; border-radius: var(--r-pill);
  font-size: 11px; font-weight: 700; letter-spacing: .1em; text-transform: uppercase;
  color: var(--pink); background: rgba(255, 123, 172, .1); border: 1px solid rgba(255, 123, 172, .25);
}
.chip-row { display: flex; flex-wrap: wrap; gap: var(--s-2); }

/* ---------- Header / nav (floating glass pill) ---------- */
.site-header {
  position: fixed; z-index: 100; top: max(12px, env(safe-area-inset-top)); left: 50%;
  transform: translateX(-50%);
  width: min(760px, calc(100% - 24px));
}
.nav-bar {
  display: flex; align-items: center; gap: 6px;
  height: var(--nav-h); padding: 6px 6px 6px 16px; border-radius: var(--r-pill);
  transition: background var(--t-med) var(--ease), box-shadow var(--t-med) var(--ease);
}
.site-header.is-scrolled .nav-bar { background: linear-gradient(180deg, rgba(40, 40, 48, .6), rgba(24, 24, 30, .5)); }
.nav-brand { display: flex; align-items: center; gap: 8px; margin-right: auto; padding: 6px 4px; }
.nav-brand .nav-mark { height: 26px; width: auto; }
.nav-brand .nav-word { height: 18px; width: auto; margin-top: 2px; }
.nav-links { display: flex; gap: 2px; list-style: none; }
.nav-links a {
  display: block; padding: 10px 14px; border-radius: var(--r-pill);
  font-size: 13px; font-weight: 500; color: var(--dim);
  transition: color var(--t-fast), background var(--t-fast);
}
.nav-links a:hover, .nav-links a[aria-current="page"] { color: var(--ink); background: rgba(255, 255, 255, .1); }
.nav-cta { margin-left: 4px; }
.nav-toggle { display: none; width: 44px; height: 44px; border-radius: 50%; align-items: center; justify-content: center; }
.nav-toggle span, .nav-toggle span::before { display: block; width: 18px; height: 1.5px; background: var(--ink); border-radius: 2px; transition: transform var(--t-med) var(--ease); }
.nav-toggle span { position: relative; transform: translateY(-3px); }
.nav-toggle span::before { content: ""; position: absolute; left: 0; top: 6px; }
.site-header.is-open .nav-toggle span { transform: translateY(0) rotate(45deg); }
.site-header.is-open .nav-toggle span::before { transform: translateY(-6px) rotate(-90deg); }

/* Mobile menu: a glass sheet that drops from the pill. No scroll lock.
   It floats (position: absolute) so the closed sheet doesn't stretch the header box down
   the page: an invisible header box there would swallow every tap on the top of the screen. */
.nav-sheet { display: none; }
@media (max-width: 720px) {
  .nav-bar .nav-links, .nav-bar .nav-cta { display: none; }
  .nav-toggle { display: inline-flex; }
  .nav-sheet {
    display: block; position: absolute; top: 100%; left: 0; right: 0;
    margin-top: 8px; padding: 10px; border-radius: var(--r-lg);
    opacity: 0; transform: translateY(-8px) scale(.98); transform-origin: top center;
    visibility: hidden; pointer-events: none;
    transition: opacity var(--t-med) var(--ease), transform var(--t-med) var(--ease), visibility 0s linear var(--t-med);
  }
  .site-header.is-open .nav-sheet { opacity: 1; transform: none; visibility: visible; pointer-events: auto; transition-delay: 0s; }
  .nav-sheet .nav-links { flex-direction: column; gap: 2px; }
  .nav-sheet .nav-links a { padding: 14px 16px; font-size: 20px; font-weight: 600; letter-spacing: -.02em; border-radius: var(--r-md); }
  .nav-sheet .btn { width: 100%; margin-top: 8px; }
}

/* ---------- Footer: no box. A gap below the page content, then a long fade to black,
   with the footer content sitting on the black. ---------- */
.site-footer { padding: var(--section) 0 0; }
.footer-cta { text-align: center; display: flex; flex-direction: column; align-items: center; gap: var(--s-5); padding-inline: var(--gutter); }
.footer-bar {
  margin-top: clamp(64px, 10vw, 128px);
  padding: clamp(120px, 16vw, 200px) var(--gutter) max(32px, env(safe-area-inset-bottom));
  background: linear-gradient(180deg, rgba(0, 0, 0, 0) 0%, rgba(0, 0, 0, .7) 35%, #000 70%);
}
.footer-inner { max-width: var(--max); margin-inline: auto; display: grid; gap: var(--s-6) var(--s-8); grid-template-columns: auto minmax(0, 1fr); align-items: start; }
/* Cube and tagline side by side on one line; social bubbles sit above the email in Say hello */
.footer-brand { grid-column: 1 / -1; display: grid; grid-template-columns: auto minmax(0, 1fr); align-items: center; column-gap: var(--s-4); }
.footer-brand img { height: 48px; width: auto; }
.footer-brand p { color: var(--dim); font-size: 15px; }

.footer-col:nth-child(3) { justify-self: end; text-align: right; }
.footer-col:nth-child(3) ul { justify-content: flex-end; }
.footer-col h3 { font-size: var(--fs-eyebrow); font-weight: 600; letter-spacing: .18em; text-transform: uppercase; color: var(--faint); margin-bottom: var(--s-4); }
/* Links run across in a row */
.footer-col ul { list-style: none; display: flex; flex-wrap: wrap; gap: 6px 24px; }
.footer-col a { color: var(--dim); font-size: 16px; overflow-wrap: break-word; transition: color var(--t-fast); }
.footer-col a:hover { color: var(--ink); }
.footer-social { display: flex; gap: 8px; margin-bottom: var(--s-4); }
.footer-col:nth-child(3) .footer-social { justify-content: flex-end; }
/* Wide screens: left side stacks cube + tagline, then Pages, all sitting at the bottom
   so the links line up with the email opposite; Say hello fills the right side */
@media (min-width: 761px) {
  .footer-inner {
    grid-template-columns: minmax(0, 1fr) auto;
    grid-template-rows: 1fr auto auto;
    grid-template-areas: "brand hello" "pages hello" "legal legal";
    row-gap: var(--s-5);
  }
  .footer-brand { grid-area: brand; align-self: end; }
  .footer-col:nth-child(2) { grid-area: pages; align-self: end; }
  .footer-col:nth-child(3) { grid-area: hello; align-self: end; }
  .footer-legal { grid-area: legal; margin-top: var(--s-6); }
}
.footer-social a { width: 44px; height: 44px; border-radius: 50%; background: rgba(255, 255, 255, .08); border: 1px solid var(--line); display: grid; place-items: center; color: var(--dim); transition: color var(--t-fast), transform var(--t-med) var(--ease); }
.footer-social a:hover { color: var(--ink); transform: scale(1.08); }
.footer-social svg { width: 18px; height: 18px; }
.footer-legal { grid-column: 1 / -1; display: flex; justify-content: space-between; gap: var(--s-3) var(--s-4); flex-wrap: wrap; margin-top: var(--s-5); padding-top: var(--s-5); border-top: 1px solid var(--line); color: var(--faint); font-size: var(--fs-small); }
@media (max-width: 760px) {
  .footer-inner { grid-template-columns: minmax(0, 1fr); gap: var(--s-6); }
  .footer-col:nth-child(3) { justify-self: start; text-align: left; }
  .footer-col:nth-child(3) ul { justify-content: flex-start; }
  .footer-col:nth-child(3) .footer-social { justify-content: flex-start; }
  .footer-col a { overflow-wrap: anywhere; }
}
@media (pointer: coarse) {
  .footer-col ul { row-gap: 0; }
  .footer-col a { display: inline-block; padding-block: 8px; }
}

/* ---------- Media helpers ---------- */
.media { border-radius: var(--r-lg); overflow: hidden; background: var(--bg-2); }
.media img, .media video { width: 100%; height: 100%; object-fit: cover; }

/* Swipeable row (galleries on phones). Native scroll-snap, no JS needed. */
.swipe {
  display: grid; grid-auto-flow: column; grid-auto-columns: min(82%, 420px); gap: var(--s-4);
  overflow-x: auto; overscroll-behavior-x: contain; scroll-snap-type: x mandatory;
  padding-inline: var(--gutter); scroll-padding-inline: var(--gutter);
  scrollbar-width: none; -webkit-overflow-scrolling: touch;
}
.swipe::-webkit-scrollbar { display: none; }
.swipe > * { scroll-snap-align: start; }

/* ---------- Scroll reveal ---------- */
/* Only hidden when JS is running (html.js), so content never stays invisible. */
.js .reveal { opacity: 0; transform: translateY(28px) scale(.985); filter: blur(6px); transition: opacity var(--t-slow) var(--ease), transform var(--t-slow) var(--ease), filter var(--t-slow) var(--ease); transition-delay: var(--reveal-delay, 0ms); }
.js .reveal.is-in { opacity: 1; transform: none; filter: none; }
.js .reveal--fade { transform: none; filter: none; }

/* ---------- Page transitions (browsers that support it; others just navigate) ---------- */
@view-transition { navigation: auto; }
::view-transition-old(root) { animation: vt-out .28s var(--ease) both; }
::view-transition-new(root) { animation: vt-in .5s var(--ease) both; }
@keyframes vt-out { to { opacity: 0; } }
@keyframes vt-in { from { opacity: 0; transform: translateY(10px); } }
/* Note: don't give the header or aurora a view-transition-name; it stops glass blurring the page behind it. */

/* ---------- Touch screens: phones keep :hover "stuck" after a tap, so no hover movement there ---------- */
@media (hover: none) {
  .btn:hover, .footer-social a:hover { transform: none; }
  .btn:active { transform: scale(.98); }
}

/* ---------- Reduced motion: everything calm and instant ---------- */
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation-duration: .01ms !important; animation-iteration-count: 1 !important; transition-duration: .01ms !important; scroll-behavior: auto !important; }
  .aurora span { animation: none !important; }
  .js .reveal { opacity: 1; transform: none; filter: none; }
  .btn:hover { transform: none; }
  @view-transition { navigation: none; }
}
