/* ==========================================================================
   Folia Showcase Website — Authentic Light Mode & Editorial Style
   Matches the Real Folia Electron Application 1:1
   ========================================================================== */

:root {
  /* Folia Official Paper & Brand Palette */
  --bg-page: #FAFAF8;
  --bg-card: #FFFFFF;
  --bg-subtle: #F7F6F3;
  --bg-muted: #F1EFEA;
  --bg-hover: #EBE8E1;

  --text-main: #1A1917;
  --text-secondary: #5A564E;
  --text-muted: #8E8A80;
  --text-light: #B5B1A8;

  --border-color: #E8E5DF;
  --border-subtle: #F0EEEA;
  --border-focus: #1A1917;

  /* Folia Brand Greens */
  --brand-green: #16A34A;
  --brand-dark: #14532D;
  --brand-light: #DCFCE7;
  --brand-tint: #F0FDF4;

  /* Typography */
  --font-sans: 'Plus Jakarta Sans', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
  --font-serif: 'Lora', 'Cormorant Garamond', Georgia, serif;
  --font-mono: 'JetBrains Mono', monospace;

  /* Radii */
  --radius-sm: 6px;
  --radius-md: 10px;
  --radius-lg: 14px;
  --radius-pill: 9999px;

  /* Subtle Notion Shadows */
  --shadow-subtle: 0 1px 2px rgba(0, 0, 0, 0.04);
  --shadow-card: 0 2px 8px rgba(0, 0, 0, 0.04), 0 1px 2px rgba(0, 0, 0, 0.02);
  --shadow-app: 0 16px 40px -12px rgba(0, 0, 0, 0.1), 0 4px 14px -2px rgba(0, 0, 0, 0.04);
  --shadow-sheet: 0 6px 20px -4px rgba(0, 0, 0, 0.07), 0 2px 6px -1px rgba(0, 0, 0, 0.03);
}

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

html {
  scroll-behavior: smooth;
  font-size: 16px;
}

body {
  background-color: var(--bg-page);
  color: var(--text-main);
  font-family: var(--font-sans);
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

::selection {
  background: #DCFCE7;
  color: #14532D;
}

.container {
  width: 100%;
  max-width: 1160px;
  margin: 0 auto;
  padding: 0 1.5rem;
}

.container-narrow {
  max-width: 840px;
}

/* Typography Helpers */
h1, h2, h3, h4, h5 {
  color: var(--text-main);
  font-weight: 600;
  letter-spacing: -0.02em;
}

p {
  color: var(--text-secondary);
}

.serif {
  font-family: var(--font-serif);
}

/* Navigation */
.navbar {
  position: sticky;
  top: 0;
  background: rgba(250, 250, 248, 0.92);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border-bottom: 1px solid var(--border-color);
  z-index: 100;
}

.nav-wrap {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 64px;
}

.nav-brand {
  display: flex;
  align-items: center;
  gap: 10px;
  text-decoration: none;
  color: var(--text-main);
}

.nav-logo {
  width: 32px;
  height: 32px;
  border-radius: 7px;
  object-fit: cover;
}

.nav-title {
  font-size: 1.15rem;
  font-weight: 600;
  letter-spacing: -0.01em;
}

.nav-links {
  display: flex;
  align-items: center;
  gap: 1.8rem;
  list-style: none;
}

.nav-link {
  color: var(--text-secondary);
  text-decoration: none;
  font-size: 0.92rem;
  font-weight: 500;
  transition: color 0.15s ease;
}

.nav-link:hover {
  color: var(--text-main);
}

.nav-actions {
  display: flex;
  align-items: center;
  gap: 0.8rem;
}

/* Buttons */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  padding: 0.55rem 1.15rem;
  border-radius: var(--radius-sm);
  font-size: 0.9rem;
  font-weight: 500;
  text-decoration: none;
  cursor: pointer;
  transition: all 0.15s ease;
  white-space: nowrap;
  border: 1px solid transparent;
}

.btn-primary {
  background: #16A34A;
  color: #FFFFFF;
  border-color: #15803D;
  font-weight: 600;
  box-shadow: 0 2px 8px rgba(22, 163, 74, 0.25), 0 1px 2px rgba(0, 0, 0, 0.04);
}

.btn-primary:hover {
  background: #15803D;
  border-color: #14532D;
  color: #FFFFFF;
  box-shadow: 0 6px 18px rgba(22, 163, 74, 0.35);
  transform: translateY(-1px);
}

.btn-primary:active {
  background: #14532D;
  border-color: #14532D;
  transform: translateY(0);
}

.btn-subtle {
  background: #FFFFFF;
  color: var(--text-main);
  border-color: var(--border-color);
  box-shadow: 0 1px 2px rgba(0, 0, 0, 0.03);
}

.btn-subtle:hover {
  background: #F0FDF4;
  color: #16A34A;
  border-color: #86EFAC;
}

.btn-kofi-subtle {
  background: transparent;
  color: var(--text-secondary);
  border-color: var(--border-color);
  font-weight: 500;
}

.btn-kofi-subtle:hover {
  background: #FFF7ED;
  color: #C2410C;
  border-color: #FED7AA;
}

.btn-lg {
  padding: 0.75rem 1.4rem;
  font-size: 0.96rem;
  border-radius: var(--radius-md);
}

/* Hero Section */
.hero {
  padding: 4.5rem 0 3rem;
  text-align: center;
}

.hero-tag {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 4px 12px;
  border-radius: var(--radius-pill);
  background: var(--brand-light);
  color: var(--brand-dark);
  font-size: 0.82rem;
  font-weight: 600;
  margin-bottom: 1.5rem;
  border: 1px solid rgba(46, 125, 50, 0.15);
}

.hero-tag svg {
  width: 14px;
  height: 14px;
  color: var(--brand-green);
}

.hero-title {
  font-family: var(--font-serif);
  font-size: 3.5rem;
  line-height: 1.16;
  font-weight: 500;
  max-width: 920px;
  margin: 0 auto 1.4rem;
  color: #1A1917;
}

.hero-title em {
  font-style: italic;
  font-weight: 400;
  color: var(--brand-dark);
}

.hero-desc {
  font-size: 1.15rem;
  color: var(--text-secondary);
  max-width: 760px;
  margin: 0 auto 2.2rem;
  line-height: 1.65;
}

.hero-cta-group {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.9rem;
  margin-bottom: 2rem;
  flex-wrap: wrap;
}

.hero-meta-badges {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 1.8rem;
  font-size: 0.84rem;
  color: var(--text-muted);
  flex-wrap: wrap;
}

