/* =============================================
   SANTALI CALENDAR — Premium UI
   Design: Organic green, cultural, motion-driven
   ============================================= */

@import url('https://fonts.googleapis.com/css2?family=Playfair+Display:ital,wght@0,400..900;1,400..900&family=Outfit:wght@300..900&family=Inter:wght@300;400;500;600;700&family=Noto+Sans+Ol+Chiki:wght@400;500;600;700&family=Baloo+2:wght@400..800&family=Montserrat:ital,wght@0,100..900;1,100..900&display=swap');

@font-face {
  font-family: 'olciki_okTe_TiTeol';
  src: url('../assets/OlChikiFont/olciki_okTe_TiTeol.ttf') format('truetype');
  font-weight: normal;
  font-style: normal;
  font-display: swap;
}

@font-face {
  font-family: 'olciki_webx_ol';
  src: url('../assets/OlChikiFont/olciki_webx_ol.ttf') format('truetype');
  font-weight: normal;
  font-style: normal;
  font-display: swap;
}

/* ── Design Tokens ── */
:root {
  /* Palette */
  --bg-page:        #f0f7f2;
  --bg-card:        #ffffff;
  --bg-subtle:      #e6f2e9;
  --bg-header:      var(--green-dark-gradient);

  /* Greens */
  --green-deep:     #125e30;
  --green-mid:      #1c8243;
  --green-light:    #2eba5b;
  --green-muted:    #6fba89;
  --green-pale:     #d0ebd9;
  --green-glow:     rgba(46, 186, 91, 0.3);
  --green-gradient: linear-gradient(135deg, var(--green-mid) 0%, var(--green-light) 100%);
  --green-dark-gradient: linear-gradient(135deg, var(--green-deep) 0%, var(--green-mid) 100%);

  /* Text */
  --text-main:      #0f2718;
  --text-sub:       #3a5f46;
  --text-muted:     #6b8f78;
  --text-on-dark:   #ffffff;

  /* Accents */
  --accent:         #1b6b3a;
  --accent-hover:   #0d4a25;
  --gold:           #b7892a;
  --gold-light:     #e8c14d;
  --terracotta:     #c1440e;
  --terracotta-light: #e8814a;
  --ivory:          #f6efdc;

  /* Today */
  --today-bg:       linear-gradient(135deg, #1b6b3a 0%, #0d4a25 100%);
  --today-ring:     rgba(27, 107, 58, 0.3);

  /* Borders & Shadows */
  --border:         #d0e4d7;
  --border-strong:  #a8c9b5;
  --border-color:   var(--border);
  --border-light:   var(--border);

  /* Aliases used by some older components */
  --primary:        var(--green-deep);
  --shadow-xs:      0 1px 3px rgba(13, 74, 37, 0.06);
  --shadow-sm:      0 4px 16px rgba(13, 74, 37, 0.08);
  --shadow-md:      0 8px 30px rgba(13, 74, 37, 0.12);
  --shadow-lg:      0 24px 60px rgba(13, 74, 37, 0.16), 0 8px 20px rgba(13, 74, 37, 0.08);

  /* Timing */
  --ease-smooth:    cubic-bezier(0.4, 0, 0.2, 1);
  --ease-spring:    cubic-bezier(0.34, 1.56, 0.64, 1);
}

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

/* ── Body ── */
body {
  font-family: 'Outfit', sans-serif;
  background-color: #f4fbf6;
  background-image: url('../assets/santali-bg.png');
  background-size: cover;
  background-position: center bottom;
  background-attachment: fixed;
  background-repeat: no-repeat;
  color: var(--text-main);
  display: flex;
  justify-content: center;
  min-height: 100vh;
  padding: 32px 16px 60px;
}

.san-font {
  font-family: 'Noto Sans Ol Chiki', sans-serif;
}

/* ── App Container ── */
.app-container {
  width: 100%;
  max-width: 900px;
  display: flex;
  flex-direction: column;
  gap: 28px;
  margin: auto;
  animation: fadeInUp 0.5s var(--ease-smooth) both;
}

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

.cal-facts-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 14px;
}

.cal-fact-item {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: 14px;
  padding: 16px 12px;
  box-shadow: 0 4px 15px rgba(28, 130, 67, 0.05);
  transition: all 0.3s ease;
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
}

.cal-fact-item:hover {
  transform: translateY(-4px);
  box-shadow: 0 8px 25px rgba(28, 130, 67, 0.12);
  border-color: var(--green-pale);
}

.cal-fact-value {
  font-family: 'Outfit', sans-serif;
  font-weight: 700;
  font-size: 1.05rem;
  color: var(--green-deep);
  line-height: 1.2;
}

.cal-fact-label {
  font-size: 0.75rem;
  color: var(--text-muted);
  margin-top: 4px;
  line-height: 1.3;
}

/* ── Header ── */
.app-header {
  background: var(--bg-header);
  border-radius: 24px;
  padding: 38px 24px 34px;
  text-align: center;
  position: relative;
  overflow: hidden;
  box-shadow: 
    var(--shadow-lg), 
    0 0 0 1px rgba(232, 193, 77, 0.25), 
    inset 0 1px 0 rgba(255, 255, 255, 0.15);
  border: 1px solid rgba(232, 193, 77, 0.15);
}

.app-header::before {
  content: '';
  position: absolute;
  inset: 0;
  background:
    radial-gradient(circle at 50% 50%, rgba(232, 193, 77, 0.08) 0%, transparent 60%),
    radial-gradient(ellipse at 30% 50%, rgba(255,255,255,0.06) 0%, transparent 60%),
    radial-gradient(ellipse at 75% 20%, rgba(184, 233, 122, 0.08) 0%, transparent 50%);
  pointer-events: none;
}

/* decorative leaf dots */
.app-header::after {
  content: '⬤ ⬤ ⬤';
  position: absolute;
  bottom: 14px;
  left: 50%;
  transform: translateX(-50%);
  font-size: 0.35rem;
  letter-spacing: 6px;
  color: rgba(255,255,255,0.3);
}

.main-title {
  font-family: 'Playfair Display', serif;
  font-size: 2.4rem;
  font-weight: 800;
  color: #ffffff;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 8px;
  letter-spacing: 2px;
  text-transform: uppercase;
  text-shadow: 0 2px 14px rgba(0,0,0,0.30);
  position: relative;
  z-index: 1;
}

.english-title {
  display: block;
  text-align: center;
}

.english-title .title-line {
  display: inline;
}

.english-title .title-space {
  display: inline;
}


.san-title {
  font-family: 'Noto Sans Ol Chiki', sans-serif;
  font-size: 1.25rem;
  font-weight: 500;
  color: var(--gold-light);
  letter-spacing: normal;
  text-transform: none;
  text-shadow: 0 1px 8px rgba(0, 0, 0, 0.25);
}

/* Header corner decorations styling */
.header-decor-left {
  position: absolute;
  top: -15px;
  left: -15px;
  width: 130px;
  height: 130px;
  pointer-events: none;
  opacity: 0.85;
  z-index: 0;
}

.header-decor-right {
  position: absolute;
  top: -15px;
  right: -15px;
  width: 130px;
  height: 130px;
  pointer-events: none;
  opacity: 0.85;
  z-index: 0;
}

.title-divider {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 100%;
  max-width: 240px;
  gap: 12px;
  margin: 2px 0;
}

.title-divider-line {
  height: 1px;
  background: linear-gradient(90deg, transparent, rgba(232, 193, 77, 0.3) 50%, transparent);
  flex: 1;
}

.title-divider-star {
  color: var(--gold-light);
  font-size: 0.85rem;
  opacity: 0.85;
  animation: goldPulse 3s infinite ease-in-out;
}

@keyframes goldPulse {
  0%, 100% { opacity: 0.6; transform: scale(1); }
  50% { opacity: 1; transform: scale(1.15); }
}

/* ── Main Layout ── */
.main-layout {
  display: flex;
  flex-direction: row;
  justify-content: center;
  align-items: stretch;
  gap: 24px;
  width: 100%;
}

/* ── Calendar Card ── */
.calendar-card {
  background-color: var(--bg-card);
  border-radius: 24px;
  box-shadow: var(--shadow-lg);
  padding: 70px 22px 28px;
  border: 1px solid var(--border);
  display: flex;
  flex-direction: column;
  flex: 1;
  min-width: 0;
  position: relative;
  overflow: hidden;
  transition: box-shadow 0.3s var(--ease-smooth);
}

/* ── Card Decoration Banner ── */
.card-decoration {
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 62px;
  line-height: 0;
  z-index: 1;
}

/* ── Right Column ── */
.right-column {
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  gap: 16px;
  width: 290px;
}

/* ── Calendar Header ── */
.calendar-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 24px;
}

.nav-btn {
  background: var(--bg-subtle);
  border: 1.5px solid var(--border);
  border-radius: 50%;
  width: 42px;
  height: 42px;
  display: flex;
  justify-content: center;
  align-items: center;
  color: var(--text-sub);
  cursor: pointer;
  transition: all 0.22s var(--ease-smooth);
  flex-shrink: 0;
}

.nav-btn:hover {
  background: var(--green-gradient);
  color: #fff;
  border-color: var(--green-deep);
  transform: scale(1.08);
  box-shadow: 0 4px 14px rgba(13, 74, 37, 0.25);
}

.month-display {
  text-align: center;
  display: flex;
  flex-direction: column;
  align-items: center;
  min-width: 0;
  flex: 1;
  padding: 0 12px;
}

.month-eng {
  font-family: 'Playfair Display', serif;
  font-size: 2.1rem;
  font-weight: 700;
  color: var(--text-main);
  line-height: 1.1;
  letter-spacing: -0.5px;
}

.month-san {
  font-family: 'Noto Sans Ol Chiki', sans-serif;
  font-size: 1rem;
  color: var(--green-mid);
  margin-top: 4px;
  margin-bottom: 5px;
}

.year-display {
  font-size: 1rem;
  color: var(--text-muted);
  font-weight: 600;
  background: var(--bg-subtle);
  padding: 2px 14px;
  border-radius: 20px;
  border: 1px solid var(--border);
  letter-spacing: 1px;
}

.year-select {
  cursor: pointer;
  outline: none;
  font-family: inherit;
  appearance: none;
  -webkit-appearance: none;
  background-image: url("data:image/svg+xml;charset=UTF-8,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 24 24' fill='none' stroke='%236b8f78' stroke-width='3' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpolyline points='6 9 12 15 18 9'%3E%3C/polyline%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 10px center;
  padding-right: 28px !important;
  transition: all 0.2s var(--ease-smooth);
}

.year-select:hover {
  background-color: var(--border);
  border-color: var(--green-muted);
}

.year-select:focus {
  border-color: var(--green-light);
  box-shadow: 0 0 0 3px rgba(45, 147, 83, 0.15);
}

/* ── Calendar Grid ── */
.weekdays {
  display: grid;
  grid-template-columns: repeat(7, 1fr);
  gap: 6px;
  margin-bottom: 12px;
  text-align: center;
  border-bottom: 1.5px solid var(--border);
  padding-bottom: 12px;
}

.weekday {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 2px;
  padding: 4px 0;
}

.weekday-eng {
  font-weight: 700;
  font-size: 0.82rem;
  color: var(--text-main);
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

.weekday-san {
  font-size: 0.72rem;
  color: var(--text-muted);
}

.days {
  display: grid;
  grid-template-columns: repeat(7, 1fr);
  gap: 6px;
  margin-bottom: 20px;
}

/* ── Day Cell ── */
.day-cell {
  aspect-ratio: 1;
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  border-radius: 12px;
  cursor: pointer;
  transition: all 0.2s var(--ease-smooth);
  color: var(--text-main);
  position: relative;
  background-color: transparent;
  border: 1px solid transparent;
  gap: 1px;
  min-width: 0;
}

.day-cell:hover:not(.empty) {
  background-color: var(--green-glow);
  border-color: var(--green-pale);
  transform: translateY(-2px) scale(1.04);
  box-shadow: var(--shadow-sm);
}

.day-cell.empty {
  cursor: default;
}

/* ── Festival Indicator Dot ── */
.festival-dot {
  position: absolute;
  top: 6px;
  right: 6px;
  width: 6px;
  height: 6px;
  background-color: #fbc02d; /* Moon color */
  border-radius: 50%;
  z-index: 10;
  pointer-events: none;
}

.moon-day .festival-dot {
  top: 4px;
  right: 4px;
}

/* ── Day Numbers ── */
.day-eng {
  font-size: 1.5rem;
  font-weight: 600;
  line-height: 1;
}

.day-san {
  font-size: 0.9rem;
  color: var(--text-muted);
  line-height: 1;
}

/* ── TODAY ── */
.day-cell.today {
  background: var(--today-bg);
  color: #fff;
  box-shadow: 0 6px 20px var(--today-ring), 0 2px 6px rgba(0,0,0,0.1);
  transform: scale(1.07);
  border: 2px solid rgba(255,255,255,0.25);
  z-index: 1;
}

.day-cell.today .day-san {
  color: rgba(255, 255, 255, 0.8);
}

.day-cell.today:hover {
  transform: scale(1.07) translateY(-2px);
  box-shadow: 0 10px 28px var(--today-ring);
}

/* ── Sunday column highlight ── */
.weekday:first-child {
  background-color: rgba(192, 57, 43, 0.08);
  border-radius: 8px;
}

.weekday:first-child .weekday-eng,
.weekday:first-child .weekday-san {
  color: #c0392b !important;
}

.day-cell:nth-child(7n + 1):not(.empty) {
  background-color: rgba(192, 57, 43, 0.035);
}

.day-cell:nth-child(7n + 1):not(.empty) .day-eng {
  color: #c0392b;
}

.day-cell:nth-child(7n + 1):hover:not(.empty):not(.today) {
  background-color: rgba(192, 57, 43, 0.09);
  border-color: rgba(192, 57, 43, 0.2);
}

.day-cell.today .day-eng {
  color: #ffffff !important;
}

/* ── MOON DAYS ── */
.day-cell.moon-day {
  justify-content: center;
  padding: 4px;
}

.moon-icon-wrapper {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 3px;
  flex-grow: 1;
  width: 100%;
  margin-top: 1px;
}

.moon-svg {
  width: 30px;
  height: 30px;
  flex-shrink: 0;
  display: block;
  transition: transform 0.2s cubic-bezier(0.4, 0, 0.2, 1);
}

.day-cell:hover .moon-svg {
  transform: scale(1.15);
}

.full-moon-svg {
  filter: drop-shadow(0 0 5px rgba(255, 255, 255, 0.8));
}

.day-cell.full-moon {
  background: var(--today-bg) !important;
  color: #ffffff !important;
  box-shadow: 0 6px 20px var(--today-ring), 0 2px 6px rgba(0,0,0,0.1) !important;
  transform: scale(1.07);
  border: 2px solid rgba(255,255,255,0.25) !important;
  z-index: 1;
}

.day-cell.full-moon .moon-san-center {
  color: #ffffff !important;
}

.day-cell.full-moon .day-eng,
.day-cell.full-moon .day-san {
  color: #ffffff !important;
}

.day-cell.full-moon:hover:not(.empty) {
  transform: scale(1.07) translateY(-2px);
  box-shadow: 0 10px 28px var(--today-ring) !important;
}

.first-moon-svg, .fifth-moon-svg {
  filter: drop-shadow(0 0 2px rgba(251, 192, 45, 0.4));
}

.moon-san-center {
  font-size: 0.65rem;
  color: var(--green-deep);
  font-weight: 600;
  text-align: center;
  line-height: 1.2;
  max-width: 100%;
  word-wrap: break-word;
  white-space: normal;
}

.day-cell.today .moon-san-center {
  color: rgba(255, 255, 255, 0.95);
}

/* Hover dot decoration for normal days */
.day-cell:not(.empty):not(.today):not(.moon-day)::after {
  content: '';
  position: absolute;
  top: 6px;
  right: 6px;
  width: 5px;
  height: 5px;
  border-radius: 50%;
  background: var(--border);
  opacity: 0;
  transition: opacity 0.2s ease;
}

.day-cell:hover:not(.empty):not(.today):not(.moon-day)::after {
  opacity: 1;
  background: var(--accent);
}

/* ── Festival Card ── */
.festival-card {
  background-color: var(--bg-card);
  border-radius: 24px;
  box-shadow: var(--shadow-lg);
  padding: 70px 22px 28px;
  border: 1px solid var(--border);
  display: flex;
  flex-direction: column;
  flex: 1;
  position: relative;
  width: 100%;
  min-height: auto;
  gap: 16px;
  flex-shrink: 0;
  overflow: hidden;
}

.festival-bottom-links {
  display: flex;
  flex-direction: column;
  gap: 12px;
  margin-top: auto;
  padding-top: 18px;
  width: 100%;
}

.festival-card::before {
  content: '';
  position: absolute;
  top: 0; left: 0; right: 0;
  height: 5px;
  background: linear-gradient(90deg, #8bc34a 0%, var(--green-mid) 50%, #8bc34a 100%);
  border-top-left-radius: 24px;
  border-top-right-radius: 24px;
}


.festival-title {
  font-family: 'Playfair Display', serif;
  font-size: 1.25rem;
  font-weight: 700;
  color: var(--text-main);
  display: flex;
  flex-direction: column;
  gap: 3px;
  border-bottom: 1.5px solid var(--border);
  padding-bottom: 12px;
}

.san-fest-title {
  font-family: 'Noto Sans Ol Chiki', sans-serif;
  font-size: 0.95rem;
  font-weight: 400;
  color: var(--green-mid);
}

.festival-list {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.view-all-btn {
  width: 100%;
  padding: 12px;
  margin-top: auto;
  background-color: transparent;
  color: var(--green-deep);
  border: 1.5px solid var(--border-strong);
  border-radius: 16px;
  font-size: 0.9rem;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.2s var(--ease-smooth);
  text-align: center;
}

.view-all-btn:hover {
  background: var(--green-gradient);
  color: #ffffff;
  border-color: var(--green-deep);
  box-shadow: var(--shadow-sm);
  transform: translateY(-2px);
}

.festival-item {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  padding: 10px 12px;
  border-radius: 14px;
  background: var(--bg-subtle);
  border: 1px solid transparent;
  transition: all 0.22s var(--ease-smooth);
  cursor: pointer;
}

.festival-item:hover {
  border-color: var(--border-strong);
  transform: translateY(-2px);
  box-shadow: var(--shadow-sm);
  background: #f0f7f2;
}

/* ── Month Start Highlight Styling ── */
.festival-item.month-start {
  background: linear-gradient(135deg, rgba(183, 137, 42, 0.07) 0%, rgba(183, 137, 42, 0.02) 100%);
  border: 1.5px solid rgba(183, 137, 42, 0.35);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.6);
}

/* Sibling divider line below the month-start section */
.festival-item.month-start + .festival-item:not(.month-start) {
  margin-top: 18px;
  position: relative;
}

.festival-item.month-start + .festival-item:not(.month-start)::before {
  content: '';
  position: absolute;
  top: -14px;
  left: 0;
  right: 0;
  height: 1.5px;
  background-color: var(--border);
  pointer-events: none;
  transition: transform 0.22s var(--ease-smooth);
}

.festival-item.month-start + .festival-item:not(.month-start):hover::before {
  transform: translateY(2px);
}

.festival-item.month-start:hover {
  background: linear-gradient(135deg, rgba(183, 137, 42, 0.14) 0%, rgba(183, 137, 42, 0.05) 100%);
  border-color: rgba(183, 137, 42, 0.65);
  box-shadow: 0 4px 15px rgba(183, 137, 42, 0.16);
  transform: translateY(-2px);
}

.festival-item.month-start .month-start-icon {
  stroke: #b7892a;
  fill: #e8c14d;
  filter: drop-shadow(0 0 3px rgba(232, 193, 77, 0.5));
}

.fest-icon.full-moon-icon {
  stroke: #b7892a;
  stroke-width: 1.3px;
  fill: #e8c14d;
  filter: drop-shadow(0 0 3px rgba(232, 193, 77, 0.45));
}

.fest-icon.full-moon-icon circle {
  fill: #e8c14d;
}

.festival-item.month-start .fest-name-san {
  color: #8c6210;
  font-weight: 700;
}

.festival-item.month-start .fest-date {
  color: #b7892a;
}

.festival-item.month-start .fest-date::before {
  background: #e8c14d;
}

.festival-item-left {
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--gold);
  padding-top: 1px;
  flex-shrink: 0;
}

.fest-icon {
  width: 18px;
  height: 18px;
  stroke: var(--gold);
  stroke-width: 1.3px;
  fill: rgba(183, 137, 42, 0.1);
}

.festival-item-right {
  display: flex;
  flex-direction: column;
  gap: 2px;
  min-width: 0;
}

.fest-name-san {
  font-family: 'Noto Sans Ol Chiki', sans-serif;
  font-size: 1rem;
  font-weight: 600;
  color: var(--text-main);
}

.fest-name-eng {
  font-size: 0.82rem;
  font-weight: 500;
  color: var(--text-sub);
}

.fest-date {
  font-size: 0.72rem;
  color: var(--green-mid);
  font-weight: 600;
  margin-top: 2px;
  display: flex;
  align-items: center;
  gap: 4px;
}

.fest-date::before {
  content: '';
  width: 5px;
  height: 5px;
  border-radius: 50%;
  background: var(--gold-light);
  flex-shrink: 0;
}

/* ── Responsive ── */
@media (max-width: 850px) {
  .main-layout {
    flex-direction: column;
    align-items: center;
  }

  .calendar-card,
  .right-column {
    width: 100% !important;
  }

  .moon-svg {
    width: 18px;
    height: 18px;
  }

  .moon-san-center {
    font-size: 0.5rem;
  }

  .day-cell.moon-day {
    padding: 2px;
  }
}

@media (max-width: 650px) {
  .day-eng {
    font-size: 1.15rem;
  }
}

@media (max-width: 480px) {
  body {
    padding: 16px 10px 40px;
  }

  .app-header {
    padding: 24px 16px 22px;
    border-radius: 18px;
  }

  .main-title {
    font-size: 1.7rem;
    letter-spacing: 1px;
  }

  .english-title .title-line {
    display: block;
  }

  .english-title .title-space {
    display: none;
  }

  .san-title {
    font-size: 0.95rem;
  }

  .calendar-card,
  .festival-card {
    padding: 70px 12px 18px;
    border-radius: 18px;
  }

  .month-eng {
    font-size: 1.6rem;
  }

  .day-cell {
    font-size: 1rem;
    border-radius: 9px;
  }

  .day-eng {
    font-size: 0.95rem;
  }

  .day-san {
    font-size: 0.6rem;
  }

  /* Optimize moon days on mobile - hide tiny text and center/enlarge SVG */
  .moon-san-center {
    display: none;
  }

  .moon-svg {
    width: 20px;
    height: 20px;
    margin: 0 auto;
  }

  .day-cell.moon-day {
    padding: 0;
    justify-content: center;
    align-items: center;
  }

  .moon-icon-wrapper {
    margin-top: 0;
    gap: 0;
    justify-content: center;
    width: 100%;
    height: 100%;
  }

  .weekday-eng {
    font-size: 0.7rem;
  }

  .weekday-san {
    font-size: 0.58rem;
  }

  .weekdays {
    gap: 4px;
  }

  .days {
    gap: 4px;
  }

  .calendar-bottom-links {
    flex-direction: column;
    gap: 8px;
    margin-top: 14px;
  }

  .moon-phases-link {
    padding: 11px 14px;
    font-size: 0.83rem;
    gap: 6px;
  }

  .header-decor-left,
  .header-decor-right {
    width: 80px;
    height: 80px;
  }

  .title-divider {
    max-width: 160px;
  }
}

/* Extra responsive query for very narrow viewports */
@media (max-width: 360px) {
  body {
    padding: 12px 6px 30px;
  }

  .calendar-card,
  .festival-card {
    padding: 66px 8px 14px;
    border-radius: 14px;
  }

  .nav-btn {
    width: 36px;
    height: 36px;
  }

  .month-eng {
    font-size: 1.35rem;
  }

  .month-san {
    font-size: 0.85rem;
  }

  .weekdays,
  .days {
    gap: 3px;
  }

  .day-cell {
    border-radius: 6px;
  }

  .day-eng {
    font-size: 0.85rem;
  }

  .day-san {
    font-size: 0.52rem;
  }

  .moon-svg {
    width: 18px;
    height: 18px;
  }
}

/* ── Calendar Bottom Links ── */
.calendar-bottom-links {
  display: flex;
  gap: 10px;
  margin-top: auto;
  padding-top: 18px;
  padding-left: 2px;
  padding-right: 2px;
}

.moon-phases-link {
  flex: 1;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 7px;
  background: var(--green-gradient);
  color: #ffffff;
  border: none;
  padding: 13px 16px;
  border-radius: 14px;
  text-decoration: none;
  font-weight: 600;
  font-size: 0.88rem;
  box-shadow: 0 4px 14px rgba(10, 61, 31, 0.28);
  transition: all 0.25s var(--ease-smooth);
  line-height: 1.3;
  text-align: center;
}

.moon-phases-link:hover {
  background: var(--green-gradient);
  transform: translateY(-2px);
  box-shadow: 0 7px 18px rgba(10, 61, 31, 0.32);
}

.moon-phases-link svg {
  flex-shrink: 0;
  transition: transform 0.3s var(--ease-smooth);
}

.moon-phases-link:hover svg {
  transform: rotate(15deg);
}

.calculation-guide-link {
  background: transparent;
  color: var(--green-deep);
  border: 1.5px solid var(--green-deep);
  box-shadow: 0 2px 8px rgba(10, 61, 31, 0.08);
}

.calculation-guide-link:hover {
  background: var(--green-gradient);
  color: #ffffff;
  transform: translateY(-2px);
  box-shadow: 0 7px 18px rgba(10, 61, 31, 0.22);
}

.btn-text {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 2px;
}

.btn-san {
  font-size: 1em;
  line-height: 1.2;
}

.btn-eng {
  font-size: 0.75em;
  opacity: 0.85;
  font-family: 'Outfit', sans-serif;
  font-weight: 500;
}

/* ── Right Column ── */
/* ── Accessibility ── */
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    animation-duration: 0.01ms !important;
    transition-duration: 0.01ms !important;
  }
}

