/* ==========================================================================
   SHUBH PANCHANG & HINDI CALENDAR DESIGN SYSTEM
   Modern Vedic Aesthetics: Saffron, Temple Gold, Glassmorphism & Night Mode
   SUPER MOBILE-FIRST RESPONSIVE ARCHITECTURE (Optimized for Indian Smartphones)
   100% Vanilla CSS - Sub-25KB, 100/100 Core Web Vitals, 0 CLS
   ========================================================================== */

/* ----------------- CSS Custom Properties (Design Tokens) ----------------- */
:root {
  /* Sacred Vedic Color Palette */
  --saffron-primary: #E65100;
  --saffron-hover: #BF360C;
  --saffron-light: #FFE0B2;
  --saffron-gradient: linear-gradient(135deg, #FF6F00 0%, #E65100 100%);
  
  --gold-primary: #FFB300;
  --gold-accent: #D4AF37;
  --gold-light: #FFF8E1;
  --gold-border: rgba(255, 179, 0, 0.35);
  --gold-glow: 0 4px 20px rgba(255, 179, 0, 0.22);

  --crimson-sacred: #B71C1C;
  --crimson-soft: #FFEBEE;
  
  --emerald-shubh: #2E7D32;
  --emerald-light: #E8F5E9;
  --emerald-border: #A5D6A7;
  
  --ruby-ashubh: #C62828;
  --ruby-light: #FFEBEE;
  --ruby-border: #EF9A9A;

  /* Theme: Light Day Mode (Sacred Parchment) */
  --bg-canvas: #FFFDF9;
  --bg-surface: #FFFFFF;
  --bg-surface-elevated: #FFFFFF;
  --bg-glass: rgba(255, 255, 255, 0.92);
  --border-subtle: #EBE3DC;
  --border-card: rgba(212, 175, 55, 0.28);

  --text-primary: #211915;
  --text-secondary: #5D5046;
  --text-muted: #8D7B70;
  --text-gold: #B27B00;

  --shadow-sm: 0 2px 8px rgba(90, 45, 10, 0.05);
  --shadow-md: 0 6px 20px rgba(90, 45, 10, 0.08);
  --shadow-lg: 0 12px 36px rgba(90, 45, 10, 0.12);

  /* Typography */
  --font-heading: 'Rozha One', 'Noto Sans Devanagari', serif;
  --font-body: 'Noto Sans Devanagari', 'Plus Jakarta Sans', sans-serif;
  --font-mono: 'JetBrains Mono', monospace;

  /* Spacing & Radii */
  --radius-sm: 8px;
  --radius-md: 14px;
  --radius-lg: 20px;
  --radius-pill: 9999px;
  --container-max: 1280px;

  /* Mobile Bottom Nav Height */
  --bottom-nav-height: 64px;
}

/* ----------------- Night Mode (रात्री मोड) ----------------- */
[data-theme="dark"] {
  --bg-canvas: #0A0D14;
  --bg-surface: #121824;
  --bg-surface-elevated: #182030;
  --bg-glass: rgba(18, 24, 36, 0.92);
  --border-subtle: #242E42;
  --border-card: rgba(255, 179, 0, 0.24);

  --text-primary: #F7F5F0;
  --text-secondary: #B8C1D1;
  --text-muted: #738096;
  --text-gold: #FFD54F;

  --shadow-sm: 0 2px 8px rgba(0, 0, 0, 0.4);
  --shadow-md: 0 6px 24px rgba(0, 0, 0, 0.5);
  --shadow-lg: 0 12px 40px rgba(0, 0, 0, 0.7);
  --gold-glow: 0 4px 25px rgba(255, 179, 0, 0.18);

  --emerald-light: rgba(46, 125, 50, 0.2);
  --emerald-border: rgba(46, 125, 50, 0.45);
  --ruby-light: rgba(198, 40, 40, 0.2);
  --ruby-border: rgba(198, 40, 40, 0.45);
}

/* ----------------- Global Reset & Base Styles ----------------- */
*, *::before, *::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
  -webkit-tap-highlight-color: transparent;
}

html {
  scroll-behavior: smooth;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

body {
  font-family: var(--font-body);
  background-color: var(--bg-canvas);
  color: var(--text-primary);
  line-height: 1.55;
  min-height: 100vh;
  transition: background-color 0.25s ease, color 0.25s ease;
  overflow-x: hidden;
  padding-bottom: calc(var(--bottom-nav-height) + 24px);
}

@media (min-width: 768px) {
  body {
    padding-bottom: 0;
  }
}

img, svg {
  display: block;
  max-width: 100%;
}

button, input, select {
  font-family: inherit;
  font-size: inherit;
  color: inherit;
  touch-action: manipulation;
}

a {
  color: inherit;
  text-decoration: none;
}

.container {
  width: 100%;
  max-width: var(--container-max);
  margin: 0 auto;
  padding: 0 12px;
}

@media (min-width: 600px) {
  .container {
    padding: 0 16px;
  }
}

/* ----------------- Header & Navigation ----------------- */
.site-header {
  position: sticky;
  top: 0;
  z-index: 1000;
  background: var(--bg-glass);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  border-bottom: 1px solid var(--border-subtle);
  padding: 8px 0;
  transition: all 0.25s ease;
}

.header-inner {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

@media (min-width: 768px) {
  .header-inner {
    flex-direction: row;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
    padding: 4px 0;
  }
}

/* Top bar row on mobile: Brand + Controls */
.header-top-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  width: 100%;
}

.brand-wrapper {
  display: flex;
  align-items: center;
  gap: 8px;
}

.brand-icon {
  width: 36px;
  height: 36px;
  filter: drop-shadow(0 2px 6px rgba(230, 81, 0, 0.25));
  flex-shrink: 0;
}

@media (min-width: 768px) {
  .brand-icon {
    width: 44px;
    height: 44px;
  }
}

.brand-text h1 {
  font-family: var(--font-heading);
  font-size: 1.25rem;
  font-weight: 700;
  color: var(--saffron-primary);
  line-height: 1.1;
  letter-spacing: -0.01em;
}

@media (max-width: 480px) {
  .brand-text h1 {
    font-size: 1.05rem;
  }
  .brand-text span {
    display: none;
  }
  .brand-icon {
    width: 32px;
    height: 32px;
  }
  .header-controls-wrapper {
    gap: 4px;
  }
}

@media (min-width: 768px) {
  .brand-text h1 {
    font-size: 1.45rem;
  }
}

.brand-text span {
  font-size: 0.7rem;
  color: var(--text-muted);
  font-weight: 500;
  display: block;
}

/* Mobile Controls Wrapper */
.header-controls-wrapper {
  display: flex;
  align-items: center;
  gap: 6px;
  flex-shrink: 0;
}

/* Language Toggle Segment */
.lang-toggle-wrapper {
  display: flex;
  background: var(--bg-surface-elevated);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-pill);
  padding: 2px;
  box-shadow: var(--shadow-sm);
}

