/*
 * AstroBioRhythm - Enhanced Astrological/Virgoan Theme CSS
 */

:root {
  --font-headings: 'Cinzel', serif;
  --font-subheadings: 'Playfair Display', serif;
  --font-body: 'Lora', serif;
  --font-sans: 'Lora', sans-serif;
  
  --gold-primary: #bf953f;
  --gold-light: #fcf6ba;
  --gold-medium: #b38728;
  --gold-dark: #aa771c;
  --gold-gradient: linear-gradient(135deg, #bf953f 0%, #fcf6ba 25%, #b38728 50%, #fbf5b7 75%, #aa771c 100%);
  --gold-glow: 0 0 15px rgba(191, 149, 63, 0.4);
  
  --transition-smooth: all 0.35s cubic-bezier(0.25, 0.8, 0.25, 1);
  --transition-fast: all 0.15s ease-out;
  
  --font-size-base: 16px;
  --line-height-base: 1.6;
}

/* 1. THEME DEFINITIONS - Earth & Mercury Palette */

/* Theme 1: Analitička platina (Sleek Gray & Silver) */
body.theme-platinum {
  --color-bg: #0c0f16;
  --color-bg-sidebar: #131720;
  --color-bg-card: #1c212c;
  --color-bg-accent: #272d3b;
  --color-text-main: #f0f3f8;
  --color-text-muted: #8fa0b5;
  --color-border: rgba(191, 149, 63, 0.35);
  --color-border-hover: rgba(191, 149, 63, 0.65);
  --color-glow: rgba(191, 149, 63, 0.15);
  --color-scrollbar: #1b202c;
  --color-shadow: rgba(0, 0, 0, 0.6);
  background-color: var(--color-bg);
  color: var(--color-text-main);
  background-image: 
    radial-gradient(circle at 10% 20%, rgba(48, 54, 61, 0.25) 0%, transparent 60%),
    radial-gradient(circle at 90% 80%, rgba(22, 27, 34, 0.4) 0%, transparent 60%);
}

/* Theme 2: Micelijum i žad (Earthy Forest Green & Copper) */
body.theme-earth {
  --color-bg: #090c0a;
  --color-bg-sidebar: #111612;
  --color-bg-card: #19211b;
  --color-bg-accent: #232d25;
  --color-text-main: #edf5ee;
  --color-text-muted: #a3b8a7;
  --color-border: rgba(120, 144, 114, 0.4);
  --color-border-hover: rgba(120, 144, 114, 0.7);
  --color-glow: rgba(120, 144, 114, 0.2);
  --color-scrollbar: #131b15;
  --color-shadow: rgba(0, 0, 0, 0.65);
  background-color: var(--color-bg);
  color: var(--color-text-main);
  
  --gold-primary: #789072;
  --gold-light: #c2d3bd;
  --gold-medium: #4e6349;
  --gold-dark: #31442d;
  --gold-gradient: linear-gradient(135deg, #789072 0%, #c2d3bd 25%, #4e6349 50%, #c2d3bd 75%, #31442d 100%);
  --gold-glow: 0 0 15px rgba(120, 144, 114, 0.4);
  
  background-image: 
    radial-gradient(ellipse at top left, rgba(25, 33, 27, 0.6) 0%, transparent 60%),
    radial-gradient(ellipse at bottom right, rgba(17, 22, 18, 0.7) 0%, transparent 70%),
    radial-gradient(circle at 50% 50%, rgba(20, 27, 22, 0.85) 0%, #090c0a 100%);
}

/* Theme 3: Glinena posuda (Copper, Terracotta & Bronze) */
body.theme-clay {
  --color-bg: #100a08;
  --color-bg-sidebar: #19110d;
  --color-bg-card: #251a14;
  --color-bg-accent: #33241c;
  --color-text-main: #fcf6f2;
  --color-text-muted: #d8c3b9;
  --color-border: rgba(205, 127, 50, 0.35);
  --color-border-hover: rgba(205, 127, 50, 0.65);
  --color-glow: rgba(205, 127, 50, 0.2);
  --color-scrollbar: #1c130f;
  --color-shadow: rgba(0, 0, 0, 0.75);
  background-color: var(--color-bg);
  color: var(--color-text-main);
  
  --gold-primary: #cd7f32;
  --gold-light: #f0a967;
  --gold-medium: #a05a1e;
  --gold-dark: #7c3e0d;
  --gold-gradient: linear-gradient(135deg, #cd7f32 0%, #f0a967 25%, #a05a1e 50%, #f0a967 75%, #7c3e0d 100%);
  --gold-glow: 0 0 15px rgba(205, 127, 50, 0.4);

  background-image: 
    radial-gradient(ellipse at top left, rgba(51, 36, 28, 0.6) 0%, transparent 60%),
    radial-gradient(ellipse at bottom right, rgba(25, 17, 13, 0.7) 0%, transparent 70%),
    radial-gradient(circle at 50% 50%, rgba(37, 26, 20, 0.85) 0%, #100a08 100%);
}

/* Theme 4: Kozmički red (Deep Navy & Starry Amber) */
body.theme-celestial {
  --color-bg: #05070e;
  --color-bg-sidebar: #0b0d18;
  --color-bg-card: #121626;
  --color-bg-accent: #1b2038;
  --color-text-main: #f0f4ff;
  --color-text-muted: #9baac7;
  --color-border: rgba(191, 149, 63, 0.35);
  --color-border-hover: rgba(191, 149, 63, 0.65);
  --color-glow: rgba(191, 149, 63, 0.15);
  --color-scrollbar: #0b0e1a;
  --color-shadow: rgba(0, 0, 0, 0.7);
  background-color: var(--color-bg);
  color: var(--color-text-main);
  
  background-image: 
    radial-gradient(ellipse at top left, rgba(27, 32, 56, 0.6) 0%, transparent 60%),
    radial-gradient(ellipse at bottom right, rgba(11, 13, 24, 0.7) 0%, transparent 70%),
    radial-gradient(circle at 50% 50%, rgba(18, 22, 38, 0.85) 0%, #05070e 100%);
}

/* Theme 5: Stari rukopis (Light Parchment) */
body.theme-parchment {
  --color-bg: #f5eedc;
  --color-bg-sidebar: #eae0ca;
  --color-bg-card: #ffffff;
  --color-bg-accent: #dfd1b3;
  --color-text-main: #2a2016;
  --color-text-muted: #786b5c;
  --color-border: rgba(170, 119, 28, 0.35);
  --color-border-hover: rgba(170, 119, 28, 0.7);
  --color-glow: rgba(170, 119, 28, 0.1);
  --color-scrollbar: #ded2b8;
  --color-shadow: rgba(60, 48, 35, 0.15);
  background-color: var(--color-bg);
  color: var(--color-text-main);
  background-image: 
    linear-gradient(rgba(170, 119, 28, 0.02) 1px, transparent 1px),
    linear-gradient(90deg, rgba(170, 119, 28, 0.02) 1px, transparent 1px);
  background-size: 24px 24px;
}

body {
  font-family: var(--font-body);
  font-size: var(--font-size-base);
  line-height: var(--line-height-base);
  height: 100vh;
  overflow: hidden;
  margin: 0;
  padding: 0;
  background-color: var(--color-bg);
  color: var(--color-text-main);
  transition: background-color 0.4s ease, color 0.4s ease;

  /* Backward Compatibility Mapping */
  --primary-color: var(--color-bg);
  --secondary-color: var(--color-bg-sidebar);
  --accent-color: var(--color-bg-accent);
  --gold-accent: var(--gold-primary);
  --silver-accent: var(--color-text-muted);
  --cosmic-purple: var(--color-bg-accent);
  --nebula-blue: var(--color-border);
  --star-white: var(--color-text-main);
  --dark-space: var(--color-bg);
  --gradient-cosmic: linear-gradient(135deg, var(--color-bg) 0%, var(--color-bg-sidebar) 50%, var(--color-bg-accent) 100%);
  --gradient-nebula: var(--gold-gradient);
  --gradient-aurora: var(--gold-gradient);
}

/* Scrollbar Customization */
::-webkit-scrollbar {
  width: 8px;
  height: 8px;
}
::-webkit-scrollbar-track {
  background: transparent;
}
::-webkit-scrollbar-thumb {
  background: var(--color-scrollbar);
  border-radius: 4px;
  border: 1px solid var(--color-border);
}
::-webkit-scrollbar-thumb:hover {
  background: var(--gold-primary);
}

/* App Shell Components */
.app-container {
  display: flex;
  width: 100vw;
  height: 100vh;
  position: fixed !important;
  top: 0;
  left: 0;
  overflow: hidden;
}

/* Sidebar Styles */
.sidebar {
  width: 320px;
  height: 100%;
  background-color: var(--color-bg-sidebar);
  border-right: 1px solid var(--color-border);
  display: flex;
  flex-direction: column;
  z-index: 100;
  transition: transform 0.4s cubic-bezier(0.25, 0.8, 0.25, 1), background-color 0.4s ease, border-color 0.4s ease;
  box-shadow: 2px 0 15px var(--color-shadow);
  flex-shrink: 0;
}

.sidebar-header {
  padding: 24px 16px;
  display: flex;
  align-items: center;
  gap: 12px;
  border-bottom: 1px solid var(--color-border);
  position: relative;
}

.logo-link {
  display: flex;
  align-items: center;
  gap: 12px;
  text-decoration: none;
  color: inherit;
  transition: opacity 0.2s ease;
}

.logo-link:hover {
  text-decoration: none;
  opacity: 0.85;
}

.title-group h1 {
  font-family: var(--font-headings);
  font-size: 1.15rem;
  letter-spacing: 0.04em;
  line-height: 1.1;
  background: var(--gold-gradient);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  text-shadow: 0 2px 4px rgba(0,0,0,0.15);
  margin: 0;
}

.title-group .subtitle {
  font-size: 0.7rem;
  font-family: var(--font-headings);
  letter-spacing: 0.05em;
  color: var(--color-text-muted);
  text-transform: uppercase;
  margin: 4px 0 0 0;
}

.gold-svg {
  color: var(--gold-primary);
  filter: drop-shadow(0 2px 4px rgba(0,0,0,0.2));
}

.animate-rotate {
  transition: transform 0.8s ease-in-out;
}
.animate-rotate:hover {
  transform: rotate(180deg);
}

.mobile-close-btn {
  display: none;
  background: none;
  border: none;
  color: var(--color-text-main);
  cursor: pointer;
  padding: 4px;
}

/* Tabs */
.nav-tabs {
  display: flex;
  border-bottom: 1px solid var(--color-border);
  background-color: rgba(0, 0, 0, 0.1);
}

.tab-btn {
  flex: 1;
  background: none;
  border: none;
  border-bottom: 2px solid transparent;
  color: var(--color-text-muted);
  padding: 12px;
  font-family: var(--font-headings);
  font-size: 0.75rem;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  cursor: pointer;
  transition: var(--transition-fast);
}

.tab-btn:hover {
  color: var(--color-text-main);
}

.tab-btn.active {
  color: var(--gold-primary);
  border-bottom-color: var(--gold-primary);
  background-color: rgba(191, 149, 63, 0.05);
}

/* Sidebar Scroll Area */
.sidebar-scroll-area {
  flex: 1;
  overflow-y: auto;
  padding: 16px 8px;
}

.toc-list, .widgets-list {
  list-style: none;
  padding: 0;
  margin: 0;
}

.toc-list li {
  margin-bottom: 8px;
}

.toc-item {
  display: block;
  padding: 8px 12px;
  border-radius: 4px;
  color: var(--color-text-muted);
  font-family: var(--font-headings);
  font-size: 0.85rem;
  letter-spacing: 0.04em;
  cursor: pointer;
  transition: var(--transition-fast);
  text-decoration: none;
}

.toc-item:hover {
  background-color: rgba(191, 149, 63, 0.08);
  color: var(--color-text-main);
  padding-left: 16px;
  text-decoration: none;
}

.toc-item.active {
  background: var(--gold-gradient);
  color: #120d03 !important;
  font-weight: 600;
  box-shadow: 0 2px 8px rgba(0,0,0,0.15);
}

/* Widgets list menu (Zodiac Books list) */
.widget-menu-item {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 10px;
  border-radius: 6px;
  margin-bottom: 8px;
  border: 1px solid transparent;
  background-color: rgba(0,0,0,0.15);
  cursor: pointer;
  transition: var(--transition-smooth);
}

.widget-menu-item:hover {
  background-color: rgba(191,149,63,0.06);
  border-color: var(--color-border);
  transform: translateY(-2px);
}

.widget-menu-item .icon {
  font-size: 1.3rem;
  color: var(--gold-primary);
  text-shadow: 0 0 8px rgba(191,149,63,0.3);
}

.widget-desc {
  display: flex;
  flex-direction: column;
}

.widget-desc .title {
  font-family: var(--font-headings);
  font-size: 0.85rem;
  color: var(--color-text-main);
  font-weight: 600;
}

.widget-desc .detail {
  font-size: 0.65rem;
  color: var(--color-text-muted);
  font-family: var(--font-sans);
}

/* Sidebar Footer Settings */
.sidebar-footer {
  padding: 16px 20px;
  border-top: 1px solid var(--color-border);
  background-color: rgba(0,0,0,0.15);
}

.footer-action-btn {
  width: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  background: none;
  border: 1px solid var(--color-border);
  border-radius: 4px;
  color: var(--color-text-main);
  padding: 8px 12px;
  font-family: var(--font-headings);
  font-size: 0.75rem;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  cursor: pointer;
  transition: var(--transition-fast);
}

.footer-action-btn:hover {
  background-color: var(--gold-primary);
  color: #120d03;
  border-color: var(--gold-primary);
  box-shadow: var(--gold-glow);
}

/* Main Workspace Styles */
.main-workspace {
  flex: 1;
  height: 100%;
  display: flex;
  flex-direction: column;
  position: relative;
  overflow: hidden;
  background-color: var(--color-bg);
}

/* Top Action Bar */
.top-bar {
  height: 70px;
  border-bottom: 1px solid var(--color-border);
  padding: 0 32px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  background-color: rgba(0, 0, 0, 0.12);
  backdrop-filter: blur(8px);
  position: sticky !important;
  top: 0 !important;
  z-index: 1000 !important;
  flex-shrink: 0;
}

.top-bar-left {
  display: flex;
  align-items: center;
  gap: 16px;
}

.hamburger-btn {
  background: none;
  border: none;
  color: var(--color-text-main);
  cursor: pointer;
  padding: 4px;
  display: none;
}

.current-chapter-indicator {
  font-family: var(--font-headings);
  font-size: 0.95rem;
  letter-spacing: 0.05em;
  color: var(--gold-primary);
  font-weight: 600;
  text-transform: uppercase;
}

.top-bar-right {
  display: flex;
  align-items: center;
  gap: 20px;
}

.top-bar-select {
  background: rgba(0, 0, 0, 0.2);
  color: var(--color-text-main);
  border: 1px solid var(--color-border);
  border-radius: 4px;
  padding: 6px 12px;
  font-family: var(--font-sans);
  font-size: 0.85rem;
  outline: none;
  cursor: pointer;
}

.top-bar-select:focus {
  border-color: var(--gold-primary);
}

/* Viewport Content Area */
.viewport-content {
  flex: 1;
  overflow-y: auto;
  position: relative;
  padding: 48px 24px;
  display: flex;
  flex-direction: column;
  align-items: center;
  box-sizing: border-box;
}

/* Premium Royal Border Frames */
.royal-frame {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  pointer-events: none;
  z-index: 10;
}

.royal-frame::before {
  content: '';
  position: absolute;
  top: 8px;
  left: 8px;
  right: 8px;
  bottom: 8px;
  border: 2px solid var(--gold-primary);
  border-radius: 6px;
  opacity: 0.7;
}

.royal-frame::after {
  content: '';
  position: absolute;
  top: 16px;
  left: 16px;
  right: 16px;
  bottom: 16px;
  border: 1px solid rgba(191, 149, 63, 0.35);
  border-radius: 4px;
}

.frame-corner {
  position: absolute;
  width: 120px;
  height: 120px;
}

.frame-corner svg.corner {
  width: 100%;
  height: 100%;
  filter: drop-shadow(0 0 6px rgba(191, 149, 63, 0.3));
}

.frame-corner.top-left { top: 0; left: 0; }
.frame-corner.top-right { top: 0; right: 0; transform: scaleX(-1); }
.frame-corner.bottom-left { bottom: 0; left: 0; transform: scaleY(-1); }
.frame-corner.bottom-right { bottom: 0; right: 0; transform: scale(-1); }

.frame-edge {
  position: absolute;
}

.frame-edge.top {
  top: 4px;
  left: 120px;
  right: 120px;
  height: 60px;
  display: flex;
  justify-content: center;
  align-items: flex-start;
}

.frame-edge svg.top-arch {
  width: 400px;
  height: 60px;
  filter: drop-shadow(0 0 4px rgba(191, 149, 63, 0.25));
}

.frame-edge.bottom {
  bottom: 4px;
  left: 120px;
  right: 120px;
  height: 40px;
  display: flex;
  justify-content: center;
  align-items: flex-end;
}

.frame-edge svg.bottom-scroll {
  width: 300px;
  height: 40px;
  filter: drop-shadow(0 0 4px rgba(191, 149, 63, 0.25));
}

/* Premium Card (Book Card) Styles */
.book-card {
  position: relative;
  background-color: var(--color-bg-card) !important;
  border-radius: 12px !important;
  border: 1px solid var(--color-border) !important;
  box-shadow: 0 15px 45px var(--color-shadow) !important;
  padding: 80px 60px !important;
  max-width: 780px !important;
  width: 100% !important;
  margin: 32px auto !important;
  box-sizing: border-box !important;
  backdrop-filter: blur(15px);
}

.book-card::before {
  content: '';
  position: absolute;
  top: 20px;
  left: 20px;
  right: 20px;
  bottom: 20px;
  border: 1px dashed var(--color-border);
  border-radius: 8px;
  pointer-events: none;
}

.card-inner-wrapper {
  position: relative;
  z-index: 5;
  width: 100%;
}

.book-card h2 {
  font-family: var(--font-headings) !important;
  font-size: 2.2rem !important;
  color: var(--gold-primary) !important;
  text-shadow: 0 0 20px rgba(191, 149, 63, 0.4) !important;
  border-bottom: 1px solid var(--color-border);
  padding-bottom: 16px;
  margin-bottom: 20px;
  text-align: center;
}

/* Interactive elements overrides */
.form-group input,
.form-group select,
.date-input-wrapper input,
.time-input-wrapper input {
  background: var(--color-bg-sidebar) !important;
  border: 1px solid var(--color-border) !important;
  color: var(--color-text-main) !important;
  font-family: var(--font-sans) !important;
  font-size: 0.95rem !important;
  border-radius: 4px !important;
  padding: 10px 14px !important;
  box-sizing: border-box;
}

.form-group input:focus,
.form-group select:focus,
.date-input-wrapper input:focus,
.time-input-wrapper input:focus {
  border-color: var(--gold-primary) !important;
  box-shadow: var(--gold-glow) !important;
  background: var(--color-bg-card) !important;
  outline: none !important;
}

.form-row {
  display: flex;
  gap: 16px;
  width: 100%;
  margin-bottom: 16px;
}

.flex-1 {
  flex: 1;
}

.form-group label {
  color: var(--color-text-muted) !important;
  font-family: var(--font-headings) !important;
  font-size: 0.8rem !important;
  letter-spacing: 0.05em;
  text-transform: uppercase;
}

/* Settings Drawer Styles */
.settings-drawer-overlay {
  position: fixed;
  top: 0;
  left: 0;
  width: 100vw;
  height: 100vh;
  background-color: rgba(0, 0, 0, 0.5);
  backdrop-filter: blur(4px);
  z-index: 1000;
  display: flex;
  justify-content: flex-end;
  transition: opacity 0.3s ease;
}

.settings-drawer-content {
  width: 100%;
  max-width: 400px;
  height: 100%;
  background-color: var(--color-bg-sidebar);
  border-left: 1px solid var(--color-border);
  box-shadow: -5px 0 25px rgba(0,0,0,0.5);
  display: flex;
  flex-direction: column;
  animation: slideLeft 0.4s cubic-bezier(0.25, 0.8, 0.25, 1);
  transition: background-color 0.4s ease, border-color 0.4s ease;
}

@keyframes slideLeft {
  from { transform: translateX(100%); }
  to { transform: translateX(0); }
}

.drawer-header {
  padding: 24px;
  border-bottom: 1px solid var(--color-border);
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.drawer-header h3 {
  font-family: var(--font-headings);
  font-size: 1.15rem;
  color: var(--gold-primary);
  margin: 0;
  letter-spacing: 0.05em;
  text-transform: uppercase;
}

.close-drawer-btn {
  background: none;
  border: none;
  color: var(--color-text-muted);
  cursor: pointer;
  padding: 4px;
  display: flex;
  align-items: center;
  transition: var(--transition-fast);
}

.close-drawer-btn:hover {
  color: var(--color-text-main);
}

.drawer-body {
  flex: 1;
  overflow-y: auto;
  padding: 24px;
}

.settings-group {
  margin-bottom: 32px;
}

.settings-group h4 {
  font-family: var(--font-headings);
  font-size: 0.85rem;
  color: var(--color-text-muted);
  text-transform: uppercase;
  letter-spacing: 0.05em;
  margin-bottom: 16px;
  border-bottom: 1px solid rgba(191, 149, 63, 0.15);
  padding-bottom: 6px;
}

.theme-selector-grid {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.theme-option {
  display: flex;
  align-items: center;
  gap: 12px;
  background-color: rgba(0, 0, 0, 0.15);
  border: 1px solid var(--color-border);
  border-radius: 6px;
  padding: 10px 14px;
  width: 100%;
  cursor: pointer;
  transition: var(--transition-smooth);
  color: var(--color-text-main);
}

.theme-option:hover {
  background-color: rgba(191, 149, 63, 0.06);
  border-color: var(--gold-primary);
}

.theme-option.active {
  border-color: var(--gold-primary);
  background-color: rgba(191, 149, 63, 0.1);
  box-shadow: var(--gold-glow);
}

.theme-option .color-dot {
  width: 16px;
  height: 16px;
  border-radius: 50%;
  flex-shrink: 0;
}

.theme-option .theme-name {
  font-family: var(--font-headings);
  font-size: 0.8rem;
  letter-spacing: 0.05em;
  text-align: left;
}

.font-size-adjuster {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 20px;
  background-color: rgba(0, 0, 0, 0.15);
  border: 1px solid var(--color-border);
  border-radius: 6px;
  padding: 12px;
}

.size-btn {
  background: none;
  border: 1px solid var(--color-border);
  border-radius: 4px;
  color: var(--color-text-main);
  width: 36px;
  height: 36px;
  font-size: 1rem;
  font-family: var(--font-headings);
  cursor: pointer;
  transition: var(--transition-fast);
}

.size-btn:hover {
  border-color: var(--gold-primary);
  color: var(--gold-primary);
}

.size-display {
  font-family: var(--font-headings);
  font-size: 1rem;
  color: var(--gold-primary);
  min-width: 60px;
  text-align: center;
}

/* Custom pickers matching theme */
.custom-date-picker, .custom-time-picker {
  background: var(--color-bg-sidebar) !important;
  border: 1px solid var(--color-border) !important;
  box-shadow: 0 10px 25px var(--color-shadow) !important;
}

.date-picker-header, .time-picker-header {
  border-bottom: 1px solid var(--color-border) !important;
}

.month-year-display, .time-picker-header h4 {
  font-family: var(--font-headings) !important;
  color: var(--gold-primary) !important;
}

.weekday {
  color: var(--color-text-muted) !important;
  font-family: var(--font-headings) !important;
  font-size: 0.75rem !important;
}

.calendar-day {
  color: var(--color-text-main) !important;
}

.calendar-day:hover {
  background-color: rgba(191, 149, 63, 0.1) !important;
  color: var(--gold-primary) !important;
}

.calendar-day.selected {
  background: var(--gold-gradient) !important;
  color: #120d03 !important;
}

.date-picker-btn, .time-picker-btn {
  background: none !important;
  border: 1px solid var(--color-border) !important;
  color: var(--color-text-main) !important;
  font-family: var(--font-headings) !important;
}

.date-picker-btn:hover, .time-picker-btn:hover {
  border-color: var(--gold-primary) !important;
  color: var(--gold-primary) !important;
}

.date-picker-btn.primary, .time-picker-btn.primary {
  background: var(--gold-gradient) !important;
  color: #120d03 !important;
  border: none !important;
}

.year-slider {
  accent-color: var(--gold-primary) !important;
}

.year-slider-label {
  font-family: var(--font-headings) !important;
  color: var(--color-text-muted) !important;
}

.clock-face {
  border: 2px solid var(--color-border) !important;
}

.clock-center {
  background: var(--gold-primary) !important;
}

.hour-hand {
  background: var(--gold-primary) !important;
}

.minute-hand {
  background: var(--color-text-muted) !important;
}

.hour-marker {
  color: var(--color-text-muted) !important;
  font-family: var(--font-headings) !important;
}

.hour-marker.active {
  color: var(--gold-primary) !important;
  font-weight: 700 !important;
}

.time-number-input, #ampmSelect {
  background: var(--color-bg-card) !important;
  border: 1px solid var(--color-border) !important;
  color: var(--color-text-main) !important;
}

.time-number-input:focus, #ampmSelect:focus {
  border-color: var(--gold-primary) !important;
}

/* Cards & Grid Styling */
.astro-card, .horoscope-card, .bio-card, .characteristic-card {
  background: var(--color-bg-sidebar) !important;
  border: 1px solid var(--color-border) !important;
  border-radius: 8px !important;
  transition: var(--transition-smooth) !important;
  padding: 20px !important;
  box-shadow: 0 4px 15px rgba(0,0,0,0.2) !important;
}

.astro-card:hover, .horoscope-card:hover, .bio-card:hover, .characteristic-card:hover {
  border-color: var(--gold-primary) !important;
  transform: translateY(-4px) !important;
  box-shadow: var(--gold-glow) !important;
}

.astro-card h4, .horoscope-card h4, .bio-card h4, .characteristic-card h4 {
  font-family: var(--font-headings) !important;
  color: var(--gold-primary) !important;
}

.profile-title {
  background: linear-gradient(135deg, var(--color-bg-sidebar) 0%, var(--color-bg-accent) 100%) !important;
  border: 1px solid var(--color-border) !important;
}

.profile-header h3 {
  font-family: var(--font-headings) !important;
}

.zodiac-image {
  border-color: var(--gold-primary) !important;
  box-shadow: var(--gold-glow) !important;
}

/* Biorhythm Graph & Charts */
.chart-container {
  background: rgba(0, 0, 0, 0.15) !important;
  border: 1px solid var(--color-border) !important;
  border-radius: 6px !important;
  padding: 16px;
}

/* Footer elements */
footer {
  border-top: 1px dashed var(--color-border) !important;
  padding-top: 32px !important;
  margin-top: 64px !important;
  width: 100%;
}

footer h3, footer h4 {
  font-family: var(--font-headings) !important;
  color: var(--gold-primary) !important;
}

footer p, footer li {
  color: var(--color-text-muted) !important;
}


.language-selector select:hover {
  background: rgba(106, 13, 173, 0.9);
  box-shadow: 0 0 20px rgba(255, 215, 0, 0.4);
  transform: scale(1.05);
}

.language-selector select:focus {
  outline: none;
  box-shadow: 0 0 20px rgba(255, 215, 0, 0.6);
}

/* Enhanced Form Section */
.form-section {
  padding: 0;
  background: none;
  border: none;
  box-shadow: none;
  backdrop-filter: none;
  position: relative;
  overflow: visible;
}

.form-section::before {
  display: none;
}

.form-section h2 {
  font-family: var(--font-headings);
  font-size: 2.2rem;
  color: var(--gold-primary);
  margin-bottom: 1.5rem;
  text-align: center;
  text-shadow: var(--gold-glow);
}

.form-description {
  text-align: center;
  color: var(--color-text-muted);
  font-size: 1rem;
  line-height: 1.6;
  margin-bottom: 2rem;
  max-width: 600px;
  margin-left: auto;
  margin-right: auto;
  opacity: 0.9;
}

.form-group {
  margin-bottom: 1.5rem;
  position: relative;
}

.form-group label {
  display: block;
  margin-bottom: 0.5rem;
  color: var(--color-text-muted);
  font-weight: 500;
  font-size: 0.95rem;
}

.form-group input,
.form-group select {
  width: 100%;
  padding: 12px 15px;
  background: var(--color-bg-sidebar);
  border: 1px solid var(--color-border);
  border-radius: 4px;
  color: var(--color-text-main);
  font-size: 1rem;
  transition: var(--transition-smooth);
  position: relative;
}

.form-group input:focus,
.form-group select:focus {
  outline: none;
  border-color: var(--gold-primary);
  background: var(--color-bg-card);
  box-shadow: var(--gold-glow);
  transform: translateY(-2px);
}

.form-group input::placeholder {
  color: var(--color-text-muted);
  opacity: 0.6;
}

/* Autocomplete Suggestions Dropdown */
.input-container {
  position: relative;
}

.suggestions-dropdown {
  position: absolute;
  top: 100%;
  left: 0;
  right: 0;
  background: var(--color-bg-sidebar);
  border: 1px solid var(--color-border);
  border-radius: 0 0 6px 6px;
  border-top: none;
  backdrop-filter: blur(15px);
  z-index: 1000;
  max-height: 200px;
  overflow-y: auto;
  box-shadow: 0 5px 25px rgba(0, 0, 0, 0.5);
  display: none;
}

.suggestion-item {
  padding: 12px 15px;
  cursor: pointer;
  transition: all 0.2s ease;
  border-bottom: 1px solid var(--color-border);
  color: var(--color-text-main);
  font-size: 0.95rem;
}

.suggestion-item:hover,
.suggestion-item.highlighted {
  background: rgba(191, 149, 63, 0.1);
  color: var(--gold-primary);
  transform: translateX(5px);
  border-left: 3px solid var(--gold-primary);
}

.suggestion-item:last-child {
  border-bottom: none;
  border-radius: 0 0 6px 6px;
}

/* Custom scrollbar for suggestions */
.suggestions-dropdown::-webkit-scrollbar {
  width: 6px;
}

.suggestions-dropdown::-webkit-scrollbar-track {
  background: transparent;
}

.suggestions-dropdown::-webkit-scrollbar-thumb {
  background: var(--color-scrollbar);
  border-radius: 3px;
}

.suggestions-dropdown::-webkit-scrollbar-thumb:hover {
  background: var(--gold-primary);
}

/* Enhanced Submit Button with Cosmic Spinner */
.submit-btn {
  width: 100%;
  padding: 15px;
  background: var(--gold-gradient);
  color: #120d03 !important;
  border: none;
  border-radius: 4px;
  font-size: 1.1rem;
  font-weight: 700;
  cursor: pointer;
  transition: var(--transition-smooth);
  position: relative;
  overflow: hidden;
  text-transform: uppercase;
  letter-spacing: 1px;
  box-shadow: 0 4px 15px rgba(170,119,28,0.3);
  display: flex;
  align-items: center;
  justify-content: center;
  min-height: 50px;
}

.submit-btn::before {
  content: "";
  position: absolute;
  top: 0;
  left: -100%;
  width: 100%;
  height: 100%;
  background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.2), transparent);
  transition: left 0.5s;
}

.submit-btn:hover {
  transform: translateY(-3px);
  box-shadow: var(--gold-glow);
}

.submit-btn:hover::before {
  left: 100%;
}

.submit-btn:active {
  transform: translateY(-1px);
}

.cosmic-spinner {
  position: relative;
  width: 30px;
  height: 30px;
}

.spinner-ring {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  border: 2px solid transparent;
  border-top: 2px solid var(--gold-primary);
  border-radius: 50%;
  animation: cosmicSpin 1s linear infinite;
}

.spinner-ring:nth-child(2) {
  width: 80%;
  height: 80%;
  top: 10%;
  left: 10%;
  border-top-color: var(--color-text-muted);
  animation-delay: -0.3s;
  animation-duration: 1.5s;
}

.spinner-ring:nth-child(3) {
  width: 60%;
  height: 60%;
  top: 20%;
  left: 20%;
  border-top-color: var(--gold-light);
  animation-delay: -0.6s;
  animation-duration: 2s;
}

@keyframes cosmicSpin {
  0% { transform: rotate(0deg); }
  100% { transform: rotate(360deg); }
}

/* Enhanced Results Section */
.results-section {
  padding: 0;
  background: none;
  border: none;
  box-shadow: none;
  backdrop-filter: none;
  animation: fadeInUp 0.8s ease-out;
}

@keyframes fadeInUp {
  from {
    opacity: 0;
    transform: translateY(30px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.results-section h2 {
  font-family: var(--font-headings);
  font-size: 2.2rem;
  color: var(--gold-primary);
  text-align: center;
  margin-bottom: 2rem;
  text-shadow: var(--gold-glow);
}

/* Enhanced Profile Summary */
.profile-summary {
  margin-bottom: 2rem;
}

.profile-title {
  display: flex;
  align-items: center;
  justify-content: space-between;
  background: linear-gradient(135deg, var(--color-bg-sidebar) 0%, var(--color-bg-accent) 100%);
  padding: 1.5rem;
  border-radius: 8px;
  border: 1px solid var(--color-border);
  margin-bottom: 1.5rem;
  box-shadow: 0 10px 25px rgba(0, 0, 0, 0.3);
  position: relative;
  overflow: hidden;
}

.profile-title::before {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 2px;
  background: var(--gold-gradient);
  animation: pulse 2s ease-in-out infinite;
}

@keyframes pulse {
  0%, 100% { opacity: 0.5; }
  50% { opacity: 1; }
}

.profile-header h3 {
  font-family: var(--font-headings);
  font-size: 1.8rem;
  color: var(--color-text-main);
  margin-bottom: 0.5rem;
  text-shadow: 0 2px 4px rgba(0,0,0,0.15);
}

.profile-header p {
  color: var(--color-text-muted);
  font-size: 1rem;
}

.zodiac-image {
  width: 80px;
  height: 80px;
  border-radius: 50%;
  border: 2px solid var(--gold-primary);
  box-shadow: var(--gold-glow);
  animation: zodiacGlow 3s ease-in-out infinite;
}

@keyframes zodiacGlow {
  0%, 100% { box-shadow: var(--gold-glow); }
  50% { box-shadow: 0 0 25px rgba(191, 149, 63, 0.75); }
}

/* Enhanced Astro Grid with Constellation Effects */
.astro-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  gap: 1.5rem;
  margin-bottom: 2rem;
}

.astro-card {
  background: var(--color-bg-sidebar);
  padding: 1.5rem;
  border-radius: 8px;
  border: 1px solid var(--color-border);
  transition: var(--transition-smooth);
  position: relative;
  overflow: hidden;
}

.astro-card::before {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 1px;
  background: var(--gold-gradient);
  transform: scaleX(0);
  transition: transform 0.3s ease;
}

.astro-card::after {
  content: "✦";
  position: absolute;
  top: 10px;
  right: 10px;
  font-size: 1.2rem;
  color: var(--gold-primary);
  opacity: 0;
  transform: rotate(0deg) scale(0);
  transition: all 0.3s ease;
}

.astro-card:hover {
  transform: translateY(-5px);
  box-shadow: 
    0 15px 30px rgba(0, 0, 0, 0.3),
    0 0 25px rgba(255, 215, 0, 0.2);
  border-color: var(--gold-accent);
}

.astro-card:hover::before {
  transform: scaleX(1);
}

.astro-card:hover::after {
  opacity: 1;
  transform: rotate(360deg) scale(1);
}

/* Zodiac Sign Specific Colors */
.astro-card.sun-sign {
  border-left: 4px solid #ff6b35;
}

.astro-card.moon-sign {
  border-left: 4px solid #74b9ff;
}

.astro-card.rising-sign {
  border-left: 4px solid #a29bfe;
}

.astro-card h4 {
  font-size: 1.3rem;
  color: var(--gold-accent);
  margin-bottom: 1rem;
  text-align: center;
  text-shadow: 0 0 15px rgba(255, 215, 0, 0.5);
}

.sign-info {
  font-size: 1.5rem;
  text-align: center;
  margin-bottom: 1rem;
  color: var(--star-white);
  font-weight: 600;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
}

.zodiac-symbol {
  font-size: 2rem;
  color: var(--gold-accent);
  text-shadow: 0 0 15px rgba(255, 215, 0, 0.8);
  animation: symbolGlow 3s ease-in-out infinite;
}

@keyframes symbolGlow {
  0%, 100% { 
    transform: scale(1);
    text-shadow: 0 0 15px rgba(255, 215, 0, 0.8);
  }
  50% { 
    transform: scale(1.1);
    text-shadow: 0 0 25px rgba(255, 215, 0, 1);
  }
}

.zodiac-story {
  color: var(--silver-accent);
  line-height: 1.6;
  font-size: 0.95rem;
}

/* Enhanced Daily Horoscope */
.daily-horoscope {
  margin-bottom: 2rem;
}

.daily-horoscope h3 {
  font-family: "Playfair Display", serif;
  font-size: 2rem;
  color: var(--gold-accent);
  text-align: center;
  margin-bottom: 1.5rem;
  text-shadow: 0 0 20px rgba(255, 215, 0, 0.5);
}

.horoscope-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
  gap: 1.5rem;
}

.horoscope-card {
  background: var(--gradient-nebula);
  padding: 1.5rem;
  border-radius: 15px;
  text-align: center;
  box-shadow: 0 10px 25px rgba(0, 0, 0, 0.3);
  transition: all 0.3s ease;
  position: relative;
  overflow: hidden;
}

.horoscope-card::after {
  content: "";
  position: absolute;
  top: 50%;
  left: 50%;
  width: 0;
  height: 0;
  background: radial-gradient(circle, rgba(255, 255, 255, 0.1) 0%, transparent 70%);
  transition: all 0.3s ease;
  transform: translate(-50%, -50%);
  border-radius: 50%;
}

.horoscope-card:hover {
  transform: translateY(-5px) scale(1.02);
  box-shadow: 
    0 20px 40px rgba(0, 0, 0, 0.4),
    0 0 30px rgba(255, 215, 0, 0.3);
}

.horoscope-card:hover::after {
  width: 100%;
  height: 100%;
}

.horoscope-card h4 {
  font-size: 1.2rem;
  margin-bottom: 1rem;
  color: var(--star-white);
  text-shadow: 0 0 10px rgba(255, 255, 255, 0.5);
}

.horoscope-card p {
  color: var(--silver-accent);
  line-height: 1.5;
}

/* Enhanced Biorhythm Section */
.biorhythm-section {
  margin-bottom: 2rem;
}

.biorhythm-section h3 {
  font-family: "Playfair Display", serif;
  font-size: 2rem;
  color: var(--gold-accent);
  text-align: center;
  margin-bottom: 1.5rem;
  text-shadow: 0 0 20px rgba(255, 215, 0, 0.5);
}

.bio-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
  gap: 1.5rem;
  margin-bottom: 2rem;
}

.bio-card {
  background: rgba(45, 27, 105, 0.7);
  padding: 1.5rem;
  border-radius: 15px;
  text-align: center;
  backdrop-filter: blur(10px);
  border: 1px solid rgba(255, 215, 0, 0.2);
  transition: all 0.3s ease;
  position: relative;
  overflow: hidden;
}

.bio-card::before {
  content: "";
  position: absolute;
  top: -50%;
  left: -50%;
  width: 200%;
  height: 200%;
  background: conic-gradient(from 0deg, transparent, rgba(255, 215, 0, 0.05), transparent);
  animation: rotateGlow 8s linear infinite;
  z-index: 0;
}

@keyframes rotateGlow {
  0% { transform: rotate(0deg); }
  100% { transform: rotate(360deg); }
}

.bio-card:hover {
  transform: translateY(-5px);
  box-shadow: 
    0 15px 30px rgba(0, 0, 0, 0.3),
    0 0 25px rgba(255, 215, 0, 0.2);
  border-color: var(--gold-accent);
}

.bio-card h4 {
  font-size: 1.2rem;
  color: var(--gold-accent);
  margin-bottom: 1rem;
  position: relative;
  z-index: 1;
  text-shadow: 0 0 15px rgba(255, 215, 0, 0.5);
}

.bio-meter {
  background: rgba(0, 0, 0, 0.3);
  border-radius: 20px;
  height: 20px;
  margin-bottom: 1rem;
  overflow: hidden;
  position: relative;
  z-index: 1;
  box-shadow: inset 0 2px 5px rgba(0, 0, 0, 0.3);
}

.bio-bar {
  height: 100%;
  border-radius: 20px;
  transition: all 0.8s ease;
  position: relative;
  overflow: hidden;
  background: linear-gradient(90deg, 
    var(--cosmic-purple) 0%, 
    var(--nebula-blue) 50%, 
    var(--gold-accent) 100%);
}

.bio-card.physical .bio-bar {
  background: linear-gradient(90deg, 
    #ff4757 0%, 
    #ff6b6b 50%, 
    #ff9f43 100%);
}

.bio-card.emotional .bio-bar {
  background: linear-gradient(90deg, 
    #7bed9f 0%, 
    #70a1ff 50%, 
    #a4b0be 100%);
}

.bio-card.intellectual .bio-bar {
  background: linear-gradient(90deg, 
    #5f27cd 0%, 
    #00d2d3 50%, 
    #ff9ff3 100%);
}

.bio-bar::after {
  content: "";
  position: absolute;
  top: 0;
  left: -100%;
  width: 100%;
  height: 100%;
  background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.3), transparent);
  animation: shimmer 2s ease-in-out infinite;
}

/* Magical Particles Effect */
.bio-card::after {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background-image: 
    radial-gradient(circle at 20% 30%, rgba(255, 215, 0, 0.3) 2px, transparent 2px),
    radial-gradient(circle at 80% 70%, rgba(106, 13, 173, 0.3) 1px, transparent 1px),
    radial-gradient(circle at 50% 50%, rgba(65, 105, 225, 0.3) 1.5px, transparent 1.5px);
  background-size: 50px 50px, 30px 30px, 40px 40px;
  animation: particleFloat 15s ease-in-out infinite;
  opacity: 0;
  transition: opacity 0.3s ease;
  pointer-events: none;
  z-index: 2;
}

.bio-card:hover::after {
  opacity: 1;
}

@keyframes particleFloat {
  0%, 100% { transform: translateY(0px) rotate(0deg); }
  33% { transform: translateY(-10px) rotate(120deg); }
  66% { transform: translateY(5px) rotate(240deg); }
}

@keyframes shimmer {
  0% { left: -100%; }
  100% { left: 100%; }
}

.bio-card p {
  color: var(--silver-accent);
  font-size: 0.9rem;
  position: relative;
  z-index: 1;
}

/* Enhanced Biorhythm Story */
.biorhythm-story {
  background: rgba(106, 13, 173, 0.2);
  padding: 2rem;
  border-radius: 15px;
  margin-bottom: 2rem;
  backdrop-filter: blur(10px);
  border: 1px solid rgba(255, 215, 0, 0.2);
  position: relative;
  overflow: hidden;
}

.biorhythm-story::before {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 100%;
  background: 
    radial-gradient(circle at 20% 20%, rgba(255, 215, 0, 0.1) 0%, transparent 50%),
    radial-gradient(circle at 80% 80%, rgba(106, 13, 173, 0.1) 0%, transparent 50%);
  z-index: 0;
}

.biorhythm-story h3 {
  font-family: "Playfair Display", serif;
  font-size: 1.8rem;
  color: var(--gold-accent);
  margin-bottom: 1.5rem;
  text-align: center;
  position: relative;
  z-index: 1;
  text-shadow: 0 0 20px rgba(255, 215, 0, 0.5);
}

.story-content {
  position: relative;
  z-index: 1;
}

.story-content p {
  color: var(--silver-accent);
  line-height: 1.7;
  margin-bottom: 1rem;
  font-size: 1rem;
}

.story-content strong {
  color: var(--gold-accent);
  text-shadow: 0 0 10px rgba(255, 215, 0, 0.3);
}

/* Enhanced Chart Containers */
.chart-container {
  background: rgba(0, 0, 0, 0.3);
  border-radius: 15px;
  padding: 1.5rem;
  margin-bottom: 1rem;
  backdrop-filter: blur(10px);
  border: 1px solid rgba(255, 215, 0, 0.1);
  position: relative;
  overflow: hidden;
}

.chart-container::before {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: 
    radial-gradient(circle at 50% 50%, rgba(255, 215, 0, 0.05) 0%, transparent 70%);
  z-index: 0;
}

.chart-container canvas {
  position: relative;
  z-index: 1;
  filter: drop-shadow(0 5px 15px rgba(0, 0, 0, 0.3));
}

/* Enhanced Natal Chart */
.natal-chart {
  margin-bottom: 2rem;
}

.natal-chart h3 {
  font-family: "Playfair Display", serif;
  font-size: 2rem;
  color: var(--gold-accent);
  text-align: center;
  margin-bottom: 1.5rem;
  text-shadow: 0 0 20px rgba(255, 215, 0, 0.5);
}

.aspects-list {
  background: rgba(45, 27, 105, 0.4);
  padding: 1.5rem;
  border-radius: 15px;
  margin-top: 1rem;
  backdrop-filter: blur(10px);
  border: 1px solid rgba(255, 215, 0, 0.1);
}

/* Enhanced Footer */
footer {
  background: var(--gradient-cosmic);
  border-radius: 20px;
  margin-top: 2rem;
  position: relative;
  overflow: hidden;
  box-shadow: 0 -10px 25px rgba(0, 0, 0, 0.3);
  padding: 2rem 0 1rem 0;
}

footer::before {
  content: "";
  position: absolute;
  top: 0;
  left: -100%;
  width: 100%;
  height: 2px;
  background: var(--gradient-aurora);
  animation: footerScan 4s ease-in-out infinite;
}

@keyframes footerScan {
  0%, 50% { left: -100%; }
  100% { left: 100%; }
}

.footer-content {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
  gap: 2rem;
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 2rem;
  position: relative;
  z-index: 1;
}

.footer-section h3 {
  color: var(--gold-accent);
  font-size: 1.3rem;
  margin-bottom: 1rem;
  text-shadow: 0 0 10px rgba(255, 215, 0, 0.5);
}

.footer-section h4 {
  color: var(--silver-accent);
  font-size: 1.1rem;
  margin-bottom: 0.8rem;
}

.footer-section p {
  color: var(--star-white);
  font-size: 0.9rem;
  line-height: 1.6;
  opacity: 0.9;
}

.footer-section ul {
  list-style: none;
  padding: 0;
}

.footer-section ul li {
  color: var(--star-white);
  font-size: 0.85rem;
  padding: 0.3rem 0;
  opacity: 0.8;
  transition: opacity 0.2s ease;
}

.footer-section ul li:hover {
  opacity: 1;
  color: var(--gold-accent);
}

.footer-bottom {
  text-align: center;
  padding-top: 1.5rem;
  margin-top: 1.5rem;
  border-top: 1px solid rgba(192, 192, 192, 0.2);
  position: relative;
  z-index: 1;
}

.footer-bottom p {
  color: var(--silver-accent);
  font-size: 0.85rem;
  margin: 0.5rem 0;
}

.footer-disclaimer {
  font-size: 0.75rem !important;
  opacity: 0.7;
  max-width: 600px;
  margin: 0 auto;
}

@media (max-width: 768px) {
  .footer-content {
    grid-template-columns: 1fr;
    text-align: center;
    gap: 1.5rem;
  }
}

/* Enhanced Zodiac Characteristics */
.zodiac-characteristics h3 {
  font-family: "Playfair Display", serif;
  font-size: 2rem;
  color: var(--gold-accent);
  text-align: center;
  margin-bottom: 1.5rem;
  text-shadow: 0 0 20px rgba(255, 215, 0, 0.5);
}

.characteristics-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  gap: 1.5rem;
}

.characteristic-card {
  background: var(--gradient-nebula);
  padding: 2rem;
  border-radius: 15px;
  text-align: center;
  box-shadow: 0 10px 25px rgba(0, 0, 0, 0.3);
  transition: all 0.3s ease;
  position: relative;
  overflow: hidden;
}

.characteristic-card::before {
  content: "";
  position: absolute;
  top: -2px;
  left: -2px;
  right: -2px;
  bottom: -2px;
  background: var(--gradient-aurora);
  border-radius: 15px;
  z-index: -1;
  opacity: 0;
  transition: opacity 0.3s ease;
}

.characteristic-card:hover {
  transform: translateY(-8px) scale(1.02);
  box-shadow: 
    0 20px 40px rgba(0, 0, 0, 0.4),
    0 0 30px rgba(255, 215, 0, 0.3);
}

.characteristic-card:hover::before {
  opacity: 1;
}

.characteristic-card h4 {
  font-size: 1.3rem;
  color: var(--star-white);
  margin-bottom: 1rem;
  text-shadow: 0 0 15px rgba(255, 255, 255, 0.5);
}

.characteristic-card p {
  color: var(--silver-accent);
  line-height: 1.6;
}

/* Responsive Design */
@media (max-width: 768px) {
  .container {
    padding: 15px;
  }
  
  header h1 {
    font-size: 2.5rem;
  }
  
  .language-selector {
    position: static !important;
    top: 15px;
    right: 15px;
    z-index: 1000;
  }
  
  .language-selector select {
    padding: 6px 12px;
    font-size: 0.85rem;
    min-width: 100px;
    border-radius: 20px;
    touch-action: manipulation;
    -webkit-tap-highlight-color: transparent;
  }
  
  .profile-title {
    flex-direction: column;
    text-align: center;
    gap: 1rem;
  }
  .astro-grid,
  .horoscope-grid,
  .bio-grid,
  .characteristics-grid {
    grid-template-columns: 1fr;
  }
  
  .form-section,
  .results-section {
    padding: 1.5rem;
  }
}

footer {
  position: relative;
  background-color: #0c0f16;
  border-top: 1px solid var(--color-border);
  padding: 60px 0 20px 0;
  overflow: hidden;
  margin-top: auto;
  transition: background-color 0.4s ease, border-color 0.4s ease;
}

footer::before {
  content: "";
  position: absolute;
  top: 0;
  left: -100%;
  width: 100%;
  height: 2px;
  background: var(--gradient-aurora);
  animation: footerScan 4s ease-in-out infinite;
}

@keyframes footerScan {
  0%, 50% { left: -100%; }
  100% { left: 100%; }
}

.footer-content {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
  gap: 2rem;
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 2rem;
  position: relative;
  z-index: 1;
}

.footer-section h3 {
  color: var(--gold-accent);
  font-size: 1.3rem;
  margin-bottom: 1rem;
  text-shadow: 0 0 10px rgba(255, 215, 0, 0.5);
}

.footer-section h4 {
  color: var(--silver-accent);
  font-size: 1.1rem;
  margin-bottom: 0.8rem;
}

.footer-section p {
  color: var(--star-white);
  font-size: 0.9rem;
  line-height: 1.6;
  opacity: 0.9;
}

.footer-section ul {
  list-style: none;
  padding: 0;
}

.footer-section ul li {
  color: var(--star-white);
  font-size: 0.85rem;
  padding: 0.3rem 0;
  opacity: 0.8;
  transition: opacity 0.2s ease;
}

.footer-section ul li:hover {
  opacity: 1;
  color: var(--gold-accent);
}

.footer-bottom {
  text-align: center;
  padding-top: 1.5rem;
  margin-top: 1.5rem;
  border-top: 1px solid rgba(192, 192, 192, 0.2);
  position: relative;
  z-index: 1;
}

.footer-bottom p {
  color: var(--silver-accent);
  font-size: 0.85rem;
  margin: 0.5rem 0;
}

.footer-disclaimer {
  font-size: 0.75rem !important;
  opacity: 0.7;
  max-width: 600px;
  margin: 0 auto;
}

@media (max-width: 768px) {
  .footer-content {
    grid-template-columns: 1fr;
    text-align: center;
    gap: 1.5rem;
  }
}

/* Enhanced Zodiac Characteristics */
.zodiac-characteristics h3 {
  font-family: "Playfair Display", serif;
  font-size: 2rem;
  color: var(--gold-accent);
  text-align: center;
  margin-bottom: 1.5rem;
  text-shadow: 0 0 20px rgba(255, 215, 0, 0.5);
}

.characteristics-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  gap: 1.5rem;
}

.characteristic-card {
  background: var(--gradient-nebula);
  padding: 2rem;
  border-radius: 15px;
  text-align: center;
  box-shadow: 0 10px 25px rgba(0, 0, 0, 0.3);
  transition: all 0.3s ease;
  position: relative;
  overflow: hidden;
}

.characteristic-card::before {
  content: "";
  position: absolute;
  top: -2px;
  left: -2px;
  right: -2px;
  bottom: -2px;
  background: var(--gradient-aurora);
  border-radius: 15px;
  z-index: -1;
  opacity: 0;
  transition: opacity 0.3s ease;
}

.characteristic-card:hover {
  transform: translateY(-8px) scale(1.02);
  box-shadow: 
    0 20px 40px rgba(0, 0, 0, 0.4),
    0 0 30px rgba(255, 215, 0, 0.3);
}

.characteristic-card:hover::before {
  opacity: 1;
}

.characteristic-card h4 {
  font-size: 1.3rem;
  color: var(--star-white);
  margin-bottom: 1rem;
  text-shadow: 0 0 15px rgba(255, 255, 255, 0.5);
}

.characteristic-card p {
  color: var(--silver-accent);
  line-height: 1.6;
}

/* Responsive Design */
@media (max-width: 768px) {
  margin-bottom: 1rem;
  text-shadow: 0 0 10px rgba(255, 215, 0, 0.5);
}

.footer-section h4 {
  color: var(--silver-accent);
  font-size: 1.1rem;
  margin-bottom: 0.8rem;
}

.footer-section p {
  color: var(--star-white);
  font-size: 0.9rem;
  line-height: 1.6;
  opacity: 0.9;
}

.footer-section ul {
  list-style: none;
  padding: 0;
}

.footer-section ul li {
  color: var(--star-white);
  font-size: 0.85rem;
  padding: 0.3rem 0;
  opacity: 0.8;
  transition: opacity 0.2s ease;
}

.footer-section ul li:hover {
  opacity: 1;
  color: var(--gold-accent);
}

.footer-bottom {
  text-align: center;
  padding-top: 1.5rem;
  margin-top: 1.5rem;
  border-top: 1px solid rgba(192, 192, 192, 0.2);
  position: relative;
  z-index: 1;
}

.footer-bottom p {
  color: var(--silver-accent);
  font-size: 0.85rem;
  margin: 0.5rem 0;
}

.footer-disclaimer {
  font-size: 0.75rem !important;
  opacity: 0.7;
  max-width: 600px;
  margin: 0 auto;
}

@media (max-width: 768px) {
  .footer-content {
    grid-template-columns: 1fr;
    text-align: center;
    gap: 1.5rem;
  }
}

/* Enhanced Zodiac Characteristics */
.zodiac-characteristics h3 {
  font-family: "Playfair Display", serif;
  font-size: 2rem;
  color: var(--gold-accent);
  text-align: center;
  margin-bottom: 1.5rem;
  text-shadow: 0 0 20px rgba(255, 215, 0, 0.5);
}

.characteristics-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  gap: 1.5rem;
}

.characteristic-card {
  background: var(--gradient-nebula);
  padding: 2rem;
  border-radius: 15px;
  text-align: center;
  box-shadow: 0 10px 25px rgba(0, 0, 0, 0.3);
  transition: all 0.3s ease;
  position: relative;
  overflow: hidden;
}

.characteristic-card::before {
  content: "";
  position: absolute;
  top: -2px;
  left: -2px;
  right: -2px;
  bottom: -2px;
  background: var(--gradient-aurora);
  border-radius: 15px;
  z-index: -1;
  opacity: 0;
  transition: opacity 0.3s ease;
}

.characteristic-card:hover {
  transform: translateY(-8px) scale(1.02);
  box-shadow: 
    0 20px 40px rgba(0, 0, 0, 0.4),
    0 0 30px rgba(255, 215, 0, 0.3);
}

.characteristic-card:hover::before {
  opacity: 1;
}

.characteristic-card h4 {
  font-size: 1.3rem;
  color: var(--star-white);
  margin-bottom: 1rem;
  text-shadow: 0 0 15px rgba(255, 255, 255, 0.5);
}

.characteristic-card p {
  color: var(--silver-accent);
  line-height: 1.6;
}

/* Responsive Design */
@media (max-width: 768px), (max-width: 920px) and (max-height: 480px) {
  .sidebar {
    position: fixed !important;
    top: 0;
    left: 0;
    bottom: 0;
    width: 280px !important;
    height: 100% !important;
    z-index: 1000 !important;
    transform: translateX(-100%) !important;
    visibility: hidden;
    box-shadow: 5px 0 25px rgba(0, 0, 0, 0.5) !important;
    transition: transform 0.4s cubic-bezier(0.25, 0.8, 0.25, 1), visibility 0.4s !important;
  }
  
  .sidebar.open {
    transform: translateX(0) !important;
    visibility: visible !important;
  }

  .mobile-close-btn {
    display: block !important;
  }

  .hamburger-btn {
    display: block !important;
  }

  .language-selector {
    position: static !important;
  }

  .top-bar {
    padding: 0 16px !important;
  }

  .container {
    padding: 15px;
  }
  
  header h1 {
    font-size: 2.5rem;
  }
  
  .language-selector {
    position: static !important;
  }
  
  .language-selector select {
    padding: 6px 12px;
    font-size: 0.85rem;
    min-width: 100px;
    border-radius: 20px;
    touch-action: manipulation;
    -webkit-tap-highlight-color: transparent;
  }
  
  .profile-title {
    flex-direction: column;
    text-align: center;
    gap: 1rem;
  }
  
  .astro-grid,
  .horoscope-grid,
  .bio-grid,
  .characteristics-grid {
    grid-template-columns: 1fr;
  }
  
  .form-section,
  .results-section {
    padding: 1.5rem;
  }

  /* Responsive book cover, card, and royal frame ornaments */
  .book-card {
    padding: 55px 35px !important;
  }
  
  .book-cover-page {
    max-width: 90%;
    padding: 55px 35px;
    margin: 16px auto;
  }
  
  .cover-title {
    font-size: 2.4rem;
    letter-spacing: 0.1em;
  }
  
  .cover-subtitle {
    font-size: 0.95rem;
    letter-spacing: 0.1em;
    margin-bottom: 16px;
  }
  
  .cover-art-wrapper {
    width: 150px;
    height: 150px;
    margin-bottom: 16px;
  }
  
  .cover-meta {
    font-size: 0.85rem;
    max-width: 380px;
  }
  
  .frame-corner {
    width: 80px;
    height: 80px;
  }
  
  .frame-edge.top {
    left: 80px;
    right: 80px;
    height: 40px;
  }
  
  .frame-edge svg.top-arch {
    width: 240px;
    height: 40px;
  }
  
  .frame-edge.bottom {
    left: 80px;
    right: 80px;
    height: 30px;
  }
  
  .frame-edge svg.bottom-scroll {
    width: 180px;
    height: 30px;
  }
}

@media (max-width: 480px) {
  .language-selector {
    position: static !important;
  }
  
  .language-selector select {
    padding: 5px 10px;
    font-size: 0.8rem;
    min-width: 90px;
    border-radius: 18px;
  }

  .book-card {
    padding: 45px 20px !important;
  }
  
  .book-cover-page {
    max-width: 95%;
    padding: 45px 20px;
    margin: 10px auto;
  }
  
  .cover-title {
    font-size: 1.8rem;
    letter-spacing: 0.05em;
  }
  
  .cover-subtitle {
    font-size: 0.8rem;
    letter-spacing: 0.05em;
    margin-bottom: 12px;
  }
  
  .cover-art-wrapper {
    width: 110px;
    height: 110px;
    margin-bottom: 12px;
    padding: 4px;
  }
  
  .cover-meta {
    font-size: 0.8rem;
    max-width: 290px;
    margin-bottom: 16px;
    line-height: 1.5;
  }
  
  .cover-author {
    font-size: 0.7rem;
    margin-bottom: 8px;
  }

  .cover-ornament-top {
    font-size: 0.9rem;
    margin-bottom: 10px;
  }
  
  .cover-ornament-bottom {
    font-size: 0.65rem;
    margin-top: 10px;
  }
  
  .frame-corner {
    width: 50px;
    height: 50px;
  }
  
  .frame-edge.top {
    left: 50px;
    right: 50px;
    height: 25px;
  }
  
  .frame-edge svg.top-arch {
    width: 150px;
    height: 25px;
  }
  
  .frame-edge.bottom {
    left: 50px;
    right: 50px;
    height: 20px;
  }
  
  .frame-edge svg.bottom-scroll {
    width: 110px;
    height: 20px;
  }
}

/* Custom Date Picker Card */
.date-picker-container {
  position: relative;
  display: inline-block;
  width: 100%;
}

.custom-date-picker {
  position: fixed;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  width: 320px;
  max-width: 90vw;
  background: var(--color-bg-card);
  border: 2px solid var(--color-border);
  border-radius: 15px;
  backdrop-filter: blur(15px);
  box-shadow: 
    0 20px 40px var(--color-shadow),
    0 0 30px var(--color-glow);
  z-index: 2000;
  display: none;
  animation: datePickerSlideIn 0.3s ease-out;
  color: var(--color-text-main);
}

.custom-date-picker.show {
  display: block;
}

/* Modal overlay */
.date-picker-overlay {
  position: fixed;
  top: 0;
  left: 0;
  width: 100vw;
  height: 100vh;
  background: rgba(0, 0, 0, 0.65);
  backdrop-filter: blur(4px);
  z-index: 1999;
  display: none;
  animation: overlayFadeIn 0.3s ease-out;
}

.date-picker-overlay.show {
  display: block;
}

@keyframes datePickerSlideIn {
  from {
    opacity: 0;
    transform: translate(-50%, -50%) scale(0.8);
  }
  to {
    opacity: 1;
    transform: translate(-50%, -50%) scale(1);
  }
}

@keyframes overlayFadeIn {
  from {
    opacity: 0;
  }
  to {
    opacity: 1;
  }
}

.date-picker-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 12px 16px;
  border-bottom: 1px solid var(--color-border);
  background: var(--color-bg-sidebar);
  border-radius: 13px 13px 0 0;
}

.date-nav-btn {
  background: none;
  border: none;
  color: var(--color-text-main);
  font-size: 1.1rem;
  cursor: pointer;
  padding: 4px 8px;
  border-radius: 6px;
  transition: all 0.3s ease;
  width: 28px;
  height: 28px;
  display: flex;
  align-items: center;
  justify-content: center;
}

.date-nav-btn:hover {
  background: var(--color-bg-accent);
  color: var(--gold-primary);
  transform: scale(1.1);
}

.month-year-display {
  color: var(--gold-primary);
  font-weight: 600;
  font-size: 1rem;
  text-align: center;
  min-width: 140px;
}

.year-slider-container {
  margin: 12px 16px;
  padding: 8px 0;
  border-bottom: 1px solid var(--color-border);
}

.year-slider-label {
  color: var(--color-text-muted);
  font-size: 0.8rem;
  margin-bottom: 6px;
  text-align: center;
  display: block;
}

.year-slider {
  width: 100%;
  height: 6px;
  background: var(--color-bg-accent);
  border-radius: 3px;
  outline: none;
  appearance: none;
  position: relative;
  cursor: pointer;
}

.year-slider::-webkit-slider-thumb {
  appearance: none;
  width: 16px;
  height: 16px;
  background: var(--gold-gradient);
  border-radius: 50%;
  cursor: pointer;
  box-shadow: var(--gold-glow);
  transition: all 0.3s ease;
}

.year-slider::-webkit-slider-thumb:hover {
  transform: scale(1.2);
  box-shadow: var(--gold-glow);
}

.year-slider::-moz-range-thumb {
  width: 16px;
  height: 16px;
  background: var(--gold-gradient);
  border-radius: 50%;
  cursor: pointer;
  border: none;
  box-shadow: var(--gold-glow);
  transition: all 0.3s ease;
}

.year-slider::-moz-range-thumb:hover {
  transform: scale(1.2);
  box-shadow: var(--gold-glow);
}

.year-slider::-moz-range-track {
  width: 100%;
  height: 6px;
  background: var(--color-bg-accent);
  border-radius: 3px;
  border: none;
}

.year-range-display {
  display: flex;
  justify-content: space-between;
  font-size: 0.7rem;
  color: var(--color-text-muted);
  margin-top: 4px;
  opacity: 0.8;
}

/* ===============================
   Custom Time Picker Styling
   =============================== */

.time-input-wrapper {
  position: relative;
}

.custom-time-picker {
  position: fixed;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%) scale(0.95);
  background: var(--color-bg-card);
  border: 2px solid var(--color-border);
  border-radius: 16px;
  box-shadow: 
    0 20px 40px var(--color-shadow),
    0 0 30px var(--color-glow),
    inset 0 1px 0 rgba(255, 255, 255, 0.05);
  backdrop-filter: blur(15px);
  width: 280px;
  max-width: 90vw;
  z-index: 2000;
  opacity: 0;
  visibility: hidden;
  transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
  color: var(--color-text-main);
}

