/* ============================================================
   Cedrex Group — Editorial Luxury
   Palette : cream / espresso / sage / brass
   Type    : Fraunces (variable serif) · Geist (sans)
   ============================================================ */

:root {
  --cream:   #FAF7F0;
  --cream-2: #F2EDDF;
  --espresso:#2C1810;
  --espresso-soft:#3D2519;
  --sage:    #8B9D77;
  --brass:   #C9A055;
  --ink:     rgba(44, 24, 16, 0.85);
  --ink-soft:rgba(44, 24, 16, 0.62);
  --ink-mute:rgba(44, 24, 16, 0.42);
  --hairline:rgba(44, 24, 16, 0.10);
  --hairline-strong:rgba(44, 24, 16, 0.18);
  --inset-highlight: inset 0 1px 0 rgba(255,255,255,0.55);

  --ease: cubic-bezier(0.32, 0.72, 0, 1);
  --ease-out: cubic-bezier(0.16, 1, 0.3, 1);
}

* { box-sizing: border-box; -webkit-font-smoothing: antialiased; }

html, body {
  margin: 0;
  padding: 0;
  background: var(--cream);
  color: var(--espresso);
  font-family: 'Geist', system-ui, -apple-system, sans-serif;
  font-feature-settings: "ss01", "ss02", "kern", "liga";
  font-size: 16px;
  line-height: 1.55;
  letter-spacing: -0.005em;
}

.bg-cream { background: var(--cream); }
.text-espresso { color: var(--espresso); }

/* Subtle film grain overlay — performance-safe (fixed, pointer-events-none) */
.grain {
  position: fixed; inset: 0;
  pointer-events: none;
  z-index: 50;
  opacity: 0.04;
  mix-blend-mode: multiply;
  background-image: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' width='240' height='240'><filter id='n'><feTurbulence type='fractalNoise' baseFrequency='0.9' numOctaves='2' stitchTiles='stitch'/></filter><rect width='100%25' height='100%25' filter='url(%23n)' opacity='0.6'/></svg>");
}

a { color: inherit; text-decoration: none; }
em { font-style: italic; font-family: 'Fraunces', serif; font-variation-settings: "SOFT" 50; }

/* ===== NAV ===================================================== */
.nav-island {
  position: fixed;
  top: 24px; left: 50%;
  transform: translateX(-50%);
  z-index: 60;
  display: flex; align-items: center; gap: 32px;
  padding: 10px 12px 10px 18px;
  background: rgba(250, 247, 240, 0.72);
  backdrop-filter: saturate(140%) blur(18px);
  -webkit-backdrop-filter: saturate(140%) blur(18px);
  border: 1px solid var(--hairline);
  border-radius: 999px;
  box-shadow:
    0 1px 0 rgba(255,255,255,0.6) inset,
    0 10px 40px -20px rgba(44, 24, 16, 0.25);
  transition: all 600ms var(--ease);
}

.nav-brand { display: flex; align-items: center; gap: 10px; }
.nav-logomark {
  width: 28px;
  height: 28px;
  display: block;
  flex-shrink: 0;
  border-radius: 7px;
  overflow: hidden;
}
.nav-name {
  font-family: 'Fraunces', serif;
  font-weight: 500;
  font-variation-settings: "opsz" 60;
  font-size: 17px;
  letter-spacing: -0.01em;
}
.nav-links { display: flex; gap: 8px; }
.nav-links a {
  padding: 8px 14px;
  border-radius: 999px;
  font-size: 14px;
  color: var(--ink-soft);
  transition: all 400ms var(--ease);
}
.nav-links a:hover {
  color: var(--espresso);
  background: rgba(44, 24, 16, 0.05);
}

/* ===== SHARED ELEMENTS ========================================= */
.eyebrow {
  display: inline-block;
  padding: 6px 12px;
  border: 1px solid var(--hairline-strong);
  border-radius: 999px;
  font-family: 'Geist', sans-serif;
  font-size: 11px;
  text-transform: uppercase;
  letter-spacing: 0.18em;
  color: var(--ink-soft);
  font-weight: 500;
  margin-bottom: 24px;
  background: rgba(255,255,255,0.4);
}
.eyebrow--light { color: rgba(250,247,240,0.7); border-color: rgba(250,247,240,0.2); background: transparent; }

/* ===== HERO ==================================================== */
.hero {
  min-height: 100dvh;
  padding: 160px 56px 96px;
  display: grid;
  grid-template-columns: 1.05fr 0.95fr;
  gap: 80px;
  align-items: center;
  position: relative;
}

