/* Modern direction. Newsreader for headings, Instrument Sans for everything else.
   Warm off-white ground, near-black ink, one muted red for the period and links. */
:root {
    --bg: #F4F1EA;
    --card: #FFFFFF;
    --line: #DCD8CD;
    --ink: #1E211C;
    --body: #2E322B;
    --muted: #6B7065;
    --accent: #8B2F3A;
    --accent-dark: #6E2430;
    --radius: 14px;
    --measure: 42rem;
    --serif: "Newsreader", Georgia, "Times New Roman", serif;
    --sans: "Instrument Sans", "Helvetica Neue", Arial, sans-serif;
    font-size: 17px;
}
@media (min-width: 720px) { :root { font-size: 18px; } }

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body { margin: 0; background: var(--bg); color: var(--ink); font-family: var(--sans); line-height: 1.65; }
h1, h2 { font-family: var(--serif); font-weight: 400; line-height: 1.1; letter-spacing: -0.01em; margin: 0; color: var(--ink); }
h1 { font-size: clamp(3.2rem, 9vw, 5.2rem); line-height: 0.98; letter-spacing: -0.02em; }
h2 { font-size: clamp(1.9rem, 4.5vw, 2.5rem); }
p { margin: 0; max-width: var(--measure); color: var(--body); text-wrap: pretty; }
a { color: var(--accent); }
a:hover { color: var(--accent-dark); }
button, input { font: inherit; }
em { font-style: italic; }

.eyebrow { font-size: .72rem; font-weight: 600; letter-spacing: .16em; text-transform: uppercase; color: var(--muted); margin: 0; }

/* ---- Top bar ---- */
.topbar {
    position: sticky; top: 0; z-index: 10;
    display: flex; align-items: center; gap: 1.25rem;
    padding: .7rem 1.25rem;
    background: rgba(244,241,234,.9); backdrop-filter: blur(10px);
    font-size: .88rem;
}
.brand { font-family: var(--serif); font-size: 1.15rem; text-decoration: none; color: var(--ink); }
.topnav { display: none; gap: 1.1rem; margin-left: auto; }
.topnav a { color: var(--muted); text-decoration: none; padding: .2rem 0; border-bottom: 1px solid transparent; }
.topnav a.on { color: var(--ink); border-color: var(--ink); }
.signed-in { margin-left: auto; color: var(--muted); text-decoration: none; white-space: nowrap; }
@media (min-width: 720px) { .topnav { display: flex; } .signed-in { margin-left: 0; } }

/* ---- Layout ---- */
main { padding: 0 1.5rem 3rem; }
.section { max-width: var(--measure); margin: 0 auto; padding: 2.6rem 0; display: flex; flex-direction: column; gap: 1.1rem; }
.section.wide { max-width: 55rem; }
.section > h2 { margin-bottom: .2rem; }
.panel { background: var(--card); margin: 1rem -1.5rem; padding: 1.2rem 1.5rem; }
@media (min-width: 720px) { .panel { margin: 1.5rem 0; padding: 1.4rem 2.5rem; border-radius: 22px; } }

/* ---- Hero ---- */
.hero { max-width: 55rem; margin: 0 auto; padding: 2.6rem 0 1.5rem; display: grid; gap: 1.4rem; }
@media (min-width: 720px) {
    .hero { grid-template-columns: minmax(0, 1fr) 340px; gap: 3.5rem; align-items: end; padding: 4rem 0 2.5rem; }
    .hero-photo { grid-column: 2; grid-row: 1; }
}
.hero-text { display: flex; flex-direction: column; gap: 1.2rem; }
.greeting .dot { color: var(--accent); }
.tagline { font-size: 1.1rem; color: var(--muted); }
.hero-photo { margin: 0; }
.hero-photo img, .family-photo img, .photo img {
    width: 100%; display: block; border-radius: var(--radius); object-fit: cover; background: var(--line);
}
.hero-photo img { border-radius: 20px; }
.chips { list-style: none; padding: 0; margin: 0; display: flex; flex-wrap: wrap; gap: .5rem; }
.chips li { font-size: .82rem; font-weight: 500; color: var(--body); border: 1px solid var(--line); border-radius: 999px; padding: .38rem .8rem; }

