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

body {
  font-family: Georgia, 'Times New Roman', serif;
  line-height: 1.6;
  color: #3d2817;
  background: #e8dcc8;
  background-image:
    linear-gradient(rgba(230, 210, 180, 0.3) 1px, transparent 1px),
    linear-gradient(90deg, rgba(230, 210, 180, 0.3) 1px, transparent 1px);
  background-size: 20px 20px;
  min-height: 100vh;
  padding: 20px;
}

.container {
  max-width: 900px;
  margin: 0 auto;
  background: linear-gradient(to bottom, #f4e8d8 0%, #e8dcc8 100%);
  padding: 40px;
  border-radius: 4px;
  box-shadow:
    0 0 0 1px rgba(61, 40, 23, 0.1),
    0 10px 40px rgba(61, 40, 23, 0.15),
    inset 0 0 80px rgba(255, 255, 255, 0.3);
  position: relative;
}

.container::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background:
    radial-gradient(ellipse at 20% 30%, rgba(160, 120, 80, 0.05) 0%, transparent 50%),
    radial-gradient(ellipse at 80% 70%, rgba(160, 120, 80, 0.05) 0%, transparent 50%);
  pointer-events: none;
  border-radius: 4px;
}

/* Hero */

.hero {
  display: flex;
  align-items: center;
  gap: 3rem;
  padding: 2rem 0 3rem;
  position: relative;
  z-index: 1;
}

.cover-wrapper {
  flex: 0 0 auto;
  max-width: 280px;
}

.cover-image {
  width: 100%;
  height: auto;
  filter: drop-shadow(0 8px 24px rgba(61, 40, 23, 0.35));
  border-radius: 2px;
}

.hero-text {
  flex: 1;
  text-align: left;
}

.series-label {
  font-size: 0.95rem;
  color: #5a4232;
  letter-spacing: 0.08em;
  margin-bottom: 0.25rem;
  font-style: italic;
}

h1 {
  font-size: 2.4rem;
  color: #2d1810;
  font-weight: 400;
  letter-spacing: 0.05em;
  text-transform: uppercase;
  margin-bottom: 0.25rem;
}

.book-title {
  font-size: 1.6rem;
  color: #5a4232;
  font-weight: 400;
  letter-spacing: 0.03em;
  font-style: italic;
  margin-bottom: 1rem;
}

.author {
  font-size: 1.1rem;
  color: #3d2817;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  margin-bottom: 1.5rem;
}

.release-date {
  font-size: 1.05rem;
  color: #6B4423;
  font-weight: 600;
  letter-spacing: 0.04em;
  padding: 0.6rem 1.2rem;
  border: 1px solid rgba(107, 68, 35, 0.3);
  border-radius: 3px;
  display: inline-block;
  background: rgba(107, 68, 35, 0.05);
}

/* Navigation */

.site-nav {
  display: flex;
  align-items: center;
  gap: 2rem;
  padding: 0.5rem 0 1.5rem;
  border-bottom: 1px solid rgba(139, 111, 71, 0.15);
  margin-bottom: 2rem;
  position: relative;
  z-index: 1;
}

.nav-logo {
  flex: 0 0 auto;
}

.nav-icon {
  width: 48px;
  height: 48px;
  animation: rotate-cw 120s linear infinite;
  opacity: 0.7;
}

.nav-links {
  display: flex;
  gap: 1.5rem;
  align-items: center;
}

.nav-link {
  font-family: Georgia, 'Times New Roman', serif;
  font-size: 0.95rem;
  color: #5a4232;
  text-decoration: none;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  padding: 0.25rem 0;
  border-bottom: 1.5px solid transparent;
  transition: color 0.2s, border-color 0.2s;
}

.nav-link:hover {
  color: #2d1810;
  border-bottom-color: rgba(139, 111, 71, 0.4);
}

.nav-link.active {
  color: #2d1810;
  border-bottom-color: #6B4423;
}

/* Center Circle */

.geo-circle-hit {
  fill: transparent;
  stroke: none;
  cursor: pointer;
}

