:root {
  --ink: #1a140c;
  --ink-soft: #3a3126;
  --teal: #0d3d38;
  --teal-deep: #082824;
  --foam: #fff6ea;
  --sand: #f3e4c8;
  --gold: #b8893a;
  --gold-bright: #e0b45a;
  --wine: #7a2e24;
  --line: rgba(26, 20, 12, 0.14);
  --max: 1180px;
  --serif: "Fraunces", "Noto Naskh Arabic", serif;
  --sans: "Vazirmatn", "Tahoma", sans-serif;
}

*,
*::before,
*::after {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

html[lang="fa"] {
  direction: rtl;
}

body {
  margin: 0;
  color: var(--ink);
  font-family: var(--sans);
  font-size: 1.05rem;
  line-height: 1.9;
  background:
    radial-gradient(1200px 700px at 10% -10%, rgba(184, 137, 58, 0.18), transparent 55%),
    radial-gradient(900px 600px at 110% 8%, rgba(13, 61, 56, 0.16), transparent 50%),
    linear-gradient(180deg, #fff8ee 0%, #f6ead3 42%, #efe0c4 100%);
  background-attachment: fixed;
}

body::before {
  content: "";
  pointer-events: none;
  position: fixed;
  inset: 0;
  z-index: -1;
  opacity: 0.35;
  background-image: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' width='160' height='160'><path d='M0 80 Q40 20 80 80 T160 80' fill='none' stroke='%230d3d38' stroke-opacity='0.07' stroke-width='1.2'/><circle cx='20' cy='20' r='1.4' fill='%23b8893a' fill-opacity='0.25'/></svg>");
}

img {
  max-width: 100%;
  height: auto;
  display: block;
}

a {
  color: var(--teal);
  text-decoration-thickness: 1px;
  text-underline-offset: 0.22em;
}

a:hover {
  color: var(--wine);
}

.wrap {
  width: min(var(--max), calc(100% - 2.4rem));
  margin-inline: auto;
}

.skip {
  position: absolute;
  right: 1rem;
  top: -4rem;
  background: var(--ink);
  color: var(--foam);
  padding: 0.5rem 0.9rem;
}

.skip:focus {
  top: 0.8rem;
  z-index: 40;
}

.site-header {
  position: sticky;
  top: 0;
  z-index: 20;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  padding: 0.85rem 1.2rem;
  background: rgba(255, 246, 234, 0.82);
  backdrop-filter: blur(12px);
  border-bottom: 1px solid var(--line);
}

.brand {
  font-family: var(--serif);
  font-weight: 700;
  font-size: clamp(1.6rem, 3vw, 2.15rem);
  letter-spacing: 0.08em;
  color: var(--teal-deep);
  text-decoration: none;
  line-height: 1;
}

.brand span {
  display: block;
  font-family: var(--sans);
  font-size: 0.72rem;
  letter-spacing: 0.28em;
  color: var(--gold);
  margin-top: 0.15rem;
}

nav ul {
  display: flex;
  flex-wrap: wrap;
  gap: 0.35rem 1.1rem;
  list-style: none;
  margin: 0;
  padding: 0;
}

nav a {
  color: var(--ink);
  text-decoration: none;
  font-weight: 600;
  font-size: 0.95rem;
}

nav a:hover,
nav a[aria-current="page"] {
  color: var(--teal);
}

.cta,
.cta-ghost {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  border: 0;
  text-decoration: none;
  font-weight: 700;
  font-family: var(--sans);
  padding: 0.72rem 1.25rem;
  transition: transform 0.25s ease, background 0.25s ease, color 0.25s ease;
}

.cta {
  background: var(--teal);
  color: var(--foam);
  box-shadow: 0 10px 24px rgba(13, 61, 56, 0.22);
}

.cta:hover {
  background: var(--teal-deep);
  color: #fff;
  transform: translateY(-2px);
}

.cta-ghost {
  background: transparent;
  color: var(--foam);
  border: 1px solid rgba(255, 246, 234, 0.5);
}

.cta-ghost:hover {
  background: rgba(255, 246, 234, 0.12);
  color: #fff;
}

.hero {
  position: relative;
  min-height: 100svh;
  display: grid;
  align-items: end;
  overflow: hidden;
  color: var(--foam);
}

.hero img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center 18%;
  animation: drift 22s ease-in-out infinite alternate;
}

@keyframes drift {
  from { transform: scale(1); }
  to { transform: scale(1.07); }
}

.hero::after {
  content: "";
  position: absolute;
  inset: 0;
  background:
    linear-gradient(180deg, rgba(8, 40, 36, 0.18) 0%, rgba(8, 40, 36, 0.15) 38%, rgba(8, 40, 36, 0.78) 100%);
}

.hero-copy {
  position: relative;
  z-index: 1;
  padding: 0 1.2rem 4.5rem;
  width: min(var(--max), 100%);
  margin-inline: auto;
}

.hero-copy .brand-mark {
  font-family: var(--serif);
  font-size: clamp(3.4rem, 10vw, 7.4rem);
  letter-spacing: 0.06em;
  line-height: 0.9;
  margin: 0 0 0.8rem;
  text-shadow: 0 12px 40px rgba(0, 0, 0, 0.35);
}

.hero-copy h1 {
  font-size: clamp(1.25rem, 2.4vw, 1.85rem);
  font-weight: 700;
  max-width: 34ch;
  margin: 0 0 0.55rem;
}

.hero-copy p {
  margin: 0 0 1.4rem;
  max-width: 42ch;
  color: rgba(255, 246, 234, 0.88);
}

.hero-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 0.7rem;
}

