* {
    box-sizing: border-box;
}

body {
    margin: 0;
    background: #f4e9d9;
    color: #681c29;
    font-family: Georgia,serif;
}

button {
    font: inherit;
    cursor: pointer;
}

#opening {
    position: fixed;
    inset: 0;
    display: grid;
    place-content: center;
    justify-items: center;
    background: radial-gradient(ellipse,#fff8e9,#d8c2a7);
    z-index: 10;
    overflow: hidden;
    transition: opacity 1.2s,visibility 1.2s;
}

#envelope {
    position: relative;
    width: min(82vw,620px,68dvh);
    aspect-ratio: 1140/701;
    border: 0;
    padding: 0;
    background: none;
    perspective: 1400px;
    transition: transform 1.7s;
    filter: drop-shadow(0 18px 18px #3b10134d);
}

#envelope img {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    pointer-events: none;
}

.back {
    z-index: 1;
}

.letter {
    position: absolute;
    z-index: 2;
    inset: 5% 7%;
    background: repeating-linear-gradient(35deg,#fff9e9 0 3px,#faf1df 4px 5px);
    padding: 4%;
    box-shadow: 0 2px 12px #0003;
    transition: transform 1.8s cubic-bezier(.2,.8,.2,1);
}

.letter div {
    height: 100%;
    border: 1px solid #b38a4e;
    display: flex;
    flex-direction: column;
    justify-content: center;
    gap: 8%;
    align-items: center;
}

.letter strong {
    font-size: clamp(18px,4vw,42px);
    font-weight: normal;
    font-style: italic;
}

.letter small {
    letter-spacing: 2px;
    font-size: clamp(8px,1.5vw,13px);
}

.letter span {
    font-size: clamp(10px,2vw,16px);
}

.pocket {
    z-index: 3;
}

.flap {
    z-index: 4;
    transform-origin: top center;
    transition: transform 1.25s ease-in-out;
}

.seal {
    z-index: 5;
    inset: auto !important;
    left: 42.98% !important;
    top: 62.77% !important;
    width: 14.04% !important;
    height: 22.82% !important;
    transition: opacity .4s,transform .4s;
}

.closed {
    z-index: 6;
    transition: opacity .25s;
}

.start .closed {
    opacity: 0;
}

.unseal .seal {
    opacity: 0;
    transform: scale(1.15);
}

.flip .flap {
    transform: rotateX(180deg);
}

.behind .flap {
    z-index: 0;
}

.slide .letter {
    transform: translateY(-78%);
}

.slide {
    transform: translateY(22%);
}

.hint {
    text-transform: uppercase;
    letter-spacing: 3px;
    font-size: 11px;
    margin-top: 36px;
    transition: opacity .4s;
}

.busy .hint {
    opacity: 0;
}

#opening.hidden {
    opacity: 0;
    visibility: hidden;
    pointer-events: none;
}

#invitation {
    min-height: 100dvh;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    text-align: center;
    padding: 24px;
    background: radial-gradient(#fffaf0,#ead8bf);
}

h1 {
    font-size: clamp(42px,9vw,90px);
    font-weight: normal;
    font-style: italic;
    margin: 12px;
}

.eyebrow {
    text-transform: uppercase;
    letter-spacing: 3px;
    font-size: 12px;
}

#replay {
    margin-top: 30px;
    border: 1px solid #681c29;
    background: transparent;
    color: inherit;
    padding: 12px 20px;
}

@media(prefers-reduced-motion:reduce) {
    *,*::before,*::after {
        transition: none !important;
    }
}

html {
    scroll-behavior: smooth;
}

body.locked {
    overflow: hidden;
}

#invitation {
    display: block;
    padding: 0;
    background: #f8efdf;
}

#envelope {
    width: min(86vw,620px,83dvh);
}

#envelope .seal {
    z-index: 7;
    left: 50% !important;
    top: 74% !important;
    width: 15% !important;
    height: auto !important;
    transform: translate(-50%,-50%);
    filter: drop-shadow(0 4px 4px #250b0b88);
}