.geo-circle.center {
  fill: none;
  stroke: #1a0d08;
  stroke-width: 2;
  opacity: .5;
  filter: url(#glow);
  pointer-events: none;
}

/* Truesight easter egg */

.truesight-text {
  font-family: Georgia, 'Times New Roman', serif;
  font-size: 7px;
  font-style: italic;
  fill: #1a0d08;
  text-anchor: middle;
  dominant-baseline: central;
  filter: url(#glow);
  opacity: 0;
  animation: truesight-fade 3s ease-in forwards;
}

@keyframes truesight-fade {
  to { opacity: 0.9; }
}

/* Text-formed circles */

.circle-text {
  font-family: Georgia, 'Times New Roman', serif;
  fill: #1a0d08;
  font-size: 4px;
  font-weight: bold;
  opacity: 0.6;
  filter: url(#glow);
}

/* Ring orbit — both rings revolve together around center */

.ring-orbit {
  transform-origin: 0 0;
  animation: rotate-cw 120s linear infinite;
  animation-play-state: paused;
  will-change: transform;
}

#geometry-svg.orbiting .ring-orbit {
  animation-play-state: running;
}

/* Word-ring rotation — text scrolls around each circle */

.word-ring {
  will-change: transform;
}

.word-ring-inner {
  animation: rotate-ccw 60s linear infinite;
}

.word-ring-outer {
  animation: rotate-ccw 90s linear infinite;
}

@keyframes rotate-cw {
  from { transform: rotate(0deg); }
  to   { transform: rotate(360deg); }
}

@keyframes rotate-ccw {
  from { transform: rotate(0deg); }
  to   { transform: rotate(-360deg); }
}

/* Connecting lines between circles */

.connecting-line {
  stroke: #1a0d08;
  stroke-width: 0.8;
  fill: none;
  opacity: 0;
  filter: url(#glow);
  animation: line-pulse 4s ease-in-out forwards;
}

@keyframes line-pulse {
  0%   { opacity: 0; }
  25%  { opacity: 0.45; }
  65%  { opacity: 0.45; }
  100% { opacity: 0; }
}

@media (prefers-reduced-motion: reduce) {
  .ring-orbit,
  .word-ring-inner, .word-ring-outer {
    animation: none;
  }
}

/* Updates Page */

.updates-section {
  display: flex;
  flex-direction: column;
  align-items: center;
  padding: 0.5rem 0 2rem;
  position: relative;
  z-index: 1;
}

.updates-section .geometry-container {
  width: 420px;
  height: 420px;
  margin-bottom: 0.75rem;
}

.updates-section #geometry-svg {
  width: 100%;
  height: 100%;
}

.updates-heading {
  font-size: 1.5rem;
  color: #2d1810;
  font-weight: 400;
  letter-spacing: 0.05em;
  margin-bottom: 0.5rem;
}

.updates-description {
  font-size: 1rem;
  color: #5a4232;
  text-align: center;
  max-width: 400px;
  margin-bottom: 1.5rem;
}

.signup-form {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.75rem;
  width: 100%;
  max-width: 420px;
}

.signup-input {
  width: 100%;
  font-family: Georgia, 'Times New Roman', serif;
  font-size: 0.95rem;
  color: #3d2817;
  background: linear-gradient(to bottom, #fff 0%, #f5efe6 100%);
  border: 1px solid #a08060;
  border-top-color: #8b6f47;
  border-bottom-color: #c4ad8f;
  border-radius: 4px;
  padding: 0.65rem 1rem;
  outline: none;
  box-shadow:
    inset 0 1px 3px rgba(61, 40, 23, 0.15),
    0 1px 0 rgba(255, 255, 255, 0.6);
  transition: border-color 0.2s, box-shadow 0.2s;
}

.signup-input::placeholder {
  color: #8b6f47;
  opacity: 0.7;
}

.signup-input:focus {
  border-color: #6B4423;
  box-shadow:
    inset 0 1px 3px rgba(61, 40, 23, 0.15),
    0 0 0 2px rgba(107, 68, 35, 0.15);
}

.signup-button {
  font-family: Georgia, 'Times New Roman', serif;
  font-size: 0.95rem;
  color: #f4e8d8;
  background: linear-gradient(to bottom, #7d5230 0%, #5a3819 100%);
  border: 1px solid #4a2e14;
  border-top-color: #8b6040;
  border-radius: 4px;
  padding: 0.65rem 1.5rem;
  cursor: pointer;
  letter-spacing: 0.04em;
  box-shadow:
    0 1px 2px rgba(61, 40, 23, 0.3),
    inset 0 1px 0 rgba(255, 255, 255, 0.1);
  transition: background 0.2s, box-shadow 0.2s;
}

.signup-button:hover {
  background: linear-gradient(to bottom, #6B4423 0%, #4a2e14 100%);
  box-shadow:
    0 1px 3px rgba(61, 40, 23, 0.4),
    inset 0 1px 0 rgba(255, 255, 255, 0.1);
}

.signup-button:active {
  background: linear-gradient(to bottom, #5a3819 0%, #4a2e14 100%);
  box-shadow:
    inset 0 1px 3px rgba(0, 0, 0, 0.2);
  transform: translateY(0.5px);
}

.signup-button:disabled {
  opacity: 0.6;
  cursor: not-allowed;
  box-shadow: none;
}

.signup-form.submitted .signup-input,
.signup-form.submitted .signup-button,
.signup-form.submitted .cf-turnstile {
  display: none;
}

.cf-turnstile {
  min-height: 0;
}

.cf-turnstile iframe {
  max-height: 65px;
}

.subscribe-status {
  font-size: 0.9rem;
  text-align: center;
  min-height: 1.4em;
}

.subscribe-status.success {
  font-family: Georgia, 'Times New Roman', serif;
  font-size: 1.05rem;
  font-style: italic;
  color: #3d2817;
  letter-spacing: 0.02em;
  padding: 0.8rem 1.2rem;
  border-top: 1px solid rgba(139, 111, 71, 0.25);
  border-bottom: 1px solid rgba(139, 111, 71, 0.25);
  margin-top: 0.25rem;
}

.subscribe-status.error {
  color: #8b3a3a;
}

/* Footer */

.landing-footer {
  text-align: center;
  padding-top: 2rem;
  margin-top: 2rem;
  border-top: 1px solid rgba(139, 111, 71, 0.2);
  position: relative;
  z-index: 1;
}

.landing-footer p {
  font-size: 0.85rem;
  color: #6b5544;
  letter-spacing: 0.04em;
}

/* Responsive */

@media (max-width: 768px) {
  .hero {
    flex-direction: column;
    text-align: center;
    gap: 2rem;
  }

  .cover-wrapper {
    max-width: 200px;
  }

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

  .release-date {
    display: inline-block;
  }

  .nav-icon {
    width: 40px;
    height: 40px;
  }

  .updates-section .geometry-container {
    width: 220px;
    height: 220px;
  }

  h1 {
    font-size: 2rem;
  }

  .book-title {
    font-size: 1.3rem;
  }
}

@media (max-width: 480px) {
  .container {
    padding: 20px;
  }

  .cover-wrapper {
    max-width: 180px;
  }

  h1 {
    font-size: 1.7rem;
  }

  .circle-text {
    font-size: 4px;
  }
}
