:root {
    --red: #b1353a;
    --cream: #f8f6f1;
    --blue: #a9c9e4;
    --ink: #5b1f22;
}

@font-face {
    font-family: 'Aloja';
    src: url('../fonts/Aloja-Light.woff') format('woff');
    font-style: normal;
    font-weight: 300;
    font-display: swap;
}

html {
    scrollbar-width: none;
    -ms-overflow-style: none;
}

html::-webkit-scrollbar {
    display: none;
}

img.bismillah {
    width: 25rem;
    position: absolute;
    top: 1rem;
    left: 50%;
    transform: translateX(-50%);
    mix-blend-mode: multiply;
    /* Membuat warna putih pada gambar menjadi transparan */
}

img.location {
    width: 25rem;
    position: absolute;
    top: 5rem;
    left: 50%;
    transform: translateX(-50%);
    mix-blend-mode: multiply;
}

body {
    margin: 0;
    background: #dcd6ca;
    color: var(--red);
    font-family: 'Gaegu', cursive;
    font-size: 1.2rem;
    line-height: 1.35;
}

p {
    margin: 0;
}

.display {
    font-family: 'Caveat Brush', cursive;
    line-height: 1.05;
    font-weight: 400;
    margin: 0;
}

.display.font-aloja {
    font-family: 'Aloja', sans-serif;
}

.spaced {
    letter-spacing: 0.4em;
    text-transform: uppercase;
}

.cursor-pointer {
    cursor: pointer;
}

/* Layout */
.page {
    max-width: 480px;
    margin: 0 auto;
    background: var(--cream);
    box-shadow: 0 0 2rem rgba(0, 0, 0, 0.25);
    overflow: hidden;
}

.sec {
    position: relative;
    padding: 4rem 1.75rem;
    text-align: center;
    overflow: hidden;
}

.sec-cream {
    background: var(--cream);
    color: var(--red);
}

.sec-red {
    background: var(--red);
    color: var(--cream);
}

.sec-blue {
    background: var(--blue);
    color: var(--red);
}

.player {
    max-width: 21rem;
    margin: 0 auto 1.75rem;
    padding: 1.5rem;
    background: var(--red);
    color: #fff;
    border-radius: 2rem 2rem 2rem 2rem;
    box-shadow: 0 0.5rem 1.5rem rgba(0, 0, 0, 0.15);
}

.foto-prewed {
    max-width: 21rem;
    margin: 0 auto 1.75rem;
    padding: 0.5rem;
    background: var(--red);
    color: #fff;
    border-radius: 0.5rem 0.5rem 0.5rem 0.5rem;
}

.player-photo {
    display: block;
    width: 100%;
    aspect-ratio: 1;
    object-fit: cover;
    border-radius: 4px;
}

.player-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin: 1.5rem 0 1rem;
    font-size: 1.4rem;
}

.player-bar {
    position: relative;
    height: 0.4rem;
    border-radius: 999px;
    background: #aaa;
}

.player-bar span {
    position: absolute;
    inset: 0 auto 0 0;
    width: 36%;
    border-radius: 999px;
    background: #fff;
}

.player-bar span::after {
    content: "";
    position: absolute;
    right: -0.6rem;
    top: 50%;
    width: 1.2rem;
    height: 1.2rem;
    border-radius: 50%;
    background: #fff;
    transform: translateY(-50%);
}

.player-controls {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-top: 1.5rem;
    font-size: 1.5rem;
}

.player-controls .play {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 4.6rem;
    height: 4.6rem;
    border-radius: 50%;
    background: #fff;
    color: var(--red);
    font-size: 2rem;
}

.quote {
    max-width: 21rem;
    margin-left: auto;
    margin-right: auto;
    text-align: left;
    font-size: 1.3rem;
}

.sec-title {
    font-size: 3.5rem;
    margin-bottom: 1rem;
}

.sec-text {
    font-size: 1.3rem;
    margin: 0 auto;
    max-width: 20rem;
}

/* Hand-drawn pieces */
.sketch {
    border: 4px solid var(--blue);
    border-radius: 255px 18px 225px 18px / 18px 225px 18px 255px;
}

.frame {
    display: block;
    width: 100%;
    border: 4px solid var(--blue);
    border-radius: 14px 22px 12px 24px / 22px 12px 24px 14px;
    background: #000;
}

