/* lore.css - Estilo de Pergaminho Medieval Rústico e Premium */

:root {
  --color-parchment-bg: #f5edd6;
  --color-parchment-dark: #eddcb9;
  --color-text-dark: #3a220f;
  --color-text-medium: #5c3c1e;
  --color-gold: #c59b27;
  --color-gold-bright: #dfb15b;
  --color-border-dark: #4e3621;
  --font-title: 'Cinzel Decorative', Georgia, serif;
  --font-text: 'Metamorphous', Georgia, serif;
}

/* Scrollbar Customizado Estilo Medieval */
::-webkit-scrollbar {
  width: 12px;
}
::-webkit-scrollbar-track {
  background: var(--color-border-dark);
  border-left: 2px solid var(--color-gold);
}
::-webkit-scrollbar-thumb {
  background: var(--color-gold);
  border: 3px solid var(--color-border-dark);
  border-radius: 4px;
}
::-webkit-scrollbar-thumb:hover {
  background: var(--color-gold-bright);
}

body {
  margin: 0;
  padding: 0;
  background-color: #1a0f05;
  background-image: radial-gradient(circle, rgba(40, 25, 10, 0.8) 0%, rgba(10, 5, 0, 0.95) 100%);
  color: var(--color-text-dark);
  font-family: var(--font-text);
  line-height: 1.8;
  overflow-x: hidden;
}

/* Cabeçalho da Página */
.lore-header {
  position: relative;
  width: 100%;
  height: 450px;
  background-size: cover;
  background-position: center;
  background-repeat: no-repeat;
  border-bottom: 5px double var(--color-gold);
  box-shadow: 0 10px 30px rgba(0,0,0,0.8);
  display: flex;
  align-items: center;
  justify-content: center;
  text-align: center;
}

.lore-header::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: linear-gradient(to bottom, rgba(26,15,5,0.3) 0%, rgba(26,15,5,0.85) 100%);
}

.header-title-container {
  position: relative;
  z-index: 2;
  padding: 20px;
}

.header-badge {
  font-family: var(--font-title);
  color: var(--color-gold-bright);
  font-size: 0.9rem;
  letter-spacing: 4px;
  text-transform: uppercase;
  text-shadow: 0 2px 4px rgba(0,0,0,0.9);
  display: inline-block;
  margin-bottom: 10px;
}

.header-title {
  font-family: var(--font-title);
  font-size: 3.5rem;
  color: #fff;
  text-shadow: 0 4px 15px rgba(0,0,0,0.9), 0 0 10px var(--color-gold);
  margin: 0 0 15px 0;
  letter-spacing: 2px;
}

/* Efeito de Divisor Clássico */
.scroll-divider {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 15px;
  margin: 20px 0;
}

.scroll-divider .line {
  height: 2px;
  width: 80px;
  background: linear-gradient(to right, transparent, var(--color-gold), transparent);
}

.scroll-divider .symbol {
  font-size: 1.5rem;
  color: var(--color-gold);
  text-shadow: 0 0 5px rgba(197, 155, 39, 0.5);
}

/* Container de Pergaminho Rústico */
.parchment-container {
  max-width: 900px;
  margin: -60px auto 60px auto;
  position: relative;
  z-index: 3;
  padding: 0 20px;
}

.parchment {
  background-color: var(--color-parchment-bg);
  background-image: radial-gradient(var(--color-parchment-bg) 60%, var(--color-parchment-dark) 100%);
  border: 2px solid var(--color-border-dark);
  border-radius: 4px;
  padding: 60px;
  box-shadow: 
    0 15px 35px rgba(0,0,0,0.7),
    inset 0 0 60px rgba(78,54,33,0.15),
    inset 0 0 20px rgba(78,54,33,0.25);
  position: relative;
}

/* Detalhes de Canto no Pergaminho */
.parchment::before, .parchment::after {
  content: '';
  position: absolute;
  width: 30px;
  height: 30px;
  border: 2px solid var(--color-gold);
  pointer-events: none;
}

.parchment::before {
  top: 15px;
  left: 15px;
  border-right: none;
  border-bottom: none;
}

.parchment::after {
  bottom: 15px;
  right: 15px;
  border-left: none;
  border-top: none;
}

