/* ==========================================================================
   Amaan Door & Hardware Suppliers — modern site stylesheet
   ========================================================================== */

@import url("https://fonts.googleapis.com/css2?family=Poppins:wght@500;600;700&family=Inter:wght@400;500;600&display=swap");

:root {
  --ink: #211a15;
  --ink-soft: #5c5147;
  --paper: #fbf8f4;
  --paper-alt: #f2ece3;
  --line: #e6ddd1;
  --brand: #b5652f;
  --brand-dark: #8f4d22;
  --brand-light: #f2e0cf;
  --accent: #1f6f5c;
  --white: #ffffff;
  --shadow-sm: 0 1px 2px rgba(33, 26, 21, 0.06), 0 1px 3px rgba(33, 26, 21, 0.08);
  --shadow-md: 0 8px 24px rgba(33, 26, 21, 0.1);
  --shadow-lg: 0 20px 48px rgba(33, 26, 21, 0.18);
  --radius-sm: 8px;
  --radius-md: 14px;
  --radius-lg: 22px;
  --font-head: "Poppins", system-ui, sans-serif;
  --font-body: "Inter", system-ui, sans-serif;
  --header-h: 72px;
}

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

body {
  margin: 0;
  font-family: var(--font-body);
  color: var(--ink);
  background: var(--paper);
  -webkit-font-smoothing: antialiased;
  line-height: 1.6;
}

img { max-width: 100%; display: block; }
a { color: inherit; text-decoration: none; }
h1, h2, h3, h4 { font-family: var(--font-head); margin: 0 0 0.5em; line-height: 1.2; }
p { margin: 0 0 1em; }

.container {
  width: 100%;
  max-width: 1180px;
  margin: 0 auto;
  padding: 0 20px;
}

.eyebrow {
  display: inline-block;
  font-size: 0.75rem;
  font-weight: 600;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--brand);
  margin-bottom: 10px;
}

.section-title {
  font-size: clamp(1.6rem, 3vw, 2.2rem);
  font-weight: 700;
}

.section-sub {
  color: var(--ink-soft);
  max-width: 640px;
  margin-bottom: 2rem;
}

.btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 12px 24px;
  border-radius: 999px;
  font-weight: 600;
  font-size: 0.95rem;
  border: 1px solid transparent;
  cursor: pointer;
  transition: transform 0.15s ease, box-shadow 0.15s ease, background 0.15s ease;
}
.btn:hover { transform: translateY(-2px); }
.btn-primary { background: var(--brand); color: var(--white); box-shadow: var(--shadow-sm); }
.btn-primary:hover { background: var(--brand-dark); box-shadow: var(--shadow-md); }
.btn-ghost { background: var(--white); color: var(--ink); border-color: var(--line); }
.btn-ghost:hover { border-color: var(--brand); color: var(--brand); }

/* ---------- Header ---------- */
.site-header {
  position: sticky;
  top: 0;
  z-index: 200;
  min-height: var(--header-h);
  display: flex;
  align-items: center;
  background: rgba(251, 248, 244, 0.85);
  backdrop-filter: saturate(180%) blur(14px);
  -webkit-backdrop-filter: saturate(180%) blur(14px);
  border-bottom: 1px solid var(--line);
}

.nav-wrap {
  width: 100%;
  max-width: 1180px;
  margin: 0 auto;
  padding: 12px 20px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}

.brand {
  display: flex;
  align-items: center;
  gap: 10px;
  min-width: 0;
  flex: 1 1 auto;
}
.brand img {
  width: 40px;
  height: 40px;
  border-radius: 10px;
  object-fit: cover;
  box-shadow: var(--shadow-sm);
  flex-shrink: 0;
}
.brand-name {
  font-family: var(--font-head);
  font-weight: 700;
  font-size: clamp(0.82rem, 3.6vw, 1rem);
  line-height: 1.2;
  min-width: 0;
}
.brand-name small {
  display: block;
  font-family: var(--font-body);
  font-weight: 500;
  font-size: 0.68rem;
  color: var(--ink-soft);
  text-transform: uppercase;
  letter-spacing: 0.06em;
}

.nav-menu {
  display: flex;
  align-items: center;
  gap: 4px;
  list-style: none;
  margin: 0;
  padding: 0;
}
.nav-menu a {
  display: block;
  padding: 9px 16px;
  border-radius: 999px;
  font-weight: 500;
  font-size: 0.94rem;
  color: var(--ink-soft);
  transition: background 0.15s ease, color 0.15s ease;
}
.nav-menu a:hover { background: var(--paper-alt); color: var(--ink); }
.nav-menu a.active { background: var(--brand); color: var(--white); }