.hero-meta-item {
  display: flex;
  align-items: center;
  gap: 6px;
}

.hero-meta-item svg {
  width: 15px;
  height: 15px;
  color: var(--brand-green);
}

/* Niche Selector Section */
.niches-section {
  padding: 3rem 0 4.5rem;
  border-bottom: 1px solid var(--border-color);
}

.niches-intro {
  text-align: center;
  max-width: 740px;
  margin: 0 auto 2.2rem;
}

.niches-tabs {
  display: flex;
  justify-content: center;
  gap: 8px;
  flex-wrap: wrap;
  margin-bottom: 2rem;
}

.niche-tab-btn {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 8px 16px;
  border-radius: var(--radius-pill);
  background: var(--bg-card);
  border: 1px solid var(--border-color);
  color: var(--text-secondary);
  font-family: var(--font-sans);
  font-size: 0.88rem;
  font-weight: 500;
  cursor: pointer;
  transition: all 0.15s ease;
}

.niche-tab-btn:hover {
  border-color: var(--text-muted);
  color: var(--text-main);
}

.niche-tab-btn.active {
  background: #16A34A;
  color: #FFFFFF;
  border-color: #16A34A;
  box-shadow: 0 2px 8px rgba(42, 135, 59, 0.25);
}

.niche-display-card {
  background: var(--bg-card);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-md);
  padding: 2.2rem;
  box-shadow: var(--shadow-card);
  display: none;
  animation: fadeIn 0.25s ease;
}

.niche-display-card.active {
  display: block;
}

@keyframes fadeIn {
  from { opacity: 0; transform: translateY(4px); }
  to { opacity: 1; transform: translateY(0); }
}

.niche-card-header {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 20px;
  margin-bottom: 1.5rem;
  padding-bottom: 1.2rem;
  border-bottom: 1px solid var(--border-subtle);
}

.niche-header-title h3 {
  font-size: 1.5rem;
  margin-bottom: 0.3rem;
  font-family: var(--font-serif);
}

.niche-header-title p {
  font-size: 0.98rem;
}

.niche-pill-badge {
  display: inline-block;
  font-size: 0.76rem;
  font-weight: 600;
  padding: 4px 10px;
  border-radius: var(--radius-pill);
  background: var(--brand-light);
  color: var(--brand-dark);
  white-space: nowrap;
}

.niche-features-columns {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1.5rem;
}

.niche-feat-col h4 {
  font-size: 0.92rem;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  color: var(--brand-dark);
  margin-bottom: 0.8rem;
  display: flex;
  align-items: center;
  gap: 6px;
}

.niche-feat-col h4 svg {
  width: 16px;
  height: 16px;
  color: var(--brand-green);
}

.niche-bullets {
  list-style: none;
  font-size: 0.86rem;
  color: var(--text-secondary);
}

.niche-bullets li {
  margin-bottom: 0.6rem;
  position: relative;
  padding-left: 14px;
  line-height: 1.5;
}

.niche-bullets li::before {
  content: '•';
  position: absolute;
  left: 0;
  color: var(--text-muted);
}

/* ==========================================================================
   ACTUAL FOLIA APPLICATION WINDOW MOCKUP (1:1 Layout)
   ========================================================================== */
.app-mockup-wrapper {
  margin: 3.5rem auto 4.5rem;
  max-width: 1120px;
}

/* ==========================================================================
   AUTHENTIC FOLIA REAL SCREENSHOT SHOWCASE
   ========================================================================== */
.sc-header-flex {
  display: flex;
  justify-content: space-between;
  align-items: flex-end;
  margin-bottom: 1rem;
}

.sc-main-heading {
  font-size: 1.35rem;
  margin-top: 4px;
}

.sc-badge-live {
  display: flex;
  align-items: center;
  gap: 7px;
  background: #FFFFFF;
  border: 1px solid var(--border-color);
  padding: 5px 12px;
  border-radius: 999px;
  font-size: 0.78rem;
  color: var(--text-main);
  font-weight: 500;
  box-shadow: var(--shadow-subtle);
}

.sc-live-dot {
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: #22C55E;
  box-shadow: 0 0 6px #22C55E;
}

.folia-slider-window {
  background: #FFFFFF;
  border: 1px solid var(--border-color);
  border-radius: var(--radius-lg);
  box-shadow: 0 20px 48px -12px rgba(0, 0, 0, 0.1), 0 4px 16px -2px rgba(0, 0, 0, 0.04);
  overflow: hidden;
  position: relative;
}

.slider-window-topbar {
  background: #FAFAF8;
  border-bottom: 1px solid var(--border-color);
  padding: 0 16px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 52px;
  user-select: none;
}

.slider-title-center {
  display: flex;
  align-items: center;
  gap: 10px;
}

.slider-title-text {
  font-size: 0.92rem;
  font-weight: 600;
  color: var(--brand-dark);
  letter-spacing: -0.01em;
}

.slider-counter-pill {
  font-size: 0.75rem;
  font-weight: 600;
  color: var(--text-muted);
  background: #EFECE6;
  padding: 2px 9px;
  border-radius: 999px;
  font-variant-numeric: tabular-nums;
}

.slider-topbar-controls {
  display: flex;
  align-items: center;
  gap: 6px;
}

.slider-nav-btn {
  width: 32px;
  height: 32px;
  border-radius: 7px;
  background: #FFFFFF;
  border: 1px solid var(--border-color);
  color: var(--text-secondary);
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: all 0.15s ease;
  box-shadow: 0 1px 2px rgba(0, 0, 0, 0.03);
}

.slider-nav-btn:hover {
  background: #F1EFEA;
  color: var(--brand-green);
  border-color: #D3CECE;
  transform: translateY(-1px);
}

.slider-nav-btn:active {
  transform: translateY(0);
  background: #E8E5DF;
}

/* Viewport & Slider Track */
.slider-viewport {
  position: relative;
  overflow: hidden;
  width: 100%;
  background: #F5F4F0;
}

.slider-track {
  display: flex;
  width: 400%;
  transition: transform 0.45s cubic-bezier(0.22, 1, 0.36, 1);
  will-change: transform;
}

.slider-slide {
  width: 25%;
  flex-shrink: 0;
  display: flex;
  flex-direction: column;
}

/* Floating Navigation Arrows */
.slider-floating-arrow {
  position: absolute;
  top: 38%;
  transform: translateY(-50%);
  z-index: 20;
  width: 46px;
  height: 46px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.94);
  backdrop-filter: blur(8px);
  border: 1px solid rgba(0, 0, 0, 0.08);
  box-shadow: 0 4px 18px rgba(0, 0, 0, 0.14);
  color: #2D2A26;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: all 0.2s cubic-bezier(0.16, 1, 0.3, 1);
  opacity: 0.88;
}

