/* Reset and Base Styles */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Inter', sans-serif;
    overflow-x: hidden;
    background: #0f172a;
    color: white;
}

.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
}

/* Preloader */
.preloader {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(135deg, #064e3b, #065f46, #047857);
    display: flex;
    justify-content: center;
    align-items: center;
    z-index: 9999;
    transition: opacity 0.5s ease;
}

.preloader-inner {
    text-align: center;
}

.preloader .dot {
    width: 20px;
    height: 20px;
    background: white;
    border-radius: 50%;
    display: inline-block;
    animation: pulse 1.5s infinite;
}

.preloader .dots {
    margin-top: 20px;
}

.preloader .dots span {
    width: 10px;
    height: 10px;
    background: rgba(255, 255, 255, 0.7);
    border-radius: 50%;
    display: inline-block;
    margin: 0 5px;
    animation: bounce 1.4s infinite ease-in-out both;
}

.preloader .dots span:nth-child(1) { animation-delay: -0.32s; }
.preloader .dots span:nth-child(2) { animation-delay: -0.16s; }

@keyframes pulse {
    0%, 100% { transform: scale(1); opacity: 1; }
    50% { transform: scale(1.2); opacity: 0.7; }
}

@keyframes bounce {
    0%, 80%, 100% { transform: scale(0); }
    40% { transform: scale(1); }
}

/* Main Page */
.main-page {
    min-height: 100vh;
    background: linear-gradient(135deg, #064e3b, #065f46, #047857, #059669);
    position: relative;
    overflow: hidden;
    display: flex;
    align-items: center;
    justify-content: center;
}

.main-container {
    position: relative;
    width: 100%;
    height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
}

/* Particles */
.particles {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    pointer-events: none;
}

.particles::before,
.particles::after {
    content: '';
    position: absolute;
    width: 4px;
    height: 4px;
    background: rgba(255, 255, 255, 0.6);
    border-radius: 50%;
    animation: float 6s infinite linear;
}

.particles::before {
    top: 20%;
    left: 10%;
    animation-delay: 0s;
}

.particles::after {
    top: 60%;
    right: 15%;
    animation-delay: 3s;
}

@keyframes float {
    0% { transform: translateY(0px) rotate(0deg); opacity: 1; }
    100% { transform: translateY(-100vh) rotate(360deg); opacity: 0; }
}

/* Decorative Elements */
.decorative-elements {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    pointer-events: none;
}

.deco-element {
    position: absolute;
    background: rgba(255, 255, 255, 0.1);
    border-radius: 50%;
    animation: pulse 4s infinite;
}

.deco-1 {
    width: 80px;
    height: 80px;
    top: 10%;
    left: 10%;
    animation-delay: 0s;
}

.deco-2 {
    width: 60px;
    height: 60px;
    top: 20%;
    right: 15%;
    animation-delay: 1s;
}

.deco-3 {
    width: 100px;
    height: 100px;
    bottom: 20%;
    left: 15%;
    animation-delay: 2s;
}

.deco-4 {
    width: 40px;
    height: 40px;
    bottom: 30%;
    right: 20%;
    animation-delay: 3s;
}

.deco-5 {
    width: 70px;
    height: 70px;
    top: 50%;
    left: 5%;
    animation-delay: 4s;
}

/* Main Content */
.main-content {
    text-align: center;
    z-index: 10;
    max-width: 500px;
    padding: 20px;
}

.event-type {
    font-size: 14px;
    letter-spacing: 3px;
    margin-bottom: 40px;
    opacity: 0.9;
    font-weight: 300;
}

.couple-names {
    margin-bottom: 40px;
}

.couple-names h2 {
    font-family: 'Playfair Display', serif;
    font-size: 3.5rem;
    font-weight: 400;
    margin: 10px 0;
    text-shadow: 2px 2px 4px rgba(0, 0, 0, 0.3);
}

.ampersand {
    font-size: 2rem;
    opacity: 0.8;
    margin: 20px 0;
}

.wedding-date {
    margin-bottom: 50px;
}

.day h4 {
    font-size: 1.2rem;
    font-weight: 400;
    margin-bottom: 15px;
    letter-spacing: 2px;
}

.date-numbers h2 {
    font-size: 2.5rem;
    font-weight: 700;
    margin-bottom: 10px;
}

.date-numbers span:nth-child(2),
.date-numbers span:nth-child(4) {
    font-size: 1.5rem;
    opacity: 0.7;
}

.hijri-date h6 {
    font-size: 0.9rem;
    opacity: 0.8;
    font-weight: 300;
}

.btn-open {
    background: rgba(255, 255, 255, 0.2);
    border: 2px solid rgba(255, 255, 255, 0.3);
    color: white;
    padding: 15px 40px;
    border-radius: 50px;
    font-size: 1rem;
    font-weight: 500;
    letter-spacing: 1px;
    cursor: pointer;
    transition: all 0.3s ease;
    backdrop-filter: blur(10px);
}

.btn-open:hover {
    background: rgba(255, 255, 255, 0.3);
    border-color: rgba(255, 255, 255, 0.5);
    transform: translateY(-2px);
    box-shadow: 0 10px 25px rgba(0, 0, 0, 0.2);
}

.btn-open i {
    margin: 0 10px;
}

/* Sub Page */
.sub-page {
    min-height: 100vh;
    background: linear-gradient(135deg, #064e3b, #065f46, #047857);
    position: relative;
    padding: 20px 0 100px;
}

.sub-particles {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    pointer-events: none;
    opacity: 0.3;
}

.sub-decorative {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    pointer-events: none;
}

.sub-deco {
    position: absolute;
    background: rgba(255, 255, 255, 0.05);
    border-radius: 50%;
    animation: pulse 6s infinite;
}

.sub-deco-1 {
    width: 120px;
    height: 120px;
    top: 10%;
    left: 5%;
}

.sub-deco-2 {
    width: 80px;
    height: 80px;
    top: 30%;
    right: 10%;
    animation-delay: 2s;
}

.sub-deco-3 {
    width: 100px;
    height: 100px;
    bottom: 20%;
    left: 10%;
    animation-delay: 4s;
}

.sub-deco-4 {
    width: 60px;
    height: 60px;
    bottom: 40%;
    right: 5%;
    animation-delay: 6s;
}

/* Content Sections */
.greeting-section {
    text-align: center;
    margin-bottom: 40px;
    position: relative;
    z-index: 10;
}

.greeting {
    font-size: 1.1rem;
    margin-bottom: 30px;
    opacity: 0.9;
}

.parents-name {
    font-size: 1.2rem;
    font-weight: 300;
    margin: 15px 0;
    line-height: 1.4;
}

.invitation-text {
    font-size: 1rem;
    line-height: 1.6;
    margin: 30px 0;
    opacity: 0.9;
    max-width: 800px;
    margin-left: auto;
    margin-right: auto;
}

.bride-name {
    font-family: 'Playfair Display', serif;
    font-size: 1.8rem;
    font-weight: 400;
    margin: 20px 0;
}

.divider {
    border: none;
    height: 1px;
    background: rgba(255, 255, 255, 0.3);
    margin: 50px 0;
    max-width: 600px;
    margin-left: auto;
    margin-right: auto;
}

/* Event Details */
.event-details {
    margin-bottom: 60px;
    position: relative;
    z-index: 10;
}

.detail-item {
    margin-bottom: 30px;
    text-align: center;
}

.detail-item label {
    display: block;
    font-size: 0.9rem;
    font-weight: 600;
    letter-spacing: 1px;
    margin-bottom: 10px;
    opacity: 0.8;
}

.detail-item p {
    font-size: 1.1rem;
    line-height: 1.5;
}

.program-table {
    width: 100%;
    max-width: 400px;
    margin: 0 auto;
    border-collapse: collapse;
}

.program-table td {
    padding: 10px 20px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.2);
}

.program-table td:first-child {
    text-align: left;
    font-weight: 500;
}

.program-table td:last-child {
    text-align: right;
}

/* Countdown */
.countdown-section {
    text-align: center;
    margin-bottom: 60px;
    position: relative;
    z-index: 10;
}

.countdown-section h4 {
    font-size: 1.5rem;
    margin-bottom: 30px;
    letter-spacing: 2px;
}

.countdown-display {
    display: flex;
    justify-content: center;
    gap: 20px;
    flex-wrap: wrap;
}

.countdown-item {
    background: rgba(255, 255, 255, 0.1);
    backdrop-filter: blur(10px);
    border-radius: 15px;
    padding: 20px;
    min-width: 80px;
    text-align: center;
}

.countdown-number {
    display: block;
    font-size: 2rem;
    font-weight: 700;
    margin-bottom: 5px;
}

.countdown-label {
    font-size: 0.8rem;
    opacity: 0.8;
    letter-spacing: 1px;
}

/* Gallery */
.gallery-section {
    margin-bottom: 60px;
    text-align: center;
    position: relative;
    z-index: 10;
}

.gallery-section h4 {
    font-size: 1.5rem;
    margin-bottom: 30px;
    letter-spacing: 2px;
}

.gallery-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 15px;
    max-width: 800px;
    margin: 0 auto;
}

.gallery-item {
    aspect-ratio: 1;
    border-radius: 15px;
    overflow: hidden;
    cursor: pointer;
    transition: transform 0.3s ease;
}

.gallery-item:hover {
    transform: scale(1.05);
}

.gallery-item img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

/* Guestbook */
.guestbook-section {
    margin-bottom: 60px;
    text-align: center;
    position: relative;
    z-index: 10;
}

.guestbook-section h4 {
    font-size: 1.5rem;
    margin-bottom: 30px;
    letter-spacing: 2px;
}

.guestbook-messages {
    margin-bottom: 30px;
    max-width: 600px;
    margin-left: auto;
    margin-right: auto;
}

.message-item {
    background: rgba(255, 255, 255, 0.1);
    backdrop-filter: blur(10px);
    border-radius: 15px;
    padding: 20px;
    margin-bottom: 15px;
    text-align: left;
}

.message-text {
    font-style: italic;
    margin-bottom: 10px;
    line-height: 1.5;
}

.message-author {
    text-align: right;
    font-weight: 500;
    opacity: 0.8;
}

.guestbook-form {
    max-width: 400px;
    margin: 0 auto;
}

.guestbook-form textarea,
.guestbook-form input {
    width: 100%;
    padding: 15px;
    margin-bottom: 15px;
    border: 1px solid rgba(255, 255, 255, 0.3);
    border-radius: 10px;
    background: rgba(255, 255, 255, 0.1);
    color: white;
    font-family: inherit;
    backdrop-filter: blur(10px);
}

.guestbook-form textarea::placeholder,
.guestbook-form input::placeholder {
    color: rgba(255, 255, 255, 0.7);
}

.guestbook-form textarea:focus,
.guestbook-form input:focus {
    outline: none;
    border-color: rgba(255, 255, 255, 0.5);
}

.btn-submit {
    width: 100%;
    padding: 15px;
    background: rgba(255, 255, 255, 0.2);
    border: 1px solid rgba(255, 255, 255, 0.3);
    border-radius: 10px;
    color: white;
    font-size: 1rem;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.3s ease;
    backdrop-filter: blur(10px);
}

.btn-submit:hover {
    background: rgba(255, 255, 255, 0.3);
    transform: translateY(-2px);
}

/* Prayer Section */
.prayer-section {
    margin-bottom: 60px;
    text-align: center;
    position: relative;
    z-index: 10;
}

.prayer-card {
    background: rgba(255, 255, 255, 0.1);
    backdrop-filter: blur(10px);
    border-radius: 20px;
    padding: 40px 30px;
    max-width: 600px;
    margin: 0 auto;
    border: 1px solid rgba(255, 255, 255, 0.2);
}

.prayer-card p {
    font-style: italic;
    line-height: 1.8;
    font-size: 1rem;
}

/* Footer */
.footer-section {
    text-align: center;
    padding: 40px 0;
    border-top: 1px solid rgba(255, 255, 255, 0.2);
    position: relative;
    z-index: 10;
}

.footer-logo {
    font-size: 1.5rem;
    font-weight: 600;
    margin: 15px 0;
}

.social-media a {
    color: white;
    font-size: 1.5rem;
    margin: 0 10px;
    transition: color 0.3s ease;
}

.social-media a:hover {
    color: #10b981;
}

/* App Bar */
.appbar {
    position: fixed;
    bottom: 0;
    left: 0;
    right: 0;
    z-index: 1000;
    background: rgba(0, 0, 0, 0.9);
    backdrop-filter: blur(10px);
    border-top: 1px solid rgba(255, 255, 255, 0.1);
}

.appbar-nav ul {
    display: flex;
    justify-content: space-around;
    list-style: none;
    padding: 15px 0;
    margin: 0;
}

.appbar-nav li {
    text-align: center;
    cursor: pointer;
    padding: 10px;
    border-radius: 10px;
    transition: background 0.3s ease;
    min-width: 60px;
}

.appbar-nav li:hover {
    background: rgba(255, 255, 255, 0.1);
}

.appbar-nav i {
    display: block;
    font-size: 1.2rem;
    margin-bottom: 5px;
}

.appbar-nav span {
    font-size: 0.7rem;
    display: block;
}

/* Modals */
.modal-backdrop {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.7);
    z-index: 1500;
    backdrop-filter: blur(5px);
}