.lang-btn {
  background: transparent;
  border: none;
  padding: 4px 7px;
  border-radius: var(--radius-pill);
  font-size: 0.74rem;
  font-weight: 600;
  color: var(--text-secondary);
  cursor: pointer;
  transition: all 0.2s ease;
  min-height: 28px;
  display: flex;
  align-items: center;
  justify-content: center;
}

@media (max-width: 480px) {
  .lang-btn {
    padding: 3px 5px;
    font-size: 0.7rem;
  }
  .widget-modal-btn {
    padding: 3px 6px;
    font-size: 0.7rem;
  }
}

@media (min-width: 768px) {
  .lang-btn {
    padding: 5px 12px;
    font-size: 0.82rem;
    min-height: 32px;
  }
}

.lang-btn.active {
  background: var(--saffron-gradient);
  color: #FFFFFF;
  box-shadow: 0 2px 8px rgba(230, 81, 0, 0.35);
}

/* Theme Toggle Button */
.theme-toggle-btn {
  background: var(--bg-surface);
  border: 1px solid var(--border-subtle);
  width: 34px;
  height: 34px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  color: var(--text-secondary);
  transition: all 0.2s ease;
  box-shadow: var(--shadow-sm);
  flex-shrink: 0;
}

@media (min-width: 768px) {
  .theme-toggle-btn {
    width: 38px;
    height: 38px;
  }
}

.theme-toggle-btn:hover {
  border-color: var(--gold-primary);
  color: var(--saffron-primary);
  transform: rotate(15deg);
}

/* Second Row on Mobile: City Pill + Live Time */
.header-sub-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  width: 100%;
}

@media (min-width: 768px) {
  .header-sub-row {
    width: auto;
    gap: 14px;
  }
}

.city-pill-btn {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  background: var(--bg-surface);
  border: 1px solid var(--border-card);
  padding: 6px 12px;
  border-radius: var(--radius-pill);
  font-size: 0.82rem;
  font-weight: 600;
  color: var(--text-primary);
  cursor: pointer;
  box-shadow: var(--shadow-sm);
  transition: all 0.2s ease;
  flex: 1;
  max-width: 220px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

@media (min-width: 768px) {
  .city-pill-btn {
    padding: 7px 14px;
    font-size: 0.88rem;
    flex: initial;
    max-width: none;
  }
}

.city-pill-btn:hover {
  border-color: var(--gold-primary);
  box-shadow: var(--gold-glow);
  transform: translateY(-1px);
}

.city-pin-icon {
  color: var(--saffron-primary);
  flex-shrink: 0;
}

.live-clock-badge {
  font-size: 0.76rem;
  color: var(--text-secondary);
  font-family: var(--font-body);
  text-align: right;
  line-height: 1.2;
  white-space: nowrap;
}

@media (min-width: 768px) {
  .live-clock-badge {
    font-size: 0.82rem;
  }
}

/* ----------------- Live Choghadiya Real-Time Banner ----------------- */
.live-status-ticker {
  background: linear-gradient(90deg, #A83800 0%, #D84315 50%, #A83800 100%);
  color: #FFFFFF;
  padding: 8px 0;
  box-shadow: 0 2px 10px rgba(216, 67, 21, 0.22);
  font-size: 0.84rem;
  font-weight: 600;
  position: relative;
  overflow: hidden;
}

@media (min-width: 768px) {
  .live-status-ticker {
    padding: 10px 0;
    font-size: 0.92rem;
  }
}

.live-status-ticker::after {
  content: '';
  position: absolute;
  top: 0; left: -100%; width: 50%; height: 100%;
  background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.2), transparent);
  animation: shine 4s infinite linear;
}

@keyframes shine {
  0% { left: -100%; }
  100% { left: 200%; }
}

.ticker-content {
  display: flex;
  align-items: center;
  justify-content: center;
  flex-wrap: wrap;
  gap: 6px 10px;
  text-align: center;
}

.status-indicator-dot {
  width: 9px;
  height: 9px;
  background-color: #00E676;
  border-radius: 50%;
  box-shadow: 0 0 8px #00E676;
  animation: pulse-glow 2s infinite ease-in-out;
  display: inline-block;
  flex-shrink: 0;
}

@keyframes pulse-glow {
  0%, 100% { transform: scale(1); opacity: 1; }
  50% { transform: scale(1.35); opacity: 0.7; }
}

.ticker-time-left {
  background: rgba(0, 0, 0, 0.25);
  padding: 2px 8px;
  border-radius: var(--radius-pill);
  font-size: 0.76rem;
  font-family: var(--font-mono);
  border: 1px solid rgba(255, 255, 255, 0.2);
}

/* ----------------- Mobile Segmented View Tabs ----------------- */
.mobile-view-tabs {
  display: flex;
  gap: 6px;
  background: var(--bg-surface);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-pill);
  padding: 4px;
  margin: 12px 0 16px 0;
  box-shadow: var(--shadow-sm);
}

@media (min-width: 900px) {
  .mobile-view-tabs {
    display: none; /* Desktop shows all 3 columns simultaneously */
  }
}

.mobile-tab-btn {
  flex: 1;
  background: transparent;
  border: none;
  padding: 8px 4px;
  border-radius: var(--radius-pill);
  font-size: 0.8rem;
  font-weight: 600;
  color: var(--text-secondary);
  cursor: pointer;
  text-align: center;
  transition: all 0.2s ease;
  white-space: nowrap;
}

.mobile-tab-btn.active {
  background: var(--saffron-gradient);
  color: #FFFFFF;
  box-shadow: 0 2px 8px rgba(230, 81, 0, 0.3);
}

/* ----------------- Hero Dashboard Layout ----------------- */
.hero-dashboard-section {
  padding: 12px 0 24px 0;
}

@media (min-width: 768px) {
  .hero-dashboard-section {
    padding: 24px 0 36px 0;
  }
}

.dashboard-grid {
  display: flex;
  flex-direction: column;
  gap: 16px;
  width: 100%;
}

/* 1. Mobile Phones (< 768px): Segmented view, 1 active card at a time */
@media (max-width: 767px) {
  .dashboard-grid > .card-surface {
    display: none;
    width: 100%;
  }
  .dashboard-grid > .card-surface.mobile-active-card {
    display: block;
    animation: fadeIn 0.25s ease;
  }
  .secondary-details-section {
    display: block;
    width: 100%;
    margin-top: 14px;
    padding: 14px 0 24px 0;
    border-top: 1px solid var(--border-subtle);
  }
}

/* 2. Tablets & Small Laptops (768px to 1199px): 2-Column Balanced Responsive Grid */
@media (min-width: 768px) and (max-width: 1199px) {
  .mobile-view-tabs {
    display: none !important;
  }
  .dashboard-grid {
    display: grid;
    grid-template-columns: minmax(290px, 340px) minmax(0, 1fr);
    gap: 20px;
    align-items: start;
    width: 100%;
  }
  .dashboard-grid > .card-surface {
    display: block !important;
  }
  .panchang-today-card {
    grid-column: 1;
    grid-row: 1;
  }
  .wall-calendar-card {
    grid-column: 2;
    grid-row: 1;
  }
  .secondary-details-section {
    grid-column: 1 / span 2;
    grid-row: 2;
    width: 100%;
    padding: 0;
    border-top: none;
    margin-top: 4px;
  }
  .whatsapp-generator-card {
    grid-column: 1 / span 2;
    grid-row: 3;
    width: 100%;
    margin-top: 8px;
  }
  .wa-content-split {
    display: grid;
    grid-template-columns: 1.1fr 0.9fr;
    gap: 20px;
    align-items: start;
  }
}

