/*
==========================================
9CAMPNOU - EBOOK PAGE STYLES
==========================================
Loaded conditionally via functions.php
only on the Ebook page.
==========================================
*/

/* ==========================================================================
   EBOOK PAGE - BASE & VARIABLES
   ========================================================================== */

.ebook-page {
  --ebook-primary: #a50044;
  --ebook-primary-hover: #c40051;
  --ebook-secondary: #004d98;
  --ebook-secondary-dark: #003a75;
  --ebook-accent: #edbb00;
  --ebook-dark: #0d1b2a;
  --ebook-darker: #001a3d;
  --ebook-white: #ffffff;
  --ebook-gray-300: #d4d4d8;
  --ebook-gray-400: #a1a1aa;
  --ebook-gray-500: #71717a;

  --ebook-font-display: 'Plus Jakarta Sans', sans-serif;
  --ebook-font-body: 'DM Sans', sans-serif;
  --ebook-font-mono: 'Roboto Mono', monospace;

  --ebook-ease: cubic-bezier(0.22, 1, 0.36, 1);
  --ebook-ease-out: cubic-bezier(0.16, 1, 0.3, 1);

  background-color: var(--ebook-secondary-dark);
  color: var(--ebook-white);
  overflow-x: hidden;
  padding-top: 8rem;
  padding-bottom: 5rem;
}

.ebook-page *::selection {
  background-color: var(--ebook-accent);
  color: var(--ebook-secondary-dark);
}

.ebook-page .container {
  max-width: 1280px;
  margin: 0 auto;
  padding-left: 1.5rem;
  padding-right: 1.5rem;
}

@media (min-width: 1024px) {
  .ebook-page .container {
    padding-left: 3rem;
    padding-right: 3rem;
  }
}

/* ==========================================================================
   BACKGROUND GRADIENTS (ambient atmosphere)
   ========================================================================== */

.ebook-bg-gradients {
  position: fixed;
  inset: 0;
  pointer-events: none;
  overflow: hidden;
  z-index: 0;
}

.ebook-bg-gradients .gradient-top {
  position: absolute;
  top: 0;
  right: 0;
  width: 500px;
  height: 500px;
  background-color: rgba(165, 0, 68, 0.2);
  border-radius: 50%;
  filter: blur(100px);
  transform: translate(50%, -50%);
}

.ebook-bg-gradients .gradient-bottom {
  position: absolute;
  bottom: 0;
  left: 0;
  width: 500px;
  height: 500px;
  background-color: rgba(237, 187, 0, 0.1);
  border-radius: 50%;
  filter: blur(100px);
  transform: translate(-50%, 50%);
}

/* ==========================================================================
   ANIMATIONS
   ========================================================================== */

.ebook-animate {
  opacity: 0;
  transition: all 0.8s var(--ebook-ease);
}

.ebook-animate.is-visible {
  opacity: 1;
}

.ebook-animate.slide-left {
  transform: translateX(-50px);
}
.ebook-animate.slide-left.is-visible {
  transform: translateX(0);
}

.ebook-animate.slide-right {
  transform: translateX(50px);
}
.ebook-animate.slide-right.is-visible {
  transform: translateX(0);
}

.ebook-animate.fade-up {
  transform: translateY(40px);
}
.ebook-animate.fade-up.is-visible {
  transform: translateY(0);
}

.ebook-animate.scale-in {
  transform: scale(0.95);
}
.ebook-animate.scale-in.is-visible {
  transform: scale(1);
}

.ebook-delay-1 { transition-delay: 0.1s; }
.ebook-delay-2 { transition-delay: 0.2s; }
.ebook-delay-3 { transition-delay: 0.3s; }
.ebook-delay-4 { transition-delay: 0.4s; }
.ebook-delay-5 { transition-delay: 0.5s; }

/* ==========================================================================
   1. HERO / PRODUCT SECTION
   ========================================================================== */

.ebook-hero-section {
  position: relative;
  z-index: 1;
  margin-bottom: 8rem;
}

.ebook-hero-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 3rem;
  align-items: start;
}

@media (min-width: 1024px) {
  .ebook-hero-grid {
    grid-template-columns: 5fr 7fr;
    gap: 5rem;
  }
}

/* --- Left Column: Cover Image --- */