.modal {
    position: fixed;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    z-index: 1600;
    width: 90%;
    max-width: 500px;
    max-height: 80vh;
    overflow-y: auto;
}

.modal-content {
    background: rgba(6, 78, 59, 0.95);
    backdrop-filter: blur(20px);
    border-radius: 20px;
    border: 1px solid rgba(255, 255, 255, 0.2);
}

.modal-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 20px 25px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.2);
}

.modal-header h5 {
    font-size: 1.2rem;
    font-weight: 600;
    letter-spacing: 1px;
}

.btn-close {
    background: none;
    border: none;
    color: white;
    font-size: 1.5rem;
    cursor: pointer;
    padding: 5px;
    border-radius: 5px;
    transition: background 0.3s ease;
}

.btn-close:hover {
    background: rgba(255, 255, 255, 0.1);
}

.modal-body {
    padding: 25px;
}

/* Contact Modal */
.contact-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 15px 0;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}

.contact-item:last-child {
    border-bottom: none;
}

.contact-item label {
    display: flex;
    align-items: center;
    font-weight: 500;
}

.contact-item i {
    margin-right: 10px;
}

.contact-actions a {
    color: white;
    font-size: 1.2rem;
    margin-left: 15px;
    padding: 8px;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.1);
    transition: all 0.3s ease;
}

