/* TEMA PERGAMINO — fondo #f4e8d0, tinta #2c1810, oro #c9a227. NO usar rojo sangre. */
/* Religión Digital — Estética Antigua / Pergamino */
@import url('https://fonts.googleapis.com/css2?family=Cinzel:wght@400;700&family=Merriweather:ital,wght@0,400;0,700;1,400&display=swap');

:root {
  --parchment: #f4e8d0;
  --parchment-dark: #e8d5b0;
  --ink: #2c1810;
  --ink-soft: #5c4030;
  --stone: #3d3428;
  --bronze: #8b6914;
  --gold: #c9a227;
  --gold-light: #e8c547;
  --temple: #6b4423;
  --white: #fffef8;
  --border-stone: #a08060;
}

* { margin: 0; padding: 0; box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  font-family: 'Merriweather', Georgia, serif;
  line-height: 1.85;
  color: var(--ink);
  background: var(--parchment);
  background-image:
    radial-gradient(ellipse at 20% 50%, rgba(201,162,39,0.08) 0%, transparent 50%),
    radial-gradient(ellipse at 80% 20%, rgba(107,68,35,0.06) 0%, transparent 40%);
  min-height: 100vh;
}

a { color: var(--temple); text-decoration: underline; text-underline-offset: 3px; }
a:hover { color: var(--bronze); }