.slider-viewport:hover .slider-floating-arrow {
  opacity: 1;
}

.slider-floating-arrow:hover {
  background: #FFFFFF;
  color: #16A34A;
  transform: translateY(-50%) scale(1.1);
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.18);
  border-color: rgba(42, 135, 59, 0.25);
}

.slider-floating-arrow:active {
  transform: translateY(-50%) scale(1.02);
}

.slider-floating-arrow.arrow-prev {
  left: 18px;
}

.slider-floating-arrow.arrow-next {
  right: 18px;
}

/* Bottom Pagination Pills */
.slider-pagination-pills {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  padding: 1.25rem 1rem 0.25rem;
  flex-wrap: wrap;
}

.slider-pill-dot {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 8px 18px;
  border-radius: 999px;
  background: #FFFFFF;
  border: 1px solid var(--border-color);
  color: var(--text-secondary);
  font-size: 0.83rem;
  font-weight: 500;
  cursor: pointer;
  transition: all 0.2s cubic-bezier(0.16, 1, 0.3, 1);
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.03);
}

.slider-pill-dot .pill-dot-circle {
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: #D1D5DB;
  transition: all 0.2s ease;
}

.slider-pill-dot:hover {
  border-color: #16A34A;
  color: var(--brand-dark);
  background: #F8FAF8;
  transform: translateY(-1px);
}

.slider-pill-dot.active {
  background: #FFFFFF;
  border-color: #16A34A;
  color: #16A34A;
  font-weight: 600;
  box-shadow: 0 3px 10px rgba(42, 135, 59, 0.15);
}

.slider-pill-dot.active .pill-dot-circle {
  background: #16A34A;
  box-shadow: 0 0 7px rgba(42, 135, 59, 0.6);
  transform: scale(1.25);
}

@media (max-width: 768px) {
  .slider-window-topbar {
    padding: 0 10px;
  }
  .slider-title-text {
    font-size: 0.82rem;
  }
  .slider-floating-arrow {
    width: 38px;
    height: 38px;
  }
  .slider-floating-arrow.arrow-prev {
    left: 8px;
  }
  .slider-floating-arrow.arrow-next {
    right: 8px;
  }
  .slider-pill-dot {
    font-size: 0.78rem;
    padding: 6px 12px;
  }
}

.sc-image-card {
  position: relative;
  background: #F5F4F0;
  cursor: zoom-in;
  overflow: hidden;
  border-bottom: 1px solid var(--border-color);
}

.sc-full-img {
  width: 100%;
  height: auto;
  display: block;
  transition: transform 0.22s ease;
}

.sc-image-card:hover .sc-full-img {
  transform: scale(1.006);
}

.sc-hover-overlay {
  position: absolute;
  inset: 0;
  background: rgba(0, 0, 0, 0.03);
  display: flex;
  align-items: flex-end;
  justify-content: flex-end;
  padding: 14px;
  pointer-events: none;
  opacity: 0.85;
  transition: opacity 0.2s ease;
}

.sc-image-card:hover .sc-hover-overlay {
  opacity: 1;
}

.sc-zoom-btn {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  background: rgba(26, 25, 23, 0.85);
  color: #FFFFFF;
  padding: 6px 13px;
  border-radius: 6px;
  font-size: 0.78rem;
  font-weight: 500;
  backdrop-filter: blur(4px);
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.25);
}

.sc-feature-highlights {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 1.2rem;
  padding: 1.5rem 1.6rem;
  background: #FAFAF8;
}

.sc-hl-box {
  display: flex;
  align-items: flex-start;
  gap: 10px;
}

.sc-hl-num {
  width: 22px;
  height: 22px;
  border-radius: 50%;
  background: var(--brand-light);
  color: var(--brand-dark);
  font-weight: 700;
  font-size: 0.78rem;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  margin-top: 1px;
}

.sc-hl-box strong {
  display: block;
  font-size: 0.86rem;
  color: var(--text-main);
  margin-bottom: 3px;
}

.sc-hl-box p {
  font-size: 0.78rem;
  color: var(--text-secondary);
  line-height: 1.45;
  margin: 0;
}

/* Lightbox Modal */
#folia-lightbox {
  position: fixed;
  inset: 0;
  background: rgba(15, 23, 42, 0.92);
  backdrop-filter: blur(8px);
  z-index: 99999;
  display: none;
  align-items: center;
  justify-content: center;
  padding: 1.5rem;
  cursor: zoom-out;
}

#folia-lightbox.active {
  display: flex;
}

#folia-lightbox img {
  max-width: 95vw;
  max-height: 92vh;
  border-radius: 8px;
  box-shadow: 0 25px 60px rgba(0, 0, 0, 0.6);
  cursor: default;
}

.lightbox-close-btn {
  position: absolute;
  top: 16px;
  right: 20px;
  color: #FFFFFF;
  background: rgba(255, 255, 255, 0.15);
  border: none;
  font-size: 1.4rem;
  width: 38px;
  height: 38px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: background 0.15s ease;
}

.lightbox-close-btn:hover {
  background: rgba(255, 255, 255, 0.3);
}

@media (max-width: 900px) {
  .sc-feature-highlights {
    grid-template-columns: repeat(2, 1fr);
  }
  .sc-tabs-nav {
    overflow-x: auto;
  }
}

@media (max-width: 600px) {
  .sc-feature-highlights {
    grid-template-columns: 1fr;
  }
  .sc-window-dots {
    display: none;
  }
}

.folia-real-window {
  background: #FFFFFF;
  border: 1px solid var(--border-color);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-app);
  overflow: hidden;
  text-align: left;
  display: flex;
  flex-direction: column;
  height: 640px;
}

/* 1. Real Folia TopBar */
.real-topbar {
  height: 48px;
  background: #FAFAF8;
  border-bottom: 1px solid var(--border-color);
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 14px;
  user-select: none;
  font-size: 0.82rem;
}

.topbar-left {
  display: flex;
  align-items: center;
  gap: 12px;
}

.topbar-dots {
  display: flex;
  gap: 6px;
  align-items: center;
  margin-right: 4px;
}

.topbar-dot {
  width: 11px;
  height: 11px;
  border-radius: 50%;
}

