@import url('https://cdn.jsdelivr.net/gh/rastikerdar/vazirmatn@v33.003/Vazirmatn-font-face.css');

:root {
  --ink: #101216;
  --surface: #1A1D22;
  --surface-2: #23262C;
  --chalk: #F2F0EA;
  --chalk-dim: #9CA1AA;
  --ember: #FF4B26;
  --ember-2: #FF7A3D;
  --ember-dim: #7A2A19;
  --steel: #8A8F98;
  --line: #2C3038;
  --radius: 6px;
  --radius-lg: 14px;
  --container: 1180px;
  --shadow-sm: 0 2px 8px rgba(0,0,0,.25);
  --shadow-md: 0 8px 28px rgba(0,0,0,.35);
  --shadow-glow: 0 0 0 1px rgba(255,75,38,.15), 0 8px 24px rgba(255,75,38,.08);
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }

body {
  margin: 0;
  background: var(--ink);
  color: var(--chalk);
  font-family: 'Vazirmatn', Tahoma, sans-serif;
  direction: rtl;
  line-height: 1.85;
  font-size: 16px;
  -webkit-font-smoothing: antialiased;
}

img { max-width: 100%; display: block; }
a { color: inherit; text-decoration: none; transition: color .2s ease; }

h1, h2, h3, h4 {
  font-family: 'Vazirmatn', Tahoma, sans-serif;
  font-weight: 800;
  letter-spacing: -0.015em;
  margin: 0 0 .5em;
  color: var(--chalk);
}
h2 { font-size: clamp(24px, 3.2vw, 34px); }

.container {
  max-width: var(--container);
  margin: 0 auto;
  padding: 0 24px;
}

/* ===== Header ===== */
.site-header {
  position: sticky;
  top: 0;
  z-index: 100;
  background: rgba(16,18,22,.85);
  backdrop-filter: blur(12px) saturate(140%);
  border-bottom: 1px solid var(--line);
}
.site-header .container {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 76px;
}
.logo {
  font-size: 21px;
  font-weight: 800;
  display: flex;
  align-items: center;
  gap: 10px;
  letter-spacing: -.01em;
}
.logo span.mark {
  width: 11px; height: 26px;
  background: linear-gradient(180deg, var(--ember-2), var(--ember));
  display: inline-block;
  transform: skewX(-12deg);
  border-radius: 2px;
  box-shadow: 0 0 14px rgba(255,75,38,.5);
}
.nav-links {
  display: flex;
  gap: 30px;
  list-style: none;
  margin: 0; padding: 0;
  font-size: 14px;
  font-weight: 600;
}
.nav-links a { color: var(--chalk-dim); transition: color .2s; position: relative; display: inline-block; padding-bottom: 4px; }
.nav-links a::after {
  content: ''; position: absolute; right: 0; bottom: 0; width: 0; height: 2px;
  background: var(--ember); transition: width .25s ease;
}
.nav-links a:hover, .nav-links a.active { color: var(--chalk); }
.nav-links a.active::after, .nav-links a:hover::after { width: 100%; }
.header-actions { display: flex; align-items: center; gap: 12px; }
.nav-toggle { display: none; background: none; border: none; color: var(--chalk); font-size: 24px; cursor: pointer; }

/* ===== Buttons ===== */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 14px 28px;
  border-radius: var(--radius);
  font-weight: 700;
  font-size: 14px;
  border: none;
  cursor: pointer;
  transition: transform .18s ease, box-shadow .25s ease, background .25s, border-color .2s, color .2s;
}
.btn-primary {
  background: linear-gradient(135deg, var(--ember-2), var(--ember));
  color: #14161A;
  box-shadow: 0 6px 20px rgba(255,75,38,.28);
}
.btn-primary:hover { transform: translateY(-2px); box-shadow: 0 10px 28px rgba(255,75,38,.4); }
.btn-primary:active { transform: translateY(0); }
.btn-outline { background: transparent; color: var(--chalk); border: 1.5px solid var(--line); }
.btn-outline:hover { border-color: var(--ember); color: var(--ember); background: rgba(255,75,38,.06); }
.btn-sm { padding: 10px 20px; font-size: 13px; }
.btn-block { width: 100%; }

/* ===== Hero (diagonal plate signature) ===== */
.hero {
  position: relative;
  padding: 100px 0 140px;
  overflow: hidden;
  background:
    radial-gradient(circle at 85% 20%, rgba(255,75,38,.14), transparent 45%),
    var(--ink);
}
.hero-eyebrow {
  color: var(--ember);
  font-weight: 700;
  font-size: 13px;
  letter-spacing: .12em;
  margin-bottom: 14px;
  display: flex; align-items: center; gap: 10px;
}
.hero-eyebrow::before { content: ''; width: 28px; height: 2px; background: var(--ember); }
.hero h1 {
  font-size: clamp(34px, 6vw, 62px);
  line-height: 1.15;
  max-width: 800px;
}
.hero p.lead {
  color: var(--chalk-dim);
  font-size: 18px;
  max-width: 560px;
  margin: 18px 0 34px;
}
.hero-actions { display: flex; gap: 16px; flex-wrap: wrap; }

