/* =====================================================
   AirSync Sanctuary Design System — shared overlay
   Load AFTER each page's own <style> block.
   ===================================================== */

@import url('https://fonts.googleapis.com/css2?family=Manrope:wght@300;400;500;600&family=Playfair+Display:ital,wght@0,400;0,500;1,400;1,500&family=Shippori+Mincho:wght@400;500;600&family=Noto+Sans+JP:wght@300;400;500;600&display=swap');

:root {
  --blue: #c8a97e;
  --blue-light: #e0c9a6;
  --dark: #2a2622;
  --mid: #3a332d;
  --ease: cubic-bezier(0.25, 1, 0.5, 1);
  --ease-fluid: cubic-bezier(0.25, 1, 0.5, 1);
  --c-bg-base: #2a2622;
  --c-bg-overlay: rgba(42, 38, 34, 0.82);
  --c-text-main: #ffffff;
  --c-text-muted: rgba(255, 255, 255, 0.7);
  --font-serif: 'Playfair Display', 'Shippori Mincho', serif;
  --font-serif-jp: 'Shippori Mincho', 'Playfair Display', serif;
  --font-sans: 'Manrope', 'Noto Sans JP', -apple-system, sans-serif;
}

body {
  font-family: var(--font-sans) !important;
  letter-spacing: 0.01em;
}

/* ---- Fixed layered background (image + cursor-reveal blur + noise) ---- */
html { background: #1c1916; }
body { background: transparent !important; }

.sanct-layer-sharp, .sanct-layer-blur, .sanct-noise {
  position: fixed; top: 0; left: 0; width: 100%; height: 100%;
  pointer-events: none;
}
.sanct-layer-sharp {
  background-image: url('/assets/hero-bg.jpg');
  background-size: cover;
  background-position: center;
  background-repeat: no-repeat;
  filter: sepia(0.18) grayscale(0.2) brightness(0.75);
  z-index: 0;
}
.sanct-layer-blur {
  background-image: url('/assets/hero-bg.jpg');
  background-size: cover;
  background-position: center;
  background-repeat: no-repeat;
  filter: blur(30px) brightness(0.6) sepia(0.3);
  transform: scale(1.1);
  z-index: 1;
  mask-image: radial-gradient(circle 420px at var(--sx, 50%) var(--sy, 50%), transparent 0%, black 100%);
  -webkit-mask-image: radial-gradient(circle 420px at var(--sx, 50%) var(--sy, 50%), transparent 0%, black 100%);
}
.sanct-noise {
  z-index: 2;
  opacity: 0.08;
  mix-blend-mode: overlay;
  background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 200 200' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='noiseFilter'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.8' numOctaves='3' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23noiseFilter)'/%3E%3C/svg%3E");
}

.page-gradient { position: relative; z-index: 10; background: transparent !important; }
nav { z-index: 100 !important; }

/* Lift EVERY body-level content block above the fixed background layers.
   Works on pages without a .page-gradient wrapper. */
body > nav,
body > header,
body > main,
body > section,
body > article,
body > footer,
body > aside,
body > .wrap,
body > .container,
body > .breadcrumb,
body > .hero,
body > div:not([class^="sanct-"]):not([id^="sanctCursor"]):not(.glow-cursor) {
  position: relative;
  z-index: 10;
}

section, .s-dark { background: transparent !important; }
section::before, .s-dark::before { background: transparent !important; }
.page-gradient .s-dark::after { display: none !important; }
section + section { box-shadow: 0 -1px 0 rgba(255,255,255,0.04); }