.custom-time-picker.show {
  opacity: 1;
  visibility: visible;
  transform: translate(-50%, -50%) scale(1);
}

.time-picker-header {
  padding: 12px 16px 6px;
  text-align: center;
  border-bottom: 1px solid var(--color-border);
}

.time-picker-header h4 {
  color: var(--gold-primary);
  font-size: 1rem;
  font-weight: 600;
  margin: 0;
}

.clock-container {
  padding: 16px;
  display: flex;
  justify-content: center;
  align-items: center;
}

.clock-face {
  position: relative;
  width: 160px;
  height: 160px;
  border: 2px solid var(--color-border);
  border-radius: 50%;
  background: var(--color-bg-sidebar);
  box-shadow: 
    inset 0 0 15px var(--color-shadow),
    0 0 20px var(--color-glow);
}

.clock-center {
  position: absolute;
  top: 50%;
  left: 50%;
  width: 8px;
  height: 8px;
  background: var(--gold-primary);
  border-radius: 50%;
  transform: translate(-50%, -50%);
  box-shadow: var(--gold-glow);
}

.clock-hand {
  position: absolute;
  top: 50%;
  left: 50%;
  transform-origin: bottom center;
  border-radius: 2px;
  transition: transform 0.3s ease;
}

.custom-time-picker.dragging .clock-hand {
  transition: none !important;
}