.ebook-cover-column {
  perspective: 1000px;
}

.ebook-cover-wrap {
  position: relative;
  cursor: pointer;
  transform-style: preserve-3d;
  transition: transform 0.4s var(--ebook-ease);
}

/* 3D tilt on hover (CSS fallback, enhanced by JS) */
.ebook-cover-wrap:hover {
  transform: rotateX(-3deg) rotateY(5deg);
}

/* Glow effect behind cover */
.ebook-cover-glow {
  position: absolute;
  inset: 0;
  background: linear-gradient(135deg, var(--ebook-primary), var(--ebook-secondary), var(--ebook-accent));
  filter: blur(40px);
  opacity: 0.4;
  transition: opacity 0.5s ease;
  transform: translateZ(-20px);
  z-index: -1;
}

.ebook-cover-wrap:hover .ebook-cover-glow {
  opacity: 0.6;
}

.ebook-cover-inner {
  position: relative;
  transform-style: preserve-3d;
}

.ebook-cover-inner img {
  width: 100%;
  height: auto;
  display: block;
  box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.5);
  border: 1px solid rgba(255, 255, 255, 0.1);
}

/* Floating Badge: 2026 EDITION */
.ebook-badge-year {
  position: absolute;
  top: -1.5rem;
  right: -1.5rem;
  width: 6rem;
  height: 6rem;
  background-color: var(--ebook-accent);
  color: var(--ebook-dark);
  border-radius: 50%;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  font-family: var(--ebook-font-display);
  font-weight: 900;
  font-size: 1.25rem;
  text-transform: uppercase;
  transform: rotate(12deg) translateZ(40px);
  box-shadow: 0 10px 25px rgba(237, 187, 0, 0.3);
  z-index: 20;
  line-height: 1.1;
  text-align: center;
}

.ebook-badge-year .badge-sub {
  font-family: var(--ebook-font-body);
  font-size: 0.625rem;
  font-weight: 700;
  letter-spacing: 0.15em;
}

/* Instant Download Badge */
.ebook-badge-download {
  position: absolute;
  bottom: 1.5rem;
  left: 50%;
  transform: translateX(-50%) translateZ(30px);
  width: 90%;
  background-color: rgba(16, 185, 129, 0.9);
  backdrop-filter: blur(12px);
  color: var(--ebook-white);
  padding: 0.75rem 1rem;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  border: 1px solid rgba(16, 185, 129, 0.3);
  box-shadow: 0 10px 25px rgba(16, 185, 129, 0.2);
  z-index: 20;
}

.ebook-badge-download .icon {
  width: 1.25rem;
  height: 1.25rem;
  flex-shrink: 0;
}

.ebook-badge-download span {
  font-family: var(--ebook-font-mono);
  font-size: 0.8rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.05em;
}

/* Pre-Order Badge */
.ebook-badge-preorder {
  position: absolute;
  bottom: 1.5rem;
  left: 50%;
  transform: translateX(-50%) translateZ(30px);
  width: 90%;
  background-color: rgba(165, 0, 68, 0.92);
  backdrop-filter: blur(12px);
  color: var(--ebook-white);
  padding: 0.75rem 1rem;
  display: flex;
  align-items: center;
  justify-content: center;
  border: 1px solid rgba(165, 0, 68, 0.3);
  box-shadow: 0 10px 25px rgba(165, 0, 68, 0.3);
  z-index: 20;
  animation: preorder-pulse 2.5s ease-in-out infinite;
}

.ebook-badge-preorder span {
  font-family: var(--ebook-font-mono);
  font-size: 0.85rem;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: 0.2em;
}

@keyframes preorder-pulse {
  0%, 100% { box-shadow: 0 10px 25px rgba(165, 0, 68, 0.3); }
  50% { box-shadow: 0 10px 40px rgba(165, 0, 68, 0.6); }
}

/* Author Snippet */
.ebook-author {
  margin-top: 2rem;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 1rem;
}

@media (min-width: 1024px) {
  .ebook-author {
    justify-content: flex-start;
  }
}

.ebook-author img {
  width: 3rem;
  height: 3rem;
  border-radius: 50%;
  border: 1px solid rgba(255, 255, 255, 0.2);
  object-fit: cover;
}