/* Selo de Cera Virtual */
.wax-seal {
  position: absolute;
  top: -40px;
  right: 60px;
  width: 80px;
  height: 80px;
  background: radial-gradient(circle, #b81d18 0%, #7d0a06 100%);
  border-radius: 50%;
  box-shadow: 0 6px 12px rgba(0,0,0,0.4), inset 0 0 15px rgba(0,0,0,0.5);
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 5;
  transform: rotate(-10deg);
  border: 1px solid rgba(255,255,255,0.1);
  transition: transform 0.3s ease;
}

.wax-seal:hover {
  transform: rotate(-5deg) scale(1.05);
}

.wax-seal-inner {
  width: 60px;
  height: 60px;
  border: 2px dashed rgba(255,255,255,0.25);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  color: rgba(255,255,255,0.8);
  font-family: var(--font-title);
  font-size: 1.5rem;
  font-weight: bold;
  text-shadow: 0 -2px 2px rgba(0,0,0,0.6);
}

/* Estilos de Capítulo e Texto */
.lore-chapter {
  margin-bottom: 50px;
  opacity: 0;
  transform: translateY(20px);
  animation: fadeInUp 0.8s forwards;
}

.lore-chapter:nth-child(1) { animation-delay: 0.2s; }
.lore-chapter:nth-child(2) { animation-delay: 0.4s; }
.lore-chapter:nth-child(3) { animation-delay: 0.6s; }
.lore-chapter:nth-child(4) { animation-delay: 0.8s; }

.chapter-num {
  font-family: var(--font-title);
  color: var(--color-gold);
  font-size: 1.1rem;
  letter-spacing: 2px;
  text-transform: uppercase;
  margin-bottom: 5px;
  display: block;
}

.chapter-title {
  font-family: var(--font-title);
  font-size: 2.2rem;
  color: var(--color-text-dark);
  margin: 0 0 20px 0;
  border-bottom: 1px dashed rgba(78, 54, 33, 0.2);
  padding-bottom: 10px;
}

.lore-text {
  font-size: 1.05rem;
  color: var(--color-text-medium);
  margin-bottom: 25px;
  text-align: justify;
  text-indent: 30px;
}

/* Remove indent apenas no primeiro parágrafo para não criar um buraco ao lado da capitular */
.lore-chapter .lore-text:first-of-type {
  text-indent: 0;
}

/* Letra Capitular Clássica e Limpa - Sem caixas, em tom vermelho real com contorno dourado */
.lore-chapter .lore-text:first-of-type::first-letter {
  font-family: var(--font-title);
  font-size: 4rem;
  float: left;
  line-height: 0.8;
  margin: 4px 10px 0 0;
  color: #8a1814;
  text-shadow: 1px 1px 0 var(--color-gold-bright), 2px 2px 2px rgba(0,0,0,0.15);
}

/* Ilustrações dos Capítulos */
.chapter-illustration {
  width: 100%;
  margin: 25px 0 35px 0;
  border: 3px double var(--color-border-dark);
  border-radius: 4px;
  overflow: hidden;
  box-shadow: 0 8px 20px rgba(0,0,0,0.3);
  position: relative;
}

.chapter-illustration img {
  width: 100%;
  display: block;
  transition: transform 0.8s ease, filter 0.5s ease;
  filter: sepia(0.25) contrast(1.05);
}

.chapter-illustration:hover img {
  transform: scale(1.03);
  filter: sepia(0) contrast(1.1);
}

/* Botões da Página */
.lore-actions {
  display: flex;
  gap: 20px;
  justify-content: center;
  margin-top: 50px;
}

.btn-lore {
  display: inline-block;
  padding: 12px 30px;
  border: 2px solid var(--color-border-dark);
  border-radius: 4px;
  font-family: var(--font-title);
  font-size: 1rem;
  text-decoration: none;
  font-weight: bold;
  transition: all 0.3s ease;
  cursor: pointer;
}

.btn-lore-primary {
  background: var(--color-border-dark);
  color: var(--color-parchment-bg);
}

.btn-lore-primary:hover {
  background: var(--color-gold);
  border-color: var(--color-gold);
  color: var(--color-text-dark);
  box-shadow: 0 5px 15px rgba(197, 155, 39, 0.4);
}

.btn-lore-secondary {
  background: transparent;
  color: var(--color-border-dark);
}

.btn-lore-secondary:hover {
  background: rgba(78, 54, 33, 0.1);
}

/* Animações */
@keyframes fadeInUp {
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

/* Responsividade */
@media (max-width: 768px) {
  .parchment {
    padding: 30px;
  }
  .header-title {
    font-size: 2.5rem;
  }
  .chapter-title {
    font-size: 1.8rem;
  }
  .lore-actions {
    flex-direction: column;
    align-items: center;
    gap: 15px;
  }
  .btn-lore {
    width: 100%;
    text-align: center;
  }
}