.contact-actions a:hover {
    background: rgba(255, 255, 255, 0.2);
    transform: scale(1.1);
}

/* Location Modal */
.map-container {
    margin-bottom: 20px;
    border-radius: 15px;
    overflow: hidden;
}

.map-buttons {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 10px;
}

.btn-map {
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 12px;
    background: rgba(255, 255, 255, 0.1);
    border: 1px solid rgba(255, 255, 255, 0.2);
    border-radius: 10px;
    color: white;
    text-decoration: none;
    font-weight: 500;
    transition: all 0.3s ease;
}

.btn-map:hover {
    background: rgba(255, 255, 255, 0.2);
    transform: translateY(-2px);
}

.btn-map i {
    margin-right: 8px;
}

/* Calendar Modal */
.calendar-buttons {
    display: grid;
    gap: 15px;
}

.btn-calendar {
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 15px;
    background: rgba(255, 255, 255, 0.1);
    border: 1px solid rgba(255, 255, 255, 0.2);
    border-radius: 10px;
    color: white;
    text-decoration: none;
    font-weight: 500;
    transition: all 0.3s ease;
}

.btn-calendar:hover {
    background: rgba(255, 255, 255, 0.2);
    transform: translateY(-2px);
}

.btn-calendar i {
    margin-right: 10px;
}

