/* ============================================================
   NAILS BY THE SIE — GLOBAL STYLESHEET
   Pacific Atelier Color System + Typography + Base Styles
   ============================================================ */

/* --- FONTS --- */
@import url('https://fonts.googleapis.com/css2?family=Cormorant+Garamond:ital,wght@0,300;0,400;0,500;1,300;1,400;1,500&family=Inter:wght@300;400;500;600&display=swap');

/* --- DESIGN TOKENS --- */
:root {
  /* Color Palette — Pacific Atelier */
  --obsidian:    #0E0E0C;
  --bone:        #F4EFE7;
  --champagne:   #C8B6A0;
  --mocha:       #6B5544;
  --gold:        #A48A6E;

  /* Tints */
  --bone-dark:   #EBE4D8;
  --obsidian-80: rgba(14,14,12,0.80);
  --obsidian-50: rgba(14,14,12,0.50);
  --champagne-20: rgba(200,182,160,0.20);

  /* Typography */
  --font-display: 'Cormorant Garamond', 'Georgia', serif;
  --font-body:    'Inter', -apple-system, BlinkMacSystemFont, sans-serif;

  /* Spacing scale */
  --space-xs:   8px;
  --space-sm:   16px;
  --space-md:   32px;
  --space-lg:   64px;
  --space-xl:   120px;
  --space-2xl:  180px;

  /* Transitions */
  --ease-out:   cubic-bezier(0.16, 1, 0.3, 1);
  --ease-in-out: cubic-bezier(0.45, 0, 0.55, 1);

  /* Border */
  --border-thin: 1px solid var(--champagne);
  --border-faint: 1px solid rgba(200,182,160,0.30);
}

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

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

body {
  background-color: var(--bone);
  color: var(--obsidian);
  font-family: var(--font-body);
  font-weight: 400;
  line-height: 1.6;
  overflow-x: hidden;
  cursor: auto; /* native cursor always visible by default */
}

/* Hide native cursor ONLY after JS confirms custom cursor is ready */
body.cursor-ready {
  cursor: none;
}

@media (hover: none) {
  body, body.cursor-ready { cursor: auto; }
}

img, video {
  display: block;
  max-width: 100%;
  height: auto;
}

/* ── Suppress Chromium / WebKit native media-play overlay ────────────────
   Chromium injects a Shadow-DOM play button on any element it classifies as
   a "media container": typically a flex-centred, overflow:hidden div that
   contains an SVG or image child.  All .img-placeholder and .img-grain divs
   match that heuristic.  These rules kill the overlay at every level.      */

/* 1. Pseudo-element selectors (caught by most UA implementations) */
*::-webkit-media-controls,
*::-webkit-media-controls-overlay-play-button,
*::-webkit-media-controls-panel,
*::-webkit-media-controls-play-button,
*::-webkit-media-controls-start-playback-button {
  display: none !important;
  -webkit-appearance: none !important;
  opacity: 0 !important;
  pointer-events: none !important;
}

/* 2. Block pointer-events on every decorative image / placeholder so the
      browser never treats the container as an interactive media element.
      Clicks on the *parent* fire normally (lightbox, hover states, etc.)  */
.img-container img,
.work-item img,
.masonry-img-wrap img,
.hero-media-bg,
.img-placeholder,
.img-grain {
  pointer-events: none;
  -webkit-user-select: none;
  user-select: none;
}

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

ul, ol {
  list-style: none;
}

button, input, textarea, select {
  font-family: inherit;
  font-size: inherit;
  border: none;
  outline: none;
  background: none;
  cursor: pointer;
}

/* ============================================================
   CUSTOM CURSOR (desktop only)
   ============================================================ */
.cursor-dot,
.cursor-ring {
  position: fixed;
  top: 0;
  left: 0;
  pointer-events: none;
  z-index: 9999;
  transform: translate(-50%, -50%);
  transition: opacity 0.3s ease;
}