/* 3. Full Desktop (>= 1200px): 3-Column Master Grid with Right Sidebar */
@media (min-width: 1200px) {
  .mobile-view-tabs {
    display: none !important;
  }
  .dashboard-grid {
    display: grid;
    grid-template-columns: 320px minmax(0, 1fr) 290px;
    gap: 24px;
    align-items: start;
    width: 100%;
  }
  .dashboard-grid > .card-surface {
    display: block !important;
  }
  .panchang-today-card {
    grid-column: 1;
    grid-row: 1;
  }
  .wall-calendar-card {
    grid-column: 2;
    grid-row: 1;
  }
  .whatsapp-generator-card {
    grid-column: 3;
    grid-row: 1 / span 2;
    position: sticky;
    top: 20px;
  }
  .secondary-details-section {
    grid-column: 1 / span 2;
    grid-row: 2;
    width: 100%;
    padding: 0;
    border-top: none;
    margin-top: 2px;
  }
  .wa-content-split {
    display: flex;
    flex-direction: column;
  }
}

/* ----------------- Shared Card Aesthetic ----------------- */
.card-surface {
  background: var(--bg-surface);
  border: 1px solid var(--border-card);
  border-radius: var(--radius-md);
  box-shadow: var(--shadow-md);
  padding: 14px;
  position: relative;
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}

@media (min-width: 600px) {
  .card-surface {
    border-radius: var(--radius-lg);
    padding: 20px;
  }
}

.card-surface:hover {
  box-shadow: var(--shadow-lg);
}

.card-title-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 12px;
  border-bottom: 1px dashed var(--border-subtle);
  padding-bottom: 10px;
}

@media (min-width: 600px) {
  .card-title-header {
    margin-bottom: 16px;
    padding-bottom: 12px;
  }
}

.card-title-header h2 {
  font-family: var(--font-heading);
  font-size: 1.15rem;
  color: var(--saffron-primary);
  display: flex;
  align-items: center;
  gap: 6px;
}

@media (min-width: 600px) {
  .card-title-header h2 {
    font-size: 1.25rem;
    gap: 8px;
  }
}

.card-subtitle {
  font-size: 0.74rem;
  color: var(--text-muted);
}

/* ----------------- Left Column: Aaj Ka Panchang Card ----------------- */
.panchang-today-card {
  border-top: 4px solid var(--saffron-primary);
}

.panchang-meta-date {
  text-align: center;
  background: var(--gold-light);
  border-radius: var(--radius-sm);
  padding: 8px;
  margin-bottom: 12px;
  border: 1px solid var(--gold-border);
}

@media (min-width: 600px) {
  .panchang-meta-date {
    border-radius: var(--radius-md);
    padding: 10px;
    margin-bottom: 16px;
  }
}

[data-theme="dark"] .panchang-meta-date {
  background: rgba(255, 179, 0, 0.08);
}

.panchang-date-text {
  font-family: var(--font-heading);
  font-size: 1.05rem;
  font-weight: 700;
  color: var(--text-primary);
}

@media (min-width: 600px) {
  .panchang-date-text {
    font-size: 1.15rem;
  }
}

.panchang-sun-row {
  display: flex;
  justify-content: space-around;
  background: var(--bg-canvas);
  border-radius: var(--radius-sm);
  padding: 7px 10px;
  margin-bottom: 12px;
  border: 1px solid var(--border-subtle);
}

@media (min-width: 600px) {
  .panchang-sun-row {
    border-radius: var(--radius-md);
    padding: 8px 12px;
    margin-bottom: 16px;
  }
}

.sun-item {
  display: flex;
  align-items: center;
  gap: 4px;
  font-size: 0.78rem;
  font-weight: 600;
}

@media (min-width: 600px) {
  .sun-item {
    gap: 6px;
    font-size: 0.85rem;
  }
}

.sun-item span {
  color: var(--text-secondary);
}

.panchang-attributes-list {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

@media (min-width: 600px) {
  .panchang-attributes-list {
    gap: 10px;
  }
}

.attr-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 5px 0;
  font-size: 0.82rem;
  border-bottom: 1px solid var(--border-subtle);
}

@media (min-width: 600px) {
  .attr-row {
    padding: 6px 0;
    font-size: 0.88rem;
  }
}

.attr-row:last-child {
  border-bottom: none;
}

.attr-label {
  color: var(--text-secondary);
  font-weight: 500;
  display: flex;
  align-items: center;
  gap: 4px;
  flex-shrink: 0;
}

.attr-value {
  font-weight: 700;
  color: var(--text-primary);
  text-align: right;
  word-break: break-word;
}

.badge-shubh {
  background: var(--emerald-light);
  color: var(--emerald-shubh);
  border: 1px solid var(--emerald-border);
  padding: 2px 7px;
  border-radius: var(--radius-sm);
  font-size: 0.78rem;
  font-weight: 700;
  white-space: nowrap;
}

.badge-ashubh {
  background: var(--ruby-light);
  color: var(--ruby-ashubh);
  border: 1px solid var(--ruby-border);
  padding: 2px 7px;
  border-radius: var(--radius-sm);
  font-size: 0.78rem;
  font-weight: 700;
  white-space: nowrap;
}

/* ----------------- Center Column: Interactive Wall Calendar ----------------- */
.wall-calendar-card {
  border-top: 4px solid var(--gold-primary);
}

.calendar-nav-bar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 12px;
}

.cal-month-title {
  font-family: var(--font-heading);
  font-size: 1.2rem;
  color: var(--text-primary);
  font-weight: 700;
}

@media (min-width: 600px) {
  .cal-month-title {
    font-size: 1.45rem;
  }
}

.cal-nav-btn {
  background: var(--bg-surface-elevated);
  border: 1px solid var(--border-subtle);
  width: 32px;
  height: 32px;
  border-radius: var(--radius-sm);
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: all 0.2s ease;
  font-size: 0.8rem;
}

@media (min-width: 600px) {
  .cal-nav-btn {
    width: 36px;
    height: 36px;
    font-size: 0.9rem;
  }
}

.cal-nav-btn:hover {
  background: var(--gold-light);
  border-color: var(--gold-primary);
  color: var(--saffron-primary);
}

/* Calendar Grid Header */
.calendar-grid-header {
  display: grid;
  grid-template-columns: repeat(7, minmax(0, 1fr));
  width: 100%;
  text-align: center;
  font-weight: 700;
  font-size: 0.76rem;
  color: var(--text-muted);
  padding-bottom: 6px;
  border-bottom: 1px solid var(--border-subtle);
}