/* diagonal plate divider - the signature element */
.plate-divider {
  position: relative;
  height: 90px;
  background: var(--surface);
  clip-path: polygon(0 100%, 100% 40%, 100% 100%);
}
.plate-divider.flip {
  clip-path: polygon(0 40%, 100% 100%, 0 100%);
}

/* ===== Stats strip (rep-counter feel) ===== */
.stats-strip {
  background: var(--surface);
  border-top: 1px solid var(--line);
  border-bottom: 1px solid var(--line);
  padding: 46px 0;
}
.stats-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  text-align: center;
}
.stats-grid div + div { border-right: 1px solid var(--line); }
.stat-num {
  font-size: 40px;
  font-weight: 800;
  color: var(--ember);
  font-variant-numeric: tabular-nums;
}
.stat-label { color: var(--chalk-dim); font-size: 13px; margin-top: 6px; }

/* ===== Section ===== */
.section { padding: 90px 0; }
.section-head { margin-bottom: 48px; max-width: 620px; }
.section-eyebrow {
  color: var(--ember); font-weight: 700; font-size: 12px; letter-spacing: .12em; margin-bottom: 10px;
}
.section-head p { color: var(--chalk-dim); }

.grid-3 { display: grid; grid-template-columns: repeat(3, 1fr); gap: 24px; }
.grid-2 { display: grid; grid-template-columns: repeat(2, 1fr); gap: 24px; }
.grid-4 { display: grid; grid-template-columns: repeat(4, 1fr); gap: 20px; }

/* Card */
.card {
  background: linear-gradient(180deg, var(--surface), var(--surface) 60%, var(--surface-2));
  border: 1px solid var(--line);
  border-radius: var(--radius-lg);
  padding: 28px;
  transition: border-color .25s, transform .25s, box-shadow .25s;
  box-shadow: var(--shadow-sm);
}
.card:hover { border-color: var(--ember-dim); transform: translateY(-5px); box-shadow: var(--shadow-glow); }
.card h3 { font-size: 18px; margin-bottom: 8px; }
.card p { color: var(--chalk-dim); font-size: 14px; margin: 0; }

/* Product card */
.product-card {
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius-lg);
  overflow: hidden;
  display: flex; flex-direction: column;
  transition: transform .25s, box-shadow .25s, border-color .25s;
  box-shadow: var(--shadow-sm);
}
.product-card:hover { transform: translateY(-5px); box-shadow: var(--shadow-md); border-color: var(--ember-dim); }
.product-media {
  aspect-ratio: 1/1;
  background: var(--surface-2);
  display: flex; align-items: center; justify-content: center;
  color: var(--steel);
  font-size: 13px;
  overflow: hidden;
}
.product-media img { width: 100%; height: 100%; object-fit: cover; }
.product-body { padding: 18px; flex: 1; display: flex; flex-direction: column; gap: 8px; }
.product-cat { color: var(--ember); font-size: 11px; font-weight: 700; letter-spacing: .06em; }
.product-price { font-weight: 800; font-size: 18px; margin-top: auto; }
.stock-badge { font-size: 12px; color: var(--steel); }

/* Media (podcast/video) card */
.media-card { display: flex; gap: 16px; background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); padding: 16px; }
.media-thumb { width: 96px; height: 96px; background: var(--surface-2); border-radius: var(--radius); flex-shrink: 0; display:flex; align-items:center; justify-content:center; color: var(--ember); font-size: 22px; }
.media-info h3 { font-size: 16px; margin-bottom: 4px; }
.media-info p { color: var(--chalk-dim); font-size: 13px; margin: 0 0 8px; }
.media-meta { color: var(--steel); font-size: 12px; }

/* ===== Forms ===== */
.form-card {
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 36px;
  max-width: 560px;
  margin: 0 auto;
}
.field { margin-bottom: 18px; }
.field label { display: block; font-size: 13px; font-weight: 700; margin-bottom: 8px; color: var(--chalk-dim); }
.field input, .field select, .field textarea {
  width: 100%;
  background: var(--ink);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 12px 14px;
  color: var(--chalk);
  font-family: inherit;
  font-size: 14px;
}
.field input:focus, .field select:focus, .field textarea:focus {
  outline: none; border-color: var(--ember);
}
.field-row { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; }
.form-error {
  background: rgba(255,75,38,.1);
  border: 1px solid var(--ember-dim);
  color: #ffb3a3;
  padding: 12px 16px;
  border-radius: var(--radius);
  font-size: 14px;
  margin-bottom: 18px;
}
.form-success {
  background: rgba(43,138,99,.12);
  border: 1px solid #2B8A63;
  color: #a6e8cb;
  padding: 12px 16px;
  border-radius: var(--radius);
  font-size: 14px;
  margin-bottom: 18px;
}

