/* bargafzar.ir — company page. No JavaScript, no inline styles (CSP). */

/* Vazirmatn, self-hosted (same files as the Darabarg WordPress theme). */
@font-face {
  font-family: "Vazirmatn";
  font-weight: 400;
  font-display: swap;
  src: url("/fonts/vazirmatn-arabic-400.woff2") format("woff2");
  unicode-range: U+0600-06FF, U+0750-077F, U+08A0-08FF, U+FB50-FDFF, U+FE70-FEFF, U+200C-200D, U+2010-2011;
}
@font-face {
  font-family: "Vazirmatn";
  font-weight: 400;
  font-display: swap;
  src: url("/fonts/vazirmatn-latin-400.woff2") format("woff2");
}
@font-face {
  font-family: "Vazirmatn";
  font-weight: 500;
  font-display: swap;
  src: url("/fonts/vazirmatn-arabic-500.woff2") format("woff2");
  unicode-range: U+0600-06FF, U+0750-077F, U+08A0-08FF, U+FB50-FDFF, U+FE70-FEFF, U+200C-200D, U+2010-2011;
}
@font-face {
  font-family: "Vazirmatn";
  font-weight: 500;
  font-display: swap;
  src: url("/fonts/vazirmatn-latin-500.woff2") format("woff2");
}
@font-face {
  font-family: "Vazirmatn";
  font-weight: 700;
  font-display: swap;
  src: url("/fonts/vazirmatn-arabic-700.woff2") format("woff2");
  unicode-range: U+0600-06FF, U+0750-077F, U+08A0-08FF, U+FB50-FDFF, U+FE70-FEFF, U+200C-200D, U+2010-2011;
}
@font-face {
  font-family: "Vazirmatn";
  font-weight: 700;
  font-display: swap;
  src: url("/fonts/vazirmatn-latin-700.woff2") format("woff2");
}

/* ---- Tokens: Bargafzar green (the logo); Darabarg blue only on its own product ---- */
:root {
  --bg: #ffffff;
  --bg-alt: #f4f8f5;
  --surface: #ffffff;
  --ink: #132219;
  --text: #2d3b32;
  --muted: #5c6d62;
  --line: #e0eae3;

  --brand: #2e7d46;
  --brand-strong: #22663a;
  --brand-soft: #e7f5eb;
  --accent: #45a85f;
  --on-brand: #ffffff;

  --product: #1565c0;
  --product-strong: #0d47a1;

  --shadow: 0 1px 2px rgba(19, 34, 25, .06), 0 12px 32px -12px rgba(19, 34, 25, .18);
  --radius: 16px;
  --hero-glow: radial-gradient(60% 80% at 15% 20%, rgba(69, 168, 95, .16), transparent 70%),
               radial-gradient(50% 60% at 90% 0%, rgba(21, 101, 192, .10), transparent 70%);
}

@media (prefers-color-scheme: dark) {
  :root {
    --bg: #0e1511;
    --bg-alt: #121c16;
    --surface: #17221b;
    --ink: #eef5f0;
    --text: #d4e0d8;
    --muted: #94a89b;
    --line: #26362c;

    --brand: #6fcf86;
    --brand-strong: #96e0a8;
    --brand-soft: #173222;
    --accent: #5fbf77;
    --on-brand: #0b2414;

    --product: #64b5f6;
    --product-strong: #90caf9;

    --shadow: 0 1px 2px rgba(0, 0, 0, .3), 0 16px 40px -16px rgba(0, 0, 0, .6);
    --hero-glow: radial-gradient(60% 80% at 15% 20%, rgba(111, 207, 134, .12), transparent 70%),
                 radial-gradient(50% 60% at 90% 0%, rgba(100, 181, 246, .08), transparent 70%);
  }
}

/* ---- Base ---- */
* { box-sizing: border-box; }
html { scroll-behavior: smooth; scroll-padding-top: 5rem; }

body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font: 400 1rem/1.9 "Vazirmatn", Tahoma, sans-serif;
  -webkit-font-smoothing: antialiased;
}

h1, h2, h3 { color: var(--ink); line-height: 1.4; margin: 0; }
h1 { font-size: clamp(1.9rem, 1.2rem + 3vw, 3rem); font-weight: 700; }
h2 { font-size: clamp(1.5rem, 1.1rem + 1.6vw, 2.1rem); font-weight: 700; margin-bottom: 1.5rem; }
h3 { font-size: 1.4rem; font-weight: 700; }
p { margin: 0 0 1rem; }
a { color: var(--brand); }
a:hover { color: var(--brand-strong); }