#envelope.unseal .seal {
    transform: translate(-50%,-50%) scale(1.12);
}

.panel {
    position: relative;
    padding: clamp(52px,9vw,100px) 24px;
    max-width: 920px;
    margin: auto;
    line-height: 1.85;
}

.panel:not(:last-child):after {
    content: "❦";
    position: absolute;
    bottom: -18px;
    left: 50%;
    transform: translateX(-50%);
    font-size: 24px;
    color: #a77c42;
    z-index: 1;
}

.hero {
    min-height: 100svh;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
}

.monogram {
    width: 115px;
    height: 115px;
    object-fit: contain;
    mix-blend-mode: multiply;
}

.hero h1 {
    line-height: 1.1;
}

.hero h1 i {
    color: #a77c42;
    font-size: .65em;
}

.date {
    letter-spacing: 2px;
}

.gu {
    font-family: "Noto Serif Gujarati","Nirmala UI",Shruti,serif;
    font-size: clamp(16px,2.6vw,20px);
}

h2 {
    font-size: clamp(28px,5vw,48px);
    font-weight: normal;
    line-height: 1.25;
    margin: 14px 0 28px;
}

h3 {
    font-weight: normal;
    font-size: 23px;
}

.tinted {
    background: #f0e0c9;
}

.family-grid {
    display: grid;
    grid-template-columns: repeat(2,1fr);
    gap: 20px;
}

.timeline {
    display: grid;
    grid-template-columns: repeat(2,1fr);
    gap: 16px;
}

.timeline article {
    border: 1px solid #b99565;
    padding: 22px 12px;
    background: #fff9ed;
}

.timeline span {
    color: #8a6337;
    font-weight: bold;
    letter-spacing: 1px;
}

.timeline h3 {
    margin: 10px 0;
}

.timeline p {
    margin: 0;
}

address {
    font-style: normal;
}

.cta,.scroll {
    display: inline-block;
    color: inherit;
    text-decoration: none;
    border-bottom: 1px solid #a77c42;
    margin-top: 24px;
}

.cta {
    background: #681c29;
    color: #fff6e5;
    padding: 10px 22px;
    border: 0;
}

.guest {
    margin-top: 28px;
}

footer a {
    color: inherit;
}

#replay {
    display: inline-block;
}

@media(max-width:520px) {
    .family-grid,.timeline {
        grid-template-columns: 1fr;
    }

    .panel {
        padding-inline: 20px;
    }
}

@media(prefers-reduced-motion:reduce) {
    html {
        scroll-behavior: auto;
    }
}

/* FULL SCREEN ENVELOPE — responsive opening cover */

#opening {
    display: block;
    background: #651321;
    isolation: isolate;
    z-index: 100;
}

#envelope {
    position: absolute;
    left: 50%;
    top: 50%;
    width: 100vw;
    height: 100dvh;
    aspect-ratio: auto;
    transform: translate(-50%,-50%);
    filter: none;
    transition: width .9s cubic-bezier(.2,.8,.2,1),height .9s cubic-bezier(.2,.8,.2,1),transform 1.7s;
}

#envelope .seal {
    width: clamp(76px,15vmin,180px) !important;
    height: auto !important;
    top: 74% !important;
}

#envelope.compact {
    width: min(88vw,760px,90dvh);
    height: auto;
    aspect-ratio: 1140/701;
    filter: drop-shadow(0 18px 18px #250b0b66);
}

#envelope.compact .seal {
    width: 15% !important;
}

#envelope.slide {
    transform: translate(-50%,-28%);
}

#opening .hint {
    position: absolute;
    bottom: max(24px,env(safe-area-inset-bottom));
    left: 0;
    right: 0;
    margin: 0;
    text-align: center;
    color: #ffe8bc;
    text-shadow: 0 2px 5px #24050b;
    pointer-events: none;
    z-index: 12;
    font-size: clamp(10px,2.5vw,14px);
}

