/* =============================================================
   A to Z Gemstones — Editorial Luxury Design System
   ============================================================= */

:root {
  /* Palette — refined editorial luxury */
  --ink: #1a1a1a;
  --charcoal: #2b2b2b;
  --slate: #55524d;
  --stone: #8a857d;
  --mist: #b8b3a9;
  --paper: #faf8f4;
  --cream: #f3efe7;
  --line: #e4ded3;
  --white: #ffffff;

  /* Accent — jewel gold + deep emerald hint */
  --gold: #a8863f;
  --gold-soft: #c2a35e;
  --emerald: #1f4c3f;
  --plum: #6a2c48;

  /* Typography */
  --serif: "Cormorant Garamond", "Times New Roman", Georgia, serif;
  --sans: "Jost", "Helvetica Neue", Arial, sans-serif;

  /* Metrics */
  --maxw: 1240px;
  --readw: 720px;
  --gutter: clamp(1.25rem, 4vw, 3.5rem);
  --radius: 2px;
  --ease: cubic-bezier(0.22, 1, 0.36, 1);
}

/* ---------- Reset ---------- */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; }
body {
  font-family: var(--sans);
  color: var(--ink);
  background: var(--paper);
  line-height: 1.7;
  font-size: 17px;
  font-weight: 300;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}
img { max-width: 100%; height: auto; display: block; }
a { color: inherit; text-decoration: none; transition: color .3s var(--ease); }

/* ---------- Typography ---------- */
h1, h2, h3, h4 { font-family: var(--serif); font-weight: 500; line-height: 1.12; color: var(--ink); letter-spacing: -0.01em; }
.eyebrow {
  font-family: var(--sans);
  font-size: .72rem;
  font-weight: 500;
  letter-spacing: .28em;
  text-transform: uppercase;
  color: var(--gold);
}
.serif-italic { font-family: var(--serif); font-style: italic; }

/* ---------- Layout ---------- */
.wrap { max-width: var(--maxw); margin: 0 auto; padding: 0 var(--gutter); }
.section { padding: clamp(4rem, 9vw, 8rem) 0; }
.divider { width: 60px; height: 1px; background: var(--gold); margin: 1.5rem 0; }
.divider.center { margin-left: auto; margin-right: auto; }

/* ---------- Header ---------- */
.site-header {
  position: sticky; top: 0; z-index: 100;
  background: rgba(250, 248, 244, 0.9);
  backdrop-filter: saturate(180%) blur(12px);
  border-bottom: 1px solid var(--line);
}
.nav {
  display: flex; align-items: center; justify-content: space-between;
  height: 84px;
}
.brand { display: flex; flex-direction: column; line-height: 1; }
.brand .logo {
  font-family: var(--serif); font-size: 1.7rem; font-weight: 600;
  letter-spacing: .02em; color: var(--ink);
}
.brand .tagline {
  font-family: var(--sans); font-size: .62rem; letter-spacing: .24em;
  text-transform: uppercase; color: var(--stone); margin-top: 5px;
}
.nav-links { display: flex; gap: 2.4rem; align-items: center; list-style: none; }
.nav-links a {
  font-size: .82rem; letter-spacing: .14em; text-transform: uppercase;
  color: var(--slate); font-weight: 400; position: relative; padding: 4px 0;
}
.nav-links a::after {
  content: ""; position: absolute; left: 0; bottom: 0; width: 0; height: 1px;
  background: var(--gold); transition: width .35s var(--ease);
}
.nav-links a:hover, .nav-links a[aria-current="page"] { color: var(--ink); }
.nav-links a:hover::after, .nav-links a[aria-current="page"]::after { width: 100%; }

.nav-toggle {
  display: none; background: none; border: none; cursor: pointer;
  width: 30px; height: 22px; position: relative;
}
.nav-toggle span {
  position: absolute; left: 0; width: 100%; height: 1.5px; background: var(--ink);
  transition: all .3s var(--ease);
}
.nav-toggle span:nth-child(1) { top: 0; }
.nav-toggle span:nth-child(2) { top: 50%; transform: translateY(-50%); }
.nav-toggle span:nth-child(3) { bottom: 0; }
.nav-toggle.open span:nth-child(1) { top: 50%; transform: translateY(-50%) rotate(45deg); }
.nav-toggle.open span:nth-child(2) { opacity: 0; }
.nav-toggle.open span:nth-child(3) { bottom: 50%; transform: translateY(50%) rotate(-45deg); }

