/* ===================================================
   VARIABLES & THEME
   =================================================== */
:root {
  --bg-dark: #030008;
  --accent-cyan: #00f0ff;
  --accent-purple: #9d4edd;
  --accent-gold: #ffb703;
  --accent-neon: #7000ff;
  --text-main: #f1f5f9;
  --text-dim: #94a3b8;
  --glass-bg: rgba(15, 10, 30, 0.65);
  --glass-border: rgba(157, 78, 221, 0.25);
  --glow-primary: 0 0 35px rgba(0, 240, 255, 0.4);
}

/* ===================================================
   RESET & TRAVAS MASTER DE LARGURA
   =================================================== */
*, *::before, *::after { 
  box-sizing: border-box; 
  margin: 0; 
  padding: 0; 
}

html, body {
  width: 100%;
  max-width: 100vw;
  overflow-x: hidden !important;
}

body {
  background-color: var(--bg-dark);
  color: var(--text-main);
  font-family: 'Plus Jakarta Sans', sans-serif;
  min-height: 100vh;
}

img, svg, canvas, video {
  max-width: 100%;
  height: auto;
}

/* Canvas de partículas no fundo */
#bg-canvas {
  position: fixed;
  top: 0;
  left: 0;
  width: 100vw;
  height: 100vh;
  z-index: 0;
  pointer-events: none;
}

/* Ambient Glow Orbs */
.orb {
  position: absolute;
  border-radius: 50%;
  filter: blur(120px);
  opacity: 0.5;
  pointer-events: none;
  z-index: 1;
  animation: floatOrb 12s ease-in-out infinite alternate;
  max-width: 100vw;
}

.orb-1 { 
  width: clamp(280px, 50vw, 500px); 
  height: clamp(280px, 50vw, 500px); 
  background: var(--accent-neon); 
  top: -50px; 
  left: -50px; 
}

.orb-2 { 
  width: clamp(300px, 60vw, 600px); 
  height: clamp(300px, 60vw, 600px); 
  background: #0044ff; 
  bottom: -100px; 
  right: -50px; 
  animation-delay: -6s; 
}

@keyframes floatOrb {
  0% { transform: translate(0, 0) scale(1); }
  100% { transform: translate(40px, 30px) scale(1.1); }
}

.app-container {
  position: relative;
  z-index: 2;
  width: 100%;
  overflow-x: hidden;
}

/* ===================================================
   HEADER NAVBAR & BRAND
   =================================================== */
header {
  padding: 10px 20px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  background: rgba(3, 0, 8, 0.9);
  border-bottom: 1px solid rgba(255, 255, 255, 0.08);
  position: fixed;
  top: 0; left: 0; right: 0;
  z-index: 100;
  width: 100%;
  height: 60px;
}