#opening.busy {
    background: radial-gradient(ellipse,#fff8e9,#d8c2a7);
    transition: background .9s,opacity 1.2s,visibility 1.2s;
}

/* New source artwork: closed and open faces from supplied image. */

#envelope.compact {
    aspect-ratio: 1140/630;
    width: min(88vw,760px,75dvh);
}

#envelope .seal {
    top: 75% !important;
    width: clamp(80px,17vmin,180px) !important;
}

#envelope.compact .seal {
    width: 16% !important;
}

#envelope .flap {
    position: absolute;
    left: 0;
    top: 0;
    width: 100%;
    height: 80%;
    transform-style: preserve-3d;
    transform-origin: top center;
    z-index: 4;
}

#envelope .flap img {
    backface-visibility: hidden;
    object-fit: fill;
}

#envelope .flap-inner {
    transform: rotateX(180deg);
}

#envelope.behind .flap {
    z-index: 0;
}

#envelope .closed {
    transition: none;
}

#envelope.start .closed {
    opacity: 1;
}

#envelope.flip .closed {
    opacity: 0;
}

#envelope.slide {
    transform: translate(-50%,-20%);
}

/* FLORAL PAPER EDITION — inner pages only */

#invitation {
    background: #e9ddc7;
    padding: clamp(12px,3vw,38px);
    overflow: clip;
}

#invitation .panel {
    max-width: 860px;
    margin: 0 auto 28px;
    padding: clamp(65px,12vw,130px) clamp(20px,9vw,92px);
    background: linear-gradient(#fff8eac9,#fff8eac9),url("images/floral-paper.png") center/cover;
    border: 1px solid #b79560;
    box-shadow: 0 12px 32px #4e202022;
    isolation: isolate;
    overflow: hidden;
}

#invitation .panel::before {
    content: "";
    position: absolute;
    inset: 12px;
    border: 1px solid #b7956077;
    pointer-events: none;
    z-index: -1;
}

#invitation .panel::after {
    content: "❦";
    position: static;
    display: block;
    transform: none;
    margin: 28px auto -25px;
    color: #9a713b;
    font-size: 26px;
}

#invitation .hero {
    min-height: calc(100svh - 24px);
    background: url("images/floral-paper.png") center/100% 100%;
    padding-block: clamp(90px,15vw,170px);
}

.hero .gu,.hero .date,.hero .eyebrow,.hero h1 {
    text-shadow: 0 1px 5px #fff8e8;
}

.hero .monogram {
    width: 92px;
    height: 92px;
}

.hero h1 {
    font-size: clamp(42px,9vw,82px);
}

.countdown {
    width: min(100%,460px);
    margin: 20px auto 0;
    padding: 14px 10px 20px;
    background: #fff9eddb;
    border: 1px solid #b79560;
    box-shadow: 0 5px 16px #6b24301a;
}

.countdown .eyebrow {
    margin: 0 0 12px;
    letter-spacing: 2px;
}

.count-grid {
    display: grid;
    grid-template-columns: repeat(4,minmax(0,1fr));
    gap: 6px;
}

.count-grid div {
    background: #681c29;
    color: #fff0d3;
    border: 1px solid #b79560;
    padding: 10px 2px;
    box-shadow: inset 0 0 0 2px #681c29,inset 0 0 0 3px #b7956066;
}

.count-grid strong {
    display: block;
    font-size: clamp(22px,5vw,36px);
    font-weight: normal;
    line-height: 1.1;
    font-variant-numeric: tabular-nums;
}

.count-grid small {
    font-size: 10px;
    letter-spacing: .6px;
}

.family-grid>div,.timeline article {
    background: #fffaf0e8;
    border: 1px solid #b79560;
    outline: 1px solid #b7956055;
    outline-offset: -6px;
    padding: 24px 14px;
    box-shadow: 0 6px 18px #681c2912;
}

.family-grid h3 {
    margin-top: 0;
}

.event-symbol {
    font-size: 36px;
    color: #a77c42;
    line-height: 1.2;
    margin-bottom: 12px;
}