.hero-title {
  font-family: 'Fraunces', serif;
  font-weight: 360;
  font-variation-settings: "opsz" 144, "SOFT" 30;
  font-size: clamp(48px, 7.2vw, 108px);
  line-height: 0.96;
  letter-spacing: -0.035em;
  margin: 0 0 32px;
  color: var(--espresso);
}
.hero-title em { font-weight: 320; color: var(--espresso-soft); }

.hero-lede {
  font-size: 19px;
  line-height: 1.55;
  color: var(--ink);
  max-width: 480px;
  margin: 0 0 40px;
  letter-spacing: -0.008em;
}

.hero-cta-row { display: flex; gap: 14px; align-items: center; flex-wrap: wrap; }

/* ===== BUTTONS ================================================= */
.btn-primary {
  display: inline-flex; align-items: center; gap: 6px;
  padding: 8px 8px 8px 22px;
  background: var(--espresso);
  color: var(--cream);
  border-radius: 999px;
  font-size: 14.5px;
  font-weight: 500;
  letter-spacing: -0.005em;
  transition: all 500ms var(--ease);
  border: 1px solid var(--espresso);
}
.btn-primary > span:first-child { padding-right: 6px; }
.btn-icon {
  display: inline-grid; place-items: center;
  width: 32px; height: 32px;
  background: rgba(250,247,240,0.12);
  border-radius: 999px;
  transition: all 500ms var(--ease);
}
.btn-primary:hover { transform: translateY(-1px); box-shadow: 0 14px 30px -16px rgba(44,24,16,0.55); }
.btn-primary:hover .btn-icon {
  transform: translate(2px, -1px) scale(1.05);
  background: rgba(250,247,240,0.2);
}
.btn-primary:active { transform: translateY(0) scale(0.985); }

.btn-primary--light { background: var(--cream); color: var(--espresso); border-color: rgba(250,247,240,0.2); }
.btn-primary--light .btn-icon { background: rgba(44,24,16,0.08); }
.btn-primary--light:hover .btn-icon { background: rgba(44,24,16,0.14); }

.btn-ghost {
  padding: 10px 18px;
  font-size: 14.5px;
  font-weight: 500;
  color: var(--ink);
  border-radius: 999px;
  transition: all 400ms var(--ease);
  border: 1px solid transparent;
}
.btn-ghost:hover { background: rgba(44,24,16,0.05); border-color: var(--hairline); }

/* ===== CATEGORY CARDS (Right side of hero) ===================== */
.hero-right {
  display: grid;
  grid-template-columns: 1fr 1fr;
  grid-auto-rows: minmax(120px, auto);
  gap: 14px;
}
.category-card { transition: all 700ms var(--ease); opacity: 0; transform: translateY(28px); }
.category-card.in-view { opacity: 1; transform: translateY(0); transition-delay: var(--delay, 0ms); }
.category-card--lg { grid-column: span 2; grid-row: span 1; min-height: 200px; }
.category-card--wide { grid-column: span 2; }

.cat-shell {
  padding: 6px;
  background: linear-gradient(180deg, rgba(255,255,255,0.4), rgba(255,255,255,0.05));
  border: 1px solid var(--hairline);
  border-radius: 28px;
  box-shadow: 0 1px 0 rgba(255,255,255,0.6) inset;
  height: 100%;
}
.cat-core {
  background: var(--cream-2);
  border-radius: 22px;
  padding: 22px 22px 20px;
  height: 100%;
  display: flex; flex-direction: column;
  position: relative;
  box-shadow: var(--inset-highlight);
  transition: all 600ms var(--ease);
}
.cat-core:hover { background: #ECE6D2; }

.cat-eyebrow {
  font-size: 10.5px;
  text-transform: uppercase;
  letter-spacing: 0.22em;
  color: var(--ink-mute);
  font-weight: 500;
  margin-bottom: 14px;
}
.cat-title {
  font-family: 'Fraunces', serif;
  font-weight: 420;
  font-variation-settings: "opsz" 60, "SOFT" 40;
  font-size: 22px;
  line-height: 1.15;
  letter-spacing: -0.015em;
  color: var(--espresso);
  margin-bottom: auto;
  padding-bottom: 18px;
}
.category-card--lg .cat-title { font-size: 28px; }
.cat-meta {
  font-size: 12.5px;
  color: var(--ink-soft);
  letter-spacing: -0.003em;
}

/* ===== SECTION HEAD ============================================ */
.section-head { margin-bottom: 64px; max-width: 760px; }
.section-title {
  font-family: 'Fraunces', serif;
  font-weight: 360;
  font-variation-settings: "opsz" 144, "SOFT" 30;
  font-size: clamp(36px, 4.6vw, 64px);
  line-height: 1.02;
  letter-spacing: -0.028em;
  margin: 0;
  color: var(--espresso);
}

/* ===== PRINCIPLES ============================================== */
.principles { padding: 160px 56px; max-width: 1320px; margin: 0 auto; }
.principles-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 18px; }