/* ---------- Hero ---------- */
.hero {
  position: relative; text-align: center;
  padding: clamp(5rem, 12vw, 10rem) 0 clamp(4rem, 8vw, 7rem);
  background:
    radial-gradient(ellipse 80% 60% at 50% -10%, rgba(168,134,63,.09), transparent 60%),
    var(--paper);
}
.hero .eyebrow { display: block; margin-bottom: 1.5rem; }
.hero h1 {
  font-size: clamp(3rem, 8vw, 6.5rem);
  font-weight: 500; letter-spacing: -0.02em; line-height: 1;
}
.hero h1 em { font-style: italic; color: var(--gold); }
.hero .lede {
  max-width: 640px; margin: 1.8rem auto 0; font-size: clamp(1.05rem, 2vw, 1.3rem);
  color: var(--slate); font-weight: 300; font-family: var(--serif);
  font-style: italic; line-height: 1.5;
}
.hero-actions { margin-top: 2.6rem; display: flex; gap: 1rem; justify-content: center; flex-wrap: wrap; }

/* ---------- Buttons ---------- */
.btn {
  display: inline-flex; align-items: center; gap: .6rem;
  font-family: var(--sans); font-size: .78rem; letter-spacing: .18em;
  text-transform: uppercase; font-weight: 400;
  padding: 1rem 2.2rem; border: 1px solid var(--ink); color: var(--ink);
  background: transparent; cursor: pointer; transition: all .4s var(--ease);
}
.btn:hover { background: var(--ink); color: var(--paper); }
.btn-gold { border-color: var(--gold); color: var(--gold); }
.btn-gold:hover { background: var(--gold); color: var(--white); }

/* ---------- Featured post ---------- */
.featured {
  display: grid; grid-template-columns: 1.15fr 1fr; gap: clamp(2rem, 5vw, 4.5rem);
  align-items: center;
}
.featured-media { overflow: hidden; }
.featured-media img {
  width: 100%; aspect-ratio: 4/3; object-fit: cover;
  transition: transform 1.2s var(--ease);
}
.featured:hover .featured-media img { transform: scale(1.04); }
.featured h2 { font-size: clamp(2rem, 4vw, 3.2rem); margin: 1rem 0 1rem; }
.featured p { color: var(--slate); margin-bottom: 1.8rem; }

/* ---------- Post grid ---------- */
.section-head { text-align: center; margin-bottom: clamp(2.5rem, 5vw, 4rem); }
.section-head h2 { font-size: clamp(2rem, 4vw, 2.8rem); }
.section-head .eyebrow { display: block; margin-bottom: 1rem; }

.grid {
  display: grid; grid-template-columns: repeat(3, 1fr);
  gap: clamp(1.8rem, 3.5vw, 3rem) clamp(1.8rem, 3vw, 2.6rem);
}
.card { display: flex; flex-direction: column; }
.card-media { overflow: hidden; margin-bottom: 1.3rem; position: relative; }
.card-media img {
  width: 100%; aspect-ratio: 3/2; object-fit: cover;
  transition: transform 1s var(--ease);
}
.card:hover .card-media img { transform: scale(1.05); }
.card-meta {
  font-size: .68rem; letter-spacing: .18em; text-transform: uppercase;
  color: var(--stone); margin-bottom: .7rem; display: flex; gap: .8rem; align-items: center;
}
.card-meta .cat { color: var(--gold); }
.card h3 {
  font-size: 1.5rem; line-height: 1.2; margin-bottom: .6rem;
  transition: color .3s var(--ease);
}
.card:hover h3 { color: var(--gold); }
.card p { font-size: .92rem; color: var(--slate); margin-bottom: 1rem; flex: 1; }
.card .read {
  font-size: .72rem; letter-spacing: .18em; text-transform: uppercase;
  color: var(--ink); font-weight: 400; align-self: flex-start;
  border-bottom: 1px solid var(--gold); padding-bottom: 3px;
}

/* ---------- Article (single) ---------- */
.article-hero {
  text-align: center; padding: clamp(3rem, 7vw, 6rem) 0 clamp(2rem, 4vw, 3.5rem);
}
.article-hero .meta {
  font-size: .72rem; letter-spacing: .2em; text-transform: uppercase;
  color: var(--stone); margin-bottom: 1.4rem;
}
.article-hero .meta .cat { color: var(--gold); }
.article-hero h1 {
  font-size: clamp(2.4rem, 5.5vw, 4.5rem); max-width: 900px; margin: 0 auto;
  font-weight: 500;
}
.article-cover { max-width: 1000px; margin: 0 auto clamp(2.5rem, 5vw, 4rem); }
.article-cover img { width: 100%; max-height: 620px; object-fit: cover; }