.dot-close { background: #FF5F56; border: 1px solid #E0443E; }
.dot-min { background: #FFBD2E; border: 1px solid #DEA123; }
.dot-max { background: #27C93F; border: 1px solid #1AAB29; }

.topbar-brand {
  display: flex;
  align-items: center;
  gap: 7px;
  font-weight: 700;
  color: #1A1917;
  letter-spacing: -0.01em;
}

.topbar-brand img {
  width: 20px;
  height: 20px;
  border-radius: 4px;
}

.topbar-project-pill {
  display: flex;
  align-items: center;
  gap: 6px;
  background: #F1EFEA;
  border: 1px solid var(--border-color);
  border-radius: var(--radius-sm);
  padding: 3px 9px;
  font-size: 0.78rem;
  color: var(--text-main);
  font-weight: 500;
}

.topbar-center {
  display: flex;
  align-items: center;
  gap: 12px;
}

.topbar-save-status {
  display: flex;
  align-items: center;
  gap: 5px;
  color: var(--brand-green);
  font-size: 0.76rem;
  font-weight: 600;
}

.topbar-metrics-pill {
  display: flex;
  align-items: center;
  gap: 8px;
  background: #F1EFEA;
  border: 1px solid var(--border-color);
  border-radius: var(--radius-sm);
  padding: 3px 10px;
  font-size: 0.76rem;
  color: var(--text-secondary);
  font-family: var(--font-mono);
}

.topbar-right {
  display: flex;
  align-items: center;
  gap: 8px;
}

.topbar-tool-btn {
  display: flex;
  align-items: center;
  gap: 5px;
  padding: 4px 8px;
  border-radius: 4px;
  background: transparent;
  border: 1px solid transparent;
  color: var(--text-secondary);
  font-size: 0.76rem;
  font-weight: 500;
  cursor: pointer;
}

.topbar-tool-btn:hover {
  background: #EBE8E1;
  color: var(--text-main);
}

/* 2. Real Folia Main Workspace Layout (Sidebar + Content View) */
.real-app-workspace {
  display: flex;
  flex: 1;
  overflow: hidden;
  background: #F1EFEA;
}

/* Left Global Navigation Sidebar (Exact Folia Navigation) */
.real-app-sidebar {
  width: 210px;
  background: #FAFAF8;
  border-right: 1px solid var(--border-color);
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  padding: 12px 8px;
  user-select: none;
  flex-shrink: 0;
}

.sidebar-search-box {
  display: flex;
  align-items: center;
  gap: 6px;
  background: #FFFFFF;
  border: 1px solid var(--border-color);
  border-radius: 6px;
  padding: 5px 8px;
  font-size: 0.76rem;
  color: var(--text-muted);
  margin-bottom: 12px;
}

.sidebar-nav-section-title {
  font-size: 0.68rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  color: var(--text-muted);
  padding: 4px 8px;
  margin-bottom: 4px;
}

.sidebar-nav-item {
  display: flex;
  align-items: center;
  gap: 9px;
  padding: 7px 10px;
  border-radius: 6px;
  color: var(--text-secondary);
  font-size: 0.82rem;
  font-weight: 500;
  cursor: pointer;
  transition: all 0.12s ease;
  margin-bottom: 2px;
  border: 1px solid transparent;
}

.sidebar-nav-item:hover {
  background: #EBE8E1;
  color: var(--text-main);
}

.sidebar-nav-item.active {
  background: #E8F5E9;
  color: #1B4332;
  font-weight: 600;
  border-color: rgba(46, 125, 50, 0.15);
}

.sidebar-nav-item svg {
  width: 16px;
  height: 16px;
  color: var(--text-muted);
}

.sidebar-nav-item.active svg {
  color: var(--brand-green);
}

.sidebar-bottom-tools {
  border-top: 1px solid var(--border-color);
  padding-top: 8px;
}

/* 3. Real Folia Center Workspace Views */
.real-app-view-container {
  flex: 1;
  overflow: hidden;
  position: relative;
  display: flex;
  flex-direction: column;
}

.real-view-pane {
  display: none;
  width: 100%;
  height: 100%;
}

.real-view-pane.active {
  display: flex;
  flex-direction: column;
}

/* Subview: Manoscritto & Editor */
.real-editor-layout {
  display: flex;
  flex: 1;
  overflow: hidden;
}

.real-chapter-list {
  width: 190px;
  background: #F7F6F3;
  border-right: 1px solid var(--border-color);
  padding: 10px 8px;
  overflow-y: auto;
  font-size: 0.8rem;
  flex-shrink: 0;
}

.ch-list-heading {
  display: flex;
  align-items: center;
  justify-content: space-between;
  font-size: 0.68rem;
  font-weight: 700;
  text-transform: uppercase;
  color: var(--text-muted);
  padding: 4px 6px;
  margin-bottom: 6px;
}

.ch-item {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 6px 8px;
  border-radius: 5px;
  color: var(--text-secondary);
  cursor: pointer;
  margin-bottom: 2px;
}

.ch-item:hover {
  background: #EAE8E1;
  color: var(--text-main);
}

.ch-item.active {
  background: #FFFFFF;
  color: var(--text-main);
  font-weight: 600;
  box-shadow: 0 1px 3px rgba(0,0,0,0.04);
  border: 1px solid var(--border-color);
}

.ch-item-words {
  font-size: 0.7rem;
  font-family: var(--font-mono);
  color: var(--text-muted);
}

/* Center Editor Sheet */
.real-editor-center {
  flex: 1;
  display: flex;
  flex-direction: column;
  overflow-y: auto;
  background: #F1EFEA;
}

.real-tiptap-toolbar {
  background: #FFFFFF;
  border-bottom: 1px solid var(--border-color);
  padding: 6px 14px;
  display: flex;
  align-items: center;
  gap: 6px;
  font-size: 0.74rem;
  color: var(--text-secondary);
  flex-wrap: wrap;
  flex-shrink: 0;
}

.real-tb-select {
  padding: 3px 8px;
  border-radius: 4px;
  border: 1px solid var(--border-color);
  background: #FAFAF8;
  font-size: 0.74rem;
  font-weight: 500;
}

.real-tb-btn {
  padding: 3px 6px;
  border-radius: 4px;
  border: 1px solid transparent;
  background: transparent;
  cursor: pointer;
  color: var(--text-secondary);
}

.real-tb-btn:hover {
  background: #EBE8E1;
}

.real-tb-btn.active {
  background: #E8F5E9;
  color: #1B4332;
  border-color: rgba(46, 125, 50, 0.2);
  font-weight: 600;
}

.real-editor-sheet {
  background: #FFFFFF;
  border: 1px solid var(--border-color);
  box-shadow: var(--shadow-sheet);
  border-radius: 4px;
  width: 90%;
  max-width: 530px;
  margin: 18px auto 24px;
  padding: 36px 44px;
  font-family: var(--font-serif);
  color: #1A1917;
  line-height: 1.8;
}

.real-editor-sheet h2 {
  font-family: var(--font-serif);
  font-size: 1.4rem;
  font-weight: 600;
  margin-bottom: 1.2rem;
  border-bottom: 1px solid #F0EEEA;
  padding-bottom: 0.4rem;
}

.real-editor-sheet p {
  color: #24221D;
  font-size: 0.94rem;
  margin-bottom: 1rem;
  text-indent: 1.2rem;
  text-align: justify;
}

.real-editor-sheet p.dialogue {
  text-indent: 0;
  padding-left: 1.2rem;
  font-style: italic;
}

.real-editor-inspector {
  width: 200px;
  background: #F7F6F3;
  border-left: 1px solid var(--border-color);
  padding: 12px;
  font-size: 0.78rem;
  overflow-y: auto;
  flex-shrink: 0;
}

.real-stat-card {
  background: #FFFFFF;
  border: 1px solid var(--border-color);
  border-radius: 5px;
  padding: 8px 10px;
  margin-bottom: 8px;
}

.real-stat-card .lbl {
  font-size: 0.66rem;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  color: var(--text-muted);
}

.real-stat-card .val {
  font-family: var(--font-mono);
  font-size: 1.12rem;
  font-weight: 700;
  color: var(--text-main);
}

.real-stat-card .sub {
  font-size: 0.7rem;
  color: var(--text-muted);
}

/* Subview: Personaggi & D&D */
.real-chars-layout {
  display: grid;
  grid-template-columns: 240px 1fr;
  flex: 1;
  overflow: hidden;
  background: #F1EFEA;
}

.real-chars-sublist {
  background: #F7F6F3;
  border-right: 1px solid var(--border-color);
  padding: 12px 8px;
  overflow-y: auto;
}

.real-char-card {
  background: #FFFFFF;
  border: 1px solid var(--border-color);
  border-radius: 6px;
  padding: 10px 12px;
  margin-bottom: 8px;
  cursor: pointer;
  transition: all 0.12s ease;
}

.real-char-card.active {
  border-color: var(--brand-green);
  box-shadow: 0 0 0 1px var(--brand-green);
}

.real-char-role-badge {
  display: inline-block;
  font-size: 0.66rem;
  font-weight: 700;
  text-transform: uppercase;
  padding: 2px 6px;
  border-radius: 4px;
  margin-bottom: 4px;
}

.real-char-detail {
  padding: 20px;
  overflow-y: auto;
  background: #FFFFFF;
}

/* Subview: Mappe Geografiche con Pin */
.real-maps-layout {
  display: grid;
  grid-template-columns: 1fr 280px;
  flex: 1;
  overflow: hidden;
}

.real-map-canvas {
  background: #E5D9C4;
  background-image: radial-gradient(#CCAFA0 1.5px, transparent 1.5px);
  background-size: 26px 26px;
  position: relative;
  display: flex;
  align-items: center;
  justify-content: center;
}

.real-map-island {
  width: 76%;
  height: 76%;
  border-radius: 42% 58% 70% 30% / 45% 45% 55% 55%;
  background: #D8C7AE;
  border: 2px dashed #BFA88D;
  position: relative;
}

.real-map-pin {
  position: absolute;
  display: flex;
  align-items: center;
  gap: 6px;
  padding: 4px 10px;
  background: #FFFFFF;
  border: 1px solid var(--border-color);
  border-radius: var(--radius-pill);
  font-size: 0.76rem;
  font-weight: 600;
  box-shadow: var(--shadow-card);
  cursor: pointer;
}

.pin-silente { top: 22%; left: 34%; }
.pin-valico { top: 58%; left: 62%; }
.pin-dungeon { top: 68%; left: 28%; }

.real-map-sidebar {
  background: #FFFFFF;
  border-left: 1px solid var(--border-color);
  padding: 18px;
  overflow-y: auto;
}

/* Subview: Bacheca Corkboard */
.real-cork-layout {
  flex: 1;
  padding: 20px;
  overflow-y: auto;
  background: #EDEAE3;
}

.real-cork-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(210px, 1fr));
  gap: 16px;
}

.real-cork-card {
  background: #FFFFFF;
  border: 1px solid #D8D4CA;
  border-top: 4px solid var(--brand-green);
  border-radius: 4px;
  padding: 12px;
  box-shadow: var(--shadow-subtle);
}

.real-cork-card:nth-child(2) { border-top-color: #D97706; }
.real-cork-card:nth-child(3) { border-top-color: #2563EB; }
.real-cork-card:nth-child(4) { border-top-color: #7C3AED; }

/* Subview: Outliner Trama */
.real-plot-layout {
  flex: 1;
  padding: 18px;
  overflow-y: auto;
  background: #F1EFEA;
}

/* Clean Feature Sections (Notion Style) */
.section-clean {
  padding: 4.8rem 0;
  border-top: 1px solid var(--border-color);
}

.section-head {
  text-align: left;
  max-width: 720px;
  margin-bottom: 2.8rem;
}

.section-label {
  font-size: 0.78rem;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  font-weight: 700;
  color: var(--brand-green);
  margin-bottom: 0.4rem;
  display: block;
}

.section-head h2 {
  font-family: var(--font-serif);
  font-size: 2.2rem;
  margin-bottom: 0.6rem;
  line-height: 1.25;
}

.section-head p {
  font-size: 1.05rem;
  color: var(--text-secondary);
}

/* Feature 3-Columns Clean */
.grid-features {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1.8rem;
}

.feature-box {
  background: var(--bg-card);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-md);
  padding: 1.8rem;
  box-shadow: var(--shadow-subtle);
  transition: border-color 0.15s ease;
}

.feature-box:hover {
  border-color: #C8C4B8;
}

.feature-icon-clean {
  width: 40px;
  height: 40px;
  border-radius: 6px;
  background: var(--bg-subtle);
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 1.1rem;
  color: var(--brand-dark);
}

.feature-icon-clean svg {
  width: 20px;
  height: 20px;
}

.feature-box h3 {
  font-size: 1.18rem;
  margin-bottom: 0.5rem;
}

.feature-box p {
  font-size: 0.88rem;
  line-height: 1.6;
  color: var(--text-secondary);
}

.feature-box ul {
  margin-top: 10px;
  list-style: none;
  font-size: 0.82rem;
  color: var(--text-muted);
}

.feature-box ul li {
  margin-bottom: 4px;
  display: flex;
  align-items: center;
  gap: 6px;
}

.feature-box ul li svg {
  color: var(--brand-green);
  width: 12px;
  height: 12px;
}

/* Local-First Editorial Highlight */
.local-banner {
  background: var(--bg-card);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-md);
  padding: 2.4rem;
  display: grid;
  grid-template-columns: 1.2fr 0.8fr;
  gap: 2.2rem;
  align-items: center;
  margin-top: 3.5rem;
}

.local-banner h3 {
  font-family: var(--font-serif);
  font-size: 1.65rem;
  margin-bottom: 0.6rem;
}

.local-banner p {
  font-size: 0.95rem;
  color: var(--text-secondary);
  line-height: 1.6;
  margin-bottom: 1.2rem;
}

.local-points {
  list-style: none;
}

.local-points li {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 0.86rem;
  color: var(--text-main);
  margin-bottom: 6px;
}

.local-points li svg {
  width: 14px;
  height: 14px;
  color: var(--brand-green);
}

.local-box-clean {
  background: var(--bg-subtle);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-sm);
  padding: 1.4rem;
  font-family: var(--font-mono);
  font-size: 0.8rem;
  color: var(--text-secondary);
  line-height: 1.65;
}

.local-box-clean .green {
  color: var(--brand-green);
  font-weight: 600;
}

/* Ko-fi Section — Sincere & Elegant */
.kofi-box {
  background: #FFFFFF;
  border: 1px solid var(--border-color);
  border-radius: var(--radius-md);
  padding: 2.8rem 2.2rem;
  max-width: 780px;
  margin: 0 auto;
  text-align: center;
}

.kofi-cup-icon {
  width: 46px;
  height: 46px;
  border-radius: var(--radius-pill);
  background: #FFF7ED;
  color: #EA580C;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 1.1rem;
}

.kofi-cup-icon svg {
  width: 22px;
  height: 22px;
}

.kofi-box h3 {
  font-family: var(--font-serif);
  font-size: 1.85rem;
  font-weight: 500;
  margin-bottom: 0.8rem;
}

.kofi-box p {
  font-size: 0.98rem;
  color: var(--text-secondary);
  line-height: 1.7;
  max-width: 640px;
  margin: 0 auto 1.8rem;
}

.kofi-action-row {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 12px;
  flex-wrap: wrap;
}

/* Download Section — Minimal & Professional */
.download-grid-clean {
  display: flex;
  justify-content: center;
  max-width: 520px;
  margin: 0 auto 2rem;
  width: 100%;
}

.download-card-clean {
  background: var(--bg-card);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-md);
  padding: 2rem 1.8rem;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  width: 100%;
}

.download-card-clean.featured {
  border-color: #16A34A;
  box-shadow: 0 4px 18px rgba(42, 135, 59, 0.12);
}

.dl-platform-top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 0.8rem;
}

