/* ============================================================
   ZAFIROBREW — Estilos principales
   ============================================================ */

/* ── Variables ── */
:root {
  --g:   #0a9e8f;
  --gl:  #12c2b0;
  --go:  #c8860a;
  --gol: #e0a020;
  --e:   #0d0500;
  --d:   #180a00;
  --c:   rgba(245,230,211,.75);
  --cm:  rgba(245,230,211,.45);
}

/* ── Reset & base ── */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html  { scroll-behavior: smooth; }
body  { font-family: 'Inter', sans-serif; background: var(--e); color: #f5e6d3; overflow-x: hidden; }

/* ── Utilidades ── */
.serif { font-family: 'Playfair Display', serif; }
.teal  { color: var(--gl) !important; }
.gold  { color: var(--go) !important; }
.muted { color: var(--c) !important; }
.label { font-size: .7rem; font-weight: 700; letter-spacing: 2.5px; text-transform: uppercase; color: var(--gl); }
section { padding: 5.5rem 0; }
.bg2  { background: var(--d); }

/* ============================================================
   NAV
   ============================================================ */
#nav {
  position: fixed; top: 62px; left: 0; right: 0; z-index: 99;
  padding: .9rem 0;
  background: rgba(13,5,0,.8);
  backdrop-filter: blur(16px);
  border-bottom: 1px solid rgba(200,134,10,.1);
  transition: .3s;
}
#nav.dark { background: rgba(5,2,0,.97); }

.brand { font-family: 'Playfair Display', serif; font-size: 1.5rem; font-weight: 900; color: var(--go) !important; text-decoration: none; }
.brand span { color: var(--gl); }

.nav-link { color: rgba(245,230,211,.75) !important; font-size: .85rem; font-weight: 500; transition: .2s !important; }
.nav-link:hover { color: var(--go) !important; }