.hour-hand {
  width: 3px;
  height: 45px;
  background: linear-gradient(to top, var(--gold-primary), var(--gold-light));
  margin-left: -1.5px;
  margin-top: -45px;
  box-shadow: 0 0 4px var(--color-glow);
}

.minute-hand {
  width: 2px;
  height: 60px;
  background: linear-gradient(to top, var(--color-text-muted), var(--color-text-main));
  margin-left: -1px;
  margin-top: -60px;
  box-shadow: 0 0 3px rgba(255, 255, 255, 0.15);
}

.hour-markers {
  position: absolute;
  width: 100%;
  height: 100%;
}

.hour-marker {
  position: absolute;
  top: 50%;
  left: 50%;
  width: 20px;
  height: 20px;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--gold-primary);
  font-weight: 600;
  font-size: 0.8rem;
  cursor: pointer;
  border-radius: 50%;
  transition: all 0.2s ease;
  user-select: none;
}

.hour-marker:hover {
  background: var(--color-bg-accent);
  transform: rotate(0deg) translateY(-70px) rotate(0deg) scale(1.1) !important;
  box-shadow: var(--gold-glow);
}

.time-display {
  padding: 12px 16px;
  border-top: 1px solid var(--color-border);
  border-bottom: 1px solid var(--color-border);
}