.dl-platform-top svg {
  width: 24px;
  height: 24px;
  color: var(--text-main);
}

.dl-badge {
  font-size: 0.7rem;
  font-weight: 600;
  padding: 2px 8px;
  border-radius: 4px;
}

.dl-badge-available {
  background: var(--brand-light);
  color: var(--brand-dark);
}

.dl-badge-coming {
  background: var(--bg-subtle);
  color: var(--text-muted);
}

.download-card-clean h4 {
  font-size: 1.25rem;
  margin-bottom: 0.2rem;
}

.dl-meta {
  font-size: 0.8rem;
  color: var(--text-muted);
  margin-bottom: 1.2rem;
}

.dl-specs-list {
  list-style: none;
  font-size: 0.82rem;
  color: var(--text-secondary);
  margin-bottom: 1.8rem;
}

.dl-specs-list li {
  margin-bottom: 6px;
  display: flex;
  align-items: center;
  gap: 6px;
}

.dl-specs-list li svg {
  width: 13px;
  height: 13px;
  color: var(--brand-green);
  flex-shrink: 0;
}

.dl-note-clean {
  font-size: 0.86rem;
  color: var(--text-muted);
  text-align: center;
  margin-top: 1rem;
}

/* FAQ Notion Accordion */
.faq-clean-wrap {
  max-width: 820px;
  margin: 0 auto;
}