/* Header estilo templo */
.site-header {
  background: linear-gradient(180deg, #2c1810 0%, #3d2914 100%);
  border-bottom: 4px solid var(--gold);
  position: relative; z-index: 100;
  box-shadow: 0 4px 20px rgba(44,24,16,0.4);
}
.header-inner {
  max-width: 1000px; margin: 0 auto;
  padding: 1rem 1.25rem;
  display: flex; flex-wrap: wrap; align-items: center; gap: 0.75rem 1.25rem;
}
.logo {
  font-family: 'Cinzel', serif;
  font-size: 1.55rem; font-weight: 700;
  color: var(--gold-light); text-decoration: none !important;
  letter-spacing: 1px;
}
.logo span { color: #f4e8d0; }
.slogan {
  font-size: 0.8rem; color: #c4a882; font-style: italic;
  font-family: 'Merriweather', serif;
}
.nav { display: flex; flex-wrap: wrap; gap: 0.35rem 0.9rem; margin-left: auto; }
.nav a {
  color: #e8d5b0; font-size: 0.88rem; font-weight: 700;
  text-decoration: none !important; padding: 0.3rem 0.5rem;
  border-radius: 3px; font-family: 'Cinzel', serif; letter-spacing: 0.3px;
}
.nav a:hover, .nav a.active {
  color: var(--gold-light); background: rgba(201,162,39,0.2);
}

/* Hero pergamino monumental */
.hero {
  background: linear-gradient(165deg, #3d2914 0%, #5c4030 40%, #6b4423 100%);
  border-bottom: 4px solid var(--gold);
  padding: 3.5rem 1.25rem; text-align: center;
  position: relative;
}
.hero::before {
  content: '✧ ◆ ✧';
  display: block; color: var(--gold); font-size: 1.2rem; margin-bottom: 0.75rem;
  letter-spacing: 0.5rem;
}
.hero h1 {
  font-family: 'Cinzel', serif;
  font-size: clamp(2rem, 5.5vw, 3.2rem);
  color: var(--gold-light); margin-bottom: 0.75rem;
  text-shadow: 2px 2px 0 #2c1810;
}
.hero .tagline {
  font-size: 1.15rem; color: #e8d5b0; max-width: 720px;
  margin: 0 auto 1.5rem; font-style: italic;
}
.cta {
  display: inline-block;
  background: var(--gold); color: #2c1810 !important;
  padding: 0.85rem 1.75rem; border-radius: 4px;
  font-weight: 700; text-decoration: none !important;
  font-family: 'Cinzel', serif; border: 2px solid #8b6914;
  box-shadow: 0 3px 0 #6b5010;
}
.cta:hover { background: var(--gold-light); }

.container { max-width: 880px; margin: 0 auto; padding: 2.5rem 1.25rem; }
.section { margin-bottom: 3rem; }
.section h2 {
  font-family: 'Cinzel', serif;
  font-size: 1.55rem; color: var(--temple);
  margin-bottom: 1rem; padding-bottom: 0.4rem;
  border-bottom: 3px double var(--bronze);
  display: inline-block;
}
.section h3 {
  font-family: 'Cinzel', serif;
  font-size: 1.2rem; color: var(--stone); margin: 1.5rem 0 0.5rem;
}
p { margin-bottom: 1rem; color: var(--ink-soft); }
.lead { font-size: 1.1rem; color: var(--ink); }

.grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(240px, 1fr));
  gap: 1.25rem; margin-top: 1.25rem;
}
.card {
  background: var(--white);
  border: 2px solid var(--border-stone);
  border-radius: 6px; padding: 1.35rem;
  box-shadow: 3px 3px 0 rgba(61,52,40,0.15);
  transition: transform 0.15s, box-shadow 0.15s;
}
.card:hover {
  transform: translateY(-3px);
  box-shadow: 4px 5px 0 rgba(139,105,20,0.25);
  border-color: var(--bronze);
}
.card h3 { margin-top: 0; color: var(--temple); font-family: 'Cinzel', serif; }
.card .symbol { font-size: 1.9rem; display: block; margin-bottom: 0.4rem; }
.card a { font-weight: 700; color: var(--bronze); }

.keyword-cloud { display: flex; flex-wrap: wrap; gap: 0.45rem; margin: 1rem 0; }
.keyword {
  background: #efe0c0; color: var(--temple);
  padding: 0.3rem 0.75rem; border-radius: 3px;
  font-size: 0.82rem; border: 1px solid var(--border-stone);
  font-family: 'Cinzel', serif;
}

.resource-list { list-style: none; margin: 1rem 0; }
.resource-list li {
  padding: 0.75rem 0;
  border-bottom: 1px dashed var(--border-stone);
  color: var(--ink-soft);
}
.resource-list a { font-weight: 700; }
.badge {
  background: var(--bronze); color: #fff;
  font-size: 0.68rem; padding: 0.15rem 0.4rem;
  border-radius: 3px; margin-left: 0.35rem; font-weight: 700;
}

.video-wrap {
  position: relative; padding-bottom: 56.25%; height: 0;
  overflow: hidden; border-radius: 6px; margin: 1rem 0 1.5rem;
  background: #2c1810; border: 3px solid var(--bronze);
}
.video-wrap iframe {
  position: absolute; top: 0; left: 0; width: 100%; height: 100%; border: 0;
}

.seo-block, .history-block {
  background: var(--white);
  border: 2px solid var(--border-stone);
  border-left: 6px solid var(--gold);
  padding: 1.5rem; margin: 1.5rem 0; border-radius: 0 6px 6px 0;
}
.disclosure {
  background: #fff8e8;
  border: 2px solid var(--gold);
  padding: 1rem 1.25rem; margin: 1.5rem 0;
  border-radius: 6px; font-size: 0.9rem; color: var(--ink-soft);
}
.disclosure strong { color: var(--temple); }

.share-bar {
  display: flex; flex-wrap: wrap; gap: 0.45rem; align-items: center; margin: 1.5rem 0;
}
.share-bar > span { color: var(--ink-soft); font-weight: 700; font-size: 0.9rem; }
.share-btn {
  padding: 0.4rem 0.75rem; border-radius: 4px; font-size: 0.82rem;
  font-weight: 700; border: 2px solid var(--stone); cursor: pointer;
  color: var(--ink); background: var(--parchment-dark);
  font-family: 'Cinzel', serif;
}
.share-btn:hover { background: var(--gold); border-color: var(--bronze); }

.amazon-support {
  background: linear-gradient(135deg, #fff8e0, #f4e8d0);
  border: 3px solid var(--gold);
  border-radius: 8px; padding: 1.5rem; text-align: center; margin: 2rem 0;
}
.amazon-support h3 { font-family: 'Cinzel', serif; color: var(--temple); margin-bottom: 0.5rem; }
.btn-amazon {
  display: inline-block; margin-top: 0.75rem; padding: 0.75rem 1.4rem;
  background: #ff9900; color: #111 !important; font-weight: 800;
  border-radius: 5px; text-decoration: none !important;
  border: 2px solid #e68a00; font-family: 'Cinzel', serif;
}
.btn-amazon:hover { background: #e68a00; }

/* Cookie */
.cookie-banner {
  position: fixed; bottom: 0; left: 0; right: 0;
  background: #2c1810; border-top: 4px solid var(--gold);
  padding: 1rem 1.25rem; z-index: 99999; display: none;
  color: #e8d5b0;
}
.cookie-banner.show { display: block !important; }
.cookie-inner {
  max-width: 880px; margin: 0 auto;
  display: flex; flex-wrap: wrap; gap: 1rem; align-items: center; justify-content: space-between;
}
.cookie-inner p { margin: 0; font-size: 0.9rem; flex: 1; min-width: 200px; color: #d4c0a0; }
.cookie-btns { display: flex; gap: 0.5rem; }
.btn-cookie {
  padding: 0.55rem 1.1rem; border-radius: 4px; font-weight: 700;
  cursor: pointer; border: none; font-size: 0.9rem; font-family: 'Cinzel', serif;
}
.btn-accept { background: var(--gold); color: #2c1810; }
.btn-reject { background: transparent; color: #a08060; border: 2px solid #5c4030; }

/* Exit modal */
.modal-overlay {
  position: fixed; inset: 0; background: rgba(44,24,16,0.88);
  z-index: 100000; display: none; align-items: center; justify-content: center; padding: 1rem;
}
.modal-overlay.show { display: flex !important; }
.modal-box {
  background: var(--parchment); border: 4px solid var(--gold);
  border-radius: 8px; max-width: 420px; width: 100%; padding: 2rem;
  text-align: center; position: relative;
  box-shadow: 0 10px 40px rgba(0,0,0,0.4);
}
.modal-box h3 { font-family: 'Cinzel', serif; color: var(--temple); margin-bottom: 0.6rem; font-size: 1.4rem; }
.modal-close {
  position: absolute; top: 0.5rem; right: 0.9rem;
  background: none; border: none; color: var(--ink-soft); font-size: 1.6rem; cursor: pointer;
}
.modal-actions { display: flex; flex-direction: column; gap: 0.6rem; margin-top: 1.25rem; }
.btn-modal {
  padding: 0.75rem 1rem; border-radius: 5px; font-weight: 700; border: none;
  cursor: pointer; font-size: 0.95rem; text-decoration: none; display: block; text-align: center;
  font-family: 'Cinzel', serif;
}
.btn-modal.btn-amazon { background: #ff9900; color: #111; border: 2px solid #e68a00; }
.btn-modal.btn-stay { background: var(--temple); color: #f4e8d0; }
.btn-modal.btn-secondary { background: var(--parchment-dark); color: var(--ink); border: 2px solid var(--border-stone); }

.site-footer {
  background: #2c1810; border-top: 4px solid var(--gold);
  padding: 2.5rem 1.25rem 1.5rem; margin-top: 2rem; color: #c4a882;
}
.footer-inner {
  max-width: 880px; margin: 0 auto;
  display: grid; grid-template-columns: repeat(auto-fit, minmax(150px, 1fr)); gap: 1.5rem;
}
.footer-inner h4 { color: var(--gold); margin-bottom: 0.6rem; font-family: 'Cinzel', serif; font-size: 0.95rem; }
.footer-inner a { color: #a08060; display: block; margin-bottom: 0.3rem; font-size: 0.88rem; text-decoration: none; }
.footer-inner a:hover { color: var(--gold-light); }
.copyright {
  text-align: center; margin-top: 2rem; padding-top: 1.25rem;
  border-top: 1px solid #4a3520; font-size: 0.82rem; color: #7a6050;
}

.breadcrumb { font-size: 0.88rem; color: var(--ink-soft); margin-bottom: 1.25rem; }
.breadcrumb a { color: var(--bronze); }

.ornament {
  text-align: center; color: var(--bronze); font-size: 1.1rem;
  letter-spacing: 0.6rem; margin: 1.5rem 0; opacity: 0.7;
}

@media (max-width: 700px) {
  .header-inner { flex-direction: column; align-items: flex-start; }
  .nav { margin-left: 0; }
}

/* —— Extra interactivo —— */
.rd-toast {
  position: fixed; bottom: 5.5rem; left: 50%; transform: translateX(-50%) translateY(20px);
  background: #2c1810; color: #f4e8d0; padding: 0.75rem 1.4rem; border-radius: 6px;
  border: 2px solid var(--gold); z-index: 100001; opacity: 0; transition: all 0.35s;
  font-family: 'Cinzel', serif; font-size: 0.9rem; pointer-events: none;
}
.rd-toast.show { opacity: 1; transform: translateX(-50%) translateY(0); }

.oraculo-box, .quiz-wrap, .geo-box {
  background: var(--white);
  border: 3px solid var(--bronze);
  border-radius: 10px;
  padding: 1.5rem;
  margin: 1.75rem 0;
  text-align: center;
  box-shadow: 4px 4px 0 rgba(139,105,20,0.2);
}
.oraculo-box h3, .quiz-wrap h3, .geo-box h3 {
  font-family: 'Cinzel', serif; color: var(--temple); margin-bottom: 0.75rem;
}
#oraculo-texto {
  font-size: 1.15rem; font-style: italic; color: var(--ink);
  min-height: 3.5rem; transition: opacity 0.2s; margin: 1rem 0;
  padding: 1rem; background: var(--parchment); border-radius: 6px;
  border: 1px dashed var(--border-stone);
}
.oraculo-box .cta, .quiz-wrap .cta, .geo-box .cta { margin-top: 0.5rem; cursor: pointer; border: none; font-size: 0.95rem; }

.quiz-answers { display: flex; flex-direction: column; gap: 0.5rem; margin-top: 1rem; }
.quiz-btn {
  padding: 0.75rem 1rem; background: var(--parchment-dark); border: 2px solid var(--border-stone);
  border-radius: 6px; cursor: pointer; font-family: 'Merriweather', serif; font-size: 0.95rem;
  color: var(--ink); text-align: left; transition: background 0.15s, border-color 0.15s;
}
.quiz-btn:hover { background: #efe0c0; border-color: var(--bronze); }
.quiz-result { padding: 0.5rem 0; }
.quiz-emoji { font-size: 3rem; display: block; margin-bottom: 0.5rem; }
.quiz-q { color: var(--ink-soft); }

.geo-map-wrap {
  position: relative; width: 100%; height: 0; padding-bottom: 65%;
  margin: 1rem 0; border: 3px solid var(--bronze); border-radius: 8px; overflow: hidden;
  background: #2c1810;
}
.geo-map-wrap iframe {
  position: absolute; top: 0; left: 0; width: 100%; height: 100%; border: 0;
}
#geo-status { font-size: 0.9rem; color: var(--ink-soft); margin: 0.75rem 0; min-height: 1.4em; }
.geo-btns { display: flex; flex-wrap: wrap; gap: 0.5rem; justify-content: center; margin: 1rem 0; }
.geo-btns button {
  padding: 0.55rem 0.9rem; border-radius: 5px; border: 2px solid var(--stone);
  background: var(--parchment-dark); cursor: pointer; font-family: 'Cinzel', serif;
  font-size: 0.82rem; color: var(--ink);
}
.geo-btns button:hover { background: var(--gold); border-color: var(--bronze); }

.acc-btn {
  width: 100%; text-align: left; padding: 0.9rem 1rem;
  background: var(--parchment-dark); border: 2px solid var(--border-stone);
  border-radius: 6px; cursor: pointer; font-family: 'Cinzel', serif;
  font-size: 1rem; color: var(--temple); margin-top: 0.5rem;
  display: flex; justify-content: space-between; align-items: center;
}
.acc-btn:hover { border-color: var(--bronze); }
.acc-panel {
  max-height: 0; overflow: hidden; transition: max-height 0.4s ease;
  background: var(--white); border-left: 3px solid var(--gold);
  padding: 0 1rem; margin-bottom: 0.25rem;
}
.acc-panel.open { max-height: 800px; padding: 1rem; }

.surprise-banner {
  background: linear-gradient(90deg, #3d2914, #6b4423, #3d2914);
  color: var(--gold-light); text-align: center; padding: 0.6rem;
  font-family: 'Cinzel', serif; font-size: 0.9rem;
  border-bottom: 2px solid var(--gold);
}

/* Fix: botones .cta y controles clicables */
button.cta,
a.cta {
  display: inline-block;
  background: var(--gold);
  color: #2c1810 !important;
  padding: 0.85rem 1.75rem;
  border-radius: 4px;
  font-weight: 700;
  text-decoration: none !important;
  font-family: 'Cinzel', serif;
  border: 2px solid #8b6914;
  cursor: pointer;
  box-shadow: 0 3px 0 #6b5010;
}
button.cta:hover,
a.cta:hover {
  background: var(--gold-light);
}
button:disabled { opacity: 0.5; cursor: not-allowed; }

/* Enlaces de tarjeta siempre visibles */
.card a {
  display: inline-block;
  margin-top: 0.5rem;
  padding: 0.35rem 0;
  font-weight: 700;
  color: var(--bronze) !important;
  text-decoration: underline !important;
}
.nav a { cursor: pointer; }

/* Modal refuerzo */
.modal-overlay.show {
  display: flex !important;
  visibility: visible !important;
  opacity: 1 !important;
  pointer-events: auto !important;
}
.modal-box {
  animation: rdModalIn 0.35s ease;
}
@keyframes rdModalIn {
  from { transform: scale(0.92); opacity: 0; }
  to { transform: scale(1); opacity: 1; }
}

/* cookie force */
.cookie-banner.show {
  display: block !important;
  visibility: visible !important;
  z-index: 99999 !important;
}

/* Banner cookies siempre usable */
.cookie-banner {
  position: fixed !important;
  bottom: 0 !important;
  left: 0 !important;
  right: 0 !important;
  z-index: 2147483646 !important;
  background: #2c1810 !important;
  border-top: 4px solid #c9a227 !important;
  padding: 1rem 1.25rem !important;
}
.cookie-banner.show {
  display: block !important;
  visibility: visible !important;
  opacity: 1 !important;
}

/* Descargo de responsabilidad */
.disclaimer-legal {
  max-width: 880px;
  margin: 0 auto 1rem;
  padding: 1rem 1.1rem;
  font-size: 0.78rem;
  line-height: 1.45;
  color: #a08060;
  border-top: 1px solid #5c4030;
}
.disclaimer-legal p { margin: 0.4rem 0; color: #a08060; }
.disclaimer-legal a { color: #c9a227; }
.site-header { position: relative !important; top: auto !important; }

/* Banner RGPD */
.cookie-banner .cookie-text { flex: 1; min-width: 220px; }
.cookie-banner .cookie-text p { margin: 0.25rem 0; color: #d4c0a0; font-size: 0.85rem; }
.cookie-inner { align-items: flex-start; }


/* Cookie banner: siempre clicable por encima de todo */
.cookie-banner {
  z-index: 2147483647 !important;
  pointer-events: auto !important;
}
.cookie-banner.show {
  display: block !important;
  visibility: visible !important;
  opacity: 1 !important;
  pointer-events: auto !important;
}
.cookie-banner .cookie-btns {
  pointer-events: auto !important;
  position: relative;
  z-index: 10;
}
.cookie-banner .btn-cookie {
  pointer-events: auto !important;
  cursor: pointer !important;
  position: relative;
  z-index: 11;
}
.cookie-banner a.btn-cookie {
  pointer-events: auto !important;
  cursor: pointer !important;
}
/* Modal oculto no debe bloquear clics */
.modal-overlay:not(.show) {
  display: none !important;
  pointer-events: none !important;
}
.modal-overlay.show {
  pointer-events: auto !important;
}
.logo { font-size: 1.15rem; letter-spacing: 0.02em; }
.logo .net {
  color: #c9a227;
  font-size: 0.75em;
  font-weight: 600;
}

/* Enlace ampliar Wikipedia */
.wiki-more {
  display: inline-flex;
  align-items: center;
  gap: 0.25rem;
  margin-top: 0.5rem;
  font-size: 0.82rem;
  font-weight: 700;
  color: #6b4423 !important;
  text-decoration: none !important;
  border: 1px solid #a08060;
  background: #f4e8d0;
  padding: 0.25rem 0.55rem;
  border-radius: 4px;
}
.wiki-more:hover {
  background: #c9a227;
  color: #2c1810 !important;
  border-color: #8b6914;
}
.card .wiki-more { margin-top: 0.65rem; }
.wiki-block {
  margin: 1rem 0;
  padding: 0.85rem 1rem;
  background: #efe0c0;
  border-left: 4px solid #c9a227;
  border-radius: 0 6px 6px 0;
}
.wiki-block a { font-weight: 700; }

/* FAQ on-page */
.faq-item {
  background: #fffef8;
  border: 2px solid #a08060;
  border-radius: 6px;
  margin-bottom: 0.65rem;
  padding: 0.65rem 1rem;
}
.faq-item summary {
  cursor: pointer;
  font-weight: 700;
  color: #6b4423;
  font-family: Cinzel, serif;
  list-style: none;
}
.faq-item summary::-webkit-details-marker { display: none; }
.faq-item summary::before {
  content: "▸ ";
  color: #c9a227;
}
.faq-item[open] summary::before { content: "▾ "; }
.faq-item p {
  margin: 0.6rem 0 0.2rem;
  color: #5c4030;
  font-size: 0.95rem;
}

/* === COOKIE BANNER FIX FINAL === */
#cookie-banner {
  position: fixed !important;
  bottom: 0 !important;
  left: 0 !important;
  right: 0 !important;
  z-index: 2147483647 !important;
  pointer-events: auto !important;
}
#cookie-banner.cookie-hidden,
#cookie-banner[hidden],
#cookie-banner.is-hidden {
  display: none !important;
  visibility: hidden !important;
  opacity: 0 !important;
  pointer-events: none !important;
  height: 0 !important;
  overflow: hidden !important;
}
#cookie-banner.show:not(.cookie-hidden):not([hidden]) {
  display: block !important;
}
#cookie-banner button,
#cookie-banner a {
  pointer-events: auto !important;
  cursor: pointer !important;
  position: relative;
  z-index: 2147483647 !important;
}

/* COOKIE BANNER v3 — visible por defecto hasta consentimiento */
#cookie-banner.cookie-banner {
  position: fixed !important;
  left: 0 !important;
  right: 0 !important;
  bottom: 0 !important;
  z-index: 2147483647 !important;
  background: #2c1810 !important;
  border-top: 4px solid #c9a227 !important;
  padding: 1rem 1.25rem !important;
  color: #e8d5b0 !important;
  box-sizing: border-box !important;
  max-height: 50vh;
  overflow: auto;
}
#cookie-banner.cookie-banner.show {
  display: block !important;
  visibility: visible !important;
  opacity: 1 !important;
  pointer-events: auto !important;
}
#cookie-banner.cookie-banner.cookie-hidden {
  display: none !important;
  visibility: hidden !important;
  pointer-events: none !important;
}