.timeline span {
    display: inline-block;
    background: #681c29;
    color: #fff1d5;
    padding: 5px 12px;
    font-size: 13px;
}

.cta {
    border: 1px solid #b79560;
    box-shadow: 0 5px 15px #681c2922;
    padding: 14px 24px;
}

.guest {
    border-block: 1px solid #b79560;
    padding: 12px;
}

.panel.reveal-ready {
    opacity: 0;
    transform: translateY(22px);
    transition: opacity .75s ease,transform .75s ease;
}

.panel.reveal-ready.revealed {
    opacity: 1;
    transform: none;
}

@media(min-width:700px) {
    #invitation .panel {
        background-size: cover,100% 100%;
    }

    #invitation .hero {
        background-size: 100% 100%;
    }
}

@media(max-width:520px) {
    #invitation .panel {
        padding-inline: 24px;
        background-size: cover,100% 100%;
    }

    .timeline {
        grid-template-columns: repeat(2,minmax(0,1fr));
        gap: 10px;
    }

    .timeline article {
        padding: 18px 8px;
    }

    .timeline h3 {
        font-size: 18px;
    }

    .timeline span {
        font-size: 11px;
        padding: 4px 5px;
    }

    .hero .eyebrow {
        font-size: 10px;
    }

    .hero .gu {
        font-size: 15px;
    }
}

@media(prefers-reduced-motion:reduce) {
    .panel.reveal-ready {
        opacity: 1;
        transform: none;
    }
}

/* Editorial layout inspired by reference video */

#invitation {
    padding: 0 12px 24px;
    background: #e9ddc7;
}

.topline {
    position: sticky;
    top: 0;
    z-index: 20;
    display: flex;
    align-items: center;
    gap: 20px;
    max-width: 860px;
    margin: auto;
    background: #681c29;
    color: #fff2d6;
    padding: 8px 18px;
    border-bottom: 2px solid #b79560;
}

.topline img {
    width: 42px;
    height: 42px;
    object-fit: contain;
    background: #f8ecd5;
    border-radius: 50%;
}

.topline a {
    color: inherit;
    text-decoration: none;
    font-size: 13px;
}

.topline a:first-of-type {
    margin-left: auto;
}

.ritual-icon {
    width: 62px;
    height: 62px;
    display: block;
    margin: auto;
}

.ganesh {
    width: 80px;
    height: 80px;
    margin: 8px auto;
}

.hero h1 {
    max-width: 100%;
    font-size: clamp(48px,10vw,88px);
}

#invitation .panel {
    scroll-margin-top: 65px;
    background: linear-gradient(#fff8eab0,#fff8eab0),url("images/floral-paper.png") center/100% 100%;
    padding: clamp(70px,12vw,125px) clamp(22px,7vw,75px);
}

#invitation .hero {
    background: url("images/floral-paper.png") center/100% 100%;
}

.hero .gu {
    line-height: 1.9;
}

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

.timeline article {
    display: grid;
    grid-template-columns: 72px 1fr;
    text-align: left;
    align-items: center;
    column-gap: 14px;
    padding: 18px 20px;
}

.timeline .event-symbol {
    grid-row: 1/4;
    margin: 0;
}

.timeline span {
    justify-self: start;
    background: transparent;
    color: #80572d;
    padding: 0;
}

.timeline h3 {
    margin: 3px 0;
}

.timeline p {
    grid-column: 2;
}

.venue-arch {
    border: 2px solid #b79560;
    border-radius: 50% 50% 0 0 / 45% 45% 0 0;
    max-width: 420px;
    margin: 24px auto;
    padding: 50px 18px 24px;
    background: #681c29;
    color: #f6e0b4;
    box-shadow: inset 0 0 0 6px #681c29,inset 0 0 0 7px #b79560;
}

.venue-arch h2 {
    margin: 8px 0;
    font-size: clamp(26px,5vw,44px);
}

.arch-ornament {
    color: #d5ad65;
    font-size: 28px;
}

.pin {
    width: 36px;
    height: 36px;
    margin: 20px auto 0;
}