.nav-toggle {
  display: none;
  width: 40px;
  height: 40px;
  border: none;
  background: transparent;
  cursor: pointer;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  gap: 5px;
}
.nav-toggle span {
  width: 22px;
  height: 2px;
  background: var(--ink);
  border-radius: 2px;
  transition: transform 0.2s ease, opacity 0.2s ease;
}
.nav-toggle.open span:nth-child(1) { transform: translateY(7px) rotate(45deg); }
.nav-toggle.open span:nth-child(2) { opacity: 0; }
.nav-toggle.open span:nth-child(3) { transform: translateY(-7px) rotate(-45deg); }

@media (max-width: 860px) {
  .nav-toggle { display: flex; }
  .nav-menu {
    position: fixed;
    top: var(--header-h);
    left: 0;
    right: 0;
    flex-direction: column;
    align-items: stretch;
    background: var(--white);
    border-bottom: 1px solid var(--line);
    padding: 10px;
    gap: 2px;
    transform: translateY(-8px);
    opacity: 0;
    pointer-events: none;
    transition: transform 0.2s ease, opacity 0.2s ease;
  }
  .nav-menu.open { transform: translateY(0); opacity: 1; pointer-events: auto; }
  .nav-menu a { padding: 12px 16px; border-radius: 10px; }
}

