/* ============================================================
   WebClinic 18 Anos — style.css
   ============================================================ */

:root {
  --gold:        #EE6900;
  --gold-light:  #F2894A;
  --gold-dim:    rgba(238,105,0,0.15);
  --gold-glow:   rgba(238,105,0,0.45);
  --dark:        #0A0A0A;
  --dark-2:      #0D0D0D;
  --dark-3:      #111111;
  --parchment:   #F5F0E8;
  --parchment-2: #EEE8DC;
  --text-light:  rgba(255,255,255,0.88);
  --text-muted:  rgba(255,255,255,0.45);
  --font-serif:  'Cormorant Garamond', Georgia, 'Times New Roman', serif;
  --font-sans:   'Inter', -apple-system, BlinkMacSystemFont, sans-serif;
  --ease-out:    cubic-bezier(0.22, 1, 0.36, 1);
}

/* ── Reset & Base ─────────────────────────────────────────── */

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

html {
  scroll-behavior: smooth;
  font-size: 16px;
}

body {
  background: var(--dark);
  color: var(--text-light);
  font-family: var(--font-sans);
  font-weight: 300;
  line-height: 1.6;
  overflow-x: hidden;
  -webkit-font-smoothing: antialiased;
}

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

/* ── Keyframes ────────────────────────────────────────────── */

@keyframes nameMaterialise {
  from { opacity: 0; letter-spacing: 0.55em; filter: blur(6px); }
  to   { opacity: 1; letter-spacing: 0.08em;  filter: blur(0); }
}

@keyframes ruleDrawIn {
  from { transform: scaleX(0); opacity: 0; }
  to   { transform: scaleX(1); opacity: 1; }
}

@keyframes fadeIn {
  from { opacity: 0; }
  to   { opacity: 1; }
}

@keyframes fadeUp {
  from { opacity: 0; transform: translateY(28px); }
  to   { opacity: 1; transform: translateY(0); }
}

@keyframes chevronBounce {
  0%, 100% { transform: translateY(0);   opacity: 0.5; }
  50%       { transform: translateY(8px); opacity: 1; }
}

@keyframes pulseGlow {
  0%, 100% { box-shadow: 0 0 14px var(--gold-glow); }
  50%       { box-shadow: 0 0 32px var(--gold-glow), 0 0 60px rgba(238,105,0,0.2); }
}

@keyframes digitFlip {
  0%   { opacity: 1; transform: translateY(0); }
  49%  { opacity: 0; transform: translateY(-8px); }
  50%  { opacity: 0; transform: translateY(8px); }
  100% { opacity: 1; transform: translateY(0); }
}

/* ── Scroll Reveal ────────────────────────────────────────── */

.reveal {
  opacity: 0;
  transform: translateY(24px);
  transition: opacity 0.85s var(--ease-out), transform 0.85s var(--ease-out);
}
.reveal.is-visible { opacity: 1; transform: translateY(0); }
.reveal-d1 { transition-delay: 0.15s; }
.reveal-d2 { transition-delay: 0.3s; }
.reveal-d3 { transition-delay: 0.45s; }

/* ── 1. HERO ──────────────────────────────────────────────── */

#hero {
  position: relative;
  height: 100vh;
  min-height: 600px;
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
  background: var(--dark);
}

#particles-js {
  position: absolute;
  inset: 0;
  pointer-events: none;
}

.hero-content {
  position: relative;
  z-index: 2;
  text-align: center;
  padding: 0 24px;
  max-width: 760px;
  width: 100%;
}

.hero-logo {
  width: clamp(90px, 18vw, 130px);
  margin: 0 auto 28px;
  animation: fadeIn 1s var(--ease-out) 0.2s both;
}

.hero-rule {
  width: clamp(60px, 14vw, 100px);
  height: 1px;
  background: var(--gold);
  margin: 0 auto 24px;
  transform-origin: center;
  animation: ruleDrawIn 0.9s var(--ease-out) 0.6s both;
}

.hero-label {
  font-family: var(--font-sans);
  font-size: clamp(0.6rem, 1.6vw, 0.72rem);
  letter-spacing: 0.28em;
  text-transform: uppercase;
  color: var(--gold);
  margin-bottom: 12px;
  animation: fadeIn 0.8s var(--ease-out) 0.7s both;
}

.hero-intro {
  font-family: var(--font-serif);
  font-style: italic;
  font-size: clamp(1rem, 2.4vw, 1.35rem);
  color: var(--text-muted);
  margin-bottom: 16px;
  animation: fadeIn 0.8s var(--ease-out) 0.9s both;
}