.faq-row {
  border-bottom: 1px solid var(--border-color);
}

.faq-btn {
  width: 100%;
  padding: 1.2rem 0;
  display: flex;
  align-items: center;
  justify-content: space-between;
  background: none;
  border: none;
  cursor: pointer;
  text-align: left;
  font-family: var(--font-sans);
  font-size: 1.05rem;
  font-weight: 600;
  color: var(--text-main);
  transition: color 0.15s ease;
}

.faq-btn:hover {
  color: var(--brand-dark);
}

.faq-arrow {
  width: 18px;
  height: 18px;
  color: var(--text-muted);
  transition: transform 0.2s ease;
}

.faq-row.active .faq-arrow {
  transform: rotate(90deg);
}

.faq-collapse {
  max-height: 0;
  overflow: hidden;
  transition: max-height 0.25s ease;
}

.faq-text-body {
  padding-bottom: 1.2rem;
  font-size: 0.94rem;
  color: var(--text-secondary);
  line-height: 1.65;
}

/* Footer */
.footer-clean {
  border-top: 1px solid var(--border-color);
  padding: 3.5rem 0 2.2rem;
  background: var(--bg-subtle);
  margin-top: 5rem;
  font-size: 0.88rem;
}

.footer-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 1.5rem;
}

.footer-left {
  display: flex;
  align-items: center;
  gap: 10px;
}

.footer-left img {
  width: 24px;
  height: 24px;
  border-radius: 4px;
}

.footer-nav {
  display: flex;
  gap: 1.5rem;
}

.footer-nav a {
  color: var(--text-secondary);
  text-decoration: none;
}

.footer-nav a:hover {
  color: var(--text-main);
}

/* Responsive */
@media (max-width: 990px) {
  .hero-title { font-size: 2.7rem; }
  .grid-features { grid-template-columns: 1fr; }
  .niche-features-columns { grid-template-columns: 1fr; }
  .download-grid-clean { grid-template-columns: 1fr; }
  .local-banner { grid-template-columns: 1fr; }
  .real-app-sidebar { display: none; }
  .real-chapter-list { display: none; }
  .real-editor-inspector { display: none; }
  .real-chars-layout { grid-template-columns: 1fr; }
  .real-maps-layout { grid-template-columns: 1fr; }
  .real-map-sidebar { display: none; }
  .nav-links { display: none; }
}

/* ==========================================================================
   Folia CMS In-Browser Editor Styles (?edit=true)
   ========================================================================== */