.age-ribbon {
  background: var(--ink);
  color: var(--sand);
  text-align: center;
  font-size: 0.85rem;
  padding: 0.45rem 1rem;
}

.section {
  padding: 4.2rem 0 1.2rem;
}

.section h2 {
  font-family: var(--serif);
  font-weight: 650;
  font-size: clamp(1.7rem, 3vw, 2.45rem);
  line-height: 1.35;
  margin: 0 0 0.7rem;
  color: var(--teal-deep);
}

.lede {
  font-size: 1.12rem;
  color: var(--ink-soft);
  max-width: 62ch;
  margin: 0 0 1.6rem;
}

.article {
  max-width: 74ch;
}

.article p,
.article li {
  color: var(--ink-soft);
}

.article h2,
.article h3 {
  color: var(--teal-deep);
  font-family: var(--serif);
}

.article h3 {
  font-size: 1.35rem;
  margin-top: 2rem;
}

.figure {
  margin: 1.8rem 0 2.2rem;
}

.figure img {
  width: 100%;
  max-height: 520px;
  object-fit: cover;
  animation: rise 0.9s ease both;
}

@keyframes rise {
  from { opacity: 0; transform: translateY(18px); }
  to { opacity: 1; transform: none; }
}

.figure figcaption {
  font-size: 0.88rem;
  color: var(--ink-soft);
  padding-top: 0.45rem;
}

.mid-cta {
  margin: 2.4rem 0;
  padding: 1.4rem 0 0.2rem;
  border-top: 1px solid var(--line);
  border-bottom: 1px solid var(--line);
}

.blog-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(250px, 1fr));
  gap: 1.6rem 1.2rem;
  list-style: none;
  margin: 0;
  padding: 0;
}

.blog-grid a {
  text-decoration: none;
  color: inherit;
  display: block;
  cursor: pointer;
}

.blog-grid img {
  width: 100%;
  height: 180px;
  object-fit: cover;
  margin-bottom: 0.7rem;
  transition: transform 0.45s ease;
}

.blog-grid a:hover img {
  transform: scale(1.03);
}

.blog-grid h3 {
  font-size: 1.05rem;
  margin: 0 0 0.3rem;
  font-family: var(--serif);
  color: var(--teal-deep);
}

.blog-grid p {
  margin: 0;
  font-size: 0.92rem;
  color: var(--ink-soft);
}

.page-hero {
  padding: 3.2rem 0 0.4rem;
}

.page-hero h1 {
  font-family: var(--serif);
  font-size: clamp(1.9rem, 4vw, 3rem);
  margin: 0 0 0.6rem;
  color: var(--teal-deep);
}

.crumbs {
  font-size: 0.88rem;
  color: var(--ink-soft);
  margin-bottom: 0.8rem;
}

.site-footer {
  margin-top: 3.5rem;
  padding: 2.4rem 0 2.8rem;
  background: var(--teal-deep);
  color: var(--sand);
}

.site-footer a {
  color: var(--gold-bright);
}

.site-footer .wrap {
  display: grid;
  gap: 1.4rem;
}

.site-footer small {
  display: block;
  opacity: 0.85;
  line-height: 1.7;
}

@media (max-width: 720px) {
  .site-header {
    flex-wrap: wrap;
  }

  nav {
    order: 3;
    width: 100%;
  }

  .hero {
    min-height: 88svh;
  }

  .hero-copy {
    padding-bottom: 3rem;
  }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .hero img,
  .figure img,
  .blog-grid img {
    animation: none;
    transition: none;
  }
}