.hero-name {
  font-family: var(--font-serif);
  font-weight: 300;
  font-size: clamp(2.4rem, 7vw, 5.2rem);
  color: var(--gold);
  line-height: 1.1;
  opacity: 0;
  will-change: opacity, letter-spacing, filter;
}
.hero-name.name-animate {
  animation: nameMaterialise 1.4s var(--ease-out) forwards;
}

.hero-rule-bottom {
  width: clamp(60px, 14vw, 100px);
  height: 1px;
  background: linear-gradient(to right, transparent, var(--gold), transparent);
  margin: 28px auto 0;
  animation: fadeIn 0.8s var(--ease-out) 2s both;
}

.hero-scroll {
  position: absolute;
  bottom: 36px;
  left: 50%;
  transform: translateX(-50%);
  z-index: 2;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 6px;
  animation: fadeIn 1s var(--ease-out) 2.4s both;
}
.hero-scroll span {
  font-size: 0.6rem;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  color: var(--text-muted);
}
.hero-scroll i {
  color: var(--gold);
  font-size: 0.75rem;
  animation: chevronBounce 1.8s ease-in-out infinite;
}

/* ── 2. DETALHES DO EVENTO ────────────────────────────────── */

#detalhes {
  background: var(--dark-2);
  padding: clamp(72px, 10vw, 120px) 24px;
}

.detalhes-inner {
  max-width: 860px;
  margin: 0 auto;
}

.detalhes-heading {
  text-align: center;
  margin-bottom: 64px;
}
.detalhes-heading h2 {
  font-family: var(--font-serif);
  font-weight: 300;
  font-size: clamp(2rem, 5vw, 3.2rem);
  color: var(--text-light);
  margin-bottom: 10px;
}
.detalhes-heading p {
  font-family: var(--font-serif);
  font-style: italic;
  font-size: clamp(1rem, 2vw, 1.2rem);
  color: var(--text-muted);
}

.detalhes-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 40px;
}

@media (min-width: 600px) {
  .detalhes-grid { grid-template-columns: repeat(3, 1fr); gap: 32px; }
}

.detalhe-item {
  text-align: center;
}

.detalhe-label {
  font-size: 0.62rem;
  letter-spacing: 0.3em;
  text-transform: uppercase;
  color: var(--gold);
  margin-bottom: 14px;
}

.detalhe-value {
  font-family: var(--font-serif);
  font-size: clamp(1.5rem, 3.5vw, 2rem);
  color: var(--text-light);
  line-height: 1.25;
  margin-bottom: 6px;
}

.detalhe-sub {
  font-size: 0.78rem;
  color: var(--text-muted);
  letter-spacing: 0.05em;
}

.detalhe-underline {
  width: 40px;
  height: 1px;
  background: var(--gold);
  margin: 16px auto 0;
  transform-origin: left;
  transform: scaleX(0);
  opacity: 0;
  transition: transform 0.7s var(--ease-out), opacity 0.7s var(--ease-out);
}
.detalhe-item.is-visible .detalhe-underline {
  transform: scaleX(1);
  opacity: 1;
}

/* ── 3. CONTADOR REGRESSIVO ───────────────────────────────── */

#countdown {
  background: var(--dark-3);
  padding: clamp(64px, 9vw, 100px) 24px;
  text-align: center;
}

.countdown-label {
  font-size: 0.65rem;
  letter-spacing: 0.28em;
  text-transform: uppercase;
  color: var(--text-muted);
  margin-bottom: 40px;
}

.countdown-grid {
  display: inline-grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 20px;
  max-width: 480px;
  width: 100%;
}

@media (min-width: 480px) {
  .countdown-grid { grid-template-columns: repeat(4, 1fr); gap: 16px; }
}

.countdown-box {
  border: 1px solid rgba(238,105,0,0.25);
  padding: 20px 12px 16px;
  background: rgba(238,105,0,0.04);
}

.countdown-num {
  font-family: var(--font-serif);
  font-size: clamp(2.4rem, 6vw, 3.6rem);
  font-weight: 300;
  color: var(--gold);
  line-height: 1;
  display: block;
  transition: opacity 0.15s;
}
.countdown-num.digit-flip {
  animation: digitFlip 0.3s ease;
}

.countdown-unit {
  display: block;
  font-size: 0.58rem;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  color: var(--text-muted);
  margin-top: 8px;
}