.brand {
  display: flex;
  align-items: center;
  gap: 12px;
  font-family: 'Cinzel', serif;
  font-size: clamp(0.75rem, 3.2vw, 1.15rem); 
  font-weight: 900;
  letter-spacing: 0.5px;
  background: linear-gradient(135deg, #fff 0%, var(--accent-cyan) 50%, var(--accent-purple) 100%);
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
  color: transparent;
  white-space: nowrap;
  text-decoration: none;
  min-width: 0;
}

.nav-btn, header button {
  background: linear-gradient(135deg, var(--accent-neon), var(--accent-purple));
  color: #fff;
  padding: 8px 18px;
  border-radius: 50px;
  font-weight: 700;
  font-size: clamp(0.65rem, 2.2vw, 0.85rem);
  text-decoration: none;
  letter-spacing: 0.5px;
  text-transform: uppercase;
  box-shadow: 0 0 15px rgba(112, 0, 255, 0.5);
  transition: all 0.3s ease;
  border: 1px solid rgba(255, 255, 255, 0.2);
  white-space: nowrap;
  flex-shrink: 0;
}

.nav-btn:hover {
  transform: translateY(-2px) scale(1.03);
  box-shadow: 0 0 25px rgba(0, 240, 255, 0.8);
  border-color: var(--accent-cyan);
}

/* ===================================================
   LOGO DO AUTOR "SANGUE NO ZÓI"
   =================================================== */
.author-brand-logo {
  position: relative;
  width: 36px;
  height: 36px;
  min-width: 36px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  cursor: pointer;
}

.author-avatar-img {
  width: 30px;
  height: 30px;
  border-radius: 50%;
  object-fit: cover;
  z-index: 3;
  border: 2px solid #00f0ff;
  filter: contrast(1.35) saturate(1.4) brightness(1.05) drop-shadow(0 0 8px #00f0ff);
  transition: all 0.3s cubic-bezier(0.175, 0.885, 0.32, 1.275);
}

.blood-aura {
  position: absolute;
  top: -3px;
  left: -3px;
  right: -3px;
  bottom: -3px;
  border-radius: 50%;
  background: conic-gradient(from 0deg, #00f0ff, #0077ff, #7000ff, #00f0ff);
  z-index: 1;
  animation: spinBloodAura 1.5s linear infinite, bloodPulse 0.8s ease-in-out infinite alternate;
  filter: blur(2px);
}

.lightning-streak {
  position: absolute;
  width: 100%;
  height: 100%;
  border-radius: 50%;
  border: 1.5px solid var(--accent-cyan);
  box-shadow: 0 0 10px var(--accent-cyan);
  z-index: 2;
  animation: flickerLightning 0.15s infinite alternate;
  opacity: 0.7;
}

.author-brand-logo:hover .author-avatar-img {
  transform: scale(1.25) rotate(-8deg);
  filter: contrast(1.6) saturate(1.8) drop-shadow(0 0 16px #00f0ff);
  border-color: #00f0ff;
}

.author-brand-logo:hover .blood-aura {
  filter: blur(4px);
  animation-duration: 0.5s;
}

@keyframes spinBloodAura {
  0% { transform: rotate(0deg); }
  100% { transform: rotate(360deg); }
}

@keyframes bloodPulse {
  0% {
    box-shadow: 0 0 6px rgba(0, 240, 255, 0.8), inset 0 0 4px rgba(0, 240, 255, 0.5);
  }
  100% {
    box-shadow: 0 0 20px rgba(0, 240, 255, 1), 0 0 30px rgba(0, 119, 255, 0.9);
  }
}

@keyframes flickerLightning {
  0% { opacity: 0.3; transform: scale(0.98); }
  100% { opacity: 1; transform: scale(1.04); }
}

/* ===================================================
   HERO SECTION
   =================================================== */
.hero {
  padding: 80px 5% 30px;
  min-height: calc(100vh - 60px);
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 30px;
  max-width: 1400px;
  margin: 0 auto;
  width: 100%;
}

.hero-text {
  flex: 1;
  max-width: 620px;
  width: 100%;
}

.badge {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 5px 12px;
  border-radius: 30px;
  background: rgba(0, 240, 255, 0.1);
  border: 1px solid rgba(0, 240, 255, 0.3);
  color: var(--accent-cyan);
  font-family: 'Space Grotesk', sans-serif;
  font-size: clamp(0.7rem, 2vw, 0.8rem);
  font-weight: 700;
  letter-spacing: 1px;
  text-transform: uppercase;
  margin-bottom: 12px;
  max-width: 100%;
}

.hero-title {
  font-size: clamp(1.75rem, 5.5vw, 3.8rem); 
  line-height: 1.12;
  word-wrap: break-word;
  overflow-wrap: break-word;
  max-width: 100%;
}

.hero-title span {
  display: inline-block;
  background: linear-gradient(135deg, #00f0ff 0%, #7000ff 50%, #ffb703 100%);
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
  color: transparent;
  filter: drop-shadow(0 0 12px rgba(0, 240, 255, 0.3));
  max-width: 100%;
}

.hero-desc {
  font-size: clamp(0.9rem, 2.2vw, 1.1rem);
  color: var(--text-dim);
  line-height: 1.5;
  margin-top: 12px;
  margin-bottom: 22px;
  font-weight: 300;
}

.cta-group {
  display: flex;
  gap: 14px;
  align-items: center;
  flex-wrap: wrap;
  width: 100%;
}

.btn-cosmic {
  padding: 14px 28px;
  border-radius: 14px;
  font-weight: 800;
  font-size: clamp(0.8rem, 2.2vw, 0.95rem);
  text-decoration: none;
  color: #030008;
  background: linear-gradient(135deg, #00f0ff, #7000ff);
  background-size: 200% 200%;
  animation: gradientShift 4s infinite alternate;
  box-shadow: 0 0 25px rgba(0, 240, 255, 0.4);
  transition: all 0.3s ease;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  width: auto;
}

.btn-cosmic:hover {
  transform: translateY(-3px);
  box-shadow: 0 0 40px rgba(0, 240, 255, 0.8);
  color: #fff;
}

@keyframes gradientShift {
  0% { background-position: 0% 50%; }
  100% { background-position: 100% 50%; }
}

/* ===================================================
   BOTÃO E FACHO DO HERO PARA O LIVRO 3D
   =================================================== */
.btn-beam-hero {
  background: rgba(0, 240, 255, 0.08);
  color: var(--accent-cyan);
  border: 1px solid var(--accent-cyan);
  padding: 14px 24px;
  border-radius: 14px;
  font-family: 'Space Grotesk', sans-serif;
  font-size: clamp(0.8rem, 2.2vw, 0.95rem);
  font-weight: 800;
  cursor: pointer;
  letter-spacing: 0.5px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  box-shadow: 0 0 15px rgba(0, 240, 255, 0.2);
  transition: all 0.3s cubic-bezier(0.175, 0.885, 0.32, 1.275);
  backdrop-filter: blur(10px);
}

.btn-beam-hero:hover {
  background: var(--accent-cyan);
  color: #030008;
  box-shadow: 0 0 30px rgba(0, 240, 255, 0.8), 0 0 50px rgba(112, 0, 255, 0.4);
  transform: translateY(-3px);
}

.btn-beam-hero.active {
  background: #00f0ff;
  color: #030008;
  box-shadow: 0 0 45px #00f0ff, inset 0 0 10px #ffffff;
  animation: beamBtnPulse 1s infinite alternate;
}

@keyframes beamBtnPulse {
  0% { box-shadow: 0 0 25px #00f0ff; }
  100% { box-shadow: 0 0 50px #00f0ff, 0 0 20px #7000ff; }
}

#hero-beam-svg {
  position: fixed;
  top: 0;
  left: 0;
  width: 100vw;
  height: 100vh;
  pointer-events: none;
  z-index: 90;
}

/* ===================================================
   STAGE DO LIVRO 3D
   =================================================== */
.book-stage {
  flex: 1;
  display: flex;
  justify-content: center;
  align-items: center;
  perspective: 1000px;
  position: relative;
  width: 100%;
  margin-top: -15px;
  transform: translateY(-10px);
}

.mystic-ring {
  position: absolute;
  width: clamp(240px, 65vw, 400px);
  height: clamp(240px, 65vw, 400px);
  border: 2px dashed rgba(0, 240, 255, 0.3);
  border-radius: 50%;
  animation: spinRing 25s linear infinite;
  pointer-events: none;
}

.mystic-ring-2 {
  width: clamp(290px, 75vw, 490px);
  height: clamp(290px, 75vw, 490px);
  border: 1px solid rgba(157, 78, 221, 0.2);
  border-top: 2px solid var(--accent-gold);
  animation: spinRing 40s linear infinite reverse;
}

@keyframes spinRing {
  0% { transform: rotate(0deg); }
  100% { transform: rotate(360deg); }
}

.book-3d {
  width: clamp(210px, 55vw, 290px);
  height: clamp(295px, 78vw, 400px);
  position: relative;
  transform-style: preserve-3d;
  transform: rotateY(-20deg) rotateX(8deg) rotateZ(1deg);
  transition: transform 0.8s cubic-bezier(0.175, 0.885, 0.32, 1.275);
  cursor: pointer;
}

.book-3d:hover {
  transform: rotateY(-5deg) rotateX(2deg) scale(1.04) translateY(-10px);
}

/* Quando o Livro Abre no HERO */
.book-3d.open {
  transform: rotateY(-5deg) scale(1.05);
}

.book-3d.open .book-cover {
  transform: rotateY(-160deg);
  pointer-events: none;
}

.book-3d.beam-charged {
  animation: bookSupercharge 0.8s ease-in-out infinite alternate !important;
}

.book-3d.beam-charged .book-cover {
  border-color: #00f0ff !important;
  box-shadow: 
    -10px 15px 40px rgba(0, 0, 0, 0.9),
    0 0 50px #00f0ff,
    inset 0 0 30px rgba(0, 240, 255, 0.8) !important;
}

@keyframes bookSupercharge {
  0% { transform: rotateY(-18deg) rotateX(6deg) scale(1.02); }
  100% { transform: rotateY(-24deg) rotateX(10deg) scale(1.08); }
}

.book-cover {
  position: absolute;
  width: 100%;
  height: 100%;
  background: linear-gradient(145deg, #0d061f, #1a0b36);
  border: 2px solid rgba(0, 240, 255, 0.4);
  border-radius: 12px 20px 20px 12px;
  box-shadow: 
    -10px 15px 30px rgba(0, 0, 0, 0.8),
    0 0 20px rgba(0, 240, 255, 0.3),
    inset 0 0 15px rgba(112, 0, 255, 0.5);
  padding: clamp(15px, 4vw, 30px);
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  backface-visibility: hidden;
  overflow: hidden;
  transform-origin: left center;
  transition: transform 0.8s cubic-bezier(0.645, 0.045, 0.355, 1);
  z-index: 5;
}

.rune-symbol {
  font-size: clamp(1.8rem, 5.5vw, 2.8rem);
  text-align: center;
  color: var(--accent-cyan);
  text-shadow: 0 0 15px var(--accent-cyan);
  margin-top: 5px;
  animation: floatRune 3s ease-in-out infinite alternate;
}

@keyframes floatRune {
  0% { transform: translateY(0); }
  100% { transform: translateY(-8px); }
}

.cover-title {
  font-family: 'Cinzel', serif;
  font-size: clamp(1.05rem, 3.2vw, 1.55rem);
  font-weight: 900;
  text-align: center;
  color: #fff;
  letter-spacing: 1px;
  line-height: 1.2;
}

.cover-subtitle {
  font-size: clamp(0.6rem, 2vw, 0.75rem);
  text-align: center;
  color: var(--accent-gold);
  letter-spacing: 2px;
  text-transform: uppercase;
  margin-top: 6px;
}

.book-spine {
  position: absolute;
  left: 0;
  width: clamp(25px, 6vw, 40px);
  height: 100%;
  background: #090314;
  transform: rotateY(-90deg) translateZ(15px);
  border: 1px solid rgba(0, 240, 255, 0.2);
}

.book-pages {
  position: absolute;
  right: 5px;
  top: 10px;
  width: clamp(25px, 6vw, 35px);
  height: calc(100% - 20px);
  background: linear-gradient(90deg, #d8d8d8, #fff 50%, #b0b0b0);
  transform: rotateY(90deg) translateZ(clamp(190px, 50vw, 270px));
  box-shadow: inset 0 0 10px rgba(0,0,0,0.5);
  border-radius: 4px;
}

.floating-page {
  display: none;
}

@media (min-width: 768px) {
  .floating-page {
    display: block;
    position: absolute;
    width: 260px;
    height: 380px;
    background: rgba(255, 255, 255, 0.05);
    backdrop-filter: blur(10px);
    border: 1px solid rgba(0, 240, 255, 0.3);
    border-radius: 12px;
    top: 20px;
    left: 20px;
    pointer-events: none;
    animation: pageFlip 8s infinite ease-in-out;
    transform-origin: left center;
  }
}

/* Página Interna Integrada ao Hero */
.book-inner-page {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: rgba(8, 16, 38, 0.96);
  border: 1px solid rgba(0, 240, 255, 0.3);
  border-radius: 8px;
  padding: 20px 15px;
  box-shadow: inset 0 0 20px rgba(0, 240, 255, 0.15);
  overflow-y: auto;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.5s ease 0.3s;
  z-index: 2;
}

.book-3d.open .book-inner-page {
  opacity: 1;
  pointer-events: auto;
}

/* ===================================================
   EFEITO DO MAR NEGRO NO TÍTULO DA CRÔNICA (INTERNO)
   =================================================== */
.chronicle-header-wrapper {
  position: relative;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  margin-bottom: 18px;
  padding: 18px 10px;
  border-radius: 8px;
  background: radial-gradient(circle at center, rgba(0, 0, 0, 0.85) 0%, rgba(5, 10, 26, 0.98) 100%);
  border: 1px solid rgba(0, 240, 255, 0.25);
  overflow: hidden;
  box-shadow: inset 0 0 25px rgba(0, 0, 0, 0.9);
}

.dark-sea-bg {
  position: absolute;
  bottom: -5px;
  left: 0;
  width: 200%;
  height: 45px;
  background: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 1200 120' preserveAspectRatio='none'%3E%3Cpath d='M0,0 C150,90 350,-40 500,65 C650,170 900,10 1200,40 L1200,120 L0,120 Z' fill='%23020617' opacity='0.9'%3E%3C/path%3E%3Cpath d='M0,20 C200,100 450,-20 700,75 C850,140 1050,30 1200,60 L1200,120 L0,120 Z' fill='%2300f0ff' opacity='0.18'%3E%3C/path%3E%3C/svg%3E") repeat-x;
  background-size: 600px 45px;
  animation: waveMotion 10s linear infinite;
  pointer-events: none;
}

@keyframes waveMotion {
  0% { transform: translateX(0); }
  100% { transform: translateX(-600px); }
}

.chronicle-section-title {
  position: relative;
  z-index: 2;
  font-family: 'Cinzel', serif;
  font-size: clamp(1.2rem, 3vw, 1.6rem);
  font-weight: 900;
  letter-spacing: 2px;
  text-transform: uppercase;
  color: #ffffff;
  margin: 0;
  text-shadow: 
    0 0 10px rgba(0, 240, 255, 0.8),
    0 0 20px rgba(0, 240, 255, 0.4);
  animation: titlePulse 3s ease-in-out infinite alternate, glowIn 0.8s ease-out;
}

@keyframes titlePulse {
  0% {
    text-shadow: 0 0 8px rgba(0, 240, 255, 0.6), 0 0 15px rgba(0, 240, 255, 0.3);
    transform: scale(1);
  }
  100% {
    text-shadow: 0 0 15px rgba(0, 240, 255, 1), 0 0 30px rgba(112, 0, 255, 0.8);
    transform: scale(1.03);
  }
}

.chronicle-paragraph {
  color: #e2e8f0;
  font-size: 0.88rem;
  line-height: 1.6;
  background: rgba(255, 255, 255, 0.03);
  padding: 12px;
  border-left: 3px solid #00f0ff;
  border-radius: 4px;
  margin-bottom: 10px;
  animation: slideFadeIn 0.5s ease-out forwards;
}

.chronicle-paragraph strong {
  color: #00f0ff;
}

@keyframes slideFadeIn {
  from { opacity: 0; transform: translateY(15px); filter: blur(5px); }
  to { opacity: 1; transform: translateY(0); filter: blur(0); }
}

@keyframes glowIn {
  from { opacity: 0; filter: drop-shadow(0 0 20px #00f0ff); }
  to { opacity: 1; filter: drop-shadow(0 0 8px #00f0ff); }
}

/* ===================================================
   SEÇÃO DE ESTATÍSTICAS
   =================================================== */
.stats-bar {
  margin: 10px 5% 0;
  max-width: 1300px;
  margin-left: auto;
  margin-right: auto;
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(140px, 1fr));
  gap: 16px;
  width: 90%;
}

.stat-card {
  background: var(--glass-bg);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  border: 1px solid var(--glass-border);
  border-radius: 16px;
  padding: 20px 12px;
  text-align: center;
  position: relative;
  overflow: hidden;
  transition: all 0.3s ease;
}

.stat-card:hover {
  border-color: var(--accent-cyan);
  transform: translateY(-3px);
  box-shadow: 0 8px 20px rgba(0, 240, 255, 0.15);
}

.stat-number {
  font-family: 'Space Grotesk', sans-serif;
  font-size: clamp(1.5rem, 5vw, 3rem); 
  font-weight: 700;
  line-height: 1.1;
  background: linear-gradient(135deg, #fff 0%, var(--accent-cyan) 100%);
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
  color: transparent;
  display: inline-block;
  white-space: nowrap;
}

.stat-label {
  color: var(--text-dim);
  font-size: clamp(0.7rem, 2vw, 0.95rem);
  text-transform: uppercase;
  letter-spacing: 1px;
  margin-top: 6px;
}

/* ===================================================
   FEED DE CRÔNICAS
   =================================================== */
.live-feed {
  padding: 80px 5%;
  max-width: 1300px;
  margin: 0 auto;
  width: 100%;
}

.section-header {
  text-align: center;
  margin-bottom: 40px;
}

.section-title {
  font-family: 'Cinzel', serif;
  font-size: clamp(1.6rem, 5vw, 2.5rem);
  font-weight: 800;
  margin-bottom: 12px;
}

.section-title span {
  color: var(--accent-cyan);
}

.feed-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 20px;
}

.chronicle-card {
  background: rgba(18, 10, 38, 0.7);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 16px;
  padding: 24px;
  position: relative;
  transition: all 0.4s ease;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
}

.chronicle-card:hover {
  border-color: var(--accent-purple);
  box-shadow: 0 10px 25px rgba(157, 78, 221, 0.2);
  transform: translateY(-4px);
}

.card-tag {
  font-size: 0.7rem;
  font-family: 'Space Grotesk', sans-serif;
  color: var(--accent-gold);
  letter-spacing: 1.5px;
  text-transform: uppercase;
  margin-bottom: 10px;
}

.card-quote {
  font-size: clamp(0.95rem, 2vw, 1.1rem);
  line-height: 1.6;
  color: #e2e8f0;
  font-style: italic;
  margin-bottom: 20px;
}

.author-info {
  display: flex;
  align-items: center;
  gap: 12px;
  border-top: 1px solid rgba(255, 255, 255, 0.08);
  padding-top: 14px;
}

.avatar-glow {
  width: 38px;
  height: 38px;
  border-radius: 50%;
  background: linear-gradient(135deg, var(--accent-cyan), var(--accent-purple));
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 800;
  color: #000;
  flex-shrink: 0;
}

.author-name {
  font-weight: 700;
  font-size: 0.9rem;
}

.author-role {
  font-size: 0.75rem;
  color: var(--text-dim);
}

/* ===================================================
   FOOTER
   =================================================== */
footer {
  border-top: 1px solid rgba(255, 255, 255, 0.08);
  padding: 40px 5% 30px;
  text-align: center;
  background: rgba(3, 0, 8, 0.8);
}

.footer-text {
  color: var(--text-dim);
  font-size: 0.85rem;
}

/* ===================================================
   MEDIA QUERIES (RESPONSIVIDADE)
   =================================================== */
@media (max-width: 968px) {
  .hero {
    flex-direction: column;
    text-align: center;
    padding-top: 75px;
    gap: 20px;
  }
  
  .hero-text { 
    max-width: 100%; 
  }

  .cta-group { 
    justify-content: center; 
  }

  .btn-cosmic {
    width: 100%;
    max-width: 320px;
  }

  .book-stage { 
    margin-top: 0; 
    transform: translateY(0);
  }
}

@media (max-width: 380px) {
  header {
    padding: 8px 10px;
  }

  .author-brand-logo {
    width: 30px;
    height: 30px;
    min-width: 30px;
  }

  .author-avatar-img {
    width: 25px;
    height: 25px;
  }

  .nav-btn, header button {
    padding: 6px 12px;
    font-size: 0.65rem;
  }

  .stats-bar {
    grid-template-columns: repeat(2, 1fr);
    gap: 10px;
  }
}

/* ===================================================
   MODAL TELA CHEIA DO AUTOR & FACHO DE LUZ
   =================================================== */
#beam-canvas {
  position: fixed;
  top: 0;
  left: 0;
  width: 100vw;
  height: 100vh;
  pointer-events: none;
  z-index: 999;
}

.author-modal {
  position: fixed;
  top: 0;
  left: 0;
  width: 100vw;
  height: 100vh;
  background: rgba(3, 0, 8, 0.96);
  backdrop-filter: blur(25px);
  -webkit-backdrop-filter: blur(25px);
  z-index: 1000;
  display: flex;
  justify-content: center;
  align-items: center;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.4s ease;
  overflow-y: auto;
  padding: 20px;
}

.author-modal.active {
  opacity: 1;
  pointer-events: all;
}

.close-modal {
  position: absolute;
  top: 20px;
  right: 25px;
  background: transparent;
  border: none;
  color: #ffffff;
  font-size: 2.8rem;
  line-height: 1;
  cursor: pointer;
  z-index: 1001;
  transition: transform 0.25s ease, color 0.25s ease;
}

.close-modal:hover {
  transform: scale(1.2) rotate(90deg);
  color: var(--accent-cyan, #00f0ff);
}

.modal-content {
  text-align: center;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 12px;
  max-width: 800px;
  max-height: 95vh;
  width: 100%;
  margin: auto;
}

.author-full-frame {
  position: relative;
  width: clamp(140px, 20vw, 220px);
  height: clamp(140px, 20vw, 220px);
  border-radius: 50%;
  padding: 5px;
  background: linear-gradient(135deg, #00f0ff, #0077ff, #7000ff);
  box-shadow: 0 0 35px rgba(0, 240, 255, 0.7), 0 0 60px rgba(0, 119, 255, 0.5);
  animation: pulseFrame 2s infinite alternate ease-in-out;
  flex-shrink: 0;
}

.author-full-img {
  width: 100%;
  height: 100%;
  border-radius: 50%;
  object-fit: cover;
  border: 3px solid #030008;
}

.modal-content h2 {
  font-family: 'Cinzel', serif;
  font-size: clamp(1.2rem, 2.8vw, 1.8rem);
  background: linear-gradient(135deg, #ffffff 0%, #00f0ff 100%);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
  letter-spacing: 2px;
  text-shadow: 0 0 15px rgba(0, 240, 255, 0.8), 0 0 30px rgba(0, 240, 255, 0.4);
  margin: 0;
}

.modal-content p {
  background: #091326; 
  color: #ffffff; 
  font-size: clamp(0.9rem, 1.6vw, 1.1rem);
  line-height: 1.7;
  max-width: 720px;
  font-weight: 600;
  text-shadow: none;
  
  padding: 20px 28px;
  border-radius: 8px 16px 16px 8px;
  border-left: 5px solid #00f0ff; 
  border-top: 1px solid rgba(0, 240, 255, 0.3);
  border-right: 1px solid rgba(0, 240, 255, 0.2);
  border-bottom: 1px solid rgba(0, 240, 255, 0.2);
  
  box-shadow: 
    0 10px 30px rgba(0, 0, 0, 0.8),
    0 0 20px rgba(0, 240, 255, 0.25);
    
  margin: 0;
  cursor: pointer;
  transform-style: preserve-3d;
  transition: all 0.3s ease;
  user-select: none;
}

.modal-content p:hover {
  transform: scale(1.02);
  background: #0d1b36;
  border-left-color: #00f0ff;
  box-shadow: 
    0 12px 35px rgba(0, 0, 0, 0.9),
    0 0 30px rgba(0, 240, 255, 0.4);
}

.modal-content p.book-open {
  background: #0b1a38;
  border-color: #00f0ff;
  box-shadow: 
    0 0 40px rgba(0, 240, 255, 0.6),
    inset 0 0 20px rgba(0, 140, 255, 0.3);
  animation: bookOpenAnimation 0.5s ease-out forwards;
}

.modal-content p span.highlight-word,
.modal-content p strong,
.modal-content p b {
  color: #00f0ff;
  font-weight: 800;
  background: none;
  -webkit-text-fill-color: initial;
  filter: none;
  text-shadow: 0 0 8px rgba(0, 240, 255, 0.4);
}

.btn-beam {
  background: linear-gradient(135deg, #00f0ff, #7000ff);
  color: #ffffff;
  border: none;
  padding: 12px 30px;
  font-size: clamp(0.85rem, 1.8vw, 1rem);
  font-weight: 800;
  border-radius: 50px;
  cursor: pointer;
  box-shadow: 0 0 25px rgba(0, 240, 255, 0.8), 0 0 15px rgba(112, 0, 255, 0.5);
  transition: all 0.3s ease;
  letter-spacing: 1px;
}

.btn-beam:hover {
  transform: scale(1.05);
  box-shadow: 0 0 45px #00f0ff;
}

@keyframes pulseFrame {
  0% { transform: scale(0.97); }
  100% { transform: scale(1.03); }
}

@keyframes bookOpenAnimation {
  0% { transform: scale(0.97) rotateY(-12deg); }
  50% { transform: scale(1.06) rotateY(4deg); }
  100% { transform: scale(1.03) rotateY(0deg); }
}

/* ===================================================
   SEÇÃO SEPARADA DO LIVRO INTERATIVO (CASO USE SEÇÃO EXTRA)
   =================================================== */
.interactive-book-section {
  position: relative;
  min-height: 80vh;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 40px 20px;
  overflow: hidden;
}

.cosmic-aura {
  position: absolute;
  width: 500px;
  height: 500px;
  background: radial-gradient(circle, rgba(0, 240, 255, 0.15) 0%, rgba(112, 0, 255, 0.1) 50%, transparent 70%);
  filter: blur(60px);
  pointer-events: none;
  z-index: 1;
}

.book-container {
  perspective: 1200px;
  width: 100%;
  max-width: 850px;
  height: 480px;
  z-index: 2;
  cursor: pointer;
  user-select: none;
}

.book-3d-wrapper {
  width: 100%;
  height: 100%;
  position: relative;
  transform-style: preserve-3d;
  transition: transform 0.8s cubic-bezier(0.2, 0.8, 0.2, 1);
  transform: rotateY(-15deg) rotateX(10deg);
}

.book-3d-wrapper.flipping {
  animation: cosmicPulse 0.6s ease-in-out;
}

@keyframes cosmicPulse {
  0% { transform: scale(1) rotateY(-15deg) rotateX(10deg); }
  50% { transform: scale(1.04) rotateY(0deg) rotateX(5deg); filter: drop-shadow(0 0 35px #00f0ff); }
  100% { transform: scale(1) rotateY(-5deg) rotateX(2deg); }
}

.cover {
  position: absolute;
  width: 50%;
  height: 100%;
  background: linear-gradient(145deg, #0a0418, #180933);
  border: 2px solid rgba(0, 240, 255, 0.4);
  border-radius: 12px 0 0 12px;
  box-shadow: -15px 15px 30px rgba(0, 0, 0, 0.8), 0 0 25px rgba(0, 240, 255, 0.2);
}

.cover-front {
  right: 0;
  border-radius: 0 12px 12px 0;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 30px;
  text-align: center;
  transform-origin: left;
  transition: transform 0.8s cubic-bezier(0.645, 0.045, 0.355, 1);
  z-index: 10;
}

.cover-front h3 {
  font-family: 'Cinzel', serif;
  font-size: 1.5rem;
  color: #fff;
  letter-spacing: 2px;
  margin-top: 15px;
  text-shadow: 0 0 10px rgba(0, 240, 255, 0.6);
}

.rune-icon {
  font-size: 3rem;
  filter: drop-shadow(0 0 10px #00f0ff);
}

.click-hint {
  font-size: 0.85rem;
  color: var(--accent-gold);
  margin-top: 20px;
  text-transform: uppercase;
  letter-spacing: 1.5px;
  animation: pulseHint 1.5s infinite alternate;
}

@keyframes pulseHint {
  0% { opacity: 0.5; }
  100% { opacity: 1; text-shadow: 0 0 10px #ffb703; }
}

.book-3d-wrapper.open {
  transform: rotateY(0deg) rotateX(0deg);
}

.book-3d-wrapper.open .cover-front {
  transform: rotateY(-180deg);
  pointer-events: none;
}

.page-leaf {
  position: absolute;
  width: 50%;
  height: 100%;
  top: 0;
  background: #081026;
  border: 1px solid rgba(0, 240, 255, 0.25);
  box-shadow: inset 0 0 30px rgba(0, 0, 0, 0.9);
}

.page-left {
  left: 0;
  border-radius: 12px 0 0 12px;
  background: linear-gradient(90deg, #050a1a 0%, #09132a 100%);
}

.page-right {
  right: 0;
  border-radius: 0 12px 12px 0;
  padding: 35px 30px;
  overflow-y: auto;
  background: linear-gradient(-90deg, #050a1a 0%, #09132a 100%);
}

.text-display-area {
  display: flex;
  flex-direction: column;
  gap: 15px;
}

.interaction-hud {
  margin-top: 25px;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 10px;
  z-index: 2;
}

.progress-bar {
  width: 250px;
  height: 6px;
  background: rgba(255, 255, 255, 0.1);
  border-radius: 10px;
  overflow: hidden;
  border: 1px solid rgba(0, 240, 255, 0.3);
}

.progress-fill {
  height: 100%;
  width: 0%;
  background: linear-gradient(90deg, #00f0ff, #7000ff);
  box-shadow: 0 0 12px #00f0ff;
  transition: width 0.4s ease;
}

.hud-status {
  font-size: 0.8rem;
  color: var(--text-dim);
  letter-spacing: 1px;
  text-transform: uppercase;
}

@media (max-width: 768px) {
  .book-container { height: 550px; }
  .page-right { padding: 20px 15px; }
  .cover-front h3 { font-size: 1.1rem; }
}

/* CONTAINER DE IMAGEM COM ONDAS E FLUXO DINÂMICO */
.theme-image-container {
  position: relative;
  width: 100%;
  height: 140px;
  border-radius: 8px;
  overflow: hidden;
  border: 1px solid rgba(0, 240, 255, 0.4);
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.8);
}

/* A IMAGEM GANHA MOVIMENTO DE ONDULAÇÃO CONTÍNUA */
.theme-img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  filter: contrast(1.3) saturate(1.3) brightness(0.85);
  animation: waterDrift 8s ease-in-out infinite alternate, waterWaveEffect 3s ease-in-out infinite alternate;
  transform-origin: center bottom;
}

/* ANIMAÇÃO DE DESLOCAMENTO DA ÁGUA */
@keyframes waterDrift {
  0% {
    transform: scale(1.05) translateY(0) rotate(0deg);
  }
  50% {
    transform: scale(1.12) translateY(-4px) rotate(0.5deg);
  }
  100% {
    transform: scale(1.08) translateY(2px) rotate(-0.5deg);
  }
}

/* ANIMAÇÃO DE ONDULAÇÃO LEVE (TIPO MAR) */
@keyframes waterWaveEffect {
  0% {
    filter: contrast(1.3) saturate(1.3) brightness(0.85) hue-rotate(0deg);
  }
  100% {
    filter: contrast(1.4) saturate(1.4) brightness(0.95) hue-rotate(10deg);
  }
}

/* CAMADA DE BRILHO SOBRE A ÁGUA */
.theme-image-overlay {
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg, rgba(0,240,255,0.1) 0%, rgba(2, 6, 18, 0.7) 100%);
  z-index: 1;
  pointer-events: none;
}

/* ===================================================
   CONTAINER DOS LINKS (.nav-bra)
   =================================================== */
.nav-bra {
  display: flex;
  gap: 15px;
  align-items: center;
}

/* ===================================================
   BOTÕES NEON COM HOVER CORRIGIDO
   =================================================== */
.nav-btn-neon {
  position: relative;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 12px 28px;
  font-family: 'Plus Jakarta Sans', sans-serif;
  font-size: 0.85rem;
  font-weight: 700;
  text-transform: uppercase;
  color: #ffffff;
  text-decoration: none;
  background: #090e23;
  border: 1px solid rgba(0, 240, 255, 0.25);
  border-radius: 50px;
  overflow: hidden;
  cursor: pointer;
  z-index: 1;
  box-shadow: 0 0 10px rgba(0, 240, 255, 0.15);
  transition: all 0.3s ease;
}

/* Efeito de luz varrendo o fundo no hover */
.nav-btn-neon::before {
  content: '';
  position: absolute;
  top: 0;
  left: -100%;
  width: 100%;
  height: 100%;
  background: linear-gradient(
    90deg,
    transparent,
    rgba(0, 240, 255, 0.3),
    rgba(168, 85, 247, 0.3),
    transparent
  );
  z-index: 1;
  transition: transform 0.5s ease;
}

.nav-btn-neon:hover::before {
  transform: translateX(200%);
}

/* Texto padrão do botão */
.nav-btn-neon .btn-text {
  position: relative;
  z-index: 2;
  display: inline-block;
  transition: transform 0.3s cubic-bezier(0.4, 0, 0.2, 1), opacity 0.3s ease;
}

/* Texto alternativo puxando direto do atributo data-hover do link pai */
.nav-btn-neon::after {
  content: attr(data-hover);
  position: absolute;
  left: 0;
  top: 100%;
  width: 100%;
  height: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
  color: #00f0ff;
  font-weight: 800;
  font-size: 0.85rem;
  z-index: 2;
  opacity: 0;
  transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
  white-space: nowrap;
}

/* Estado ao passar o mouse */
.nav-btn-neon:hover {
  border-color: #00f0ff;
  box-shadow: 0 0 20px rgba(0, 240, 255, 0.6), 0 0 10px rgba(168, 85, 247, 0.4);
  transform: translateY(-2px);
}

.nav-btn-neon:hover .btn-text {
  opacity: 0;
  transform: translateY(-150%);
}

.nav-btn-neon:hover::after {
  opacity: 1;
  top: 0;
  transform: translateY(0);
}