.frame-round {
    width: 12rem;
    height: 12rem;
    object-fit: cover;
    border: 4px solid var(--blue);
    border-radius: 58% 42% 55% 45% / 48% 56% 44% 52%;
}

.frame-round-1 {
    width: 6rem;
    height: 6rem;
    object-fit: cover;
    border: 4px solid var(#F8F6F0);
    border-radius: 50%;
}

.polaroid {
    background: #fff;
    padding: 0.6rem 0.6rem 2.2rem;
    box-shadow: 0 0.5rem 1.2rem rgba(0, 0, 0, 0.25);
    transform: rotate(var(--r, -4deg));
}

.polaroid img {
    display: block;
    width: 100%;
    aspect-ratio: 1;
    object-fit: cover;
}

.sparkle {
    position: absolute;
    width: 1.4rem;
    height: 1.4rem;
    background: var(--blue);
    clip-path: polygon(50% 0, 60% 40%, 100% 50%, 60% 60%, 50% 100%, 40% 60%, 0 50%, 40% 40%);
    animation: twinkle 2.4s ease-in-out infinite;
}

@keyframes twinkle {

    0%,
    100% {
        transform: scale(1) rotate(0);
        opacity: 1;
    }

    50% {
        transform: scale(0.6) rotate(25deg);
        opacity: 0.5;
    }
}

.love {
    position: absolute;
    opacity: 0;
    font-size: 1.8rem;
    color: var(--blue);
}

.love.animate-love {
    animation: love-float 4s ease-in-out infinite;
}

@keyframes love-float {

    0%,
    100% {
        opacity: 0.9;
        transform: translateY(0) scale(1);
    }

    50% {
        opacity: 0.4;
        transform: translateY(-0.75rem) scale(1.15);
    }
}

.btn-red,
.btn-cream {
    display: inline-block;
    border: 0;
    border-radius: 999px;
    padding: 0.4rem 1.5rem;
    font-family: inherit;
    font-size: 1.25rem;
    font-weight: 700;
    text-decoration: none;
    transition: transform 0.15s ease;
}

.btn-red {
    background: var(--red);
    color: var(--cream);
}

.btn-cream {
    background: var(--cream);
    color: var(--red);
}

.btn-red:hover,
.btn-cream:hover {
    transform: scale(1.05);
}

.btn-red:disabled {
    opacity: 0.6;
}

.btn-sm-red {
    background: var(--red);
    color: var(--cream);
    border: 0;
    border-radius: 999px;
    padding: 0.1rem 0.9rem;
    font-family: inherit;
    font-size: 1rem;
    white-space: nowrap;
    border: 2px solid var(--cream);
    transition: transform 0.2s ease, background-color 0.2s ease, color 0.2s ease, box-shadow 0.2s ease;
}

.btn-sm-red:hover {
    background: var(--cream);
    color: var(--red);
    transform: translateY(-3px) scale(1.06);
    box-shadow: 0 0.4rem 0.8rem rgba(0, 0, 0, 0.25);
}

.btn-sm-red:active {
    transform: translateY(0) scale(0.97);
}


.couple-container {
    display: flex;
    justify-content: center;
    /* Memosisikan elemen di tengah secara horizontal */
    align-items: center;
    /* Memosisikan elemen sejajar di tengah secara vertikal */
    gap: 1.5rem;
    /* Jarak antara foto Nabila dan Bayu */
    margin-top: 1.5rem;
}

.btn-sm-red:hover i {
    animation: btn-icon-wiggle 0.6s ease;
}

@keyframes btn-icon-wiggle {

    0%,
    100% {
        transform: rotate(0) scale(1);
    }

    30% {
        transform: rotate(-18deg) scale(1.25);
    }

    60% {
        transform: rotate(14deg) scale(1.25);
    }
}

/* Cover + loading */
.loading-page {
    position: fixed;
    inset: 0;
    z-index: 1056;
    overflow-y: auto;
    background: var(--cream);
    color: var(--red);
    transition: opacity 0.8s ease;
}

.cover {
    min-height: 100%;
    max-width: 480px;
    margin: 0 auto;
    padding: 2.5rem 1.75rem;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    text-align: center;
    gap: 1.25rem;
}

.cover .tagline {
    max-width: 100%;
    font-family: 'Aloja', sans-serif;
    font-size: clamp(4rem, 17vw, 6.5rem);
    line-height: 1.05;
    letter-spacing: 0;
}

.cover .cover-photos {
    position: relative;
    width: 15rem;
    height: 14rem;
    margin: 0.5rem 0;
}

.cover .cover-photos .polaroid {
    position: absolute;
    width: 8rem;
}

.guest-label {
    font-size: 1.3rem;
}

.guest-title {
    font-family: 'Caveat Brush', cursive;
    font-size: 2.6rem;
    font-weight: 400;
    margin: 0;
}

.loading-box {
    width: 14rem;
    text-align: center;
}

.progress {
    height: 0.5rem;
    background: rgba(177, 53, 58, 0.2);
}

.progress-bar {
    background: var(--red);
}

#root {
    transition: opacity 1s ease;
}

