@import url('https://fonts.googleapis.com/css2?family=Playfair+Display:wght@700;900&family=Inter:wght@400;500;600&display=swap');

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

/* ── DARK THEME (default) ── */
:root, [data-theme="dark"] {
  --negro:       #0D0D0D;
  --carbon:      #1A1A1A;
  --humo:        #2B2B2B;
  --hover-card:  #323232;
  --arena:       #E8DDD0;
  --crema:       #FAF7F2;
  --oro:         #C8963E;
  --oro-suave:   #E8B96A;
  --blanco:      #FFFFFF;
  --fondo:       #0D0D0D;
  --borde:       rgba(255,255,255,0.06);
  --texto-muted: rgba(232,221,208,0.4);
  --texto-sec:   rgba(232,221,208,0.65);
  --chat-bg:     #111;
}

/* ── LIGHT THEME ── */
[data-theme="light"] {
  --negro:       #FFFFFF;
  --carbon:      #F5F3EF;
  --humo:        #EDE9E2;
  --hover-card:  #E5E0D8;
  --arena:       #3A2E22;
  --crema:       #1A1209;
  --oro:         #A8721E;
  --oro-suave:   #C8963E;
  --blanco:      #FFFFFF;
  --fondo:       #FFFFFF;
  --borde:       rgba(0,0,0,0.08);
  --texto-muted: rgba(58,46,34,0.5);
  --texto-sec:   rgba(58,46,34,0.75);
  --chat-bg:     #F9F7F3;
}

html { scroll-behavior: smooth; }
body { font-family: 'Inter', sans-serif; background: var(--fondo); color: var(--arena); overflow-x: hidden; transition: background 0.25s, color 0.25s; }

/* ── NAV ── */
nav {
  position: fixed; top: 0; left: 0; right: 0; z-index: 302;
  display: flex; align-items: center; justify-content: space-between;
  padding: 18px 48px;
  background: rgba(13,13,13,0.92);
  backdrop-filter: blur(12px);
  border-bottom: 1px solid rgba(200,150,62,0.15);
  gap: 16px;
}
[data-theme="light"] nav { background: rgba(255,255,255,0.92); }
.logo { font-family: 'Playfair Display', serif; font-size: 1.4rem; font-weight: 900; color: var(--oro); letter-spacing: 0.02em; text-decoration: none; }
.logo span { color: var(--arena); }

.nav-links { display: flex; gap: 24px; align-items: center; }
.nav-links a { color: var(--arena); text-decoration: none; font-size: 0.84rem; font-weight: 500; letter-spacing: 0.04em; opacity: 0.7; transition: opacity 0.2s, color 0.2s; }
.nav-links a:hover { opacity: 1; color: var(--oro-suave); }

