/* ─────────────────────────────────────────
   ChemCo — tokens
   Ink Navy #0B2545 · Steel #5B6B79 · Paper #F7F9FA
   Teal accent #0E7C86 · Amber #F2A93B
───────────────────────────────────────── */
:root {
  --ink: #0B2545;
  --ink-soft: #123A63;
  --steel: #5B6B79;
  --steel-light: #98A6B2;
  --paper: #F7F9FA;
  --white: #FFFFFF;
  --teal: #0E7C86;
  --teal-dark: #0A5F66;
  --amber: #F2A93B;
  --line: #E2E7EB;

  --display: "Barlow Condensed", "Arial Narrow", sans-serif;
  --body: "Inter", -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
}

* { margin: 0; padding: 0; box-sizing: border-box; }

html { scroll-behavior: smooth; }

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

img { max-width: 100%; display: block; }
a { color: inherit; text-decoration: none; }

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

.btn {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.85rem 1.75rem;
  border-radius: 4px;
  font-weight: 600;
  font-size: 0.95rem;
  border: none;
  cursor: pointer;
  transition: transform 0.15s ease, background 0.15s ease, box-shadow 0.15s ease;
}
.btn svg { width: 18px; height: 18px; flex-shrink: 0; }
.btn-primary { background: var(--teal); color: var(--white); }
.btn-primary:hover { background: var(--teal-dark); transform: translateY(-1px); }
.btn-ghost { background: transparent; color: var(--ink); border: 1.5px solid var(--line); }
.btn-ghost:hover { border-color: var(--ink); }
.btn-whatsapp { background: #1EBE5D; color: #fff; }
.btn-whatsapp:hover { background: #17a34e; transform: translateY(-1px); }

/* ── Header ── */
.site-header {
  position: sticky;
  top: 0;
  z-index: 500;
  background: var(--white);
  border-bottom: 3px solid var(--ink);
}
.header-inner {
  max-width: 1240px;
  margin: 0 auto;
  padding: 0.9rem 1.5rem;
  display: flex;
  align-items: center;
  gap: 2rem;
}
.brand { display: flex; flex-direction: column; line-height: 1; margin-right: auto; }
.brand-name {
  font-family: var(--display);
  font-weight: 800;
  font-size: 1.9rem;
  color: var(--ink);
  letter-spacing: 0.01em;
}
.brand-accent { color: var(--teal); }
.brand-tag {
  font-size: 0.62rem;
  font-weight: 600;
  letter-spacing: 0.22em;
  color: var(--steel);
  margin-top: 0.15rem;
}
.main-nav { display: flex; gap: 1.75rem; }
.main-nav a {
  font-size: 0.9rem;
  font-weight: 600;
  color: var(--ink);
  padding: 0.4rem 0;
  border-bottom: 2px solid transparent;
  transition: border-color 0.15s;
}
.main-nav a:hover { border-color: var(--teal); }

.header-contact { display: flex; align-items: center; gap: 1.5rem; }
.contact-item {
  display: flex;
  align-items: center;
  gap: 0.4rem;
  font-size: 0.85rem;
  font-weight: 500;
  color: var(--ink);
  white-space: nowrap;
}
.contact-item svg { width: 16px; height: 16px; color: var(--teal); }
.admin-link {
  font-size: 0.78rem;
  color: var(--steel-light);
  border-left: 1px solid var(--line);
  padding-left: 1.25rem;
}
.admin-link:hover { color: var(--steel); }

.nav-toggle { display: none; }
.mobile-nav { display: none; }

@media (max-width: 880px) {
  .main-nav, .header-contact { display: none; }
  .nav-toggle {
    display: flex;
    flex-direction: column;
    gap: 5px;
    background: none;
    border: none;
    cursor: pointer;
    padding: 0.4rem;
  }
  .nav-toggle span { width: 22px; height: 2px; background: var(--ink); }
  .mobile-nav {
    display: none;
    flex-direction: column;
    padding: 0 1.5rem 1.25rem;
    gap: 0.9rem;
    border-top: 1px solid var(--line);
  }
  .mobile-nav.is-open { display: flex; }
  .mobile-nav a { font-size: 0.92rem; font-weight: 600; padding: 0.3rem 0; }
}

/* ── Hero ── */
.hero {
  position: relative;
  min-height: 78vh;
  display: flex;
  align-items: center;
  overflow: hidden;
  background: var(--ink);
}
.hero-slides { position: absolute; inset: 0; }
.hero-slide {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  opacity: 0;
  transition: opacity 1.4s ease;
}
.hero-slide.is-active { opacity: 1; }
@media (prefers-reduced-motion: reduce) {
  .hero-slide { transition: none; }
}
.hero-overlay {
  position: absolute;
  inset: 0;
  background: linear-gradient(100deg, rgba(11,37,69,0.92) 0%, rgba(11,37,69,0.72) 38%, rgba(11,37,69,0.25) 70%);
}
.hero-content {
  position: relative;
  z-index: 2;
  max-width: 1240px;
  margin: 0 auto;
  padding: 0 1.5rem;
  width: 100%;
  max-width: 640px;
  color: var(--white);
}
.hero-content h1 {
  font-family: var(--display);
  font-weight: 800;
  font-size: clamp(2.4rem, 5.2vw, 4rem);
  line-height: 1.02;
  letter-spacing: 0.005em;
  margin-bottom: 1.1rem;
}
.hero-content p {
  font-size: 1.05rem;
  color: rgba(255,255,255,0.88);
  margin-bottom: 1.75rem;
  max-width: 46ch;
}
.hero-dots {
  position: absolute;
  z-index: 2;
  bottom: 1.75rem;
  left: 50%;
  transform: translateX(-50%);
  display: flex;
  gap: 0.5rem;
}
.hero-dot {
  width: 28px;
  height: 3px;
  background: rgba(255,255,255,0.35);
  border: none;
  cursor: pointer;
  transition: background 0.2s;
}
.hero-dot.is-active { background: var(--white); }

/* ── Stats bar ── */
.stats-bar {
  background: var(--ink);
  display: flex;
  justify-content: center;
  gap: clamp(2rem, 6vw, 5rem);
  padding: 1.75rem 1.5rem;
  flex-wrap: wrap;
}
.stat { text-align: center; color: var(--white); }
.stat strong {
  display: block;
  font-family: var(--display);
  font-size: 2.1rem;
  font-weight: 700;
  color: var(--amber);
}
.stat span { font-size: 0.78rem; color: rgba(255,255,255,0.7); }

/* ── Section intro ── */
.section-intro {
  max-width: 700px;
  margin: 4rem auto 2.5rem;
  padding: 0 1.5rem;
  text-align: center;
}
.section-intro h2 {
  font-family: var(--display);
  font-size: 2.4rem;
  font-weight: 700;
  color: var(--ink);
  margin-bottom: 0.75rem;
}
.section-intro p { color: var(--steel); font-size: 1rem; }

/* ── Products ── */
.products-section { max-width: 1240px; margin: 0 auto 5rem; padding: 0 1.5rem; }
.product-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(250px, 1fr));
  gap: 1.5rem;
}
.loading-state, .empty-state {
  grid-column: 1 / -1;
  text-align: center;
  padding: 3rem 1rem;
  color: var(--steel);
}
.product-card {
  background: var(--white);
  border: 1px solid var(--line);
  border-radius: 6px;
  overflow: hidden;
  cursor: pointer;
  transition: border-color 0.15s, transform 0.15s;
  display: flex;
  flex-direction: column;
}
.product-card:hover { border-color: var(--teal); transform: translateY(-3px); }
.product-card .thumb {
  width: 100%;
  aspect-ratio: 4 / 3;
  object-fit: cover;
  background: var(--paper);
}
.product-card .card-body { padding: 1.1rem 1.2rem 1.3rem; display: flex; flex-direction: column; gap: 0.4rem; flex: 1; }
.product-card h3 { font-size: 1.05rem; font-weight: 700; color: var(--ink); }
.product-card p {
  font-size: 0.85rem;
  color: var(--steel);
  overflow: hidden;
  text-overflow: ellipsis;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
}
.product-card .price {
  margin-top: auto;
  padding-top: 0.5rem;
  font-family: var(--display);
  font-weight: 700;
  font-size: 1.2rem;
  color: var(--teal-dark);
}