.article-body { max-width: var(--readw); margin: 0 auto; }
.article-body p { margin: 0 0 1.5rem; color: var(--charcoal); font-size: 1.12rem; line-height: 1.85; }
.article-body p span { font-weight: 300 !important; }
.article-body h2, .article-body h3 { margin: 2.5rem 0 1rem; }
.article-body h2 { font-size: 2rem; }
.article-body h3 { font-size: 1.5rem; }
.article-body img {
  margin: 2.5rem auto; width: 100%; border-radius: var(--radius);
}
.article-body a { color: var(--gold); border-bottom: 1px solid var(--line); }
.article-body a:hover { border-color: var(--gold); }
.article-body ul, .article-body ol { margin: 0 0 1.5rem 1.4rem; color: var(--charcoal); }
.article-body li { margin-bottom: .6rem; }
.article-body blockquote {
  border-left: 2px solid var(--gold); padding-left: 1.6rem; margin: 2rem 0;
  font-family: var(--serif); font-style: italic; font-size: 1.4rem; color: var(--slate);
}
.article-body iframe { max-width: 100%; margin: 2rem auto; display: block; }

.article-foot {
  max-width: var(--readw); margin: clamp(3rem, 6vw, 5rem) auto 0;
  padding-top: 2.5rem; border-top: 1px solid var(--line); text-align: center;
}
.article-foot .signature { font-family: var(--serif); font-style: italic; font-size: 1.5rem; color: var(--gold); }

/* ---------- Post navigation ---------- */
.post-nav {
  display: grid; grid-template-columns: 1fr 1fr; gap: 1px;
  background: var(--line); margin-top: clamp(3rem, 6vw, 5rem); border-top: 1px solid var(--line);
}
.post-nav a {
  background: var(--paper); padding: 2.2rem var(--gutter); transition: background .3s var(--ease);
}
.post-nav a:hover { background: var(--cream); }
.post-nav .label { font-size: .68rem; letter-spacing: .2em; text-transform: uppercase; color: var(--stone); margin-bottom: .5rem; }
.post-nav .t { font-family: var(--serif); font-size: 1.25rem; color: var(--ink); }
.post-nav .next { text-align: right; }

/* ---------- Filter bar (blog) ---------- */
.filter-bar {
  display: flex; gap: .5rem; justify-content: center; flex-wrap: wrap;
  margin-bottom: clamp(2.5rem, 5vw, 3.5rem);
}
.filter-bar button {
  font-family: var(--sans); font-size: .74rem; letter-spacing: .14em; text-transform: uppercase;
  padding: .6rem 1.4rem; border: 1px solid var(--line); background: transparent;
  color: var(--slate); cursor: pointer; transition: all .3s var(--ease);
}
.filter-bar button:hover { border-color: var(--stone); color: var(--ink); }
.filter-bar button.active { background: var(--ink); color: var(--paper); border-color: var(--ink); }

/* ---------- About ---------- */
.about-grid {
  display: grid; grid-template-columns: 2fr 3fr; gap: clamp(2.5rem, 6vw, 5rem);
  align-items: center;
}
.about-portrait img { width: 100%; aspect-ratio: 1/1; object-fit: cover; }
.about-text h1 { font-size: clamp(2.4rem, 5vw, 4rem); margin-bottom: 1.5rem; }
.about-text p { color: var(--charcoal); margin-bottom: 1.4rem; font-size: 1.1rem; }

/* ---------- Glossary ---------- */
.alpha-nav {
  display: flex; flex-wrap: wrap; gap: .3rem; justify-content: center;
  margin-bottom: clamp(2.5rem, 5vw, 4rem);
}
.alpha-nav a {
  font-family: var(--serif); font-size: 1.15rem; width: 42px; height: 42px;
  display: flex; align-items: center; justify-content: center;
  border: 1px solid var(--line); color: var(--slate); transition: all .3s var(--ease);
}
.alpha-nav a:hover { background: var(--gold); color: var(--white); border-color: var(--gold); }
.alpha-nav a.empty { opacity: .3; pointer-events: none; }

