/* dakmuk.in — wedding site
   Palash & stone: plaster and sandstone grounds, palash orange for actions and petals,
   sindoor for headings, peacock teal for small details. Day 1 mustard, Day 2 sindoor. */

:root {
  --plaster: #f4ecdd;
  --whitewash: #fbf7ee;
  --sand: #c9a36a;
  --ink: #4a3426;
  --ink-soft: #7a6252;
  --palash: #e4572e;
  --palash-deep: #c8461f; /* palash dark enough for white button text */
  --sindoor: #b8322a;
  --peacock: #1f6e73;
  --mustard-wash: #f7e6ad;
  --sindoor-wash: #f4d8cd;
  --rule: rgba(74, 52, 38, 0.14);

  --serif: 'Playfair Display', Georgia, serif;
  --script: 'Dancing Script', 'Brush Script MT', cursive;
  --sans: 'Inter', system-ui, -apple-system, sans-serif;

  --tabbar-h: 64px;
}

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

/* Sandstone backdrop behind the centred column on wide screens */
html { background: linear-gradient(180deg, #e9dcc4 0%, #efe4d0 100%) fixed; }

body {
  max-width: 480px;
  min-height: 100vh;
  margin: 0 auto;
  background: var(--plaster);
  color: var(--ink);
  font-family: var(--serif);
  -webkit-font-smoothing: antialiased;
}
@media (min-width: 500px) { body { box-shadow: 0 0 44px rgba(74, 52, 38, 0.16); } }

img { max-width: 100%; display: block; }
a { color: inherit; }

main {
  padding-bottom: calc(var(--tabbar-h) + env(safe-area-inset-bottom, 0px) + 24px);
  overflow-x: hidden;
}

/* ── Shared type ── */
.kicker {
  font-family: var(--sans); font-size: 11px; font-weight: 600;
  letter-spacing: 2.5px; text-transform: uppercase; color: var(--ink-soft);
}
.script-title {
  font-family: var(--script); font-weight: 700; color: var(--sindoor);
  font-size: clamp(42px, 12vw, 52px); line-height: 1;
}
.page-head { text-align: center; padding: 34px 20px 14px; display: grid; gap: 4px; }

/* Small logo at the top of inner pages, tapping back to the invite */
.top-logo { display: block; width: 96px; margin: 18px auto 0; padding: 8px 0; }
.top-logo img { width: 96px; height: auto; }
.top-logo:focus-visible { outline: 2px solid var(--peacock); outline-offset: 2px; border-radius: 4px; }
.top-logo + .page-head { padding-top: 14px; }
.top-logo.on-photo { position: absolute; top: 10px; left: 50%; transform: translateX(-50%); margin: 0; }
.top-logo.on-photo img { filter: drop-shadow(0 1px 6px rgba(30, 20, 15, 0.5)); }
.note { font-style: italic; font-size: 14px; color: var(--ink-soft); text-align: center; padding: 6px 24px 0; }

/* ── Buttons ── */
.actions { display: grid; gap: 10px; padding: 20px 24px 0; }
.btn {
  display: block; width: 100%; text-align: center; text-decoration: none; cursor: pointer;
  font-family: var(--sans); font-size: 13px; font-weight: 600; letter-spacing: 1.8px; text-transform: uppercase;
  padding: 14px 16px; border-radius: 999px; border: 1px solid transparent;
  transition: opacity 0.15s;
}
.btn:active { opacity: 0.75; }
.btn:focus-visible, .tab:focus-visible, .text-link:focus-visible { outline: 2px solid var(--peacock); outline-offset: 3px; }
.btn-fill { background: var(--palash-deep); color: #fff; }
.btn-line { background: transparent; border-color: rgba(74, 52, 38, 0.35); color: var(--ink); }
.text-link {
  background: none; border: none; cursor: pointer; justify-self: center;
  font-family: var(--sans); font-size: 12px; letter-spacing: 1px; color: var(--peacock);
  text-decoration: underline; text-underline-offset: 3px; padding: 14px 16px;
}

/* ── Bottom tab bar ── */
.tabbar {
  position: fixed; bottom: 0; left: 50%; transform: translateX(-50%);
  width: min(100%, 480px); z-index: 20;
  display: grid; grid-template-columns: repeat(4, 1fr);
  padding: 8px 6px calc(10px + env(safe-area-inset-bottom, 0px));
  background: rgba(251, 247, 238, 0.94);
  -webkit-backdrop-filter: blur(10px); backdrop-filter: blur(10px);
  border-top: 1px solid var(--rule);
}
.tab {
  display: grid; justify-items: center; gap: 3px; text-decoration: none;
  font-family: var(--sans); font-size: 11px; font-weight: 600; letter-spacing: 0.3px;
  color: var(--ink-soft); padding: 4px 0;
}
.tab svg { width: 24px; height: 24px; }
.tab[aria-current="page"] { color: var(--sindoor); }

/* ── Falling palash petals ── */
.petals { position: fixed; inset: 0; pointer-events: none; z-index: 5; overflow: hidden; }
.petal {
  position: absolute; top: -20px; width: 13px; height: 7px;
  border-radius: 0 100% 0 100%;
  background: linear-gradient(135deg, #f06a35, var(--palash) 60%, #c9441f);
  opacity: 0;
  animation: fall linear infinite;
}
@keyframes fall {
  0%   { transform: translateY(-3vh) translateX(0) rotate(0deg); opacity: 0; }
  8%   { opacity: 0.9; }
  85%  { opacity: 0.75; }
  100% { transform: translateY(105vh) translateX(52px) rotate(340deg); opacity: 0; }
}
.petal:nth-child(1) { left: 7%;  animation-duration: 12s; animation-delay: 0s; }
.petal:nth-child(2) { left: 22%; animation-duration: 15s; animation-delay: 4s; }
.petal:nth-child(3) { left: 38%; animation-duration: 13s; animation-delay: 8s; }
.petal:nth-child(4) { left: 55%; animation-duration: 16s; animation-delay: 2s; }
.petal:nth-child(5) { left: 70%; animation-duration: 11s; animation-delay: 6s; }
.petal:nth-child(6) { left: 86%; animation-duration: 14s; animation-delay: 10s; }

/* ── Invite ── */
.hero {
  position: relative; text-align: center; color: #fff4e4;
  background: linear-gradient(180deg, #5c2a1d 0%, #9a4327 30%, #d9814f 52%, #f0b26a 78%, var(--plaster) 100%);
  min-height: clamp(470px, 67svh, 610px);
  padding: 80px 20px 0;
  display: grid; align-content: start; gap: 10px;
}
/* Chhatris on the Betwa at sunset, fading into the dusk sky above and plaster below */
.hero::before {
  content: ''; position: absolute; left: 0; right: 0; bottom: 0;
  aspect-ratio: 1000 / 818;
  background: url(/assets/img/hero-chhatris.jpg) center / cover;
  -webkit-mask-image: linear-gradient(180deg, transparent 0%, #000 32%, #000 80%, transparent 100%);
  mask-image: linear-gradient(180deg, transparent 0%, #000 32%, #000 80%, transparent 100%);
  pointer-events: none;
}
.hero > * { position: relative; }
.hero .invite-line { font-style: italic; font-size: clamp(14px, 4vw, 16px); line-height: 1.45; color: #fbe3c6; }
.hero .names { font-family: var(--script); font-weight: 700; font-size: clamp(54px, 16vw, 68px); line-height: 0.95; }
.hero .names .amp { color: #ffb48f; font-size: 0.68em; display: inline-block; }
/* The two names take turns to lead (see site.js); inline-block so each can travel on its own */
.hero .names .nm { display: inline-block; will-change: transform; }
.hero .names[data-turns] { cursor: pointer; -webkit-tap-highlight-color: transparent; }

.date-block { text-align: center; padding: 18px 20px 0; display: grid; gap: 4px; }
.date-big { font-weight: 700; font-size: clamp(60px, 18vw, 76px); line-height: 1; letter-spacing: -1px; }
.date-big span { font-weight: 400; font-style: italic; color: var(--sindoor); font-size: 0.58em; margin: 0 6px; }
.date-month { font-weight: 700; font-size: clamp(20px, 6vw, 26px); letter-spacing: 7px; }
.place { font-style: italic; color: var(--peacock); font-size: 17px; margin-top: 6px; }

.closing-line { text-align: center; font-style: italic; font-size: 16px; color: var(--ink-soft); padding: 36px 24px 8px; }

/* ── Schedule ── */
.day { margin: 0 18px; }
.day .arch { display: block; width: 100%; height: 44px; }
.day-body { padding: 0 14px 16px; border-radius: 0 0 12px 12px; margin-top: -1px; }
.day-one .arch { fill: var(--mustard-wash); }
.day-one .day-body { background: var(--mustard-wash); }
.day-two .arch { fill: var(--sindoor-wash); }
.day-two .day-body { background: var(--sindoor-wash); }
.day-label { text-align: center; font-family: var(--sans); font-size: 11px; font-weight: 700; letter-spacing: 2px; text-transform: uppercase; color: var(--sindoor); margin-top: -14px; position: relative; }
.day-date { text-align: center; font-weight: 700; font-size: 21px; margin: 2px 0 8px; }
.event-list { list-style: none; }
.event { padding: 12px 2px; border-top: 1px solid var(--rule); }
.event-name { font-size: 19px; }
.countdown { font-family: var(--sans); font-size: 13px; font-weight: 600; color: var(--peacock); margin-top: 6px; }

/* Theme colour per day: dashed placeholder dots until colours are chosen */
.ev-theme { font-family: var(--sans); font-size: 14px; line-height: 1.45; color: var(--ink-soft); margin-top: 4px; }
.ev-theme .dots { vertical-align: -1px; margin-right: 3px; }
/* One card per event (Day 1) or for the whole wedding day (Day 2). The band across the top
   shows the theme colours once chosen (set --c1 / --c2 on the card); until then it's a sand stripe. */
.ev-card { background: var(--whitewash); border: 1px solid var(--rule); border-radius: 12px; overflow: hidden; margin-top: 12px; }
.ev-band {
  height: 10px;
  background: linear-gradient(90deg, var(--c1, transparent) 50%, var(--c2, transparent) 50%),
    repeating-linear-gradient(45deg, rgba(201, 163, 106, 0.5) 0 6px, rgba(201, 163, 106, 0.18) 6px 12px);
}
/* Hairline under the band so pale theme colours (Haldi's off-white) still read against the card */
.ev-band { box-shadow: inset 0 -1px 0 var(--rule); }
/* Sangeet: dark and glittery — a night-sky band scattered with gold and silver specks */
.ev-glitter .ev-band {
  box-shadow: none;
  background:
    radial-gradient(circle, #fff 0 0.6px, transparent 1.1px) 7px 1px / 23px 10px,
    radial-gradient(circle, #f6dc8c 0 0.8px, transparent 1.3px) 0 0 / 15px 10px,
    radial-gradient(circle, #d9b45a 0 0.7px, transparent 1.2px) 4px 2px / 19px 10px,
    radial-gradient(circle, #fff3c4 0 0.5px, transparent 1px) 11px -2px / 29px 10px,
    linear-gradient(90deg, #17131f, #2b2142 50%, #17131f);
}
.dot.dot-glitter { background: linear-gradient(135deg, #f8e7a8 0%, #c9973a 35%, #fff6d2 55%, #b8862f 100%); }
.ev-card-body { padding: 12px 14px 14px; }
.ev-card h3.event-name { font-size: 21px; font-weight: 400; }
/* Event name with its time on the right */
.ev-head { display: flex; align-items: baseline; justify-content: space-between; gap: 12px; }
.ev-time { font-family: var(--sans); font-size: 13px; font-weight: 600; color: var(--peacock); white-space: nowrap; }
/* An event with no theme colour: a quiet sand band instead of the "to be announced" stripes */
.ev-plain .ev-band { background: rgba(201, 163, 106, 0.4); }
.ev-card .event-list { margin-top: 6px; }
.ev-card .event:first-child { border-top: 0; }
.ev-card .event { padding: 10px 0; display: flex; align-items: baseline; justify-content: space-between; gap: 12px; }
.ev-theme em { font-style: italic; }
.dots { display: inline-flex; gap: 3px; }
.dot { width: 12px; height: 12px; border-radius: 50%; background: var(--c); box-shadow: inset 0 0 0 1px rgba(74, 52, 38, 0.2); }
.dot-ph { background: transparent; box-shadow: none; border: 1.5px dashed rgba(74, 52, 38, 0.45); }



.btn-wa { background: var(--peacock); color: #fff; }

.ev-note { font-family: var(--sans); font-size: 14px; line-height: 1.45; color: var(--ink-soft); margin-top: 2px; }
.frieze { margin: 16px 18px; height: 40px; border-radius: 6px; background: url(/assets/img/frieze.jpg) center / cover; }

/* ── Travel ── */
.jharokha { margin: 6px 22px 0; text-decoration: none; display: block; }
.jharokha .roof { display: block; width: 100%; height: auto; fill: var(--sand); }
.map {
  position: relative; height: 180px; margin: -2px 12px 0;
  border: 2px solid var(--sand); border-top: 0; border-radius: 0 0 6px 6px;
  background: linear-gradient(160deg, #e3ead3, #f1ead6); overflow: hidden;
}
.map svg { position: absolute; inset: 0; width: 100%; height: 100%; }
.map-label {
  position: absolute; font-family: var(--sans); font-size: 11px; font-weight: 600;
  color: var(--ink); background: rgba(251, 247, 238, 0.88); padding: 2px 6px; border-radius: 4px; white-space: nowrap;
}
.map-label.soft { color: var(--peacock); }
.map-label.plain { background: none; color: var(--peacock); font-style: italic; }

.rows { padding: 18px 0 0; }
.row { display: flex; gap: 14px; align-items: flex-start; padding: 16px 22px; border-top: 1px solid var(--rule); }
.row .ic { width: 40px; height: 40px; border-radius: 50%; background: var(--sindoor-wash); color: var(--sindoor); display: grid; place-items: center; flex-shrink: 0; }
.row .ic svg { width: 22px; height: 22px; }
.row h3 { font-family: var(--sans); font-size: 12px; font-weight: 700; letter-spacing: 1.5px; text-transform: uppercase; margin-bottom: 3px; }
.row p { font-family: var(--sans); font-size: 15px; line-height: 1.5; color: var(--ink-soft); }
.row p + p, .row ul + p { margin-top: 8px; }
.trains { list-style: none; margin-top: 8px; display: grid; gap: 6px; font-family: var(--sans); font-size: 15px; line-height: 1.4; color: var(--ink-soft); }
.trains b { color: var(--ink); font-weight: 600; }

/* ── Orchha ── */
.photo-hero {
  position: relative;
  min-height: 300px; display: grid; align-content: end; gap: 2px; padding: 0 22px 22px; color: #fff4e4;
  background: url(/assets/img/chhatris.jpg) 56% 40% / cover, #5c2a1d;
  overflow: hidden;
}
/* Shade for the logo and title, above the photo */
.photo-hero::after {
  content: ''; position: absolute; inset: 0; pointer-events: none;
  background: linear-gradient(180deg, rgba(30, 20, 15, 0.55) 0%, rgba(30, 20, 15, 0) 24%, rgba(30, 20, 15, 0) 30%, rgba(30, 20, 15, 0.72) 100%);
}
.photo-hero > * { z-index: 1; }
.photo-hero > :is(.kicker, .script-title) { position: relative; }
.photo-hero .kicker { color: #fbe3c6; }
.photo-hero .script-title { color: #fff4e4; font-size: clamp(54px, 16vw, 66px); }
.prose { padding: 22px 22px 0; display: grid; gap: 14px; font-size: 17px; line-height: 1.65; }
.section-title { font-family: var(--script); font-weight: 700; font-size: 36px; color: var(--sindoor); padding: 34px 22px 10px; line-height: 1.1; }
.place-card { display: grid; grid-template-columns: 96px 1fr; gap: 14px; padding: 14px 22px; border-top: 1px solid var(--rule); align-items: start; }
.place-card.no-photo { grid-template-columns: 1fr; }
.place-card img { width: 96px; height: 80px; object-fit: cover; border-radius: 8px; }
.place-card h3 { font-family: var(--sans); font-size: 12px; font-weight: 700; letter-spacing: 1.5px; text-transform: uppercase; margin-bottom: 3px; }
.place-card p { font-family: var(--sans); font-size: 15px; line-height: 1.5; color: var(--ink-soft); }
.place-card .dist { color: var(--peacock); font-weight: 600; }
.credits { padding: 30px 22px 0; font-family: var(--sans); font-size: 11px; line-height: 1.6; color: var(--ink-soft); }
.credits a { color: var(--ink-soft); }

/* ── Footer ── */
.footer { text-align: center; padding: 34px 20px 6px; display: grid; justify-items: center; }
.footer .logo { width: 170px; height: auto; }
.photo-credit { margin-top: 14px; font-family: var(--sans); font-size: 11px; line-height: 1.5; color: var(--ink-soft); }
.photo-credit a { color: var(--ink-soft); }

/* ── Motion ── */
.rise { animation: rise 0.7s ease-out both; }
.rise-2 { animation-delay: 0.15s; }
.rise-3 { animation-delay: 0.3s; }
@keyframes rise { from { opacity: 0; transform: translateY(12px); } to { opacity: 1; transform: none; } }

@media (prefers-reduced-motion: reduce) {
  .petal { animation: none; display: none; }
  .rise { animation: none; }
}

/* Wikipedia / map links under each place */
.links { display: flex; flex-wrap: wrap; gap: 6px; margin-top: 8px; }
.links a {
  font-family: var(--sans); font-size: 12px; font-weight: 600; text-decoration: none;
  padding: 5px 10px; border-radius: 999px; white-space: nowrap;
}
.links a:focus-visible { outline: 2px solid var(--peacock); outline-offset: 2px; }
.chip-wiki { color: var(--peacock); border: 1px solid rgba(31, 110, 115, 0.35); }
.chip-map { color: var(--sindoor); border: 1px solid rgba(184, 50, 42, 0.35); }

/* ── Language switch (EN | हिं): scrolls away with the page so it never covers content ── */
.lang-switch {
  position: absolute; z-index: 25;
  top: calc(env(safe-area-inset-top, 0px) + 12px);
  right: max(12px, calc(50% - 240px + 12px));
  display: flex; border-radius: 999px; overflow: hidden;
  background: rgba(251, 247, 238, 0.9);
  -webkit-backdrop-filter: blur(8px); backdrop-filter: blur(8px);
  border: 1px solid var(--rule);
  box-shadow: 0 2px 10px rgba(40, 25, 15, 0.12);
}
.lang-switch a {
  font-family: 'Inter', 'Noto Sans Devanagari', system-ui, sans-serif;
  font-size: 14px; font-weight: 600; text-decoration: none;
  color: var(--ink-soft); padding: 0 15px; line-height: 1.2;
  min-height: 44px; min-width: 48px; display: flex; align-items: center; justify-content: center;
}
.lang-switch a[aria-current="true"] { background: var(--palash-deep); color: #fff; }
.lang-switch a:focus-visible { outline: 2px solid var(--peacock); outline-offset: -2px; }

/* ── Hindi pages: Devanagari faces, no letter-spacing (it breaks the shirorekha) ── */
html[lang="hi"] {
  --serif: 'Tiro Devanagari Hindi', 'Playfair Display', Georgia, serif;
  --script: 'Kalam', 'Tiro Devanagari Hindi', cursive;
  --sans: 'Noto Sans Devanagari', 'Inter', system-ui, sans-serif;
}
html[lang="hi"] :is(.kicker, .day-label, .row h3, .place-card h3, .btn, .tab, .date-month, .date-big, .links a, .text-link) {
  letter-spacing: 0; text-transform: none;
}
html[lang="hi"] .kicker { font-size: 13px; }
html[lang="hi"] .btn { font-size: 15px; padding: 12px 16px; }
html[lang="hi"] .row h3, html[lang="hi"] .place-card h3 { font-size: 15px; }
html[lang="hi"] .day-label { font-size: 13px; }
html[lang="hi"] .tab { font-size: 12px; }
html[lang="hi"] .hero .names { line-height: 1.15; font-size: clamp(50px, 15vw, 62px); }
html[lang="hi"] .hero .invite-line { font-style: normal; font-size: clamp(15px, 4.4vw, 17px); }
html[lang="hi"] .script-title { line-height: 1.2; }
html[lang="hi"] .section-title { font-size: 32px; }
html[lang="hi"] .date-month { font-size: clamp(22px, 6.5vw, 28px); }
html[lang="hi"] :is(.place, .note, .closing-line, .ev-theme em) { font-style: normal; }
html[lang="hi"] .ev-note { font-size: 15px; }
html[lang="hi"] .prose { font-size: 18px; line-height: 1.8; }

/* Fixed line heights in page headers, so content below (the Travel map) does not jump when web fonts load */
.page-head .kicker { line-height: 13px; }
.page-head .place { line-height: 23px; }
html[lang="hi"] .page-head .kicker { line-height: 17px; }