/* RSVP Modal */
.rsvp-form input {
    width: 100%;
    padding: 15px;
    margin-bottom: 15px;
    border: 1px solid rgba(255, 255, 255, 0.3);
    border-radius: 10px;
    background: rgba(255, 255, 255, 0.1);
    color: white;
    font-family: inherit;
    backdrop-filter: blur(10px);
}

.rsvp-form input::placeholder {
    color: rgba(255, 255, 255, 0.7);
}

.rsvp-form input:focus {
    outline: none;
    border-color: rgba(255, 255, 255, 0.5);
}

.counter-row {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 20px;
    margin-bottom: 20px;
}

.counter-group {
    text-align: center;
}

.counter-group label {
    display: block;
    font-size: 0.9rem;
    margin-bottom: 10px;
    opacity: 0.9;
}

.counter {
    display: flex;
    align-items: center;
    justify-content: center;
    background: rgba(255, 255, 255, 0.1);
    border-radius: 10px;
    overflow: hidden;
}

.counter button {
    background: rgba(255, 255, 255, 0.1);
    border: none;
    color: white;
    padding: 12px 15px;
    cursor: pointer;
    transition: background 0.3s ease;
}

.counter button:hover {
    background: rgba(255, 255, 255, 0.2);
}

.counter input {
    background: transparent;
    border: none;
    color: white;
    text-align: center;
    width: 60px;
    padding: 12px 5px;
    margin: 0;
}