.glossary-group { margin-bottom: clamp(2.5rem, 5vw, 4rem); scroll-margin-top: 120px; }
.glossary-letter {
  font-family: var(--serif); font-size: 3rem; color: var(--gold);
  border-bottom: 1px solid var(--line); padding-bottom: .5rem; margin-bottom: 1.5rem;
}
.glossary-list { list-style: none; }
.glossary-list li { padding: 1.2rem 0; border-bottom: 1px solid var(--line); }
.glossary-list .term { font-family: var(--serif); font-size: 1.5rem; color: var(--ink); }
.glossary-list .term a:hover { color: var(--gold); }
.glossary-list .desc { font-size: .95rem; color: var(--slate); margin-top: .3rem; }
.glossary-list .tag { font-size: .68rem; letter-spacing: .16em; text-transform: uppercase; color: var(--gold); }

/* ---------- Contact ---------- */
.contact-grid { display: grid; grid-template-columns: 1fr 1fr; gap: clamp(2.5rem, 6vw, 5rem); }
.form-field { margin-bottom: 1.6rem; }
.form-field label {
  display: block; font-size: .72rem; letter-spacing: .16em; text-transform: uppercase;
  color: var(--slate); margin-bottom: .6rem;
}
.form-field input, .form-field textarea {
  width: 100%; padding: .9rem 1rem; border: 1px solid var(--line); background: var(--white);
  font-family: var(--sans); font-size: 1rem; color: var(--ink); transition: border-color .3s var(--ease);
}
.form-field input:focus, .form-field textarea:focus { outline: none; border-color: var(--gold); }
.form-field textarea { resize: vertical; min-height: 150px; }
.form-note { font-size: .85rem; color: var(--stone); margin-top: 1rem; }

/* ---------- Footer ---------- */
.site-footer {
  background: var(--ink); color: var(--cream); padding: clamp(3.5rem, 7vw, 6rem) 0 2.5rem;
  margin-top: clamp(4rem, 8vw, 7rem);
}
.footer-top { display: grid; grid-template-columns: 2fr 1fr 1fr; gap: 2.5rem; margin-bottom: 3.5rem; }
.footer-brand .logo { font-family: var(--serif); font-size: 1.8rem; color: var(--white); margin-bottom: 1rem; }
.footer-brand p { color: var(--mist); font-size: .95rem; max-width: 320px; }
.footer-col h4 { font-family: var(--sans); font-size: .72rem; letter-spacing: .2em; text-transform: uppercase; color: var(--gold-soft); margin-bottom: 1.2rem; font-weight: 500; }
.footer-col ul { list-style: none; }
.footer-col li { margin-bottom: .8rem; }
.footer-col a { color: var(--mist); font-size: .95rem; }
.footer-col a:hover { color: var(--white); }
.footer-bottom {
  border-top: 1px solid rgba(255,255,255,.12); padding-top: 2rem;
  display: flex; justify-content: space-between; flex-wrap: wrap; gap: 1rem;
  font-size: .8rem; color: var(--stone); letter-spacing: .05em;
}

/* ---------- Reveal animation ---------- */
.reveal { opacity: 0; transform: translateY(24px); transition: opacity .9s var(--ease), transform .9s var(--ease); }
.reveal.in { opacity: 1; transform: none; }

/* ---------- Responsive ---------- */
@media (max-width: 960px) {
  .grid { grid-template-columns: repeat(2, 1fr); }
  .featured { grid-template-columns: 1fr; }
  .featured-media { order: -1; }
  .about-grid, .contact-grid { grid-template-columns: 1fr; }
  .footer-top { grid-template-columns: 1fr 1fr; }
  .footer-brand { grid-column: 1 / -1; }
}
@media (max-width: 680px) {
  body { font-size: 16px; }
  .nav-links {
    position: fixed; top: 84px; left: 0; right: 0;
    background: var(--paper); flex-direction: column; gap: 0;
    padding: 1rem var(--gutter) 2rem; border-bottom: 1px solid var(--line);
    transform: translateY(-120%); transition: transform .4s var(--ease); z-index: 99;
  }
  .nav-links.open { transform: translateY(0); }
  .nav-links li { width: 100%; border-bottom: 1px solid var(--line); }
  .nav-links a { display: block; padding: 1.1rem 0; font-size: .9rem; }
  .nav-toggle { display: block; }
  .grid { grid-template-columns: 1fr; }
  .post-nav { grid-template-columns: 1fr; }
  .post-nav .next { text-align: left; }
  .footer-top { grid-template-columns: 1fr; }
}