@media (min-width: 600px) {
  .calendar-grid-header {
    font-size: 0.84rem;
    padding-bottom: 8px;
  }
}

.calendar-grid-header .sunday-col {
  color: var(--crimson-sacred);
}

/* Calendar Grid Days (Mobile Optimized) */
.calendar-grid-days {
  display: grid;
  grid-template-columns: repeat(7, minmax(0, 1fr));
  width: 100%;
  gap: 3px;
  margin-top: 6px;
}

@media (min-width: 600px) {
  .calendar-grid-days {
    gap: 5px;
    margin-top: 8px;
  }
}

.cal-day-cell {
  aspect-ratio: 1 / 1;
  min-height: 40px;
  min-width: 0;
  overflow: hidden;
  background: var(--bg-canvas);
  border: 1px solid var(--border-subtle);
  border-radius: 6px;
  padding: 2px 2px;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  cursor: pointer;
  position: relative;
  transition: all 0.15s ease;
  user-select: none;
  box-sizing: border-box;
}

@media (max-width: 480px) {
  .cal-day-cell {
    min-height: 36px;
    padding: 1px 2px;
    border-radius: 4px;
  }
}

@media (min-width: 600px) {
  .cal-day-cell {
    min-height: 52px;
    border-radius: var(--radius-sm);
    padding: 4px 6px;
  }
}

.cal-day-cell:hover, .cal-day-cell:active {
  background: var(--gold-light);
  border-color: var(--gold-primary);
  transform: scale(1.04);
  box-shadow: var(--shadow-sm);
  z-index: 2;
}

[data-theme="dark"] .cal-day-cell:hover, [data-theme="dark"] .cal-day-cell:active {
  background: rgba(255, 179, 0, 0.18);
}

.cal-day-cell.other-month {
  opacity: 0.3;
  background: transparent;
  cursor: default;
}

.cal-day-cell.is-today {
  background: #FFF3E0;
  border: 2px solid var(--saffron-primary);
  box-shadow: 0 0 10px rgba(230, 81, 0, 0.25);
}

[data-theme="dark"] .cal-day-cell.is-today {
  background: rgba(230, 81, 0, 0.25);
  border-color: #FF9800;
}

.cal-day-cell.is-festival {
  border-bottom: 2px solid var(--gold-accent);
}

@media (min-width: 600px) {
  .cal-day-cell.is-festival {
    border-bottom-width: 3px;
  }
}

.day-number-row {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  width: 100%;
  min-width: 0;
}

.day-gregorian-num {
  font-weight: 700;
  font-size: 0.76rem;
  color: var(--text-primary);
  line-height: 1;
  flex-shrink: 0;
}

@media (max-width: 480px) {
  .day-gregorian-num {
    font-size: 0.68rem;
  }
}

@media (min-width: 600px) {
  .day-gregorian-num {
    font-size: 0.95rem;
  }
}

.day-tithi-short {
  font-size: 0.5rem;
  color: var(--text-muted);
  font-weight: 600;
  line-height: 1;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  max-width: 58%;
  text-align: right;
  flex-shrink: 1;
}

@media (max-width: 480px) {
  .day-tithi-short {
    font-size: 0.42rem;
    max-width: 52%;
  }
}

@media (min-width: 600px) {
  .day-tithi-short {
    font-size: 0.65rem;
  }
}

.day-indicators-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  width: 100%;
  min-width: 0;
  gap: 1px;
}

.moon-icon-micro {
  font-size: 0.62rem;
  line-height: 1;
}

@media (min-width: 600px) {
  .moon-icon-micro {
    font-size: 0.72rem;
  }
}

.festival-diya-icon {
  font-size: 0.65rem;
  line-height: 1;
}

@media (min-width: 600px) {
  .festival-diya-icon {
    font-size: 0.8rem;
  }
}

/* Special Spiritual Days Cell Styling */
.cal-day-cell.is-ekadashi {
  background: rgba(230, 81, 0, 0.08);
  border-color: rgba(230, 81, 0, 0.35);
}
.cal-day-cell.is-purnima {
  background: rgba(255, 179, 0, 0.12);
  border-color: rgba(255, 179, 0, 0.45);
}
.cal-day-cell.is-amavasya {
  background: rgba(94, 53, 177, 0.08);
  border-color: rgba(94, 53, 177, 0.35);
}

[data-theme="dark"] .cal-day-cell.is-ekadashi {
  background: rgba(230, 81, 0, 0.18);
  border-color: rgba(255, 152, 0, 0.5);
}
[data-theme="dark"] .cal-day-cell.is-purnima {
  background: rgba(255, 179, 0, 0.18);
  border-color: rgba(255, 193, 7, 0.5);
}
[data-theme="dark"] .cal-day-cell.is-amavasya {
  background: rgba(126, 87, 194, 0.2);
  border-color: rgba(179, 157, 219, 0.5);
}

.day-fest-name {
  font-size: 0.52rem;
  font-weight: 700;
  color: #C62828;
  line-height: 1.1;
  text-align: center;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  width: 100%;
  margin: 1px 0;
  padding: 1px 2px;
  background: rgba(198, 40, 40, 0.08);
  border-radius: 2px;
}
.day-fest-name.fest-vrat {
  color: #E65100;
  background: rgba(230, 81, 0, 0.1);
}
.day-fest-name.fest-purnima {
  color: #B78103;
  background: rgba(255, 179, 0, 0.15);
}
.day-fest-name.fest-amavasya {
  color: #4A148C;
  background: rgba(74, 20, 140, 0.08);
}

[data-theme="dark"] .day-fest-name {
  color: #FF8A80;
  background: rgba(255, 82, 82, 0.18);
}
[data-theme="dark"] .day-fest-name.fest-vrat {
  color: #FFB74D;
  background: rgba(255, 152, 0, 0.2);
}
[data-theme="dark"] .day-fest-name.fest-purnima {
  color: #FFE082;
  background: rgba(255, 213, 79, 0.2);
}
[data-theme="dark"] .day-fest-name.fest-amavasya {
  color: #CE93D8;
  background: rgba(171, 71, 188, 0.2);
}

@media (min-width: 600px) {
  .day-fest-name {
    font-size: 0.6rem;
    padding: 2px 3px;
  }
}

/* ==================== CALENDAR MONTHLY DETAILS (SCREEN & RESPONSIVE) ==================== */
.calendar-monthly-details {
  margin-top: 14px;
  padding-top: 14px;
  border-top: 1px dashed var(--border-gold);
}

.cal-details-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 12px;
}

@media (min-width: 768px) {
  .cal-details-grid {
    grid-template-columns: 1.15fr 1fr 0.95fr;
    gap: 10px;
  }
}

.cal-detail-panel {
  background: var(--bg-canvas);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-sm);
  padding: 8px 10px;
  display: flex;
  flex-direction: column;
}

.panel-header {
  display: flex;
  align-items: center;
  gap: 6px;
  padding-bottom: 6px;
  margin-bottom: 6px;
  border-bottom: 1px solid var(--border-subtle);
}