.cursor-dot {
  width: 6px;
  height: 6px;
  background: var(--gold);
  border-radius: 50%;
  transition: transform 0.1s var(--ease-out);
}

.cursor-ring {
  width: 32px;
  height: 32px;
  border: 1px solid var(--gold);
  border-radius: 50%;
  transition: transform 0.35s var(--ease-out), width 0.3s ease, height 0.3s ease, border-color 0.3s ease;
}

.cursor-ring.hover-active {
  width: 48px;
  height: 48px;
  border-color: var(--champagne);
}

/* Custom cursor elements hidden until JS positions them */
.cursor-dot,
.cursor-ring {
  opacity: 0;
}

body.cursor-ready .cursor-dot,
body.cursor-ready .cursor-ring {
  opacity: 1;
}

body:not(:hover) .cursor-dot,
body:not(:hover) .cursor-ring {
  opacity: 0;
}

@media (max-width: 768px) {
  .cursor-dot, .cursor-ring { display: none; }
  body.cursor-ready { cursor: auto; }
}

/* ============================================================
   TYPOGRAPHY SYSTEM
   ============================================================ */

/* Display — Cormorant Garamond */
.type-display-xl {
  font-family: var(--font-display);
  font-size: clamp(3.5rem, 8vw, 9rem);
  font-weight: 300;
  line-height: 0.95;
  letter-spacing: -0.02em;
}

.type-display-lg {
  font-family: var(--font-display);
  font-size: clamp(2.5rem, 5vw, 6rem);
  font-weight: 300;
  line-height: 1.0;
  letter-spacing: -0.02em;
}

.type-display-md {
  font-family: var(--font-display);
  font-size: clamp(2rem, 4vw, 4.5rem);
  font-weight: 300;
  line-height: 1.05;
  letter-spacing: -0.015em;
}

.type-display-sm {
  font-family: var(--font-display);
  font-size: clamp(1.5rem, 3vw, 3rem);
  font-weight: 300;
  line-height: 1.1;
  letter-spacing: -0.01em;
}

.type-display-italic {
  font-style: italic;
}

/* Body — Inter */
.type-body-lg {
  font-family: var(--font-body);
  font-size: clamp(1rem, 1.2vw, 1.125rem);
  font-weight: 400;
  line-height: 1.75;
}

.type-body {
  font-family: var(--font-body);
  font-size: 0.9375rem;
  font-weight: 400;
  line-height: 1.7;
}

.type-body-sm {
  font-family: var(--font-body);
  font-size: 0.8125rem;
  font-weight: 400;
  line-height: 1.6;
}

/* Label / Eyebrow */
.type-label {
  font-family: var(--font-body);
  font-size: 0.6875rem;
  font-weight: 500;
  letter-spacing: 0.15em;
  text-transform: uppercase;
}

/* Pull quote */
.type-pullquote {
  font-family: var(--font-display);
  font-size: clamp(1.4rem, 2.5vw, 2.25rem);
  font-weight: 300;
  font-style: italic;
  line-height: 1.4;
  letter-spacing: -0.01em;
}

/* ============================================================
   LAYOUT UTILITIES
   ============================================================ */

.container {
  width: 100%;
  max-width: 1440px;
  margin: 0 auto;
  padding: 0 clamp(24px, 5vw, 80px);
}

.container--narrow {
  max-width: 780px;
  margin: 0 auto;
  padding: 0 clamp(24px, 5vw, 48px);
}

.section-pad {
  padding: var(--space-xl) 0;
}

@media (max-width: 768px) {
  .section-pad {
    padding: 80px 0;
  }
}

/* ============================================================
   SCROLL REVEAL ANIMATIONS
   ============================================================ */

.reveal {
  opacity: 0;
  transform: translateY(20px);
  transition: opacity 0.8s var(--ease-out), transform 0.8s var(--ease-out);
}

.reveal.visible {
  opacity: 1;
  transform: translateY(0);
}

