/* =========================================================
   CornerStone — landing styles
   Palette: tekhelet (sacred blue), gold leaf, Jerusalem
   stone, parchment cream, and deep ink. Calm, ancient, holy.
   ========================================================= */

:root {
  /* Sacred blues (tekhelet) */
  --ink:        #16213a;
  --ink-deep:   #0f1830;
  --tekhelet:   #1d2c4d;

  /* Gold leaf */
  --gold:       #c2a253;
  --gold-soft:  #d8bd7c;
  --gold-deep:  #a8842f;

  /* Stone & parchment */
  --parchment:  #f6efe0;
  --parchment-2:#efe5d1;
  --cream:      #fbf7ee;
  --stone:      #b8ad97;
  --stone-deep: #7d735f;

  /* Text */
  --text:       #2a2519;
  --text-soft:  #5c5341;
  --text-light: #f4ecda;

  --maxw: 1140px;
  --header-h: 70px;
  --radius: 14px;
  --shadow: 0 24px 60px -28px rgba(15, 24, 48, 0.45);

  --serif-display: "Cormorant Garamond", Georgia, serif;
  --serif-body: "EB Garamond", Georgia, serif;

  /* Hebrew type: self-hosted webfont first, then a close system Hebrew serif
     (shown during the font-display: swap window), then generic serif.
     David ships on Windows/macOS; FrankRuehl on Windows (CLM on Linux). */
  --he-body: "Shofar", "David", "David Libre", serif;
  --he-aram: "Keter Aram Tsova", "FrankRuehl", "Frank Ruehl CLM", serif;
  --he-yg:   "Keter YG", var(--he-aram);   /* Keter YG → Keter Aram Tsova chain */
}

/* Self-hosted Hebrew display face, used on BOTH editions:
   the תּוֹרָה / תַּלְמוּד card glyphs (and nav/CTA on the Hebrew page).
   Each weight lazy-loads only where it's actually used. */
@font-face {
  font-family: "Keter YG";
  src: url("/assets/fonts/KeterYG-Medium.woff2") format("woff2");
  font-weight: 400 600; font-style: normal; font-display: swap;
}
@font-face {
  font-family: "Keter YG";
  src: url("/assets/fonts/KeterYG-Bold.woff2") format("woff2");
  font-weight: 700; font-style: normal; font-display: swap;
}

* { box-sizing: border-box; }

html { scroll-behavior: smooth; }