.panel-header h3 {
  font-size: 0.82rem;
  font-weight: 700;
  color: var(--gold-light);
  margin: 0;
}

.cal-fest-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 0.72rem;
}

.cal-fest-table th {
  background: rgba(243, 186, 69, 0.08);
  color: var(--text-muted);
  font-weight: 700;
  text-align: left;
  padding: 3px 5px;
  font-size: 0.68rem;
  border-bottom: 1px solid var(--border-subtle);
}

.cal-fest-table td {
  padding: 3px 5px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.04);
  color: var(--text-primary);
}

.cal-fest-table tr:last-child td {
  border-bottom: none;
}

.cal-fest-table .col-date {
  font-weight: 700;
  color: var(--saffron-primary);
  white-space: nowrap;
}

.cal-fest-table .col-day {
  color: var(--text-muted);
  white-space: nowrap;
}

.cal-fest-table .col-title {
  font-weight: 600;
}

.row-festival .col-title {
  color: #C62828;
  font-weight: 700;
}

[data-theme="dark"] .row-festival .col-title {
  color: #FF8A80;
}

.row-ekadashi .col-title {
  color: #E65100;
  font-weight: 700;
}

[data-theme="dark"] .row-ekadashi .col-title {
  color: #FFB74D;
}

.table-rahu td.rahu-val {
  color: #D32F2F;
  font-weight: 600;
}

.table-rahu td.shubh-val {
  color: #2E7D32;
  font-weight: 600;
}

[data-theme="dark"] .table-rahu td.rahu-val {
  color: #FF5252;
}

[data-theme="dark"] .table-rahu td.shubh-val {
  color: #69F0AE;
}

.abhijit-badge-bar {
  margin-top: 6px;
  padding: 4px 6px;
  background: rgba(46, 125, 50, 0.1);
  border: 1px solid rgba(46, 125, 50, 0.3);
  border-radius: 4px;
  font-size: 0.68rem;
  color: #2E7D32;
  text-align: center;
}

[data-theme="dark"] .abhijit-badge-bar {
  color: #69F0AE;
  background: rgba(46, 125, 50, 0.2);
}

.fest-table-wrap {
  max-height: 220px;
  overflow-y: auto;
}

.yogas-content {
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.yoga-card-item {
  background: rgba(255, 255, 255, 0.02);
  border: 1px solid var(--border-subtle);
  border-radius: 4px;
  padding: 5px 6px;
}

.yoga-badge-title {
  font-size: 0.72rem;
  font-weight: 700;
  color: var(--saffron-primary);
  margin-bottom: 2px;
}

.yoga-dates-text {
  font-size: 0.68rem;
  color: var(--text-secondary);
  line-height: 1.3;
}

.vedic-shloka-strip {
  margin-top: 10px;
  padding: 6px 10px;
  background: rgba(243, 186, 69, 0.08);
  border: 1px dashed var(--border-gold);
  border-radius: 6px;
  text-align: center;
  font-size: 0.75rem;
  color: var(--gold-light);
}

/* Calendar Bottom Controls */
.calendar-bottom-controls {
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 12px;
  padding-top: 10px;
  border-top: 1px dashed var(--border-subtle);
}

.btn-calendar-action {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  background: var(--bg-surface-elevated);
  border: 1px solid var(--border-card);
  padding: 7px 12px;
  border-radius: var(--radius-sm);
  font-size: 0.8rem;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.2s ease;
  min-height: 36px;
}

@media (min-width: 600px) {
  .btn-calendar-action {
    padding: 8px 14px;
    font-size: 0.85rem;
  }
}

.btn-calendar-action:hover {
  background: var(--gold-light);
  border-color: var(--gold-primary);
  color: var(--saffron-primary);
}

/* ----------------- Right Column: Viral WhatsApp Card & Utilities ----------------- */
.whatsapp-generator-card {
  border-top: 4px solid #25D366;
}

.whatsapp-preview-box {
  background: linear-gradient(135deg, #1C2430 0%, #0F141C 100%);
  border-radius: var(--radius-md);
  padding: 14px;
  color: #FFFFFF;
  text-align: center;
  position: relative;
  overflow: hidden;
  border: 1px solid rgba(255, 215, 0, 0.3);
  margin-bottom: 12px;
}

.wa-card-deity-symbol {
  font-size: 1.8rem;
  margin-bottom: 2px;
  filter: drop-shadow(0 0 8px rgba(255, 215, 0, 0.6));
}

.wa-card-greeting {
  font-family: var(--font-heading);
  font-size: 1rem;
  color: #FFD54F;
  margin-bottom: 4px;
}

.wa-card-shloka {
  font-size: 0.74rem;
  font-style: italic;
  opacity: 0.9;
  line-height: 1.35;
  margin-bottom: 8px;
}

.wa-card-details {
  background: rgba(255, 255, 255, 0.08);
  border-radius: var(--radius-sm);
  padding: 5px 8px;
  font-size: 0.72rem;
}

.btn-whatsapp-share {
  width: 100%;
  background: linear-gradient(135deg, #25D366 0%, #128C7E 100%);
  color: #FFFFFF;
  border: none;
  padding: 11px 16px;
  border-radius: var(--radius-md);
  font-weight: 700;
  font-size: 0.9rem;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  cursor: pointer;
  box-shadow: 0 4px 12px rgba(37, 211, 102, 0.3);
  transition: all 0.2s ease;
  min-height: 44px;
}

.btn-whatsapp-share:hover, .btn-whatsapp-share:active {
  transform: translateY(-2px);
  box-shadow: 0 6px 18px rgba(37, 211, 102, 0.45);
}

/* Quick Navigation Links List */
.quick-utilities-list {
  display: flex;
  flex-direction: column;
  gap: 6px;
  margin-top: 14px;
}

.util-link-item {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 9px 12px;
  background: var(--bg-surface-elevated);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-sm);
  font-size: 0.84rem;
  font-weight: 600;
  color: var(--text-primary);
  transition: all 0.2s ease;
  min-height: 40px;
}

.util-link-item:hover, .util-link-item:active {
  background: var(--gold-light);
  border-color: var(--gold-primary);
  color: var(--saffron-primary);
  transform: translateX(3px);
}

[data-theme="dark"] .util-link-item:hover, [data-theme="dark"] .util-link-item:active {
  background: rgba(255, 179, 0, 0.12);
}

/* Reserved Ad Container (Guaranteeing CLS = 0) */
.ad-slot-reserved {
  min-height: 250px;
  background: var(--bg-canvas);
  border: 1px dashed var(--border-subtle);
  border-radius: var(--radius-md);
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  color: var(--text-muted);
  font-size: 0.78rem;
  margin-top: 16px;
  text-align: center;
  padding: 12px;
}

/* ----------------- Tabs Navigation & Secondary Sections ----------------- */
.secondary-details-section {
  padding: 20px 0 40px 0;
  border-top: 1px solid var(--border-subtle);
}

.nav-tabs-wrapper {
  display: flex;
  gap: 6px;
  overflow-x: auto;
  padding-bottom: 8px;
  margin-bottom: 18px;
  -webkit-overflow-scrolling: touch;
  scrollbar-width: none;
}

.nav-tabs-wrapper::-webkit-scrollbar {
  display: none;
}

.tab-pill-btn {
  background: var(--bg-surface);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-pill);
  padding: 7px 14px;
  font-size: 0.82rem;
  font-weight: 600;
  color: var(--text-secondary);
  cursor: pointer;
  white-space: nowrap;
  transition: all 0.2s ease;
  min-height: 38px;
  flex-shrink: 0;
}

.tab-pill-btn:hover {
  border-color: var(--gold-primary);
  color: var(--saffron-primary);
}

.tab-pill-btn.active {
  background: var(--saffron-gradient);
  color: #FFFFFF;
  border-color: transparent;
  box-shadow: 0 4px 12px rgba(230, 81, 0, 0.3);
}

.tab-panel {
  display: none;
}

.tab-panel.active {
  display: block;
  animation: fadeIn 0.3s ease;
}

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

/* ----------------- Choghadiya Table ----------------- */
.choghadiya-table-wrapper {
  overflow-x: auto;
  -webkit-overflow-scrolling: touch;
}

.choghadiya-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 0.84rem;
}

