/* ============================================= */
/* == RESET & BASE STYLES                      */
/* ============================================= */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Poppins', sans-serif;
    background-color: #f9f7f7;
    color: #333;
    overflow-x: hidden;
}

p.quote {
    max-width: 720px;
    margin: auto;
    font-style: italic;
    font-size: .95rem;
    padding: 1rem;
}
p {
  margin-bottom: 10px;
}

/* ============================================= */
/* == ENVELOPE STYLES                          */
/* ============================================= */
.envelope-container {
    position: fixed;
    inset: 0;
    background: linear-gradient(135deg, #e0c3fc 0%, #8ec5fc 100%);
    display: flex;
    justify-content: center;
    align-items: center;
    z-index: 1000;
    transition: opacity 0.8s ease;
}

.envelope {
    width: 50vh;
    height: 50vh;
    position: relative;
    perspective: 1000px;
    transition: transform 0.8s ease;
    margin: 1rem;
}

.envelope-front,
.envelope-back {
    position: absolute;
    width: 100%;
    height: 100%;
    backface-visibility: hidden;
    display: flex;
    justify-content: center;
    align-items: center;
    flex-direction: column;
    padding: 20px;
    text-align: center;
    border-radius: 10px;
    box-shadow: 0 15px 35px rgba(0,0,0,0.1);
    transition: transform 0.8s ease;
}

.envelope-front {
    background-image: linear-gradient(to top, #a18cd1 0%, #fbc2eb 100%);
    z-index: 2;
}

.envelope-back {
    background: #f8f8f8;
    transform: rotateY(180deg);
    z-index: 1;
}

.envelope.open .envelope-front {
    transform: rotateY(180deg);
}

.envelope.open .envelope-back {
    transform: rotateY(0deg);
}

.envelope-flap {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 0;
    background: #f8f8f8;
    transform-origin: top;
    transform: rotateX(0deg);
    transition: transform 0.4s ease;
    z-index: 10;
    box-shadow: 0 -5px 10px rgba(0,0,0,0.05);
}

.envelope.open .envelope-flap {
    transform: rotateX(-180deg);
}

.envelope-content {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    display: flex;
    justify-content: center;
    align-items: center;
    flex-direction: column;
    padding: 20px;
    text-align: center;
    background: #fff;
    z-index: 1;
}

.envelope.open .envelope-content {
    opacity: 0;
}

.open-btn {
    margin-top: 20px;
    padding: 12px 30px;
    background: #e0c3fc;
    color: white;
    border: none;
    border-radius: 50px;
    font-size: 16px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    box-shadow: 0 5px 15px rgba(0,0,0,0.1);
}

.open-btn:hover {
    background: #d4a9fc;
    transform: translateY(-3px);
    box-shadow: 0 8px 20px rgba(0,0,0,0.15);
}

.recipient-name {
    font-size: 1.2rem;
    color: #4b5563;
    margin-bottom: 15px;
    font-weight: 600;
}

/* ============================================= */
/* == MAIN INVITATION STYLES                   */
/* ============================================= */
.invitation {
    max-width: 1200px;
    margin: 0 auto;
    padding: 40px 20px;
    display: none;
}

.invitation.show {
    display: block;
}

.header {
    text-align: center;
    margin-bottom: 40px;
}

.couple-name {
    font-family: 'Dancing Script', cursive;
    font-size: 2.5rem;
    color: #8b5cf6;
    margin-bottom: 10px;
}

.tagline {
    font-size: 1.2rem;
    color: #6b7280;
    margin-bottom: 30px;
}

/* Layout Styles */
.two-column {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 30px;
}

.one-column {
    display: grid;
    grid-template-columns: 1fr;
    gap: 30px;
}

.event-details {
    background: white;
    border-radius: 15px;
    box-shadow: 0 10px 25px rgba(0,0,0,0.05);
    text-align: center;
    transition: transform 0.3s ease;
    align-items: center;
    justify-content: center;
    display: flex;
    flex-direction: column;
}

.card {
    padding: 30px;
}

.event-details img {
    width: 100%;
    aspect-ratio: 1 / 1;
    border-radius: 15px;
}

.event-details:hover {
    transform: translateY(-5px);
}

.event-details i {
    font-size: 2.5rem;
    color: #8b5cf6;
    margin-bottom: 15px;
}

.detail-title {
    font-size: 1.2rem;
    font-weight: 600;
    color: #4b5563;
    margin-bottom: 10px;
}

.detail-content {
    font-size: 1.1rem;
    color: #1f2937;
}

.divider {
    height: 2px;
    background: linear-gradient(90deg, transparent, #8b5cf6, transparent);
    margin: 40px 0;
}

.section-title {
    text-align: center;
    font-size: 1.2rem;
    color: #8b5cf6;
    margin-bottom: 30px;
    font-weight: 600;
	letter-spacing: 2px;
 	text-transform: uppercase;
}

.rsvp-btn {
    display: inline-block;
    padding: 15px 40px;
    background: #8b5cf6;
    color: white;
    border-radius: 50px;
    text-decoration: none;
    font-weight: 600;
    margin-top: 1em;
    transition: all 0.3s ease;
    box-shadow: 0 5px 15px rgba(139, 92, 246, 0.3);
}

.rsvp-btn:hover {
    background: #7c3aed;
    transform: translateY(-3px);
    box-shadow: 0 8px 25px rgba(139, 92, 246, 0.4);
}

/* ============================================= */
/* == COUNTDOWN STYLES                         */
/* ============================================= */
#countdown {
    justify-content: center;
    margin: 30px auto;
    gap: 10px;
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(80px, 1fr));
    max-width: 500px;
    align-items: center;
    text-align: center;
}

.countdown-item {
    justify-content: center;
    align-items: center;
    display: grid;
    background: #fff;
    border-radius: 15px;
    box-shadow: 0 10px 25px rgba(0, 0, 0, 0.05);
    text-align: center;
	padding:20px 0;
    transition: transform 0.3s ease;
}

.countdown-item:hover {
    transform: scale(1.05);
}

.countdown-number {
    font-size: 2rem;
    font-weight: 700;
}

/* ============================================= */
/* == GALLERY STYLES                           */
/* ============================================= */
.gallery {
    margin-bottom: 50px;
}

.gallery-grid {
    border-radius: 10px;
    overflow: hidden;
    transition: transform 0.3s ease;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    display: grid;
    gap: 20px;
}

.gallery-item {
    display: block;
    overflow: hidden;
    border-radius: 8px;
    box-shadow: 0 4px 8px rgba(0,0,0,0.1);
    cursor: pointer;
    transition: transform 0.3s ease;
}

.gallery-item img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.5s ease;
}