/* ── WhatsApp Join Button ── */
.whatsapp-join-btn {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  width: 100%;
  padding: 14px 20px;
  background-color: #25D366;
  color: #ffffff;
  border-radius: 24px;
  text-decoration: none;
  font-family: 'Outfit', sans-serif;
  font-size: 1.05rem;
  font-weight: 600;
  transition: all 0.2s var(--ease-smooth);
  box-shadow: 0 4px 12px rgba(37, 211, 102, 0.2);
}

.whatsapp-join-btn:hover {
  background-color: #20bd5a;
  transform: translateY(-2px);
  box-shadow: 0 6px 16px rgba(37, 211, 102, 0.3);
}

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

/* ── PWA Install Button ── */
.pwa-install-btn {
  display: none; /* Hidden by default, shown via JS if PWA installation is available */
  align-items: center;
  justify-content: center;
  gap: 8px;
  width: 100%;
  padding: 14px 20px;
  background: linear-gradient(135deg, #ffe082 0%, #ffd54f 45%, #f5b301 100%);
  color: #5d4200;
  border-radius: 24px;
  border: none;
  cursor: pointer;
  font-family: 'Outfit', sans-serif;
  font-size: 1.05rem;
  font-weight: 700;
  transition: all 0.2s var(--ease-smooth);
  box-shadow: 0 4px 12px rgba(245, 179, 1, 0.3);
}

.pwa-install-btn:hover {
  background: linear-gradient(135deg, #ffec9e 0%, #ffd740 45%, #ffb300 100%);
  transform: translateY(-2px);
  box-shadow: 0 6px 16px rgba(245, 179, 1, 0.4);
}

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

/* ── PWA "Update Available" Popup ── */
.pwa-update-toast {
  position: fixed;
  left: 50%;
  bottom: 20px;
  transform: translateX(-50%) translateY(160%);
  z-index: 9999;
  display: flex;
  align-items: center;
  gap: 16px;
  width: calc(100% - 32px);
  max-width: 440px;
  padding: 14px 16px;
  background: linear-gradient(135deg, #0d4a25 0%, #1b6b3a 100%);
  color: #ffffff;
  border-radius: 16px;
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.3);
  opacity: 0;
  transition: transform 0.4s var(--ease-smooth), opacity 0.4s var(--ease-smooth);
}

.pwa-update-toast.show {
  transform: translateX(-50%) translateY(0);
  opacity: 1;
}

.pwa-update-text {
  display: flex;
  flex-direction: column;
  line-height: 1.35;
  flex: 1;
  min-width: 0;
}

.pwa-update-title {
  font-weight: 600;
  font-size: 1rem;
}

.pwa-update-sub {
  font-family: 'Outfit', sans-serif;
  font-size: 0.8rem;
  opacity: 0.85;
}

.pwa-update-btn {
  flex-shrink: 0;
  padding: 10px 22px;
  border: none;
  border-radius: 24px;
  background: linear-gradient(135deg, #ffe082 0%, #ffd54f 45%, #f5b301 100%);
  color: #5d4200;
  font-family: 'Outfit', sans-serif;
  font-weight: 700;
  font-size: 0.95rem;
  cursor: pointer;
  transition: transform 0.2s var(--ease-smooth), box-shadow 0.2s var(--ease-smooth);
}

.pwa-update-btn:hover {
  transform: translateY(-1px);
  box-shadow: 0 4px 12px rgba(245, 179, 1, 0.4);
}

.pwa-update-toast.updating .pwa-update-btn {
  opacity: 0.7;
  pointer-events: none;
}

/* =============================================
   MOON PHASES PAGE — Premium UI Redesign
   ============================================= */

.moon-page-container {
  max-width: 900px;
  width: 100%;
  margin: 10px auto 40px;
  padding: 0 16px;
  animation: fadeInUp 0.5s var(--ease-smooth) both;
}

.moon-page-container .calendar-card {
  background: linear-gradient(145deg, #ffffff 0%, #f6faf5 100%);
  position: relative;
  overflow: hidden;
}

/* Card Background Watermarks */
.card-watermark {
  position: absolute;
  top: 60px;
  right: -40px;
  width: 320px;
  height: 320px;
  opacity: 0.85;
  pointer-events: none;
  z-index: 0;
}

.card-watermark-left {
  position: absolute;
  bottom: -40px;
  left: -45px;
  width: 260px;
  height: 260px;
  opacity: 0.8;
  pointer-events: none;
  z-index: 0;
}

.moon-page-header {
  text-align: center;
  margin-bottom: 20px;
  position: relative;
}

.moon-page-header h1 {
  font-family: 'Playfair Display', serif;
  font-size: 2.6rem;
  font-weight: 800;
  background: linear-gradient(135deg, var(--green-deep) 0%, var(--green-mid) 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  margin-bottom: 6px;
  letter-spacing: -0.5px;
}

.moon-page-header .san-font {
  color: var(--gold);
  font-size: 1.5rem;
  font-weight: 700;
  letter-spacing: 0.5px;
}

.moon-divider {
  display: flex;
  align-items: center;
  justify-content: center;
  margin: 15px auto 30px;
  max-width: 320px;
  gap: 12px;
}

.moon-divider-line {
  height: 1.5px;
  background: linear-gradient(90deg, transparent, var(--border-strong) 50%, transparent);
  flex: 1;
}

.moon-divider-icon {
  color: var(--gold);
  font-size: 1rem;
  display: flex;
  align-items: center;
  opacity: 0.85;
}

.back-btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 10px 20px;
  background-color: #ffffff;
  border: 1.5px solid var(--border-strong);
  border-radius: 16px;
  color: var(--green-deep);
  text-decoration: none;
  font-weight: 600;
  font-size: 0.9rem;
  margin-bottom: 24px;
  box-shadow: var(--shadow-sm);
  transition: all 0.25s var(--ease-smooth);
}

.back-btn:hover {
  background: var(--green-gradient);
  color: #ffffff;
  border-color: var(--green-deep);
  transform: translateY(-2px);
  box-shadow: var(--shadow-sm);
}

.back-btn svg {
  transition: transform 0.25s var(--ease-smooth);
}

.back-btn:hover svg {
  transform: translateX(-2px);
}

/* Lunar Cycle Guide Panel Redesign */
.lunar-guide {
  background: linear-gradient(135deg, #ffffff 0%, var(--bg-subtle) 100%);
  border: 1.5px solid var(--border-strong);
  border-radius: 24px;
  padding: 24px 28px;
  box-shadow: 
    0 10px 30px rgba(13, 74, 37, 0.05),
    inset 0 2px 4px rgba(255, 255, 255, 0.9);
  position: relative;
  overflow: hidden;
  display: flex;
  flex-direction: column;
  gap: 16px;
}

.lunar-guide::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  width: 5px;
  height: 100%;
  background: linear-gradient(to bottom, var(--green-light) 0%, var(--green-deep) 100%);
}

.lunar-guide-header {
  display: flex;
  align-items: center;
  gap: 14px;
  border-bottom: 1.5px solid rgba(27, 107, 58, 0.1);
  padding-bottom: 12px;
}

.lunar-guide-icon {
  background: linear-gradient(135deg, var(--green-deep) 0%, var(--green-mid) 100%);
  width: 44px;
  height: 44px;
  border-radius: 12px;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--gold-light);
  box-shadow: 0 4px 10px rgba(13, 74, 37, 0.15);
  flex-shrink: 0;
}

.lunar-guide-header h3 {
  color: var(--green-deep);
  font-size: 1.25rem;
  margin: 0;
  font-weight: 700;
  line-height: 1.2;
}

.lunar-guide-body {
  display: flex;
  flex-direction: column;
  gap: 16px;
}

.lunar-guide-desc {
  color: var(--text-sub);
  font-size: 0.94rem;
  line-height: 1.5;
  margin: 0;
}

.lunar-guide-phases {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 20px;
  margin-top: 4px;
}

.lunar-phase-col {
  background: #ffffff;
  border: 1.5px solid var(--border);
  border-radius: 18px;
  padding: 18px 20px 18px 28px;
  position: relative;
  transition: transform 0.25s var(--ease-smooth), border-color 0.25s var(--ease-smooth);
}

.lunar-phase-col:hover {
  border-color: var(--green-muted);
  transform: translateY(-2px);
  box-shadow: 0 6px 15px rgba(13, 74, 37, 0.04);
}

.lunar-phase-col::before {
  content: '';
  position: absolute;
  top: 18px;
  left: 10px;
  width: 5px;
  height: calc(100% - 36px);
  border-radius: 4px;
  transition: box-shadow 0.25s var(--ease-smooth);
}

.lunar-phase-col.waxing::before {
  background: linear-gradient(to bottom, var(--gold) 0%, #f39c12 100%);
  box-shadow: 0 2px 8px rgba(183, 137, 42, 0.35);
}

.lunar-phase-col.waxing:hover::before {
  box-shadow: 0 2px 14px rgba(183, 137, 42, 0.6);
}

.lunar-phase-col.waning::before {
  background: linear-gradient(to bottom, #e74c3c 0%, #c0392b 100%);
  box-shadow: 0 2px 8px rgba(192, 57, 43, 0.35);
}

.lunar-phase-col.waning:hover::before {
  box-shadow: 0 2px 14px rgba(192, 57, 43, 0.6);
}

.lunar-phase-title {
  color: var(--green-deep);
  font-size: 1.05rem;
  font-weight: 700;
  margin-bottom: 2px;
}

.lunar-phase-days {
  color: var(--green-muted);
  font-size: 0.8rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  margin-bottom: 8px;
}

.lunar-phase-detail {
  color: var(--text-sub);
  font-size: 0.88rem;
  line-height: 1.45;
}

/* Moon Grid & Cards */
.moon-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(120px, 1fr));
  gap: 32px 18px;
  justify-items: center;
  margin-top: 15px;
}

.moon-card {
  display: flex;
  flex-direction: column;
  align-items: center;
  position: relative;
  transition: transform 0.3s var(--ease-spring);
  cursor: pointer;
}

.moon-card:hover {
  transform: translateY(-6px) scale(1.04);
}

.moon-box {
  width: 108px;
  height: 108px;
  background: radial-gradient(circle at 35% 35%, #183321 0%, #0b1a10 50%, #030805 100%);
  border-radius: 22px;
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: 
    0 8px 24px rgba(13, 74, 37, 0.16),
    inset 0 4px 10px rgba(0, 0, 0, 0.6),
    0 0 0 1.5px rgba(45, 147, 83, 0.25);
  border: none;
  position: relative;
  transition: box-shadow 0.3s var(--ease-smooth), transform 0.3s var(--ease-smooth);
  overflow: hidden;
}

.moon-card:hover .moon-box {
  box-shadow: 
    0 12px 28px rgba(45, 147, 83, 0.35),
    inset 0 4px 10px rgba(0, 0, 0, 0.6),
    0 0 0 2px rgba(183, 137, 42, 0.7);
}

.moon-box svg {
  width: 76px;
  height: 76px;
  transform: rotate(-15deg);
  filter: drop-shadow(0 2px 6px rgba(0, 0, 0, 0.55));
}

.moon-label {
  margin-top: -10px;
  background: #ffffff;
  border: 1.5px solid var(--border-strong);
  padding: 5px 12px;
  border-radius: 14px;
  font-size: 0.9rem;
  color: var(--green-deep);
  font-weight: 600;
  box-shadow: var(--shadow-sm);
  z-index: 5;
  text-align: center;
  transition: all 0.3s var(--ease-smooth);
  line-height: 1.25;
}

.moon-card:hover .moon-label {
  border-color: var(--green-light);
  color: var(--green-deep);
  box-shadow: 0 4px 12px rgba(45, 147, 83, 0.16);
  transform: scale(1.03);
}

.moon-badge {
  position: absolute;
  top: -12px;
  left: 50%;
  transform: translateX(-50%);
  color: #ffffff;
  padding: 3px 12px;
  border-radius: 20px;
  font-size: 0.76rem;
  font-weight: 700;
  z-index: 10;
  box-shadow: 0 4px 8px rgba(0, 0, 0, 0.2);
  white-space: nowrap;
  text-align: center;
  letter-spacing: 0.2px;
  border: 1px solid rgba(255, 255, 255, 0.22);
  transition: transform 0.3s var(--ease-spring);
}

.moon-card:hover .moon-badge {
  transform: translateX(-50%) translateY(-2px) scale(1.05);
}

.moon-badge.badge-gold {
  background: linear-gradient(135deg, var(--gold) 0%, #aa7e18 100%);
  box-shadow: 0 4px 10px rgba(183, 137, 42, 0.35);
}

.moon-badge.badge-red {
  background: linear-gradient(135deg, #e74c3c 0%, #c0392b 100%);
  box-shadow: 0 4px 10px rgba(192, 57, 43, 0.35);
}

.moon-badge.badge-green {
  background: linear-gradient(135deg, var(--green-mid) 0%, var(--green-deep) 100%);
  box-shadow: 0 4px 10px rgba(27, 107, 58, 0.3);
}

/* Lunar Body Background Override */
body.lunar-body {
  position: relative;
  overflow-x: hidden;
  font-family: 'Outfit', sans-serif;
  background-color: #f4fbf6;
  background-image:
    radial-gradient(rgba(0, 0, 0, 0.035) 1.5px, transparent 1.5px),
    linear-gradient(135deg, #dcfce7 0%, #ffffff 50%, #e0f2fe 100%);
  background-size: 28px 28px, 100% 100%;
  background-attachment: fixed;
}

/* Special Cards Styling */
.gold-card .moon-box {
  background: radial-gradient(circle at 35% 35%, #2a220f 0%, #15120a 55%, #050402 100%);
  box-shadow: 
    0 8px 24px rgba(183, 137, 42, 0.22),
    inset 0 4px 10px rgba(0, 0, 0, 0.65),
    0 0 0 1.5px rgba(183, 137, 42, 0.45);
}

.gold-card:hover .moon-box {
  box-shadow: 
    0 12px 30px rgba(183, 137, 42, 0.45),
    inset 0 4px 10px rgba(0, 0, 0, 0.65),
    0 0 0 2px rgba(183, 137, 42, 0.85);
}

.gold-card .moon-label {
  border-color: var(--gold);
  background: linear-gradient(135deg, #ffffff 0%, #fffdf2 100%);
}

.gold-card:hover .moon-label {
  border-color: var(--gold-light);
  box-shadow: 0 4px 12px rgba(183, 137, 42, 0.2);
}

.red-card .moon-box {
  background: radial-gradient(circle at 35% 35%, #24110e 0%, #120807 55%, #040202 100%);
  box-shadow: 
    0 8px 24px rgba(192, 57, 43, 0.2),
    inset 0 4px 10px rgba(0, 0, 0, 0.65),
    0 0 0 1.5px rgba(192, 57, 43, 0.45);
}

.red-card:hover .moon-box {
  box-shadow: 
    0 12px 30px rgba(192, 57, 43, 0.4),
    inset 0 4px 10px rgba(0, 0, 0, 0.65),
    0 0 0 2px rgba(192, 57, 43, 0.85);
}

.red-card .moon-label {
  border-color: #e74c3c;
  background: linear-gradient(135deg, #ffffff 0%, #fff5f5 100%);
}

.red-card:hover .moon-label {
  border-color: #ff6b5b;
  box-shadow: 0 4px 12px rgba(192, 57, 43, 0.2);
}

@media (max-width: 600px) {
  .moon-page-container {
    padding: 0 8px;
  }
  .moon-page-container .calendar-card {
    padding: 85px 12px 20px;
    border-radius: 16px;
  }
  .moon-page-header h1 {
    font-size: 1.8rem;
  }
  .moon-page-header .san-font {
    font-size: 1.2rem;
  }
  .moon-divider {
    margin: 10px auto 20px;
  }
  .lunar-guide {
    padding: 16px;
    gap: 12px;
    border-radius: 16px;
  }
  .lunar-guide-phases {
    grid-template-columns: 1fr;
    gap: 10px;
  }
  .lunar-phase-col {
    padding: 12px 14px 12px 24px;
  }
  .lunar-guide-header h3 {
    font-size: 1.05rem;
  }
  .lunar-guide-icon {
    width: 38px;
    height: 38px;
  }
  .moon-grid {
    grid-template-columns: repeat(3, 1fr);
    gap: 30px 15px;
  }
  .moon-box {
    width: 90px;
    height: 90px;
    border-radius: 20px;
  }
  .moon-box svg {
    width: 60px;
    height: 60px;
  }
  .moon-badge {
    font-size: 0.72rem;
    padding: 2px 8px;
  }
  .moon-label {
    font-size: 0.85rem;
    padding: 5px 10px;
    border-radius: 12px;
  }
  .moon-card:hover {
    transform: translateY(-3px) scale(1.02);
  }
  .moon-card:hover .moon-badge {
    transform: translateX(-50%) translateY(-1px) scale(1.02);
  }
}

.settings-link:hover {
  opacity: 1 !important;
  color: var(--green-deep) !important;
  transform: scale(1.03);
}

/* =============================================
   SITE HEADER — V2 Portal Header
   Top announcement bar + main nav + mobile sidebar
   ============================================= */

body.has-site-header {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: flex-start;
  padding-top: 0;
  padding-bottom: 0;
}

.site-header {
  width: 100vw;
  margin-left: calc(50% - 50vw);
  margin-right: calc(50% - 50vw);
  margin-bottom: 32px;
  font-family: 'Outfit', sans-serif;
  position: sticky;
  top: 0;
  z-index: 1000;
}

/* ── Top utility bar ── */
.topbar {
  background: var(--green-dark-gradient);
  color: rgba(255, 255, 255, 0.92);
}

.topbar-inner {
  max-width: 1240px;
  margin: 0 auto;
  padding: 9px 24px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  font-size: 0.8rem;
}

.topbar-announce {
  display: flex;
  align-items: center;
  gap: 8px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.topbar-announce b {
  font-weight: 700;
}

.topbar-right {
  display: flex;
  align-items: center;
  gap: 18px;
  flex-shrink: 0;
}

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

.topbar-links a {
  color: inherit;
  text-decoration: none;
  opacity: 0.9;
  transition: opacity 0.2s var(--ease-smooth);
}

.topbar-links a:hover {
  opacity: 1;
  text-decoration: underline;
}

.topbar-sep {
  opacity: 0.4;
}

.topbar-lang {
  display: flex;
  align-items: center;
  gap: 4px;
  cursor: pointer;
  opacity: 0.9;
}

.topbar-caret {
  width: 10px;
  height: 10px;
}

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

.topbar-social-btn {
  width: 26px;
  height: 26px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.14);
  display: flex;
  align-items: center;
  justify-content: center;
  color: #ffffff;
  transition: all 0.2s var(--ease-smooth);
}

.topbar-social-btn svg {
  width: 13px;
  height: 13px;
}

.topbar-social-btn:hover {
  background: var(--gold-light);
  color: var(--green-deep);
  transform: translateY(-1px);
}

/* ── Main nav ── */
.main-nav {
  background: var(--bg-card);
  box-shadow: var(--shadow-sm);
}

.main-nav-inner {
  max-width: 1240px;
  margin: 0 auto;
  padding: 14px 24px;
  display: flex;
  align-items: center;
  gap: 24px;
}

.nav-menu-btn {
  display: none;
  background: none;
  border: none;
  color: var(--green-deep);
  cursor: pointer;
  padding: 6px;
}

.nav-menu-btn svg {
  width: 24px;
  height: 24px;
}

.site-logo {
  display: flex;
  align-items: center;
  gap: 10px;
  text-decoration: none;
  flex-shrink: 0;
}

.site-logo-badge {
  width: 46px;
  height: 46px;
  border-radius: 50%;
  background: #ffffff;
  box-shadow: var(--shadow-sm);
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  overflow: hidden;
}

.site-logo-badge img {
  width: 34px;
  height: 34px;
}

.site-logo-text {
  display: flex;
  flex-direction: column;
  line-height: 1.1;
}

.site-logo-san {
  color: var(--green-deep);
  font-size: 1.35rem;
  font-weight: 700;
}

.site-logo-eng {
  color: var(--text-main);
  font-weight: 800;
  font-size: 0.8rem;
  letter-spacing: 1px;
}

.main-nav-links {
  display: flex;
  align-items: center;
  gap: 22px;
  flex: 1;
  margin-left: 40px;
  min-width: 0;
}

.nav-link {
  display: flex;
  align-items: center;
  gap: 3px;
  color: var(--text-main);
  text-decoration: none;
  font-weight: 600;
  font-size: 0.92rem;
  padding: 6px 0;
  position: relative;
  transition: color 0.2s var(--ease-smooth);
}

.nav-link:hover {
  color: var(--green-mid);
}

.nav-link.active {
  color: var(--green-deep);
}

.nav-link.active::after {
  content: '';
  position: absolute;
  left: 0;
  right: 0;
  bottom: -3px;
  height: 2px;
  background: var(--green-gradient);
  border-radius: 2px;
}

.nav-caret {
  opacity: 0.65;
}

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

.nav-icon-btn {
  width: 38px;
  height: 38px;
  border-radius: 50%;
  border: 1.5px solid var(--border-strong);
  background: none;
  color: var(--text-main);
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: all 0.2s var(--ease-smooth);
}

.nav-icon-btn svg {
  width: 17px;
  height: 17px;
}

.nav-icon-btn:hover {
  background: var(--bg-subtle);
  border-color: var(--green-light);
  color: var(--green-deep);
}

.nav-login-btn {
  display: flex;
  align-items: center;
  gap: 8px;
  background: var(--green-gradient);
  color: #ffffff;
  text-decoration: none;
  font-weight: 600;
  font-size: 0.88rem;
  padding: 9px 18px;
  border-radius: 30px;
  white-space: nowrap;
  transition: all 0.2s var(--ease-smooth);
}

.nav-login-btn svg {
  width: 16px;
  height: 16px;
}

.nav-login-btn:hover {
  background: var(--green-gradient);
  transform: translateY(-1px);
}

/* ── Mobile sidebar ── */
.nav-sidebar-overlay {
  position: fixed;
  inset: 0;
  background: rgba(15, 39, 24, 0.5);
  z-index: 998;
  z-index: 1001;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.25s var(--ease-smooth);
}

.nav-sidebar-overlay.active {
  opacity: 1;
  pointer-events: auto;
}

.nav-sidebar {
  position: fixed;
  top: 0;
  left: 0;
  bottom: 0;
  width: 280px;
  max-width: 82vw;
  background: #ffffff;
  z-index: 999;
  z-index: 1002;
  transform: translateX(-100%);
  transition: transform 0.3s var(--ease-smooth);
  display: flex;
  flex-direction: column;
  box-shadow: var(--shadow-lg);
}

.nav-sidebar.active {
  transform: translateX(0);
}

.nav-sidebar-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 18px 20px;
  border-bottom: 1px solid var(--border);
}

.nav-sidebar-close {
  background: none;
  border: none;
  color: var(--text-main);
  cursor: pointer;
  padding: 4px;
}

.nav-sidebar-close svg {
  width: 20px;
  height: 20px;
}

.nav-sidebar-links {
  display: flex;
  flex-direction: column;
  padding: 12px;
  gap: 2px;
  overflow-y: auto;
}

.nav-sidebar-socials {
  margin-top: auto;
  display: flex;
  justify-content: center;
  gap: 14px;
  padding: 18px;
  border-top: 1px solid var(--border, #eee);
  flex-shrink: 0;
}

.sidebar-social-btn {
  width: 36px;
  height: 36px;
  border-radius: 50%;
  background: var(--bg-subtle, #f0f3f1);
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--green-deep, #0d4a25);
  transition: all 0.2s var(--ease-smooth);
}

.sidebar-social-btn svg {
  width: 16px;
  height: 16px;
}

.sidebar-social-btn:hover {
  background: var(--green-deep, #0d4a25);
  color: #ffffff;
}

.nav-sidebar-link {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 12px 14px;
  border-radius: 12px;
  color: var(--text-main);
  text-decoration: none;
  font-weight: 600;
  font-size: 0.95rem;
  transition: all 0.2s var(--ease-smooth);
}

.nav-sidebar-link svg {
  width: 19px;
  height: 19px;
  flex-shrink: 0;
  color: var(--green-mid);
}

.nav-sidebar-link:hover,
.nav-sidebar-link.active {
  background: var(--bg-subtle);
  color: var(--green-deep);
}

@media (max-width: 900px) {
  .topbar-links {
    display: none;
  }

  .topbar-socials {
    display: none;
  }

  .main-nav-links {
    display: none;
  }

  .nav-menu-btn {
    display: flex;
  }

  .nav-login-btn .nav-login-text {
    display: none;
  }

  .nav-login-btn {
    padding: 9px;
  }

  /* .main-nav-links normally supplies the flex:1 spacer that pushes
     .nav-actions to the right edge; once it's hidden on mobile, push
     nav-actions there directly instead. */
  .nav-actions {
    margin-left: auto;
  }
}

@media (max-width: 600px) {
  .topbar-announce {
    font-size: 0.72rem;
  }

  .topbar-lang {
    display: none;
  }

  .topbar-inner {
    padding: 8px 14px;
  }

  .main-nav-inner {
    padding: 12px 14px;
    gap: 12px;
  }

  .site-logo-badge {
    width: 38px;
    height: 38px;
  }

  .site-logo-badge img {
    width: 28px;
    height: 28px;
  }

  .site-logo-san {
    font-size: 1.1rem;
  }

  .site-logo-eng {
    font-size: 0.7rem;
  }
}

/* =============================================
   SITE FOOTER — V2 Portal Footer
   ============================================= */

.site-footer {
  width: 100vw;
  margin-left: calc(50% - 50vw);
  margin-right: calc(50% - 50vw);
  margin-top: 32px;
  background: var(--green-dark-gradient);
  color: rgba(255, 255, 255, 0.82);
  font-family: 'Outfit', sans-serif;
}

.footer-inner {
  max-width: 1240px;
  margin: 0 auto;
  padding: 48px 24px 28px;
  display: grid;
  grid-template-columns: 1.6fr 1fr 1fr 1fr 1fr 1.1fr;
  gap: 28px;
}

.footer-brand-col {
  display: flex;
  flex-direction: column;
  gap: 14px;
}

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

.footer-logo-badge {
  width: 44px;
  height: 44px;
  border-radius: 50%;
  background: #ffffff;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}

.footer-logo-badge img {
  width: 32px;
  height: 32px;
}

.footer-logo-text {
  display: flex;
  flex-direction: column;
  line-height: 1.1;
}

.footer-logo-san {
  color: var(--gold-light);
  font-size: 1.2rem;
  font-weight: 700;
}

.footer-logo-eng {
  color: #ffffff;
  font-weight: 800;
  font-size: 0.85rem;
  letter-spacing: 1px;
}

.footer-tagline {
  font-size: 0.78rem;
  opacity: 0.7;
  margin-top: -6px;
}

.footer-desc {
  font-size: 0.85rem;
  line-height: 1.6;
  opacity: 0.75;
  max-width: 260px;
}

.footer-socials {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-top: 4px;
}

.footer-social-btn {
  width: 32px;
  height: 32px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.12);
  display: flex;
  align-items: center;
  justify-content: center;
  color: #ffffff;
  transition: all 0.2s var(--ease-smooth);
}

.footer-social-btn svg {
  width: 16px;
  height: 16px;
}

.footer-social-btn:hover {
  background: var(--gold-light);
  color: var(--green-deep);
  transform: translateY(-2px);
}

.footer-col-title {
  color: var(--gold-light);
  font-weight: 700;
  font-size: 0.95rem;
  margin-bottom: 16px;
}

.footer-col-links {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.footer-col-links a {
  color: inherit;
  text-decoration: none;
  font-size: 0.86rem;
  opacity: 0.8;
  transition: all 0.2s var(--ease-smooth);
}

.footer-col-links a:hover {
  opacity: 1;
  color: var(--gold-light);
  padding-left: 3px;
}

.footer-contact-item {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  font-size: 0.85rem;
  opacity: 0.85;
  line-height: 1.4;
}

.footer-contact-item svg {
  width: 15px;
  height: 15px;
  flex-shrink: 0;
  margin-top: 2px;
  color: var(--gold-light);
}

.footer-bottom {
  border-top: 1px solid rgba(255, 255, 255, 0.12);
}

.footer-bottom-inner {
  max-width: 1240px;
  margin: 0 auto;
  padding: 18px 24px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  flex-wrap: wrap;
  font-size: 0.78rem;
  opacity: 0.7;
}

.footer-bottom-tagline {
  color: var(--gold-light);
  opacity: 0.9;
}

@media (max-width: 980px) {
  .footer-inner {
    grid-template-columns: 1fr 1fr 1fr;
  }

  .footer-brand-col {
    grid-column: 1 / -1;
  }

  .footer-desc {
    max-width: 420px;
  }
}

@media (max-width: 600px) {
  .footer-inner {
    grid-template-columns: 1fr 1fr;
    padding: 36px 16px 20px;
    gap: 24px;
  }

  .footer-bottom-inner {
    justify-content: center;
    text-align: center;
    padding: 16px;
  }
}

/* =============================================
   HOMEPAGE — V2 Portal Homepage
   ============================================= */

body.home-page {
  background-color: #ffffff;
  padding-bottom: 0;
}

.home-container {
  width: 100%;
  max-width: 1240px;
  margin: 0 auto;
  padding: 0 24px 40px;
  display: flex;
  flex-direction: column;
  gap: 36px;
}

.home-section-title {
  font-family: 'Outfit', sans-serif;
  font-size: 1.5rem;
  font-weight: 700;
  color: var(--green-deep);
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}

.home-section-link {
  font-family: 'Outfit', sans-serif;
  font-size: 0.82rem;
  font-weight: 600;
  color: var(--green-mid);
  text-decoration: none;
  white-space: nowrap;
  display: flex;
  align-items: center;
  gap: 4px;
}

.home-section-link:hover {
  color: var(--green-deep);
  text-decoration: underline;
}

/* ── Hero ── */
.hero-section {
  background: var(--bg-header);
  border-radius: 24px;
  padding: 44px 40px;
  min-height: 380px;
  display: flex;
  align-items: center;
  gap: 32px;
  position: relative;
  overflow: hidden;
  box-shadow: var(--shadow-lg), 0 0 0 1px rgba(232, 193, 77, 0.2);
}

.hero-section::before {
  content: '';
  position: absolute;
  inset: 0;
  z-index: 1;
  background:
    linear-gradient(100deg, rgba(6, 26, 15, 0.94) 0%, rgba(6, 26, 15, 0.68) 42%, rgba(6, 26, 15, 0.1) 72%),
    radial-gradient(circle at 15% 20%, rgba(232, 193, 77, 0.1) 0%, transparent 45%),
    radial-gradient(circle at 90% 85%, rgba(184, 233, 122, 0.1) 0%, transparent 45%);
  pointer-events: none;
}

.hero-motif {
  position: absolute;
  left: 4%;
  bottom: 6%;
  width: 150px;
  height: auto;
  color: var(--ivory);
  opacity: 0.3;
  z-index: 1;
  pointer-events: none;
}

.hero-eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-family: 'Outfit', sans-serif;
  font-weight: 700;
  font-size: 0.78rem;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--ivory);
  background: rgba(193, 68, 14, 0.32);
  border: 1px solid rgba(232, 129, 74, 0.5);
  padding: 6px 14px;
  border-radius: 20px;
  margin-bottom: 16px;
}

.hero-bg-image {
  position: absolute;
  top: 0;
  right: 0;
  height: 100%;
  width: 68%;
  object-fit: cover;
  object-position: center 35%;
  mask-image: linear-gradient(to right, transparent 0%, black 38%);
  -webkit-mask-image: linear-gradient(to right, transparent 0%, black 38%);
  opacity: 0.95;
  z-index: 0;
}

.hero-content {
  position: relative;
  z-index: 2;
  max-width: 520px;
}

.hero-title {
  font-family: 'Playfair Display', serif;
  font-size: 2.4rem;
  font-weight: 800;
  color: #ffffff;
  line-height: 1.18;
  letter-spacing: -0.01em;
  margin-bottom: 14px;
}

.hero-title .accent {
  color: #ffea00;
}

.hero-san {
  font-size: 1.6rem;
  font-weight: 500;
  letter-spacing: 0.02em;
  color: #ffea00;
  opacity: 0.95;
  margin-bottom: 20px;
  padding-left: 14px;
  border-left: 3px solid var(--terracotta-light);
}

.hero-desc {
  color: rgba(255, 255, 255, 0.82);
  font-size: 0.98rem;
  line-height: 1.6;
  margin-bottom: 24px;
}

.hero-actions {
  display: flex;
  gap: 14px;
  flex-wrap: wrap;
}

.hero-btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 13px 24px;
  border-radius: 10px;
  font-weight: 700;
  font-size: 0.92rem;
  text-decoration: none;
  transition: all 0.25s var(--ease-smooth);
}

.hero-btn svg {
  width: 17px;
  height: 17px;
}

.hero-btn-primary {
  background: linear-gradient(135deg, #b89a00 0%, #ffea00 100%);
  color: #ffffff;
}

.hero-btn-primary:hover {
  background: linear-gradient(135deg, #ccab00 0%, #fff066 100%);
  transform: translateY(-2px);
}

.hero-btn-secondary {
  background: rgba(255, 255, 255, 0.12);
  color: #ffffff;
  border: 1.5px solid rgba(255, 255, 255, 0.35);
}

.hero-btn-secondary:hover {
  background: rgba(255, 255, 255, 0.2);
  transform: translateY(-2px);
}

@media (max-width: 800px) {
  .hero-section {
    flex-direction: column;
    text-align: center;
    padding: 32px 24px;
    min-height: 0;
  }

  .hero-content {
    max-width: 100%;
  }

  .hero-eyebrow {
    margin-left: auto;
    margin-right: auto;
  }

  .hero-san {
    border-left: none;
    border-top: 3px solid var(--terracotta-light);
    padding-left: 0;
    padding-top: 10px;
  }

  .hero-motif {
    display: none;
  }

  .hero-actions {
    justify-content: center;
  }

  .hero-bg-image {
    width: 100%;
    mask-image: linear-gradient(to bottom, transparent 0%, black 55%);
    -webkit-mask-image: linear-gradient(to bottom, transparent 0%, black 55%);
    opacity: 0.3;
  }
}

/* ── Today's Info + Quick Access ── */
.home-top-grid {
  display: grid;
  grid-template-columns: 1.3fr 1fr;
  gap: 24px;
  align-items: start;
}

.info-card {
  background: var(--bg-card);
  border-radius: 20px;
  border: 1px solid var(--border);
  box-shadow: var(--shadow-sm);
  padding: 22px 24px;
}

.info-card-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 16px;
}

.info-card-title {
  font-family: 'Playfair Display', serif;
  font-weight: 700;
  color: var(--green-deep);
  font-size: 1.1rem;
}

.info-card-date {
  font-size: 0.8rem;
  font-weight: 600;
  color: var(--green-mid);
}

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

.info-tile {
  display: flex;
  align-items: center;
  gap: 10px;
  background: var(--bg-subtle);
  border-radius: 14px;
  padding: 10px 12px;
}

.info-tile-icon {
  width: 34px;
  height: 34px;
  border-radius: 10px;
  background: var(--green-pale);
  color: var(--green-deep);
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}

.info-tile-icon svg {
  width: 17px;
  height: 17px;
}

.info-tile-label {
  font-size: 0.72rem;
  color: var(--text-sub);
  font-weight: 600;
}

.info-tile-value {
  font-size: 0.9rem;
  color: var(--text-main);
  font-weight: 700;
}

/* ── Quick access tiles ── */
.quick-access-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 14px;
}

.quick-tile {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: 16px;
  padding: 18px 10px;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 8px;
  text-decoration: none;
  text-align: center;
  transition: all 0.25s var(--ease-smooth);
}

.quick-tile:hover {
  transform: translateY(-3px);
  box-shadow: var(--shadow-md);
  border-color: var(--green-light);
}

.quick-tile-icon {
  width: 42px;
  height: 42px;
  border-radius: 12px;
  display: flex;
  align-items: center;
  justify-content: center;
  color: #ffffff;
}

.quick-tile-icon svg {
  width: 20px;
  height: 20px;
}

.quick-tile-title {
  font-size: 0.8rem;
  font-weight: 700;
  color: var(--text-main);
}

.quick-tile-sub {
  font-size: 0.68rem;
  color: var(--text-muted);
}

/* ── Stats strip ── */
.stats-strip {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 16px;
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: 20px;
  padding: 22px 20px;
  box-shadow: var(--shadow-sm);
}

.stat-item {
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  gap: 2px;
}

.stat-value {
  font-family: 'Playfair Display', serif;
  font-size: 1.6rem;
  font-weight: 800;
  color: var(--green-deep);
}

.stat-label {
  font-size: 0.75rem;
  color: var(--text-sub);
  font-weight: 600;
}

/* ── Mini calendar + upcoming festivals ── */
.home-cal-grid {
  display: grid;
  grid-template-columns: 1fr 1.3fr;
  gap: 24px;
  align-items: stretch;
}

.mini-cal-card {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: 20px;
  box-shadow: var(--shadow-sm);
  padding: 20px;
  display: flex;
  flex-direction: column;
  height: 100%;
}

.mini-cal-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 14px;
}

.mini-cal-title {
  font-weight: 700;
  color: var(--green-deep);
  font-size: 0.98rem;
}

.mini-cal-weekdays,
.mini-cal-days {
  display: grid;
  grid-template-columns: repeat(7, 1fr);
  gap: 4px;
  text-align: center;
}

.mini-cal-days {
  flex-grow: 1;
  grid-auto-rows: 1fr;
}

.mini-cal-weekdays div {
  font-size: 0.68rem;
  font-weight: 700;
  color: var(--text-muted);
  padding-bottom: 6px;
}

.mini-cal-days div {
  font-size: 0.8rem;
  padding: 6px 0;
  border-radius: 8px;
  color: var(--text-main);
  display: flex;
  align-items: center;
  justify-content: center;
}

.mini-cal-days div.mini-cal-today {
  background: var(--today-bg);
  color: #ffffff;
  font-weight: 700;
}

.mini-cal-days div.mini-cal-fest {
  background: var(--green-pale);
  font-weight: 700;
  color: var(--green-deep);
}

.mini-cal-legend {
  display: flex;
  flex-wrap: wrap;
  gap: 8px 16px;
  margin-top: 16px;
  padding-top: 14px;
  border-top: 1px solid var(--border);
}

.mini-cal-legend-item {
  display: flex;
  flex-direction: column;
  gap: 1px;
}

.mini-cal-legend-label {
  font-size: 0.68rem;
  color: var(--text-muted);
}

.mini-cal-legend-value {
  font-size: 0.82rem;
  font-weight: 700;
  color: var(--text-main);
}

.upcoming-fest-card {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: 20px;
  box-shadow: var(--shadow-sm);
  padding: 20px;
}

.upcoming-fest-list {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.upcoming-fest-item {
  display: flex;
  align-items: center;
  gap: 14px;
  padding: 10px;
  border-radius: 14px;
  transition: background 0.2s var(--ease-smooth);
}

.upcoming-fest-item:hover {
  background: var(--bg-subtle);
}

.upcoming-fest-date {
  flex-shrink: 0;
  width: 52px;
  height: 52px;
  border-radius: 12px;
  background: var(--green-gradient);
  color: #ffffff;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  line-height: 1.1;
}

.upcoming-fest-date .day-num {
  font-size: 1.05rem;
  font-weight: 800;
}

.upcoming-fest-date .mon-name {
  font-size: 0.62rem;
  text-transform: uppercase;
  opacity: 0.85;
}

.upcoming-fest-info {
  flex: 1;
  min-width: 0;
}

.upcoming-fest-name {
  font-weight: 700;
  color: var(--text-main);
  font-size: 0.92rem;
}

.upcoming-fest-san {
  font-size: 0.85rem;
  color: var(--text-sub);
}

.upcoming-fest-day {
  flex-shrink: 0;
  font-size: 0.72rem;
  font-weight: 700;
  color: var(--green-deep);
  background: var(--green-pale);
  padding: 4px 10px;
  border-radius: 20px;
}

/* ── Featured festivals ── */
.featured-fest-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 18px;
}

.featured-fest-card {
  background: var(--bg-header);
  border-radius: 18px;
  padding: 20px;
  min-height: 140px;
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
  gap: 4px;
  position: relative;
  overflow: hidden;
  color: #ffffff;
  box-shadow: var(--shadow-sm);
  transition: all 0.25s var(--ease-smooth);
}

.featured-fest-card:hover {
  transform: translateY(-4px);
  box-shadow: var(--shadow-md);
}

.featured-fest-icon {
  position: absolute;
  top: 14px;
  right: 14px;
  opacity: 0.35;
}

.featured-fest-icon svg {
  width: 34px;
  height: 34px;
}

.featured-fest-san {
  font-size: 1rem;
  font-weight: 700;
  position: relative;
  z-index: 1;
}

.featured-fest-name {
  font-size: 0.82rem;
  opacity: 0.85;
  position: relative;
  z-index: 1;
}

.featured-fest-date {
  font-size: 0.72rem;
  color: var(--gold-light);
  font-weight: 700;
  margin-top: 4px;
  position: relative;
  z-index: 1;
}

/* ── Explore more band ── */
.explore-more-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 18px;
}

.explore-more-card {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: 18px;
  padding: 22px 18px;
  display: flex;
  flex-direction: column;
  gap: 10px;
  text-decoration: none;
  transition: all 0.25s var(--ease-smooth);
}

.explore-more-card:hover {
  border-color: var(--green-light);
  box-shadow: var(--shadow-md);
  transform: translateY(-3px);
}

.explore-more-icon {
  width: 42px;
  height: 42px;
  border-radius: 12px;
  background: var(--green-pale);
  color: var(--green-deep);
  display: flex;
  align-items: center;
  justify-content: center;
}

.explore-more-icon svg {
  width: 20px;
  height: 20px;
}

.explore-more-title {
  font-weight: 700;
  color: var(--text-main);
  font-size: 0.95rem;
}

.explore-more-desc {
  font-size: 0.8rem;
  color: var(--text-sub);
  line-height: 1.4;
}

/* ── CTA band (install + community) ── */
.cta-band {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: 20px;
  box-shadow: var(--shadow-sm);
  padding: 16px 24px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  flex-wrap: wrap;
}

.cta-band-text {
  flex: 1;
  min-width: 220px;
}

.cta-band-title {
  font-family: 'Outfit', sans-serif;
  font-weight: 700;
  font-size: 1.2rem;
  color: var(--green-deep);
  margin-bottom: 4px;
}

.cta-band-desc {
  font-size: 0.88rem;
  color: var(--text-sub);
}

.cta-band-actions {
  display: flex;
  gap: 12px;
  flex-wrap: wrap;
}

.cta-band-btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 12px 20px;
  border-radius: 12px;
  font-weight: 700;
  font-size: 0.88rem;
  text-decoration: none;
  transition: all 0.2s var(--ease-smooth);
  border: none;
  cursor: pointer;
}

.cta-band-btn svg {
  width: 17px;
  height: 17px;
}

.cta-band-btn-install {
  background: var(--green-gradient);
  color: #ffffff;
}

.cta-band-btn-install:hover {
  background: var(--green-gradient);
  transform: translateY(-2px);
}

.cta-band-btn-whatsapp {
  background: #e9f7ee;
  color: #1b6b3a;
}

.cta-band-btn-whatsapp:hover {
  background: #d7f0e0;
  transform: translateY(-2px);
}

/* ── FAQ ── */
.faq-list {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

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

.faq-question {
  width: 100%;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 16px 20px;
  background: none;
  border: none;
  text-align: left;
  font-family: 'Outfit', sans-serif;
  font-weight: 700;
  font-size: 0.92rem;
  color: var(--text-main);
  cursor: pointer;
}

.faq-question svg {
  width: 16px;
  height: 16px;
  flex-shrink: 0;
  color: var(--green-mid);
  transition: transform 0.25s var(--ease-smooth);
}

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

.faq-answer {
  display: grid;
  grid-template-rows: 0fr;
  transition: grid-template-rows 0.25s ease-out;
}

.faq-item.open .faq-answer {
  grid-template-rows: 1fr;
}

.faq-answer-inner {
  overflow: hidden;
}

.faq-answer p {
  padding: 0 20px 18px;
  font-size: 0.86rem;
  color: var(--text-sub);
  line-height: 1.6;
}

@media (max-width: 980px) {
  .home-top-grid,
  .home-cal-grid {
    grid-template-columns: 1fr;
  }

  .quick-access-grid {
    grid-template-columns: repeat(3, 1fr);
  }

  .stats-strip {
    grid-template-columns: repeat(2, 1fr);
  }

  .featured-fest-grid,
  .explore-more-grid {
    grid-template-columns: repeat(2, 1fr);
  }
}

@media (max-width: 600px) {
  .home-container {
    padding: 0 14px 32px;
    gap: 26px;
  }

  .hero-title {
    font-size: 1.7rem;
  }

  .quick-access-grid {
    grid-template-columns: repeat(2, 1fr);
  }

  .info-grid {
    grid-template-columns: 1fr;
  }

  .stats-strip {
    grid-template-columns: repeat(2, 1fr);
  }

  .featured-fest-grid,
  .explore-more-grid {
    grid-template-columns: 1fr;
  }

  .cta-band {
    flex-direction: column;
    align-items: stretch;
    text-align: center;
  }

  .cta-band-actions {
    justify-content: center;
  }
}

/* =============================================
   CALENDAR PAGE — Vikram Samvat Calendar page
   ============================================= */

.cal-page-container {
  width: 100%;
  max-width: 1240px;
  margin: 0 auto;
  padding: 24px 24px 40px;
  display: flex;
  flex-direction: column;
  gap: 24px;
}

/* ── Today's Info strip (single row, matches reference stat-bar) ── */
.today-stats-strip {
  background: var(--bg-subtle);
  border: 1px solid var(--green-pale);
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.03);
  border-radius: 16px;
  padding: 18px 24px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
  flex-wrap: wrap;
}

.today-stat-item {
  display: flex;
  align-items: center;
  gap: 10px;
}

.today-stat-icon {
  width: 38px;
  height: 38px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--green-deep);
  flex-shrink: 0;
}

.today-stat-icon svg {
  width: 17px;
  height: 17px;
}

.today-stat-label {
  font-size: 0.7rem;
  color: var(--text-muted);
}

.today-stat-value {
  font-weight: 700;
  font-size: 0.85rem;
  color: var(--text-main);
}

@media (max-width: 900px) {
  .today-stats-strip {
    justify-content: flex-start;
  }
}

.stats-mobile-divider {
  display: none;
}

@media (max-width: 900px) {
  .stats-mobile-divider {
    display: block;
    width: 100%;
    height: 1px;
    background: var(--green-pale);
    margin: 8px 0;
  }
}

/* --- Hero Section --- */
.cal-hero-section {
  position: relative;
  width: 100%;
  min-height: 260px;
  background: linear-gradient(135deg, rgba(16, 24, 40, 0.95) 0%, rgba(16, 24, 40, 0.8) 50%, rgba(16, 24, 40, 0.2) 100%), url('../assets/hero-bg.png');
  background-size: cover;
  background-position: center;
  border-radius: 24px;
  padding: 40px;
  margin-bottom: 24px;
  display: flex;
  justify-content: center;
  align-items: center;
  overflow: hidden;
  box-sizing: border-box;
}

.cal-hero-left {
  flex: 1;
  max-width: 60%;
  z-index: 2;
}

.cal-hero-title {
  font-family: 'Outfit', sans-serif;
  font-size: 2.8rem;
  font-weight: 800;
  color: #ffffff;
  margin: 0 0 8px 0;
  line-height: 1.1;
}

.cal-hero-subtitle {
  font-family: 'Outfit', sans-serif;
  font-size: 1.6rem;
  font-weight: 600;
  color: #86efac;
  margin: 0 0 16px 0;
}

.cal-hero-desc {
  font-family: 'Outfit', sans-serif;
  font-size: 1.05rem;
  line-height: 1.6;
  color: #e2e8f0;
  margin: 0;
  max-width: 90%;
}

.cal-hero-right {
  flex: 0 0 350px;
  z-index: 2;
}

.thought-card {
  background: #ffffff;
  border-radius: 16px;
  padding: 24px;
  box-shadow: var(--shadow-sm, 0 4px 15px rgba(0,0,0,0.05));
}

.thought-card-header {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  margin-bottom: 20px;
}

.thought-title {
  font-family: 'Outfit', sans-serif;
  font-weight: 700;
  font-size: 1.1rem;
  color: var(--text-dark, #1a202c);
  line-height: 1.2;
}

.thought-card-body {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.thought-icon svg {
  width: 24px;
  height: 24px;
  color: var(--green-mid, #22c55e);
}

.thought-text {
  font-family: 'Outfit', sans-serif;
  font-size: 1.05rem;
  font-weight: 500;
  line-height: 1.5;
  color: var(--text-dark, #1a202c);
  margin: 0;
  white-space: pre-line;
}

.thought-author {
  font-family: 'Outfit', sans-serif;
  font-size: 0.9rem;
  color: var(--text-muted, #4a5568);
  margin: 0;
}

@media (max-width: 900px) {
  .cal-hero-section {
    flex-direction: column;
    padding: 30px 20px;
    gap: 30px;
  }
  .cal-hero-left {
    max-width: 100%;
    text-align: center;
  }
  .cal-hero-desc {
    max-width: 100%;
    margin: 0 auto;
  }
  .cal-hero-right {
    flex: 0 0 auto;
    width: 100%;
    max-width: 400px;
    margin: 0 auto;
  }
  .thought-card-header {
    justify-content: center;
  }
  .thought-card-body {
    align-items: center;
    text-align: center;
  }
  .cal-hero-title {
    font-size: 2.2rem;
  }
  .cal-hero-subtitle {
    font-size: 1.4rem;
  }
}

/* ── Toolbar + Join Community row (mirrors cal-main-grid's column widths) ── */
.cal-top-row {
  display: grid;
  grid-template-columns: minmax(0, 1.2fr) minmax(0, 1fr);
  gap: 24px;
  align-items: stretch;
}

/* ── Toolbar ── */
.cal-toolbar {
  width: 100%;
  scroll-margin-top: 120px;
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: 16px;
  padding: 10px 16px;
  display: flex;
  align-items: center;
  gap: 20px;
  flex-wrap: nowrap;
  box-sizing: border-box;
}

.cal-toolbar-field {
  display: flex;
  flex-direction: column;
  gap: 6px;
  flex: 1;
  min-width: 0;
}

.cal-toolbar-field:nth-child(1) {
  flex: 1.5;
  min-width: 0;
}

.cal-toolbar-field:nth-child(2) {
  flex: 0.7;
  min-width: 0;
}

.cal-toolbar-field:nth-child(3) {
  flex: 1.2;
  min-width: 0;
}

.cal-toolbar-field label {
  font-size: 0.72rem;
  font-weight: 600;
  color: var(--text-muted);
}

.cal-toolbar-field select,
.cal-toolbar-field input {
  border: 1px solid var(--border-strong);
  border-radius: 10px;
  padding: 8px 12px;
  font-family: 'Outfit', sans-serif;
  font-weight: 600;
  font-size: 0.85rem;
  color: var(--text-main);
  background: #ffffff;
  cursor: pointer;
}

.cal-toolbar-field input[type="date"] {
  width: 100%;
  box-sizing: border-box;
  height: 35px; /* Match custom dropdown height */
}

.cal-toolbar-field input:focus {
  border-color: var(--green-pale) !important;
  outline: none !important;
  box-shadow: 0 0 0 3px rgba(118,171,174,0.2) !important;
}

/* Custom Dropdown (WhatsApp style) */
.custom-dropdown-wrapper {
  position: relative;
  width: 100%;
}

.custom-dropdown-trigger {
  border: 1px solid var(--border-strong);
  border-radius: 10px;
  padding: 8px 12px;
  font-family: 'Outfit', sans-serif;
  font-weight: 600;
  font-size: 0.85rem;
  color: var(--text-main);
  background: #ffffff;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: space-between;
  width: 100%;
  box-sizing: border-box;
}

.custom-dropdown-trigger span:first-child {
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.custom-dropdown-trigger svg {
  width: 14px;
  height: 14px;
  color: var(--text-muted);
}

.custom-dropdown-menu {
  position: absolute;
  top: 100%;
  left: 0;
  min-width: 100%;
  margin-top: 4px;
  background: #ffffff;
  border-radius: 8px;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
  list-style: none;
  padding: 8px 0;
  z-index: 100;
  display: none;
  max-height: 250px;
  overflow-y: auto;
}

.custom-dropdown-menu.show {
  display: block;
}

.custom-dropdown-item {
  padding: 10px 16px;
  font-family: 'Outfit', sans-serif;
  font-size: 0.85rem;
  font-weight: 500;
  color: var(--text-main);
  cursor: pointer;
  display: flex;
  align-items: center;
  gap: 12px;
  white-space: nowrap;
}

.custom-dropdown-item:hover,
.custom-dropdown-item.selected {
  background: #f5f6f6;
}

.custom-dropdown-item-icon {
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--text-muted);
  width: 18px;
  height: 18px;
}

.cal-toolbar-today-btn {
  margin-left: auto;
  background: var(--green-gradient);
  color: #ffffff;
  border: none;
  border-radius: 10px;
  padding: 9px 18px;
  font-weight: 700;
  font-size: 0.85rem;
  cursor: pointer;
  transition: background 0.2s var(--ease-smooth);
}

.cal-toolbar-today-btn:hover {
  background: var(--green-gradient);
}

/* ── Main grid: calendar + side panel ── */
.cal-main-grid {
  display: grid;
  grid-template-columns: minmax(0, 1.2fr) minmax(0, 1fr);
  gap: 24px;
  align-items: stretch;
}

.cal-grid-card {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: 16px;
  overflow: hidden;
}

.cal-grid-head {
  display: grid;
  grid-template-columns: auto 1fr auto;
  align-items: center;
  gap: 12px;
  padding: 16px 20px;
}

.cal-grid-nav {
  display: flex;
  gap: 8px;
}

.cal-grid-nav button {
  width: 32px;
  height: 32px;
  border-radius: 8px;
  border: 1px solid var(--border-strong);
  background: #ffffff;
  cursor: pointer;
  font-size: 1rem;
  color: var(--text-main);
  transition: all 0.2s var(--ease-smooth);
}

.cal-grid-nav button:hover {
  background: var(--bg-subtle);
  border-color: var(--green-light);
}

.cal-grid-title {
  text-align: center;
  font-family: 'Outfit', sans-serif;
  font-weight: 700;
  font-size: 1.25rem;
  color: var(--green-deep);
  white-space: nowrap;
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
}

.cal-grid-today-btn {
  justify-self: end;
  background: #ffffff;
  border: 1px solid var(--border-strong);
  border-radius: 8px;
  padding: 8px 16px;
  font-weight: 600;
  font-size: 0.8rem;
  cursor: pointer;
  white-space: nowrap;
}

.cal-grid-today-btn:hover {
  background: var(--bg-subtle);
}

.cal-weekdays {
  display: grid;
  grid-template-columns: repeat(7, 1fr);
  background: var(--green-gradient);
}

.cal-weekdays > div {
  text-align: center;
  padding: 10px 0 8px;
  color: #ffffff;
}

.cal-weekdays .cal-wd-eng {
  font-weight: 700;
  font-size: 0.78rem;
  line-height: 1;
}

.cal-weekdays .cal-wd-san {
  font-size: 0.8rem;
  opacity: 0.9;
  margin-top: 4px;
  line-height: 1;
}

.cal-days {
  display: grid;
  grid-template-columns: repeat(7, 1fr);
  gap: 6px;
  padding: 10px;
  background: var(--bg-subtle);
}

.cal-day-cell {
  position: relative;
  aspect-ratio: 1;
  min-width: 0;
  min-height: 0;
  padding: 6px;
  border-radius: 10px;
  cursor: pointer;
  background: #ffffff;
  border: 1px solid var(--border);
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
  transition: all 0.2s var(--ease-smooth);
  overflow: hidden;
}

.cal-day-cell:hover {
  border-color: var(--green-light);
  transform: translateY(-1px);
}

.cal-day-cell.cal-day-empty {
  visibility: hidden;
  cursor: default;
}

.cal-day-cell.cal-day-selected {
  background: var(--bg-subtle);
  border: 2px solid var(--green-light);
}

.cal-day-cell.cal-day-kunami {
  background: var(--green-gradient) !important;
  border: none;
  box-shadow: 0 4px 12px var(--green-glow);
}

@keyframes animateBorderMove {
  0% { transform: translate(-50%, -50%) rotate(0deg); }
  100% { transform: translate(-50%, -50%) rotate(360deg); }
}

.cal-day-cell.cal-day-today {
  position: relative;
  overflow: hidden;
  border: none;
  background: transparent !important;
  box-shadow: 0 4px 12px var(--green-glow);
  z-index: 1;
}

.cal-day-cell.cal-day-today::before {
  content: '';
  position: absolute;
  top: 50%;
  left: 50%;
  width: 150%;
  height: 150%;
  background: conic-gradient(transparent, transparent, transparent, #ffeb3b);
  animation: animateBorderMove 3s linear infinite;
  z-index: -2;
}

.cal-day-cell.cal-day-today::after {
  content: '';
  position: absolute;
  inset: 2px;
  background: var(--green-gradient);
  border-radius: 8px;
  z-index: -1;
}

.cal-day-cell.cal-day-today .cal-day-num,
.cal-day-cell.cal-day-kunami .cal-day-num,
.cal-day-cell.cal-day-today .cal-day-olchiki,
.cal-day-cell.cal-day-kunami .cal-day-olchiki,
.cal-day-cell.cal-day-today .cal-day-moon-name,
.cal-day-cell.cal-day-kunami .cal-day-moon-name {
  color: #ffffff !important;
}

.cal-day-cell.cal-day-kunami svg,
.cal-day-cell.cal-day-today svg {
  fill: #ffffff !important;
  stroke: #ffffff !important;
}

.cal-day-num {
  font-family: 'Outfit', sans-serif;
  font-size: 1.4rem;
  font-weight: 700;
  color: var(--text-main);
  line-height: 1;
}

.cal-day-cell.cal-day-sun .cal-day-num { color: #c0392b; }
.cal-day-cell.cal-day-sat .cal-day-num { color: var(--green-mid); }

.cal-day-olchiki, .cal-day-moon-name {
  font-size: 0.6rem;
  font-weight: 700;
  color: var(--green-mid);
  text-align: center;
  margin-top: 2px;
}

.cal-day-moon-name {
  font-family: 'Noto Sans Ol Chiki', 'Outfit', sans-serif;
}

.cal-day-moon {
  font-size: 1.4rem;
  line-height: 1;
}

.cal-day-dot {
  position: absolute;
  top: 6px;
  right: 6px;
  width: 8px;
  height: 8px;
  border-radius: 50%;
}

.cal-legend {
  display: flex;
  flex-wrap: wrap;
  gap: 18px;
  padding: 14px 20px;
  border-top: 1px solid var(--border);
  font-size: 0.78rem;
  color: var(--text-sub);
}

.cal-legend-item {
  display: flex;
  align-items: center;
  gap: 6px;
}

.cal-legend-dot {
  width: 9px;
  height: 9px;
  border-radius: 50%;
  display: inline-block;
}

/* ── Side panel ── */
.cal-side-panel {
  display: flex;
  flex-direction: column;
  gap: 20px;
  height: 100%;
}

.cal-panel-card {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: 16px;
  padding: 18px 20px;
}

.month-summary-list {
  display: flex;
  flex-direction: column;
}

.month-summary-item {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 9px 0;
  border-top: 1px solid var(--border);
  font-size: 0.85rem;
}

.month-summary-item:first-child {
  border-top: none;
}

.month-summary-label {
  display: flex;
  align-items: center;
  gap: 8px;
  color: var(--text-sub);
}

.month-summary-label svg {
  width: 15px;
  height: 15px;
  color: var(--green-mid);
}

.month-summary-value {
  font-weight: 700;
  color: var(--text-main);
}

.cal-mini-promo {
  margin-top: 16px;
  background: var(--bg-subtle);
  border-radius: 12px;
  padding: 14px;
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 12px;
}

.cal-mini-promo-title {
  font-weight: 700;
  font-size: 0.85rem;
  color: var(--green-deep);
}

.cal-mini-promo-desc {
  font-size: 0.72rem;
  color: var(--text-muted);
  margin-top: 2px;
}

.cal-mini-promo button {
  flex-shrink: 0;
  width: 100%;
  background: var(--green-gradient);
  color: #ffffff;
  border: none;
  border-radius: 8px;
  padding: 10px 14px;
  font-weight: 700;
  font-size: 0.85rem;
  cursor: pointer;
  white-space: nowrap;
}

.cal-share-row {
  display: flex;
  gap: 10px;
  margin-top: 12px;
}

.cal-share-btn {
  width: 34px;
  height: 34px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  color: #ffffff;
}

.cal-share-btn svg {
  width: 16px;
  height: 16px;
}

.cal-share-url-row {
  display: flex;
  border: 1px solid var(--border-strong);
  border-radius: 10px;
  overflow: hidden;
  margin-top: 12px;
}

.cal-share-url-row span {
  flex: 1;
  min-width: 0;
  padding: 10px 12px;
  font-size: 0.78rem;
  color: var(--text-sub);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.cal-share-url-row button {
  flex-shrink: 0;
  width: 40px;
  background: var(--green-gradient);
  color: #ffffff;
  border: none;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
}

.cal-share-url-row button svg {
  width: 15px;
  height: 15px;
}

/* ── Selected day detail panel ── */
.cal-detail-back {
  display: flex;
  align-items: center;
  gap: 8px;
  background: none;
  border: none;
  cursor: pointer;
  font-weight: 700;
  font-size: 0.85rem;
  color: var(--green-deep);
  padding: 0 0 6px;
}

.cal-detail-date {
  font-size: 0.8rem;
  color: var(--text-muted);
  margin-bottom: 14px;
}

.cal-detail-highlight {
  background: var(--bg-subtle);
  border-radius: 12px;
  padding: 16px;
  display: flex;
  align-items: center;
  gap: 14px;
  margin-bottom: 16px;
}

.cal-detail-olchiki {
  font-size: 1.6rem;
  font-weight: 700;
  color: var(--green-mid);
  flex-shrink: 0;
}

.cal-detail-santali-label {
  font-size: 0.72rem;
  color: var(--text-muted);
}

.cal-detail-event-name {
  font-weight: 700;
  color: var(--text-main);
  font-size: 0.98rem;
}

.cal-detail-event-sub {
  font-size: 0.8rem;
  color: var(--green-mid);
}

.cal-detail-panchang-title {
  font-weight: 700;
  color: var(--text-main);
  font-size: 0.9rem;
  margin-bottom: 4px;
}

.cal-detail-panchang-item {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 9px 0;
  border-top: 1px solid var(--border);
  font-size: 0.85rem;
}

.cal-detail-panchang-label {
  display: flex;
  align-items: center;
  gap: 8px;
  color: var(--text-sub);
}

.cal-detail-panchang-value {
  font-weight: 700;
  color: var(--text-main);
}

.cal-detail-note {
  margin-top: 14px;
  background: var(--bg-subtle);
  border-radius: 10px;
  padding: 10px 12px;
  font-size: 0.75rem;
  color: var(--text-sub);
}

/* ── Timeline strip ── */
.cal-scroll-arrows {
  display: flex;
  gap: 8px;
}
.cal-scroll-arrows button {
  width: 28px;
  height: 28px;
  border-radius: 50%;
  border: 1px solid var(--border-strong);
  background: #ffffff;
  color: var(--text-main);
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all 0.2s;
  padding: 0;
}
.cal-scroll-arrows button:hover {
  background: var(--bg-subtle);
  border-color: var(--green-light);
}
.cal-scroll-arrows button svg {
  width: 16px;
  height: 16px;
}
.cal-timeline-strip::-webkit-scrollbar {
  display: none;
}
.cal-timeline-strip {
  display: flex;
  gap: 16px;
  overflow-x: auto;
  padding-top: 6px;
  -ms-overflow-style: none;  /* IE and Edge */
  scrollbar-width: none;  /* Firefox */
  scroll-behavior: smooth;
}

.cal-timeline-item {
  flex-shrink: 0;
  min-width: 170px;
  background: var(--bg-subtle);
  border-radius: 12px;
  padding: 12px 16px;
  display: flex;
  align-items: center;
  gap: 10px;
  position: relative;
}

.cal-timeline-item.is-next {
  border: 2px solid var(--green-light);
}

.cal-timeline-badge {
  position: absolute;
  top: -9px;
  right: 10px;
  background: var(--green-gradient);
  color: #ffffff;
  font-size: 0.6rem;
  font-weight: 700;
  padding: 2px 8px;
  border-radius: 6px;
  white-space: nowrap;
}

.cal-timeline-date {
  font-weight: 700;
  font-size: 0.78rem;
  color: var(--green-mid);
  line-height: 1.3;
  text-align: center;
}

.cal-timeline-name {
  font-weight: 700;
  font-size: 0.85rem;
  color: var(--text-main);
}

.cal-timeline-desc {
  font-size: 0.72rem;
  color: var(--text-muted);
}

/* ── 3-column: guides / faq / facts ── */
.cal-three-col {
  display: grid;
  grid-template-columns: 1fr 1fr 1fr;
  gap: 20px;
  align-items: stretch;
}

.cal-guides-list {
  display: flex;
  flex-direction: column;
}

.cal-guide-link {
  display: flex;
  gap: 10px;
  padding: 10px 0;
  border-top: 1px solid var(--border);
  text-decoration: none;
  align-items: flex-start;
}

.cal-guide-link:first-child {
  border-top: none;
}

.cal-guide-icon {
  width: 30px;
  height: 30px;
  border-radius: 8px;
  background: var(--green-pale);
  color: var(--green-deep);
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}

.cal-guide-icon svg {
  width: 15px;
  height: 15px;
}

.cal-guide-title {
  font-weight: 700;
  font-size: 0.85rem;
  color: var(--text-main);
}

.cal-guide-desc {
  font-size: 0.75rem;
  color: var(--text-muted);
  line-height: 1.4;
}



@media (max-width: 980px) {
  .cal-main-grid,
  .cal-top-row {
    grid-template-columns: 1fr;
  }

  .cal-three-col {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 600px) {
  .cal-page-container {
    padding: 16px 14px 32px;
    gap: 18px;
  }

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

  .cal-toolbar-today-btn {
    margin-left: 0;
    grid-column: 1 / -1;
  }

  .cal-facts-grid {
    grid-template-columns: 1fr;
  }
}

#cal-panel-default {
  display: grid;
  grid-template-columns: 1.4fr 1fr;
  gap: 20px;
  align-items: stretch;
  height: 100%;
}


@media (max-width: 900px) {
  #cal-panel-default {
    grid-template-columns: 1fr;
  }
}

#cal-panel-default > .cal-panel-card {
  min-width: 0;
  display: flex;
  flex-direction: column;
}

/* Fix mobile calendar card overflow */
@media (max-width: 480px) {
  .cal-grid-head {
    gap: 6px;
    padding: 10px 8px;
  }
  .cal-grid-title {
    font-size: 1.15rem;
  }
  .cal-title-daterange {
    display: none;
  }
  .cal-grid-nav button {
    width: 28px;
    height: 28px;
    font-size: 0.85rem;
  }
  .cal-grid-today-btn {
    padding: 6px 10px;
    font-size: 0.7rem;
  }
  .calendar-card, .festival-card {
    padding-left: 8px;
    padding-right: 8px;
  }
  .cal-days {
    gap: 2px;
    padding: 4px;
  }
  .cal-day-cell {
    padding: 3px 2px;
  }
  .cal-day-num {
    font-size: 1.05rem;
  }
  .cal-day-moon {
    font-size: 1rem;
  }
  .cal-day-olchiki, .cal-day-moon-name {
    font-size: 0.5rem;
    line-height: 1.05;
    margin-top: 1px;
    letter-spacing: -0.3px;
  }
  .cal-weekdays > div {
    padding: 6px 0 4px;
  }
  .cal-weekdays .cal-wd-eng {
    font-size: 0.65rem;
  }
  .cal-weekdays .cal-wd-san {
    font-size: 0.65rem;
  }
}
/* Mobile Bottom Navigation Bar */
.mobile-bottom-nav {
  display: none;
}
@media (max-width: 800px) {
  body {
    padding-bottom: 85px;
  }
  .mobile-bottom-nav {
    display: flex;
    justify-content: space-around;
    align-items: center;
    position: fixed;
    bottom: 20px;
    left: 15px;
    right: 15px;
    background: #ffffff;
    border-radius: 40px;
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.08), 0 2px 8px rgba(0,0,0,0.04);
    border: 1px solid rgba(255, 255, 255, 0.6);
    padding: 8px 10px;
    z-index: 1000;
  }
  .mobile-bottom-nav-item {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    text-decoration: none;
    color: #666;
    font-size: 0.7rem;
    font-weight: 600;
    gap: 4px;
    flex: 1;
    -webkit-tap-highlight-color: transparent;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
  }
  .mobile-bottom-nav-item.active {
    color: #1a8a4a;
  }
  .mobile-bottom-nav-item .icon-wrapper {
    position: relative;
    display: flex;
    align-items: center;
    justify-content: center;
    width: 48px;
    height: 32px;
    border-radius: 16px;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
  }
  .mobile-bottom-nav-item.active .icon-wrapper {
    background: rgba(26, 138, 74, 0.12); /* Soft green pill */
  }
  .mobile-bottom-nav-item svg {
    width: 22px;
    height: 22px;
    stroke: currentColor;
    stroke-width: 2;
    fill: none;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
  }
  .mobile-bottom-nav-item.active svg {
    stroke-width: 2.5;
    transform: scale(1.05);
  }
}
/* Hover effects for Install and Join buttons */
.cta-band-btn {
  transition: all 0.3s ease;
}
.cta-band-btn:hover {
  transform: translateY(-3px);
  box-shadow: 0 6px 15px rgba(0, 0, 0, 0.15);
  opacity: 0.95;
}

.cal-mini-promo-btn {
  transition: all 0.3s ease;
  display: inline-block;
}
.cal-mini-promo-btn:hover {
  transform: translateY(-2px);
  box-shadow: 0 4px 12px rgba(26, 138, 74, 0.3);
  filter: brightness(1.1);
}
/* Hide Get App section on mobile if installed */
@media (max-width: 800px) {
  body.app-installed #get-app-section {
    display: none !important;
  }
  body.app-installed #home-install-btn {
    display: none !important;
  }
}
/* --- Custom Dropdowns --- */
.custom-dropdown-container {
  position: relative;
  display: inline-block;
  user-select: none;
}
.custom-dropdown-selected {
  background: #ffffff;
  border: 1px solid var(--border-strong);
  border-radius: 10px;
  padding: 8px 12px;
  color: var(--text-main);
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: space-between;
  box-shadow: 0 2px 4px rgba(0,0,0,0.05);
  transition: all 0.2s ease;
  font-family: 'Outfit', sans-serif;
  font-weight: 600;
  font-size: 0.85rem;
}
.custom-dropdown-selected:hover {
  background: var(--bg-card);
  border-color: var(--green-pale);
}
.custom-dropdown-selected.dropdown-open {
  border-color: var(--green-pale);
  box-shadow: 0 0 0 3px rgba(118,171,174,0.2);
}
.dropdown-chevron {
  margin-left: 10px;
  transition: transform 0.3s ease;
}
.custom-dropdown-selected.dropdown-open .dropdown-chevron {
  transform: rotate(180deg);
}
.custom-dropdown-options {
  position: absolute;
  top: calc(100% + 6px);
  left: 0;
  right: 0;
  background: var(--bg-card);
  border: 1px solid var(--border-color);
  border-radius: 8px;
  box-shadow: 0 8px 20px rgba(0,0,0,0.1);
  overflow-y: auto;
  max-height: 250px;
  z-index: 1000;
  opacity: 0;
  visibility: hidden;
  transform: translateY(-10px);
  transition: all 0.3s cubic-bezier(0.16, 1, 0.3, 1);
}
.custom-dropdown-options.show {
  opacity: 1;
  visibility: visible;
  transform: translateY(0);
}
.custom-dropdown-option {
  padding: 12px 16px;
  cursor: pointer;
  color: var(--text-main);
  border-bottom: 1px solid var(--border-color);
  transition: background 0.2s;
  font-family: 'Outfit', sans-serif;
  font-size: 0.85rem;
}
.custom-dropdown-option:last-child {
  border-bottom: none;
}
.custom-dropdown-option:hover {
  background: #f9f9f9;
  color: var(--primary);
}
.custom-dropdown-option.selected {
  background: rgba(118,171,174,0.1);
  color: var(--primary);
  font-weight: 600;
}

/* --- Flatpickr Custom Theme for Santali Calendar --- */
.flatpickr-calendar {
  font-family: 'Outfit', sans-serif !important;
  box-shadow: 0 12px 36px rgba(0,0,0,0.12) !important;
  border: none !important;
  border-radius: 16px !important;
  padding: 10px !important;
  width: 310px !important;
}
.flatpickr-innerContainer {
  margin-top: 5px;
}
.flatpickr-months {
  background: var(--green-gradient) !important;
  border-radius: 12px !important;
  padding: 8px 0 !important;
  margin-bottom: 5px !important;
}
.flatpickr-months .flatpickr-month {
  background: transparent !important;
  color: #ffffff !important;
  fill: #ffffff !important;
  height: 40px !important;
}
.flatpickr-current-month .flatpickr-monthDropdown-months {
  background: transparent !important;
  font-weight: 700 !important;
  font-size: 1.1rem !important;
  color: #ffffff !important;
  border-radius: 6px !important;
  padding: 4px !important;
}
.flatpickr-current-month .flatpickr-monthDropdown-months option {
  color: var(--text-main) !important;
  background: #ffffff !important;
}
.flatpickr-current-month .numInputWrapper {
  width: 7.5ch !important;
  background: rgba(255, 255, 255, 0.15) !important;
  border-radius: 4px !important;
  padding: 0 4px !important;
  margin-left: 6px !important;
}
.flatpickr-current-month .numInputWrapper:hover {
  background: rgba(255, 255, 255, 0.25) !important;
}
.flatpickr-current-month input.cur-year {
  font-weight: 700 !important;
  font-size: 1.1rem !important;
  color: #ffffff !important;
  background: transparent !important;
}
.flatpickr-current-month .numInputWrapper span.arrowUp,
.flatpickr-current-month .numInputWrapper span.arrowDown {
  opacity: 1 !important; /* always visible so user knows it's changeable */
  border: none !important;
}
.flatpickr-current-month .numInputWrapper span.arrowUp:after {
  border-bottom-color: #ffffff !important;
}
.flatpickr-current-month .numInputWrapper span.arrowDown:after {
  border-top-color: #ffffff !important;
}
.flatpickr-current-month .numInputWrapper span:hover {
  background: rgba(0,0,0,0.1) !important;
}
.flatpickr-weekdays {
  background: transparent !important;
}
span.flatpickr-weekday {
  color: var(--text-muted) !important;
  font-weight: 700 !important;
  font-size: 0.85rem !important;
}
.flatpickr-day {
  color: var(--text-main) !important;
  font-weight: 500 !important;
  border-radius: 8px !important;
  margin: 2px !important;
  height: 38px !important;
  line-height: 38px !important;
  max-width: 38px !important;
}
.flatpickr-day:hover {
  background: var(--bg-subtle) !important;
  border-color: var(--bg-subtle) !important;
}
.flatpickr-day.today {
  border-color: var(--primary) !important;
  background: rgba(118,171,174,0.08) !important;
  color: var(--primary) !important;
}
.flatpickr-day.selected, .flatpickr-day.startRange, .flatpickr-day.endRange, .flatpickr-day.selected.inRange, .flatpickr-day.startRange.inRange, .flatpickr-day.endRange.inRange, .flatpickr-day.selected:focus, .flatpickr-day.startRange:focus, .flatpickr-day.endRange:focus, .flatpickr-day.selected:hover, .flatpickr-day.startRange:hover, .flatpickr-day.endRange:hover, .flatpickr-day.selected.prevMonthDay, .flatpickr-day.startRange.prevMonthDay, .flatpickr-day.endRange.prevMonthDay, .flatpickr-day.selected.nextMonthDay, .flatpickr-day.startRange.nextMonthDay, .flatpickr-day.endRange.nextMonthDay {
  background: var(--green-gradient) !important;
  border-color: transparent !important;
  color: #ffffff !important;
  box-shadow: 0 4px 10px rgba(27, 107, 58, 0.3) !important;
}
.flatpickr-months .flatpickr-prev-month, .flatpickr-months .flatpickr-next-month {
  color: #ffffff !important;
  fill: #ffffff !important;
  top: 16px !important;
}
.flatpickr-months .flatpickr-prev-month {
  left: 10px !important;
}
.flatpickr-months .flatpickr-next-month {
  right: 10px !important;
}
.flatpickr-months .flatpickr-prev-month svg, .flatpickr-months .flatpickr-next-month svg {
  fill: #ffffff !important;
  color: #ffffff !important;
}
.flatpickr-months .flatpickr-prev-month:hover, .flatpickr-months .flatpickr-next-month:hover {
  color: #fdd835 !important;
  fill: #fdd835 !important;
}
.flatpickr-months .flatpickr-prev-month:hover svg, .flatpickr-months .flatpickr-next-month:hover svg {
  fill: #fdd835 !important;
  color: #fdd835 !important;
}
.flatpickr-day.flatpickr-disabled {
  color: var(--text-muted) !important;
}
/* =========================================
   Guide Content Redesign (V2 Premium)
========================================= */

.guide-content {
  color: var(--text-base);
  font-size: 1.05rem;
  line-height: 1.7;
}

.guide-content h2 {
  font-family: 'Baloo 2', sans-serif;
  color: var(--primary);
  font-size: 1.75rem;
  margin-top: 2.5rem;
  margin-bottom: 1rem;
  padding-bottom: 0.5rem;
  border-bottom: 2px solid var(--border-light);
  display: flex;
  align-items: center;
  gap: 12px;
}

.guide-content h3 {
  font-family: 'Outfit', sans-serif;
  color: var(--text-strong);
  font-size: 1.25rem;
  font-weight: 700;
  margin-top: 1.8rem;
  margin-bottom: 0.8rem;
}

/* TOC Widget */
.guide-toc-widget {
  background: var(--bg-subtle);
  border: 1px solid var(--border-strong);
  border-radius: 16px;
  padding: 24px;
  margin-bottom: 30px;
  box-shadow: 0 4px 15px rgba(0,0,0,0.03);
}

.guide-toc-widget .toc-title {
  font-family: 'Baloo 2', sans-serif;
  font-size: 1.4rem;
  color: var(--primary);
  margin-top: 0;
  margin-bottom: 16px;
  display: flex;
  align-items: center;
  gap: 8px;
}

.guide-toc-list {
  list-style: none;
  padding: 0;
  margin: 0;
  display: grid;
  grid-template-columns: 1fr;
  gap: 12px;
}

@media (min-width: 768px) {
  .guide-toc-list {
    grid-template-columns: 1fr 1fr;
  }
}

.guide-toc-item a {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  text-decoration: none;
  color: var(--text-strong);
  font-weight: 500;
  padding: 10px 14px;
  border-radius: 8px;
  background: white;
  border: 1px solid var(--border-light);
  transition: all 0.25s ease;
}

.guide-toc-item a:hover {
  background: var(--green-light);
  border-color: var(--primary);
  color: var(--primary);
  transform: translateX(4px);
  box-shadow: 0 2px 8px rgba(36, 129, 70, 0.15);
}

.guide-toc-item .toc-icon {
  color: var(--primary);
  flex-shrink: 0;
  margin-top: 2px;
}

/* Prevent horizontal overflow from tables/code blocks on mobile */
.guide-content table {
  display: block;
  overflow-x: auto;
  -webkit-overflow-scrolling: touch;
  max-width: 100%;
}

.guide-content pre {
  overflow-x: auto;
  -webkit-overflow-scrolling: touch;
  max-width: 100%;
}

.guide-content img {
  max-width: 100%;
  height: auto;
}

/* Redesigned Highlight Boxes */
.guide-content .highlight-box {
  background: var(--green-pale);
  border-radius: 12px;
  padding: 20px 24px;
  margin: 24px 0;
  border-left: 5px solid var(--primary);
  box-shadow: 0 2px 10px rgba(0,0,0,0.03);
  position: relative;
}

.guide-content .highlight-box h3 {
  margin-top: 0;
  color: var(--primary);
  display: flex;
  align-items: center;
  gap: 8px;
}

/* Custom Lists */
.guide-content ul:not(.guide-toc-list) {
  list-style: none;
  padding-left: 0;
  margin-bottom: 20px;
}

.guide-content ul:not(.guide-toc-list) > li {
  position: relative;
  padding-left: 32px;
  margin-bottom: 10px;
}

.guide-content ul:not(.guide-toc-list) > li::before {
  content: "";
  position: absolute;
  left: 0;
  top: 6px;
  width: 20px;
  height: 20px;
  background-image: url('data:image/svg+xml;utf8,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 24 24" fill="none" stroke="%23248146" stroke-width="2.5" stroke-linecap="round" stroke-linejoin="round"><path d="M22 11.08V12a10 10 0 1 1-5.93-9.14"></path><polyline points="22 4 12 14.01 9 11.01"></polyline></svg>');
  background-size: contain;
  background-repeat: no-repeat;
}

.guide-content strong {
  color: var(--text-strong);
  font-weight: 700;
}

.guide-content em {
  color: var(--primary);
  font-style: italic;
  font-weight: 500;
}

/* =========================================
   Guide Right Sidebar Layout
========================================= */

.guide-layout-grid {
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  gap: 24px;
  align-items: start;
}

@media (min-width: 992px) {
  .guide-layout-grid {
    grid-template-columns: minmax(0, 1fr) 320px;
  }
}

@media (max-width: 600px) {
  .guide-layout-grid .cal-panel-card {
    padding: 18px !important;
  }

  .guide-content {
    padding: 0 !important;
  }
}

.guide-sidebar {
  position: sticky;
  top: 100px;
  display: flex;
  flex-direction: column;
  gap: 24px;
}

/* Sidebar Widgets */
.sidebar-widget {
  background: white;
  border-radius: 16px;
  border: 1px solid var(--border-light);
  padding: 24px;
  box-shadow: 0 4px 15px rgba(0,0,0,0.02);
}

.sidebar-widget-title {
  font-family: 'Baloo 2', sans-serif;
  font-size: 1.3rem;
  color: var(--primary);
  margin-top: 0;
  margin-bottom: 16px;
  display: flex;
  align-items: center;
  gap: 8px;
  border-bottom: 1px solid var(--border-light);
  padding-bottom: 10px;
}

/* Quick Facts Widget */
.fact-list {
  list-style: none;
  padding: 0;
  margin: 0;
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.fact-list li {
  font-size: 0.95rem;
  color: var(--text-secondary);
  display: flex;
  align-items: flex-start;
  gap: 8px;
}

.fact-list li strong {
  color: var(--text-strong);
  display: block;
}

.fact-list .fact-icon {
  color: var(--gold);
  flex-shrink: 0;
  margin-top: 2px;
}

/* Related Links */
.related-links {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.related-link {
  display: flex;
  align-items: center;
  gap: 8px;
  text-decoration: none;
  color: var(--text-strong);
  font-size: 0.95rem;
  font-weight: 500;
  padding: 10px 14px;
  background: var(--bg-subtle);
  border-radius: 8px;
  transition: all 0.2s ease;
  border: 1px solid transparent;
}

.related-link:hover {
  background: white;
  border-color: var(--primary);
  color: var(--primary);
  transform: translateX(4px);
  box-shadow: 0 2px 8px rgba(36, 129, 70, 0.1);
}

/* Share Buttons */
.share-buttons {
  display: flex;
  gap: 10px;
}

.share-btn {
  flex: 1;
  display: flex;
  justify-content: center;
  align-items: center;
  height: 44px;
  border-radius: 8px;
  color: white;
  text-decoration: none;
  transition: opacity 0.2s;
}

.share-btn:hover {
  opacity: 0.85;
}

.share-fb { background: #1877F2; }
.share-tw { background: #1DA1F2; }
.share-wa { background: #25D366; }

/* ==========================================================================
   FESTIVAL PAGE REDESIGN STYLES
   ========================================================================== */

.fest-page {
  font-family: 'Montserrat', sans-serif;
  background-color: #f9fbf9;
  color: #333;
  width: 100%;
  max-width: 1240px;
  margin: 0 auto;
  padding: 0 24px 40px;
}

/* --- Hero Section --- */
.fest-hero {
  position: relative;
  min-height: 480px;
  display: flex;
  align-items: center;
  padding: 40px 0;
  overflow: hidden;
  background: #f9fbf9;
}

.fest-hero-bg {
  position: absolute;
  top: 0;
  right: 0;
  bottom: 0;
  width: 60%;
  z-index: 0;
}

.fest-hero-bg img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: right center;
}

.fest-hero-overlay {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: linear-gradient(90deg, #f9fbf9 0%, rgba(249, 251, 249, 0.8) 30%, rgba(249, 251, 249, 0) 100%);
  z-index: 1;
}

.fest-hero-content {
  position: relative;
  z-index: 2;
  max-width: 650px;
}

.fest-breadcrumb {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 0.85rem;
  color: #555;
  margin-bottom: 24px;
}
.fest-breadcrumb a {
  color: #555;
  text-decoration: none;
}
.fest-breadcrumb a:hover {
  color: var(--green-deep, #0d4a25);
}

.fest-title {
  font-size: 3rem;
  font-weight: 700;
  color: var(--green-deep, #0d4a25);
  margin: 0 0 16px 0;
  line-height: 1.1;
}

.fest-title-divider {
  display: flex;
  align-items: center;
  gap: 10px;
  color: var(--green-deep, #0d4a25);
  margin-bottom: 24px;
}
.fest-title-divider hr {
  flex: 1;
  border: none;
  border-top: 1px solid rgba(13, 74, 37, 0.2);
  margin: 0;
  max-width: 150px;
}

.fest-subtitle {
  font-size: 1.1rem;
  color: #444;
  line-height: 1.6;
  margin-bottom: 40px;
}

.fest-stats-row {
  display: flex;
  gap: 16px;
  flex-wrap: wrap;
}

.fest-stat-card {
  background: white;
  border-radius: 12px;
  padding: 16px 20px;
  display: flex;
  align-items: center;
  gap: 16px;
  box-shadow: 0 4px 15px rgba(0,0,0,0.05);
  min-width: 180px;
}

.stat-icon {
  width: 48px;
  height: 48px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
}
.stat-icon svg { width: 24px; height: 24px; }
.stat-icon-green { background: #e8f5e9; color: #2e7d32; }
.stat-icon-yellow { background: #fff8e1; color: #ff8f00; }
.stat-icon-lightgreen { background: #e0f2f1; color: #00897b; }
.stat-icon-purple { background: #f3e5f5; color: #8e24aa; }

.stat-info {
  display: flex;
  flex-direction: column;
}
.stat-label { font-size: 0.75rem; color: #666; margin-bottom: 4px; }
.stat-value { font-size: 1.25rem; font-weight: 700; color: #222; }

/* --- Controls Section --- */
.fest-controls-section {
  padding: 0;
  margin-top: 0px;
  position: relative;
  z-index: 10;
}

.fest-search-bar {
  display: flex;
  gap: 16px;
  margin-bottom: 16px;
}

.fest-search-input-wrapper {
  flex: 1;
  display: flex;
  background: white;
  border: 1px solid #ddd;
  border-radius: 8px;
  padding: 4px;
  align-items: center;
  box-shadow: 0 2px 10px rgba(0,0,0,0.03);
}

.search-icon {
  width: 20px;
  height: 20px;
  color: #888;
  margin: 0 12px;
}

#fest-search-input {
  flex: 1;
  min-width: 0;
  border: none;
  outline: none;
  padding: 12px 0;
  font-size: 1rem;
  font-family: inherit;
}

.fest-search-btn {
  background: #f9fbf9;
  color: white;
  border: none;
  padding: 0 24px;
  height: 100%;
  border-radius: 6px;
  font-weight: 600;
  cursor: pointer;
}

.fest-filter-toggle-btn {
  background: #f1f8f4;
  color: var(--green-deep, #0d4a25);
  border: 1px solid #d4e8dd;
  border-radius: 8px;
  padding: 0 20px;
  display: flex;
  align-items: center;
  gap: 8px;
  font-weight: 600;
  cursor: pointer;
}

.fest-filter-toggle-btn .toggle-chevron {
  transition: transform 0.25s ease;
}

.fest-filter-toggle-btn.collapsed .toggle-chevron {
  transform: rotate(180deg);
}

.fest-filters-row {
  display: flex;
  background: white;
  border-radius: 8px;
  border: 1px solid #eee;
  padding: 16px 20px;
  gap: 24px;
  margin-bottom: 24px;
  box-shadow: 0 2px 10px rgba(0,0,0,0.02);
  align-items: flex-end;
  flex-wrap: wrap;
  overflow: visible;
  max-height: 300px;
  opacity: 1;
  transition: max-height 0.3s ease, opacity 0.25s ease, padding 0.3s ease, margin 0.3s ease, border-width 0.3s ease;
}

/* Only clip while the collapse/expand animation is actually running,
   so open dropdown option panels (position:absolute, taller than the
   row) aren't cut off once the row is fully expanded. */
.fest-filters-row.animating-collapse {
  overflow: hidden;
}

.fest-filters-row.collapsed {
  max-height: 0;
  opacity: 0;
  padding-top: 0;
  padding-bottom: 0;
  margin-bottom: 0;
  border-width: 0;
}

.fest-filter-group {
  display: flex;
  flex-direction: column;
  gap: 8px;
}
.fest-filter-group label {
  font-size: 0.8rem;
  font-weight: 600;
  color: #333;
}

.fest-select-wrapper {
  position: relative;
  display: flex;
  align-items: center;
}
.fest-select-wrapper .sel-icon {
  position: absolute;
  left: 12px;
  color: #6a9b75;
}
.fest-select-wrapper select {
  appearance: none;
  padding: 10px 36px 10px 36px;
  border: 1px solid #e0e0e0;
  border-radius: 6px;
  font-family: inherit;
  font-size: 0.9rem;
  color: #333;
  background: white;
  cursor: pointer;
  width: 100%;
  min-width: 150px;
}
.fest-select-wrapper::after {
  content: '';
  position: absolute;
  right: 12px;
  border-left: 5px solid transparent;
  border-right: 5px solid transparent;
  border-top: 5px solid #666;
  pointer-events: none;
  display: none;
}

.fest-view-toggle {
  display: flex;
  background: #f5f5f5;
  border-radius: 6px;
  padding: 4px;
}
.fest-view-toggle button {
  border: none;
  background: transparent;
  padding: 8px 16px;
  border-radius: 4px;
  display: flex;
  align-items: center;
  gap: 6px;
  font-weight: 600;
  color: #666;
  cursor: pointer;
  font-family: inherit;
}
.fest-view-toggle button.active {
  background: #f9fbf9;
  color: white;
}

.fest-popular-row {
  display: flex;
  align-items: center;
  background: #f1f6f1;
  padding: 16px 24px;
  border-radius: 8px;
  gap: 16px;
  flex-wrap: wrap;
}
.fest-popular-label {
  font-weight: 700;
  color: #333;
}
.fest-popular-tags {
  display: flex;
  gap: 12px;
  flex-wrap: wrap;
}
.fest-popular-tags span {
  background: white;
  padding: 6px 16px;
  border-radius: 20px;
  font-size: 0.85rem;
  color: #555;
  border: 1px solid #e0e0e0;
  cursor: pointer;
  transition: all 0.3s ease;
}
.fest-popular-tags span:hover {
  background: linear-gradient(135deg, var(--green-primary, #1a5c38) 0%, var(--green-deep, #0d4a25) 100%);
  color: white;
  border-color: var(--green-deep, #0d4a25);
  box-shadow: 0 4px 10px rgba(13, 74, 37, 0.2);
}

/* --- Main Layout --- */
.fest-main-area {
  padding: 40px 0;
}

.fest-main-header-mobile { display: none; }
.fest-main-header-desktop {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  margin-bottom: 24px;
}
.fest-main-header-desktop h3 {
  font-size: 1.6rem;
  margin: 0 0 8px 0;
  color: #222;
}
.fest-subtitle-text {
  color: #666;
  font-size: 0.95rem;
}
.fest-main-header-controls {
  display: flex;
  align-items: center;
  gap: 20px;
}
.mini-select select {
  min-width: auto;
  padding: 8px 30px 8px 12px;
}
.mini-select::after { right: 10px; }
.mini-select .sel-icon { display: none; }
.fest-view-toggle.mini button { padding: 6px 12px; font-size: 0.85rem; }

.fest-layout {
  display: grid;
  grid-template-columns: 280px minmax(0, 1fr);
  gap: 30px;
}

.fest-sidebar {
  display: flex;
  flex-direction: column;
  gap: 24px;
}

.sidebar-block {
  background: white;
  border-radius: 12px;
  padding: 24px;
  box-shadow: 0 2px 12px rgba(0,0,0,0.03);
  border: 1px solid #f0f0f0;
}

.sidebar-block-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 20px;
  border-bottom: 1px solid #eee;
  padding-bottom: 12px;
}
.sidebar-block-header h4 { margin: 0; font-size: 1.1rem; color: #222; }
.clear-filters-btn {
  background: none;
  border: none;
  color: #2e7d32;
  font-size: 0.8rem;
  font-weight: 600;
  display: flex;
  align-items: center;
  gap: 4px;
  cursor: pointer;
}

.sidebar-filter-section h5 {
  font-size: 0.9rem;
  color: #444;
  margin: 0 0 12px 0;
}

.custom-checkbox {
  display: flex;
  align-items: center;
  margin-bottom: 10px;
  font-size: 0.9rem;
  color: #555;
  cursor: pointer;
  position: relative;
  padding-left: 28px;
}
.custom-checkbox input {
  position: absolute;
  opacity: 0;
  cursor: pointer;
  height: 0;
  width: 0;
}
.checkmark {
  position: absolute;
  top: 0;
  left: 0;
  height: 18px;
  width: 18px;
  background-color: #fff;
  border: 1px solid #ccc;
  border-radius: 4px;
}
.custom-checkbox:hover input ~ .checkmark { background-color: #f1f1f1; }
.custom-checkbox input:checked ~ .checkmark {
  background-color: var(--green-deep, #0d4a25);
  border-color: var(--green-deep, #0d4a25);
}
.checkmark:after {
  content: "";
  position: absolute;
  display: none;
  left: 6px;
  top: 2px;
  width: 4px;
  height: 10px;
  border: solid white;
  border-width: 0 2px 2px 0;
  transform: rotate(45deg);
}
.custom-checkbox input:checked ~ .checkmark:after { display: block; }

.dot-indicator {
  display: inline-block;
  width: 8px;
  height: 8px;
  border-radius: 50%;
  margin-left: auto;
}
.bg-green { background: #2e7d32; }
.bg-orange { background: #f57c00; }
.bg-lightgreen { background: #7cb342; }
.bg-blue { background: #1976d2; }
.bg-purple { background: #8e24aa; }

.mt-4 { margin-top: 24px; }
.w-full { width: 100%; }

.upcoming-block h4 {
  margin: 0 0 16px 0;
  font-size: 1.1rem;
  color: var(--green-deep, #0d4a25);
}

.fest-upcoming-item {
  display: flex;
  gap: 12px;
  margin-bottom: 16px;
  align-items: center;
}
.upcoming-date-box {
  background: #f5f9f5;
  border: 1px solid #e0ebe0;
  border-radius: 8px;
  min-width: 50px;
  padding: 8px 0;
  text-align: center;
  display: flex;
  flex-direction: column;
}
.upcoming-date-box .d { font-size: 1.2rem; font-weight: 700; color: #333; line-height: 1; }
.upcoming-date-box .m { font-size: 0.75rem; color: #666; margin-top: 2px; text-transform: uppercase; }
.upcoming-info { flex: 1; }
.upcoming-info h5 { margin: 0 0 4px 0; font-size: 0.95rem; color: #222; }
.upcoming-info p { margin: 0; font-size: 0.8rem; color: #666; }
.upcoming-info .san { font-family: 'Noto Sans Ol Chiki', sans-serif; font-size: 0.75rem; color: #888; }
.view-all-upcoming {
  display: block;
  text-align: center;
  color: var(--green-deep, #0d4a25);
  font-weight: 600;
  font-size: 0.9rem;
  text-decoration: none;
  padding-top: 12px;
  border-top: 1px dashed #ddd;
  margin-top: 16px;
}

/* --- Festival Grid Cards --- */
.fest-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 24px;
}

/* Responsiveness for the 3-column grid */
@media (max-width: 1100px) {
  .fest-grid {
    grid-template-columns: repeat(2, 1fr);
  }
}
@media (max-width: 650px) {
  .fest-grid {
    grid-template-columns: 1fr;
    gap: 12px;
  }
}


.fest-card {
  background: white;
  border-radius: 12px;
  overflow: hidden;
  box-shadow: 0 4px 15px rgba(0,0,0,0.06);
  border: 1px solid #f0f0f0;
  transition: transform 0.2s;
  display: flex;
  flex-direction: column;
}
.fest-card:hover {
  transform: translateY(-4px);
  box-shadow: 0 8px 25px rgba(0,0,0,0.1);
}

.fest-card-img-wrap {
  position: relative;
  height: 180px;
}
.fest-card-img-wrap img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}
.fest-card-tag {
  position: absolute;
  top: 12px;
  left: 12px;
  background: rgba(0,0,0,0.6);
  color: white;
  padding: 4px 10px;
  border-radius: 20px;
  font-size: 0.75rem;
  font-weight: 500;
  backdrop-filter: blur(4px);
}

.fest-card-countdown-badge {
  position: absolute;
  bottom: 12px;
  right: 12px;
  background: rgba(0,0,0,0.6);
  color: white;
  padding: 4px 10px;
  border-radius: 20px;
  font-size: 0.75rem;
  font-weight: 600;
  backdrop-filter: blur(4px);
  display: flex;
  align-items: center;
}
.fest-card-like {
  position: absolute;
  top: 12px;
  right: 12px;
  color: white;
  cursor: pointer;
  background: rgba(0,0,0,0.2);
  border-radius: 50%;
  width: 32px;
  height: 32px;
  display: flex;
  align-items: center;
  justify-content: center;
}
.fest-card-like:hover { background: rgba(0,0,0,0.4); }

.fest-card-body {
  padding: 20px;
  display: flex;
  flex-direction: column;
  flex: 1;
}

.fest-card-date-row {
  display: flex;
  gap: 16px;
  margin-bottom: 16px;
  align-items: stretch;
}
.fest-date-big {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  color: #2e7d32;
}
.fest-date-big .num { font-size: 2.2rem; font-weight: 700; line-height: 1; }
.fest-date-big .mon { font-size: 0.85rem; font-weight: 600; text-transform: uppercase; }

.fest-card-titles {
  flex: 1;
  display: flex;
  flex-direction: column;
  justify-content: center;
}
.fest-card-titles h4 {
  margin: 0 0 6px 0;
  font-size: 1.05rem;
  line-height: 1.3;
  color: #222;
}
.fest-card-titles p {
  margin: 0;
  font-size: 0.85rem;
  color: #666;
  line-height: 1.4;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.fest-card-meta {
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-size: 0.8rem;
  margin-top: 12px;
  padding-top: 12px;
  border-top: 1px solid #f0f0f0;
}
.fest-card-loc {
  display: flex;
  align-items: center;
  gap: 6px;
  color: #777;
}
.fest-card-countdown {
  color: #2e7d32;
  font-weight: 600;
}

.fest-card-action {
  margin-top: auto;
  padding-top: 16px;
  text-align: center;
}
.fest-card-action a {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  text-decoration: none;
  color: var(--green-deep, #0d4a25);
  font-weight: 600;
  font-size: 0.95rem;
}
.fest-card-action a:hover { text-decoration: underline; }

@media (max-width: 650px) {
  .fest-card {
    flex-direction: row;
  }

  .fest-card-img-wrap {
    width: 110px;
    height: auto;
    flex-shrink: 0;
  }

  .fest-card-tag {
    top: 8px;
    left: 8px;
    font-size: 0.6rem;
    padding: 3px 7px;
    max-width: calc(100% - 16px);
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
  }

  .fest-card-like {
    top: 8px;
    right: 8px;
    width: 24px;
    height: 24px;
  }

  .fest-card-like svg {
    width: 12px;
    height: 12px;
  }

  .fest-card-countdown-badge {
    bottom: 8px;
    right: 8px;
    font-size: 0.56rem;
    padding: 2px 6px;
  }

  .fest-card-body {
    padding: 12px;
  }

  .fest-card-date-row {
    gap: 8px;
    margin-bottom: 4px;
  }

  .fest-date-big .num { font-size: 1.3rem; }
  .fest-date-big .mon { font-size: 0.6rem; }

  .fest-card-titles h4 {
    font-size: 0.88rem;
    line-height: 1.25;
    margin-bottom: 2px;
  }

  .fest-card-titles p {
    font-size: 0.72rem;
    line-height: 1.3;
    -webkit-line-clamp: 2;
  }
}

/* Pagination */
.fest-pagination {
  display: flex;
  justify-content: center;
  align-items: center;
  gap: 8px;
  margin-top: 40px;
}
.fest-pagination button {
  width: 36px;
  height: 36px;
  border: 1px solid #e0e0e0;
  background: white;
  border-radius: 6px;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  color: #555;
  font-family: inherit;
  font-size: 0.9rem;
}
.fest-pagination button.active {
  background: var(--green-deep, #0d4a25);
  color: white;
  border-color: var(--green-deep, #0d4a25);
}
.page-dots { color: #888; }

/* CTA Bottom */
.fest-add-cta {
  background: #fdfaf0;
  border: 1px solid #f2e2a9;
  border-radius: 12px;
  padding: 20px 30px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin: 40px 5%;
  flex-wrap: wrap;
  gap: 20px;
}
.cta-content {
  display: flex;
  align-items: center;
  gap: 12px;
  flex-wrap: wrap;
}
.cta-title { font-weight: 700; color: #333; font-size: 1.05rem; }
.cta-text { color: #555; font-size: 0.95rem; }
.cta-link { color: #d4a017; font-weight: 600; text-decoration: none; }
.cta-btn {
  background: var(--green-deep, #0d4a25);
  color: white;
  border: none;
  padding: 10px 24px;
  border-radius: 6px;
  font-weight: 600;
  cursor: pointer;
  text-decoration: none;
  display: inline-block;
  transition: all 0.2s var(--ease-smooth);
}

.cta-btn:hover {
  background: var(--green-mid, #1a8a4a);
  transform: translateY(-1px);
}

/* Responsive */
@media (max-width: 1024px) {
  .fest-layout { grid-template-columns: minmax(0, 1fr); }
  .fest-hero-bg { width: 100%; opacity: 0.4; }
  .fest-hero-overlay { background: linear-gradient(90deg, #f9fbf9 0%, rgba(249, 251, 249, 0.9) 100%); }
}

@media (max-width: 768px) {
  .fest-title { font-size: 2.2rem; }
  .fest-filters-row { flex-direction: column; align-items: stretch; flex-wrap: nowrap; max-height: 800px; }
  .fest-filter-group { width: 100%; }
  .fest-main { order: 1; }
  .fest-sidebar { order: 2; }
  .fest-search-bar { flex-direction: column; }
  .fest-search-btn { padding: 12px; }
  .fest-main-header-desktop { display: none; }
  .fest-main-header-mobile { display: block; margin-bottom: 24px; }
  .fest-main-header-mobile h3 { font-size: 1.5rem; margin: 0 0 8px 0; }
  .fest-add-cta { flex-direction: column; text-align: center; }
  .cta-content { justify-content: center; }
}

/* --- Festivals Hero Section (Separate) --- */
.fest-hero-section {
  position: relative;
  width: 100%;
  background: linear-gradient(135deg, rgba(13, 74, 37, 0.85) 0%, rgba(13, 74, 37, 0.6) 50%, rgba(13, 74, 37, 0.2) 100%), url('../assets/new-santali-hero.png');
  background-size: cover;
  background-position: center;
  border-radius: 24px;
  padding: 40px;
  margin-bottom: 24px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  overflow: hidden;
  box-sizing: border-box;
}
@media (max-width: 900px) {
  .fest-hero-section {
    flex-direction: column;
    padding: 30px 20px;
    gap: 30px;
  }
}

/* Custom Font solely for dates */
.page-santali .cal-day-num {
  font-family: 'Noto Sans Ol Chiki', 'olciki_okTe_TiTeol', sans-serif !important;
  font-weight: 700 !important;
}

.page-santali .cal-day-olchiki,
.page-santali .cal-detail-olchiki {
  font-family: 'olciki_okTe_TiTeol', 'Noto Sans Ol Chiki', sans-serif !important;
}

/* Custom font for grid title */
.cal-title-san {
  font-family: 'olciki_webx_ol', 'Noto Sans Ol Chiki', sans-serif !important;
  font-weight: bold;
}

/* ── Auth pages (login / register / profile) ── */
body.auth-body-center {
  align-items: center;
}

body.auth-body-center .auth-page-container {
  margin: 0 auto;
}

/* profile.html keeps the full site header/footer; make the card area
   fill the leftover space so the footer sticks to the bottom instead
   of leaving a trailing gap of body background beneath it. */
body.has-site-header .auth-page-container {
  flex: 1 0 auto;
  display: flex;
  align-items: center;
  justify-content: center;
  width: 100%;
  margin: 0;
}

.auth-page-container {
  max-width: 440px;
  margin: 40px auto 60px;
  padding: 0 16px;
}

.auth-card {
  background: var(--bg-card, #ffffff);
  border: 1px solid var(--border);
  border-radius: 20px;
  padding: 36px 32px;
  box-shadow: var(--shadow-sm);
}

.auth-header {
  text-align: center;
  margin-bottom: 28px;
}

.auth-header h1 {
  font-family: 'Playfair Display', serif;
  font-size: 1.7rem;
  color: var(--green-deep);
  margin: 0 0 4px;
}

.auth-header p {
  font-family: 'Montserrat', sans-serif;
  font-size: 0.9rem;
  color: var(--text-sub);
  margin: 0;
}

.auth-form-group {
  display: flex;
  flex-direction: column;
  gap: 6px;
  margin-bottom: 16px;
}

.upload-status {
  font-size: 0.8rem;
  color: var(--text-sub);
  min-height: 1em;
}

.upload-status.success { color: var(--green-deep); }
.upload-status.error { color: #c0392b; }

.poster-preview-strip {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 10px;
}

.poster-preview-strip:empty {
  margin-top: 0;
}

.poster-preview-chip {
  position: relative;
  width: 64px;
  height: 64px;
  border-radius: 8px;
  overflow: hidden;
  border: 1px solid var(--border-strong);
}

.poster-preview-chip img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

.poster-preview-remove {
  position: absolute;
  top: 2px;
  right: 2px;
  width: 18px;
  height: 18px;
  border-radius: 50%;
  background: rgba(0,0,0,0.65);
  color: #fff;
  border: none;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 12px;
  line-height: 1;
  padding: 0;
}

.poster-preview-remove:hover {
  background: rgba(200,40,40,0.85);
}

.poster-url-row {
  display: flex;
  gap: 8px;
  margin-top: 8px;
}

.poster-url-row input {
  flex: 1;
}

.poster-url-add-btn {
  padding: 0 16px;
  border-radius: 8px;
  border: 1px solid var(--border-strong);
  background: var(--bg-card);
  color: var(--green-deep);
  font-weight: 600;
  font-size: 0.85rem;
  cursor: pointer;
  white-space: nowrap;
}

.poster-url-add-btn:hover {
  background: var(--green-pale, #e6f2ea);
}

.auth-label {
  font-family: 'Outfit', sans-serif;
  font-weight: 600;
  font-size: 0.9rem;
  color: var(--text-main);
}

.auth-input {
  padding: 12px 16px;
  border-radius: 12px;
  border: 1.5px solid var(--border-strong);
  background: var(--bg-subtle);
  font-family: 'Montserrat', sans-serif;
  font-size: 0.95rem;
  color: var(--text-main);
  outline: none;
  width: 100%;
  box-sizing: border-box;
  transition: all 0.25s var(--ease-smooth);
}

.auth-input:focus {
  border-color: var(--green-light);
  box-shadow: 0 0 0 3px rgba(45, 147, 83, 0.15);
  background: #ffffff;
}

.auth-btn {
  width: 100%;
  padding: 13px 24px;
  border-radius: 12px;
  border: none;
  font-family: 'Outfit', sans-serif;
  font-weight: 600;
  font-size: 0.95rem;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  transition: all 0.25s var(--ease-smooth);
}

.auth-btn-primary {
  background: var(--green-gradient);
  color: #ffffff;
  box-shadow: var(--shadow-sm);
  margin-top: 6px;
}

.auth-btn-primary:hover {
  background: var(--green-dark-gradient);
  transform: translateY(-2px);
}

.auth-btn-primary:disabled {
  opacity: 0.6;
  cursor: default;
  transform: none;
}

.auth-btn-google {
  background: #ffffff;
  color: var(--text-main);
  border: 1.5px solid var(--border-strong);
}

.auth-btn-google:hover {
  background: var(--bg-subtle);
}

.auth-divider {
  display: flex;
  align-items: center;
  gap: 12px;
  margin: 20px 0;
  color: var(--text-sub);
  font-family: 'Montserrat', sans-serif;
  font-size: 0.8rem;
}

.auth-divider::before,
.auth-divider::after {
  content: '';
  flex: 1;
  height: 1px;
  background: var(--border);
}

.auth-switch {
  text-align: center;
  margin-top: 22px;
  font-family: 'Montserrat', sans-serif;
  font-size: 0.9rem;
  color: var(--text-sub);
}

.auth-switch a {
  color: var(--green-deep);
  font-weight: 600;
  text-decoration: none;
}

.auth-switch a:hover {
  text-decoration: underline;
}

.auth-toast {
  padding: 12px 16px;
  border-radius: 12px;
  font-family: 'Montserrat', sans-serif;
  font-size: 0.85rem;
  font-weight: 500;
  margin-bottom: 18px;
  display: none;
}

.auth-toast.toast-success {
  display: block;
  background: rgba(46, 125, 50, 0.1);
  color: var(--green-deep);
  border: 1px solid rgba(46, 125, 50, 0.2);
}

.auth-toast.toast-error {
  display: block;
  background: rgba(192, 57, 43, 0.1);
  color: #c0392b;
  border: 1px solid rgba(192, 57, 43, 0.2);
}

.auth-profile-avatar {
  width: 84px;
  height: 84px;
  border-radius: 50%;
  margin: 0 auto 16px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: var(--green-deep);
  color: #ffffff;
  font-family: 'Outfit', sans-serif;
  font-weight: 700;
  font-size: 2rem;
  overflow: hidden;
}

.auth-profile-avatar img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.nav-user-btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
}

.nav-user-avatar {
  width: 26px;
  height: 26px;
  border-radius: 50%;
  background: var(--green-deep);
  color: #ffffff;
  display: flex;
  align-items: center;
  justify-content: center;
  font-family: 'Outfit', sans-serif;
  font-weight: 700;
  font-size: 0.75rem;
  overflow: hidden;
  flex-shrink: 0;
}

.nav-user-avatar img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

/* ── Admin panel ── */
.admin-page-container {
  max-width: 440px;
  margin: 80px auto;
  padding: 0 16px;
}

/* ── Admin dashboard shell (topbar + sidebar + content) ── */
.admin-body {
  display: block;
  padding: 0;
  background: #ffffff;
  background-image: none;
  min-height: 100vh;
}

.admin-shell {
  display: flex;
  flex-direction: column;
  min-height: 100vh;
}

.admin-topbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 12px 24px;
  background: var(--green-dark-gradient);
  border-bottom: 1px solid var(--green-deep);
  position: sticky;
  top: 0;
  z-index: 100;
}

.admin-topbar-brand {
  display: flex;
  align-items: center;
  gap: 10px;
  text-decoration: none;
  font-family: 'Outfit', sans-serif;
  font-weight: 700;
  font-size: 1.05rem;
  color: #ffffff;
}

.admin-topbar-brand img {
  width: 30px;
  height: 30px;
}

.admin-topbar-brand b {
  color: #ffffff;
}

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

.admin-icon-btn {
  width: 38px;
  height: 38px;
  border-radius: 50%;
  border: 1.5px solid rgba(255, 255, 255, 0.4);
  background: none;
  color: #ffffff;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  flex-shrink: 0;
}

.admin-icon-btn svg {
  width: 18px;
  height: 18px;
}

.admin-user-chip {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 6px 12px 6px 6px;
  border-radius: 30px;
  background: rgba(255, 255, 255, 0.15);
  font-family: 'Outfit', sans-serif;
  font-weight: 600;
  font-size: 0.85rem;
  color: #ffffff;
}

.admin-topbar-search {
  display: flex;
  align-items: center;
  gap: 8px;
  flex: 1;
  max-width: 380px;
  margin: 0 24px;
  padding: 8px 14px;
  border-radius: 10px;
  background: rgba(255, 255, 255, 0.15);
  border: 1px solid transparent;
  transition: all 0.2s var(--ease-smooth);
}

.admin-topbar-search:focus-within {
  border-color: rgba(255, 255, 255, 0.6);
  background: #ffffff;
}

.admin-topbar-search:focus-within svg {
  color: var(--text-sub);
}

.admin-topbar-search:focus-within input {
  color: var(--text-main);
}

.admin-topbar-search:focus-within input::placeholder {
  color: var(--text-sub);
}

.admin-topbar-search svg {
  width: 16px;
  height: 16px;
  color: rgba(255, 255, 255, 0.8);
  flex-shrink: 0;
}

.admin-topbar-search input {
  flex: 1;
  min-width: 0;
  border: none;
  background: none;
  outline: none;
  font-family: 'Montserrat', sans-serif;
  font-size: 0.85rem;
  color: #ffffff;
}

.admin-topbar-search input::placeholder {
  color: rgba(255, 255, 255, 0.7);
}

.admin-topbar-search kbd {
  font-family: 'Outfit', sans-serif;
  font-size: 0.7rem;
  color: var(--text-sub);
  background: #ffffff;
  border: 1px solid var(--border-strong);
  border-radius: 5px;
  padding: 1px 6px;
  flex-shrink: 0;
}

@media (max-width: 900px) {
  .admin-topbar-search {
    display: none;
  }
}

.admin-body-row {
  display: flex;
  flex: 1;
  align-items: stretch;
}

.admin-sidebar-profile {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 10px;
  margin-bottom: 14px;
  border-radius: 12px;
  background: rgba(255, 255, 255, 0.12);
}

.admin-sidebar-profile .nav-user-avatar {
  width: 36px;
  height: 36px;
  font-size: 0.9rem;
}

.admin-sidebar-profile-text {
  min-width: 0;
}

.admin-sidebar-profile-name {
  font-family: 'Outfit', sans-serif;
  font-weight: 700;
  font-size: 0.88rem;
  color: #ffffff;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.admin-sidebar-profile-role {
  font-family: 'Montserrat', sans-serif;
  font-size: 0.72rem;
  color: var(--green-pale);
  font-weight: 600;
}

.admin-sidebar-nav {
  width: 220px;
  flex-shrink: 0;
  background: var(--green-dark-gradient);
  border-right: 1px solid var(--green-deep);
  padding: 20px 14px;
  display: flex;
  flex-direction: column;
  gap: 2px;
  position: sticky;
  top: 63px;
  height: calc(100vh - 63px);
  overflow-y: auto;
}

.admin-sidebar-group-label {
  font-family: 'Outfit', sans-serif;
  font-weight: 700;
  font-size: 0.7rem;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: rgba(255, 255, 255, 0.65);
  padding: 6px 14px 8px;
}

.role-switch-toggle {
  display: flex;
  background: rgba(255, 255, 255, 0.15);
  border-radius: 30px;
  padding: 4px;
  gap: 4px;
  margin: 4px 12px 12px;
}

.role-switch-btn {
  flex: 1;
  text-align: center;
  padding: 7px 10px;
  border-radius: 24px;
  border: none;
  background: transparent;
  font-family: 'Outfit', sans-serif;
  font-weight: 700;
  font-size: 0.78rem;
  text-decoration: none;
  color: rgba(255, 255, 255, 0.8);
  cursor: pointer;
  transition: all 0.2s ease;
}

.role-switch-btn.active {
  background: #ffffff;
  color: var(--green-deep);
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.15);
}

.role-switch-btn:not(.active):hover {
  background: rgba(255, 255, 255, 0.15);
  color: #ffffff;
}

.admin-sidebar-link {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 10px 14px;
  border: none;
  border-radius: 10px;
  background: none;
  font-family: 'Outfit', sans-serif;
  font-weight: 600;
  font-size: 0.9rem;
  color: rgba(255, 255, 255, 0.85);
  cursor: pointer;
  text-align: left;
  text-decoration: none;
  width: 100%;
  transition: all 0.2s var(--ease-smooth);
}

.admin-sidebar-link svg {
  width: 18px;
  height: 18px;
  flex-shrink: 0;
}

.admin-sidebar-link:hover {
  background: rgba(255, 255, 255, 0.12);
  color: #ffffff;
}

.admin-sidebar-link.active {
  color: var(--green-deep);
  background: #ffffff;
}

.admin-sidebar-badge {
  margin-left: auto;
  background: #e85d5d;
  color: #fff;
  font-size: 0.68rem;
  font-weight: 700;
  min-width: 18px;
  height: 18px;
  border-radius: 9px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0 5px;
}

.admin-notifications-panel {
  position: fixed;
  width: 260px;
  background: #ffffff;
  border-radius: 14px;
  box-shadow: var(--shadow-lg);
  padding: 8px;
  z-index: 200;
  display: none;
  flex-direction: column;
  gap: 2px;
}

.admin-notifications-panel.open {
  display: flex;
}

.admin-notification-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  width: 100%;
  background: none;
  border: none;
  border-radius: 10px;
  padding: 10px 12px;
  cursor: pointer;
  text-align: left;
  font-family: 'Outfit', sans-serif;
  font-size: 0.85rem;
  color: var(--text-main);
  transition: background 0.15s;
}

.admin-notification-row:hover {
  background: var(--green-pale, #e6f2ea);
}

.admin-notification-row-count {
  background: var(--green-pale, #e6f2ea);
  color: var(--green-deep);
  font-weight: 700;
  font-size: 0.75rem;
  min-width: 22px;
  height: 22px;
  border-radius: 11px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0 6px;
}

.admin-sidebar-spacer {
  flex: 1;
}

.admin-sidebar-logout {
  color: #ff9a8f;
}

.admin-sidebar-logout:hover {
  background: rgba(255, 255, 255, 0.12);
  color: #ffb3ab;
}

.admin-main-content {
  flex: 1;
  min-width: 0;
  padding: 28px 32px 60px;
}

.admin-menu-toggle {
  display: none;
  width: 38px;
  height: 38px;
  border-radius: 50%;
  border: 1.5px solid rgba(255, 255, 255, 0.4);
  background: none;
  color: #ffffff;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  flex-shrink: 0;
}

.admin-menu-toggle svg {
  width: 20px;
  height: 20px;
}

.admin-sidebar-backdrop {
  display: none;
  position: fixed;
  inset: 0;
  background: rgba(9, 26, 15, 0.5);
  z-index: 190;
}

.admin-sidebar-backdrop.open {
  display: block;
}

@media (max-width: 700px) {
  .admin-menu-toggle {
    display: flex;
  }

  .admin-topbar-brand {
    min-width: 0;
    gap: 8px;
  }

  .admin-topbar-brand span {
    font-size: 0.82rem;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
  }

  .admin-user-chip span:not(.nav-user-avatar) {
    max-width: 90px;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
  }

  .admin-sidebar-nav {
    position: fixed;
    top: 0;
    left: 0;
    width: 260px;
    max-width: 80vw;
    height: 100vh;
    flex-direction: column;
    overflow-x: hidden;
    overflow-y: auto;
    padding: 20px 14px;
    transform: translateX(-100%);
    transition: transform 0.25s ease;
    z-index: 200;
  }

  .admin-sidebar-nav.open {
    transform: translateX(0);
  }

  .admin-main-content {
    padding: 20px 16px 60px;
  }
}

.admin-header {
  margin-bottom: 24px;
}

.admin-header h1 {
  font-family: 'Playfair Display', serif;
  font-size: 1.8rem;
  color: var(--green-deep);
  margin: 0 0 4px;
}

.admin-header p {
  font-family: 'Montserrat', sans-serif;
  font-size: 0.9rem;
  color: var(--text-sub);
  margin: 0;
}

.admin-card {
  background: var(--bg-card, #ffffff);
  border: 1px solid var(--border);
  border-radius: 16px;
  padding: 24px;
  box-shadow: var(--shadow-sm);
  margin-bottom: 24px;
}

.admin-card-header {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-bottom: 20px;
}

.admin-card-header .admin-card-icon {
  width: 36px;
  height: 36px;
  border-radius: 50%;
  background: rgba(45, 147, 83, 0.12);
  color: var(--green-deep);
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}

.admin-card-header .admin-card-icon svg {
  width: 18px;
  height: 18px;
}

.admin-card-header h2 {
  font-family: 'Outfit', sans-serif;
  font-weight: 700;
  font-size: 1.1rem;
  color: var(--text-main);
  margin: 0;
}

.admin-welcome h1 {
  font-family: 'Playfair Display', serif;
  font-size: 1.6rem;
  color: var(--text-main);
  margin: 0 0 4px;
}

.admin-welcome p {
  font-family: 'Montserrat', sans-serif;
  font-size: 0.9rem;
  color: var(--text-sub);
  margin: 0;
}

.admin-stat-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(160px, 1fr));
  gap: 16px;
  margin-bottom: 24px;
}

.admin-stat-card {
  background: var(--bg-card, #ffffff);
  border: 1px solid var(--border);
  border-radius: 16px;
  padding: 18px 20px;
  box-shadow: var(--shadow-sm);
  display: flex;
  align-items: center;
  gap: 14px;
}

.admin-stat-icon {
  width: 44px;
  height: 44px;
  border-radius: 12px;
  background: rgba(45, 147, 83, 0.12);
  color: var(--green-deep);
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}

.admin-stat-icon svg {
  width: 20px;
  height: 20px;
}

.admin-stat-label {
  font-family: 'Outfit', sans-serif;
  font-size: 0.78rem;
  color: var(--text-sub);
  font-weight: 600;
}

.admin-stat-value {
  font-family: 'Outfit', sans-serif;
  font-weight: 800;
  font-size: 1.5rem;
  color: var(--text-main);
  line-height: 1.2;
}

.admin-quick-actions {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(130px, 1fr));
  gap: 14px;
}

.admin-quick-action-btn {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 8px;
  padding: 18px 12px;
  border: 1px solid var(--border);
  border-radius: 14px;
  background: var(--bg-subtle);
  cursor: pointer;
  font-family: 'Outfit', sans-serif;
  font-weight: 600;
  font-size: 0.85rem;
  color: var(--text-main);
  transition: all 0.2s var(--ease-smooth);
}

.admin-quick-action-btn:hover {
  background: var(--green-deep);
  color: #ffffff;
  transform: translateY(-2px);
}

.admin-quick-action-btn svg {
  width: 22px;
  height: 22px;
}

.admin-recent-list {
  display: flex;
  flex-direction: column;
  gap: 2px;
}

.admin-recent-item {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 12px 4px;
  border-bottom: 1px solid var(--border);
  font-family: 'Montserrat', sans-serif;
  font-size: 0.88rem;
}

.admin-recent-item:last-child {
  border-bottom: none;
}

.admin-recent-item-name {
  color: var(--text-main);
  font-weight: 600;
}

.admin-recent-item-meta {
  color: var(--text-sub);
  font-size: 0.78rem;
}

.admin-dashboard-grid {
  display: grid;
  grid-template-columns: minmax(0, 1.3fr) minmax(0, 1fr);
  gap: 24px;
  align-items: start;
}

#tab-festivals .admin-dashboard-grid,
#tab-events .admin-dashboard-grid {
  grid-template-columns: minmax(0, 0.85fr) minmax(0, 1.4fr);
}

.event-status-pill {
  display: inline-block;
  font-size: 0.68rem;
  font-weight: 700;
  padding: 3px 10px;
  border-radius: 20px;
  text-transform: uppercase;
  letter-spacing: 0.4px;
  white-space: nowrap;
}

.event-status-pending { background: #fff3cd; color: #8a6d1a; }
.event-status-approved { background: #d6f3e0; color: #1c6b3f; }
.event-status-rejected { background: #fde0e0; color: #a33131; }

@media (max-width: 900px) {
  .admin-dashboard-grid,
  #tab-festivals .admin-dashboard-grid,
  #tab-events .admin-dashboard-grid {
    grid-template-columns: minmax(0, 1fr);
  }
}

.admin-panel[hidden] {
  display: none;
}

.admin-table-wrap {
  overflow-x: auto;
}

.admin-table {
  width: 100%;
  border-collapse: collapse;
  font-family: 'Montserrat', sans-serif;
  font-size: 0.9rem;
}

.admin-table .auth-btn {
  width: auto;
  display: inline-flex;
  margin-right: 4px;
}

.admin-table th {
  text-align: left;
  padding: 10px 12px;
  font-family: 'Outfit', sans-serif;
  font-weight: 600;
  font-size: 0.8rem;
  color: var(--text-sub);
  border-bottom: 1.5px solid var(--border-strong);
  white-space: nowrap;
}

.admin-table td {
  padding: 12px;
  border-bottom: 1px solid var(--border);
  color: var(--text-main);
  vertical-align: middle;
}

.admin-role-badge {
  display: inline-block;
  padding: 3px 10px;
  border-radius: 20px;
  font-family: 'Outfit', sans-serif;
  font-weight: 600;
  font-size: 0.75rem;
}

.admin-role-badge.role-admin {
  background: rgba(45, 147, 83, 0.15);
  color: var(--green-deep);
}

.admin-role-badge.role-user {
  background: var(--bg-subtle);
  color: var(--text-sub);
}

.admin-role-select {
  padding: 6px 10px;
  border-radius: 8px;
  border: 1.5px solid var(--border-strong);
  background: #ffffff;
  font-family: 'Montserrat', sans-serif;
  font-size: 0.85rem;
  cursor: pointer;
}

.admin-empty {
  text-align: center;
  padding: 30px;
  color: var(--text-sub);
  font-family: 'Montserrat', sans-serif;
}

/* ── Skeleton Loading ── */
@keyframes skeletonShimmer {
  0% { background-position: -200% 0; }
  100% { background-position: 200% 0; }
}

.skel {
  display: block;
  border-radius: 6px;
  background: linear-gradient(90deg, var(--bg-subtle) 25%, #f5faf6 50%, var(--bg-subtle) 75%);
  background-size: 200% 100%;
  animation: skeletonShimmer 1.4s ease-in-out infinite;
}

.skel-text {
  height: 0.85em;
  margin: 0.3em 0;
}

.skel-text.w-100 { width: 100%; }
.skel-text.w-80 { width: 80%; }
.skel-text.w-60 { width: 60%; }
.skel-text.w-40 { width: 40%; }
.skel-text.w-25 { width: 25%; }

.skel-circle {
  border-radius: 50%;
  flex-shrink: 0;
}

.skel-block {
  width: 100%;
  height: 100%;
}

.skel-btn {
  height: 32px;
  width: 80px;
  border-radius: 8px;
}

/* Festival/event card skeleton */
.skel-card {
  background: var(--bg-card);
  border-radius: 16px;
  border: 1px solid var(--border);
  padding: 14px;
  display: flex;
  gap: 14px;
  align-items: center;
}

.skel-card .skel-thumb {
  width: 72px;
  height: 72px;
  border-radius: 12px;
  flex-shrink: 0;
}

.skel-card .skel-card-body {
  flex: 1;
  min-width: 0;
}

/* Stat card skeleton */
.skel-stat-card {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: 16px;
  padding: 18px;
  display: flex;
  align-items: center;
  gap: 14px;
}

/* Table row skeleton */
.skel-table-row td {
  padding: 12px 10px;
}

/* List row skeleton (Recent Events / My Events / Recent Festivals) */
.skel-list-row {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 12px 4px;
  border-bottom: 1px solid var(--border);
}

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

.skel-list-row .skel-avatar {
  width: 38px;
  height: 38px;
  border-radius: 10px;
  flex-shrink: 0;
}

.skel-list-row .skel-list-body {
  flex: 1;
  min-width: 0;
}

@media (prefers-reduced-motion: reduce) {
  .skel {
    animation: none;
    background: var(--bg-subtle);
  }
}

