/* =========================================
   THEME VARIABLES (theme.css)
   Prabashi Durgotsav Samiti Mohan Garden
========================================= */

:root {
  --bg-dark: #0b0f19;
  --bg-card: #151b2b;

  --color-primary: #e63946;
  --color-secondary: #ff9f1c;
  --color-accent: #ffd166;
  --color-success: #25D366;

  --text-main: #f8f9fa;
  --text-muted: #adb5bd;

  /* Footer Colors */
  --footer-heading-color: #ffd700; /* Yellow/Gold for dark theme */
  --footer-text-color: #f8f9fa;    /* White for dark theme */
  --footer-link-color: #ff9f1c;    /* Secondary color for links in dark theme */

  --glow-primary: radial-gradient(
    circle,
    rgba(230, 57, 70, 0.12) 0%,
    rgba(11, 15, 25, 0) 60%
  );
  --glow-secondary: radial-gradient(
    circle,
    rgba(255, 159, 28, 0.12) 0%,
    rgba(11, 15, 25, 0) 60%
  );

  /* Typography */
  --font-heading: "Cinzel", serif;
  --font-body: "Inter", sans-serif;

  /* Spacing System */
  --spacing-xs: 0.25rem;
  --spacing-sm: 0.5rem;
  --spacing-md: 1rem;
  --spacing-lg: 2rem;
  --spacing-xl: 4rem;

  /* Borders & Radius */
  --radius-md: 8px;
  --radius-lg: 16px;
  --radius-xl: 24px;

  /* Animations */
  --transition-fast: 0.2s ease-in-out;
  --transition-base: 0.3s ease-in-out;
}

/* =========================================
   LIGHT THEME OVERLAY
========================================= */

[data-theme="light"] {
  --bg-dark: #e0f2fe; /* Light blue background */
  --bg-card: #fef9c3; /* Light yellow for cards/sections */

  /* Vibrant Festival Colors (Orange & Red) */
  --color-primary: #ef4444; /* Light Red */
  --color-secondary: #f97316; /* Orange */
  --color-accent: #ef4444; /* Set to red for matching outlines */
  --color-success: #16a34a; /* Green for success states */

  /* Text Colors */
  --text-main: #0f172a; /* Deep slate for maximum readability */
  --text-muted: #475569;

  /* Footer Colors - Red for headings, Black for text/links in light theme */
  --footer-heading-color: #ef4444; /* Red for light theme */
  --footer-text-color: #0f172a;    /* Black/Dark for light theme */
  --footer-link-color: #ef4444;    /* Red for links in light theme */

  /* Subtle Glow Patches tuned for the light blue background */
  --glow-primary: radial-gradient(
    circle,
    rgba(239, 68, 68, 0.12) 0%,
    rgba(224, 242, 254, 0) 60%
  );
  --glow-secondary: radial-gradient(
    circle,
    rgba(249, 115, 22, 0.12) 0%,
    rgba(224, 242, 254, 0) 60%
  );
}

[data-theme="light"] input,
[data-theme="light"] textarea,
[data-theme="light"] select {
  background-color: #ffffff !important; /* Crisp white background */
  color: #0f172a !important; /* Dark text for readability */
  border: 1px solid #cbd5e1 !important; /* Subtle gray border */
}
[data-theme="light"] input::placeholder,
[data-theme="light"] textarea::placeholder {
  color: #64748b !important; /* Slate gray placeholder text */
}
[data-theme="light"] .form-wrapper,
[data-theme="light"] .detail-box,
[data-theme="light"] .inquiry-container,
[data-theme="light"] .inquiry-container,
[data-theme="light"] .sponsor-section {
  background: var(--bg-card) !important; /* Forces the box to be light yellow */
  box-shadow: 0 4px 15px rgba(0, 0, 0, 0.08) !important;
  border: 1px solid rgba(0, 0, 0, 0.05) !important;
}

/* ===== Sliding Theme Switch ===== */
.theme-switch {
  --track-w: 60px;
  --track-h: 30px;
  --thumb-size: 24px;
  position: relative;
  width: var(--track-w);
  height: var(--track-h);
  border: none;
  border-radius: 999px;
  padding: 0;
  cursor: pointer;
  overflow: hidden;
  background: linear-gradient(135deg, #0b0f19 0%, #1c2d79 100%);
  box-shadow: inset 0 2px 5px rgba(0, 0, 0, 0.35);
  transition: background var(--transition-base);
}

html[data-theme="light"] .theme-switch {
  background: linear-gradient(135deg, #87ceeb 0%, #ffd166 100%);
}

.switch-stars {
  position: absolute;
  inset: 0;
}
.switch-stars span {
  position: absolute;
  width: 2px;
  height: 2px;
  border-radius: 50%;
  background: #fff;
  opacity: 0.8;
  transition: opacity var(--transition-fast);
}
.switch-stars span:nth-child(1) {
  top: 7px;
  left: 12px;
}
.switch-stars span:nth-child(2) {
  top: 16px;
  left: 20px;
}
.switch-stars span:nth-child(3) {
  top: 9px;
  left: 26px;
}

html[data-theme="light"] .switch-stars span {
  opacity: 0;
}

.switch-thumb {
  position: absolute;
  top: 3px;
  left: 3px;
  width: var(--thumb-size);
  height: var(--thumb-size);
  border-radius: 50%;
  background: #cbd5e1;
  box-shadow: 0 2px 6px rgba(0, 0, 0, 0.35);
  transform: translateX(0) rotate(0deg);
  transition:
    transform 0.45s cubic-bezier(0.68, -0.4, 0.32, 1.4),
    background 0.45s ease;
  display: flex;
  align-items: center;
  justify-content: center;
}

html[data-theme="light"] .switch-thumb {
  background: #fff3c4;
  transform: translateX(calc(var(--track-w) - var(--thumb-size) - 6px))
    rotate(360deg);
}

.icon-sun,
.icon-moon {
  position: absolute;
  font-size: 13px;
  line-height: 1;
  transition:
    opacity 0.35s ease,
    transform 0.45s ease;
}

.icon-moon {
  color: #1e293b;
  opacity: 1;
  transform: rotate(0deg) scale(1);
}
.icon-sun {
  color: #b45309;
  opacity: 0;
  transform: rotate(90deg) scale(0.4);
}

html[data-theme="light"] .icon-sun {
  opacity: 1;
  transform: rotate(0deg) scale(1);
}
html[data-theme="light"] .icon-moon {
  opacity: 0;
  transform: rotate(-90deg) scale(0.4);
}

.theme-switch:hover .switch-thumb {
  box-shadow: 0 0 10px 2px rgba(255, 209, 102, 0.5);
}

@media (max-width: 768px) {
  .theme-switch {
    --track-w: 52px;
    --track-h: 26px;
    --thumb-size: 20px;
  }
  .icon-sun,
  .icon-moon {
    font-size: 11px;
  }
}