/* ── Why band ── */
.why-band { background: var(--ink); padding: 4rem 1.5rem; }
.why-inner {
  max-width: 1240px;
  margin: 0 auto;
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 2.25rem;
}
.why-item { color: var(--white); }
.why-icon {
  width: 46px; height: 46px;
  border: 1.5px solid rgba(255,255,255,0.25);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--amber);
  margin-bottom: 1rem;
}
.why-icon svg { width: 22px; height: 22px; }
.why-item h3 { font-family: var(--display); font-size: 1.3rem; font-weight: 700; margin-bottom: 0.4rem; }
.why-item p { font-size: 0.88rem; color: rgba(255,255,255,0.72); }

/* ── Footer ── */
.site-footer { background: #081A30; color: rgba(255,255,255,0.85); padding: 3.5rem 1.5rem 0; }
.footer-inner {
  max-width: 1240px;
  margin: 0 auto;
  display: grid;
  grid-template-columns: 2fr 1fr 1fr;
  gap: 2rem;
  padding-bottom: 2.5rem;
}
.footer-brand .brand-name { font-family: var(--display); font-size: 1.6rem; font-weight: 800; color: var(--white); }
.footer-brand p { margin-top: 0.5rem; font-size: 0.85rem; color: rgba(255,255,255,0.6); max-width: 32ch; }
.footer-col h4 { font-size: 0.8rem; text-transform: uppercase; letter-spacing: 0.08em; color: rgba(255,255,255,0.5); margin-bottom: 0.9rem; }
.footer-col a { display: block; font-size: 0.88rem; margin-bottom: 0.6rem; color: rgba(255,255,255,0.85); }
.footer-col a:hover { color: var(--amber); }
.footer-bottom {
  max-width: 1240px;
  margin: 0 auto;
  border-top: 1px solid rgba(255,255,255,0.12);
  padding: 1.5rem 0;
  display: flex;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 0.5rem;
  font-size: 0.8rem;
  color: rgba(255,255,255,0.55);
}
.footer-bottom a { color: var(--amber); }

@media (max-width: 720px) {
  .footer-inner { grid-template-columns: 1fr; }
}

/* ── Order modal ── */
.modal-overlay {
  position: fixed; inset: 0;
  background: rgba(11,37,69,0.55);
  z-index: 1000;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 1rem;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.2s;
}
.modal-overlay.show { opacity: 1; pointer-events: all; }
.order-modal {
  background: var(--white);
  border-radius: 10px;
  max-width: 460px;
  width: 100%;
  max-height: 88vh;
  overflow-y: auto;
  position: relative;
  transform: scale(0.96);
  transition: transform 0.2s;
}
.modal-overlay.show .order-modal { transform: scale(1); }
.modal-close {
  position: absolute;
  top: 0.9rem; right: 0.9rem;
  width: 32px; height: 32px;
  border-radius: 50%;
  background: rgba(255,255,255,0.9);
  border: none;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--ink);
  z-index: 2;
}
.modal-image { width: 100%; aspect-ratio: 16 / 10; object-fit: cover; background: var(--paper); }
.modal-body { padding: 1.5rem 1.5rem 1.75rem; }
.modal-body h3 { font-size: 1.3rem; font-weight: 700; color: var(--ink); margin-bottom: 0.5rem; }
.modal-desc { font-size: 0.9rem; color: var(--steel); margin-bottom: 1rem; }
.modal-price { font-family: var(--display); font-size: 1.6rem; font-weight: 700; color: var(--teal-dark); margin-bottom: 1.5rem; }
.modal-actions { display: flex; flex-direction: column; gap: 0.75rem; }
.modal-actions .btn { justify-content: center; width: 100%; }