#post-event {
  display: none;
  font-family: var(--font-serif);
  font-style: italic;
  font-size: clamp(1.1rem, 2.5vw, 1.5rem);
  color: var(--text-muted);
}

/* ── 4. RSVP ──────────────────────────────────────────────── */

#rsvp {
  background: var(--dark-2);
  padding: clamp(72px, 10vw, 120px) 24px;
}

.rsvp-inner {
  max-width: 540px;
  margin: 0 auto;
}

.rsvp-heading {
  text-align: center;
  margin-bottom: 48px;
}

.rsvp-heading h2 {
  font-family: var(--font-serif);
  font-weight: 300;
  font-size: clamp(1.8rem, 4vw, 2.6rem);
  color: var(--text-light);
  margin-bottom: 8px;
}

.rsvp-heading p {
  font-family: var(--font-serif);
  font-style: italic;
  font-size: 1rem;
  color: var(--text-muted);
}

/* Card */
.rsvp-card {
  background: var(--parchment);
  border-top: 3px solid var(--gold);
  border-radius: 2px;
  padding: clamp(32px, 6vw, 48px) clamp(24px, 5vw, 40px);
  box-shadow: 0 24px 80px rgba(0,0,0,0.6), 0 0 0 1px rgba(238,105,0,0.08);
  color: #1a1208;
}

/* Form fields */
.rsvp-field-wrap {
  position: relative;
  margin-bottom: 28px;
}

.rsvp-label {
  display: flex;
  align-items: center;
  gap: 6px;
  font-size: 0.62rem;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  color: #7a6a50;
  margin-bottom: 6px;
}
.rsvp-label .optional {
  font-style: italic;
  text-transform: none;
  letter-spacing: 0;
  font-size: 0.7em;
  color: #b0a08a;
}