.ebook-author-info .label {
  font-size: 0.7rem;
  color: var(--ebook-gray-500);
  text-transform: uppercase;
  letter-spacing: 0.15em;
  font-weight: 700;
}

.ebook-author-info .name {
  color: var(--ebook-white);
  font-weight: 700;
  font-size: 0.95rem;
}

/* --- Right Column: Details --- */

.ebook-details-column {
  position: relative;
  z-index: 1;
}

/* Tag: "Your Ultimate Guide" */
.ebook-tag {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  background-color: rgba(255, 255, 255, 0.05);
  border: 1px solid rgba(255, 255, 255, 0.1);
  padding: 0.25rem 0.75rem;
  border-radius: 9999px;
  font-family: var(--ebook-font-mono);
  font-size: 0.7rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.15em;
  color: var(--ebook-accent);
  margin-bottom: 1.5rem;
}

.ebook-tag .icon {
  width: 0.75rem;
  height: 0.75rem;
}

/* Title */
.ebook-title {
  font-family: var(--ebook-font-display);
  font-size: clamp(2.5rem, 6vw, 4.5rem);
  font-weight: 900;
  text-transform: uppercase;
  line-height: 0.9;
  margin: 0 0 1rem;
}

.ebook-title {
  color: var(--ebook-white);
}

.ebook-title .accent {
  color: var(--ebook-accent);
}

/* Subtitle */
.ebook-subtitle {
  font-size: 1.25rem;
  color: var(--ebook-gray-300);
  font-style: italic;
  font-family: Georgia, 'Times New Roman', serif;
  margin: 0 0 2rem;
  line-height: 1.5;
}

/* Price Block */
.ebook-price-block {
  display: flex;
  align-items: flex-end;
  gap: 1rem;
  margin-bottom: 2rem;
}

.ebook-price {
  font-family: var(--ebook-font-display);
  font-size: clamp(3rem, 6vw, 3.75rem);
  font-weight: 900;
  color: var(--ebook-white);
  line-height: 1;
}

.ebook-price-original {
  margin-bottom: 0.5rem;
}

.ebook-price-original .old-price {
  display: block;
  font-family: var(--ebook-font-mono);
  font-size: 1.125rem;
  color: var(--ebook-gray-400);
  text-decoration: line-through;
}

.ebook-price-original .one-time {
  display: block;
  font-size: 0.7rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  color: var(--ebook-accent);
}

/* CTA Button: Buy Now */
.ebook-cta-button {
  position: relative;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.75rem;
  background-color: var(--ebook-primary);
  color: var(--ebook-white);
  font-family: var(--ebook-font-mono);
  font-weight: 700;
  font-size: 1.125rem;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  padding: 1.25rem 2.5rem;
  border: none;
  cursor: pointer;
  text-decoration: none;
  transition: all 0.3s ease;
  box-shadow: 0 0 30px rgba(165, 0, 68, 0.3);
  overflow: hidden;
  width: 100%;
}

@media (min-width: 768px) {
  .ebook-cta-button {
    width: auto;
  }
}

.ebook-cta-button:hover {
  background-color: var(--ebook-primary-hover);
  box-shadow: 0 0 50px rgba(165, 0, 68, 0.5);
  color: var(--ebook-white);
  text-decoration: none;
}

.ebook-cta-button .icon {
  width: 1.25rem;
  height: 1.25rem;
}

/* Shimmer effect on hover */
.ebook-cta-button .shimmer {
  position: absolute;
  inset: 0;
  background: linear-gradient(
    90deg,
    transparent,
    rgba(255, 255, 255, 0.2),
    transparent
  );
  transform: skewX(-20deg) translateX(-200%);
  transition: transform 1s ease-in-out;
}

.ebook-cta-button:hover .shimmer {
  transform: skewX(-20deg) translateX(200%);
}

/* Trust Badges */
.ebook-trust-badges {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.75rem;
  margin-top: 1.5rem;
}

.ebook-trust-badge {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  background-color: rgba(255, 255, 255, 0.05);
  padding: 0.375rem 0.75rem;
  font-size: 0.75rem;
  font-weight: 500;
  color: var(--ebook-gray-400);
}

.ebook-trust-badge .icon {
  width: 1rem;
  height: 1rem;
  flex-shrink: 0;
}