.reveal-delay-1 { transition-delay: 0.1s; }
.reveal-delay-2 { transition-delay: 0.2s; }
.reveal-delay-3 { transition-delay: 0.3s; }
.reveal-delay-4 { transition-delay: 0.4s; }
.reveal-delay-5 { transition-delay: 0.5s; }
.reveal-delay-6 { transition-delay: 0.6s; }

/* ============================================================
   BUTTONS
   ============================================================ */

.btn {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  padding: 14px 32px;
  font-family: var(--font-body);
  font-size: 0.75rem;
  font-weight: 500;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  transition: all 0.4s var(--ease-out);
  cursor: pointer;
  position: relative;
}

.btn-primary {
  background: var(--obsidian);
  color: var(--bone);
  border: 1px solid var(--obsidian);
}

.btn-primary:hover {
  background: var(--gold);
  border-color: var(--gold);
  color: var(--obsidian);
}

.btn-outline {
  background: transparent;
  color: var(--obsidian);
  border: 1px solid var(--gold);
}

.btn-outline:hover {
  background: var(--gold);
  color: var(--bone);
}

.btn-ghost {
  background: transparent;
  color: var(--bone);
  border: 1px solid rgba(244,239,231,0.4);
  padding: 12px 28px;
}

.btn-ghost:hover {
  border-color: var(--champagne);
  color: var(--champagne);
}

.btn-arrow::after {
  content: '→';
  transition: transform 0.3s var(--ease-out);
}

.btn-arrow:hover::after {
  transform: translateX(4px);
}

/* ============================================================
   DIVIDERS
   ============================================================ */

.divider {
  width: 48px;
  height: 1px;
  background: var(--gold);
  margin: 24px 0;
}

.divider--center {
  margin: 24px auto;
}

.divider--full {
  width: 100%;
  background: var(--border-faint);
  margin: 0;
}

/* ============================================================
   IMAGE CONTAINERS
   ============================================================ */

.img-4-5 {
  position: relative;
  overflow: hidden;
  aspect-ratio: 4/5;
  background: var(--bone-dark);
}

.img-16-9 {
  position: relative;
  overflow: hidden;
  aspect-ratio: 16/9;
  background: var(--obsidian);
}

.img-1-1 {
  position: relative;
  overflow: hidden;
  aspect-ratio: 1/1;
  background: var(--bone-dark);
}

.img-container img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.6s var(--ease-out);
}

.img-container:hover img {
  transform: scale(1.03);
}

/* Placeholder image treatment
   NOTE: deliberately NOT display:flex — Chromium's media-overlay heuristic
   fires on flex-centred overflow:hidden containers with SVG children.
   Keep as display:block to avoid the native play-button injection.         */
.img-placeholder {
  width: 100%;
  height: 100%;
  display: block;
  background: linear-gradient(135deg, var(--bone-dark) 0%, var(--champagne) 100%);
  position: relative;
  overflow: hidden;
}

.img-placeholder::before {
  content: '';
  position: absolute;
  inset: 0;
  background-image: 
    radial-gradient(ellipse at 30% 20%, rgba(164,138,110,0.15) 0%, transparent 60%),
    radial-gradient(ellipse at 70% 80%, rgba(107,85,68,0.1) 0%, transparent 60%);
}

.img-placeholder-label {
  position: absolute;
  bottom: 16px;
  left: 16px;
  font-family: var(--font-body);
  font-size: 0.5625rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--mocha);
  opacity: 0.6;
}

.img-grain {
  position: absolute;
  inset: 0;
  opacity: 0.04;
  background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 256 256' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='noise'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.9' numOctaves='4' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23noise)'/%3E%3C/svg%3E");
  background-size: 128px;
}

/* ============================================================
   EYEBROW + LABELS
   ============================================================ */

.eyebrow {
  display: inline-block;
  font-family: var(--font-body);
  font-size: 0.6875rem;
  font-weight: 500;
  letter-spacing: 0.15em;
  text-transform: uppercase;
  color: var(--gold);
  margin-bottom: 20px;
}