.container { width: min(72rem, 100% - 2rem); margin-inline: auto; }

.eyebrow {
  display: inline-block;
  margin-bottom: .75rem;
  padding: .15rem .8rem;
  border-radius: 999px;
  background: var(--brand-soft);
  color: var(--brand);
  font-size: .85rem;
  font-weight: 500;
}

/* ---- Buttons ---- */
.actions { display: flex; flex-wrap: wrap; gap: .75rem; margin-top: 1.75rem; }

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 2.9rem;
  padding: .5rem 1.4rem;
  border-radius: 10px;
  border: 1px solid transparent;
  font-weight: 700;
  text-decoration: none;
  transition: background-color .15s, border-color .15s, color .15s, transform .15s;
}
.btn:hover { transform: translateY(-1px); }
.btn:focus-visible, .nav a:focus-visible, .brand:focus-visible {
  outline: 3px solid var(--accent);
  outline-offset: 2px;
}

.btn-primary { background: var(--brand); color: var(--on-brand); }
.btn-primary:hover { background: var(--brand-strong); color: var(--on-brand); }

.btn-product { background: var(--product); color: var(--on-brand); }
.btn-product:hover { background: var(--product-strong); color: var(--on-brand); }

.btn-ghost { border-color: var(--line); color: var(--ink); background: var(--surface); }
.btn-ghost:hover { border-color: var(--brand); color: var(--brand); }