/* ---- Nav ---- */
.nav-inner,
nav.solid .nav-inner {
  background: rgba(42,38,34,0.55) !important;
  backdrop-filter: blur(20px) saturate(1.1) !important;
  -webkit-backdrop-filter: blur(20px) saturate(1.1) !important;
  border: 1px solid rgba(255,255,255,0.08) !important;
  box-shadow: 0 1px 2px rgba(0,0,0,0.2), 0 4px 16px rgba(0,0,0,0.25) !important;
}
.nav-logo {
  font-family: var(--font-serif) !important;
  font-style: italic !important;
  font-weight: 400 !important;
  font-size: 1.3rem !important;
  letter-spacing: -0.01em !important;
}
.nav-logo em { font-style: italic !important; color: rgba(255,255,255,0.55) !important; }
nav.solid .nav-logo em { color: var(--blue) !important; }
.nav-links a {
  font-size: 11px !important;
  letter-spacing: 0.18em !important;
  text-transform: uppercase !important;
  font-weight: 500 !important;
}
.nav-links a:hover { background: transparent !important; opacity: 0.6; }
nav.solid .nav-links a:hover { background: transparent !important; opacity: 0.6; }
.nav-cta {
  background: transparent !important;
  border: 1px solid rgba(255,255,255,0.5) !important;
  color: #fff !important;
  font-size: 11px !important;
  letter-spacing: 0.18em !important;
  text-transform: uppercase !important;
  padding: 0.5rem 1rem !important;
  border-radius: 100px !important;
}
.nav-cta::after { display: none !important; }
.nav-cta:hover { background: rgba(255,255,255,0.08) !important; border-color: #fff !important; }
.nav-active { color: #fff !important; opacity: 1 !important; }
nav.solid .nav-active { color: #fff !important; }

/* ---- Hero ---- */
.hero::before { display: none !important; }
.hero-mesh, .starfield { display: none !important; }
.orb-1 { background: rgba(212, 184, 150, 0.25) !important; filter: blur(140px); }
.orb-2 { background: rgba(200, 169, 126, 0.2) !important; filter: blur(160px); }

.hero-eyebrow {
  font-family: var(--font-serif) !important;
  font-size: 1.1rem !important;
  font-weight: 400 !important;
  letter-spacing: 0.02em !important;
  color: rgba(255, 255, 255, 0.55) !important;
  margin-bottom: 1.2rem !important;
  line-height: 1 !important;
  max-width: none !important;
}
.hero-eyebrow i { font-style: italic !important; color: rgba(255, 255, 255, 0.85) !important; }

.hero-text h1 {
  font-family: var(--font-serif-jp) !important;
  font-weight: 400 !important;
  font-size: clamp(2.4rem, 5.2vw, 4.2rem) !important;
  line-height: 1.15 !important;
  letter-spacing: 0.01em !important;
}
.hero-text h1 .accent {
  background: none !important;
  -webkit-background-clip: initial !important;
  background-clip: initial !important;
  -webkit-text-fill-color: initial !important;
  font-family: var(--font-serif-jp) !important;
  font-style: normal !important;
  color: var(--blue) !important;
  animation: none !important;
}

.hero-text p {
  font-family: var(--font-serif-jp) !important;
  font-size: 1rem !important;
  line-height: 2 !important;
  letter-spacing: 0.12em !important;
  color: rgba(255,255,255,0.78) !important;
  max-width: 420px;
}

/* ---- Buttons ---- */
.btn {
  font-family: var(--font-sans) !important;
  font-size: 11px !important;
  letter-spacing: 0.2em !important;
  text-transform: uppercase !important;
  font-weight: 500 !important;
  padding: 0.95rem 1.8rem !important;
  border-radius: 100px !important;
  transition: all 0.6s var(--ease-fluid) !important;
}
.btn-blue {
  background: var(--blue) !important;
  color: #1c1916 !important;
  border: 1px solid var(--blue) !important;
  box-shadow: 0 8px 30px rgba(200, 169, 126, 0.2) !important;
  font-weight: 600 !important;
}
.btn-blue::after { display: none !important; }
.btn-blue:hover {
  background: var(--blue-light) !important;
  border-color: var(--blue-light) !important;
  color: #1c1916 !important;
  transform: translateY(-1px) !important;
  filter: none !important;
  box-shadow: 0 10px 40px rgba(224, 201, 166, 0.28) !important;
}
.btn-ghost {
  background: transparent !important;
  border: 1px solid rgba(255,255,255,0.25) !important;
  color: rgba(255,255,255,0.85) !important;
}
.btn-ghost:hover {
  border-color: rgba(255,255,255,0.6) !important;
  background: transparent !important;
  color: #fff !important;
}

/* ---- Section headings ---- */
section h2, .s-dark h2 {
  font-family: var(--font-serif) !important;
  font-weight: 400 !important;
  letter-spacing: -0.015em !important;
  line-height: 1.15 !important;
}
section h2 em, .s-dark h2 em {
  font-style: italic !important;
  color: rgba(255,255,255,0.95) !important;
}
.sec-label, .sec-label-dark {
  font-family: var(--font-sans) !important;
  font-size: 10px !important;
  letter-spacing: 0.3em !important;
  text-transform: uppercase !important;
  color: rgba(255,255,255,0.5) !important;
  background: transparent !important;
  border: 1px solid rgba(255,255,255,0.15) !important;
  padding: 0.4rem 1rem !important;
  border-radius: 100px !important;
}

/* ---- Cards: glass / translucent ---- */
.pain-card, .feature-card, .platform-card, .pricing-card,
.proof-card, .faq-item, .highlight-card, .step-card,
.demo-step, .screenshot-card, .security-card, .about-card,
.stat-card, .roadmap-card, .bento-grid > * {
  background: rgba(255,255,255,0.03) !important;
  border: 1px solid rgba(255,255,255,0.08) !important;
  backdrop-filter: blur(14px) saturate(1.05);
  -webkit-backdrop-filter: blur(14px) saturate(1.05);
  transition: all 0.5s var(--ease-fluid);
}
.pain-card:hover, .feature-card:hover, .platform-card:hover,
.pricing-card:hover, .highlight-card:hover, .step-card:hover,
.demo-step:hover, .security-card:hover {
  background: rgba(255,255,255,0.06) !important;
  border-color: rgba(255,255,255,0.2) !important;
  transform: translateY(-2px);
}

/* ---- Catch hard-coded blues ---- */
[style*="color: #0036ff"], [style*="color:#0036ff"],
[style*="color: rgb(0, 54, 255)"] { color: var(--blue) !important; }
[style*="rgba(0,54,255"], [style*="rgba(0, 54, 255"] { background-color: rgba(200,169,126,0.18) !important; }
[style*="#0036ff"] { color: var(--blue) !important; }

/* ---- Phone mockup ---- */
.phone {
  background: linear-gradient(145deg, #1a1714, #2a2622) !important;
  box-shadow: 0 30px 80px rgba(0,0,0,0.55), 0 0 0 1px rgba(255,255,255,0.08),
              inset 0 1px 0 rgba(255,255,255,0.04) !important;
}
.phone-screen { background: rgba(22, 19, 16, 0.92) !important; }
.inbox-badge {
  background: rgba(200, 169, 126, 0.18) !important;
  color: var(--blue-light) !important;
  border: 1px solid rgba(200, 169, 126, 0.3) !important;
}
.p-msg { background: rgba(255,255,255,0.03) !important; border: 1px solid rgba(255,255,255,0.06) !important; }
.p-msg-1 { border-left-color: var(--blue) !important; }
.p-msg-2 { border-left-color: #d4a574 !important; }
.p-msg-3 { border-left-color: #93b496 !important; }
.tag-gen { background: rgba(200, 169, 126, 0.18) !important; color: var(--blue-light) !important; }
.tag-wait { background: rgba(212, 165, 116, 0.18) !important; color: #e8c18b !important; }
.tag-sent { background: rgba(147, 180, 150, 0.18) !important; color: #a8c9ab !important; }
.inbox-badge, .tag-gen, .tag-wait, .tag-sent {
  font-family: var(--font-sans) !important;
  letter-spacing: 0.08em !important;
}

/* ---- Screenshot property cards ---- */
.ss-prop-card { background: rgba(28, 25, 22, 0.7) !important; border: 1px solid rgba(255, 255, 255, 0.06) !important; }
.ss-prop-img { filter: saturate(0.4) hue-rotate(-15deg) brightness(0.85); position: relative; }
.ss-prop-img::after {
  content: ''; position: absolute; inset: 0;
  background: linear-gradient(135deg, rgba(200, 169, 126, 0.12), rgba(60, 48, 38, 0.3));
  pointer-events: none;
}
.ss-prop-stat-dot[style*="#10b981"], .ss-prop-stat-dot[style*="10b981"] { background: #93b496 !important; }
.ss-prop-stat-dot[style*="#f59e0b"], .ss-prop-stat-dot[style*="f59e0b"] { background: #d4a574 !important; }
.ss-prop-stat-dot[style*="#0036ff"], .ss-prop-stat-dot[style*="0036ff"] { background: var(--blue) !important; }

[class*="screenshot"] [style*="background: #0f071d"],
[class*="ss-"] [style*="#0f071d"] { background: rgba(28, 25, 22, 0.85) !important; }

.ss-avatar, [class*="avatar"] { filter: saturate(0.6) hue-rotate(-10deg); }
.ss-panel, .ss-browser, .screenshot-browser {
  background: rgba(22, 19, 16, 0.85) !important;
  border: 1px solid rgba(255,255,255,0.06) !important;
}

/* ---- Scroll progress bar ---- */
.scroll-bar { background: linear-gradient(90deg, var(--blue), rgba(255,255,255,0.6)) !important; }

/* ---- Custom cursor ---- */
.sanct-cursor-dot, .sanct-cursor-outline {
  position: fixed; top: 0; left: 0;
  transform: translate(-50%, -50%);
  border-radius: 50%;
  z-index: 9999;
  pointer-events: none;
  mix-blend-mode: difference;
}
.sanct-cursor-dot { width: 4px; height: 4px; background: #fff; }
.sanct-cursor-outline {
  width: 32px; height: 32px;
  border: 1px solid rgba(255,255,255,0.35);
  transition: width 0.25s, height 0.25s, border-color 0.25s, background 0.25s;
}
.sanct-cursor-outline.hover {
  width: 56px; height: 56px;
  background: rgba(255,255,255,0.06);
  border-color: rgba(255,255,255,0.7);
}
@media (pointer: coarse) {
  .sanct-cursor-dot, .sanct-cursor-outline { display: none; }
}

/* ---- Slow fade-in ---- */
@keyframes sanctFadeIn {
  from { opacity: 0; transform: translateY(18px); }
  to { opacity: 1; transform: translateY(0); }
}
.hero-text h1 { animation: sanctFadeIn 2.2s var(--ease-fluid) forwards; }
.hero-text p { opacity: 0; animation: sanctFadeIn 2.2s var(--ease-fluid) 0.4s forwards; }
.hero-btns { opacity: 0; animation: sanctFadeIn 2.2s var(--ease-fluid) 0.9s forwards; }

.wave-divider svg path { fill: rgba(255,255,255,0.02) !important; }

a { transition: opacity 0.3s ease; }

input, textarea, select { cursor: text !important; }
input:focus, textarea:focus, select:focus { outline-color: var(--blue) !important; }

/* ---- Mobile ---- */
@media (max-width: 768px) {
  .sanct-layer-blur { display: none !important; }
  .sanct-cursor-dot, .sanct-cursor-outline { display: none !important; }
  * { cursor: auto !important; }
  .sanct-layer-sharp {
    background:
      radial-gradient(ellipse at 30% 20%, rgba(212,184,150,0.18), transparent 60%),
      linear-gradient(180deg, #1c1916, #2a2622) !important;
  }
  .hero-eyebrow { font-size: 0.9rem !important; margin-bottom: 0.8rem !important; }
  .hero-text h1 { font-size: clamp(2rem, 8vw, 2.8rem) !important; }
  .hero-text p { font-size: 0.95rem !important; letter-spacing: 0.08em !important; }
}

/* ---- Reduced motion ---- */
@media (prefers-reduced-motion: reduce) {
  .sanct-layer-blur { display: none !important; }
  .sanct-cursor-dot, .sanct-cursor-outline { display: none !important; }
  * { cursor: auto !important; animation-duration: 0.01ms !important; transition-duration: 0.01ms !important; }
}
