:root {
  --ink: #241610;
  --ink-soft: #5c4638;
  --cream: #f4ecdf;
  --paper: #fffaf3;
  --pomegranate: #9b2335;
  --pomegranate-deep: #6e1524;
  --wine: #3d1018;
  --apricot: #e39b3a;
  --gold: #a67c3d;
  --herb: #2c5a43;
  --line: rgba(36, 22, 16, 0.12);
  --shadow: 0 18px 40px rgba(61, 16, 24, 0.08);
  --serif: "Cormorant Garamond", "Times New Roman", serif;
  --sans: "Manrope", "Segoe UI", sans-serif;
  --hy: "Noto Sans Armenian", "Manrope", sans-serif;
  --header: 76px;
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  color: var(--ink);
  background:
    radial-gradient(1200px 500px at 10% -10%, rgba(227, 155, 58, 0.16), transparent 50%),
    var(--cream);
  font-family: var(--sans);
  font-size: 17px;
  line-height: 1.65;
}
img, svg { display: block; max-width: 100%; }
a { color: var(--pomegranate-deep); }
a:hover { color: var(--pomegranate); }
button, input { font: inherit; }
h1, h2, h3 { font-family: var(--serif); font-weight: 600; line-height: 1.05; letter-spacing: -0.02em; }
p { margin: 0 0 1rem; }

.skip {
  position: absolute;
  left: 16px;
  top: -40px;
  background: var(--paper);
  padding: 8px 12px;
  z-index: 20;
}
.skip:focus { top: 12px; }

.wrap { width: min(1120px, calc(100% - 32px)); margin: 0 auto; }
.wrap-narrow { width: min(760px, calc(100% - 32px)); margin: 0 auto; }

.site-header {
  position: sticky;
  top: 0;
  z-index: 10;
  height: var(--header);
  display: flex;
  align-items: center;
  background: rgba(244, 236, 223, 0.92);
  backdrop-filter: blur(10px);
  border-bottom: 1px solid var(--line);
}
.header-inner { display: flex; align-items: center; justify-content: space-between; gap: 24px; width: min(1120px, calc(100% - 32px)); margin: 0 auto; }
.brand { display: flex; align-items: center; gap: 12px; color: var(--ink); text-decoration: none; }
.brand-mark { width: 42px; height: 42px; color: var(--pomegranate); }
.brand-name { font-family: var(--serif); font-size: 28px; line-height: 1; }
.brand-name small { display: block; margin-top: 2px; font-family: var(--hy); font-size: 12px; letter-spacing: 0.08em; color: var(--ink-soft); font-weight: 500; }
.nav { display: flex; gap: 22px; }
.nav a { color: var(--ink); text-decoration: none; font-weight: 600; font-size: 15px; }
.nav a[aria-current="page"] { color: var(--pomegranate-deep); box-shadow: inset 0 -2px 0 var(--apricot); }

