/* ==========================================================================
   Navalha & Cia — Estilos personalizados
   (o layout principal usa classes do Tailwind no index.html)

   Índice:
   1. Variáveis e base
   2. Utilitários de cor e tipografia
   3. Componentes (botões, cards, campos, FAQ)
   4. Seções (header, hero, agendamento)
   5. Animações
   ========================================================================== */


/* 1. VARIÁVEIS E BASE
   -------------------------------------------------------------------------- */

:root {
  --bg:      #0e0e0f;
  --surface: #161617;
  --card:    #1c1c1e;
  --line:    #2c2c2f;
  --text:    #f4f1ea;
  --muted:   #a29d92;
  --gold:    #c9a14a;
  --gold-t:  #141210;
  --busy:    #3a3a3d;

  /* Áreas seguras do celular */
  box-sizing: border-box;
  padding-top: env(safe-area-inset-top, 0px);
  padding-bottom: env(safe-area-inset-bottom, 0px);
}

html {
  scroll-behavior: smooth;
  scroll-padding-top: calc(68px + env(safe-area-inset-top, 0px));
}

body {
  background: var(--bg);
  color: var(--text);
  font-family: Inter, system-ui, sans-serif;
  overflow-x: hidden;
}


/* 2. UTILITÁRIOS DE COR E TIPOGRAFIA
   -------------------------------------------------------------------------- */

.font-display { font-family: "Playfair Display", Georgia, serif; }
.text-gold    { color: var(--gold); }
.text-muted   { color: var(--muted); }
.text-white   { color: var(--text); }
.bg-surface   { background: var(--surface); }
.border-line  { border-color: var(--line); }

.eyebrow {
  color: var(--gold);
  font-size: 0.8rem;
  font-weight: 600;
  letter-spacing: 0.15em;
  text-transform: uppercase;
  margin-bottom: 0.75rem;
}

.section       { padding: 5rem 0; }
.section-title { font-family: "Playfair Display", Georgia, serif; font-size: clamp(1.75rem, 4vw, 2.5rem); font-weight: 800; }

@media (min-width: 768px) {
  .section { padding: 7rem 0; }
}


/* 3. COMPONENTES
   -------------------------------------------------------------------------- */

/* Botões */
.btn {
  display: inline-block;
  padding: 0.85rem 1.6rem;
  border-radius: 6px;
  font-weight: 600;
  transition: 0.2s;
}

.btn-gold { background: var(--gold); color: var(--gold-t); }
.btn-gold:hover { filter: brightness(1.1); transform: translateY(-2px); }

.btn-outline { border: 1.5px solid var(--gold); color: var(--gold); }
.btn-outline:hover { background: var(--gold); color: var(--gold-t); }

.btn.disabled { opacity: 0.4; pointer-events: none; }

/* Cards */
.card {
  position: relative;
  background: var(--card);
  border: 1px solid var(--line);
  border-radius: 12px;
}

.card-featured { border-color: var(--gold); }

.badge {
  position: absolute;
  top: -12px;
  left: 1.75rem;
  background: var(--gold);
  color: var(--gold-t);
  font-size: 0.75rem;
  font-weight: 700;
  padding: 0.2rem 0.75rem;
  border-radius: 999px;
}

/* Lista de benefícios dos planos */
.plan-list { margin: 1.25rem 0 1.75rem; display: grid; gap: 0.6rem; color: var(--muted); }
.plan-list li::before { content: "✓ "; color: var(--gold); font-weight: 700; }

/* Campos de formulário */
.field {
  width: 100%;
  padding: 0.8rem 1rem;
  background: var(--surface);
  color: var(--text);
  border: 1px solid var(--line);
  border-radius: 8px;
  color-scheme: dark;
}

.field:focus { outline: 2px solid var(--gold); outline-offset: 1px; }

/* Opções selecionáveis (serviços, barbeiros, horários) */
.option {
  text-align: left;
  padding: 0.9rem 1rem;
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: 8px;
  transition: 0.15s;
}

.option:hover { border-color: var(--gold); }
.option.selected { border-color: var(--gold); background: color-mix(in srgb, var(--gold) 14%, var(--surface)); }
.option.busy { background: var(--busy); color: var(--muted); text-decoration: line-through; pointer-events: none; }

/* Título de cada passo do agendamento */
.step-title { display: flex; align-items: center; gap: 0.6rem; font-weight: 700; margin-bottom: 0.9rem; }
.step-title span {
  display: grid; place-items: center;
  width: 1.7rem; height: 1.7rem;
  background: var(--gold); color: var(--gold-t);
  border-radius: 50%; font-size: 0.85rem;
}

/* Resumo do agendamento */
.summary { padding: 1rem; border: 1px dashed var(--line); border-radius: 8px; color: var(--muted); font-size: 0.95rem; }
.summary strong { color: var(--text); }

/* FAQ (usa <details> nativo, sem JS) */
.faq { background: var(--card); border: 1px solid var(--line); border-radius: 10px; padding: 1.1rem 1.25rem; }
.faq summary { cursor: pointer; font-weight: 600; list-style: none; display: flex; justify-content: space-between; gap: 1rem; }
.faq summary::after { content: "+"; color: var(--gold); font-size: 1.25rem; line-height: 1; }
.faq[open] summary::after { content: "−"; }
.faq p { margin-top: 0.75rem; color: var(--muted); }


/* 4. SEÇÕES
   -------------------------------------------------------------------------- */

/* Header fixo com desfoque */
.site-header {
  padding-top: env(safe-area-inset-top, 0px);
  background: color-mix(in srgb, var(--bg) 85%, transparent);
  backdrop-filter: blur(10px);
  border-bottom: 1px solid var(--line);
}

#menu a { color: var(--text); }
#menu.open { display: flex; }

/* Hero */
.hero {
  background:
    radial-gradient(900px 450px at 85% 0%, color-mix(in srgb, var(--gold) 20%, transparent), transparent),
    var(--bg);
}

/* Poste de barbeiro */
.pole-wrap { display: flex; flex-direction: column; align-items: center; }
.pole-cap  { width: 110px; height: 22px; background: var(--gold); border-radius: 12px; }
.pole {
  width: 80px;
  height: 300px;
  border: 3px solid var(--line);
  background: repeating-linear-gradient(-45deg, #f4f1ea 0 18px, #b3262b 18px 36px, #f4f1ea 36px 54px, #20418a 54px 72px);
  background-size: 102px 102px;
  animation: spin 2.5s linear infinite;
}


/* 5. ANIMAÇÕES
   -------------------------------------------------------------------------- */

@keyframes spin {
  to { background-position: 0 102px; }
}

.reveal { opacity: 0; transform: translateY(24px); transition: 0.7s; }
.reveal.in { opacity: 1; transform: none; }

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .pole { animation: none; }
  .reveal { opacity: 1; transform: none; transition: none; }
}
