@import url('https://fonts.googleapis.com/css2?family=Playfair+Display:wght@400;600;700;900&family=Cormorant+Garamond:ital,wght@0,300;0,400;0,500;1,300;1,400&family=Montserrat:wght@300;400;500;600&display=swap');

:root {
  --bg-dark:    #0a0804;
  --bg-mid:     #110e07;
  --bg-card:    #1a1509;
  --gold:       #c9953a;
  --gold-light: #e8b96a;
  --gold-pale:  #f5dfa0;
  --cream:      #f2e8d0;
  --text:       #e8dcc8;
  --text-muted: #8a7a5a;
  --border:     #2e2410;
  --border-gold:#3d2f10;
  --red:        #c0392b;
  --green:      #27ae60;
  --radius:     4px;
  --shadow:     0 8px 32px rgba(0,0,0,0.6);
}

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

html { scroll-behavior: smooth; }

body {
  background-color: var(--bg-dark);
  color: var(--text);
  font-family: 'Montserrat', sans-serif;
  font-weight: 300;
  min-height: 100vh;
  overflow-x: hidden;
}

/* Subtle grain overlay */
body::before {
  content: '';
  position: fixed;
  inset: 0;
  background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 256 256' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='noise'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.9' numOctaves='4' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23noise)' opacity='0.04'/%3E%3C/svg%3E");
  pointer-events: none;
  z-index: 1000;
  opacity: 0.4;
}

/* ── NAV ── */
nav {
  position: fixed;
  top: 0; left: 0; right: 0;
  z-index: 100;
  background: linear-gradient(180deg, rgba(10,8,4,0.98) 0%, rgba(10,8,4,0.85) 100%);
  border-bottom: 1px solid var(--border-gold);
  backdrop-filter: blur(12px);
}

.nav-inner {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 2rem;
  display: flex;
  align-items: center;
  justify-content: center;
  height: 60px;
}

.nav-logo {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  text-decoration: none;
}

.nav-logo-icon {
  font-size: 1.6rem;
  line-height: 1;
}

.nav-logo-text {
  font-family: 'Playfair Display', serif;
  font-size: 1.2rem;
  font-weight: 700;
  color: var(--gold-light);
  letter-spacing: 0.05em;
  line-height: 1.1;
}

.nav-logo-sub {
  display: block;
  font-family: 'Montserrat', sans-serif;
  font-size: 0.55rem;
  font-weight: 400;
  color: var(--text-muted);
  letter-spacing: 0.2em;
  text-transform: uppercase;
}

.nav-links {
  display: flex;
  gap: 0.25rem;
  list-style: none;
}

.nav-links a {
  display: block;
  padding: 0.5rem 0.9rem;
  font-size: 0.72rem;
  font-weight: 500;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  text-decoration: none;
  color: var(--text-muted);
  border-radius: var(--radius);
  transition: color 0.2s, background 0.2s;
  cursor: pointer;
}

.nav-links a:hover,
.nav-links a.active {
  color: var(--gold-light);
  background: rgba(201,149,58,0.1);
}

/* ── LAYOUT ── */
main {
  padding-top: 60px;
  min-height: 100vh;
}

.page { display: none; animation: fadeUp 0.4s ease both; }
.page.active { display: block; }

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

/* ── HERO (Inicio) ── */
.hero {
  position: relative;
  min-height: calc(100vh - 60px);
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
  padding: 3rem 1.25rem;
  overflow: hidden;
}

.hero-bg {
  position: absolute;
  inset: 0;
  background:
    radial-gradient(ellipse 80% 60% at 50% 40%, rgba(201,149,58,0.08) 0%, transparent 70%),
    radial-gradient(ellipse 40% 40% at 20% 80%, rgba(201,149,58,0.04) 0%, transparent 60%),
    linear-gradient(180deg, var(--bg-dark) 0%, var(--bg-mid) 100%);
}