.nav-right { display: flex; align-items: center; gap: 8px; margin-left: auto; }
.nav-cta { background: var(--oro); color: #0D0D0D !important; padding: 9px 20px; border-radius: 2px; font-size: 0.82rem; font-weight: 700; text-decoration: none; letter-spacing: 0.04em; white-space: nowrap; transition: background 0.2s; }
.nav-cta:hover { background: var(--oro-suave); }

/* ── CTRL BUTTONS (lang / curr / theme) ── */
.ctrl-btn {
  background: transparent;
  border: 1px solid var(--borde);
  color: var(--arena);
  font-size: 0.78rem;
  font-weight: 600;
  padding: 7px 12px;
  border-radius: 2px;
  cursor: pointer;
  font-family: inherit;
  white-space: nowrap;
  transition: border-color 0.2s, color 0.2s;
}
.ctrl-btn:hover { border-color: var(--oro); color: var(--oro); }
.theme-toggle { font-size: 1rem; padding: 7px 10px; }

/* ── DROPDOWN ── */
.lang-selector { position: relative; }
.dropdown {
  display: none; position: absolute; top: calc(100% + 8px); right: 0;
  background: var(--humo); border: 1px solid var(--borde);
  border-radius: 4px; min-width: 140px; z-index: 200;
  box-shadow: 0 8px 24px rgba(0,0,0,0.3);
}
.dropdown.open { display: block; }
.dropdown a { display: block; padding: 10px 14px; font-size: 0.82rem; color: var(--arena); text-decoration: none; transition: background 0.15s; }
.dropdown a:hover { background: rgba(200,150,62,0.1); color: var(--oro); }

/* ── SECTION COMMONS ── */
.sec-header { text-align: center; max-width: 640px; margin: 0 auto 64px; }
.section-label { font-size: 0.72rem; font-weight: 600; letter-spacing: 0.18em; text-transform: uppercase; color: var(--oro); margin-bottom: 16px; display: block; }
.sec-header h2 { font-family: 'Playfair Display', serif; font-size: clamp(2.2rem, 4vw, 3.2rem); font-weight: 900; color: var(--crema); margin-bottom: 16px; }
.sec-header p { font-size: 1rem; color: var(--texto-muted); line-height: 1.7; }

/* ── BUTTONS ── */
.btn-primary { background: var(--oro); color: #0D0D0D; padding: 15px 34px; border: none; border-radius: 2px; font-family: 'Inter', sans-serif; font-weight: 700; font-size: 0.88rem; letter-spacing: 0.06em; text-transform: uppercase; cursor: pointer; text-decoration: none; transition: background 0.2s, transform 0.15s; display: inline-block; }
.btn-primary:hover { background: var(--oro-suave); transform: translateY(-2px); }
.btn-ghost { border: 1px solid rgba(232,221,208,0.3); color: var(--arena); padding: 15px 34px; border-radius: 2px; font-family: 'Inter', sans-serif; font-weight: 500; font-size: 0.88rem; letter-spacing: 0.06em; text-transform: uppercase; cursor: pointer; text-decoration: none; transition: border-color 0.2s, color 0.2s; display: inline-block; }
.btn-ghost:hover { border-color: var(--oro); color: var(--oro-suave); }

/* ── PAGE HERO (sub-pages) ── */
.page-hero { padding: 140px 48px 80px; background: var(--carbon); position: relative; overflow: hidden; }
.page-hero::before { content: ''; position: absolute; inset: 0; background: radial-gradient(ellipse 70% 80% at 80% 50%, rgba(200,150,62,0.07) 0%, transparent 70%); pointer-events: none; }
.page-hero .eyebrow { font-size: 0.72rem; font-weight: 600; letter-spacing: 0.18em; text-transform: uppercase; color: var(--oro); margin-bottom: 18px; display: flex; align-items: center; gap: 10px; }
.page-hero .eyebrow::before { content: ''; display: block; width: 28px; height: 1px; background: var(--oro); }
.page-hero h1 { font-family: 'Playfair Display', serif; font-size: clamp(2.4rem, 5vw, 4.2rem); font-weight: 900; line-height: 1.1; color: var(--crema); max-width: 700px; margin-bottom: 24px; }
.page-hero h1 em { font-style: italic; color: var(--oro); }
.page-hero p { font-size: 1.05rem; line-height: 1.75; color: var(--texto-sec); max-width: 560px; margin-bottom: 40px; }

/* ── FEATURE SECTION ── */
.feature-section { padding: 100px 48px; }
.feature-grid { display: grid; grid-template-columns: repeat(3,1fr); gap: 2px; max-width: 1100px; margin: 0 auto; }
.feature-card { background: var(--humo); padding: 40px 32px; position: relative; overflow: hidden; transition: background 0.2s; }
.feature-card:hover { background: var(--hover-card); }
.feature-card::after { content: ''; position: absolute; bottom: 0; left: 0; right: 0; height: 2px; background: var(--oro); transform: scaleX(0); transform-origin: left; transition: transform 0.3s; }
.feature-card:hover::after { transform: scaleX(1); }
.fc-icon { font-size: 2rem; margin-bottom: 18px; display: block; }
.feature-card h3 { font-size: 1rem; font-weight: 700; color: var(--crema); margin-bottom: 10px; }
.feature-card p { font-size: 0.85rem; line-height: 1.65; color: var(--texto-muted); }

/* ── FOOTER ── */
footer { background: var(--fondo); border-top: 1px solid rgba(200,150,62,0.1); padding: 40px 48px; display: flex; justify-content: space-between; align-items: center; flex-wrap: wrap; gap: 16px; }
.footer-logo { font-family: 'Playfair Display', serif; font-size: 1.2rem; font-weight: 900; color: var(--oro); }
.footer-logo span { color: var(--texto-muted); }
footer p { font-size: 0.78rem; color: var(--texto-muted); }

/* ── HAMBURGER BUTTON ── */
.hamburger {
  display: none;
  background: transparent;
  border: none;
  cursor: pointer;
  padding: 6px;
  flex-direction: column;
  gap: 5px;
  z-index: 301;
}
.hamburger span {
  display: block;
  width: 22px;
  height: 2px;
  background: var(--arena);
  border-radius: 2px;
  transition: transform 0.25s, opacity 0.25s;
}
.hamburger.open span:nth-child(1) { transform: translateY(7px) rotate(45deg); }
.hamburger.open span:nth-child(2) { opacity: 0; }
.hamburger.open span:nth-child(3) { transform: translateY(-7px) rotate(-45deg); }

/* ── MOBILE DRAWER ── */
.mobile-menu {
  display: none;
  position: fixed;
  top: 57px; left: 0; right: 0; bottom: 0;
  background: var(--carbon);
  z-index: 300;
  flex-direction: column;
  padding: 24px 32px 40px;
  overflow-y: auto;
}
.mobile-menu.open { display: flex; }

/* Dropdowns inside mobile drawer: expand inline, not absolute */
.mobile-menu .lang-selector { position: static; }
.mobile-menu .dropdown {
  position: static;
  box-shadow: none;
  border: none;
  border-radius: 0;
  background: transparent;
  min-width: unset;
  padding-left: 12px;
  margin-top: 4px;
}
.mobile-menu .dropdown a {
  font-size: 0.9rem;
  padding: 8px 10px;
  border-radius: 4px;
}

.mobile-menu .mob-links { display: flex; flex-direction: column; gap: 0; border-top: 1px solid var(--borde); }
.mobile-menu .mob-links a {
  font-size: 1.2rem;
  font-weight: 600;
  color: var(--arena);
  text-decoration: none;
  padding: 18px 0;
  border-bottom: 1px solid var(--borde);
  letter-spacing: 0.02em;
  transition: color 0.2s;
}
.mobile-menu .mob-links a:hover,
.mobile-menu .mob-links a.active { color: var(--oro); }

.mobile-menu .mob-controls {
  margin-top: auto;
  padding-top: 32px;
  border-top: 1px solid var(--borde);
  display: flex;
  flex-direction: column;
  gap: 12px;
}
.mob-ctrl-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}
.mob-ctrl-row label {
  font-size: 0.75rem;
  color: var(--texto-muted);
  text-transform: uppercase;
  letter-spacing: 0.1em;
  flex-shrink: 0;
}
.mob-ctrl-row .mob-pills {
  display: flex;
  gap: 6px;
  flex-wrap: wrap;
}
.mob-pill {
  background: transparent;
  border: 1px solid var(--borde);
  color: var(--texto-sec);
  font-size: 0.78rem;
  font-weight: 600;
  padding: 5px 12px;
  border-radius: 2px;
  cursor: pointer;
  font-family: inherit;
  transition: border-color 0.2s, color 0.2s;
}
.mob-pill:hover, .mob-pill.active { border-color: var(--oro); color: var(--oro); }
.mob-theme-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
}
.mob-theme-row label { font-size: 0.75rem; color: var(--texto-muted); text-transform: uppercase; letter-spacing: 0.1em; }
.mob-theme-toggle {
  background: transparent;
  border: 1px solid var(--borde);
  color: var(--arena);
  font-size: 1rem;
  padding: 6px 14px;
  border-radius: 2px;
  cursor: pointer;
}
.mobile-menu .mob-cta {
  display: block;
  margin-top: 16px;
  background: var(--oro);
  color: #0D0D0D;
  text-align: center;
  padding: 16px;
  border-radius: 2px;
  font-weight: 700;
  font-size: 0.95rem;
  letter-spacing: 0.04em;
  text-decoration: none;
  text-transform: uppercase;
}

/* ── RESPONSIVE ── */
@media (max-width: 900px) {
  nav { padding: 14px 20px; }
  .nav-links { display: none; }
  .nav-right { gap: 6px; }
  .nav-right .ctrl-btn,
  .nav-right .lang-selector,
  .nav-right .nav-cta { display: none; }
  .hamburger { display: flex; }
  .page-hero { padding: 110px 24px 60px; }
  .feature-section { padding: 64px 24px; }
  .feature-grid { grid-template-columns: 1fr; }
  footer { padding: 32px 24px; flex-direction: column; align-items: flex-start; }
}