.time-inputs {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
}

.time-input-group {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 4px;
}

.time-input-group label {
  color: var(--color-text-muted);
  font-size: 0.75rem;
  font-weight: 500;
}

.time-number-input {
  width: 50px;
  padding: 6px 8px;
  background: var(--color-bg-accent);
  border: 1px solid var(--color-border);
  border-radius: 6px;
  color: var(--color-text-main);
  text-align: center;
  font-size: 0.9rem;
  font-weight: 600;
  transition: all 0.2s ease;
}

.time-number-input:focus {
  outline: none;
  border-color: var(--gold-primary);
  box-shadow: var(--gold-glow);
  background: var(--color-bg-sidebar);
}

#ampmSelect {
  width: 60px;
  cursor: pointer;
}

.time-separator {
  color: var(--gold-primary);
  font-size: 1.2rem;
  font-weight: bold;
  margin: 0 2px;
}

.time-picker-footer {
  padding: 12px 16px;
  display: flex;
  gap: 8px;
  justify-content: center;
}

.time-picker-btn {
  padding: 6px 12px;
  border: 1px solid var(--color-border);
  border-radius: 8px;
  background: var(--color-bg-accent);
  color: var(--color-text-main);
  cursor: pointer;
  transition: all 0.2s ease;
  font-size: 0.8rem;
  font-weight: 500;
}

