@import url('https://fonts.googleapis.com/css2?family=Great+Vibes&family=Montserrat:wght@300;400;500;600&family=Amiri&display=swap');
@import url('https://fonts.googleapis.com/css2?family=Akaya+Kanadaka&family=Gabarito:wght@400..900&family=Montserrat:ital,wght@0,100..900;1,100..900&family=Tangerine:wght@400;700&display=swap');

:root {
    --primary-color: #1d4c4f;
    --secondary-color: #88b585;
    --text-color: #2c3e50;
    --timeline-line-color: #8B0000;
}

body {
    font-family: 'Montserrat', sans-serif;
    color: var(--text-color);
    overflow-y: hidden;
}

body.opened {
    overflow-y: auto;
}

@media (min-width: 1024px) {
    .main-wrap {
        width: 35%;
        margin-inline: auto;
    }

    .section .mempelai-name {
        font-size: 1.6em;
    }

    .simply-countdown>.simply-section {
        width: 20px !important;
        height: 20px !important;
        padding: 35px !important;
        display: flex !important;
        align-items: center !important;
        justify-content: center !important;
        float: left !important;
        margin: -7px !important;
        font-size: 17px !important;
        box-shadow: none !important;
        border-radius: 0 !important;
    }

    .map-container iframe {
        width: 350px !important;
        height: 250px !important;
    }

    .bottom-nav {
        width: 35% !important;
        margin-inline: auto !important;
    }
}

.main-content {
    visibility: visible !important;
    opacity: 1 !important;
}


.cover-page h1 {
    font-family: 'Tangerine', cursive;
    color: white;
    font-size: 3em;
}

.cover-page.opened {
    transform: translateY(-100%);
}

.guest .guest-name {
    font-family: 'Gabarito', cursive;
    font-size: 1.4em;
}

.music-icon i {
    color: white;
    font-size: 1.5rem;
}

@keyframes rotateInfinite {
    from {
        transform: rotate(0deg);
    }

    to {
        transform: rotate(360deg);
    }

}

.section {
    background-size: cover;
    background-position: center;
    background-repeat: no-repeat;
}


.flower-corner {
    position: absolute;
    width: 120px;
    height: 120px;
    animation: none;
}

/* Define the swaying animation */
@keyframes sway {
    0% {
        transform: rotate(0deg) translate(0px, 0px);
    }

    12% {
        transform: rotate(3deg) translate(3px, -3px);
    }

    25% {
        transform: rotate(6deg) translate(6px, -6px);
    }

    38% {
        transform: rotate(3deg) translate(-3px, 3px);
    }

    50% {
        transform: rotate(0deg) translate(0px, 0px);
    }

    62% {
        transform: rotate(-3deg) translate(3px, -3px);
    }

    75% {
        transform: rotate(-6deg) translate(-6px, 6px);
    }

    88% {
        transform: rotate(-3deg) translate(-3px, 3px);
    }

    100% {
        transform: rotate(0deg) translate(0px, 0px);
    }
}

/* Add different animation delays to create natural movement */
.flower-corner:nth-child(2n) {
    animation-delay: 0.5s;
}

.flower-corner:nth-child(3n) {
    animation-delay: 1s;
}

/* Optional: Add subtle scaling for more organic movement */
@keyframes scaleWave {
    0%, 100% {
        transform: scale(1) rotate(0deg);
    }

    50% {
        transform: scale(1.02) rotate(2deg);
    }
}


.top-left {
    top: 0;
    left: 0;
}

.top-right {
    top: 0;
    right: 0;
}

.bottom-left {
    bottom: 0;
    left: 0;
}

.bottom-right {
    bottom: 0;
    right: 0;
}


.couple-frame h2 {
    font-family: 'Tangerine', cursive;
    font-size: 2em;
    margin: 0;
}

.couple-frame p {
    font-family: 'Montserrat', sans-serif;
    margin: 0;
}


.bismillah {
    max-width: 140px;
    margin: 0 auto 30px;
}

.con {
    position: relative;
    text-align: center;
}

.photo-container {
    position: relative;
    display: inline-block;
    width: 140px;
    height: 140px;
}

.bg-frame {
    position: absolute;
    top: 50%;
    left: 50%;
    width: 170px;
    height: auto;
    transform: translate(-50%, calc(-50% + 20px));
    z-index: 0;
    animation: bridge-frame 4s ease-in-out infinite alternate;
}

/* Safari and Chrome iOS fix */
@media screen and (device-width: 375px) and (device-height: 667px) and (-webkit-device-pixel-ratio: 2) {
    .bg-frame {
        transform: translate(-50%, calc(-50% + 45px));
    }
}

@keyframes cover-frame {
    0% {
        transform: rotate(-10deg);
    }

    100% {
        transform: rotate(10deg);
    }
}

@keyframes bridge-frame {
    0% {
        transform: translate(-50%, -50%) rotate(-6deg);
    }

    100% {
        transform: translate(-50%, -50%) rotate(6deg);
    }
}

.gallery-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 10px;
}

.gallery-item {
    aspect-ratio: 1 / 1;
    overflow: hidden;
}

.gallery-item.large {
    grid-column: span 2;
    grid-row: span 2;
}

.gallery-item img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}



.frame-acara {
    position: absolute;
    top: 41%;
    left: 50%;
    width: 90%;
    height: auto;
    transform: translate(-50%, -50%);
    z-index: -1;
}

.arabic {
    font-family: 'Amiri', serif;
    font-size: 1.5rem;
    margin: 20px 0;
}

.element-acara-1 {
    width: 10em !important;
    height: auto;
    padding: 20px;
    display: none;
}