.btn-light { background: #ffffff; color: #22663a; }
.btn-light:hover { background: #e7f5eb; color: #1a512e; }

/* ---- Header ---- */
.site-header {
  position: sticky;
  top: 0;
  z-index: 10;
  background: color-mix(in srgb, var(--bg) 85%, transparent);
  backdrop-filter: saturate(1.4) blur(10px);
  border-bottom: 1px solid var(--line);
}
.header-row { display: flex; align-items: center; justify-content: space-between; min-height: 4.25rem; }

.brand { display: inline-flex; align-items: center; gap: .6rem; text-decoration: none; border-radius: 10px; }
.brand-mark { width: 2.6rem; height: 2.6rem; }
.brand-name { color: var(--ink); font-size: 1.3rem; font-weight: 700; }

.nav { display: flex; gap: .25rem; }
.nav a {
  padding: .35rem .8rem;
  border-radius: 8px;
  color: var(--muted);
  font-weight: 500;
  text-decoration: none;
  white-space: nowrap;
}
.nav a:hover { color: var(--brand); background: var(--brand-soft); }

/* ---- Hero ---- */
.hero { background: var(--hero-glow); padding: clamp(3rem, 2rem + 5vw, 6rem) 0; overflow: hidden; }
.hero-grid { display: grid; grid-template-columns: 1.15fr 1fr; gap: 3rem; align-items: center; }
.lead { font-size: clamp(1.05rem, 1rem + .35vw, 1.2rem); color: var(--muted); margin-top: 1.25rem; max-width: 36rem; }
.lead strong { color: var(--ink); }

.hero-visual { position: relative; display: flex; justify-content: center; padding: 1.5rem; }

.hero-logo {
  position: relative;
  z-index: 1;
  display: grid;
  place-items: center;
  width: min(100%, 20rem);
  aspect-ratio: 1;
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: 28px;
  box-shadow: var(--shadow);
}
.hero-logo img { width: 72%; height: auto; }

/* Leaf shapes behind the logo card. */
.leaf { position: absolute; border-radius: 0 70% 0 70%; background: linear-gradient(135deg, var(--accent), var(--brand)); opacity: .18; }
.leaf-a { width: 11rem; height: 11rem; inset-block-start: -1rem; inset-inline-start: 0; transform: rotate(8deg); }
.leaf-b { width: 7rem; height: 7rem; inset-block-end: -.5rem; inset-inline-end: 1rem; transform: rotate(-20deg); opacity: .12; }

/* ---- Sections ---- */
.section { padding: clamp(3rem, 2rem + 4vw, 5.5rem) 0; }
.section-alt { background: var(--bg-alt); border-block: 1px solid var(--line); }

/* ---- Services ---- */
.services { display: grid; grid-template-columns: repeat(3, 1fr); gap: 1.25rem; }
.service {
  padding: 1.6rem;
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  transition: border-color .15s, box-shadow .15s;
}
.service:hover { border-color: color-mix(in srgb, var(--brand) 40%, var(--line)); box-shadow: var(--shadow); }
.service h3 { font-size: 1.15rem; margin: 1rem 0 .4rem; }
.service p { margin: 0; color: var(--muted); font-size: .95rem; line-height: 1.8; }
.service-icon {
  display: grid;
  place-items: center;
  width: 2.75rem;
  height: 2.75rem;
  border-radius: 12px;
  background: var(--brand-soft);
  color: var(--brand);
}
.service-icon svg { width: 1.4rem; height: 1.4rem; fill: none; stroke: currentColor; stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; }

/* ---- Product ---- */
.product {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 2.5rem;
  padding: clamp(1.5rem, 1rem + 2vw, 2.5rem);
  background: var(--surface);
  border: 1px solid var(--line);
  border-top: 4px solid var(--product);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
}
.product-head { display: flex; align-items: center; gap: 1rem; margin-bottom: 1.25rem; }
.product-head img { border-radius: 14px; }
.product-tagline { margin: .15rem 0 0; color: var(--product); font-weight: 500; }

.features { list-style: none; margin: 0; padding: 0; display: grid; gap: 1.1rem; }
.features li { display: flex; gap: .9rem; align-items: flex-start; }
.features strong { display: block; color: var(--ink); line-height: 1.6; }
.features span:not(.feature-icon) { display: block; color: var(--muted); font-size: .93rem; line-height: 1.75; }

.feature-icon {
  flex: none;
  display: grid;
  place-items: center;
  width: 2.5rem;
  height: 2.5rem;
  border-radius: 10px;
  background: color-mix(in srgb, var(--product) 12%, transparent);
  color: var(--product);
}
.feature-icon svg { width: 1.3rem; height: 1.3rem; fill: none; stroke: currentColor; stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; }

/* ---- About ---- */
.about-grid { display: grid; grid-template-columns: 1.3fr 1fr; gap: 3rem; align-items: center; }
.about-grid p { color: var(--muted); font-size: 1.05rem; max-width: 34rem; }
.about-title { display: flex; align-items: center; gap: 1rem; margin-bottom: 1.25rem; }
.about-title img { width: 4.5rem; height: 4.5rem; }
.about-title h2 { margin: 0; }

.facts { margin: 0; display: grid; gap: .75rem; }
.facts div {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 1rem;
  padding: .9rem 1.2rem;
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: 12px;
}
.facts dt { color: var(--muted); }
.facts dd { margin: 0; color: var(--ink); font-weight: 700; letter-spacing: .03em; }
.facts dd a { text-decoration: none; }

/* ---- Contact ---- */
.cta {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 2rem;
  padding: clamp(1.75rem, 1rem + 3vw, 3rem);
  border-radius: calc(var(--radius) + 4px);
  background: linear-gradient(135deg, #1a512e 0%, #2e7d46 55%, #45a85f 140%);
  color: #e7f5eb;
}
.cta h2 { color: #ffffff; margin-bottom: .5rem; }
.cta p { margin: 0; }

/* ---- Footer ---- */
.site-footer { padding: 2rem 0 2.5rem; border-top: 1px solid var(--line); color: var(--muted); font-size: .9rem; }
.footer-row p { margin: 0 0 .5rem; }
.footer-row .latin { font-size: .8rem; line-height: 1.6; text-align: left; }

/* ---- Responsive ---- */
@media (max-width: 56rem) {
  .hero-grid, .product, .about-grid, .services { grid-template-columns: 1fr; }
  .hero-visual { order: -1; padding: .5rem 1.5rem 1rem; }
  .hero-logo { width: min(100%, 11rem); border-radius: 22px; }
  .cta { flex-direction: column; align-items: flex-start; }
}

@media (max-width: 36rem) {
  .nav { gap: 0; }
  .nav a { padding: .3rem .4rem; font-size: .85rem; }
  .brand { gap: .4rem; }
  .brand-mark { width: 2.2rem; height: 2.2rem; }
  .brand-name { font-size: 1.05rem; }
  .actions .btn { flex: 1 1 100%; }
  .facts div { flex-direction: column; align-items: flex-start; gap: .1rem; }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .btn { transition: none; }
  .btn:hover { transform: none; }
}