.time-picker-btn:hover {
  border-color: var(--gold-primary);
  background: var(--color-bg-sidebar);
  box-shadow: var(--gold-glow);
}

.time-picker-btn.primary {
  background: var(--gold-gradient);
  color: #120d03;
  border-color: var(--gold-primary);
}

.time-picker-btn.primary:hover {
  opacity: 0.9;
  box-shadow: var(--gold-glow);
}

.date-picker-calendar {
  padding: 16px;
}

.calendar-weekdays {
  display: grid;
  grid-template-columns: repeat(7, 1fr);
  gap: 4px;
  margin-bottom: 8px;
}

.weekday {
  text-align: center;
  font-size: 0.8rem;
  color: var(--color-text-muted);
  font-weight: 600;
  padding: 6px 0;
}

.calendar-days {
  display: grid;
  grid-template-columns: repeat(7, 1fr);
  gap: 4px;
}

.calendar-day {
  background: none;
  border: 1px solid transparent;
  color: var(--color-text-main);
  padding: 8px;
  border-radius: 6px;
  cursor: pointer;
  transition: all 0.3s ease;
  font-size: 0.85rem;
  position: relative;
  min-height: 32px;
  display: flex;
  align-items: center;
  justify-content: center;
}

/* Top Action Bar */
.top-bar {
  height: 70px;
  border-bottom: 1px solid var(--color-border);
  padding: 0 32px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  background-color: rgba(0, 0, 0, 0.12);
  backdrop-filter: blur(8px);
  position: sticky !important;
  top: 0 !important;
  z-index: 1000 !important;
  flex-shrink: 0;
}