#folia-cms-bar {
  position: sticky;
  top: 0;
  left: 0;
  width: 100%;
  background: #16A34A;
  color: #FFFFFF;
  padding: 0.65rem 1.5rem;
  z-index: 9999;
  font-size: 0.85rem;
  box-shadow: 0 2px 10px rgba(0, 0, 0, 0.15);
}

.cms-bar-wrap {
  max-width: 1160px;
  margin: 0 auto;
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.cms-bar-left {
  display: flex;
  align-items: center;
  gap: 8px;
}

.cms-pulse {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: #86EFAC;
  display: inline-block;
  box-shadow: 0 0 8px #86EFAC;
}

.cms-hint {
  opacity: 0.85;
  font-size: 0.8rem;
}

.cms-bar-right {
  display: flex;
  align-items: center;
  gap: 8px;
}

.cms-btn {
  padding: 0.35rem 0.8rem;
  border-radius: 6px;
  font-size: 0.8rem;
  font-weight: 600;
  border: none;
  cursor: pointer;
  transition: all 0.15s ease;
}

.cms-btn-prim {
  background: #FFFFFF;
  color: #16A34A;
}

.cms-btn-prim:hover {
  background: #DCFCE7;
}

.cms-btn-sec {
  background: rgba(255, 255, 255, 0.15);
  color: #FFFFFF;
}

.cms-btn-sec:hover {
  background: rgba(255, 255, 255, 0.25);
}

.cms-btn-close {
  background: transparent;
  color: #FFFFFF;
  font-size: 1rem;
  padding: 0.2rem 0.5rem;
}

.cms-btn-close:hover {
  background: rgba(255, 255, 255, 0.2);
}

.folia-cms-edit-mode .cms-editable {
  outline: 1px dashed rgba(42, 135, 59, 0.4);
  transition: outline 0.15s ease, background 0.15s ease;
  border-radius: 2px;
}

.folia-cms-edit-mode .cms-editable:hover {
  outline: 2px solid #16A34A;
  background: rgba(240, 253, 244, 0.6);
  cursor: text;
}

.folia-cms-edit-mode .cms-editable:focus {
  outline: 2px solid #22C55E;
  background: #FFFFFF;
}

#folia-cms-toast {
  position: fixed;
  bottom: 24px;
  right: 24px;
  background: #14532D;
  color: #FFFFFF;
  padding: 0.8rem 1.4rem;
  border-radius: 8px;
  font-size: 0.88rem;
  font-weight: 500;
  box-shadow: 0 6px 20px rgba(0, 0, 0, 0.18);
  z-index: 10000;
  transform: translateY(100px);
  opacity: 0;
  transition: transform 0.3s ease, opacity 0.3s ease;
  pointer-events: none;
}

#folia-cms-toast.visible {
  transform: translateY(0);
  opacity: 1;
}

/* ==========================================================================
   Reviews & Testimonials Section (Verde Assenzio Theme)
   ========================================================================== */
.reviews-wrapper {
  margin: 4.5rem auto;
  max-width: 1120px;
}

.reviews-header-center {
  text-align: center;
  max-width: 760px;
  margin: 0 auto 2.5rem;
}

.reviews-summary-bar {
  display: inline-flex;
  align-items: center;
  gap: 1.5rem;
  background: #FFFFFF;
  border: 1px solid var(--border-color);
  padding: 0.65rem 1.4rem;
  border-radius: var(--radius-pill);
  box-shadow: var(--shadow-subtle);
  margin-top: 1.25rem;
  flex-wrap: wrap;
  justify-content: center;
}

.summary-score-box {
  display: flex;
  align-items: center;
  gap: 8px;
}

.summary-stars {
  color: #F59E0B;
  font-size: 1.15rem;
  letter-spacing: 1px;
}

.summary-number {
  font-size: 1.05rem;
  font-weight: 700;
  color: var(--text-main);
}

.summary-count {
  font-size: 0.84rem;
  color: var(--text-secondary);
}

.btn-leave-review {
  padding: 0.45rem 1.1rem !important;
  font-size: 0.85rem !important;
  border-radius: var(--radius-pill) !important;
}

.reviews-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 1.5rem;
}

.review-card {
  background: #FFFFFF;
  border: 1px solid var(--border-color);
  border-radius: var(--radius-lg);
  padding: 1.6rem;
  box-shadow: var(--shadow-card);
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.review-card:hover {
  transform: translateY(-2px);
  box-shadow: 0 8px 24px -4px rgba(0, 0, 0, 0.08);
}

.review-card-top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 1rem;
}

.reviewer-info {
  display: flex;
  align-items: center;
  gap: 12px;
}

.reviewer-avatar {
  width: 42px;
  height: 42px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 700;
  font-size: 0.9rem;
  color: #FFFFFF;
  flex-shrink: 0;
}