.countdown {
    /* background: var(--primary-color); */
    color: white;
    padding: 30px;
    border-radius: 12px;
    text-align: center;
    /* box-shadow: 0px 4px 10px rgba(0, 0, 0, 0.2); */
    width: 100%;
    margin: auto;
}

/* Agar countdown sejajar secara horizontal */
.countdown-wrapper {
    display: flex;
    justify-content: center;
    gap: 20px;
    flex-wrap: wrap;
}

/* Styling Simply Countdown */
.simply-countdown {
    display: flex;
    gap: 15px;
}


.simply-countdown>.simply-section {
    background: rgba(255, 255, 255, 0.2);
    padding: 15px;
    box-shadow: none !important;
    border-radius: 0 !important;
    text-align: center;
    font-size: 1.5rem;
    font-weight: bold;
    min-width: 90px;
}

/* Responsif: Layar kecil */
@media (max-width: 768px) {
    .simply-countdown>.simply-section {
        width: 20px !important;
        height: 20px !important;
        padding: 35px !important;
        display: flex !important;
        align-items: center !important;
        justify-content: center !important;
        float: left !important;
        margin: -7px !important;
        font-size: 17px !important;
        box-shadow: none !important;
        border-radius: 0 !important;
    }

    .map-container iframe {
        width: 350px !important;
        height: 250px !important;
    }

    .flower-corner {
        position: absolute;
        width: 120px;
        height: 120px;
        animation: none;
    }

    .section-title {
        font-size: 1.7rem !important;
    }
}


.live-stream img {
    width: 4em;
    height: auto;
}

.timeline {
    position: relative;
    max-width: 800px;
    margin: 0 auto;
    padding: 40px 0;
}

.timeline-item {
    position: relative;
    margin-bottom: 80px;
    width: 100%;
}

.timeline-content {
    position: relative;
    width: calc(50% - 30px);
    padding: 20px;
    background: white;
    border-radius: 10px;
    box-shadow: 0 3px 10px rgba(0, 0, 0, 0.1);
}

.timeline-item:nth-child(odd) .timeline-content {
    margin-left: 0;
    margin-right: auto;
}

.timeline-item:nth-child(even) .timeline-content {
    margin-left: auto;
    margin-right: 0;
    text-align: end;
}



.timeline-text {
    color: #666;
    line-height: 1.6;
    margin: 0;
}

@media (max-width: 768px) {

    .timeline::after {
        left: 31px !important;
    }

    .timeline-date {
        left: 70px !important;
        transform: translateX(-50%) !important;
        margin-bottom: 10px;
        margin-top: -30px;
        z-index: 2 !important;
    }

    .timeline-content {
        width: calc(100% - 60px);
        margin-left: 60px !important;
    }

    .element-acara-1 {
        display: block;
    }

}

.comments-section {
    max-height: 400px;
    overflow-y: auto;
}

.comment-item {
    background: #f8f9fa;
    padding: 15px;
    border-radius: 10px;
    margin-bottom: 10px;
}


#fullscreenViewer {
    display: none;
    /* Pastikan tidak tampil sebelum diklik */
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.8);
    justify-content: center;
    align-items: center;
    z-index: 1000;
}

#fullscreenImage {
    max-width: 90%;
    max-height: 90%;
    border-radius: 10px;
}

#closeViewer {
    position: absolute;
    top: 20px;
    right: 30px;
    font-size: 40px;
    color: white;
    cursor: pointer;
}

.comment-container {
    max-width: 900px;
    max-height: 400px;
    overflow-y: auto;
}

.divider {
    height: 2px;
    width: 80px;
    background: linear-gradient(to right, transparent, #6c757d, transparent);
}

.update-indicator {
    height: 20px;
    opacity: 0;
    transition: opacity 0.3s ease;
}

.update-indicator.active {
    opacity: 1;
}

.comment-list {
    display: flex;
    flex-direction: column;
    gap: 1.5rem;
}

.comment-item {
    background-color: #fff;
    border-radius: 10px;
    box-shadow: 0 3px 10px rgba(0, 0, 0, 0.08);
    padding: 1.5rem;
    transition: transform 0.2s ease, opacity 0.5s ease;
    border-left: 4px solid #ced4da;
}

.comment-item:hover {
    transform: translateY(-3px);
}

.comment-item.new {
    animation: highlightNew 2s ease;
}

@keyframes highlightNew {
    0% {
        background-color: rgba(255, 248, 220, 0.8);
    }

    100% {
        background-color: #fff;
    }
}

.comment-item.hadir {
    border-left-color: #28a745;
}

.comment-item.tidak-hadir {
    border-left-color: #dc3545;
}

.comment-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 0.75rem;
}

.comment-name {
    font-weight: 600;
    margin: 0;
    color: #333;
    font-size: 1.1rem;
}

.comment-body {
    color: #555;
    line-height: 1.6;
    margin-bottom: 1rem;
    word-wrap: break-word;
}

.comment-footer {
    display: flex;
    justify-content: space-between;
    align-items: center;
    font-size: 0.85rem;
    color: #6c757d;
}

.badge-presence {
    font-size: 0.75rem;
    padding: 0.25rem 0.75rem;
    border-radius: 20px;
    font-weight: 500;
}

.badge-hadir {
    background-color: rgba(40, 167, 69, 0.15);
    color: #28a745;
}

.badge-tidak-hadir {
    background-color: rgba(220, 53, 69, 0.15);
    color: #dc3545;
}

.comment-time {
    font-style: italic;
}

/* Responsive adjustments */
@media (max-width: 768px) {
    .comment-item {
        padding: 1.25rem;
    }

    .comment-header {
        flex-direction: column;
        align-items: flex-start;
    }

    .comment-footer {
        flex-direction: column;
        align-items: flex-start;
        gap: 0.5rem;
    }
}