.calendar-day:hover {
  background: rgba(191, 149, 63, 0.15);
  border-color: var(--color-border);
  transform: scale(1.05);
}

.calendar-day.other-month {
  color: var(--color-text-muted);
  opacity: 0.4;
  cursor: default;
}

.calendar-day.other-month:hover {
  background: none;
  border-color: transparent;
  transform: none;
}

.calendar-day.selected {
  background: var(--gold-gradient);
  border-color: var(--gold-primary);
  color: #120d03;
  font-weight: 600;
  box-shadow: var(--gold-glow);
}

.calendar-day.today {
  border-color: var(--color-border);
  background: var(--color-bg-accent);
}

.date-picker-footer {
  padding: 12px 16px;
  border-top: 1px solid var(--color-border);
  display: flex;
  justify-content: space-between;
  gap: 8px;
}

.date-picker-btn {
  padding: 6px 12px;
  border: 1px solid var(--color-border);
  background: var(--color-bg-accent);
  color: var(--color-text-main);
  border-radius: 16px;
  cursor: pointer;
  transition: all 0.3s ease;
  font-size: 0.8rem;
  font-weight: 500;
  flex: 1;
}

.date-picker-btn:hover {
  background: var(--gold-primary);
  color: #120d03;
  transform: translateY(-2px);
  box-shadow: var(--gold-glow);
}

.date-picker-btn.primary {
  background: var(--gold-gradient);
  border-color: var(--gold-primary);
  color: #120d03;
}

.date-picker-btn.primary:hover {
  opacity: 0.9;
  border-color: var(--gold-primary);
  color: #120d03;
}

/* Hide default date input arrow on webkit browsers */
input[type="date"]::-webkit-calendar-picker-indicator {
  background: transparent;
  bottom: 0;
  color: transparent;
  cursor: pointer;
  height: auto;
  left: 0;
  position: absolute;
  right: 0;
  top: 0;
  width: auto;
  opacity: 0;
}

/* Add custom calendar icon */
.date-input-wrapper {
  position: relative;
}

.date-input-wrapper::after {
  content: "📅";
  position: absolute;
  right: 15px;
  top: 50%;
  transform: translateY(-50%);
  pointer-events: none;
  font-size: 1.1rem;
  color: var(--gold-primary);
}

/* Mobile responsiveness */
@media (max-width: 480px) {
  .custom-date-picker {
    width: 280px;
  }
  
  .date-picker-header {
    padding: 10px 12px;
  }
  
  .date-picker-calendar {
    padding: 12px;
  }
  
  .calendar-day {
    min-height: 28px;
    font-size: 0.8rem;
  }
}

/* Visibility Utilities */
.hidden {
  display: none !important;
}

/* ====================================================
   ADDITIONAL REDESIGN STYLES (AstroBioRhythm Cover, Library, Sound, and Theme Polish)
   ==================================================== */

/* Cover Page and Storytelling Entrance */
.book-cover-page {
  width: 100%;
  max-width: 680px;
  margin: 32px auto;
  padding: 60px 48px; /* Increased top/bottom padding to clear frame ornaments */
  position: relative;
  background-color: var(--color-bg-card);
  border-radius: 12px;
  box-shadow: 0 15px 45px var(--color-shadow);
  border: 1px solid var(--color-border);
  overflow: hidden;
  box-sizing: border-box;
  backdrop-filter: blur(15px);
  z-index: 5;
  transition: transform 0.8s cubic-bezier(0.25, 0.8, 0.25, 1), opacity 0.6s ease;
  transform-style: preserve-3d;
  perspective: 1000px;
  flex-shrink: 0; /* Prevent vertical squishing in flex container */
}

.book-cover-page::before {
  content: '';
  position: absolute;
  top: 20px;
  left: 20px;
  right: 20px;
  bottom: 20px;
  border: 1px dashed var(--color-border);
  border-radius: 8px;
  pointer-events: none;
}

.cover-gold-border {
  padding: 24px 0;
  text-align: center;
  position: relative;
}

.cover-ornament-top {
  font-family: var(--font-headings);
  font-size: 1.1rem;
  letter-spacing: 0.5em;
  color: var(--gold-primary);
  margin-bottom: 16px;
  opacity: 0.8;
}

.cover-ornament-bottom {
  font-family: var(--font-headings);
  font-size: 0.75rem;
  letter-spacing: 0.25em;
  color: var(--gold-primary);
  text-transform: uppercase;
  margin-top: 16px;
  opacity: 0.7;
}

.cover-main-content {
  display: flex;
  flex-direction: column;
  align-items: center;
}

.cover-author {
  font-size: 0.8rem;
  text-transform: uppercase;
  letter-spacing: 0.15em;
  color: var(--color-text-muted);
  margin-bottom: 16px;
  font-family: var(--font-headings);
}

.cover-title {
  font-size: 3.5rem;
  font-weight: 900;
  letter-spacing: 0.12em;
  line-height: 1.15;
  text-align: center;
  margin-bottom: 4px;
  background: var(--gold-gradient);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  filter: drop-shadow(0 2px 4px rgba(0,0,0,0.3));
  font-family: var(--font-headings);
  word-wrap: break-word;
  overflow-wrap: break-word;
}

.cover-subtitle {
  font-size: 1.15rem;
  font-family: var(--font-headings);
  text-transform: uppercase;
  letter-spacing: 0.15em;
  line-height: 1.3;
  text-align: center;
  color: var(--color-text-main);
  margin-bottom: 20px;
}

.cover-art-wrapper {
  width: 200px;
  height: 200px;
  border-radius: 50%;
  border: 2px solid var(--gold-primary);
  padding: 8px;
  background-color: rgba(0,0,0,0.4);
  box-shadow: var(--gold-glow);
  margin-bottom: 20px;
  overflow: hidden;
  display: flex;
  align-items: center;
  justify-content: center;
  position: relative;
}

.cover-art-img {
  width: 90%;
  height: 90%;
  object-fit: contain;
  transition: transform 0.8s ease;
}

/* Spin animation for cover emblem */
.rotating-emblem {
  animation: slow-spin 60s linear infinite;
}

@keyframes slow-spin {
  from { transform: rotate(0deg); }
  to { transform: rotate(360deg); }
}

.cover-meta {
  font-size: 0.95rem;
  max-width: 460px;
  margin: 0 auto 24px auto;
  color: var(--color-text-muted);
  line-height: 1.6;
}

.book-credit-footer {
  margin-top: 24px;
  font-family: var(--font-headings);
  font-size: 0.8rem;
  letter-spacing: 0.15em;
  color: var(--color-text-muted);
  text-align: center;
  opacity: 0.6;
  width: 100%;
}

/* Premium Gold Button */
.gold-btn {
  background: var(--gold-gradient);
  color: #120d03 !important;
  border: none;
  border-radius: 4px;
  padding: 14px 36px;
  font-family: var(--font-headings);
  font-weight: 700;
  font-size: 0.9rem;
  text-transform: uppercase;
  letter-spacing: 0.12em;
  cursor: pointer;
  box-shadow: 0 4px 15px rgba(170,119,28,0.3);
  transition: var(--transition-smooth);
  position: relative;
  z-index: 5;
}

.gold-btn:hover {
  transform: translateY(-2px);
  box-shadow: var(--gold-glow);
}

.gold-btn:active {
  transform: translateY(0);
}

/* Ambient sound banner and top bar controls */
.sound-btn {
  background: none;
  border: 1px solid var(--color-border);
  border-radius: 20px;
  color: var(--color-text-main);
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 6px 14px;
  font-family: var(--font-headings);
  font-size: 0.75rem;
  cursor: pointer;
  transition: var(--transition-fast);
}

.sound-btn:hover {
  border-color: var(--gold-primary);
  background-color: rgba(191,149,63,0.06);
}

.sound-btn.active {
  background-color: var(--gold-primary);
  color: #120d03;
  border-color: var(--gold-primary);
  box-shadow: var(--gold-glow);
}

.audio-start-banner {
  position: fixed;
  bottom: 24px;
  left: 50%;
  transform: translateX(-50%);
  background-color: rgba(19, 23, 32, 0.95);
  border: 1px solid var(--color-border);
  border-radius: 8px;
  padding: 16px 24px;
  box-shadow: 0 10px 30px rgba(0,0,0,0.5);
  z-index: 2000;
  max-width: 500px;
  width: 90%;
  backdrop-filter: blur(8px);
  animation: slide-up 0.5s cubic-bezier(0.25, 0.8, 0.25, 1);
  box-sizing: border-box;
}

