/* ===== Base ===== */
html, body {
  margin: 0;
  padding: 0;
  background: #0d0d0d;
  color: #e3c770;
  font-family: 'Georgia', serif;
  font-size: 20px; /* enlarged for legibility */
  line-height: 1.8;
  text-align: center;
  scroll-behavior: smooth; /* smooth scrolling */
}

a {
  color: #e3c770;
  text-decoration: none;
  transition: color 0.3s;
}

a:hover {
  color: #fff4d1;
}

/* ===== Navigation ===== */
nav {
  background: #0d0d0d;
  padding: 16px;
  border-bottom: 1px solid #e3c77033;
  display: flex;
  justify-content: center;
  gap: 2rem;
  font-size: 18px;
}

nav a {
  font-weight: bold;
}

nav a:hover {
  text-shadow: 0 0 6px #e3c770, 0 0 12px #e3c770;
}

/* ===== Container ===== */
.container {
  padding: 64px 24px;
  max-width: 900px;
  margin: 0 auto;
}

/* ===== Glyph (Radiant Triangle) ===== */
.glyph {
  font-size: 60px;
  color: #e3c770;
  margin-bottom: 20px;
  animation: glow 2s ease-in-out infinite alternate;
}

@keyframes glow {
  from { text-shadow: 0 0 6px #e3c770, 0 0 12px #e3c77055; }
  to   { text-shadow: 0 0 24px #fff4d1, 0 0 48px #e3c770aa; }
}

/* ===== Radiant Flame (optional SVG) ===== */
.flame {
  width: 36px;
  margin: 0 auto 24px;
  animation: pulse 3s ease-in-out infinite;
}

@keyframes pulse {
  0%, 100% { opacity: 0.8; transform: scale(1); }
  50% { opacity: 1; transform: scale(1.1); }
}

/* ===== Headings ===== */
h1, h2, h3 {
  font-weight: bold;
  margin: 24px 0 16px;
}

/* ===== Lists (like Gates) ===== */
ul {
  list-style: none;
  padding: 0;
  margin: 32px auto;
  max-width: 700px;
}

ul li {
  margin: 12px 0;
  font-size: 20px;
}

/* nice subtle line breaks between gates */
hr {
  border: none;
  border-top: 1px solid #e3c77033;
  margin: 24px auto;
  width: 60%;
}

/* ===== Buttons ===== */
.enter-button {
  display: inline-block;
  padding: 14px 36px;
  margin: 36px 0;
  font-size: 20px;
  color: #0d0d0d;
  background: #e3c770;
  border-radius: 40px;
  font-weight: bold;
  transition: all 0.3s ease;
}

.enter-button:hover {
  background: #fff4d1;
  box-shadow: 0 0 16px #e3c77088;
}

/* ===== Footer ===== */
.footer-text {
  font-size: 18px;
  font-style: italic;
  margin-top: 60px;
  opacity: 0.8;
  animation: footerPulse 3s infinite;
}

@keyframes footerPulse {
  0%, 100% { opacity: 0.7; text-shadow: 0 0 6px #e3c77066; }
  50%      { opacity: 1; text-shadow: 0 0 16px #e3c770aa, 0 0 24px #fff4d1; }
}

/* ===== Embers Background ===== */
.embers {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  pointer-events: none;
  background: radial-gradient(circle at 20% 20%, rgba(227,199,112,0.05) 0%, transparent 60%),
              radial-gradient(circle at 80% 40%, rgba(227,199,112,0.05) 0%, transparent 60%),
              radial-gradient(circle at 50% 80%, rgba(227,199,112,0.04) 0%, transparent 70%);
  animation: drift 30s linear infinite;
  z-index: -1;
}

@keyframes drift {
  0%   { background-position: 0 0, 0 0, 0 0; }
  100% { background-position: 1000px 0, -1000px 0, 500px -500px; }
}

/* ===== Responsive ===== */
@media (max-width: 768px) {
  body { font-size: 18px; }
  nav { flex-direction: column; gap: 1rem; }
  .glyph { font-size: 48px; }
}

/* --- Persistent top seal above nav --- */
.top-seal {
  position: fixed;
  top: 0; left: 0; right: 0;
  height: 56px;
  display: flex; align-items: center; justify-content: center;
  pointer-events: none;                 /* purely decorative */
  z-index: 1001;
}
.top-seal .seal-glyph {
  font-size: 24px; line-height: 1;
  color: #e3c770;
  text-shadow: 0 0 6px #e3c77088, 0 0 18px #fff4d166;
  animation: sealTopPulse 2.6s ease-in-out infinite;
}
@keyframes sealTopPulse {
  0%,100% { opacity: .9; transform: translateY(0); }
  50%     { opacity: 1;  transform: translateY(-1px); text-shadow: 0 0 12px #fff4d1aa; }
}

/* move the nav down to sit under the seal */
nav { top: 56px; }

/* give pages a bit more top padding to account for seal + nav */
.container { padding-top: 140px; }
@media (max-width: 640px) {
  .container { padding-top: 126px; }
}

.modal-overlay {
  position: fixed;
  z-index: 9999;
  top: 0; left: 0;
  width: 100%; height: 100%;
  background: rgba(0, 0, 0, 0.95);
  display: flex;
  align-items: center;
  justify-content: center;
}

.modal-content {
  background: #0d0d0d;
  border: 1px solid gold;
  color: gold;
  padding: 40px;
  width: 90%;
  max-width: 600px;
  text-align: center;
  font-family: serif;
  border-radius: 12px;
  box-shadow: 0 0 12px rgba(255, 215, 0, 0.3);
}

.modal-list {
  text-align: left;
  margin: 20px 0;
  padding-left: 20px;
}

.modal-list li {
  margin-bottom: 12px;
}

.modal-buttons button {
  background: black;
  color: gold;
  border: 1px solid gold;
  padding: 12px 24px;
  margin: 10px;
  cursor: pointer;
  font-size: 1em;
  border-radius: 8px;
}

.modal-buttons button:hover {
  background: gold;
  color: black;
  transition: 0.3s;
}

/* Covenant fade-out */
.modal-overlay {
  opacity: 1;
  transition: opacity 0.8s ease;
}

.modal-overlay.fade-out {
  opacity: 0;
  pointer-events: none;
}

/* Silent Sanctuary Responsive Styling */

body {
  margin: 0;
  font-family: 'Garamond', serif;
  background-color: #0d0d0d;
  color: #d4af37;
}

nav {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  background-color: #000;
  padding: 16px 0;
  font-size: 18px;
  border-bottom: 1px solid #222;
}

nav a {
  color: #d4af37;
  text-decoration: none;
  margin: 0 12px;
  padding: 8px 12px;
  border-radius: 6px;
  transition: background 0.3s;
}

nav a:hover {
  background-color: #1a1a1a;
}

.container {
  padding: 40px 24px;
  max-width: 800px;
  margin: auto;
  text-align: center;
}

.enter-button {
  background-color: #d4af37;
  color: #0d0d0d;
  padding: 12px 24px;
  font-size: 18px;
  text-decoration: none;
  display: inline-block;
  margin-top: 24px;
  border-radius: 8px;
  transition: background-color 0.3s;
}

.enter-button:hover {
  background-color: #e6c34f;
}

.fine {
  font-size: 14px;
  color: #999;
}

.footer-text {
  margin-top: 48px;
  font-size: 16px;
  color: #777;
}

.glyph {
  font-size: 42px;
  color: #d4af37;
  margin-bottom: 12px;
}

/* Covenant Modal */
.modal-overlay {
  position: fixed;
  top: 0; left: 0; right: 0; bottom: 0;
  background-color: rgba(0, 0, 0, 0.88);
  display: none;
  justify-content: center;
  align-items: center;
  z-index: 9999;
}

.modal-content {
  background-color: #121212;
  color: #d4af37;
  padding: 32px;
  max-width: 600px;
  border-radius: 12px;
  text-align: center;
  box-shadow: 0 0 10px #222;
}

.modal-text {
  font-size: 16px;
  margin-bottom: 20px;
}

.modal-list {
  text-align: left;
  margin-bottom: 20px;
}

.modal-list li {
  margin: 8px 0;
  font-size: 14px;
}

.modal-buttons {
  display: flex;
  justify-content: space-around;
  margin-top: 24px;
}

.modal-buttons button {
  background-color: #d4af37;
  border: none;
  color: #0d0d0d;
  padding: 10px 20px;
  font-size: 16px;
  border-radius: 6px;
  cursor: pointer;
}

.modal-buttons button:hover {
  background-color: #e6c34f;
}

/* Hall of Flame Scroll */
.scroll-list {
  max-height: 520px;
  overflow-y: auto;
  background: rgba(255, 255, 255, 0.02);
  border: 1px solid #333;
  padding: 16px;
  border-radius: 10px;
  text-align: left;
}

.scroll-entry {
  margin-bottom: 16px;
  border-bottom: 1px solid #444;
  padding-bottom: 12px;
}

.scroll-entry strong {
  color: #e6c34f;
}

.scroll-entry em {
  color: #aaa;
  font-size: 14px;
}

/* Responsive Mobile Pass */
@media screen and (max-width: 768px) {
  nav {
    font-size: 14px;
    padding: 12px 0;
  }

  nav a {
    margin: 6px 8px;
    padding: 6px 10px;
  }

  .container {
    padding: 24px 16px;
  }

  .enter-button {
    font-size: 16px;
    padding: 10px 18px;
  }

  .modal-content {
    width: 90%;
    padding: 24px;
  }

  .modal-buttons button {
    font-size: 14px;
    padding: 8px 14px;
  }

  .scroll-list {
    padding: 12px;
    font-size: 14px;
  }
}