.gallery-item:hover img {
    transform: scale(1.05);
}

section.sb-map-container {
    width: 100%;
    height: 300px;
    border-radius: 15px;
    overflow: hidden;
    margin: 50px 0;
    box-shadow: 0 10px 25px rgba(0, 0, 0, 0.1);
}

/* ============================================= */
/* == MODAL & LIGHTBOX STYLES                  */
/* ============================================= */
/* Base untuk Overlay */
.modal-overlay, .lightbox-overlay {
    position: fixed;
    top: 0; 
    left: 0;
    width: 100%; 
    height: 100%;
    background-color: rgba(0, 0, 0, 0.85);
    display: none;
    justify-content: center;
    align-items: center;
    z-index: 9998;
    padding: 15px;
}

/* Lightbox Galeri */
.lightbox-image {
    max-width: 90vw;
    max-height: 85vh;
    object-fit: contain;
    border-radius: 8px;
    animation: zoomIn 0.4s;
}

.lightbox-close, .lightbox-prev, .lightbox-next {
    position: absolute;
    color: white;
    font-size: 2.5em;
    cursor: pointer;
    user-select: none;
    transition: opacity 0.3s;
}

.lightbox-close { 
    top: 20px; 
    right: 30px; 
    font-weight: bold; 
}

.lightbox-prev, .lightbox-next { 
    top: 50%; 
    transform: translateY(-50%); 
    padding: 0 20px; 
}

.lightbox-prev { 
    left: 10px; 
}

.lightbox-next { 
    right: 10px; 
}