.ebook-trust-badge .icon.icon-shield {
  color: #10b981;
}

.ebook-trust-badge .icon.icon-mail {
  color: #60a5fa;
}

.ebook-trust-badge .icon.icon-card {
  color: #a78bfa;
}

/* What You'll Get Box */
.ebook-features-box {
  margin-top: 3rem;
  background-color: var(--ebook-darker);
  border: 1px solid rgba(255, 255, 255, 0.05);
  padding: 2rem;
}

.ebook-features-box h3 {
  font-family: var(--ebook-font-display);
  font-size: 1.5rem;
  font-weight: 700;
  text-transform: uppercase;
  margin: 0 0 1rem;
  color: var(--ebook-white);
}

.ebook-features-box > p {
  color: var(--ebook-gray-300);
  line-height: 1.7;
  margin: 0 0 1.5rem;
  font-size: 1rem;
}

.ebook-features-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 1rem;
}

@media (min-width: 768px) {
  .ebook-features-grid {
    grid-template-columns: 1fr 1fr;
  }
}

.ebook-feature-item {
  display: flex;
  align-items: flex-start;
  gap: 0.75rem;
}

.ebook-feature-item .icon {
  width: 1.25rem;
  height: 1.25rem;
  flex-shrink: 0;
  margin-top: 0.125rem;
  color: var(--ebook-accent);
}

.ebook-feature-item span {
  color: var(--ebook-gray-300);
  font-size: 0.875rem;
  line-height: 1.5;
}

/* ==========================================================================
   1b. TABLE OF CONTENTS — CHAPTER COVERS CAROUSEL
   ========================================================================== */

.ebook-toc-section {
  position: relative;
  z-index: 1;
  margin-bottom: 8rem;
}

.ebook-toc-carousel-heading {
  font-family: var(--ebook-font-display);
  font-size: 1.75rem;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  color: #ffffff;
  text-align: center;
  margin: 0 0 2rem;
}

/* Carousel wrapper with nav buttons */
.ebook-toc-carousel-wrapper {
  position: relative;
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

/* Scrollable track */
.ebook-toc-carousel {
  display: flex;
  gap: 1rem;
  overflow-x: auto;
  scroll-snap-type: x mandatory;
  scroll-behavior: smooth;
  -webkit-overflow-scrolling: touch;
  scrollbar-width: none;      /* Firefox */
  padding: 0.5rem 0;
}

.ebook-toc-carousel::-webkit-scrollbar {
  display: none;               /* Chrome/Safari */
}

/* Individual slide */
.ebook-toc-carousel-slide {
  flex: 0 0 auto;
  width: 260px;
  scroll-snap-align: center;
  border-radius: 12px;
  overflow: hidden;
  transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.ebook-toc-carousel-slide:hover {
  transform: scale(1.03);
  box-shadow: 0 8px 30px rgba(0, 0, 0, 0.35);
}

.ebook-toc-carousel-slide img {
  width: 100%;
  height: auto;
  display: block;
}

/* Prev / Next buttons */
.ebook-toc-carousel-btn {
  flex-shrink: 0;
  width: 44px;
  height: 44px;
  border: none;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.15);
  color: #ffffff;
  font-size: 1.5rem;
  line-height: 1;
  cursor: pointer;
  transition: background 0.2s ease;
  display: flex;
  align-items: center;
  justify-content: center;
  backdrop-filter: blur(4px);
  -webkit-backdrop-filter: blur(4px);
}

.ebook-toc-carousel-btn:hover {
  background: var(--ebook-primary);
}

/* Dot navigation */
.ebook-toc-carousel-dots {
  display: flex;
  justify-content: center;
  gap: 0.5rem;
  margin-top: 1.5rem;
}

.ebook-toc-carousel-dot {
  width: 10px;
  height: 10px;
  border-radius: 50%;
  border: none;
  background: rgba(255, 255, 255, 0.3);
  cursor: pointer;
  padding: 0;
  transition: background 0.2s ease, transform 0.2s ease;
}

.ebook-toc-carousel-dot.active {
  background: var(--ebook-primary);
  transform: scale(1.3);
}

.ebook-toc-carousel-dot:hover {
  background: rgba(255, 255, 255, 0.6);
}

/* Responsive */
@media (min-width: 768px) {
  .ebook-toc-carousel-slide {
    width: 280px;
  }

  .ebook-toc-carousel-heading {
    font-size: 2rem;
  }
}

@media (min-width: 1024px) {
  .ebook-toc-carousel-slide {
    width: 300px;
  }
}

@media (max-width: 767px) {
  .ebook-toc-section {
    margin-bottom: 4rem;
  }

  .ebook-toc-carousel-btn {
    display: none;
  }

  .ebook-toc-carousel-slide {
    width: 220px;
  }
}

/* ==========================================================================
   2. TESTIMONIALS SECTION
   ========================================================================== */

.ebook-testimonials-section {
  position: relative;
  z-index: 1;
  margin-bottom: 8rem;
}

.ebook-testimonials-header {
  text-align: center;
  margin-bottom: 4rem;
}

.ebook-testimonials-header h2 {
  font-family: var(--ebook-font-display);
  font-size: clamp(2rem, 5vw, 2.5rem);
  font-weight: 900;
  text-transform: uppercase;
  color: var(--ebook-white);
  margin: 0 0 1rem;
}

.ebook-stars {
  display: flex;
  justify-content: center;
  gap: 0.25rem;
  color: var(--ebook-accent);
}

.ebook-stars .icon {
  width: 1.5rem;
  height: 1.5rem;
}

.ebook-testimonials-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 2rem;
}

