/* =========================================================
   Deebco Textiles — design tokens
   Background: charcoal night warehouse
   Accent: mustard gold (from logo) — used with restraint
   Signature: diagonal mesh/weave crosshatch + split panel
   echoing the wolf logo's solid/outline divide
   ========================================================= */

:root {
  --bg: #0b0d12;
  --bg-elevated: #10131b;
  --card: #151923;
  --card-hover: #1b202c;
  --line: rgba(240, 180, 41, 0.16);
  --line-soft: rgba(255, 255, 255, 0.06);

  --gold: #f0b429;
  --gold-soft: #f8d27a;
  --gold-dark: #a5760f;

  --ink: #f4f1e6;
  --muted: #97a0ae;
  --muted-2: #6c7482;

  --radius: 14px;
  --radius-sm: 8px;
  --shadow: 0 20px 50px rgba(0, 0, 0, 0.45);

  --font-display: "Cairo", "Tajawal", sans-serif;
  --font-body: "Tajawal", "Cairo", sans-serif;
}

* { box-sizing: border-box; }

html { scroll-behavior: smooth; }

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  * { animation-duration: 0.01ms !important; transition-duration: 0.01ms !important; }
}

body {
  margin: 0;
  background: var(--bg);
  color: var(--ink);
  font-family: var(--font-body);
  line-height: 1.6;
  position: relative;
  overflow-x: hidden;
}

a { color: inherit; text-decoration: none; }
h1, h2, h3 { font-family: var(--font-display); margin: 0; }
p { margin: 0; color: var(--muted); }
ul { list-style: none; margin: 0; padding: 0; }
img { max-width: 100%; display: block; }

:focus-visible {
  outline: 2px solid var(--gold);
  outline-offset: 3px;
}

/* ---------- signature texture: mesh crosshatch background ---------- */
.mesh-bg {
  position: fixed;
  inset: 0;
  z-index: 0;
  pointer-events: none;
  background-image:
    repeating-linear-gradient(45deg, rgba(240, 180, 41, 0.035) 0, rgba(240, 180, 41, 0.035) 1px, transparent 1px, transparent 14px),
    repeating-linear-gradient(-45deg, rgba(240, 180, 41, 0.035) 0, rgba(240, 180, 41, 0.035) 1px, transparent 1px, transparent 14px);
  mask-image: radial-gradient(ellipse 90% 60% at 50% 0%, black 40%, transparent 90%);
}

/* ================= header ================= */
.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  background: rgba(11, 13, 18, 0.85);
  backdrop-filter: blur(10px);
  border-bottom: 1px solid var(--line-soft);
}

.header-inner {
  max-width: 1180px;
  margin: 0 auto;
  padding: 14px 24px;
  display: flex;
  align-items: center;
  gap: 24px;
}

.brand {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-left: 8px;
}

.brand-logo {
  width: 42px;
  height: 42px;
  border-radius: 8px;
  object-fit: cover;
  border: 1px solid var(--line);
}

.brand-text { display: flex; flex-direction: column; line-height: 1.2; }
.brand-text strong { font-family: var(--font-display); font-weight: 800; font-size: 16px; }
.brand-text em { font-style: normal; font-size: 10.5px; letter-spacing: 2px; color: var(--muted-2); }

.main-nav {
  display: flex;
  align-items: center;
  gap: 22px;
  flex: 1;
  font-weight: 500;
  font-size: 14.5px;
}

.main-nav a { color: var(--muted); transition: color 0.2s; position: relative; padding: 4px 0; }
.main-nav a:hover, .main-nav a.active { color: var(--gold-soft); }
.main-nav a.active::after {
  content: "";
  position: absolute;
  right: 0; left: 0; bottom: -3px;
  height: 2px;
  background: var(--gold);
  border-radius: 2px;
}

.nav-whatsapp {
  background: var(--gold);
  color: #14140f;
  font-weight: 700;
  font-size: 14px;
  padding: 10px 18px;
  border-radius: 999px;
  white-space: nowrap;
  transition: transform 0.2s, box-shadow 0.2s;
}
.nav-whatsapp:hover { transform: translateY(-1px); box-shadow: 0 8px 20px rgba(240, 180, 41, 0.25); }