/* Hero */
.hero-date {
    font-size: 2.2rem;
    letter-spacing: 0.15em;
}

.hero-names {
    font-size: clamp(2.8rem, 16vw, 4rem);
}

.hero-hands {
    position: relative;
    height: 19rem;
    margin: 1rem auto 0;
    max-width: 22rem;
}

.hero-hands .hand {
    position: absolute;
    width: 70%;
    mix-blend-mode: multiply;
}

.hand-woman {
    top: 0;
    left: 0;
    animation: reach-left 3.2s ease-in-out infinite;
}

.hand-man {
    bottom: 0;
    right: 0;
    animation: reach-right 3.2s ease-in-out infinite;
}

@keyframes reach-left {

    0%,
    100% {
        translate: 0 0;
        rotate: -3deg;
    }

    50% {
        translate: 0.5rem 0.3rem;
        rotate: 2deg;
    }
}

@keyframes reach-right {

    0%,
    100% {
        translate: 0 0;
        rotate: 3deg;
    }

    50% {
        translate: -0.5rem -0.3rem;
        rotate: -2deg;
    }
}

@media (prefers-reduced-motion: reduce) {

    .hand-woman,
    .hand-man {
        animation: none;
    }
}

/* Verse */
.verse {
    font-size: 1.35rem;
    line-height: 1.5;
    margin: 1.5rem auto 1rem;
    max-width: 22rem;
}

/* Couple */
.person {
    margin: 2rem 0;
}

.person .name {
    font-size: 2.6rem;
    margin: 1.25rem 0 0.4rem;
}

.amp {
    font-size: 5rem;
}

/* Save the date */
.calendar {
    display: flex;
    justify-content: center;
    gap: 0.75rem;
    margin: 1.5rem 0;
}

.calendar .day {
    width: 5.5rem;
    padding: 0.6rem 0;
    border: 3px solid var(--blue);
    border-radius: 14px 22px 12px 24px / 22px 12px 24px 14px;
}

.calendar .day.active {
    background: var(--cream);
    color: var(--red);
    transform: rotate(-3deg) scale(1.08);
}

.calendar .day b {
    display: block;
    font-size: 2.2rem;
    font-family: 'Caveat Brush', cursive;
    font-weight: 400;
}

.countdown {
    display: flex;
    justify-content: center;
    gap: 0.6rem;
    margin: 1.25rem 0 2rem;
}

.countdown div {
    min-width: 4.2rem;
    padding: 0.4rem 0.2rem;
    border: 3px solid var(--blue);
    border-radius: 14px 20px 12px 22px / 20px 12px 22px 14px;
}

.countdown b {
    display: block;
    font-family: 'Caveat Brush', cursive;
    font-size: 2rem;
    font-weight: 400;
    line-height: 1;
}

.countdown small {
    font-size: 1rem;
}

.event {
    margin: 1.5rem 0;
}

.event h3 {
    font-family: 'Caveat Brush', cursive;
    font-size: 2.4rem;
    font-weight: 400;
    margin: 0;
}

.swatches {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 0.75rem;
    /* Memberi jarak otomatis dan rapi antar bulatan */
    margin: 0.75rem 0;
}

.swatches span {
    width: 2.6rem;
    height: 2.6rem;
    border-radius: 50%;
    border: 3px solid #ffffff;
    /* atau var(--white) */
    /* Tambahkan box-shadow tipis agar border putih terlihat jelas memisahkan bulatan */
    box-shadow: 0 2px 5px rgba(0, 0, 0, 0.15);

    /* Hapus margin-left negatif agar tidak saling bertumpuk/berpotongan */
    margin-left: 0;
}