@media (min-width: 768px) {
  .ebook-testimonials-grid {
    grid-template-columns: repeat(2, 1fr);
  }
}

@media (min-width: 1024px) {
  .ebook-testimonials-grid {
    grid-template-columns: repeat(3, 1fr);
  }
}

.ebook-testimonial-card {
  background-color: rgba(255, 255, 255, 0.05);
  padding: 2rem;
  border: 1px solid rgba(255, 255, 255, 0.05);
  position: relative;
}

.ebook-testimonial-quote {
  position: absolute;
  top: 1.5rem;
  left: 1.5rem;
  font-family: Georgia, 'Times New Roman', serif;
  font-size: 4rem;
  color: rgba(255, 255, 255, 0.1);
  line-height: 1;
  pointer-events: none;
}

.ebook-testimonial-text {
  color: var(--ebook-gray-300);
  font-style: italic;
  line-height: 1.7;
  margin: 0 0 1.5rem;
  position: relative;
  z-index: 1;
  font-size: 0.95rem;
}

.ebook-testimonial-footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
  border-top: 1px solid rgba(255, 255, 255, 0.1);
  padding-top: 1rem;
}

.ebook-testimonial-author {
  font-weight: 700;
  color: var(--ebook-white);
  font-size: 0.95rem;
}

.ebook-testimonial-country {
  font-family: var(--ebook-font-mono);
  font-size: 0.75rem;
  text-transform: uppercase;
  color: var(--ebook-gray-500);
}

/* ==========================================================================
   3. FAQ SECTION
   ========================================================================== */

.ebook-faq-section {
  position: relative;
  z-index: 1;
  max-width: 48rem;
  margin: 0 auto 8rem;
}

.ebook-faq-section h2 {
  font-family: var(--ebook-font-display);
  font-size: clamp(1.75rem, 4vw, 2rem);
  font-weight: 700;
  text-transform: uppercase;
  color: var(--ebook-white);
  text-align: center;
  margin: 0 0 2rem;
}

.ebook-faq-list {
  display: flex;
  flex-direction: column;
  gap: 1rem;
}

.ebook-faq-item {
  background-color: var(--ebook-darker);
  border: 1px solid rgba(255, 255, 255, 0.05);
  overflow: hidden;
}

.ebook-faq-question {
  display: flex;
  align-items: center;
  justify-content: space-between;
  width: 100%;
  padding: 1.5rem;
  background: none;
  border: none;
  color: var(--ebook-white);
  font-family: var(--ebook-font-body);
  font-weight: 700;
  font-size: 1rem;
  text-align: left;
  cursor: pointer;
  transition: color 0.3s ease;
}

.ebook-faq-question:hover {
  color: var(--ebook-accent);
}

.ebook-faq-question .icon {
  width: 1rem;
  height: 1rem;
  flex-shrink: 0;
  color: var(--ebook-gray-500);
  transition: transform 0.3s var(--ebook-ease);
}