.panel.gu {
    text-align: left;
}

.panel.gu h2,.panel.gu h3 {
    text-align: center;
    color: #681c29;
    border-bottom: 1px solid #b79560;
    padding-bottom: 12px;
}

.panel.gu p {
    background: #fff8e9b8;
    padding: 18px;
    line-height: 2.2;
}

#invitation footer.panel {
    background: #681c29;
    color: #fff0d3;
}

footer #replay {
    border-color: #d5ad65;
}

@media(max-width:520px) {
    .timeline article {
        grid-template-columns: 52px 1fr;
        padding: 16px 12px;
    }

    .ritual-icon {
        width: 48px;
        height: 48px;
    }

    .ganesh {
        width: 65px;
        height: 65px;
    }

    .topline {
        gap: 12px;
    }

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

/* Wedding date emphasis */

.hero .date {
    font-size: clamp(18px, 3.2vw, 24px);
    font-weight: 600;
    letter-spacing: 1.5px;
    line-height: 1.5;
    text-align: center;
}

/* Bilingual and music controls */

#language,#music-toggle {
    border: 1px solid #b38c50;
    background: #731e30;
    color: #fff4dc;
    border-radius: 24px;
    padding: 9px 14px;
    cursor: pointer;
    font: inherit;
}

#music-toggle {
    position: fixed;
    bottom: 20px;
    right: 20px;
    z-index: 120;
    width: 48px;
    height: 48px;
    padding: 0;
    box-shadow: 0 3px 12px #0003;
}

#music-toggle[hidden] {
    display: none;
}

.hero .date {
    font-size: clamp(18px,3.2vw,24px);
    font-weight: 600;
}

.topline {
    flex-wrap: wrap;
}

/* Mobile-first refinements */

html,body {
    max-width: 100%;
    overflow-x: clip;
}

img {
    max-width: 100%;
}

.panel,.timeline article,.family-grid>div {
    min-width: 0;
    overflow-wrap: anywhere;
}

.topline {
    padding-top: max(8px,env(safe-area-inset-top));
    gap: 12px;
}

.topline a,#language,.cta,#replay {
    min-height: 44px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
}

#music-toggle {
    bottom: max(16px,env(safe-area-inset-bottom));
    right: max(16px,env(safe-area-inset-right));
}

.count-grid small {
    display: block;
    overflow-wrap: normal;
}

@media(max-width:600px) {
    #invitation {
        padding: 0 0 72px;
    }

    .topline {
        display: grid;
        grid-template-columns: 36px minmax(0,1fr) minmax(0,1fr) auto;
        gap: 6px;
        padding-inline: 10px;
    }

    .topline img {
        width: 36px;
        height: 36px;
    }

    .topline a:first-of-type {
        margin-left: 0;
    }

    .topline a {
        font-size: 13px;
    }

    #language {
        font-size: 13px;
        padding: 6px 10px;
    }

    #invitation .panel {
        margin: 0 8px 16px;
        padding: 76px 22px 58px;
        scroll-margin-top: 80px;
    }

    #invitation .hero {
        min-height: calc(100svh - 60px);
        padding-top: 100px;
        padding-bottom: 95px;
    }

    .hero h1 {
        font-size: clamp(34px,10vw,60px);
        margin: 10px 0;
    }

    .hero .date {
        font-size: clamp(18px,5vw,23px);
        letter-spacing: .5px;
    }

    .hero .gu {
        font-size: 16px;
    }

    .countdown {
        padding: 12px 6px;
    }

    .count-grid {
        gap: 4px;
    }

    .count-grid strong {
        font-size: 25px;
    }

    .count-grid small {
        font-size: 10px;
        letter-spacing: 0;
    }

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

    .timeline article {
        grid-template-columns: 48px minmax(0,1fr);
        gap: 4px 12px;
    }

    .timeline h3 {
        font-size: 19px;
    }

    .timeline span {
        font-size: 14px;
    }

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

    .panel.gu p {
        padding: 12px;
    }

    .venue-arch {
        padding-inline: 12px;
    }

    .cta {
        max-width: 100%;
        white-space: normal;
    }

    #envelope.compact {
        width: min(92vw,75dvh);
    }

    #opening .hint {
        bottom: max(28px,calc(env(safe-area-inset-bottom) + 12px));
    }
}