/* ---- Playlists ---- */
.playlists { display: flex; flex-wrap: wrap; align-items: center; gap: .5rem .6rem; margin: .1rem 0 .3rem; }
.pl-lead { color: var(--muted); font-size: .88rem; }
.playlists a { display: inline-flex; align-items: baseline; gap: .35rem; text-decoration: none; color: var(--ink);
    border: 1px solid var(--line); background: var(--card); border-radius: 999px; padding: .45rem .9rem; font-size: .88rem; }
.playlists a:hover { border-color: var(--ink); color: var(--ink); }
.pl-service { color: var(--muted); font-size: .85em; }

/* ---- Photos ---- */
.photo-grid { display: grid; grid-template-columns: repeat(2, 1fr); gap: .8rem; }
@media (min-width: 720px) { .photo-grid { grid-template-columns: repeat(3, 1fr); gap: 1rem; } }
.photo { margin: 0; }
.photo.wide { grid-column: 1 / -1; }
.photo figcaption { font-size: .82rem; color: var(--muted); margin-top: .45rem; line-height: 1.45; }
.photo-note { margin-top: .6rem; color: var(--muted); font-size: .92rem; }

/* Missing photo placeholders */
.placeholder-label { display: none; }
figure.missing img { display: none; }
figure.missing .placeholder-label, figure.missing figcaption {
    display: flex; align-items: center; justify-content: center; text-align: center;
    border: 1px dashed var(--line); border-radius: var(--radius); padding: 1rem; color: var(--muted); font-size: .85rem;
}
.hero-photo.missing .placeholder-label { aspect-ratio: 2 / 3; }
.photo.missing figcaption { aspect-ratio: 3 / 4; }
.family-photo.missing .placeholder-label { aspect-ratio: 16 / 9; }

/* ---- Details ---- */
.details { display: grid; gap: 0 2.2rem; margin: 0; }
@media (min-width: 720px) { .details { grid-template-columns: 1fr 1fr; } }
.details div { display: grid; grid-template-columns: 7rem 1fr; gap: .6rem; padding: .7rem 0; border-top: 1px solid var(--line); }
.details dt { font-size: .72rem; font-weight: 600; letter-spacing: .06em; text-transform: uppercase; color: var(--muted); padding-top: .2rem; }
.details dd { margin: 0; color: var(--body); }

/* ---- Family and contact ---- */
.family-photo { margin: 0; }
.contact { align-items: flex-start; }
.whatsapp { display: inline-flex; align-items: center; gap: .7rem; background: var(--ink); color: var(--bg); border-radius: 999px; padding: .8rem 1.2rem; font-size: .95rem; font-weight: 500; }
.whatsapp strong, .whatsapp a { color: var(--bg); font-weight: 500; text-decoration: none; opacity: .85; }
.wa-label { font-size: .72rem; letter-spacing: .1em; text-transform: uppercase; }
.copy { border: 1px solid rgba(244,241,234,.35); background: transparent; color: var(--bg); border-radius: 999px; padding: .25rem .7rem; cursor: pointer; font-size: .78rem; }
.fallback { color: var(--muted); font-size: .88rem; }
.closing { color: var(--muted); margin-top: .4rem; }

.foot { display: flex; justify-content: space-between; padding: 1.2rem 1.5rem 2rem; color: var(--muted); font-size: .82rem; }
.foot a { color: var(--muted); }

/* ---- Gate (guest sign-in) and admin sign-in ---- */
.gate-body { display: grid; min-height: 100vh; place-items: center; padding: 1.5rem; }
.gate-card { background: var(--card); border-radius: 22px; padding: 2.2rem 1.8rem; width: min(100%, 26rem); display: flex; flex-direction: column; gap: 1rem; }
.gate h1 { font-size: 2.6rem; }
.gate .lead { color: var(--muted); }
.gate label { display: block; font-size: .72rem; font-weight: 600; letter-spacing: .1em; text-transform: uppercase; color: var(--muted); margin-bottom: .4rem; }
.gate input { width: 100%; padding: .85rem 1rem; border: 1px solid var(--line); border-radius: 12px; margin-bottom: 1rem; font-size: 1.05rem; background: var(--bg); color: var(--ink); }
.gate input:focus { outline: 2px solid var(--ink); outline-offset: 1px; }
.gate button { width: 100%; padding: .95rem; border: 0; border-radius: 999px; background: var(--ink); color: var(--bg); font-size: 1rem; font-weight: 500; cursor: pointer; }
.error { background: #F6E4E6; color: var(--accent-dark); padding: .7rem 1rem; border-radius: 12px; font-size: .92rem; }
.lead { color: var(--muted); }