.lightbox-prev:hover, 
.lightbox-next:hover, 
.lightbox-close:hover { 
    opacity: 0.7; 
}

/* Modal Hadiah */
.modal-content {
    background-color: #ffffff;
    color: #333;
    padding: 25px 30px;
    border-radius: 12px;
    box-shadow: 0 5px 20px rgba(0,0,0,0.2);
    max-width: 500px;
    width: 100%;
    position: relative;
    text-align: left;
    max-height: 90vh;
    overflow-y: auto;
    animation: zoomIn 0.4s;
}

.modal-close {
    position: absolute;
    top: 10px; 
    right: 15px;
    font-size: 2.5em;
    font-weight: 300;
    color: #888;
    cursor: pointer;
    line-height: 1;
}

.modal-content h3 { 
    text-align: center; 
    margin-top: 0; 
    margin-bottom: 1rem; 
}

.modal-content p { 
    margin-bottom: 1.5rem; 
    line-height: 1.6; 
}

.rekening-info {
    background-color: #f8f9fa;
    border: 1px solid #dee2e6;
    border-radius: 8px;
    padding: 15px;
    margin-bottom: 1rem;
}

.rekening-info p { 
    margin: 0; 
}

.copy-btn {
    background-color: #d1ecf1;
    color: #0c5460;
    border: none;
    padding: 4px 8px;
    font-size: 0.8em;
    border-radius: 4px;
    cursor: pointer;
    margin-left: 10px;
    font-weight: bold;
}

.qris-gallery {
    display: flex;
    justify-content: center;
    gap: 20px;
    margin-top: 1.5rem;
    flex-wrap: wrap;
}

.qris-item { 
    text-align: center; 
}

.qris-item img { 
    max-width: 150px; 
    border: 1px solid #ddd; 
    padding: 5px; 
    border-radius: 8px; 
}

.qris-item span { 
    display: block; 
    margin-top: 8px; 
    font-weight: bold; 
}

.small-text { 
    font-size: 0.8em; 
    text-align: center; 
    color: #6c757d; 
    margin-top: 1rem; 
}

/* ============================================= */
/* == INTERACTIVE ELEMENTS & ANIMATIONS         */
/* ============================================= */
/* Music Button */
#music-button {
    position: fixed;
    bottom: 20px; 
    right: 20px;
    width: 50px; 
    height: 50px;
    background-color: rgba(43, 42, 76, 0.8);
    border-radius: 50%;
    cursor: pointer;
    z-index: 999;
    display: flex;
    justify-content: center;
    align-items: center;
    box-shadow: 0 4px 10px rgba(0,0,0,0.3);
    transition: transform 0.3s ease;
}

#music-button:hover { 
    transform: scale(1.1); 
}

#music-button::before {
    content: '';
    display: block;
    box-sizing: border-box;
}

#music-button.playing::before {
    width: 16px; 
    height: 16px;
    border-left: 5px solid #fff;
    border-right: 5px solid #fff;
}

#music-button:not(.playing)::before {
    width: 0; 
    height: 0;
    border-top: 10px solid transparent;
    border-bottom: 10px solid transparent;
    border-left: 16px solid #fff;
    margin-left: 5px;
}

/* Animations */
.fade-in.hidden {
    opacity: 0;
    transform: translateY(30px);
}

@keyframes zoomIn {
    from { 
        transform: scale(0.9); 
        opacity: 0; 
    }
    to { 
        transform: scale(1); 
        opacity: 1; 
    }
}

/* ============================================= */
/* == RSVP & GUEST BOOK STYLES                 */
/* ============================================= */
/* Container for 2 columns */
.sb-rsvp-container {
    display: flex;
    flex-wrap: wrap;
    gap: 2rem;
    margin: 2rem 0;
}

/* Individual columns */
.sb-rsvp-column {
    flex: 1;
    min-width: 300px;
}

/* RSVP Form */
.sb-rsvp-form {
    border-radius: 10px;
    padding: 2rem;
    height: 100%;
}

/* Guest List */
.sb-ucapan-list {
    background-color:#8b5cf6;
    border-radius: 10px;
    padding: 2rem;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.05);
    height: 600px;
    overflow-y: auto;
	color:#fff;
}