.principle { opacity: 0; transform: translateY(28px); transition: all 800ms var(--ease); }
.principle.in-view { opacity: 1; transform: translateY(0); }
.principle:nth-child(2) { transition-delay: 80ms; }
.principle:nth-child(3) { transition-delay: 160ms; }

.principle-shell {
  padding: 6px;
  background: linear-gradient(180deg, rgba(255,255,255,0.5), rgba(255,255,255,0.05));
  border: 1px solid var(--hairline);
  border-radius: 28px;
  height: 100%;
}
.principle-core {
  background: var(--cream-2);
  border-radius: 22px;
  padding: 32px 30px 36px;
  height: 100%;
  display: flex; flex-direction: column;
  box-shadow: var(--inset-highlight);
}
.principle-num {
  font-family: 'Fraunces', serif;
  font-style: italic;
  font-variation-settings: "SOFT" 80;
  font-size: 36px;
  color: var(--brass);
  margin-bottom: 32px;
  line-height: 1;
}
.principle-title {
  font-family: 'Fraunces', serif;
  font-weight: 400;
  font-variation-settings: "opsz" 60;
  font-size: 24px;
  line-height: 1.18;
  letter-spacing: -0.018em;
  margin: 0 0 14px;
}
.principle-body {
  font-size: 15px;
  line-height: 1.6;
  color: var(--ink-soft);
  margin: 0;
}

/* ===== CTA SECTION ============================================= */
.cta-section { padding: 0 56px 120px; max-width: 1320px; margin: 0 auto; }
.cta-shell {
  padding: 6px;
  background: linear-gradient(180deg, rgba(44,24,16,0.95), rgba(44,24,16,0.85));
  border: 1px solid rgba(44,24,16,0.6);
  border-radius: 36px;
  opacity: 0;
  transform: translateY(28px);
  transition: all 900ms var(--ease);
}
.cta-shell.in-view { opacity: 1; transform: translateY(0); }
.cta-core {
  background: var(--espresso);
  border-radius: 30px;
  padding: 96px 64px 88px;
  text-align: center;
  color: var(--cream);
  box-shadow: inset 0 1px 0 rgba(255,255,255,0.06);
}
.cta-title {
  font-family: 'Fraunces', serif;
  font-weight: 360;
  font-variation-settings: "opsz" 144, "SOFT" 30;
  font-size: clamp(34px, 4.4vw, 60px);
  line-height: 1.05;
  letter-spacing: -0.028em;
  margin: 0 auto 18px;
  max-width: 880px;
  color: var(--cream);
}
.cta-title em { color: var(--brass); }
.cta-lede {
  font-size: 16px;
  color: rgba(250,247,240,0.7);
  margin: 0 0 36px;
}

/* ===== FOOTER ================================================== */
.site-footer {
  padding: 56px;
  border-top: 1px solid var(--hairline);
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 24px 56px;
  align-items: center;
}
.footer-tagline {
  font-size: 13.5px;
  color: var(--ink-soft);
  margin: 8px 0 0;
}
.footer-right { display: flex; gap: 24px; }
.footer-right a {
  font-size: 14px;
  color: var(--ink);
  padding: 6px 0;
  transition: opacity 300ms var(--ease);
}
.footer-right a:hover { opacity: 0.6; }
.footer-bottom {
  grid-column: 1 / -1;
  display: flex; justify-content: space-between;
  padding-top: 28px; margin-top: 16px;
  border-top: 1px solid var(--hairline);
  font-size: 12px;
  color: var(--ink-mute);
  letter-spacing: 0.04em;
}

/* ===== SCROLL-IN-VIEW REVEALS for hero text =================== */
.hero-title, .hero-lede, .hero-cta-row, .section-head { opacity: 0; transform: translateY(20px); transition: all 900ms var(--ease); filter: blur(8px); }
.hero-title.in-view { opacity: 1; transform: translateY(0); filter: blur(0); }
.hero-lede.in-view { opacity: 1; transform: translateY(0); filter: blur(0); transition-delay: 120ms; }
.hero-cta-row.in-view { opacity: 1; transform: translateY(0); filter: blur(0); transition-delay: 220ms; }
.section-head.in-view { opacity: 1; transform: translateY(0); filter: blur(0); }