.hero-ornament {
  position: absolute;
  width: 600px;
  height: 600px;
  border: 1px solid rgba(201,149,58,0.06);
  border-radius: 50%;
  top: 50%; left: 50%;
  transform: translate(-50%, -50%);
}
.hero-ornament:nth-child(2) { width: 800px; height: 800px; border-color: rgba(201,149,58,0.03); }
.hero-ornament:nth-child(3) { width: 1000px; height: 1000px; border-color: rgba(201,149,58,0.02); }

.hero-content { position: relative; z-index: 2; max-width: 760px; }

.hero-badge {
  display: inline-block;
  padding: 0.35rem 1.2rem;
  border: 1px solid var(--gold);
  border-radius: 100px;
  font-size: 0.65rem;
  font-weight: 600;
  letter-spacing: 0.25em;
  text-transform: uppercase;
  color: var(--gold);
  margin-bottom: 2rem;
  animation: fadeUp 0.6s 0.1s both;
}

.hero-title {
  font-family: 'Playfair Display', serif;
  font-size: clamp(3.5rem, 8vw, 6.5rem);
  font-weight: 900;
  line-height: 0.95;
  color: var(--cream);
  letter-spacing: -0.02em;
  animation: fadeUp 0.6s 0.2s both;
}

.hero-title span {
  display: block;
  background: linear-gradient(135deg, var(--gold) 0%, var(--gold-pale) 50%, var(--gold) 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

.hero-subtitle {
  font-family: 'Cormorant Garamond', serif;
  font-size: 1.35rem;
  font-style: italic;
  color: var(--text-muted);
  margin-top: 1.5rem;
  animation: fadeUp 0.6s 0.3s both;
}

.hero-date {
  margin-top: 3rem;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 1.5rem;
  animation: fadeUp 0.6s 0.4s both;
}

.hero-date-block {
  text-align: center;
}

.hero-date-num {
  font-family: 'Playfair Display', serif;
  font-size: 2.5rem;
  font-weight: 700;
  color: var(--gold-light);
  line-height: 1;
}

.hero-date-label {
  font-size: 0.6rem;
  font-weight: 600;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: var(--text-muted);
  margin-top: 0.25rem;
}

.hero-divider {
  width: 1px;
  height: 40px;
  background: var(--border-gold);
}

.hero-cta {
  margin-top: 3.5rem;
  display: flex;
  gap: 1rem;
  justify-content: center;
  flex-wrap: wrap;
  animation: fadeUp 0.6s 0.5s both;
}

.hero-info {
  margin-top: 5rem;
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1px;
  border: 1px solid var(--border-gold);
  background: var(--border-gold);
  animation: fadeUp 0.6s 0.6s both;
}

.hero-info-item {
  background: var(--bg-card);
  padding: 1.5rem;
  text-align: center;
}

.hero-info-icon { font-size: 1.5rem; margin-bottom: 0.5rem; }
.hero-info-title {
  font-family: 'Playfair Display', serif;
  font-size: 0.9rem;
  font-weight: 600;
  color: var(--gold-light);
  margin-bottom: 0.25rem;
}
.hero-info-text { font-size: 0.75rem; color: var(--text-muted); line-height: 1.5; }

/* ── BUTTONS ── */
.btn {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.75rem 1.8rem;
  font-family: 'Montserrat', sans-serif;
  font-size: 0.72rem;
  font-weight: 600;
  letter-spacing: 0.15em;
  text-transform: uppercase;
  border: none;
  border-radius: var(--radius);
  cursor: pointer;
  transition: all 0.2s ease;
  text-decoration: none;
}

.btn-primary {
  background: linear-gradient(135deg, var(--gold) 0%, var(--gold-light) 100%);
  color: var(--bg-dark);
}
.btn-primary:hover {
  background: linear-gradient(135deg, var(--gold-light) 0%, var(--gold-pale) 100%);
  transform: translateY(-1px);
  box-shadow: 0 6px 20px rgba(201,149,58,0.35);
}

.btn-outline {
  background: transparent;
  color: var(--gold-light);
  border: 1px solid var(--gold);
}
.btn-outline:hover {
  background: rgba(201,149,58,0.1);
  transform: translateY(-1px);
}

.btn-sm { padding: 0.5rem 1.1rem; font-size: 0.65rem; }
.btn-danger { background: var(--red); color: white; }
.btn-danger:hover { background: #a93226; }
.btn-success { background: var(--green); color: white; }
.btn-success:hover { background: #229954; }

/* ── PAGE SECTIONS ── */
.page-header {
  background: linear-gradient(180deg, var(--bg-mid) 0%, var(--bg-dark) 100%);
  padding: 4rem 2rem 3rem;
  text-align: center;
  border-bottom: 1px solid var(--border);
  position: relative;
  overflow: hidden;
}

.page-header::before {
  content: '';
  position: absolute;
  top: 0; left: 50%; transform: translateX(-50%);
  width: 400px; height: 1px;
  background: linear-gradient(90deg, transparent, var(--gold), transparent);
}

.page-header-icon { font-size: 2rem; margin-bottom: 1rem; }

.page-title {
  font-family: 'Playfair Display', serif;
  font-size: clamp(2rem, 4vw, 3rem);
  font-weight: 700;
  color: var(--cream);
  letter-spacing: -0.02em;
}

.page-subtitle {
  font-family: 'Cormorant Garamond', serif;
  font-style: italic;
  color: var(--text-muted);
  font-size: 1.1rem;
  margin-top: 0.5rem;
}

.page-content {
  max-width: 800px;
  margin: 0 auto;
  padding: 3rem 2rem;
}

.page-content-wide {
  max-width: 1100px;
  margin: 0 auto;
  padding: 3rem 2rem;
}

/* ── CARDS & FORMS ── */
.card {
  background: var(--bg-card);
  border: 1px solid var(--border-gold);
  border-radius: var(--radius);
  padding: 2rem;
  box-shadow: var(--shadow);
}

.card + .card { margin-top: 1.5rem; }

.form-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 1.25rem;
}

.form-grid .full { grid-column: 1 / -1; }

.form-group { display: flex; flex-direction: column; gap: 0.5rem; }

label {
  font-size: 0.68rem;
  font-weight: 600;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--gold);
}

input, select, textarea {
  background: rgba(255,255,255,0.03);
  border: 1px solid var(--border-gold);
  border-radius: var(--radius);
  padding: 0.75rem 1rem;
  color: var(--text);
  font-family: 'Montserrat', sans-serif;
  font-size: 0.85rem;
  font-weight: 300;
  width: 100%;
  transition: border-color 0.2s, box-shadow 0.2s;
  outline: none;
}

input:focus, select:focus, textarea:focus {
  border-color: var(--gold);
  box-shadow: 0 0 0 3px rgba(201,149,58,0.12);
}

select option { background: var(--bg-card); }

.form-actions {
  margin-top: 2rem;
  display: flex;
  gap: 1rem;
  justify-content: flex-end;
}

/* ── RESPONSE BOX ── */
.response-box {
  margin-top: 1.5rem;
  padding: 1.25rem 1.5rem;
  border-radius: var(--radius);
  font-size: 0.85rem;
  line-height: 1.6;
  display: none;
}

.response-box.show { display: block; }
.response-box.success { background: rgba(39,174,96,0.1); border: 1px solid rgba(39,174,96,0.3); color: #5dbb7e; }
.response-box.error   { background: rgba(192,57,43,0.1);  border: 1px solid rgba(192,57,43,0.3);  color: #e57878; }
.response-box.info    { background: rgba(201,149,58,0.1); border: 1px solid rgba(201,149,58,0.3); color: var(--gold-light); }

.response-box pre {
  font-family: 'Montserrat', monospace;
  white-space: pre-wrap;
  word-break: break-all;
  font-size: 0.78rem;
}

/* ── TABLE ── */
.table-wrapper { overflow-x: auto; }

table {
  width: 100%;
  border-collapse: collapse;
  font-size: 0.82rem;
}

thead tr {
  border-bottom: 1px solid var(--gold);
}

th {
  padding: 0.75rem 1rem;
  text-align: left;
  font-size: 0.65rem;
  font-weight: 600;
  letter-spacing: 0.15em;
  text-transform: uppercase;
  color: var(--gold);
}

td {
  padding: 0.9rem 1rem;
  color: var(--text);
  border-bottom: 1px solid var(--border);
}

tbody tr:hover { background: rgba(201,149,58,0.04); }

.badge {
  display: inline-block;
  padding: 0.2rem 0.65rem;
  border-radius: 100px;
  font-size: 0.65rem;
  font-weight: 600;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.badge-pending  { background: rgba(201,149,58,0.15); color: var(--gold-light); border: 1px solid rgba(201,149,58,0.3); }
.badge-accepted { background: rgba(39,174,96,0.15);  color: #5dbb7e;           border: 1px solid rgba(39,174,96,0.3); }
.badge-rejected { background: rgba(192,57,43,0.15);  color: #e57878;           border: 1px solid rgba(192,57,43,0.3); }
.badge-paid     { background: rgba(52,152,219,0.15); color: #7bb8e8;           border: 1px solid rgba(52,152,219,0.3); }

/* ── LOADING ── */
.loading {
  display: none;
  align-items: center;
  gap: 0.75rem;
  color: var(--gold);
  font-size: 0.8rem;
  margin-top: 1rem;
}
.loading.show { display: flex; }

.spinner {
  width: 18px; height: 18px;
  border: 2px solid var(--border-gold);
  border-top-color: var(--gold);
  border-radius: 50%;
  animation: spin 0.7s linear infinite;
}
@keyframes spin { to { transform: rotate(360deg); } }

/* ── ORNAMENTAL DIVIDER ── */
.ornament {
  display: flex;
  align-items: center;
  gap: 1rem;
  margin: 2rem 0;
  color: var(--text-muted);
  font-size: 1rem;
}
.ornament::before,
.ornament::after {
  content: '';
  flex: 1;
  height: 1px;
  background: linear-gradient(90deg, transparent, var(--border-gold), transparent);
}

/* ── FOOTER ── */
footer {
  border-top: 1px solid var(--border);
  padding: 2rem;
  text-align: center;
  color: var(--text-muted);
  font-size: 0.72rem;
  letter-spacing: 0.08em;
  background: var(--bg-mid);
}

/* ── RESPONSIVE ── */
@media (max-width: 680px) {
  .form-grid { grid-template-columns: 1fr; }

  .hero { padding: 2rem 1.25rem; }
  .hero-title { font-size: 3rem; }
  .hero-subtitle { font-size: 1.1rem; }
  .hero-date { gap: 1rem; }
  .hero-date-num { font-size: 1.8rem; }
  .hero-cta { flex-direction: column; align-items: stretch; gap: 0.75rem; margin-top: 2.5rem; }
  .hero-cta .btn { width: 100%; justify-content: center; padding: 1rem; font-size: 0.8rem; }

  .page-header { padding: 2.5rem 1.25rem 2rem; }
  .page-content, .page-content-wide { padding: 1.5rem 1rem; }

  .card { padding: 1.25rem; }

  input, select, textarea { font-size: 1rem; padding: 0.9rem 0.9rem; }

  .form-actions { justify-content: stretch; }
  .form-actions .btn { width: 100%; justify-content: center; padding: 1rem; }

  .btn-sm { padding: 0.6rem 0.9rem; font-size: 0.7rem; }

  table { font-size: 0.75rem; }
  th, td { padding: 0.65rem 0.6rem; }
}