/* Music Player */
.music-player {
    position: fixed;
    bottom: 100px;
    right: 20px;
    z-index: 1000;
}

#music-toggle {
    width: 50px;
    height: 50px;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.2);
    border: 1px solid rgba(255, 255, 255, 0.3);
    color: white;
    cursor: pointer;
    transition: all 0.3s ease;
    backdrop-filter: blur(10px);
}

#music-toggle:hover {
    background: rgba(255, 255, 255, 0.3);
    transform: scale(1.1);
}

/* Animations */
@keyframes fadeIn {
    from { opacity: 0; transform: translateY(30px); }
    to { opacity: 1; transform: translateY(0); }
}

@keyframes slideUp {
    from { opacity: 0; transform: translateY(50px); }
    to { opacity: 1; transform: translateY(0); }
}

@keyframes zoomIn {
    from { opacity: 0; transform: scale(0.8); }
    to { opacity: 1; transform: scale(1); }
}

.animate-fade-in {
    animation: fadeIn 1s ease forwards;
}

.animate-slide-up {
    animation: slideUp 1s ease forwards;
}

.animate-zoom-in {
    animation: zoomIn 1s ease forwards;
}

.delay-500 { animation-delay: 0.5s; }
.delay-1000 { animation-delay: 1s; }
.delay-1500 { animation-delay: 1.5s; }
.delay-2000 { animation-delay: 2s; }

/* Responsive Design */
@media (max-width: 768px) {
    .couple-names h2 {
        font-size: 2.5rem;
    }
    
    .date-numbers h2 {
        font-size: 2rem;
    }
    
    .countdown-display {
        gap: 10px;
    }
    
    .countdown-item {
        padding: 15px;
        min-width: 70px;
    }
    
    .countdown-number {
        font-size: 1.5rem;
    }
    
    .gallery-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 10px;
    }
    
    .modal {
        width: 95%;
    }
    
    .counter-row {
        grid-template-columns: 1fr;
        gap: 15px;
    }
    
    .map-buttons {
        grid-template-columns: 1fr;
    }
}

@media (max-width: 480px) {
    .couple-names h2 {
        font-size: 2rem;
    }
    
    .main-content {
        padding: 15px;
    }
    
    .btn-open {
        padding: 12px 30px;
        font-size: 0.9rem;
    }
    
    .prayer-card {
        padding: 30px 20px;
    }
    
    .appbar-nav span {
        font-size: 0.6rem;
    }
}