/* Scrollbar styling */
.sb-ucapan-list::-webkit-scrollbar {
    width: 8px;
}

.sb-ucapan-list::-webkit-scrollbar-track {
    background: #f1f1f1;
    border-radius: 10px;
}

.sb-ucapan-list::-webkit-scrollbar-thumb {
    background: #d4a5a5;
    border-radius: 10px;
}

.sb-ucapan-list::-webkit-scrollbar-thumb:hover {
    background: #c19696;
}

/* Form styling */
.sb-rsvp-form form div {
    margin-bottom: 1.5rem;
}

.sb-rsvp-form label {
    display: block;
    margin-bottom: 0.5rem;
    color: #4a4a4a;
    font-weight: 500;
}

.sb-rsvp-form input[type="text"],
.sb-rsvp-form input[type="number"],
.sb-rsvp-form select,
.sb-rsvp-form textarea {
    width: 100%;
    padding: 0.75rem;
    border: 1px solid #ddd;
    border-radius: 5px;
    font-size: 1rem;
    transition: border-color 0.3s;
}

.sb-rsvp-form button[type="submit"] {
    display: inline-block;
    padding: 15px 40px;
    background: #8b5cf6;
    color: white;
    border-radius: 6px;
    text-decoration: none;
    font-weight: 600;
    transition: all 0.3s ease;
    box-shadow: 0 5px 15px rgba(139, 92, 246, 0.3);
    border: 0;
	cursor: pointer;
}

.sb-rsvp-form button[type="submit"]:hover {
    background: #7c3aed;
    transform: translateY(-3px);
    box-shadow: 0 8px 25px rgba(139, 92, 246, 0.4);
}

/* Guest message item */
.sb-ucapan-item {
    border-bottom: 1px solid #eee;
    padding: 1.5rem 0;
}

.sb-ucapan-item:last-child {
    border-bottom: none;
}

.ucapan-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 0.75rem;
}

.nama {
    font-weight: 600;
    font-size: 1.1rem;
}

.status-kehadiran {
    padding: 0.25rem 0.75rem;
    border-radius: 20px;
    font-size: 0.85rem;
    font-weight: 500;
}

.status-hadir {
    background-color: #d4edda;
    color: #155724;
}

.status-tidak-hadir {
    background-color: #f8d7da;
    color: #721c24;
}

.status-ragu-ragu {
    background-color: #fff3cd;
    color: #856404;
}

.ucapan-isi {
    line-height: 1.6;
    margin-bottom: 0.75rem;
}

.tanggal {
    font-size: 0.85rem;
    color: #d4edda;
    display: block;
    text-align: right;
}

.alert-success {
    background-color: #d4edda;
    color: #155724;
    padding: 0.75rem 1.25rem;
    border-radius: 5px;
    margin-bottom: 1.5rem;
    border: 1px solid #c3e6cb;
}

/* ============================================= */
/* == FOOTER STYLES                            */
/* ============================================= */
.footer {
    text-align: center;
    padding: 20px;
    color: #6b7280;
    font-size: 0.9rem;
}

/* ============================================= */
/* == RESPONSIVE DESIGN                        */
/* ============================================= */
@media (max-width: 768px) {
    .couple-name {
        font-size: 2.5rem;
    }
    
    .two-column {
        grid-template-columns: 1fr;
    }
    
    .gallery {
        grid-template-columns: 1fr;
    }
    
    .sb-section.serenity-container {
        padding: 2rem 0.75rem;
    }
    
    .sb-rsvp-container {
        flex-direction: column;
    }
    
    .sb-rsvp-form,
    .sb-ucapan-list {
        padding: 1.5rem;
    }
    
    .sb-ucapan-list {
        height: auto;
        max-height: 500px;
    }
    
    .ucapan-header {
        flex-direction: column;
        align-items: flex-start;
    }
    
    .status-kehadiran {
        margin-top: 0.5rem;
    }
    
    .tanggal {
        text-align: left;
    }
    
    .modal-content {
        width: 95%;
    }
    
    .prev, .next {
        padding: 10px;
        font-size: 16px;
    }
}