@media(max-width:350px) {
    #invitation .panel {
        padding-inline: 15px;
    }

    .topline {
        gap: 3px;
        padding-inline: 5px;
    }

    .topline a,#language {
        font-size: 12px;
    }

    .count-grid strong {
        font-size: 21px;
    }

    .count-grid small {
        font-size: 9px;
    }

    .hero .gu {
        font-size: 15px;
    }
}

/* Responsive desktop and tablet layout — mobile rules remain intact. */

@media (min-width: 601px) {
    #invitation {
        padding: 0 24px 40px;
    }

    .topline {
        max-width: 1040px;
        flex-wrap: nowrap;
        gap: 24px;
    }

    #invitation .panel {
        max-width: 1040px;
        padding: clamp(70px, 9vw, 120px) clamp(32px, 7vw, 90px);
    }

    #invitation .hero {
        min-height: calc(100svh - 62px);
    }

    .family-grid {
        grid-template-columns: repeat(2,minmax(0,1fr));
    }

    .timeline {
        grid-template-columns: repeat(2,minmax(0,1fr));
        gap: 18px;
    }

    .timeline article {
        grid-template-columns: 56px minmax(0,1fr);
        padding: 20px 16px;
    }

    .timeline .ritual-icon {
        width: 52px;
        height: 52px;
    }

    .countdown {
        width: min(100%, 520px);
    }
}

@media (min-width: 601px) and (max-width: 820px) {
    .timeline {
        grid-template-columns: 1fr;
    }
}

@media (min-width: 1024px) {
    #invitation {
        padding-inline: 40px;
    }

    .hero h1 {
        font-size: clamp(70px, 7vw, 100px);
    }

    .hero .date {
        font-size: 24px;
    }
}

/* Preserve the seal's proportions at all screen sizes. */

#envelope .seal {
    object-fit: contain;
}

/* Illustrated ceremony cards: editable text, responsive artwork. */

#schedule .timeline article {
    grid-template-columns: minmax(0, 43%) minmax(0,1fr);
    grid-template-rows: auto auto;
    gap: 8px 16px;
    padding: 20px 16px;
    min-height: 155px;
    align-content: center;
    background: #fff8ecf5;
}

#schedule .event-symbol {
    grid-column: 1;
    grid-row: 1/3;
    align-self: center;
    margin: 0;
    padding-right: 10px;
    border-right: 1px solid #b7956088;
}

#schedule .ritual-icon {
    width: 100%;
    height: auto;
    aspect-ratio: 1.35;
    object-fit: contain;
    mix-blend-mode: multiply;
}

#schedule .timeline article>span {
    grid-column: 2;
    align-self: end;
    color: #681c29;
    font-size: clamp(15px,1.5vw,20px);
    font-weight: bold;
}

#schedule .timeline h3 {
    grid-column: 2;
    align-self: start;
    margin: 0;
    font-size: clamp(16px,1.5vw,21px);
    line-height: 1.6;
    border-top: 1px solid #b7956077;
    padding-top: 8px;
}

@media(max-width:600px) {
    #schedule .timeline article {
        grid-template-columns: minmax(0,40%) minmax(0,1fr);
        min-height: 120px;
        padding: 12px;
        gap: 5px 10px;
    }

    #schedule .event-symbol {
        padding-right: 6px;
    }

    #schedule .timeline h3 {
        font-size: 16px;
    }

    #schedule .timeline article>span {
        font-size: 15px;
    }
}

/* Final illustrated layout */

#invitation #schedule .timeline article {
    display: grid;
    grid-template-columns: minmax(0,46%) minmax(0,1fr);
    grid-template-rows: auto auto;
    min-height: 190px;
    padding: 12px;
    gap: 8px 12px;
    text-align: center;
}