.ebook-faq-item.is-open .ebook-faq-question .icon {
  transform: rotate(180deg);
}

.ebook-faq-answer {
  max-height: 0;
  overflow: hidden;
  transition: max-height 0.4s var(--ebook-ease), padding 0.4s var(--ebook-ease);
}

.ebook-faq-answer p {
  padding: 0 1.5rem 1.5rem;
  margin: 0;
  color: var(--ebook-gray-400);
  font-size: 0.875rem;
  line-height: 1.7;
}

.ebook-faq-item.is-open .ebook-faq-answer {
  max-height: 200px;
}

/* ==========================================================================
   4. BOTTOM CTA SECTION
   ========================================================================== */

.ebook-bottom-cta {
  position: relative;
  z-index: 1;
  text-align: center;
  padding-bottom: 5rem;
}

.ebook-bottom-cta-box {
  display: inline-block;
  padding: 1px;
  background: linear-gradient(to right, var(--ebook-primary), rgba(255, 255, 255, 0.5), var(--ebook-accent));
}

.ebook-bottom-cta-inner {
  background-color: var(--ebook-secondary-dark);
  padding: 3rem 2.5rem;
  position: relative;
  overflow: hidden;
}

@media (min-width: 768px) {
  .ebook-bottom-cta-inner {
    padding: 3rem 5rem;
  }
}

.ebook-bottom-cta-inner .cta-glow {
  position: absolute;
  inset: 0;
  background-color: rgba(237, 187, 0, 0.05);
  filter: blur(60px);
  pointer-events: none;
}

.ebook-bottom-cta-inner h2 {
  font-family: var(--ebook-font-display);
  font-size: clamp(2rem, 5vw, 2.5rem);
  font-weight: 900;
  text-transform: uppercase;
  color: var(--ebook-white);
  margin: 0 0 1.5rem;
  position: relative;
  z-index: 1;
}

.ebook-bottom-cta-inner > p {
  color: var(--ebook-gray-400);
  max-width: 32rem;
  margin: 0 auto 2rem;
  position: relative;
  z-index: 1;
  line-height: 1.6;
}

.ebook-btn-white {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  background-color: var(--ebook-accent);
  color: var(--ebook-dark);
  font-family: var(--ebook-font-mono);
  font-weight: 700;
  font-size: 1.125rem;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  padding: 1rem 2rem;
  text-decoration: none;
  transition: all 0.3s ease;
  position: relative;
  z-index: 1;
}

.ebook-btn-white:hover {
  background-color: #f5ca00;
  color: var(--ebook-dark);
  text-decoration: none;
}

.ebook-btn-white .icon {
  width: 1.25rem;
  height: 1.25rem;
}

/* ==========================================================================
   RESPONSIVE ADJUSTMENTS
   ========================================================================== */

@media (max-width: 767px) {
  .ebook-page {
    padding-top: 6rem;
    padding-bottom: 3rem;
  }

  .ebook-hero-section {
    margin-bottom: 4rem;
  }

  .ebook-cover-column {
    max-width: 400px;
    margin: 0 auto;
  }

  .ebook-badge-year {
    top: -1rem;
    right: -0.5rem;
    width: 5rem;
    height: 5rem;
    font-size: 1rem;
  }

  .ebook-testimonials-section {
    margin-bottom: 4rem;
  }

  .ebook-faq-section {
    margin-bottom: 4rem;
    padding-left: 1.5rem;
    padding-right: 1.5rem;
  }

  .ebook-bottom-cta {
    padding-bottom: 3rem;
  }
}

/* ==========================================================================
   WORDPRESS / BLOCKSY OVERRIDES
   ========================================================================== */

.ebook-page,
.ebook-page * {
  box-sizing: border-box;
}

.ebook-page section {
  margin-top: 0;
  margin-left: 0;
  margin-right: 0;
  padding-left: 0;
  padding-right: 0;
}

body .ebook-page .container {
  max-width: 1280px;
  width: 100%;
}

.ebook-page img {
  max-width: 100%;
  height: auto;
  border-radius: 0;
}

.ebook-page a {
  text-decoration: none;
}

.ebook-page a:hover {
  text-decoration: none;
}