/* Force hero text visible on first paint (no flash-of-invisible) */
.hero-title, .hero-lede, .hero-cta-row { opacity: 1; transform: none; filter: none; }
.hero-title.pre-reveal, .hero-lede.pre-reveal, .hero-cta-row.pre-reveal { opacity: 0; transform: translateY(20px); filter: blur(8px); }

/* ===== ABOUT / CONTACT PAGES =================================== */
.page-wrap { padding: 160px 56px 96px; max-width: 1080px; margin: 0 auto; }
.page-eyebrow { margin-bottom: 28px; }
.page-title {
  font-family: 'Fraunces', serif;
  font-weight: 360;
  font-variation-settings: "opsz" 144, "SOFT" 30;
  font-size: clamp(42px, 6vw, 96px);
  line-height: 0.98;
  letter-spacing: -0.032em;
  margin: 0 0 36px;
}
.page-title em { color: var(--espresso-soft); }
.page-lede {
  font-size: 20px;
  line-height: 1.55;
  color: var(--ink);
  max-width: 700px;
  margin: 0 0 80px;
}

.about-blocks { display: grid; grid-template-columns: 1fr 1fr; gap: 18px; margin-bottom: 96px; }
.about-blocks .principle-core { padding: 36px 32px; }

.about-row {
  display: grid;
  grid-template-columns: 220px 1fr;
  gap: 56px;
  padding: 36px 0;
  border-top: 1px solid var(--hairline);
}
.about-row:last-child { border-bottom: 1px solid var(--hairline); }
.about-row-label {
  font-size: 11.5px;
  text-transform: uppercase;
  letter-spacing: 0.22em;
  color: var(--ink-mute);
  font-weight: 500;
  padding-top: 6px;
}
.about-row-body {
  font-family: 'Fraunces', serif;
  font-weight: 380;
  font-variation-settings: "opsz" 60, "SOFT" 30;
  font-size: 22px;
  line-height: 1.4;
  letter-spacing: -0.012em;
  color: var(--espresso);
}
.about-row-body p { margin: 0 0 12px; }
.about-row-body p:last-child { margin-bottom: 0; }

.contact-card {
  margin-top: 16px;
  padding: 6px;
  background: linear-gradient(180deg, rgba(255,255,255,0.5), rgba(255,255,255,0.05));
  border: 1px solid var(--hairline);
  border-radius: 32px;
}
.contact-core {
  background: var(--cream-2);
  border-radius: 26px;
  padding: 56px 48px;
  box-shadow: var(--inset-highlight);
}
.contact-row {
  display: grid;
  grid-template-columns: 200px 1fr;
  gap: 56px;
  padding: 26px 0;
  border-top: 1px solid var(--hairline);
}
.contact-row:first-of-type { border-top: 0; padding-top: 0; }
.contact-label {
  font-size: 11.5px;
  text-transform: uppercase;
  letter-spacing: 0.22em;
  color: var(--ink-mute);
  font-weight: 500;
  padding-top: 4px;
}
.contact-value {
  font-family: 'Fraunces', serif;
  font-size: 22px;
  font-weight: 400;
  font-variation-settings: "opsz" 60;
  letter-spacing: -0.012em;
  line-height: 1.3;
}
.contact-value a { color: var(--brass); transition: opacity 300ms var(--ease); }
.contact-value a:hover { opacity: 0.7; }
.contact-note { font-size: 14.5px; color: var(--ink-soft); margin-top: 8px; font-family: 'Geist', sans-serif; line-height: 1.5; }

/* ===== RESPONSIVE ============================================== */
@media (max-width: 980px) {
  .hero { grid-template-columns: 1fr; padding: 140px 24px 64px; gap: 56px; min-height: auto; }
  .principles, .cta-section { padding: 96px 24px; }
  .site-footer { padding: 40px 24px; grid-template-columns: 1fr; }
  .principles-grid { grid-template-columns: 1fr; }
  .about-blocks { grid-template-columns: 1fr; }
  .page-wrap { padding: 130px 24px 56px; }
  .about-row { grid-template-columns: 1fr; gap: 12px; padding: 28px 0; }
  .contact-row { grid-template-columns: 1fr; gap: 8px; }
  .cta-core { padding: 64px 28px; }
  .nav-island { gap: 12px; padding: 8px 8px 8px 14px; top: 16px; }
  .nav-name { display: none; }
  .nav-links a { padding: 6px 10px; font-size: 13px; }
}
@media (max-width: 540px) {
  .hero-right { grid-template-columns: 1fr; }
  .category-card--lg, .category-card--wide { grid-column: span 1; }
}