/* ============================================================
   FORM ELEMENTS
   ============================================================ */

.form-field {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.form-label {
  font-family: var(--font-body);
  font-size: 0.6875rem;
  font-weight: 500;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--mocha);
}

.form-input {
  width: 100%;
  padding: 14px 0;
  border-bottom: 1px solid var(--champagne);
  background: transparent;
  color: var(--obsidian);
  font-family: var(--font-body);
  font-size: 0.9375rem;
  transition: border-color 0.3s ease;
}

.form-input::placeholder {
  color: var(--champagne);
}

.form-input:focus {
  border-bottom-color: var(--gold);
}

.form-textarea {
  width: 100%;
  padding: 14px 0;
  border-bottom: 1px solid var(--champagne);
  background: transparent;
  color: var(--obsidian);
  font-family: var(--font-body);
  font-size: 0.9375rem;
  resize: none;
  transition: border-color 0.3s ease;
  min-height: 120px;
}

.form-textarea:focus {
  border-bottom-color: var(--gold);
}

.form-error {
  font-size: 0.75rem;
  color: #8B0000;
  letter-spacing: 0.05em;
  margin-top: 4px;
}

/* ============================================================
   COOKIE BANNER
   ============================================================ */

.cookie-banner {
  position: fixed;
  bottom: 0;
  left: 0;
  right: 0;
  z-index: 8000;
  background: var(--obsidian);
  color: var(--bone);
  padding: 20px clamp(24px, 5vw, 80px);
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  transform: translateY(100%);
  transition: transform 0.5s var(--ease-out);
}

.cookie-banner.visible {
  transform: translateY(0);
}

.cookie-banner p {
  font-size: 0.8125rem;
  line-height: 1.6;
  color: var(--champagne);
  max-width: 600px;
}

.cookie-banner a {
  color: var(--gold);
  text-decoration: underline;
  text-underline-offset: 3px;
}

.cookie-dismiss {
  flex-shrink: 0;
  padding: 10px 24px;
  border: 1px solid var(--champagne);
  color: var(--bone);
  font-size: 0.6875rem;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  cursor: pointer;
  transition: all 0.3s ease;
  white-space: nowrap;
}

.cookie-dismiss:hover {
  background: var(--champagne);
  color: var(--obsidian);
}

/* ============================================================
   UTILITY CLASSES
   ============================================================ */

.text-gold    { color: var(--gold); }
.text-mocha   { color: var(--mocha); }
.text-bone    { color: var(--bone); }
.text-champagne { color: var(--champagne); }

.bg-obsidian  { background: var(--obsidian); }
.bg-bone      { background: var(--bone); }
.bg-bone-dark { background: var(--bone-dark); }

.text-center  { text-align: center; }
.text-right   { text-align: right; }

.italic { font-style: italic; }
.uppercase { text-transform: uppercase; letter-spacing: 0.1em; }

.flex { display: flex; }
.flex-col { flex-direction: column; }
.items-center { align-items: center; }
.justify-between { justify-content: space-between; }
.gap-sm { gap: var(--space-sm); }
.gap-md { gap: var(--space-md); }

.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;
}

/* ============================================================
   PAGE TRANSITION OVERLAY
   ============================================================ */

.page-overlay {
  position: fixed;
  inset: 0;
  background: var(--bone);
  z-index: 7000;
  transform: translateY(-100%);
  transition: transform 0.5s var(--ease-in-out);
  pointer-events: none;
}

/* ============================================================
   SELECTION
   ============================================================ */

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

/* ============================================================
   SCROLLBAR (webkit)
   ============================================================ */

::-webkit-scrollbar { width: 4px; }
::-webkit-scrollbar-track { background: var(--bone); }
::-webkit-scrollbar-thumb { background: var(--champagne); }
::-webkit-scrollbar-thumb:hover { background: var(--gold); }