@keyframes slide-up {
  from { transform: translate(-50%, 100px); opacity: 0; }
  to { transform: translate(-50%, 0); opacity: 1; }
}

.banner-content {
  display: flex;
  flex-direction: column;
  gap: 12px;
  align-items: center;
  text-align: center;
}

.banner-content p {
  font-size: 0.85rem;
  margin: 0;
  line-height: 1.5;
  color: var(--color-text-main);
}

.banner-buttons {
  display: flex;
  gap: 12px;
}

.btn-small {
  padding: 8px 16px;
  font-size: 0.75rem;
}

.text-btn {
  background: none;
  border: none;
  color: var(--color-text-muted);
  cursor: pointer;
  font-family: var(--font-headings);
  font-size: 0.75rem;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  padding: 8px 12px;
  transition: var(--transition-fast);
}

.text-btn:hover {
  color: var(--color-text-main);
  text-decoration: underline;
}

/* Zodiac Books Library Grid */
.zodiac-library-section {
  padding: 60px 40px !important;
}

.zodiac-library-section h2 {
  font-family: var(--font-headings) !important;
  font-size: 2.2rem !important;
  color: var(--gold-primary) !important;
  text-shadow: var(--gold-glow);
  text-align: center;
  margin-bottom: 8px;
}

.library-description {
  text-align: center;
  color: var(--color-text-muted);
  font-size: 0.95rem;
  max-width: 580px;
  margin: 0 auto 32px auto;
  line-height: 1.6;
}

.zodiac-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 20px;
  margin-top: 16px;
}

@media (max-width: 768px) {
  .zodiac-grid {
    grid-template-columns: repeat(3, 1fr);
    gap: 16px;
  }
}

@media (max-width: 480px) {
  .zodiac-grid {
    grid-template-columns: repeat(2, 1fr);
    gap: 12px;
  }
}

.zodiac-book-item {
  cursor: pointer;
  transition: transform 0.3s ease;
}

.zodiac-book-item:hover {
  transform: translateY(-8px);
}

.book-cover-mini {
  height: 140px;
  background-color: var(--color-bg-sidebar);
  border: 1px solid var(--color-border);
  border-radius: 6px;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 16px;
  position: relative;
  box-shadow: 0 4px 10px rgba(0,0,0,0.3);
  transition: all 0.3s ease;
  overflow: hidden;
}

.book-cover-mini::after {
  content: '';
  position: absolute;
  top: 4px;
  left: 4px;
  right: 4px;
  bottom: 4px;
  border: 1px dashed rgba(191, 149, 63, 0.15);
  border-radius: 4px;
  pointer-events: none;
  transition: border-color 0.3s ease;
}

.zodiac-book-item:hover .book-cover-mini {
  border-color: var(--gold-primary);
  box-shadow: var(--gold-glow);
  background-color: rgba(191, 149, 63, 0.04);
}

.zodiac-book-item:hover .book-cover-mini::after {
  border-color: rgba(191, 149, 63, 0.45);
}

.book-cover-mini .zodiac-icon {
  font-size: 2.2rem;
  color: var(--gold-primary);
  margin-bottom: 8px;
  text-shadow: 0 0 10px rgba(191, 149, 63, 0.3);
}

.book-cover-mini .book-title-mini {
  font-family: var(--font-headings);
  font-size: 0.9rem;
  font-weight: 600;
  color: var(--color-text-main);
  text-align: center;
}

.book-cover-mini .book-subtitle-mini {
  font-size: 0.65rem;
  color: var(--color-text-muted);
  text-transform: uppercase;
  letter-spacing: 0.05em;
  margin-top: 2px;
}