.rsvp-field {
  width: 100%;
  background: transparent;
  border: none;
  border-bottom: 1px solid rgba(0,0,0,0.18);
  border-radius: 0;
  font-family: var(--font-sans);
  font-size: 1rem;
  font-weight: 400;
  color: #1a1208;
  padding: 8px 0;
  transition: border-color 0.3s;
  -webkit-appearance: none;
}
.rsvp-field:focus {
  outline: none;
  border-bottom-color: var(--gold);
}
.rsvp-field[readonly] {
  background: var(--parchment-2);
  padding: 8px 10px;
  border-bottom-color: transparent;
  cursor: default;
}
.rsvp-field::placeholder { color: #b0a08a; }

.field-lock {
  position: absolute;
  right: 0;
  bottom: 10px;
  color: #b0a08a;
  font-size: 0.75rem;
  display: none;
}

.field-error {
  font-size: 0.72rem;
  color: #b33000;
  margin-top: 4px;
  display: none;
}
.field-error.visible { display: block; }

.honeypot { display: none !important; }

/* Decline toggle */
.decline-toggle {
  margin-bottom: 28px;
}
.decline-toggle label {
  display: flex;
  align-items: center;
  gap: 10px;
  cursor: pointer;
  font-size: 0.85rem;
  color: #7a6a50;
  user-select: none;
}
.decline-toggle input[type="checkbox"] {
  width: 16px;
  height: 16px;
  accent-color: var(--gold);
  cursor: pointer;
}

/* Buttons */
.btn-confirmar {
  display: block;
  width: 100%;
  padding: 16px;
  background: var(--gold);
  color: #fff;
  font-family: var(--font-sans);
  font-size: 0.72rem;
  font-weight: 400;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  border: none;
  border-radius: 1px;
  cursor: pointer;
  transition: background 0.25s, box-shadow 0.25s;
  animation: pulseGlow 3s ease-in-out infinite;
}
.btn-confirmar:hover  { background: var(--gold-light); }
.btn-confirmar:active { background: #cc5500; }
.btn-confirmar:disabled {
  opacity: 0.6;
  cursor: not-allowed;
  animation: none;
}

.form-error-msg {
  margin-top: 14px;
  padding: 10px 14px;
  background: rgba(179,48,0,0.1);
  border-left: 2px solid #b33000;
  font-size: 0.82rem;
  color: #b33000;
  display: none;
}
.form-error-msg.visible { display: block; }

/* Success state */
.rsvp-success {
  display: none;
  text-align: center;
  padding: 16px 0;
}
.rsvp-success .success-icon {
  font-size: 2.8rem;
  color: var(--gold);
  margin-bottom: 20px;
}
.rsvp-success h3 {
  font-family: var(--font-serif);
  font-weight: 300;
  font-size: 1.6rem;
  color: #1a1208;
  margin-bottom: 10px;
}
.rsvp-success p {
  font-family: var(--font-serif);
  font-style: italic;
  color: #7a6a50;
  font-size: 1rem;
}
.rsvp-success .success-name {
  color: var(--gold);
  font-style: normal;
}

/* ── 5. RODAPÉ / 18 ANOS ──────────────────────────────────── */

#anos {
  background: var(--dark);
  padding: clamp(80px, 12vw, 140px) 24px clamp(60px, 9vw, 100px);
  text-align: center;
}

.anos-number {
  font-family: var(--font-serif);
  font-weight: 300;
  font-size: clamp(7rem, 22vw, 16rem);
  color: var(--gold);
  line-height: 0.85;
  opacity: 0.12;
  user-select: none;
  margin-bottom: -0.1em;
  position: relative;
  z-index: 0;
}

.anos-content {
  position: relative;
  z-index: 1;
}

.anos-since {
  font-size: 0.65rem;
  letter-spacing: 0.28em;
  text-transform: uppercase;
  color: var(--gold);
  margin-bottom: 20px;
}

.anos-message {
  font-family: var(--font-serif);
  font-weight: 300;
  font-size: clamp(1.1rem, 2.5vw, 1.5rem);
  color: var(--text-light);
  line-height: 1.55;
  max-width: 480px;
  margin: 0 auto 32px;
}

.anos-logo {
  width: clamp(70px, 14vw, 100px);
  margin: 0 auto 20px;
  opacity: 0.7;
  transition: opacity 0.3s;
}
.anos-logo:hover { opacity: 1; }

/* ── Acesso Restrito ──────────────────────────────────────── */

.restricted {
  height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  background: var(--dark);
}

.restricted-inner {
  text-align: center;
  padding: 24px;
  max-width: 360px;
}

.restricted-icon {
  color: rgba(255,255,255,0.15);
  margin-bottom: 24px;
}

.restricted-title {
  font-family: var(--font-serif);
  font-size: 1.4rem;
  font-weight: 300;
  color: var(--text-muted);
  margin-bottom: 12px;
}

.restricted-msg {
  font-size: 0.82rem;
  color: rgba(255,255,255,0.25);
  line-height: 1.7;
}

/* ── RSVP — lock icon ─────────────────────────────────────── */

.rsvp-lock-icon {
  font-size: 0.6em;
  color: #b0a08a;
  opacity: 0.7;
  margin-left: 4px;
  vertical-align: middle;
}

/* ── RSVP — dois botões ───────────────────────────────────── */

.rsvp-actions {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.btn-decline {
  display: block;
  width: 100%;
  padding: 13px;
  background: transparent;
  color: #7a6a50;
  font-family: var(--font-sans);
  font-size: 0.72rem;
  font-weight: 400;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  border: 1px solid rgba(0,0,0,0.15);
  border-radius: 1px;
  cursor: pointer;
  transition: border-color 0.25s, color 0.25s;
}
.btn-decline:hover  { border-color: rgba(0,0,0,0.3); color: #4a3a20; }
.btn-decline:disabled { opacity: 0.5; cursor: not-allowed; }

/* ── RSVP — restrição alimentar ──────────────────────────── */

.rsvp-checkbox-label {
  display: flex;
  align-items: center;
  gap: 10px;
  cursor: pointer;
  color: #8a7a60;
  font-size: 0.72rem;
  letter-spacing: 0.1em;
}

.rsvp-checkbox-label input[type="checkbox"] {
  width: 16px;
  height: 16px;
  accent-color: var(--gold);
  cursor: pointer;
  flex-shrink: 0;
}

.rsvp-textarea {
  resize: vertical;
  min-height: 72px;
  font-family: var(--font-sans);
  font-size: 0.85rem;
  line-height: 1.5;
}

/* ── FOOTER ───────────────────────────────────────────────── */

footer {
  background: var(--dark-3);
  padding: 28px 24px;
  text-align: center;
  border-top: 1px solid rgba(255,255,255,0.05);
}

.footer-text {
  font-size: 0.72rem;
  color: var(--text-muted);
  letter-spacing: 0.05em;
  line-height: 1.8;
}

.footer-text a {
  color: var(--text-muted);
  border-bottom: 1px solid rgba(255,255,255,0.15);
  transition: color 0.2s;
}
.footer-text a:hover { color: var(--gold); }

.footer-sep { margin: 0 8px; opacity: 0.3; }
