:root {
  --maroon-ink: #1c0408;
  --maroon-deep: #2a070c;
  --maroon: #4c1016;
  --maroon-mid: #6e1c24;
  --saffron: #f08c2b;
  --saffron-deep: #d56a12;
  --gold: #e8c547;
  --gold-soft: #f7e7a6;
  --cream: #fff6e8;
  --ivory: #fffdf7;
  --lime: #c8ee3a;
  --lime-deep: #9ec41a;
  --red: #e23b2f;
  --ink: #2a140f;
  --muted: #7c5a4c;
  --card: rgba(255, 253, 247, 0.94);
  --shadow: 0 18px 40px rgba(28, 4, 8, 0.28);
  --radius: 22px;
  --nav-h: calc(68px + env(safe-area-inset-bottom));
  --font: "Outfit", "Noto Sans Devanagari", system-ui, sans-serif;
  --display: "Yatra One", "Noto Serif Devanagari", serif;
}

*,
*::before,
*::after {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

html,
body {
  margin: 0;
  min-height: 100%;
}

body {
  font-family: var(--font);
  color: var(--ink);
  background: var(--maroon-deep);
  line-height: 1.45;
  -webkit-font-smoothing: antialiased;
  padding-bottom: var(--nav-h);
  overflow-x: hidden;
}

img {
  max-width: 100%;
  display: block;
}

a {
  color: inherit;
}

button,
select {
  font-family: inherit;
}

.skip {
  position: absolute;
  left: -999px;
  top: 8px;
}

.skip:focus {
  left: 8px;
  z-index: 40;
  background: var(--lime);
  padding: 8px 12px;
  border-radius: 8px;
}

.toran {
  height: 22px;
  background:
    radial-gradient(circle at 8px 4px, var(--gold) 5px, transparent 6px),
    radial-gradient(circle at 24px 4px, var(--saffron) 5px, transparent 6px),
    radial-gradient(circle at 40px 4px, var(--red) 5px, transparent 6px),
    radial-gradient(circle at 56px 4px, var(--lime) 5px, transparent 6px),
    linear-gradient(var(--maroon-mid), var(--maroon-mid));
  background-size: 64px 22px, 64px 22px, 64px 22px, 64px 22px, 100% 8px;
  background-repeat: repeat-x;
  background-position: 0 8px, 0 8px, 0 8px, 0 8px, 0 0;
}

.petals {
  pointer-events: none;
  position: fixed;
  inset: 0;
  overflow: hidden;
  z-index: 0;
}

.petal {
  position: absolute;
  top: -24px;
  width: 10px;
  height: 14px;
  border-radius: 80% 0 80% 0;
  background: linear-gradient(135deg, var(--saffron), var(--red));
  opacity: 0.35;
  animation: fall linear infinite;
}

.petal:nth-child(1) { left: 8%; animation-duration: 14s; animation-delay: -2s; }
.petal:nth-child(2) { left: 22%; animation-duration: 18s; animation-delay: -7s; background: linear-gradient(135deg, var(--gold), var(--saffron)); }
.petal:nth-child(3) { left: 41%; animation-duration: 16s; animation-delay: -4s; }
.petal:nth-child(4) { left: 63%; animation-duration: 20s; animation-delay: -11s; background: linear-gradient(135deg, var(--lime), var(--gold)); }
.petal:nth-child(5) { left: 81%; animation-duration: 15s; animation-delay: -1s; }
.petal:nth-child(6) { left: 92%; animation-duration: 19s; animation-delay: -9s; }

@keyframes fall {
  0% { transform: translateY(0) rotate(0deg); }
  100% { transform: translateY(110vh) rotate(360deg); }
}

.hero {
  position: relative;
  z-index: 1;
  overflow: hidden;
  padding: 28px 20px 36px;
  color: var(--cream);
  text-align: center;
  background:
    radial-gradient(ellipse at 50% 0%, rgba(232, 197, 71, 0.22), transparent 52%),
    radial-gradient(circle at 12% 80%, rgba(224, 59, 47, 0.18), transparent 30%),
    radial-gradient(circle at 88% 70%, rgba(200, 238, 58, 0.12), transparent 28%),
    linear-gradient(180deg, var(--maroon-ink), var(--maroon) 70%, #5a141c);
}

.hero::before {
  content: "";
  position: absolute;
  inset: 18px;
  border: 1px solid rgba(232, 197, 71, 0.28);
  border-radius: 28px;
  pointer-events: none;
}

.mandala {
  position: absolute;
  left: 50%;
  top: 42%;
  width: min(92vw, 520px);
  height: min(92vw, 520px);
  transform: translate(-50%, -50%);
  opacity: 0.14;
  background:
    repeating-conic-gradient(from 0deg, rgba(232, 197, 71, 0.7) 0 6deg, transparent 6deg 18deg);
  mask: radial-gradient(circle, transparent 18%, #000 19%, #000 46%, transparent 47%, transparent 58%, #000 59%, #000 72%, transparent 73%);
  animation: spin 80s linear infinite;
}

@keyframes spin {
  to { transform: translate(-50%, -50%) rotate(360deg); }
}

.hero-inner {
  position: relative;
  z-index: 1;
}

.logo-badge {
  width: 108px;
  height: 108px;
  margin: 8px auto 18px;
  padding: 10px;
  border-radius: 28px;
  background: #000;
  box-shadow: 0 0 0 3px var(--gold), 0 0 28px rgba(232, 197, 71, 0.45);
}

.logo-badge img {
  width: 100%;
  height: 100%;
  object-fit: contain;
}

.kicker {
  margin: 0;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  font-size: 0.68rem;
  color: var(--gold-soft);
}

.mantra {
  font-family: var(--display);
  font-size: clamp(1.9rem, 8vw, 2.8rem);
  font-weight: 400;
  line-height: 1.25;
  margin: 8px 0 6px;
  text-shadow: 0 8px 24px rgba(0, 0, 0, 0.35);
}

.hero h1 {
  margin: 0 0 6px;
  font-size: clamp(1.15rem, 4.4vw, 1.55rem);
  font-weight: 700;
}

.lede {
  margin: 0 auto 22px;
  max-width: 34ch;
  color: rgba(255, 246, 232, 0.82);
  font-size: 0.95rem;
}

.countdown {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 8px;
  max-width: 360px;
  margin: 0 auto 10px;
}

.cd-box {
  background: rgba(0, 0, 0, 0.28);
  border: 1px solid rgba(232, 197, 71, 0.28);
  border-radius: 16px;
  padding: 10px 4px 8px;
  backdrop-filter: blur(8px);
}

.cd-box strong {
  display: block;
  font-size: 1.35rem;
  color: var(--lime);
  font-variant-numeric: tabular-nums;
}

.cd-box span {
  font-size: 0.68rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--gold-soft);
}

.countdown-label {
  margin: 0;
  font-size: 0.82rem;
  color: rgba(255, 246, 232, 0.75);
}

.dates-line {
  margin: 14px 0 0;
  font-size: 0.9rem;
  color: var(--gold);
  font-weight: 600;
}

.sheet {
  position: relative;
  z-index: 1;
  margin-top: -8px;
  border-radius: 28px 28px 0 0;
  background:
    radial-gradient(circle at 12px 12px, rgba(240, 140, 43, 0.18) 2px, transparent 3px),
    var(--cream);
  background-size: 22px 22px, auto;
  padding: 22px 16px 28px;
  color: var(--ink);
}

.section {
  margin: 0 auto 28px;
  max-width: 720px;
}

.section-head {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 12px;
}

.section h2 {
  margin: 0;
  font-size: 1.25rem;
}

.mr {
  display: block;
  font-family: var(--display);
  font-size: 0.95rem;
  color: var(--maroon-mid);
  font-weight: 400;
}

.chips {
  display: flex;
  gap: 8px;
  overflow-x: auto;
  padding: 4px 2px 12px;
  scroll-snap-type: x mandatory;
  -webkit-overflow-scrolling: touch;
}

.chips::-webkit-scrollbar {
  display: none;
}

.chip {
  flex: 0 0 auto;
  scroll-snap-align: start;
  border: 0;
  background: #fff;
  color: var(--ink);
  border-radius: 999px;
  padding: 10px 14px;
  font-weight: 600;
  font-size: 0.86rem;
  box-shadow: 0 4px 12px rgba(76, 16, 22, 0.08);
  min-height: 44px;
}

.chip.is-on,
.chip:focus-visible {
  background: var(--maroon);
  color: var(--cream);
}

.chip.today-chip {
  box-shadow: 0 0 0 2px var(--lime);
}

.filters {
  display: flex;
  gap: 8px;
  align-items: center;
  margin-bottom: 12px;
}

.filters label {
  font-size: 0.8rem;
  color: var(--muted);
  white-space: nowrap;
}

.filters select {
  flex: 1;
  min-height: 44px;
  border-radius: 12px;
  border: 1px solid rgba(76, 16, 22, 0.12);
  background: #fff;
  padding: 0 12px;
  font-size: 1rem;
}

.card-list,
.day-group {
  display: grid;
  gap: 12px;
}

.day-label {
  margin: 18px 0 0;
  font-size: 0.78rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--maroon-mid);
  font-weight: 700;
}

.event {
  background: var(--card);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  padding: 16px 16px 14px 20px;
  border: 1px solid rgba(232, 197, 71, 0.35);
  position: relative;
  overflow: hidden;
}

.event::before {
  content: "";
  position: absolute;
  left: 0;
  top: 0;
  bottom: 0;
  width: 6px;
  background: linear-gradient(var(--saffron), var(--gold));
}

.event.kind-ritual::before {
  background: linear-gradient(var(--gold), var(--red));
}

.event.kind-community::before {
  background: linear-gradient(var(--lime-deep), var(--lime));
}

.event-top {
  display: flex;
  justify-content: space-between;
  gap: 8px;
  align-items: start;
}

.time {
  margin: 0;
  color: var(--saffron-deep);
  font-weight: 700;
  font-size: 0.86rem;
}

.badge {
  border-radius: 999px;
  padding: 4px 8px;
  font-size: 0.68rem;
  font-weight: 700;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  background: #f3e0c8;
  color: var(--maroon);
}

.badge.required {
  background: var(--lime);
  color: #1c2a00;
}

.badge.onspot {
  background: #ffe1b5;
  color: #7a3d00;
}

.event h3 {
  margin: 6px 0 4px;
  font-size: 1.12rem;
}

.sub {
  margin: 0 0 8px;
  color: var(--muted);
  font-size: 0.88rem;
}

.pills {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin: 8px 0 12px;
}

.pill {
  background: #fff3d8;
  color: var(--maroon);
  border-radius: 999px;
  padding: 4px 8px;
  font-size: 0.75rem;
  font-weight: 700;
}

.actions {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.btn {
  appearance: none;
  border: 0;
  cursor: pointer;
  text-decoration: none;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 44px;
  padding: 0 14px;
  border-radius: 14px;
  font-weight: 700;
  font-size: 0.9rem;
}

.btn-primary {
  background: var(--lime);
  color: #1a2800;
  box-shadow: 0 8px 16px rgba(158, 196, 26, 0.28);
}

.btn-ghost {
  background: #fff;
  color: var(--maroon);
  border: 1px solid rgba(76, 16, 22, 0.12);
}

.details,
.people {
  margin-top: 8px;
  font-size: 0.9rem;
}

.details summary {
  cursor: pointer;
  color: var(--maroon-mid);
  font-weight: 600;
  padding: 8px 0;
}

.details p,
.people p {
  margin: 0 0 6px;
  color: var(--muted);
}

.rule-list {
  margin: 8px 0 0;
  padding-left: 1.2rem;
  color: var(--muted);
}

.rule-list li + li {
  margin-top: 6px;
}

.rules-fold .sub {
  margin-top: 4px;
}

.rules-more {
  margin: 10px 0 0;
  font-weight: 600;
}

.rules-more a {
  color: var(--maroon-mid);
}

.rule-card h3 {
  margin-top: 0;
}

.empty {
  background: #fff;
  border-radius: var(--radius);
  padding: 22px;
  text-align: center;
  color: var(--muted);
}

.how-grid {
  display: grid;
  gap: 10px;
}

.how {
  background: #fff;
  border-radius: 18px;
  padding: 14px;
  border: 1px solid rgba(76, 16, 22, 0.08);
}

.how strong {
  display: block;
  margin-bottom: 4px;
}

.hero-cta {
  margin-top: 18px;
}

.hero-compact {
  padding: 22px 20px 28px;
}

.logo-badge-sm {
  width: 84px;
  height: 84px;
  margin-bottom: 12px;
}

.field-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 12px;
}

.field {
  display: flex;
  flex-direction: column;
  gap: 6px;
  margin-bottom: 12px;
}

.field label {
  font-size: 0.85rem;
  font-weight: 600;
}

.field input,
.field select {
  min-height: 48px;
  border-radius: 12px;
  border: 1px solid rgba(76, 16, 22, 0.14);
  background: #fff;
  padding: 0 12px;
  font-size: 1rem;
  color: var(--ink);
}

.contribute-card .btn-primary,
.contribute-card .btn-ghost {
  width: 100%;
  margin-top: 4px;
}

.choice-label {
  margin: 14px 0 8px;
  font-weight: 700;
}

.choice-grid {
  display: grid;
  gap: 8px;
}

.switch-method {
  width: 100%;
  margin-top: 10px;
}

.amount-chips {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin: 0 0 12px;
}

.form-error {
  margin: 10px 0 0;
  color: var(--red);
  font-weight: 600;
  font-size: 0.9rem;
}

.qr-wrap {
  margin-top: 14px;
  text-align: center;
}

.qr-wrap .pay-actions {
  justify-content: center;
  margin: 8px 0 12px;
}

.btn-pay {
  min-width: min(100%, 280px);
  min-height: 48px;
}

.upi-apps {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 8px;
  margin: 12px 0 14px;
}

.upi-app {
  display: flex;
  align-items: center;
  justify-content: center;
  min-height: 48px;
  border-radius: 14px;
  font-weight: 700;
  text-decoration: none;
  color: #fff;
}

.upi-app.app-gpay { background: #1a73e8; }
.upi-app.app-phonepe { background: #5f259f; }
.upi-app.app-paytm { background: #00baf2; color: #083344; }
.upi-app.app-bhim { background: #1a7f4b; }

.pay-hint {
  margin: 0 0 18px;
}

.qr-box {
  display: inline-block;
  margin: 8px auto 12px;
  padding: 12px;
  background: #fff;
  border-radius: 16px;
  box-shadow: 0 8px 20px rgba(28, 4, 8, 0.12);
}

.qr-box img,
.qr-box canvas {
  display: block;
}

.upi-id {
  font-weight: 700;
  margin: 0 0 6px;
  word-break: break-all;
}

.setup-note {
  margin-top: 16px;
  font-size: 0.82rem;
  color: var(--muted);
  background: #fff;
  border-radius: 14px;
  padding: 12px;
}

.how-cta {
  margin-top: 10px;
}

.how-grid .how .btn {
  width: 100%;
}

.site-footer {
  text-align: center;
  padding: 8px 16px 18px;
  color: var(--muted);
  font-size: 0.85rem;
}

.bottom-nav {
  position: fixed;
  left: 0;
  right: 0;
  bottom: 0;
  z-index: 20;
  display: flex;
  background: rgba(28, 4, 8, 0.94);
  color: var(--cream);
  padding: 6px 8px calc(8px + env(safe-area-inset-bottom));
  backdrop-filter: blur(14px);
  border-top: 1px solid rgba(232, 197, 71, 0.25);
}

.bottom-nav a {
  background: none;
  border: 0;
  color: inherit;
  text-decoration: none;
  display: flex;
  flex: 1 1 0;
  flex-direction: column;
  align-items: center;
  gap: 2px;
  min-height: 52px;
  min-width: 0;
  justify-content: center;
  font-size: 0.68rem;
  font-weight: 600;
  letter-spacing: 0.02em;
}

.bottom-nav svg {
  width: 22px;
  height: 22px;
}

.bottom-nav .accent {
  color: var(--lime);
}

@media (min-width: 720px) {
  .sheet {
    max-width: 760px;
    margin: -8px auto 40px;
    padding: 32px 24px 48px;
    border-radius: 28px;
    box-shadow: var(--shadow);
  }

  .hero {
    padding: 40px 24px 48px;
  }

  .how-grid {
    grid-template-columns: repeat(2, 1fr);
  }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .petal,
  .mandala {
    animation: none;
  }
}