/* Sync and add additional themes styling for completeness */
body.theme-sun {
  --color-bg: #090703;
  --color-bg-sidebar: #130f06;
  --color-bg-card: #1e170a;
  --color-bg-accent: #2d220e;
  --color-text-main: #fffaf0;
  --color-text-muted: #b3a085;
  --color-border: rgba(191, 149, 63, 0.35);
  --color-border-hover: rgba(191, 149, 63, 0.65);
  --color-glow: rgba(191, 149, 63, 0.25);
  --color-scrollbar: #130f06;
  --color-shadow: rgba(0, 0, 0, 0.9);
  background-color: var(--color-bg);
  color: var(--color-text-main);
  
  --gold-primary: #d4af37;
  --gold-light: #fff3b3;
  --gold-medium: #aa771c;
  --gold-dark: #8a5a00;
  --gold-gradient: linear-gradient(135deg, #d4af37 0%, #fff3b3 25%, #aa771c 50%, #fff3b3 75%, #8a5a00 100%);
  --gold-glow: 0 0 15px rgba(212, 175, 55, 0.45);
  
  background-image: 
    radial-gradient(ellipse at top left, rgba(45, 34, 14, 0.6) 0%, transparent 60%),
    radial-gradient(ellipse at bottom right, rgba(19, 15, 6, 0.7) 0%, transparent 70%),
    radial-gradient(circle at 50% 50%, rgba(30, 23, 10, 0.85) 0%, #090703 100%);
}

body.theme-heart {
  --color-bg: #120507;
  --color-bg-sidebar: #1d0a0c;
  --color-bg-card: #2c0f13;
  --color-bg-accent: #3f161b;
  --color-text-main: #fff5f5;
  --color-text-muted: #caa3a7;
  --color-border: rgba(224, 123, 83, 0.35);
  --color-border-hover: rgba(224, 123, 83, 0.65);
  --color-glow: rgba(224, 123, 83, 0.25);
  --color-scrollbar: #1d0a0c;
  --color-shadow: rgba(0, 0, 0, 0.85);
  background-color: var(--color-bg);
  color: var(--color-text-main);
  
  --gold-primary: #e07b53;
  --gold-light: #ffd5c6;
  --gold-medium: #b5512b;
  --gold-dark: #863314;
  --gold-gradient: linear-gradient(135deg, #e07b53 0%, #ffd5c6 25%, #b5512b 50%, #ffd5c6 75%, #863314 100%);
  --gold-glow: 0 0 15px rgba(224, 123, 83, 0.4);
  
  background-image: 
    radial-gradient(ellipse at top left, rgba(63, 22, 27, 0.6) 0%, transparent 60%),
    radial-gradient(ellipse at bottom right, rgba(29, 10, 12, 0.7) 0%, transparent 70%),
    radial-gradient(circle at 50% 50%, rgba(44, 15, 19, 0.85) 0%, #120507 100%);
}

body.theme-crown {
  --color-bg: #0c0614;
  --color-bg-sidebar: #140a21;
  --color-bg-card: #1f0f33;
  --color-bg-accent: #2d164a;
  --color-text-main: #faf5ff;
  --color-text-muted: #c0acd9;
  --color-border: rgba(168, 85, 247, 0.35);
  --color-border-hover: rgba(168, 85, 247, 0.65);
  --color-glow: rgba(168, 85, 247, 0.25);
  --color-scrollbar: #140a21;
  --color-shadow: rgba(0, 0, 0, 0.85);
  background-color: var(--color-bg);
  color: var(--color-text-main);
  
  --gold-primary: #bf953f;
  --gold-light: #fcf6ba;
  --gold-medium: #b38728;
  --gold-dark: #aa771c;
  --gold-gradient: linear-gradient(135deg, #a855f7 0%, #e9d5ff 25%, #bf953f 50%, #fcf6ba 75%, #aa771c 100%);
  --gold-glow: 0 0 15px rgba(168, 85, 247, 0.4);
  
  background-image: 
    radial-gradient(ellipse at top left, rgba(45, 22, 74, 0.6) 0%, transparent 60%),
    radial-gradient(ellipse at bottom right, rgba(20, 10, 33, 0.7) 0%, transparent 70%),
    radial-gradient(circle at 50% 50%, rgba(31, 15, 51, 0.85) 0%, #0c0614 100%);
}

/* Page turn exit effect for the cover */
.book-cover-page.exit-active {
  transform: rotateY(-110deg) scale(0.9) translateX(-100px);
  opacity: 0;
  pointer-events: none;
}

/* ══════════════════════════════════════════════════════════════
   ✦ PREMIUM LUXURY UI ENHANCEMENTS — AstroBioRhythm
   Cinematic, editorial, polished micro-interactions
   ══════════════════════════════════════════════════════════════ */

/* ── 1. GLASSMORPHISM TOP-BAR UPGRADE ─────────────────────────── */
.top-bar {
  background: rgba(12, 15, 22, 0.55) !important;
  backdrop-filter: blur(22px) saturate(180%) !important;
  -webkit-backdrop-filter: blur(22px) saturate(180%) !important;
  border-bottom: 1px solid rgba(191, 149, 63, 0.25) !important;
  box-shadow:
    0 1px 0 rgba(191, 149, 63, 0.1),
    0 4px 24px rgba(0, 0, 0, 0.35) !important;
  transition: background 0.4s ease, box-shadow 0.4s ease, border-color 0.4s ease !important;
}

/* Audio button refinement */
.sound-btn {
  display: flex;
  align-items: center;
  gap: 6px;
  background: rgba(191, 149, 63, 0.08);
  border: 1px solid rgba(191, 149, 63, 0.3);
  border-radius: 20px;
  color: var(--color-text-muted);
  padding: 6px 14px;
  font-family: var(--font-headings);
  font-size: 0.72rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  cursor: pointer;
  transition: all 0.3s ease;
}
.sound-btn:hover {
  background: rgba(191, 149, 63, 0.18);
  border-color: var(--gold-primary);
  color: var(--gold-primary);
  box-shadow: var(--gold-glow);
}

/* Language selector refinement */
.language-selector select {
  background: rgba(191, 149, 63, 0.06) !important;
  border: 1px solid rgba(191, 149, 63, 0.3) !important;
  border-radius: 20px !important;
  color: var(--color-text-muted) !important;
  padding: 6px 14px !important;
  font-family: var(--font-headings) !important;
  font-size: 0.72rem !important;
  letter-spacing: 0.08em !important;
  text-transform: uppercase !important;
  cursor: pointer !important;
  transition: all 0.3s ease !important;
  outline: none !important;
  appearance: none !important;
  -webkit-appearance: none !important;
}
.language-selector select:hover,
.language-selector select:focus {
  border-color: var(--gold-primary) !important;
  color: var(--gold-primary) !important;
  box-shadow: none !important;
  transform: none !important;
  background: rgba(191, 149, 63, 0.12) !important;
}

/* ── 2. CINEMATIC COVER PAGE HERO UPGRADE ─────────────────────── */
.book-cover-page {
  position: relative;
  overflow: hidden;
}

/* Ambient cinematic radial glow behind the emblem */
.book-cover-page::after {
  content: '';
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  width: 340px;
  height: 340px;
  background: radial-gradient(circle, rgba(191, 149, 63, 0.12) 0%, transparent 70%);
  pointer-events: none;
  z-index: 1;
  animation: heroAmbient 6s ease-in-out infinite;
}

@keyframes heroAmbient {
  0%, 100% { opacity: 0.6; transform: translate(-50%, -50%) scale(1); }
  50%       { opacity: 1;   transform: translate(-50%, -50%) scale(1.12); }
}

/* Cover title — larger, more cinematic on desktop */
.cover-title {
  font-size: clamp(2rem, 4.2vw, 3.2rem) !important;
  letter-spacing: 0.08em !important;
  line-height: 1.1 !important;
  background: linear-gradient(135deg, #bf953f 0%, #fcf6ba 30%, #d4af5a 55%, #fbf5b7 80%, #aa771c 100%) !important;
  -webkit-background-clip: text !important;
  -webkit-text-fill-color: transparent !important;
  filter: drop-shadow(0 4px 12px rgba(0, 0, 0, 0.5)) !important;
  animation: titleShimmer 8s linear infinite !important;
  background-size: 200% auto !important;
}

@keyframes titleShimmer {
  0%   { background-position: 0% center; }
  100% { background-position: 200% center; }
}

/* Rotating emblem — premium glow ring */
.cover-art-wrapper {
  position: relative;
}
.cover-art-wrapper::before {
  content: '';
  position: absolute;
  inset: -8px;
  border-radius: 50%;
  background: conic-gradient(
    from 0deg,
    transparent 0deg,
    rgba(191, 149, 63, 0.6) 60deg,
    transparent 120deg,
    rgba(252, 246, 186, 0.4) 180deg,
    transparent 240deg,
    rgba(191, 149, 63, 0.5) 300deg,
    transparent 360deg
  );
  animation: ringRotate 8s linear infinite;
  z-index: 0;
}

.rotating-emblem {
  position: relative;
  z-index: 1;
}

@keyframes ringRotate {
  from { transform: rotate(0deg); }
  to   { transform: rotate(360deg); }
}

/* CTA Button — premium shine sweep */
.btn-read-start {
  position: relative;
  overflow: hidden;
  font-family: var(--font-headings) !important;
  font-size: 0.9rem !important;
  letter-spacing: 0.18em !important;
  text-transform: uppercase !important;
  padding: 14px 40px !important;
  border-radius: 2px !important;
  border: 1px solid var(--gold-primary) !important;
  background: transparent !important;
  color: var(--gold-primary) !important;
  cursor: pointer;
  transition: all 0.4s cubic-bezier(0.25, 0.8, 0.25, 1) !important;
  -webkit-text-fill-color: var(--gold-primary) !important;
}

.btn-read-start::before {
  content: '';
  position: absolute;
  top: 0; left: -100%;
  width: 100%; height: 100%;
  background: linear-gradient(90deg, transparent, rgba(191,149,63,0.15), transparent);
  transition: left 0.5s ease;
}

.btn-read-start:hover {
  background: var(--gold-gradient) !important;
  color: #120d03 !important;
  -webkit-text-fill-color: #120d03 !important;
  box-shadow: 0 8px 30px rgba(191, 149, 63, 0.4), var(--gold-glow) !important;
  transform: translateY(-3px) !important;
  letter-spacing: 0.22em !important;
}
.btn-read-start:hover::before {
  left: 100%;
}

/* Scroll indicator arrow */
.scroll-indicator {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 6px;
  margin-top: 20px;
  opacity: 0.55;
  animation: scrollBounce 2.2s ease-in-out infinite;
  font-family: var(--font-headings);
  font-size: 0.65rem;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: var(--color-text-muted);
}
.scroll-indicator svg {
  width: 20px;
  height: 20px;
  color: var(--gold-primary);
}
@keyframes scrollBounce {
  0%, 100% { transform: translateY(0); }
  50%       { transform: translateY(7px); }
}

/* ── 3. EDITORIAL STORY / NARRATIVE SECTION ───────────────────── */
.editorial-story {
  width: 100%;
  max-width: 780px;
  margin: 0 auto 48px;
  padding: 0 24px;
  box-sizing: border-box;
}

.editorial-story .story-eyebrow {
  font-family: var(--font-headings);
  font-size: 0.7rem;
  letter-spacing: 0.35em;
  text-transform: uppercase;
  color: var(--gold-primary);
  text-align: center;
  margin-bottom: 16px;
  opacity: 0.8;
}

.editorial-story .story-headline {
  font-family: var(--font-subheadings);
  font-size: clamp(1.6rem, 3.5vw, 2.6rem);
  font-weight: 700;
  color: var(--color-text-main);
  text-align: center;
  line-height: 1.25;
  margin-bottom: 32px;
  max-width: 560px;
  margin-left: auto;
  margin-right: auto;
}

/* Asymmetric two-column narrative grid */
.narrative-grid {
  display: grid;
  grid-template-columns: 1.4fr 1fr;
  gap: 40px;
  align-items: center;
  margin-bottom: 48px;
}

.narrative-grid.reverse {
  grid-template-columns: 1fr 1.4fr;
  direction: rtl;
}
.narrative-grid.reverse > * {
  direction: ltr;
}

.narrative-col {
  display: flex;
  flex-direction: column;
  gap: 16px;
}

.narrative-col .col-eyebrow {
  font-family: var(--font-headings);
  font-size: 0.65rem;
  letter-spacing: 0.3em;
  text-transform: uppercase;
  color: var(--gold-primary);
  opacity: 0.75;
}

.narrative-col .col-title {
  font-family: var(--font-subheadings);
  font-size: 1.5rem;
  font-weight: 600;
  color: var(--color-text-main);
  line-height: 1.3;
}

.narrative-col .col-body {
  font-family: var(--font-body);
  font-size: 0.97rem;
  line-height: 1.75;
  color: var(--color-text-muted);
}

.narrative-col .col-rule {
  width: 48px;
  height: 1px;
  background: var(--gold-gradient);
  opacity: 0.7;
}

/* Visual panel (right/left column graphic side) */
.narrative-visual {
  position: relative;
  border-radius: 4px;
  overflow: hidden;
  background: var(--color-bg-accent);
  border: 1px solid var(--color-border);
  min-height: 200px;
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 20px 50px rgba(0, 0, 0, 0.45);
  transition: transform 0.5s ease, box-shadow 0.5s ease;
}
.narrative-visual:hover {
  transform: translateY(-6px);
  box-shadow: 0 28px 60px rgba(0, 0, 0, 0.6), 0 0 30px rgba(191, 149, 63, 0.12);
}
.narrative-visual .visual-icon {
  font-size: 4rem;
  opacity: 0.8;
  filter: drop-shadow(0 0 20px rgba(191,149,63,0.5));
}
.narrative-visual::before {
  content: '';
  position: absolute;
  inset: 0;
  background: radial-gradient(circle at 40% 40%, rgba(191,149,63,0.08) 0%, transparent 60%);
}

/* Gold divider */
.gold-divider {
  width: 100%;
  max-width: 240px;
  margin: 0 auto 40px;
  display: flex;
  align-items: center;
  gap: 12px;
}
.gold-divider::before,
.gold-divider::after {
  content: '';
  flex: 1;
  height: 1px;
  background: var(--gold-gradient);
  opacity: 0.5;
}
.gold-divider-diamond {
  width: 6px; height: 6px;
  background: var(--gold-primary);
  transform: rotate(45deg);
  flex-shrink: 0;
  box-shadow: 0 0 8px rgba(191,149,63,0.5);
}

/* ── 4. ZODIAC BOOK GRID — PREMIUM HOVER ──────────────────────── */
.zodiac-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(110px, 1fr));
  gap: 16px;
  margin-top: 24px;
}

.zodiac-book-item {
  cursor: pointer;
  transition: transform 0.3s cubic-bezier(0.25, 0.8, 0.25, 1), box-shadow 0.3s ease !important;
  transform-style: preserve-3d;
  border-radius: 8px;
  will-change: transform;
}

.zodiac-book-item:hover {
  z-index: 5;
}

.book-cover-mini {
  border-radius: 8px !important;
  border: 1px solid var(--color-border) !important;
  background: var(--color-bg-accent) !important;
  display: flex !important;
  flex-direction: column !important;
  align-items: center !important;
  justify-content: center !important;
  gap: 6px !important;
  padding: 18px 8px !important;
  transition: border-color 0.3s ease, box-shadow 0.3s ease, background 0.3s ease !important;
  position: relative;
  overflow: hidden;
  min-height: 110px;
}

.book-cover-mini::after {
  content: '';
  position: absolute;
  inset: 0;
  background: radial-gradient(circle at 50% 50%, rgba(191,149,63,0.14) 0%, transparent 65%);
  opacity: 0;
  transition: opacity 0.35s ease;
}

.zodiac-book-item:hover .book-cover-mini {
  border-color: var(--gold-primary) !important;
  box-shadow: 0 12px 32px rgba(0,0,0,0.4), 0 0 20px rgba(191,149,63,0.2) !important;
  background: var(--color-bg-card) !important;
}

.zodiac-book-item:hover .book-cover-mini::after {
  opacity: 1;
}

.book-cover-mini .zodiac-icon {
  font-size: 2rem !important;
  line-height: 1 !important;
  filter: drop-shadow(0 0 8px rgba(191,149,63,0.5));
  transition: transform 0.35s ease, filter 0.35s ease;
  position: relative;
  z-index: 1;
}

.zodiac-book-item:hover .zodiac-icon {
  transform: scale(1.18) translateY(-2px);
  filter: drop-shadow(0 0 14px rgba(191,149,63,0.8));
}

.book-title-mini {
  font-family: var(--font-headings) !important;
  font-size: 0.72rem !important;
  letter-spacing: 0.08em !important;
  color: var(--color-text-main) !important;
  text-transform: uppercase !important;
  position: relative;
  z-index: 1;
}

.book-subtitle-mini {
  font-size: 0.6rem !important;
  color: var(--color-text-muted) !important;
  letter-spacing: 0.05em !important;
  position: relative;
  z-index: 1;
}

/* ── 5. PREMIUM GOLD BUTTON (global upgrade) ──────────────────── */
.gold-btn {
  position: relative !important;
  overflow: hidden !important;
  font-family: var(--font-headings) !important;
  letter-spacing: 0.12em !important;
  text-transform: uppercase !important;
  border-radius: 2px !important;
  transition: all 0.35s cubic-bezier(0.25, 0.8, 0.25, 1) !important;
}

.gold-btn::after {
  content: '';
  position: absolute;
  top: -50%;
  left: -75%;
  width: 50%;
  height: 200%;
  background: linear-gradient(
    to right,
    transparent,
    rgba(255, 255, 255, 0.18),
    transparent
  );
  transform: skewX(-20deg);
  transition: left 0.55s ease;
  pointer-events: none;
}

.gold-btn:hover::after {
  left: 120%;
}

/* ── 6. PREMIUM FOOTER WITH NEWSLETTER ────────────────────────── */
footer {
  border-radius: 12px 12px 0 0 !important;
  overflow: hidden;
}

.footer-newsletter {
  margin-top: 20px;
  padding-top: 20px;
  border-top: 1px solid var(--color-border);
}

.footer-newsletter-label {
  font-family: var(--font-headings);
  font-size: 0.68rem;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: var(--color-text-muted);
  margin-bottom: 12px;
  display: block;
}

.footer-newsletter-form {
  display: flex;
  gap: 0;
  border: 1px solid var(--color-border);
  border-radius: 2px;
  overflow: hidden;
  transition: border-color 0.3s ease, box-shadow 0.3s ease;
}

.footer-newsletter-form:focus-within {
  border-color: var(--gold-primary);
  box-shadow: var(--gold-glow);
}

.footer-newsletter-input {
  flex: 1;
  background: transparent;
  border: none;
  outline: none;
  padding: 10px 14px;
  color: var(--color-text-main);
  font-family: var(--font-body);
  font-size: 0.85rem;
}

.footer-newsletter-input::placeholder {
  color: var(--color-text-muted);
  opacity: 0.6;
}

.footer-newsletter-btn {
  background: var(--gold-gradient);
  border: none;
  padding: 10px 18px;
  font-family: var(--font-headings);
  font-size: 0.7rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: #120d03;
  cursor: pointer;
  transition: opacity 0.3s ease, letter-spacing 0.3s ease;
  white-space: nowrap;
}

.footer-newsletter-btn:hover {
  opacity: 0.88;
  letter-spacing: 0.18em;
}

/* Social icon links */
.footer-social-links {
  display: flex;
  gap: 12px;
  margin-top: 16px;
}

.footer-social-link {
  width: 34px;
  height: 34px;
  border: 1px solid var(--color-border);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--color-text-muted);
  text-decoration: none;
  font-size: 0.85rem;
  transition: all 0.3s ease;
}

.footer-social-link:hover {
  border-color: var(--gold-primary);
  color: var(--gold-primary);
  box-shadow: var(--gold-glow);
  transform: translateY(-2px);
}

/* ── 7. STARS FIELD PREMIUM ───────────────────────────────────── */
.stars {
  position: fixed;
  top: 0; left: 0;
  width: 110%; height: 110%;
  pointer-events: none;
  z-index: 0;
  overflow: hidden;
  will-change: transform;
}

/* ── 8. SIDEBAR PREMIUM REFINEMENTS ──────────────────────────── */
.sidebar {
  background: linear-gradient(
    180deg,
    var(--color-bg-sidebar) 0%,
    rgba(12,15,22,0.97) 100%
  ) !important;
}

.sidebar-header {
  background: rgba(191, 149, 63, 0.04);
}

/* Sidebar menu item active state — gold bar indicator */
.toc-item.active {
  position: relative;
}
.toc-item.active::before {
  content: '';
  position: absolute;
  left: 0; top: 0; bottom: 0;
  width: 3px;
  background: var(--gold-gradient);
  border-radius: 0 2px 2px 0;
}

/* ── 9. FORM SECTION VISUAL POLISH ───────────────────────────── */
.form-group input,
.form-group select,
.date-input-wrapper input[type="date"],
.time-input-wrapper input[type="time"] {
  transition: border-color 0.3s ease, box-shadow 0.3s ease, background 0.3s ease, transform 0.3s ease !important;
}

/* ── 10. RESPONSIVE POLISH ──────────────────────────────────── */
@media (max-width: 900px) {
  .narrative-grid {
    grid-template-columns: 1fr;
    gap: 24px;
  }
  .narrative-grid.reverse {
    grid-template-columns: 1fr;
    direction: ltr;
  }
  .narrative-visual {
    min-height: 150px;
    order: -1;
  }
}

@media (max-width: 768px) {
  .zodiac-grid {
    grid-template-columns: repeat(auto-fill, minmax(90px, 1fr)) !important;
    gap: 10px !important;
  }
  .editorial-story {
    padding: 0 12px;
  }
  .footer-social-links {
    justify-content: center;
  }
  .footer-newsletter-form {
    flex-direction: column;
  }
  .footer-newsletter-btn {
    text-align: center;
  }
}

@media (max-width: 480px) {
  .cover-title {
    font-size: 2rem !important;
  }
  .zodiac-grid {
    grid-template-columns: repeat(auto-fill, minmax(80px, 1fr)) !important;
  }
}

/* ── 11. UTILITY / ACCESSIBILITY ─────────────────────────────── */
.sr-only {
  position: absolute !important;
  width: 1px !important;
  height: 1px !important;
  padding: 0 !important;
  margin: -1px !important;
  overflow: hidden !important;
  clip: rect(0,0,0,0) !important;
  white-space: nowrap !important;
  border: 0 !important;
}

/* Focus ring for keyboard users */
.gold-btn:focus-visible,
.btn-read-start:focus-visible,
.submit-btn:focus-visible {
  outline: 2px solid var(--gold-primary);
  outline-offset: 3px;
}