.swatches span:first-child {
    margin-left: 0;
}

/* Location */
.map-card {
    margin: 1.5rem auto;
    padding: 1.25rem 1rem;
    max-width: 20rem;
    transform: rotate(-2deg);
    background: #fff;
}

/* Gallery */
.masonry {
    columns: 2;
    column-gap: 0.8rem;
}

.masonry .frame {
    margin-bottom: 0.8rem;
    break-inside: avoid;
    cursor: pointer;
}

/* Gift */
.gift-card {
    position: relative;
    margin: 1.5rem auto;
    padding: 1rem 1.25rem 1rem;
    width: 17rem;
    max-width: 90%;
    text-align: left;
    background: var(--cream);
    color: #222;
    border: 4px solid var(--blue);
    border-radius: 6px 14px 8px 12px / 12px 8px 14px 6px;
    rotate: var(--r, -3deg);
}

.gift-card .bank {
    font-weight: 700;
    color: var(--red);
    font-size: 1.4rem;
}

.gift-card .number {
    font-size: 1.4rem;
    letter-spacing: 0.08em;
}

.gift-card .holder {
    font-size: 1rem;
    margin-top: 0.75rem;
    display: flex;
    justify-content: space-between;
    align-items: flex-end;
    gap: 0.5rem;
}

.gift-card img {
    width: 100%;
    border-radius: 8px;
    background: #fff;
}

/* RSVP */
.rsvp {
    background: var(--cream);
    color: var(--red);
    border-radius: 14px 22px 12px 24px / 22px 12px 24px 14px;
    padding: 1.5rem 1.25rem;
    text-align: left;
}

.rsvp label {
    font-weight: 700;
    margin-bottom: 0.2rem;
}

.rsvp .form-control,
.rsvp .form-select {
    background-color: #fff;
    color: var(--ink);
    font-family: inherit;
    font-size: 1.2rem;
    border: 3px solid var(--blue);
    border-radius: 14px 18px 12px 18px / 18px 12px 18px 14px;
}

.rsvp .form-control:focus,
.rsvp .form-select:focus {
    border-color: var(--red);
    box-shadow: none;
}

.rsvp .form-text {
    color: var(--red);
    opacity: 0.7;
    font-size: 1rem;
}

.comment-card {
    background: #fff;
    border: 3px solid var(--blue);
    border-radius: 12px 18px 10px 20px / 18px 10px 20px 12px;
    padding: 0.75rem 1rem;
    margin-bottom: 0.9rem;
}

.comment-card .comment-text {
    white-space: pre-wrap;
    word-break: break-word;
    margin: 0.3rem 0 0.5rem;
    color: var(--ink);
}

.comment-card strong {
    color: #000;
}

.comment-card small {
    color: var(--red);
    opacity: 0.7;
}

.like-btn {
    background: transparent;
    color: var(--red);
    border: 2px solid var(--blue);
    border-radius: 999px;
    padding: 0 0.7rem;
    font-family: inherit;
    font-size: 1rem;
    transition: transform 0.15s ease;
}

.like-btn:active {
    transform: scale(1.25);
}

.like-btn.liked {
    background: var(--red);
    color: var(--cream);
    border-color: var(--red);
}

.page-link {
    color: var(--red);
    background: var(--cream);
    border-color: var(--blue);
    font-family: inherit;
}

.page-item.active .page-link {
    background: var(--red);
    border-color: var(--red);
    color: var(--cream);
}

/* Thank you */
.thanks-top {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 1.25rem;
}

.envelope {
    width: 12rem;
    flex: none;
    mix-blend-mode: multiply;
}

.car {
    font-size: 5rem;
    color: var(--blue);
}

img[data-src] {
    opacity: 0;
    transition: opacity 0.6s ease;
}

img.loaded {
    opacity: 1;
}

/* Floating music button */
#button-music {
    position: fixed;
    right: max(1rem, calc(50% - 240px + 1rem));
    bottom: 1.25rem;
    z-index: 1030;
    width: 2.8rem;
    height: 2.8rem;
    border: 3px solid var(--blue);
    border-radius: 50%;
    background: var(--cream);
    color: var(--red);
}

.spin-button {
    animation: spin 3s linear infinite;
}

@keyframes spin {
    to {
        transform: rotate(360deg);
    }
}

/* Modal */
#show-modal-image {
    max-height: 85vh;
    object-fit: contain;
}