@media (min-width: 600px) {
  .choghadiya-table {
    font-size: 0.9rem;
  }
}

.choghadiya-table th, .choghadiya-table td {
  padding: 8px 10px;
  text-align: left;
  border-bottom: 1px solid var(--border-subtle);
  white-space: nowrap;
}

@media (min-width: 600px) {
  .choghadiya-table th, .choghadiya-table td {
    padding: 10px 14px;
    white-space: normal;
  }
}

.choghadiya-table th {
  background: var(--bg-canvas);
  color: var(--text-muted);
  font-weight: 700;
  font-size: 0.76rem;
  text-transform: uppercase;
  letter-spacing: 0.05em;
}

/* ----------------- Shubh Muhurat Cards & Grid ----------------- */
.muhurat-cards-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 12px;
}

@media (min-width: 600px) {
  .muhurat-cards-grid {
    grid-template-columns: repeat(auto-fill, minmax(260px, 1fr));
    gap: 16px;
  }
}

.muhurat-mini-card {
  background: var(--bg-surface);
  border: 1px solid var(--border-card);
  border-radius: var(--radius-md);
  padding: 14px;
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.muhurat-mini-card h4 {
  color: var(--saffron-primary);
  font-size: 1rem;
}

/* ----------------- Bhakti & Chalisa Audio Section ----------------- */
.bhakti-player-box {
  background: var(--bg-surface);
  border: 1px solid var(--gold-border);
  border-radius: var(--radius-lg);
  padding: 16px;
  box-shadow: var(--shadow-md);
}

@media (min-width: 600px) {
  .bhakti-player-box {
    padding: 24px;
  }
}

.chalisa-lyrics-container {
  max-height: 280px;
  overflow-y: auto;
  padding: 12px;
  background: var(--bg-canvas);
  border-radius: var(--radius-md);
  font-size: 0.95rem;
  line-height: 1.7;
  text-align: center;
}

@media (min-width: 600px) {
  .chalisa-lyrics-container {
    max-height: 320px;
    font-size: 1.05rem;
    line-height: 1.8;
    padding: 16px;
  }
}

/* ----------------- SEO FAQ Accordion & Footer ----------------- */
.faq-section {
  padding: 28px 0;
  background: var(--bg-surface);
  border-top: 1px solid var(--border-subtle);
}

.faq-grid {
  display: flex;
  flex-direction: column;
  gap: 10px;
  max-width: 850px;
  margin: 16px auto 0 auto;
}

.faq-item {
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-sm);
  background: var(--bg-canvas);
  overflow: hidden;
}

.faq-question {
  width: 100%;
  padding: 12px 14px;
  background: transparent;
  border: none;
  text-align: left;
  font-weight: 700;
  font-size: 0.92rem;
  color: var(--text-primary);
  display: flex;
  justify-content: space-between;
  align-items: center;
  cursor: pointer;
  min-height: 44px;
}

.faq-answer {
  padding: 0 14px 12px 14px;
  font-size: 0.85rem;
  color: var(--text-secondary);
  display: none;
  line-height: 1.55;
}

.faq-item.open .faq-answer {
  display: block;
}

/* Footer */
.site-footer {
  background: var(--bg-surface-elevated);
  border-top: 1px solid var(--border-subtle);
  padding: 28px 0 20px 0;
  font-size: 0.82rem;
  color: var(--text-secondary);
}

.footer-columns-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 20px;
  margin-bottom: 20px;
}

@media (min-width: 600px) {
  .footer-columns-grid {
    grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
    gap: 24px;
  }
}

.footer-col h5 {
  color: var(--saffron-primary);
  font-size: 0.92rem;
  margin-bottom: 10px;
  font-weight: 700;
}

.footer-col ul {
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.footer-col a:hover {
  color: var(--saffron-primary);
}

.footer-bottom-bar {
  text-align: center;
  border-top: 1px solid var(--border-subtle);
  padding-top: 14px;
  font-size: 0.76rem;
  color: var(--text-muted);
}

/* ----------------- Mobile Bottom App Navigation Bar ----------------- */
.mobile-bottom-nav {
  position: fixed;
  bottom: 0;
  left: 0;
  right: 0;
  height: var(--bottom-nav-height);
  background: var(--bg-surface);
  border-top: 1px solid var(--border-card);
  display: flex;
  align-items: center;
  justify-content: space-around;
  z-index: 1500;
  box-shadow: 0 -4px 16px rgba(0, 0, 0, 0.08);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
}

@media (min-width: 768px) {
  .mobile-bottom-nav {
    display: none; /* Hide on Tablet and Desktop */
  }
}

.nav-bottom-item {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  flex: 1;
  height: 100%;
  color: var(--text-muted);
  font-size: 0.7rem;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.2s ease;
  border: none;
  background: transparent;
  padding: 4px 0;
}

.nav-bottom-item .nav-icon {
  font-size: 1.25rem;
  margin-bottom: 2px;
  line-height: 1;
}

.nav-bottom-item.active, .nav-bottom-item:active {
  color: var(--saffron-primary);
}

.nav-bottom-item.active .nav-icon {
  transform: translateY(-2px);
}

/* ----------------- Mobile Bottom-Sheet Modals ----------------- */
.modal-overlay {
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, 0.65);
  backdrop-filter: blur(4px);
  z-index: 2000;
  display: none;
  align-items: flex-end; /* Bottom sheet on mobile */
  justify-content: center;
  padding: 0;
}

@media (min-width: 600px) {
  .modal-overlay {
    align-items: center;
    padding: 16px;
  }
}

.modal-overlay.active {
  display: flex;
  animation: fadeIn 0.2s ease;
}