body {
  margin: 0;
  font-family: var(--serif-body);
  font-size: 1.125rem;
  line-height: 1.65;
  color: var(--text);
  background: var(--cream);
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

.container { width: 100%; max-width: var(--maxw); margin: 0 auto; padding: 0 28px; }

h1, h2, h3 { font-family: var(--serif-display); font-weight: 500; line-height: 1.1; margin: 0; letter-spacing: 0.2px; text-wrap: balance; }
h1 { font-size: clamp(2.5rem, 5.4vw, 4.1rem); }
h2 { font-size: clamp(2rem, 3.8vw, 2.9rem); }
h3 { font-size: 1.5rem; }
p { margin: 0 0 1rem; }
a { color: inherit; text-decoration: none; }

.eyebrow {
  font-family: var(--serif-body);
  text-transform: uppercase;
  letter-spacing: 0.32em;
  font-size: 0.74rem;
  color: var(--gold-deep);
  margin: 0 0 1rem;
  font-weight: 500;
}
.eyebrow.light { color: var(--gold-soft); }

.skip-link {
  position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px;
  overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; border: 0;
}
.skip-link:focus {
  position: fixed; top: 12px; left: 12px; width: auto; height: auto;
  clip: auto; padding: 10px 16px; background: var(--ink); color: var(--text-light);
  border-radius: 8px; z-index: 100;
}

/* ---------- Buttons ---------- */
.btn {
  display: inline-block; font-family: var(--serif-body); font-size: 1.02rem;
  padding: 15px 28px; border-radius: 999px; cursor: pointer; border: 1px solid transparent;
  transition: transform .18s ease, box-shadow .18s ease, background .18s ease, color .18s ease;
  letter-spacing: 0.2px;
}
.btn-primary {
  background: linear-gradient(180deg, var(--gold-soft), var(--gold));
  color: #2b2410; font-weight: 600; border-color: var(--gold-deep);
  box-shadow: 0 10px 26px -10px rgba(168, 132, 47, 0.7);
}
.btn-primary:hover { transform: translateY(-2px); box-shadow: 0 16px 34px -12px rgba(168, 132, 47, 0.8); }

/* ---------- Header ---------- */
.site-header {
  position: sticky; top: 0; z-index: 40;
  background: rgba(15, 24, 48, 0.86);
  backdrop-filter: blur(10px);
  border-bottom: 1px solid rgba(194, 162, 83, 0.22);
}
.header-inner { display: flex; align-items: center; justify-content: space-between; height: var(--header-h); }
.brand { display: flex; align-items: center; gap: 11px; color: var(--text-light); }
.brand-mark { color: var(--gold-soft); }
.brand-name { font-family: var(--serif-display); font-size: 1.4rem; letter-spacing: 1px; }
.site-nav { display: flex; align-items: center; gap: 30px; }
.site-nav a { color: var(--text-light); font-size: 0.98rem; opacity: 0.85; transition: opacity .2s, color .2s; }
.site-nav a:hover { opacity: 1; color: var(--gold-soft); }
.nav-cta {
  border: 1px solid rgba(216, 189, 124, 0.5); padding: 8px 18px; border-radius: 999px;
  opacity: 1 !important; color: var(--gold-soft) !important;
}
.nav-cta:hover { background: rgba(216, 189, 124, 0.12); }

/* Language switcher */
.lang-switch {
  display: inline-flex; align-items: center; gap: 4px;
  border: 1px solid rgba(216, 189, 124, 0.32); border-radius: 999px; padding: 3px;
}
.lang-switch a {
  font-size: 0.82rem; letter-spacing: 0.06em; line-height: 1;
  padding: 5px 10px; border-radius: 999px; opacity: 0.7;
}
.lang-switch a.lang-current {
  background: rgba(216, 189, 124, 0.16); color: var(--gold-soft) !important; opacity: 1;
}

/* ---------- Hero ---------- */
.hero {
  position: relative; overflow: hidden;
  background:
    radial-gradient(1100px 600px at 78% -10%, rgba(194,162,83,0.16), transparent 60%),
    linear-gradient(165deg, var(--ink-deep) 0%, var(--tekhelet) 55%, var(--ink) 100%);
  color: var(--text-light);
  /* Fill the first screen (minus the sticky header) and centre the content,
     so the hero stays above the fold regardless of viewport height.
     Padding is the breathing room / minimum gap when content overflows. */
  display: flex;
  flex-direction: column;
  justify-content: center;
  min-height: calc(100vh - var(--header-h));   /* fallback */
  min-height: calc(100svh - var(--header-h));  /* mobile-safe (no URL-bar jump) */
  padding: clamp(2.5rem, 6vh, 5.5rem) 0;
}
.hero::after {
  content: ""; position: absolute; inset: 0; pointer-events: none;
  background-image: radial-gradient(rgba(255,255,255,0.04) 1px, transparent 1px);
  background-size: 22px 22px; opacity: 0.5;
}
.hero-grid {
  position: relative; z-index: 1;
  display: grid; grid-template-columns: 1fr 1.1fr; gap: 56px; align-items: center;
}
.hero-copy .lede { font-size: 1.3rem; color: #e8ddc6; max-width: 33ch; margin-top: 1.4rem; }
.hero-copy .lede strong { color: var(--gold-soft); font-weight: 600; }
.hero h1 { margin-bottom: 0.2rem; }
.hero-actions { display: flex; align-items: center; flex-wrap: wrap; gap: 14px 20px; margin: 2rem 0 1.2rem; }
.hero-link {
  color: var(--gold-soft); font-size: 1.05rem; letter-spacing: 0.3px;
  border-bottom: 1px solid rgba(216, 189, 124, 0.45); padding-bottom: 2px;
  transition: color .2s ease, border-color .2s ease;
}
.hero-link:hover { color: var(--cream); border-color: var(--gold-soft); }
.hero-note { font-size: 1rem; color: var(--stone); letter-spacing: 0.3px; }

/* Device image */
.hero-art { position: relative; display: flex; justify-content: center; align-items: center; }
.hero-art picture { display: contents; } /* let the <img> be the flex child */
.hero-image {
  width: 100%; max-width: 660px; height: auto;
  border-radius: 16px;
  filter: drop-shadow(0 30px 60px rgba(15, 24, 48, 0.55));
}

/* ---------- Trust strip ---------- */
.strip { background: var(--ink); border-top: 1px solid rgba(194,162,83,0.2); }
.strip-inner {
  display: grid; grid-template-columns: repeat(4, 1fr); gap: 24px;
  padding: 30px 28px; color: var(--text-light);
}
.strip-item { text-align: center; border-inline-end: 1px solid rgba(194,162,83,0.18); padding: 0 12px; }
.strip-item:last-child { border-inline-end: none; }
.strip-num { display: block; font-family: var(--serif-display); font-size: 1.7rem; color: var(--gold-soft); }
.strip-label { display: block; font-size: 0.88rem; color: var(--stone); margin-top: 4px; }

/* ---------- Sections ---------- */
.section { padding: 92px 0; }
.section-head { max-width: 60ch; margin: 0 auto 52px; text-align: center; }
.section-intro { font-size: 1.18rem; color: var(--text-soft); margin-top: 1rem; }

/* Cards */
.cards { display: grid; gap: 26px; }
.cards.two { grid-template-columns: repeat(2, 1fr); }
.cards.three { grid-template-columns: repeat(3, 1fr); }
.card {
  background: var(--cream); border: 1px solid var(--parchment-2);
  border-radius: var(--radius); padding: 38px 34px;
  box-shadow: 0 18px 44px -32px rgba(42,37,25,0.5);
  transition: transform .2s ease, box-shadow .2s ease;
}
.card:hover { transform: translateY(-4px); box-shadow: 0 26px 54px -30px rgba(42,37,25,0.55); }
.card h3 { margin-bottom: 0.5rem; color: var(--tekhelet); }
.card p { color: var(--text-soft); margin: 0; }
.card.soft { background: linear-gradient(180deg, #fbf7ee, #f4ecda); border-color: #ece1ca; }
.card-glyph {
  font-family: var(--he-yg); font-size: 2.4rem; font-weight: 700; color: var(--gold-deep);
  direction: rtl; margin-bottom: 14px; line-height: 1;
}

/* ---------- Craft ---------- */
.section-craft { background: linear-gradient(180deg, var(--parchment), var(--parchment-2)); }
.craft-grid { display: grid; grid-template-columns: 0.9fr 1.1fr; gap: 60px; align-items: center; }
.craft-copy p { color: var(--text-soft); }
.craft-copy h2 { color: var(--tekhelet); margin-bottom: 1rem; }
.craft-copy strong { color: var(--gold-deep); }
.feature-list { list-style: none; padding: 0; margin: 1.6rem 0 0; }
.feature-list li {
  padding: 14px 0; padding-inline-start: 30px; position: relative; color: var(--text-soft);
  border-top: 1px solid rgba(125,115,95,0.2);
}
.feature-list li::before {
  content: ""; position: absolute; inset-inline-start: 4px; top: 21px; width: 9px; height: 9px;
  background: var(--gold); border-radius: 2px; transform: rotate(45deg);
}
.feature-list span { color: var(--text); font-weight: 600; }

.craft-art {
  display: grid; grid-template-rows: 1.4fr 1fr 0.7fr; gap: 14px; height: 420px;
}
.material {
  border-radius: var(--radius); display: flex; align-items: flex-end; padding: 22px;
  font-family: var(--serif-display); font-size: 1.4rem; letter-spacing: 2px;
  box-shadow: var(--shadow); position: relative; overflow: hidden;
}
.material span { position: relative; z-index: 1; }
.material-wood { background: linear-gradient(135deg, #7a5634, #a37a4a 60%, #6a4a2c); color: #f4e6cf; }
.material-metal { background: linear-gradient(135deg, #8d8e92, #c7c9cd 50%, #6f7176); color: #2c2f34; }
.material-stone { background: linear-gradient(135deg, #a59a82, #c3b89f 55%, #847a64); color: #3a3424; }

/* ---------- Specs ---------- */
.section-specs { background: var(--ink-deep); color: var(--text-light); }
.section-specs .eyebrow { color: var(--gold-soft); }
.section-specs h2 { color: var(--cream); }
.specs {
  display: grid; grid-template-columns: repeat(2, 1fr); gap: 0; margin: 0;
  border: 1px solid rgba(194,162,83,0.25); border-radius: var(--radius); overflow: hidden;
}
.spec {
  display: flex; justify-content: space-between; gap: 20px; padding: 22px 28px;
  border-bottom: 1px solid rgba(194,162,83,0.16); border-inline-end: 1px solid rgba(194,162,83,0.16);
}
.spec:nth-child(even) { border-inline-end: none; }
.spec dt { font-family: var(--serif-display); font-size: 1.2rem; color: var(--gold-soft); flex-shrink: 0; }
.spec dd { margin: 0; text-align: end; color: #e6dcc6; }

/* ---------- Notify ---------- */
.section-notify {
  background:
    radial-gradient(900px 480px at 50% -20%, rgba(194,162,83,0.18), transparent 60%),
    linear-gradient(165deg, var(--tekhelet) 0%, var(--ink-deep) 100%);
  color: var(--text-light); text-align: center;
}
.notify-inner { max-width: 680px; margin: 0 auto; }
.section-notify h2 { color: var(--cream); }
.notify-lede { font-size: 1.2rem; color: #e6dcc6; margin: 1rem auto 2rem; max-width: 52ch; }
.notify-form { display: flex; gap: 12px; justify-content: center; flex-wrap: wrap; }
.notify-fine { font-size: 0.86rem; color: var(--stone); margin-top: 1.2rem; }

/* ---------- FAQ ---------- */
.faq { max-width: 760px; margin: 0 auto; }
.faq details {
  border-bottom: 1px solid var(--parchment-2); padding: 8px 0;
}
.faq summary {
  cursor: pointer; list-style: none; padding: 18px 4px; font-family: var(--serif-display);
  font-size: 1.3rem; color: var(--tekhelet); display: flex; justify-content: space-between; align-items: center;
}
.faq summary::-webkit-details-marker { display: none; }
.faq summary::after { content: "+"; color: var(--gold-deep); font-size: 1.6rem; transition: transform .2s; }
.faq details[open] summary::after { transform: rotate(45deg); }
.faq details p { color: var(--text-soft); padding: 0 4px 18px; margin: 0; }

/* ---------- Footer ---------- */
.site-footer { background: var(--ink-deep); color: var(--text-light); padding: 56px 0 0; }
.footer-inner {
  display: flex; align-items: center; justify-content: space-between; gap: 24px;
  flex-wrap: wrap; padding-bottom: 32px; border-bottom: 1px solid rgba(194,162,83,0.18);
}
.footer-brand { display: flex; align-items: center; gap: 10px; font-family: var(--serif-display); font-size: 1.3rem; }
.footer-brand .brand-mark { color: var(--gold-soft); }
.footer-tag { font-style: italic; color: var(--stone); margin: 0; }
.footer-nav { display: flex; gap: 26px; }
.footer-nav a { color: #e6dcc6; opacity: 0.85; transition: color .2s; }
.footer-nav a:hover { color: var(--gold-soft); }
.footer-base { padding: 22px 28px; text-align: center; }
.footer-base p { margin: 0; font-size: 0.86rem; color: var(--stone-deep); }

/* ---------- Responsive ---------- */
@media (max-width: 900px) {
  .hero-grid { grid-template-columns: 1fr; gap: 48px; }
  .hero-art { order: -1; }
  .craft-grid { grid-template-columns: 1fr; gap: 40px; }
  .craft-art { height: 340px; order: 2; }
  .strip-inner { grid-template-columns: repeat(2, 1fr); }
  .strip-item:nth-child(2) { border-inline-end: none; }
  .cards.two, .cards.three { grid-template-columns: 1fr; }
  .specs { grid-template-columns: 1fr; }
  .spec { border-right: none; }
  .site-nav { gap: 14px; }
  /* Hide the in-page section links on mobile, but keep the language switcher + CTA */
  .site-nav > a:not(.nav-cta) { display: none; }
}
@media (max-width: 540px) {
  .container { padding: 0 20px; }
  .section { padding: 64px 0; }
  .strip-inner { grid-template-columns: 1fr; }
  .strip-item { border-inline-end: none; border-bottom: 1px solid rgba(194,162,83,0.18); padding-bottom: 18px; }
  .strip-item:last-child { border-bottom: none; }
  .footer-inner { flex-direction: column; text-align: center; }
}

@media (prefers-reduced-motion: reduce) {
  * { scroll-behavior: auto !important; transition: none !important; }
}