#invitation #schedule .timeline .event-symbol {
    grid-column: 1;
    grid-row: 1/3;
    width: 100%;
    padding: 0 8px 0 0;
    align-self: center;
}

#invitation #schedule .timeline img.ritual-icon {
    display: block;
    width: 100%;
    max-width: none;
    height: auto;
    aspect-ratio: auto;
    object-fit: contain;
    margin: 0;
    mix-blend-mode: multiply;
}

#invitation #schedule .timeline article>span {
    justify-self: center;
    font-size: clamp(16px,2vw,23px);
    white-space: normal;
}

#invitation #schedule .timeline h3 {
    font-size: clamp(16px,1.8vw,23px);
    color: #681c29;
    text-align: center;
}

@media(max-width:820px) {
    #invitation #schedule .timeline {
        grid-template-columns: 1fr;
    }

    #invitation #schedule .timeline article {
        min-height: 145px;
    }
}

@media(max-width:360px) {
    #invitation #schedule .timeline article {
        grid-template-columns: 40% minmax(0,1fr);
        gap: 6px;
        min-height: 125px;
    }

    #invitation #schedule .timeline article>span {
        font-size: 14px;
    }
}

/* Final Ganesha artwork */

#invitation img.ganesh {
    width: clamp(150px,24vw,300px);
    height: auto;
    max-width: 80%;
    object-fit: contain;
    margin: 12px auto 16px;
    mix-blend-mode: multiply;
}

@media(max-width:600px) {
    #invitation img.ganesh {
        width: clamp(145px,48vw,220px);
        margin: 8px auto 12px;
    }
}

#invitation img.ganesh {
    mix-blend-mode: normal;
    background: transparent;
}

/* MOBILE FONT SIZE CORRECTION */

@media (max-width: 600px) {
    /* General invitation text */

    #invitation {
        font-size: 14px;
    }

    /* Gujarati text */

    #invitation .gu {
        font-size: 14px;
        line-height: 1.8;
    }

    /* Couple names */

    #invitation .hero h1 {
        font-size: 36px;
    }

    /* Main headings */

    #invitation h2 {
        font-size: 24px;
    }

    /* Subheadings */

    #invitation h3 {
        font-size: 18px;
    }

    /* Family names and descriptions */

    #invitation .panel p,
    #invitation .family-grid p {
        font-size: 14px;
        line-height: 1.8;
    }

    /* Wedding date */

    #invitation .hero .date {
        font-size: 18px;
    }

    /* Ceremony timings */

    #invitation #schedule .timeline article > span {
        font-size: 14px;
    }

    /* Ceremony names */

    #invitation #schedule .timeline h3 {
        font-size: 15px;
    }

    /* Countdown timer */

    #invitation .count-grid strong {
        font-size: 22px;
    }

    #invitation .count-grid small {
        font-size: 10px;
    }

    /* Venue details */

    #invitation .venue-arch h2 {
        font-size: 22px;
    }

    #invitation address {
        font-size: 14px;
        line-height: 1.7;
    }

    /* Guest instructions */

    #invitation .guest {
        font-size: 13px;
    }
}

/* Final accessibility and bilingual spacing fixes */

html[lang="gu"] #invitation .gu, html[lang="gu"] #invitation [data-i18n] {
    letter-spacing: normal;
    word-spacing: normal;
}

#invitation .panel p, #invitation address {
    overflow-wrap: break-word;
}

#invitation #schedule .timeline article > span {
    min-width: 0;
    overflow-wrap: break-word;
    text-align: center;
}

#invitation #schedule .timeline h3 {
    min-width: 0;
    overflow-wrap: break-word;
}

button:focus-visible, a:focus-visible {
    outline: 2px solid #b79560;
    outline-offset: 3px;
}

#invitation:focus {
    outline: none;
}

@media (max-width:350px) {
    .count-grid div {
        padding-inline: 1px;
    }

    .count-grid small {
        font-size: 9px;
    }
}