.modal-content-box {
  background: var(--bg-surface);
  border: 1px solid var(--border-card);
  border-radius: 20px 20px 0 0; /* Bottom Sheet */
  width: 100%;
  max-width: 100%;
  padding: 16px 16px 28px 16px;
  box-shadow: var(--shadow-lg);
  max-height: 85vh;
  overflow-y: auto;
  -webkit-overflow-scrolling: touch;
  animation: slideUp 0.25s cubic-bezier(0.16, 1, 0.3, 1);
}

@media (min-width: 600px) {
  .modal-content-box {
    border-radius: var(--radius-lg);
    max-width: 520px;
    padding: 24px;
    max-height: 90vh;
    animation: fadeIn 0.2s ease;
  }
}

@keyframes slideUp {
  from { transform: translateY(100%); }
  to { transform: translateY(0); }
}

.bottom-sheet-handle {
  width: 40px;
  height: 4px;
  background: var(--border-subtle);
  border-radius: var(--radius-pill);
  margin: 0 auto 12px auto;
  display: block;
}

@media (min-width: 600px) {
  .bottom-sheet-handle {
    display: none;
  }
}

.modal-header-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  border-bottom: 1px solid var(--border-subtle);
  padding-bottom: 10px;
  margin-bottom: 14px;
}

.btn-close-modal {
  background: transparent;
  border: none;
  font-size: 1.4rem;
  cursor: pointer;
  color: var(--text-muted);
  width: 36px;
  height: 36px;
  display: flex;
  align-items: center;
  justify-content: center;
}

/* ==================== 15. EMBED WIDGET & PRINT STYLES ==================== */
.widget-modal-btn {
  background: rgba(255, 179, 0, 0.15);
  border: 1px solid var(--border-subtle);
  color: var(--text-primary);
  padding: 4px 10px;
  border-radius: var(--radius-pill);
  font-size: 0.76rem;
  cursor: pointer;
  font-weight: 600;
  display: flex;
  align-items: center;
  gap: 4px;
  transition: all 0.2s ease;
}
.widget-modal-btn:hover {
  background: rgba(255, 179, 0, 0.25);
  transform: translateY(-1px);
}

.print-cal-btn {
  background: rgba(255, 179, 0, 0.12) !important;
  border: 1px solid var(--border-subtle) !important;
  color: var(--text-primary) !important;
  font-size: 0.78rem !important;
  width: auto !important;
  padding: 0 10px !important;
  border-radius: var(--radius-pill) !important;
}

.print-only-header,
.print-only-footer {
  display: none;
}