.ebook-page h1,
.ebook-page h2,
.ebook-page h3 {
  margin-top: 0;
}

/* ==========================================================================
   FULL WIDTH FIX DLA EBOOK PAGE
   ========================================================================== */

.entry-content .ebook-page,
.post-content .ebook-page {
  width: 100vw !important;
  margin-left: calc(-50vw + 50%) !important;
  max-width: none !important;
}

/* ==========================================================================
   FAQ CENTERING FIX
   Ensure FAQ section is centered within the container
   ========================================================================== */

.ebook-page .ebook-faq-section {
  max-width: 48rem;
  margin-left: auto;
  margin-right: auto;
  margin-bottom: 8rem;
}

@media (max-width: 767px) {
  .ebook-page .ebook-faq-section {
    margin-bottom: 4rem;
  }
}

/* ==========================================================================
   AUTHOR BIO SECTION
   ========================================================================== */

.ebook-author-bio-section {
  padding: 0 0 5rem;
}

.ebook-author-bio-card {
  display: flex;
  align-items: center;
  gap: 3rem;
  background-color: var(--ebook-dark);
  border: 1px solid rgba(255, 255, 255, 0.08);
  padding: 2.5rem 3rem;
}

.ebook-author-bio-photo {
  flex-shrink: 0;
}

.ebook-author-bio-photo img {
  width: 160px;
  height: 160px;
  object-fit: cover;
  object-position: top center;
  border: 3px solid var(--ebook-primary);
  display: block;
}

.ebook-author-bio-eyebrow {
  font-family: var(--ebook-font-mono);
  font-size: 0.75rem;
  font-weight: 500;
  text-transform: uppercase;
  letter-spacing: 0.12em;
  color: var(--ebook-accent);
  margin: 0 0 0.5rem;
}

.ebook-author-bio-name {
  font-family: var(--ebook-font-display);
  font-size: clamp(1.5rem, 3vw, 2rem);
  font-weight: 900;
  color: var(--ebook-white);
  margin: 0 0 1rem;
}

.ebook-author-bio-text {
  color: var(--ebook-gray-400);
  font-size: 0.9375rem;
  line-height: 1.7;
  margin: 0 0 1.75rem;
  max-width: 52rem;
}

.ebook-author-bio-text strong {
  color: var(--ebook-white);
  font-weight: 600;
}

.ebook-author-bio-text em {
  color: var(--ebook-gray-300);
  font-style: italic;
}

.ebook-author-bio-stats {
  display: flex;
  gap: 2.5rem;
  margin-bottom: 1.75rem;
}

.ebook-bio-stat {
  display: flex;
  flex-direction: column;
  gap: 0.2rem;
}

.ebook-bio-stat .stat-val {
  font-family: var(--ebook-font-mono);
  font-size: 1.5rem;
  font-weight: 700;
  color: var(--ebook-accent);
  line-height: 1;
}

.ebook-bio-stat .stat-lbl {
  font-size: 0.7rem;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--ebook-gray-500);
}

.ebook-author-bio-link {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  font-family: var(--ebook-font-mono);
  font-size: 0.8125rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--ebook-accent);
  text-decoration: none;
  transition: gap 0.2s ease;
}

.ebook-author-bio-link:hover {
  gap: 0.875rem;
  color: var(--ebook-accent);
  text-decoration: none;
}

.ebook-author-bio-link svg {
  width: 1rem;
  height: 1rem;
  flex-shrink: 0;
}

/* Author name link in hero snippet */
.ebook-author-name-link {
  color: inherit;
  text-decoration: none;
  border-bottom: 1px solid rgba(255, 255, 255, 0.3);
  transition: border-color 0.2s ease, color 0.2s ease;
}

.ebook-author-name-link:hover {
  color: var(--ebook-accent);
  border-color: var(--ebook-accent);
  text-decoration: none;
}

@media (max-width: 767px) {
  .ebook-author-bio-card {
    flex-direction: column;
    padding: 2rem 1.5rem;
    text-align: center;
  }

  .ebook-author-bio-stats {
    justify-content: center;
  }

  .ebook-author-bio-link {
    justify-content: center;
  }

  .ebook-author-bio-section {
    padding-bottom: 4rem;
  }
}

/* Blocksy default copyright is hidden globally via style.css */