.btn-nav { background: var(--go); color: #0d0500 !important; border: none; border-radius: 50px; padding: .5rem 1.4rem; font-weight: 700; font-size: .85rem; transition: .2s; }
.btn-nav:hover { background: var(--gol); transform: translateY(-1px); }

/* ============================================================
   BOTONES
   ============================================================ */
.btn-g {
  display: inline-block;
  background: linear-gradient(135deg, var(--go), #9a5e00);
  color: #0d0500 !important; font-weight: 700; border: none; border-radius: 50px;
  padding: .8rem 2rem; box-shadow: 0 4px 20px rgba(200,134,10,.3);
  transition: .2s; text-decoration: none;
}
.btn-g:hover { transform: translateY(-2px); box-shadow: 0 8px 30px rgba(200,134,10,.45); }

.btn-t {
  display: inline-block;
  background: linear-gradient(135deg, var(--g), var(--gl));
  color: #fff !important; font-weight: 700; border: none; border-radius: 50px;
  padding: .8rem 2rem; box-shadow: 0 4px 20px rgba(0,158,143,.25);
  transition: .2s; text-decoration: none;
}
.btn-t:hover { transform: translateY(-2px); box-shadow: 0 8px 30px rgba(0,158,143,.4); }

.btn-o {
  display: inline-block;
  border: 2px solid rgba(245,230,211,.25);
  color: rgba(245,230,211,.8) !important; font-weight: 600; border-radius: 50px;
  padding: .8rem 2rem; background: transparent; transition: .2s; text-decoration: none;
}
.btn-o:hover { border-color: var(--go); background: rgba(200,134,10,.07); }

/* ============================================================
   HERO
   ============================================================ */
#hero {
  min-height: 100vh; display: flex; align-items: center;
  position: relative; overflow: hidden;
  background: radial-gradient(ellipse at 65% 35%, #3a1800 0%, var(--e) 65%);
  padding-top: 5rem;
}
.blob { position: absolute; border-radius: 50%; pointer-events: none; opacity: .1; }
.b1   { width: 560px; height: 560px; background: var(--go); top: -130px; right: -100px; }
.b2   { width: 300px; height: 300px; background: var(--g);  bottom: -60px; left: 5%; }

.hero-tag {
  display: inline-flex; align-items: center; gap: .4rem;
  background: rgba(0,158,143,.15); border: 1px solid rgba(18,194,176,.3);
  color: var(--gl); padding: .35rem .9rem; border-radius: 50px;
  font-size: .72rem; font-weight: 700; letter-spacing: 1px; text-transform: uppercase;
}
.hero-h   { font-size: clamp(3rem, 6vw, 5rem); line-height: 1.05; font-weight: 900; }
.hero-sub { font-size: 1.05rem; color: var(--c); line-height: 1.8; max-width: 460px; }

@keyframes float { 0%, 100% { transform: translateY(0); } 50% { transform: translateY(-10px); } }

/* ============================================================
   PRODUCTOS
   ============================================================ */
.prod-card    { border-radius: 20px; overflow: hidden; position: relative; height: 100%; }
.prod-premium { background: linear-gradient(155deg, #2a1200, #0d0500); border: 1px solid rgba(200,134,10,.35); }
.prod-eco     { background: linear-gradient(155deg, #002a26, #0d0500); border: 1px solid rgba(0,158,143,.35); }

.prod-badge  { position: absolute; top: 1.2rem; right: 1.2rem; padding: .3rem .8rem; border-radius: 50px; font-size: .7rem; font-weight: 700; }
.badge-gold  { background: rgba(200,134,10,.2); border: 1px solid var(--go); color: var(--go); }
.badge-eco   { background: rgba(0,158,143,.2);  border: 1px solid var(--gl); color: var(--gl); }
.prod-price  { font-family: 'Playfair Display', serif; font-size: 1.1rem; font-weight: 700; }

/* ============================================================
   CARDS genéricas
   ============================================================ */
.why-card {
  background: rgba(255,255,255,.03); border: 1px solid rgba(255,255,255,.08);
  border-radius: 16px; padding: 1.8rem 1.4rem; text-align: center;
  transition: .25s; height: 100%;
}
.why-card:hover { border-color: rgba(200,134,10,.4); transform: translateY(-5px); background: rgba(200,134,10,.05); }

/* ============================================================
   EQUIPO
   ============================================================ */
.team-card { background: rgba(255,255,255,.03); border: 1px solid rgba(200,134,10,.12); border-radius: 16px; padding: 2rem 1.5rem; text-align: center; transition: .25s; height: 100%; }
.team-card:hover { border-color: rgba(200,134,10,.4); transform: translateY(-4px); }
.team-card.featured { border-color: rgba(0,158,143,.35); background: rgba(0,158,143,.05); }
.team-card.featured:hover { border-color: var(--gl); }

.avatar {
  width: 80px; height: 80px; border-radius: 50%; margin: 0 auto 1rem;
  display: flex; align-items: center; justify-content: center; font-size: 1.8rem;
  border: 2px solid rgba(200,134,10,.25);
}
.avatar.featured-av {
  border-color: var(--gl); border-width: 3px; background: rgba(0,158,143,.1);
  box-shadow: 0 0 0 4px rgba(0,158,143,.12);
}
.team-role { font-size: .7rem; font-weight: 700; letter-spacing: 1.5px; text-transform: uppercase; }

/* ============================================================
   PROCESO
   ============================================================ */
.step-num {
  width: 48px; height: 48px; border-radius: 12px; flex-shrink: 0;
  background: linear-gradient(135deg, var(--g), var(--gl));
  display: flex; align-items: center; justify-content: center;
  font-family: 'Playfair Display', serif; font-size: 1.2rem; font-weight: 700;
}
.process-flow {
  display: flex;
  align-items: flex-start;
  justify-content: center;
  flex-wrap: wrap;
  gap: .25rem;
}
.process-node { min-width: 110px; max-width: 140px; }
.process-arrow {
  font-size: 1.8rem;
  line-height: 1;
  padding: .55rem .25rem 0;
  color: var(--go);
  opacity: .5;
  flex-shrink: 0;
}
.market-chip {
  background: rgba(255,255,255,.04);
  border: 1px solid rgba(255,255,255,.09);
  border-radius: 12px;
  padding: .6rem 1rem;
  transition: .2s;
  min-width: 190px;
}
.market-chip:hover {
  border-color: rgba(200,134,10,.35);
  background: rgba(200,134,10,.05);
}

/* ============================================================
   STATS
   ============================================================ */
.stat-b { background: rgba(0,120,112,.1); border: 1px solid rgba(0,158,143,.2); border-radius: 14px; padding: 1.5rem; text-align: center; }
.stat-n { font-family: 'Playfair Display', serif; font-size: 2.2rem; font-weight: 700; color: var(--gl); line-height: 1; }

/* ============================================================
   BANDA LOS ZAFIROS
   ============================================================ */
.zafiros-band {
  background: linear-gradient(135deg, #0a1a18 0%, #0d0400 50%, #091614 100%);
  border-top: 1px solid rgba(0,158,143,.2);
  border-bottom: 1px solid rgba(0,158,143,.2);
  padding: 5.5rem 0;
}
.zafiros-nota {
  font-size: 2.5rem;
  color: var(--go);
  opacity: .5;
  line-height: 1;
  margin-bottom: 1.2rem;
  letter-spacing: .5rem;
}
.zafiros-slogan {
  font-size: clamp(2rem, 4vw, 3rem);
  font-style: italic;
  font-weight: 700;
  line-height: 1.2;
  margin-bottom: 1.2rem;
}
.zafiros-desc {
  max-width: 600px;
  margin: 0 auto 1.2rem;
  font-size: .97rem;
  line-height: 1.85;
}
.zafiros-attr {
  font-size: .78rem;
  color: var(--go);
  opacity: .6;
  letter-spacing: .08em;
  margin: 0;
}

/* ============================================================
   FOOTER
   ============================================================ */
footer { background: #050200; border-top: 1px solid rgba(200,134,10,.1); padding: 2rem 0; }

/* ============================================================
   REVEAL on scroll
   ============================================================ */
.rv { opacity: 0; transform: translateY(24px); transition: opacity .6s, transform .6s; }
.rv.on { opacity: 1; transform: none; }

/* ============================================================
   FORMULARIO
   ============================================================ */
.form-zb { background: rgba(255,255,255,.04); border: 1px solid rgba(200,134,10,.18); border-radius: 20px; padding: 2.5rem; }

.form-zb .form-control,
.form-zb .form-select {
  background: rgba(255,255,255,.06); border: 1px solid rgba(245,230,211,.15);
  color: #f5e6d3; border-radius: 10px; padding: .75rem 1rem; font-size: .9rem; transition: .2s;
}
.form-zb .form-control::placeholder { color: rgba(245,230,211,.35); }
.form-zb .form-control:focus,
.form-zb .form-select:focus {
  background: rgba(255,255,255,.09); border-color: var(--gl);
  box-shadow: 0 0 0 3px rgba(18,194,176,.15); color: #f5e6d3;
}
.form-zb .form-select option { background: #180a00; color: #f5e6d3; }
.form-zb label { font-size: .82rem; font-weight: 600; color: rgba(245,230,211,.7); margin-bottom: .4rem; display: block; }

.form-success {
  display: none;
  background: rgba(0,158,143,.15); border: 1px solid rgba(18,194,176,.35);
  border-radius: 12px; padding: 1.2rem; text-align: center; color: var(--gl);
}

/* ============================================================
   CHATBOT FLOTANTE (WhatsApp Bot)
   ============================================================ */
.chat-fab {
  position: fixed; bottom: 1.8rem; right: 1.8rem; z-index: 1000;
  width: 60px; height: 60px; border-radius: 50%; background: #25d366;
  display: flex; align-items: center; justify-content: center;
  box-shadow: 0 4px 20px rgba(37,211,102,.45);
  cursor: pointer; border: none; transition: .25s;
  animation: waPulse 2.8s infinite;
}
.chat-fab:hover { transform: scale(1.1); box-shadow: 0 6px 28px rgba(37,211,102,.6); }
.chat-fab i { font-size: 1.9rem; color: #fff; }

.chat-badge {
  position: absolute; top: -4px; right: -4px;
  width: 20px; height: 20px; border-radius: 50%;
  background: #ff3b30; color: #fff; font-size: .65rem; font-weight: 700;
  display: flex; align-items: center; justify-content: center;
  border: 2px solid var(--e);
}

@keyframes waPulse {
  0%, 100% { box-shadow: 0 4px 20px rgba(37,211,102,.45); }
  50%       { box-shadow: 0 4px 28px rgba(37,211,102,.75), 0 0 0 10px rgba(37,211,102,.08); }
}

/* Ventana del chat */
.chat-window {
  position: fixed; bottom: 6rem; right: 1.8rem; z-index: 1000;
  width: 340px; border-radius: 20px; overflow: hidden;
  box-shadow: 0 20px 60px rgba(0,0,0,.5);
  display: none; flex-direction: column;
  max-height: 520px;
  border: 1px solid rgba(37,211,102,.2);
}
.chat-window.open { display: flex; animation: slideUp .25s ease; }
@keyframes slideUp { from { opacity: 0; transform: translateY(16px); } to { opacity: 1; transform: none; } }

.chat-header {
  background: #075e54; padding: 1rem 1.2rem;
  display: flex; align-items: center; gap: .75rem;
}
.chat-avatar {
  width: 42px; height: 42px; border-radius: 50%;
  background: #25d366; display: flex; align-items: center; justify-content: center;
  font-size: 1.2rem; flex-shrink: 0;
}
.chat-header-name  { font-weight: 700; font-size: .95rem; color: #fff; line-height: 1.2; }
.chat-header-sub   { font-size: .72rem; color: rgba(255,255,255,.7); }
.chat-close {
  margin-left: auto; background: none; border: none; color: rgba(255,255,255,.7);
  font-size: 1.2rem; cursor: pointer; padding: .2rem; line-height: 1;
}
.chat-close:hover { color: #fff; }

.chat-body {
  background: #ece5dd; padding: 1rem; flex: 1;
  overflow-y: auto; display: flex; flex-direction: column; gap: .75rem;
  min-height: 200px;
}

/* Burbujas */
.bubble {
  max-width: 85%; padding: .6rem .9rem; border-radius: 12px;
  font-size: .85rem; line-height: 1.5; position: relative;
  word-break: break-word;
}
.bubble.bot  { background: #fff; color: #111; border-radius: 0 12px 12px 12px; align-self: flex-start; box-shadow: 0 1px 2px rgba(0,0,0,.12); }
.bubble.user { background: #dcf8c6; color: #111; border-radius: 12px 0 12px 12px; align-self: flex-end; box-shadow: 0 1px 2px rgba(0,0,0,.12); }
.bubble-time { font-size: .65rem; color: rgba(0,0,0,.4); margin-top: .25rem; display: block; text-align: right; }

/* Opciones rápidas */
.chat-options { display: flex; flex-wrap: wrap; gap: .4rem; margin-top: .2rem; }
.chat-opt {
  background: #fff; border: 1px solid #25d366; color: #075e54;
  font-size: .78rem; font-weight: 600; border-radius: 50px;
  padding: .3rem .8rem; cursor: pointer; transition: .15s;
}
.chat-opt:hover { background: #25d366; color: #fff; }

/* Footer del chat */
.chat-footer { background: #f0f0f0; padding: .75rem 1rem; border-top: 1px solid #ddd; }
.chat-input-row { display: flex; gap: .5rem; align-items: center; }
.chat-input {
  flex: 1; border: 1px solid #ddd; border-radius: 50px;
  padding: .5rem 1rem; font-size: .85rem; outline: none;
  color: #111; background: #fff;
}
.chat-input:focus { border-color: #25d366; }
.chat-send {
  width: 38px; height: 38px; border-radius: 50%; background: #25d366;
  border: none; cursor: pointer; display: flex; align-items: center; justify-content: center;
  color: #fff; font-size: 1rem; flex-shrink: 0; transition: .15s;
}
.chat-send:hover { background: #1da851; }

.wa-open-link {
  display: block; text-align: center; margin-top: .6rem;
  font-size: .75rem; color: #075e54; text-decoration: none; font-weight: 600;
}
.wa-open-link:hover { text-decoration: underline; }

/* Typing indicator */
.typing { display: flex; gap: 4px; align-items: center; padding: .5rem .8rem; }
.typing span { width: 7px; height: 7px; border-radius: 50%; background: #999; animation: dot 1.2s infinite; }
.typing span:nth-child(2) { animation-delay: .2s; }
.typing span:nth-child(3) { animation-delay: .4s; }
@keyframes dot { 0%, 60%, 100% { transform: translateY(0); } 30% { transform: translateY(-6px); } }

/* ============================================================
   SELECTOR DE IDIOMA
   ============================================================ */
.lang-switcher { display: flex; align-items: center; gap: .3rem; }

.lang-btn {
  background: transparent; border: 1px solid rgba(245,230,211,.15);
  color: rgba(245,230,211,.6); border-radius: 6px;
  padding: .25rem .55rem; font-size: .75rem; font-weight: 700;
  cursor: pointer; transition: .2s; letter-spacing: .5px;
  line-height: 1;
}
.lang-btn:hover  { border-color: var(--go); color: var(--go); }
.lang-btn.active { background: var(--go); border-color: var(--go); color: var(--e); }

/* ============================================================
   RESPONSIVE
   ============================================================ */
@media (max-width: 768px) {
  .hero-sub    { max-width: 100%; }
  .form-zb     { padding: 1.5rem; }
  .chat-window { width: calc(100vw - 2rem); right: 1rem; bottom: 5.5rem; }
}