/* ---------- Social rail (fixed, right edge, visible on every page/breakpoint) ---------- */
.social-rail {
  position: fixed;
  top: 50%;
  right: 16px;
  transform: translateY(-50%);
  z-index: 150;
  display: flex;
  flex-direction: column;
  gap: 10px;
}
.social-rail a {
  width: 46px;
  height: 46px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  background: var(--white);
  color: var(--ink-soft);
  border: 1px solid var(--line);
  box-shadow: var(--shadow-md);
  transition: transform 0.15s ease, background 0.15s ease, color 0.15s ease, border-color 0.15s ease;
}
.social-rail a svg { width: 22px; height: 22px; }
.social-rail a:hover { transform: translateX(-3px) scale(1.05); }
.social-rail a.rail-fb { background: #1877f2; color: #fff; border-color: #1877f2; }
.social-rail a.rail-fb:hover { background: #1462c9; }
.social-rail a.rail-wa { background: #25d366; color: #fff; border-color: #25d366; }
.social-rail a.rail-wa:hover { background: #1fb457; }
.social-rail a.rail-ig:hover {
  background: radial-gradient(circle at 30% 110%, #fdf497, #fd5949 45%, #d6249f 60%, #285aeb 90%);
  color: #fff;
  border-color: transparent;
}
@media (max-width: 600px) {
  .social-rail { right: 10px; gap: 8px; }
  .social-rail a { width: 40px; height: 40px; }
  .social-rail a svg { width: 19px; height: 19px; }
}

/* ---------- Hero ---------- */
.hero {
  position: relative;
  overflow: hidden;
  background: linear-gradient(160deg, var(--paper-alt), var(--paper));
}
.hero-grid {
  max-width: 1180px;
  margin: 0 auto;
  padding: 64px 20px 56px;
  display: grid;
  grid-template-columns: 1.05fr 0.95fr;
  gap: 40px;
  align-items: center;
}
.hero h1 {
  font-size: clamp(2rem, 4vw, 3.1rem);
  font-weight: 700;
  letter-spacing: -0.01em;
}
.hero h1 span { color: var(--brand); }
.hero p { color: var(--ink-soft); font-size: 1.05rem; max-width: 480px; }
.hero-cta { display: flex; gap: 12px; flex-wrap: wrap; margin-top: 10px; }

.hero-media {
  position: relative;
  border-radius: var(--radius-lg);
  overflow: hidden;
  aspect-ratio: 4 / 3;
  box-shadow: var(--shadow-lg);
  background: linear-gradient(160deg, var(--paper-alt), var(--brand-light));
}
.hero-media .slide {
  position: absolute;
  inset: 0;
  opacity: 0;
  transition: opacity 0.7s ease;
  display: flex;
  align-items: center;
  justify-content: center;
}
.hero-media .slide.active { opacity: 1; }
.hero-media img { width: 100%; height: 100%; object-fit: contain; }
.hero-dots {
  position: absolute;
  bottom: 14px;
  left: 0;
  right: 0;
  display: flex;
  justify-content: center;
  gap: 7px;
  z-index: 5;
}
.hero-dots button {
  width: 8px; height: 8px; border-radius: 50%;
  border: none; background: rgba(255,255,255,0.55); cursor: pointer; padding: 0;
  transition: background 0.2s ease, width 0.2s ease;
}
.hero-dots button.active { background: var(--white); width: 22px; border-radius: 4px; }

@media (max-width: 860px) {
  .hero-grid { grid-template-columns: 1fr; padding-top: 40px; }
  .hero-media { aspect-ratio: 16/10; }
}

/* ---------- Trust strip ---------- */
.trust-strip {
  border-top: 1px solid var(--line);
  border-bottom: 1px solid var(--line);
  background: var(--white);
}
.trust-grid {
  max-width: 1180px;
  margin: 0 auto;
  padding: 26px 20px;
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
  gap: 18px;
}
.trust-item { display: flex; align-items: center; gap: 12px; font-size: 0.92rem; color: var(--ink-soft); }
.trust-item .ic {
  width: 38px; height: 38px; border-radius: 10px; background: var(--brand-light);
  color: var(--brand-dark); display: flex; align-items: center; justify-content: center;
  font-size: 1.1rem; flex-shrink: 0;
}

/* ---------- Sections ---------- */
.section { padding: 64px 0; }
.section-alt { background: var(--paper-alt); }
.section-head { display: flex; align-items: flex-end; justify-content: space-between; gap: 20px; flex-wrap: wrap; }

/* ---------- Category grid ---------- */
.cat-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
  gap: 20px;
}
.cat-card {
  position: relative;
  border-radius: var(--radius-md);
  overflow: hidden;
  aspect-ratio: 4 / 5;
  background: var(--paper-alt);
  box-shadow: var(--shadow-sm);
  transition: transform 0.25s ease, box-shadow 0.25s ease;
}
.cat-card:hover { transform: translateY(-5px); box-shadow: var(--shadow-md); }
.cat-card .img-wrap { position: absolute; inset: 0; }
.cat-card img { width: 100%; height: 100%; object-fit: cover; transition: transform 0.4s ease; }
.cat-card:hover img { transform: scale(1.06); }
.cat-card::after {
  content: "";
  position: absolute; inset: 0;
  background: linear-gradient(180deg, rgba(33,26,21,0) 40%, rgba(20,15,11,0.82) 100%);
}
.cat-card .label {
  position: absolute; left: 16px; right: 16px; bottom: 14px; z-index: 2;
  color: var(--white); font-family: var(--font-head); font-weight: 600; font-size: 1.05rem;
}
.cat-card .label small {
  display: block; font-family: var(--font-body); font-weight: 400; font-size: 0.78rem;
  color: rgba(255,255,255,0.75); margin-top: 2px;
}

/* ---------- Skeleton / lazy image ---------- */
.lazy-frame {
  position: relative;
  width: 100%;
  height: 100%;
  overflow: hidden;
  background: var(--paper-alt);
}
.lazy-frame::before {
  content: "";
  position: absolute; inset: 0;
  background: linear-gradient(100deg, var(--paper-alt) 30%, #ffffff 50%, var(--paper-alt) 70%);
  background-size: 200% 100%;
  animation: shimmer 1.5s infinite;
}
.lazy-frame.loaded::before { display: none; }
.lazy-frame img {
  position: relative; z-index: 1;
  opacity: 0;
  transition: opacity 0.4s ease;
  width: 100%; height: 100%; object-fit: cover;
}
.lazy-frame.loaded img { opacity: 1; }
@keyframes shimmer {
  0% { background-position: 200% 0; }
  100% { background-position: -200% 0; }
}

/* ---------- Product gallery ---------- */
.group-block { margin-bottom: 40px; }
.group-title {
  font-size: 1.15rem; font-weight: 600; margin-bottom: 4px;
  display: flex; align-items: center; gap: 10px;
}
.group-title::after { content: ""; flex: 1; height: 1px; background: var(--line); }
.group-blurb { color: var(--ink-soft); font-size: 0.92rem; margin-bottom: 16px; }

.gallery-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(190px, 1fr));
  gap: 16px;
}
.gallery-item {
  border-radius: var(--radius-md);
  overflow: hidden;
  background: var(--white);
  box-shadow: var(--shadow-sm);
  cursor: zoom-in;
  border: 1px solid var(--line);
}
.gallery-item .lazy-frame { aspect-ratio: 1 / 1; }
.gallery-item .cap {
  padding: 10px 12px;
  font-size: 0.85rem;
  color: var(--ink-soft);
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 6px;
}
.gallery-item .cap .zoom-hint { font-size: 0.72rem; color: var(--brand); font-weight: 600; white-space: nowrap; }
.gallery-item:hover { box-shadow: var(--shadow-md); border-color: var(--brand-light); }

.pdf-item .cap a { color: var(--brand); font-weight: 600; }

/* ---------- Lightbox ---------- */
.lightbox {
  position: fixed; inset: 0; z-index: 1000;
  background: rgba(15, 11, 8, 0.94);
  display: none;
  align-items: center;
  justify-content: center;
  touch-action: none;
}
.lightbox.active { display: flex; }
.lightbox-stage {
  position: relative;
  width: 100%; height: 100%;
  display: flex; align-items: center; justify-content: center;
  overflow: hidden;
}
.lightbox-img-wrap {
  cursor: grab;
  will-change: transform;
}
.lightbox-img-wrap.dragging { cursor: grabbing; }
.lightbox-img-wrap img {
  max-width: 92vw;
  max-height: 86vh;
  object-fit: contain;
  border-radius: 6px;
  box-shadow: 0 30px 80px rgba(0,0,0,0.5);
  user-select: none;
  -webkit-user-drag: none;
}
.lightbox-spinner {
  position: absolute;
  width: 40px; height: 40px;
  border-radius: 50%;
  border: 3px solid rgba(255,255,255,0.25);
  border-top-color: var(--white);
  animation: spin 0.8s linear infinite;
  display: none;
}
.lightbox-spinner.active { display: block; }
@keyframes spin { to { transform: rotate(360deg); } }

.lightbox-bar {
  position: absolute; top: 0; left: 0; right: 0;
  display: flex; align-items: center; justify-content: space-between;
  padding: 16px 20px;
  z-index: 5;
  color: var(--white);
  font-size: 0.85rem;
  background: linear-gradient(180deg, rgba(0,0,0,0.45), transparent);
}
.lightbox-quality {
  display: inline-flex; align-items: center; gap: 7px;
  background: rgba(255,255,255,0.12);
  padding: 6px 12px; border-radius: 999px;
  backdrop-filter: blur(6px);
}
.lightbox-quality .dot { width: 7px; height: 7px; border-radius: 50%; background: #f3b354; }
.lightbox-quality.hq .dot { background: #4fd1a5; }

.lightbox-actions { display: flex; gap: 8px; }
.lightbox-actions button {
  width: 40px; height: 40px;
  border-radius: 50%;
  border: none;
  background: rgba(255,255,255,0.12);
  color: var(--white);
  font-size: 1.05rem;
  cursor: pointer;
  display: flex; align-items: center; justify-content: center;
  transition: background 0.15s ease;
}
.lightbox-actions button:hover { background: rgba(255,255,255,0.28); }

.lightbox-nav {
  position: absolute; top: 50%; transform: translateY(-50%);
  width: 46px; height: 46px; border-radius: 50%;
  border: none; background: rgba(255,255,255,0.12); color: var(--white);
  font-size: 1.3rem; cursor: pointer; z-index: 5;
  display: flex; align-items: center; justify-content: center;
  transition: background 0.15s ease;
}
.lightbox-nav:hover { background: rgba(255,255,255,0.28); }
.lightbox-prev { left: 16px; }
.lightbox-next { right: 16px; }

.lightbox-hint {
  position: absolute; bottom: 16px; left: 0; right: 0;
  text-align: center; color: rgba(255,255,255,0.6); font-size: 0.78rem;
  z-index: 5;
}
@media (max-width: 640px) {
  .lightbox-nav { width: 38px; height: 38px; font-size: 1.05rem; }
  .lightbox-hint { display: none; }
}

/* ---------- About / Contact ---------- */
.page-hero {
  padding: 56px 0 20px;
  text-align: center;
}
.page-hero .eyebrow { display: block; }
.page-hero h1 { font-size: clamp(1.8rem, 4vw, 2.6rem); }
.page-hero p { color: var(--ink-soft); max-width: 620px; margin: 0 auto; }

.about-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 40px;
  align-items: center;
}
.about-media {
  border-radius: var(--radius-lg);
  overflow: hidden;
  aspect-ratio: 4/3;
  box-shadow: var(--shadow-md);
}
.value-list { list-style: none; padding: 0; margin: 20px 0 0; display: grid; gap: 12px; }
.value-list li { display: flex; gap: 12px; align-items: flex-start; color: var(--ink-soft); }
.value-list .ic {
  width: 30px; height: 30px; border-radius: 8px; background: var(--brand-light); color: var(--brand-dark);
  display: flex; align-items: center; justify-content: center; flex-shrink: 0; font-size: 0.85rem;
}
@media (max-width: 800px) { .about-grid { grid-template-columns: 1fr; } }

.contact-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 18px;
  margin-bottom: 36px;
}
.contact-card {
  background: var(--white);
  border: 1px solid var(--line);
  border-radius: var(--radius-md);
  padding: 24px;
  text-align: center;
  box-shadow: var(--shadow-sm);
}
.contact-card .ic {
  width: 48px; height: 48px; margin: 0 auto 14px; border-radius: 50%;
  background: var(--brand-light); color: var(--brand-dark);
  display: flex; align-items: center; justify-content: center; font-size: 1.3rem;
}
.contact-card h3 { font-size: 1rem; margin-bottom: 6px; }
.contact-card a, .contact-card p { color: var(--ink-soft); font-size: 0.95rem; margin: 0; }
.contact-card a:hover { color: var(--brand); }
@media (max-width: 800px) { .contact-grid { grid-template-columns: 1fr; } }

.map-wrap {
  border-radius: var(--radius-lg);
  overflow: hidden;
  box-shadow: var(--shadow-md);
  line-height: 0;
}
.map-wrap iframe { width: 100%; height: 380px; border: 0; }

/* ---------- CTA ---------- */
.cta-band {
  background: linear-gradient(135deg, var(--brand-dark), var(--brand));
  color: var(--white);
  border-radius: var(--radius-lg);
  padding: 44px 36px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  flex-wrap: wrap;
}
.cta-band h2 { margin-bottom: 4px; }
.cta-band p { color: rgba(255,255,255,0.85); margin: 0; }
.cta-band .btn-ghost { background: var(--white); color: var(--brand-dark); }

/* ---------- Footer ---------- */
.site-footer { background: #1b140f; color: rgba(255,255,255,0.72); margin-top: 40px; }
.footer-grid {
  max-width: 1180px; margin: 0 auto; padding: 56px 20px 28px;
  display: grid; grid-template-columns: 1.4fr 1fr 1fr; gap: 32px;
}
.footer-brand { display: flex; gap: 12px; align-items: center; margin-bottom: 12px; }
.footer-brand img { width: 40px; height: 40px; border-radius: 9px; }
.footer-brand span { font-family: var(--font-head); font-weight: 700; color: var(--white); font-size: 1rem; }
.site-footer h4 { color: var(--white); font-size: 0.95rem; margin-bottom: 14px; }
.site-footer ul { list-style: none; padding: 0; margin: 0; display: grid; gap: 9px; }
.site-footer a { color: rgba(255,255,255,0.72); font-size: 0.92rem; transition: color 0.15s ease; }
.site-footer a:hover { color: var(--white); }
.footer-social { display: flex; gap: 10px; margin-top: 14px; }
.footer-social a {
  width: 38px; height: 38px; border-radius: 50%; background: rgba(255,255,255,0.08);
  display: flex; align-items: center; justify-content: center; color: #fff;
  transition: background 0.15s ease;
}
.footer-social a svg { width: 18px; height: 18px; }
.footer-social a.rail-fb:hover { background: #1877f2; }
.footer-social a.rail-wa:hover { background: #25d366; }
.footer-social a.rail-ig:hover {
  background: radial-gradient(circle at 30% 110%, #fdf497, #fd5949 45%, #d6249f 60%, #285aeb 90%);
}

.footer-bottom {
  border-top: 1px solid rgba(255,255,255,0.1);
  text-align: center; padding: 18px 20px; font-size: 0.82rem; color: rgba(255,255,255,0.5);
}
@media (max-width: 760px) { .footer-grid { grid-template-columns: 1fr; } }

/* ---------- Misc ---------- */
.badge {
  display: inline-flex; align-items: center; gap: 6px;
  background: var(--brand-light); color: var(--brand-dark);
  font-size: 0.78rem; font-weight: 600; padding: 5px 12px; border-radius: 999px;
}
.crumbs { font-size: 0.85rem; color: var(--ink-soft); margin-bottom: 8px; }
.crumbs a:hover { color: var(--brand); }