.nav-toggle {
  display: none;
  flex-direction: column;
  gap: 4px;
  background: none;
  border: none;
  cursor: pointer;
  padding: 6px;
}
.nav-toggle span { width: 22px; height: 2px; background: var(--ink); border-radius: 2px; }

/* ================= buttons ================= */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 13px 26px;
  border-radius: 999px;
  font-weight: 700;
  font-size: 15px;
  transition: transform 0.2s, box-shadow 0.2s, background 0.2s;
  cursor: pointer;
  border: 1px solid transparent;
}
.btn-gold { background: var(--gold); color: #14140f; }
.btn-gold:hover { transform: translateY(-2px); box-shadow: 0 12px 24px rgba(240, 180, 41, 0.28); }

.btn-ghost { border-color: var(--line); color: var(--ink); background: transparent; }
.btn-ghost:hover { border-color: var(--gold); color: var(--gold-soft); }

.btn-order {
  width: 100%;
  padding: 10px 16px;
  font-size: 13.5px;
  background: transparent;
  border: 1px solid var(--line);
  color: var(--gold-soft);
}
.btn-order:hover { background: var(--gold); color: #14140f; border-color: var(--gold); }

/* ================= hero ================= */
.hero {
  max-width: 1180px;
  margin: 0 auto;
  padding: 72px 24px 40px;
  display: grid;
  grid-template-columns: 1.1fr 0.9fr;
  gap: 48px;
  align-items: center;
  position: relative;
  z-index: 1;
}

.eyebrow {
  display: inline-block;
  font-size: 12.5px;
  font-weight: 700;
  letter-spacing: 1px;
  color: var(--gold-soft);
  border: 1px solid var(--line);
  padding: 6px 14px;
  border-radius: 999px;
  margin-bottom: 18px;
}

.hero-copy h1 {
  font-size: clamp(34px, 5vw, 54px);
  font-weight: 900;
  line-height: 1.15;
  margin-bottom: 16px;
}

.hero-tagline { font-size: 17px; max-width: 480px; margin-bottom: 30px; }
.hero-actions { display: flex; gap: 14px; flex-wrap: wrap; }

.hero-panel {
  position: relative;
  aspect-ratio: 1 / 1;
  border-radius: 24px;
  background:
    linear-gradient(135deg, rgba(240, 180, 41, 0.16), transparent 60%),
    var(--bg-elevated);
  border: 1px solid var(--line);
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 30px;
  overflow: hidden;
}
.hero-panel::before {
  /* split divider echoing the logo's solid/outline half-face */
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(115deg, rgba(240,180,41,0.10) 50%, transparent 50.4%);
}
.hero-panel-inner { position: relative; text-align: center; z-index: 1; }
.hero-logo {
  width: 150px;
  height: 150px;
  object-fit: cover;
  border-radius: 20px;
  margin: 0 auto 22px;
  box-shadow: var(--shadow);
  border: 2px solid var(--gold);
}
.hero-stats { display: flex; gap: 28px; justify-content: center; }
.hero-stats li { display: flex; flex-direction: column; align-items: center; }
.hero-stats strong { font-family: var(--font-display); font-size: 26px; color: var(--gold-soft); }
.hero-stats span { font-size: 12px; color: var(--muted); margin-top: 2px; }

/* ================= stats strip ================= */
.stats-strip {
  max-width: 1180px;
  margin: 20px auto 0;
  padding: 0 24px;
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 1px;
  background: var(--line-soft);
  border: 1px solid var(--line-soft);
  border-radius: var(--radius);
  overflow: hidden;
  position: relative;
  z-index: 1;
}
.stat-item {
  background: var(--bg-elevated);
  padding: 26px 18px;
  text-align: center;
}
.js .stat-item { opacity: 0; transform: translateY(10px); transition: opacity 0.5s, transform 0.5s; }
.js .stat-item.in-view { opacity: 1; transform: none; }
.stat-item strong { display: block; font-family: var(--font-display); font-size: 20px; color: var(--gold-soft); margin-bottom: 4px; }
.stat-item span { font-size: 12.5px; color: var(--muted); }

/* ================= section head ================= */
.section-head { max-width: 1180px; margin: 90px auto 30px; padding: 0 24px; position: relative; z-index: 1; }
.section-head h2 { font-size: clamp(24px, 3vw, 32px); font-weight: 800; }

/* ================= category grid (home) ================= */
.categories-section { position: relative; z-index: 1; }
.category-grid {
  max-width: 1180px;
  margin: 0 auto;
  padding: 0 24px 20px;
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
  gap: 20px;
}

.category-card {
  background: var(--card);
  border: 1px solid var(--line-soft);
  border-radius: var(--radius);
  padding: 24px;
  display: flex;
  flex-direction: column;
  gap: 12px;
  transition: transform 0.25s, border-color 0.25s, background 0.25s;
}
.js .category-card { opacity: 0; transform: translateY(14px); }
.js .category-card.in-view { opacity: 1; transform: none; }
.category-card:hover { transform: translateY(-4px); border-color: var(--gold); background: var(--card-hover); }

.category-swatch-row { display: flex; gap: 6px; }
.mini-swatch {
  width: 20px; height: 20px;
  border-radius: 5px;
  border: 1px solid rgba(255,255,255,0.12);
}

.category-card h3 { font-size: 18px; font-weight: 800; }
.category-card p { font-size: 13.5px; }
.category-cta { color: var(--gold-soft); font-size: 13px; font-weight: 700; margin-top: auto; }

/* ================= CTA band ================= */
.cta-band {
  max-width: 1180px;
  margin: 90px auto;
  padding: 56px 40px;
  text-align: center;
  background: linear-gradient(135deg, rgba(240,180,41,0.14), rgba(240,180,41,0.02));
  border: 1px solid var(--line);
  border-radius: 24px;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 16px;
  position: relative;
  z-index: 1;
}
.js .cta-band { opacity: 0; transform: translateY(14px); transition: opacity 0.6s, transform 0.6s; }
.js .cta-band.in-view { opacity: 1; transform: none; }
.cta-band h2 { font-size: clamp(22px, 3vw, 28px); max-width: 560px; }
.cta-band p { max-width: 480px; }

/* ================= category page ================= */
.cat-hero {
  max-width: 1180px;
  margin: 0 auto;
  padding: 56px 24px 20px;
  position: relative;
  z-index: 1;
}
.breadcrumb { font-size: 13px; color: var(--muted-2); margin-bottom: 18px; display: flex; gap: 8px; }
.breadcrumb a:hover { color: var(--gold-soft); }
.cat-hero h1 { font-size: clamp(28px, 4vw, 40px); margin: 14px 0 10px; font-weight: 900; }
.cat-hero p { max-width: 560px; font-size: 15.5px; }

.product-grid {
  max-width: 1180px;
  margin: 30px auto 0;
  padding: 0 24px;
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  gap: 18px;
  position: relative;
  z-index: 1;
}

.product-card {
  background: var(--card);
  border: 1px solid var(--line-soft);
  border-radius: var(--radius);
  overflow: hidden;
  transition: transform 0.25s, border-color 0.25s;
}
.js .product-card { opacity: 0; transform: translateY(14px); }
.js .product-card.in-view { opacity: 1; transform: none; }
.product-card:hover { transform: translateY(-4px); border-color: var(--gold); }

.product-media { aspect-ratio: 4 / 3; position: relative; }
.product-media img { width: 100%; height: 100%; object-fit: cover; }

.woven-swatch {
  width: 100%;
  height: 100%;
  position: relative;
}
.woven-swatch::before {
  content: "";
  position: absolute;
  inset: 0;
  background-image:
    repeating-linear-gradient(0deg, rgba(0,0,0,0.16) 0 2px, transparent 2px 6px),
    repeating-linear-gradient(90deg, rgba(255,255,255,0.06) 0 2px, transparent 2px 6px);
}
.woven-swatch::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(160deg, rgba(255,255,255,0.10), transparent 55%);
}

.product-info { padding: 16px; display: flex; flex-direction: column; gap: 10px; }
.product-info h3 { font-size: 15.5px; font-weight: 700; }
.color-code { font-size: 11.5px; color: var(--muted-2); letter-spacing: 0.5px; font-family: monospace; margin-top: -6px; }

.other-categories {
  max-width: 1180px;
  margin: 70px auto 90px;
  padding: 0 24px;
  position: relative;
  z-index: 1;
}
.chip-row { display: flex; gap: 10px; flex-wrap: wrap; margin-top: 14px; }
.chip {
  border: 1px solid var(--line);
  padding: 9px 18px;
  border-radius: 999px;
  font-size: 13.5px;
  color: var(--muted);
  transition: color 0.2s, border-color 0.2s;
}
.chip:hover { color: var(--gold-soft); border-color: var(--gold); }

/* ================= 404 ================= */
.not-found {
  max-width: 600px;
  margin: 120px auto;
  text-align: center;
  padding: 0 24px;
  position: relative; z-index: 1;
}
.not-found h1 { font-size: 90px; color: var(--gold); font-weight: 900; }
.not-found p { margin: 10px 0 28px; }

/* ================= footer ================= */
.site-footer {
  border-top: 1px solid var(--line-soft);
  margin-top: 60px;
  position: relative;
  z-index: 1;
  background: var(--bg-elevated);
}
.footer-inner {
  max-width: 1180px;
  margin: 0 auto;
  padding: 48px 24px;
  display: grid;
  grid-template-columns: 1.4fr 1fr 1fr;
  gap: 30px;
}
.footer-brand { display: flex; gap: 12px; align-items: flex-start; }
.footer-brand img { width: 46px; height: 46px; border-radius: 8px; object-fit: cover; }
.footer-brand strong { font-family: var(--font-display); font-size: 16px; }
.footer-brand p { font-size: 13px; margin-top: 6px; max-width: 260px; }

.footer-heading { display: block; font-size: 12.5px; font-weight: 700; color: var(--gold-soft); letter-spacing: 1px; margin-bottom: 12px; }
.footer-links, .footer-contact { display: flex; flex-direction: column; gap: 9px; }
.footer-links a, .footer-contact a { color: var(--muted); font-size: 13.5px; }
.footer-links a:hover, .footer-contact a:hover { color: var(--gold-soft); }

.footer-bottom {
  text-align: center;
  font-size: 12px;
  color: var(--muted-2);
  padding: 18px;
  border-top: 1px solid var(--line-soft);
}

/* ================= floating whatsapp ================= */
.wa-float {
  position: fixed;
  bottom: 24px;
  left: 24px;
  width: 58px;
  height: 58px;
  border-radius: 50%;
  background: #25d366;
  color: #fff;
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 12px 28px rgba(37, 211, 102, 0.4);
  z-index: 60;
  animation: wa-pulse 2.4s infinite;
}
@keyframes wa-pulse {
  0%, 100% { box-shadow: 0 12px 28px rgba(37, 211, 102, 0.4); }
  50% { box-shadow: 0 12px 28px rgba(37, 211, 102, 0.7), 0 0 0 8px rgba(37, 211, 102, 0.12); }
}

/* ================= responsive ================= */
@media (max-width: 860px) {
  .hero { grid-template-columns: 1fr; padding-top: 40px; }
  .hero-panel { max-width: 340px; aspect-ratio: auto; padding: 34px 24px; margin: 0 auto; }
  .hero-logo { width: 110px; height: 110px; margin-bottom: 16px; }
  .hero-stats { gap: 20px; }
  .hero-stats strong { font-size: 21px; }
  .stats-strip { grid-template-columns: repeat(2, 1fr); }
  .footer-inner { grid-template-columns: 1fr; }
}

@media (max-width: 760px) {
  .main-nav {
    position: absolute;
    top: 100%; right: 0; left: 0;
    background: var(--bg-elevated);
    border-bottom: 1px solid var(--line-soft);
    flex-direction: column;
    align-items: flex-start;
    padding: 16px 24px;
    gap: 14px;
    display: none;
  }
  .main-nav.open { display: flex; }
  .nav-toggle { display: flex; }
  .nav-whatsapp { display: none; }
}