/* ===== Table (cart / admin) ===== */
table.plain { width: 100%; border-collapse: collapse; }
table.plain th, table.plain td { padding: 14px; text-align: right; border-bottom: 1px solid var(--line); font-size: 14px; }
table.plain th { color: var(--chalk-dim); font-weight: 700; font-size: 12px; text-transform: uppercase; letter-spacing: .04em; }

/* ===== Footer ===== */
.site-footer { background: var(--surface); border-top: 1px solid var(--line); padding: 64px 0 32px; margin-top: 60px; }
.footer-grid { display: grid; grid-template-columns: 2fr 1fr 1fr 1fr; gap: 32px; margin-bottom: 40px; }
.footer-grid h4 { font-size: 14px; color: var(--chalk-dim); margin-bottom: 14px; }
.footer-grid ul { list-style: none; padding: 0; margin: 0; display: flex; flex-direction: column; gap: 10px; font-size: 14px; }
.footer-grid ul a:hover { color: var(--ember); }
.social-row { display: flex; gap: 12px; margin-top: 14px; }
.social-row a {
  width: 38px; height: 38px; border-radius: var(--radius);
  border: 1px solid var(--line);
  display: flex; align-items: center; justify-content: center;
  font-size: 15px;
}
.social-row a:hover { border-color: var(--ember); color: var(--ember); }
.footer-bottom {
  border-top: 1px solid var(--line);
  padding-top: 24px;
  color: var(--steel);
  font-size: 13px;
  display: flex; justify-content: space-between; flex-wrap: wrap; gap: 10px;
}

/* ===== Utilities ===== */
.text-center { text-align: center; }
.mt-0 { margin-top: 0; }
.badge { display: inline-block; padding: 4px 10px; border-radius: 20px; font-size: 12px; background: var(--surface-2); color: var(--chalk-dim); }
.badge-ember { background: rgba(255,75,38,.14); color: var(--ember); }

/* ===== Responsive ===== */
@media (max-width: 900px) {
  .grid-3, .grid-4 { grid-template-columns: repeat(2, 1fr); }
  .footer-grid { grid-template-columns: 1fr 1fr; }
  .stats-grid { grid-template-columns: repeat(2, 1fr); }
  .stats-grid div:nth-child(2) { border-right: none; }
}
@media (max-width: 640px) {
  .nav-links, .header-actions .btn-outline { display: none; }
  .nav-toggle { display: block; }
  .grid-3, .grid-4, .grid-2, .field-row { grid-template-columns: 1fr; }
  .footer-grid { grid-template-columns: 1fr; }
  .stats-grid { grid-template-columns: 1fr 1fr; }
  .hero { padding: 70px 0 90px; }
}

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

/* Visible focus for accessibility */
a:focus-visible, button:focus-visible, input:focus-visible, select:focus-visible, textarea:focus-visible {
  outline: 2px solid var(--ember);
  outline-offset: 2px;
}

/* ===== Scroll reveal (progressive enhancement — nothing hides if JS fails) ===== */
body.js-reveal-ready .card,
body.js-reveal-ready .product-card,
body.js-reveal-ready .form-card,
body.js-reveal-ready .section-head,
body.js-reveal-ready .media-card {
  opacity: 0;
  transform: translateY(18px);
  transition: opacity .6s ease, transform .6s ease;
}
body.js-reveal-ready .is-visible {
  opacity: 1 !important;
  transform: translateY(0) !important;
}
@media (prefers-reduced-motion: reduce) {
  body.js-reveal-ready .card, body.js-reveal-ready .product-card,
  body.js-reveal-ready .form-card, body.js-reveal-ready .section-head,
  body.js-reveal-ready .media-card { opacity: 1; transform: none; transition: none; }
}

/* Floating WhatsApp button */
.float-whatsapp {
  position: fixed;
  bottom: 22px;
  left: 22px;
  z-index: 200;
  width: 58px; height: 58px;
  border-radius: 50%;
  background: linear-gradient(135deg, #25D366, #1DA851);
  display: flex; align-items: center; justify-content: center;
  font-size: 28px;
  box-shadow: 0 8px 24px rgba(37,211,102,.45);
  transition: transform .2s ease;
}
.float-whatsapp:hover { transform: scale(1.08); }
@media (max-width: 640px) {
  .float-whatsapp { width: 52px; height: 52px; font-size: 24px; bottom: 16px; left: 16px; }
}