.hero { padding: 28px 0 10px; }
.hero-frame {
  position: relative;
  overflow: hidden;
  color: #f8efe4;
  background:
    radial-gradient(500px 240px at 90% 0%, rgba(227, 155, 58, 0.28), transparent 55%),
    linear-gradient(160deg, #541722, var(--wine) 55%, #2a0c12);
  border-radius: 28px;
  padding: 56px 56px 48px;
  box-shadow: var(--shadow);
}
.hero-frame::before {
  content: "";
  position: absolute;
  inset: 14px;
  border: 1px solid rgba(227, 155, 58, 0.45);
  border-radius: 18px;
  pointer-events: none;
}
.hero-kicker, .eyebrow {
  margin: 0 0 12px;
  font-family: var(--hy);
  font-size: 15px;
  letter-spacing: 0.04em;
  color: var(--apricot);
}
.hero h1 { margin: 0; font-size: clamp(56px, 8vw, 92px); color: #fffaf3; }
.hero-lead { max-width: 38rem; margin: 18px 0 0; font-size: 18px; color: rgba(248, 239, 228, 0.88); }
.hero-actions { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 28px; }

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 46px;
  padding: 0 18px;
  border-radius: 999px;
  text-decoration: none;
  font-weight: 700;
  border: 1px solid transparent;
}
.btn-primary { background: var(--apricot); color: var(--wine); }
.btn-primary:hover { background: #f0b15a; color: var(--wine); }
.btn-ghost { background: transparent; color: #fffaf3; border-color: rgba(255, 250, 243, 0.4); }
.btn-ghost:hover { color: white; border-color: white; }
.btn-ink { background: var(--wine); color: #fffaf3; }
.btn-ink:hover { background: var(--pomegranate-deep); color: white; }

.carpet {
  height: 8px;
  margin: 28px 0;
  border-radius: 999px;
  background: repeating-linear-gradient(90deg, var(--pomegranate) 0 12px, var(--apricot) 12px 18px, var(--wine) 18px 30px, var(--herb) 30px 36px);
}

.section { padding: 10px 0 28px; }
.section-head { display: flex; justify-content: space-between; gap: 20px; align-items: end; margin-bottom: 18px; }
.section-head h2, .page-title h1 { margin: 0; font-size: clamp(36px, 5vw, 56px); }
.section-head p, .lede { color: var(--ink-soft); max-width: 40rem; }

.table-words { display: flex; flex-wrap: wrap; gap: 8px; margin: 8px 0 0; padding: 0; list-style: none; }
.table-words li {
  padding: 6px 12px;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: rgba(255, 250, 243, 0.7);
  font-size: 14px;
}

.cats, .cards, .related-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 16px; }
.cats { grid-template-columns: repeat(3, 1fr); }
.cat, .card, .related a, .glossary article, .author-card {
  background: var(--paper);
  border: 1px solid var(--line);
  border-radius: 18px;
  box-shadow: var(--shadow);
}
.cat { display: block; padding: 18px 18px 16px; color: inherit; text-decoration: none; min-height: 150px; }
.cat:hover, .card:hover { border-color: rgba(155, 35, 53, 0.35); }
.cat-no { font-variant-numeric: tabular-nums; color: var(--gold); font-size: 13px; font-weight: 700; }
.cat h3, .card h2 { margin: 8px 0 6px; font-size: 32px; }
.cat p, .card p { margin: 0; color: var(--ink-soft); font-size: 15px; }
.cat-hy { font-family: var(--hy); color: var(--pomegranate); }

.card { padding: 18px; display: flex; flex-direction: column; gap: 6px; color: inherit; text-decoration: none; }
.card h2 { font-size: 34px; }
.card-top { display: flex; justify-content: space-between; gap: 12px; align-items: center; }
.mark {
  width: 42px; height: 42px; border-radius: 50%;
  display: grid; place-items: center;
  background: var(--wine); color: var(--apricot);
  font-family: var(--hy); font-weight: 700;
}
.meta { color: var(--ink-soft); font-size: 13px; font-weight: 600; letter-spacing: 0.02em; }
.card .meta { margin-top: auto; padding-top: 8px; }

.page { padding: 28px 0 48px; }
.crumbs { display: flex; flex-wrap: wrap; gap: 6px; margin: 0 0 14px; color: var(--ink-soft); font-size: 14px; }
.crumbs a { color: var(--ink-soft); }
.page-title h1 { font-size: clamp(48px, 7vw, 76px); }
.hy-title { margin: 8px 0 0; font-family: var(--hy); color: var(--pomegranate); font-size: 20px; }
.chips { display: flex; flex-wrap: wrap; gap: 8px; margin: 18px 0; }
.chip, .pill {
  border: 1px solid var(--line);
  background: var(--paper);
  color: var(--ink);
  border-radius: 999px;
  padding: 8px 12px;
  text-decoration: none;
  font-size: 14px;
  font-weight: 650;
}
.chip[aria-pressed="true"], .pill { background: var(--wine); color: #fffaf3; border-color: var(--wine); }
button.chip { cursor: pointer; }

.toolbar { display: flex; flex-wrap: wrap; gap: 10px; align-items: center; margin: 18px 0; }
.search {
  flex: 1 1 240px;
  min-height: 46px;
  border-radius: 999px;
  border: 1px solid var(--line);
  background: var(--paper);
  padding: 0 16px;
  color: var(--ink);
}
.search:focus, .chip:focus-visible, a:focus-visible, button:focus-visible {
  outline: 2px solid var(--apricot);
  outline-offset: 2px;
}

.recipe-layout { display: grid; grid-template-columns: 300px 1fr; gap: 36px; align-items: start; margin-top: 12px; }
.ingredients {
  position: sticky;
  top: calc(var(--header) + 16px);
  background: var(--paper);
  border-radius: 18px;
  padding: 18px 18px 8px;
  border: 1px solid var(--line);
}
.ingredients h2, .steps h2 { font-size: 32px; margin: 0 0 10px; }
.ingredients ul, .steps ol { margin: 0; padding: 0; list-style: none; }
.ingredients li {
  display: grid;
  grid-template-columns: 92px 1fr;
  gap: 8px;
  padding: 8px 0;
  border-top: 1px solid var(--line);
}
.ingredients li span { color: var(--pomegranate-deep); font-weight: 700; font-size: 14px; }
.steps li { display: grid; grid-template-columns: 36px 1fr; gap: 12px; margin: 0 0 16px; }
.steps li b {
  width: 36px; height: 36px; border-radius: 50%;
  display: grid; place-items: center;
  background: var(--wine); color: var(--apricot); font-family: var(--serif); font-size: 18px;
}
.tip {
  margin-top: 8px;
  padding: 16px 18px;
  border-left: 4px solid var(--pomegranate);
  background: rgba(255, 250, 243, 0.8);
  border-radius: 0 16px 16px 0;
}
.tip strong { font-family: var(--serif); font-size: 24px; font-weight: 600; }

.prose p { font-size: 18px; }
.glossary { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; margin-top: 8px; }
.glossary article, .author-card { padding: 16px 18px; }
.glossary h3 { margin: 0 0 4px; font-size: 28px; }
.author-card { margin-top: 8px; }
.author-card a { font-weight: 700; }

.related { margin-top: 36px; }
.related h2 { font-size: 40px; margin-bottom: 12px; }
.related a { display: block; padding: 16px 18px; color: inherit; text-decoration: none; }
.related a span { color: var(--ink-soft); font-size: 13px; font-weight: 700; }
.related a strong { display: block; font-family: var(--serif); font-size: 28px; font-weight: 600; }

.empty {
  padding: 28px;
  border: 1px dashed var(--gold);
  border-radius: 18px;
  background: var(--paper);
}

.site-footer { margin-top: 20px; background: var(--wine); color: rgba(248, 239, 228, 0.86); padding: 36px 0 28px; }
.footer-grid { display: grid; grid-template-columns: 1.4fr 1fr; gap: 24px; }
.site-footer a { color: var(--apricot); }
.site-footer p { margin: 0 0 6px; }
.legal { font-size: 14px; color: rgba(248, 239, 228, 0.72); }

@media (max-width: 860px) {
  .cats, .cards, .related-grid, .glossary, .footer-grid, .recipe-layout { grid-template-columns: 1fr; }
  .hero-frame { padding: 36px 22px 28px; }
  .ingredients { position: static; }
  .section-head { display: block; }
}

@media (max-width: 520px) {
  .site-header { height: auto; }
  .header-inner { flex-wrap: wrap; padding: 12px 0; }
  .nav { width: 100%; gap: 18px; padding-bottom: 4px; }
  .nav a { white-space: nowrap; }
}

@media print {
  .site-header, .site-footer, .hero-actions, .related, .no-print { display: none !important; }
  body { background: white; }
  .hero-frame, .card, .ingredients { box-shadow: none; }
  a { color: black; text-decoration: none; }
}