.avatar-purple { background: linear-gradient(135deg, #8B5CF6, #6D28D9); }
.avatar-amber  { background: linear-gradient(135deg, #F59E0B, #D97706); }
.avatar-blue   { background: linear-gradient(135deg, #3B82F6, #1D4ED8); }
.avatar-green  { background: linear-gradient(135deg, #16A34A, #14532D); }

.reviewer-name {
  display: block;
  font-size: 0.95rem;
  color: var(--text-main);
}

.reviewer-role {
  display: block;
  font-size: 0.78rem;
  color: var(--text-muted);
}

.review-stars {
  color: #F59E0B;
  font-size: 0.95rem;
  letter-spacing: 1px;
}

.review-heading {
  font-size: 1.02rem;
  font-weight: 600;
  color: var(--brand-dark);
  margin-bottom: 0.65rem;
  line-height: 1.35;
}

.review-text {
  font-size: 0.88rem;
  color: var(--text-secondary);
  line-height: 1.6;
  margin-bottom: 1.25rem;
  flex-grow: 1;
}

.review-footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
  font-size: 0.76rem;
  color: var(--text-muted);
  border-top: 1px solid var(--border-subtle);
  padding-top: 0.75rem;
}

.review-verified {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  color: #16A34A;
  font-weight: 600;
}

/* ==========================================================================
   Google Auth & Review Modal
   ========================================================================== */
.review-modal-overlay {
  position: fixed;
  inset: 0;
  background: rgba(15, 23, 42, 0.65);
  backdrop-filter: blur(4px);
  z-index: 99999;
  display: none;
  align-items: center;
  justify-content: center;
  padding: 1rem;
}

.review-modal-overlay.active {
  display: flex;
}

.review-modal-card {
  background: #FFFFFF;
  border-radius: var(--radius-lg);
  max-width: 520px;
  width: 100%;
  padding: 2.2rem;
  box-shadow: 0 25px 60px -15px rgba(0, 0, 0, 0.25);
  position: relative;
  animation: modalFadeIn 0.22s cubic-bezier(0.16, 1, 0.3, 1);
}

@keyframes modalFadeIn {
  from { opacity: 0; transform: scale(0.96) translateY(8px); }
  to { opacity: 1; transform: scale(1) translateY(0); }
}

.review-modal-close {
  position: absolute;
  top: 16px;
  right: 18px;
  border: none;
  background: transparent;
  font-size: 1.2rem;
  color: var(--text-muted);
  cursor: pointer;
  width: 32px;
  height: 32px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all 0.15s ease;
}

.review-modal-close:hover {
  background: #F1EFEA;
  color: var(--text-main);
}

.review-modal-icon {
  width: 54px;
  height: 54px;
  border-radius: 12px;
  background: var(--brand-light);
  color: #16A34A;
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 1.25rem;
}

.review-modal-card h3 {
  font-size: 1.35rem;
  font-weight: 700;
  color: var(--text-main);
  margin-bottom: 0.65rem;
}

.review-modal-desc {
  font-size: 0.88rem;
  color: var(--text-secondary);
  line-height: 1.55;
  margin-bottom: 1.75rem;
}

.btn-google-signin {
  width: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 12px;
  background: #FFFFFF;
  color: #3C4043;
  border: 1px solid #DADCE0;
  border-radius: 8px;
  padding: 0.8rem 1.2rem;
  font-size: 0.95rem;
  font-weight: 600;
  cursor: pointer;
  box-shadow: 0 1px 3px rgba(60, 64, 67, 0.08);
  transition: all 0.18s ease;
}

.btn-google-signin:hover {
  background: #F8FAFC;
  border-color: #C2C7D0;
  box-shadow: 0 2px 8px rgba(60, 64, 67, 0.15);
}

.review-modal-privacy-note {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-top: 1.25rem;
  font-size: 0.76rem;
  color: var(--text-muted);
  line-height: 1.4;
}

/* Review Form Inside Modal */
.review-user-connected {
  display: flex;
  align-items: center;
  gap: 12px;
  background: var(--brand-light);
  border: 1px solid rgba(118, 181, 131, 0.3);
  padding: 0.75rem 1rem;
  border-radius: 8px;
  margin-bottom: 1.5rem;
}

.connected-user-avatar {
  width: 36px;
  height: 36px;
  border-radius: 50%;
  background: #16A34A;
  color: #FFFFFF;
  font-weight: 700;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 0.85rem;
}

.connected-user-name {
  font-size: 0.88rem;
  font-weight: 600;
  color: var(--brand-dark);
}

.connected-user-badge {
  font-size: 0.72rem;
  color: #16A34A;
  font-weight: 600;
}

.btn-disconnect-google {
  margin-left: auto;
  background: transparent;
  border: none;
  font-size: 0.76rem;
  color: var(--text-muted);
  cursor: pointer;
  text-decoration: underline;
}

.form-group {
  margin-bottom: 1.15rem;
}

.form-label {
  display: block;
  font-size: 0.82rem;
  font-weight: 600;
  color: var(--text-main);
  margin-bottom: 0.4rem;
}

.form-input, .form-textarea, .form-select {
  width: 100%;
  padding: 0.65rem 0.85rem;
  border: 1px solid var(--border-color);
  border-radius: var(--radius-sm);
  font-family: inherit;
  font-size: 0.88rem;
  color: var(--text-main);
  background: #FFFFFF;
  transition: border-color 0.15s ease, box-shadow 0.15s ease;
}

.form-input:focus, .form-textarea:focus, .form-select:focus {
  outline: none;
  border-color: #16A34A;
  box-shadow: 0 0 0 3px rgba(118, 181, 131, 0.2);
}

.star-rating-picker {
  display: flex;
  gap: 6px;
  font-size: 1.7rem;
  color: #D1D5DB;
  cursor: pointer;
}

.star-rating-picker .star-btn {
  transition: color 0.15s ease, transform 0.15s ease;
  user-select: none;
}

.star-rating-picker .star-btn.active {
  color: #F59E0B;
}

.star-rating-picker .star-btn:hover {
  transform: scale(1.15);
}

.form-actions {
  display: flex;
  justify-content: flex-end;
  gap: 10px;
  margin-top: 1.5rem;
}

/* ==========================================================================
   Live Download Counter Pill
   ========================================================================== */
.download-counter-pill {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  background: #FFFFFF;
  border: 1px solid var(--border-color);
  padding: 6px 14px;
  border-radius: var(--radius-pill);
  font-size: 0.82rem;
  color: var(--text-secondary);
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.04);
  margin-top: 1.1rem;
}

.counter-pulse {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: #16A34A;
  box-shadow: 0 0 8px #16A34A;
  display: inline-block;
  animation: pulseGreen 2s infinite;
}

@keyframes pulseGreen {
  0% { transform: scale(0.95); box-shadow: 0 0 0 0 rgba(118, 181, 131, 0.7); }
  70% { transform: scale(1); box-shadow: 0 0 0 8px rgba(118, 181, 131, 0); }
  100% { transform: scale(0.95); box-shadow: 0 0 0 0 rgba(118, 181, 131, 0); }
}

.counter-label {
  color: var(--text-muted);
}

.counter-val {
  font-weight: 700;
  color: #14532D;
  font-variant-numeric: tabular-nums;
  font-size: 0.9rem;
}

@media (max-width: 768px) {
  .reviews-grid {
    grid-template-columns: 1fr;
  }
}



/* Reviews Empty State & CTA */
.reviews-cta-card {
  background: #FFFFFF;
  border: 1px solid var(--border-color);
  border-radius: var(--radius-lg);
  padding: 2.8rem 2rem;
  text-align: center;
  box-shadow: var(--shadow-card);
  max-width: 720px;
  margin: 0 auto;
}

.reviews-cta-badge {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  background: var(--brand-light);
  color: #14532D;
  font-size: 0.8rem;
  font-weight: 600;
  padding: 5px 14px;
  border-radius: var(--radius-pill);
  margin-bottom: 1.2rem;
}

.reviews-cta-card h3 {
  font-size: 1.45rem;
  font-weight: 700;
  color: var(--text-main);
  margin-bottom: 0.8rem;
}

.reviews-cta-card p {
  font-size: 0.94rem;
  color: var(--text-secondary);
  line-height: 1.65;
  max-width: 580px;
  margin: 0 auto 1.8rem;
}

.reviews-empty-placeholder {
  text-align: center;
  font-size: 0.86rem;
  color: var(--text-muted);
  margin-top: 2rem;
  font-style: italic;
}
