/* ===== Generic template styles for the "livro" post type =====
   Uses var(--accent) / var(--accent-rgb) / var(--accent-light) / var(--accent-dark),
   injected per-post via inline <style> in single-livro.php so every book keeps its
   own color theme without needing a separate stylesheet per book. */

* { box-sizing:border-box; }
body { font-family:"Lato",sans-serif; background:#f9fafb; }
h1, h2, h3, .font-display { font-family:"Playfair Display",serif; }
.book-hero { background:linear-gradient(135deg,var(--accent-warm,#f5f5f5) 0%,#fff 55%,var(--accent-light) 100%); min-height:90vh; display:flex; align-items:center; position:relative; overflow:hidden; }
.book-hero::before { content:""; position:absolute; inset:0; background-image:radial-gradient(circle at 80% 10%, rgba(var(--accent-rgb),.09) 0%, transparent 50%), radial-gradient(circle at 8% 90%, rgba(201,168,76,.07) 0%, transparent 45%), radial-gradient(circle at 50% 50%, rgba(var(--accent-rgb),.04) 0%, transparent 60%); pointer-events:none; }
.hero-deco { position:absolute; border-radius:50%; pointer-events:none; opacity:.06; }
.hero-deco-1 { width:420px; height:420px; background:var(--accent); top:-120px; right:-80px; }
.hero-deco-2 { width:200px; height:200px; background:var(--gold); bottom:-60px; left:5%; }
.hero-deco-3 { width:80px; height:80px; background:var(--accent); top:30%; left:3%; border-radius:12px; transform:rotate(25deg); opacity:.08; }
.book-cover-wrap { position:relative; z-index:2; display:inline-block; }
.book-cover-wrap img { max-height:520px; width:auto; border-radius:3px 10px 10px 3px; filter:drop-shadow(0 30px 60px rgba(var(--accent-rgb),0.28)) drop-shadow(0 8px 20px rgba(0,0,0,0.30)); transform:perspective(1000px) rotateY(-8deg) rotateX(1deg); transition:transform .5s cubic-bezier(.25,.46,.45,.94),filter .5s ease; display:block; }
.book-cover-wrap:hover img { transform:perspective(1000px) rotateY(0deg) rotateX(0deg) translateY(-10px); filter:drop-shadow(0 40px 70px rgba(var(--accent-rgb),0.35)) drop-shadow(0 12px 25px rgba(0,0,0,0.35)); }
.book-cover-wrap::before { content:""; position:absolute; top:3px; bottom:3px; left:-12px; width:12px; background:linear-gradient(90deg,rgba(0,0,0,0.18),rgba(0,0,0,0.06)); border-radius:3px 0 0 3px; transform:perspective(1000px) rotateY(20deg); transform-origin:right; transition:transform .5s; }
.hero-badge { display:inline-flex; align-items:center; gap:6px; font-size:.72rem; font-weight:700; letter-spacing:.18em; text-transform:uppercase; color:var(--accent); border:1.5px solid var(--accent); padding:5px 16px; border-radius:20px; margin-bottom:12px; margin-right:8px; background:rgba(var(--accent-rgb),.06); }
.hero-title { font-family:"Playfair Display",serif; color:var(--navy); line-height:1.08; }
.hero-author { color:var(--gold); font-family:"Playfair Display",serif; font-style:italic; font-size:1.2rem; }
.hero-divider { width:64px; height:3px; background:linear-gradient(90deg,var(--accent),var(--gold)); margin:22px 0; border-radius:2px; }
.hero-tagline { color:#374151; font-size:1.05rem; line-height:1.75; font-weight:300; max-width:480px; }
.btn-primary { background:var(--accent); color:white; padding:15px 34px; font-weight:700; letter-spacing:.06em; text-transform:uppercase; font-size:.82rem; border-radius:3px; transition:background .2s,transform .15s,box-shadow .2s; display:inline-block; text-decoration:none; box-shadow:0 4px 14px rgba(var(--accent-rgb),.35); border:none; cursor:pointer; }
.btn-primary:hover { background:var(--accent-dark); transform:translateY(-2px); box-shadow:0 8px 24px rgba(var(--accent-rgb),.45); }
.btn-outline { border:2px solid var(--navy); color:var(--navy); padding:13px 30px; font-weight:700; letter-spacing:.06em; text-transform:uppercase; font-size:.82rem; border-radius:3px; transition:all .2s; display:inline-block; text-decoration:none; background:transparent; }
.btn-outline:hover { border-color:var(--accent); color:var(--accent); background:rgba(var(--accent-rgb),.04); }
.stats-bar { background:var(--navy); padding:20px 0; }
.stat-pill { display:inline-flex; align-items:center; gap:8px; padding:8px 20px; border-radius:30px; background:rgba(255,255,255,.08); border:1px solid rgba(255,255,255,.12); font-size:.85rem; font-weight:600; color:#fde68a; }
.stat-icon { font-size:1rem; }
.stat-label, .stat-value { display:inline; font-size:inherit; font-weight:inherit; color:inherit; }
.inner-tab-bar { background:white; border-bottom:1px solid #e5e7eb; position:sticky; top:62px; z-index:40; box-shadow:0 2px 8px rgba(0,0,0,.05); }
.inner-tab { padding:14px 24px; font-size:.78rem; font-weight:700; letter-spacing:.08em; text-transform:uppercase; border-bottom:3px solid transparent; color:#9ca3af; transition:color .2s,border-color .2s; white-space:nowrap; text-decoration:none; display:inline-block; }
.inner-tab.active, .inner-tab:hover { color:var(--accent); border-bottom-color:var(--accent); }
.section-label { font-size:.72rem; font-weight:700; letter-spacing:.18em; text-transform:uppercase; color:var(--gold); display:block; margin-bottom:8px; }
.section-heading { font-family:"Playfair Display",serif; color:var(--navy); }
.section-line { width:50px; height:3px; background:linear-gradient(90deg,var(--accent),var(--gold)); border-radius:2px; }
.ficha-card { background:white; border-radius:10px; box-shadow:0 4px 24px rgba(0,0,0,.08); overflow:hidden; border-top:4px solid var(--accent); padding:24px; }
.ficha-row { display:flex; justify-content:space-between; align-items:center; padding:10px 0; border-bottom:1px solid #f3f4f6; font-size:.875rem; }
.ficha-row:last-child { border-bottom:none; }
.pull-quote-section { background:linear-gradient(135deg,var(--accent-dark) 0%,var(--accent) 100%); position:relative; overflow:hidden; padding:64px 0; }
.pull-quote-mark { font-family:"Playfair Display",serif; font-size:8rem; line-height:.6; color:rgba(255,255,255,.15); display:block; margin-bottom:-20px; }
.pull-quote-text { font-family:"Playfair Display",serif; font-style:italic; color:white; font-size:1.5rem; line-height:1.65; max-width:780px; }
.pull-quote-attr { color:rgba(255,255,255,.65); font-size:.85rem; letter-spacing:.06em; margin-top:16px; }
.open-quote { font-family:"Playfair Display",serif; font-size:6rem; line-height:.6; color:var(--accent-light); float:left; margin-right:10px; margin-top:16px; }
.excerpt-text { font-family:"Playfair Display",serif; font-style:italic; color:#374151; line-height:1.85; font-size:1rem; }
.buy-card, .store-card { background:white; border-radius:10px; box-shadow:0 4px 20px rgba(0,0,0,.07); overflow:hidden; transition:transform .25s,box-shadow .25s; text-decoration:none; display:flex; flex-direction:column; align-items:center; text-align:center; padding:0; }
.buy-card:hover, .store-card:hover { transform:translateY(-5px); box-shadow:0 16px 40px rgba(0,0,0,.12); }
.buy-card-header { padding:28px 24px 20px; text-align:center; }
.buy-card-icon { width:56px; height:56px; border-radius:14px; display:flex; align-items:center; justify-content:center; margin:28px auto 16px; font-size:1.7rem; }
.buy-card-footer { padding:16px 24px; border-top:1px solid #f3f4f6; margin-top:auto; width:100%; }
.buy-tag { display:inline-block; font-size:.72rem; font-weight:700; letter-spacing:.1em; text-transform:uppercase; padding:4px 12px; border-radius:20px; margin-bottom:8px; }
.buy-card-name { font-weight:700; font-size:1rem; color:var(--navy); margin-bottom:4px; }
.buy-card-desc { font-size:.75rem; color:#9ca3af; padding:0 20px 20px; }
.books-scroll { display:grid; grid-template-columns:repeat(6,minmax(140px,1fr)); gap:20px; overflow-x:auto; padding-bottom:8px; }
@media (max-width:900px) { .books-scroll{grid-template-columns:repeat(3,minmax(130px,1fr));} }
@media (max-width:560px) { .books-scroll{grid-template-columns:repeat(2,minmax(130px,1fr));} }
.book-thumb { background:white; border-radius:8px; box-shadow:0 3px 14px rgba(0,0,0,.07); overflow:hidden; transition:transform .2s,box-shadow .2s; text-decoration:none; display:block; }
.book-thumb:hover { transform:translateY(-5px); box-shadow:0 12px 32px rgba(0,0,0,.13); }
.book-thumb img { width:100%; height:auto; display:block; aspect-ratio:3/4; object-fit:cover; }
.book-thumb-title { padding:10px 12px; font-size:.75rem; font-weight:700; color:var(--navy); line-height:1.3; }
.footer-divider { width:50px; height:2px; background:var(--gold); margin:12px auto; }
.reveal-delay-1 { transition-delay:.1s; }
.reveal-delay-2 { transition-delay:.2s; }
.reveal-delay-3 { transition-delay:.3s; }
.prefacio-card { background:white; border-radius:10px; box-shadow:0 4px 24px rgba(0,0,0,.07); overflow:hidden; }
.prefacio-stripe { width:8px; flex-shrink:0; }
.prefacist-avatar { width:54px; height:54px; border-radius:50%; display:flex; align-items:center; justify-content:center; background:var(--accent-light); flex-shrink:0; }
.film-tag, .tema-tag { display:inline-block; background:white; color:var(--accent); border:1px solid var(--accent-light); padding:4px 12px; border-radius:20px; font-size:.75rem; font-weight:600; }
.cta-banner { border-radius:12px; padding:32px; display:flex; flex-direction:column; gap:16px; align-items:center; justify-content:space-between; background:var(--accent-light); }
@media (min-width:768px) { .cta-banner { flex-direction:row; } }
@media (max-width:1023px) {
  .book-hero{min-height:auto;padding-top:60px;padding-bottom:60px;}
  .book-cover-wrap img{max-height:360px;}
}
@media (max-width:639px) {
  .book-cover-wrap img{max-height:300px;}
  .pull-quote-text{font-size:1.15rem;}
  .stat-pill{padding:12px 16px;}
}