/* ==================== 16. PRINT STYLES: CRISP 1-PAGE A4 MONTHLY WALL CALENDAR ==================== */
@media print {
  @page {
    size: A4 portrait;
    margin: 8mm 10mm;
  }

  *, *::before, *::after {
    background: transparent !important;
    box-shadow: none !important;
    text-shadow: none !important;
  }

  html, body {
    background: #ffffff !important;
    color: #000000 !important;
    font-size: 10pt !important;
    padding: 0 !important;
    margin: 0 !important;
    width: 100% !important;
    max-width: 100% !important;
    height: auto !important;
    min-height: auto !important;
    overflow: visible !important;
  }

  /* 1. HIDE ABSOLUTELY EVERYTHING EXCEPT THE WALL CALENDAR */
  .site-header,
  .live-status-ticker,
  .mobile-view-tabs,
  .panchang-today-card,
  .whatsapp-generator-card,
  .secondary-details-section,
  .faq-section,
  .site-footer,
  .mobile-bottom-nav,
  .modal-overlay,
  .cal-nav-btn,
  .print-cal-btn,
  #btn-print-calendar,
  .widget-modal-btn,
  #city-modal,
  #day-detail-modal {
    display: none !important;
    visibility: hidden !important;
    height: 0 !important;
    margin: 0 !important;
    padding: 0 !important;
  }

  /* 2. RESET PARENT CONTAINERS SO THEY DON'T OCCUPY ANY EXTRA SPACE */
  .hero-dashboard-section,
  .hero-dashboard-section .container,
  .dashboard-grid {
    display: block !important;
    width: 100% !important;
    max-width: 100% !important;
    margin: 0 !important;
    padding: 0 !important;
    border: none !important;
    background: transparent !important;
  }

  /* 3. SHOW ONLY THE WALL CALENDAR AS FULL-PAGE PRINTABLE CALENDAR */
  #card-wall-calendar,
  .wall-calendar-card {
    display: block !important;
    visibility: visible !important;
    width: 100% !important;
    max-width: 100% !important;
    margin: 0 auto !important;
    padding: 10px 14px !important;
    border: 3px solid #D84315 !important;
    border-radius: 10px !important;
    background: #ffffff !important;
    box-shadow: none !important;
    page-break-inside: avoid !important;
    break-inside: avoid !important;
    page-break-after: avoid !important;
    page-break-before: avoid !important;
  }

  /* 4. PRINTABLE BRAND HEADER */
  .print-only-header {
    display: block !important;
    text-align: center !important;
    margin-bottom: 8px !important;
    border-bottom: 2px solid #D84315 !important;
    padding-bottom: 6px !important;
  }

  /* 5. MONTH & YEAR HEADING */
  .calendar-nav-bar {
    display: flex !important;
    justify-content: center !important;
    align-items: center !important;
    border-bottom: 1px solid #D84315 !important;
    padding-bottom: 6px !important;
    margin-bottom: 8px !important;
    text-align: center !important;
  }
  .cal-month-title {
    font-size: 1.8rem !important;
    color: #B71C1C !important;
    font-weight: 800 !important;
    font-family: 'Rozha One', serif !important;
  }

  /* 6. WEEKDAY HEADERS */
  .calendar-grid-header {
    display: grid !important;
    grid-template-columns: repeat(7, 1fr) !important;
    background: #FFF3E0 !important;
    border: 1px solid #D84315 !important;
    border-bottom: 2px solid #D84315 !important;
    color: #000000 !important;
    font-weight: 800 !important;
    font-size: 0.95rem !important;
    padding: 5px 0 !important;
    text-align: center !important;
  }
  .calendar-grid-header .sunday-col {
    color: #C62828 !important;
  }

  /* 7. CALENDAR DAYS GRID (TAILORED FOR EXACT 1-PAGE A4 FIT) */
  .calendar-grid-days {
    display: grid !important;
    grid-template-columns: repeat(7, 1fr) !important;
    gap: 2px !important;
    margin-top: 3px !important;
  }

  .cal-day-cell {
    display: flex !important;
    flex-direction: column !important;
    justify-content: space-between !important;
    min-height: 56px !important;
    max-height: 60px !important;
    border: 1px solid #BBBBBB !important;
    background: #FFFFFF !important;
    padding: 2px 3px !important;
    border-radius: 3px !important;
    page-break-inside: avoid !important;
    break-inside: avoid !important;
  }

  .cal-day-cell.is-today {
    background: #FFF8E1 !important;
    border: 2px solid #E65100 !important;
  }

  .cal-day-cell.is-festival {
    border-bottom: 3px solid #D84315 !important;
    background: #FFFDE7 !important;
  }

  .cal-day-cell.is-ekadashi {
    background: #FFF8E1 !important;
    border: 1.5px solid #FF9800 !important;
  }

  .cal-day-cell.is-purnima {
    background: #FFFDE7 !important;
    border: 1.5px solid #FBC02D !important;
  }

  .cal-day-cell.is-amavasya {
    background: #F3E5F5 !important;
    border: 1.5px solid #AB47BC !important;
  }

  .cal-day-cell.other-month {
    opacity: 0.25 !important;
    border-color: #E0E0E0 !important;
  }

  .day-number-row {
    display: flex !important;
    justify-content: space-between !important;
    align-items: flex-start !important;
    width: 100% !important;
  }

  .day-gregorian-num {
    font-size: 0.95rem !important;
    font-weight: 800 !important;
    color: #000000 !important;
    line-height: 1 !important;
  }

  .day-tithi-short {
    font-size: 0.62rem !important;
    font-weight: 700 !important;
    color: #B71C1C !important;
    max-width: 65% !important;
    line-height: 1 !important;
  }

  .day-fest-name {
    display: block !important;
    font-size: 0.5rem !important;
    font-weight: 800 !important;
    color: #B71C1C !important;
    background: #FFEBEE !important;
    border: 1px solid #FFCDD2 !important;
    border-radius: 2px !important;
    padding: 1px 2px !important;
    text-align: center !important;
    white-space: nowrap !important;
    overflow: hidden !important;
    text-overflow: ellipsis !important;
    margin: 1px 0 !important;
    line-height: 1.1 !important;
  }

  .day-fest-name.fest-vrat {
    color: #E65100 !important;
    background: #FFF3E0 !important;
    border-color: #FFE0B2 !important;
  }

  .day-fest-name.fest-purnima {
    color: #E65100 !important;
    background: #FFFDE7 !important;
    border-color: #FFF59D !important;
  }

  .day-fest-name.fest-amavasya {
    color: #4A148C !important;
    background: #EDE7F6 !important;
    border-color: #D1C4E9 !important;
  }

  .day-indicators-row {
    display: flex !important;
    justify-content: space-between !important;
    align-items: center !important;
    width: 100% !important;
    font-size: 0.75rem !important;
  }

  /* 8. BOTTOM CONTROLS & LEGEND */
  .calendar-bottom-controls {
    display: flex !important;
    justify-content: space-between !important;
    align-items: center !important;
    margin-top: 4px !important;
    padding-top: 4px !important;
    border-top: 1px dashed #D84315 !important;
    font-size: 0.72rem !important;
    font-weight: 600 !important;
  }

  /* 9. PRINTABLE MONTHLY DETAILS (FESTIVALS, RAHU KAAL, YOGAS) */
  .calendar-monthly-details {
    display: block !important;
    margin-top: 4px !important;
    padding-top: 4px !important;
    border-top: 1.5px dashed #D84315 !important;
    page-break-inside: avoid !important;
    break-inside: avoid !important;
  }

  .cal-details-grid {
    display: grid !important;
    grid-template-columns: 1.25fr 1fr 1fr !important;
    gap: 5px !important;
    align-items: start !important;
  }

  .cal-detail-panel {
    border: 1.5px solid #D84315 !important;
    border-radius: 4px !important;
    padding: 3px 5px !important;
    background: #FFFFFF !important;
    page-break-inside: avoid !important;
    break-inside: avoid !important;
  }

  .panel-header {
    display: flex !important;
    align-items: center !important;
    gap: 4px !important;
    border-bottom: 1.5px solid #D84315 !important;
    padding-bottom: 2px !important;
    margin-bottom: 3px !important;
  }

  .panel-header .panel-icon {
    font-size: 0.7rem !important;
  }

  .panel-header h3 {
    font-size: 0.7rem !important;
    font-weight: 800 !important;
    color: #B71C1C !important;
    margin: 0 !important;
  }

  .cal-fest-table {
    width: 100% !important;
    border-collapse: collapse !important;
    font-size: 0.55rem !important;
    line-height: 1.15 !important;
  }

  .cal-fest-table th {
    background: #FFF3E0 !important;
    color: #000000 !important;
    font-weight: 800 !important;
    font-size: 0.55rem !important;
    padding: 1.5px 2px !important;
    border-bottom: 1px solid #D84315 !important;
    text-align: left !important;
  }

  .cal-fest-table td {
    padding: 1.2px 2px !important;
    border-bottom: 1px solid #EEEEEE !important;
    color: #000000 !important;
    font-size: 0.55rem !important;
  }

  .cal-fest-table .col-date {
    font-weight: 800 !important;
    color: #D84315 !important;
    white-space: nowrap !important;
  }

  .cal-fest-table .col-day {
    color: #555555 !important;
    white-space: nowrap !important;
  }

  .cal-fest-table .col-title {
    font-weight: 600 !important;
    color: #000000 !important;
  }

  .row-festival .col-title {
    color: #C62828 !important;
    font-weight: 800 !important;
  }

  .row-ekadashi .col-title {
    color: #E65100 !important;
    font-weight: 800 !important;
  }

  .table-rahu td.rahu-val {
    color: #C62828 !important;
    font-weight: 700 !important;
  }

  .table-rahu td.shubh-val {
    color: #2E7D32 !important;
    font-weight: 700 !important;
  }

  .abhijit-badge-bar {
    margin-top: 3px !important;
    padding: 1.5px 3px !important;
    background: #E8F5E9 !important;
    border: 1px solid #2E7D32 !important;
    border-radius: 3px !important;
    font-size: 0.55rem !important;
    color: #1B5E20 !important;
    text-align: center !important;
    font-weight: 700 !important;
  }

  .fest-table-wrap {
    max-height: none !important;
    overflow: visible !important;
  }

  .yogas-content {
    display: flex !important;
    flex-direction: column !important;
    gap: 2px !important;
  }

  .yoga-card-item {
    border: 1px solid #E0E0E0 !important;
    border-radius: 3px !important;
    padding: 2px 3px !important;
    background: #FAFAFA !important;
  }

  .yoga-badge-title {
    font-size: 0.58rem !important;
    font-weight: 800 !important;
    color: #D84315 !important;
    margin-bottom: 1px !important;
  }

  .yoga-dates-text {
    font-size: 0.52rem !important;
    color: #333333 !important;
    line-height: 1.2 !important;
    font-weight: 500 !important;
  }

  .vedic-shloka-strip {
    margin-top: 3px !important;
    padding: 2px 5px !important;
    background: #FFF8E1 !important;
    border: 1px dashed #D84315 !important;
    border-radius: 3px !important;
    text-align: center !important;
    font-size: 0.58rem !important;
    color: #5D4037 !important;
    font-weight: 600 !important;
  }

  .print-only-footer {
    display: block !important;
    text-align: center !important;
    font-size: 0.6rem !important;
    color: #555555 !important;
    margin-top: 3px !important;
    border-top: 1px solid #E0E0E0 !important;
    padding-top: 2px !important;
  }
}

