/* Reset and base styles */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Georgia', 'Times New Roman', serif;
    line-height: 1.6;
    color: #333;
    background-color: #faf8f5;
}

/* Header and Navigation */
header {
    background-color: #fff;
    box-shadow: 0 2px 10px rgba(0,0,0,0.1);
    position: sticky;
    top: 0;
    z-index: 100;
}

nav ul {
    display: flex;
    justify-content: center;
    list-style: none;
    padding: 1rem 0;
    max-width: 1200px;
    margin: 0 auto;
}

nav li {
    margin: 0 2rem;
}

nav a {
    text-decoration: none;
    color: #333;
    font-weight: 500;
    padding: 0.5rem 1rem;
    border-radius: 5px;
    transition: all 0.3s ease;
}

nav a:hover {
    background-color: #396803;
    color: #fff;
}

nav a.active {
    background-color: #478104;
    color: #fff;
}

/* Main content */
main {
    min-height: calc(100vh - 120px);
    padding: 2rem 0;
}

/* Hero section */
.hero {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 2rem;
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 3rem;
    align-items: center;
}

.hero-image {
    text-align: center;
}

.hero-image img {
    max-width: 100%;
    height: auto;
    border-radius: 15px;
    box-shadow: 0 10px 30px rgba(0,0,0,0.2);
}

.hero-content {
    padding: 2rem 0;
}

.hero-content h1 {
    font-family: 'Dancing Script', cursive;
    font-size: 4rem;
    font-weight: 700;
    color: #478104;
    margin-bottom: 1rem;
    text-align: center;
}

.couple-names {
    font-family: 'Playfair Display', serif;
    font-size: 1.8rem;
    text-align: center;
    margin-bottom: 2rem;
    color: #666;
    font-style: italic;
}

.wedding-details {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 2rem;
    margin: 2rem 0;
}

.detail-item {
    text-align: center;
    padding: 1.5rem;
    background-color: #fff;
    border-radius: 10px;
    box-shadow: 0 5px 15px rgba(0,0,0,0.1);
}

.detail-item h3 {
    font-family: 'Playfair Display', serif;
    color: #478104;
    margin-bottom: 0.5rem;
    font-size: 1.2rem;
    font-weight: 600;
}

.detail-item p {
    margin-bottom: 0.25rem;
}

.invitation-text {
    text-align: center;
    font-size: 1.1rem;
    line-height: 1.8;
    color: #555;
    margin-top: 2rem;
}

/* Page header */
.page-header {
    text-align: center;
    margin-bottom: 3rem;
    max-width: 1200px;
    margin-left: auto;
    margin-right: auto;
    padding: 0 2rem;
}

.page-header h1 {
    font-family: 'Dancing Script', cursive;
    font-size: 3.5rem;
    font-weight: 700;
    color: #478104;
    margin-bottom: 0.5rem;
}

.page-header p {
    font-size: 1.1rem;
    color: #666;
}

/* Location info */
.location-info {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 2rem;
}

.venue-details,
.map-container,
.wedding-timeline,
.practical-info {
    margin-bottom: 3rem;
}

.venue-details h2,
.map-container h2,
.wedding-timeline h2,
.practical-info h2 {
    font-family: 'Dancing Script', cursive;
    font-size: 2.5rem;
    font-weight: 600;
    color: #478104;
    margin-bottom: 1.5rem;
    text-align: center;
}

.venue-card {
    background-color: #fff;
    padding: 2rem;
    border-radius: 10px;
    box-shadow: 0 5px 15px rgba(0,0,0,0.1);
    text-align: center;
    max-width: 400px;
    margin: 0 auto;
}

.venue-card h3 {
    font-family: 'Playfair Display', serif;
    color: #478104;
    margin-bottom: 1rem;
    font-size: 1.3rem;
    font-weight: 600;
}

.map-container iframe {
    border-radius: 10px;
    box-shadow: 0 5px 15px rgba(0,0,0,0.1);
}

/* Timeline */
.timeline {
    background-color: #fff;
    border-radius: 10px;
    padding: 2rem;
    box-shadow: 0 5px 15px rgba(0,0,0,0.1);
}

.timeline-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 1rem 0;
    border-bottom: 1px solid #eee;
}

.timeline-item:last-child {
    border-bottom: none;
}

.timeline-item .time {
    font-weight: bold;
    color: #478104;
    min-width: 100px;
}

.timeline-item .event {
    flex: 1;
    margin-left: 2rem;
}

/* Info grid */
.info-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 2rem;
}

.info-item {
    background-color: #fff;
    padding: 1.5rem;
    border-radius: 10px;
    box-shadow: 0 5px 15px rgba(0,0,0,0.1);
}

.info-item h3 {
    font-family: 'Playfair Display', serif;
    color: #478104;
    margin-bottom: 0.5rem;
    font-weight: 600;
}

/* Color Palette */
.color-palette-section {
    background-color: #fff;
    padding: 2rem;
    border-radius: 10px;
    box-shadow: 0 5px 15px rgba(0,0,0,0.1);
    text-align: center;
    margin-top: 2rem;
}

.color-palette-section h3 {
    font-family: 'Playfair Display', serif;
    color: #478104;
    margin-bottom: 1rem;
    font-size: 1.4rem;
    font-weight: 600;
}

.color-palette-section p {
    font-style: italic;
    color: #666;
    margin-bottom: 2rem;
    font-size: 1.1rem;
    line-height: 1.6;
}

.color-palette {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 1rem;
    flex-wrap: wrap;
    margin: 0 auto;
}

.color-item {
    width: 80px;
    height: 80px;
    border-radius: 50%;
    border: 3px solid #fff;
    box-shadow: 0 3px 10px rgba(0,0,0,0.2);
    cursor: pointer;
    transition: transform 0.3s ease;
    position: relative;
    flex-shrink: 0;
}

.color-item:hover {
    transform: scale(1.1);
}

.color-item::after {
    content: attr(data-color) " • " attr(data-name);
    position: absolute;
    top: 90px;
    left: 50%;
    transform: translateX(-50%);
    background-color: rgba(0,0,0,0.9);
    color: #fff;
    padding: 0.5rem 0.75rem;
    border-radius: 6px;
    font-size: 0.85rem;
    opacity: 0;
    transition: opacity 0.3s ease;
    white-space: nowrap;
    pointer-events: none;
    z-index: 10;
}

.color-item:hover::after {
    opacity: 1;
}

/* Photo Gallery */
.photo-gallery {
    margin-bottom: 3rem;
}

.photo-gallery h2 {
    font-family: 'Dancing Script', cursive;
    font-size: 2.5rem;
    font-weight: 600;
    color: #478104;
    margin-bottom: 1.5rem;
    text-align: center;
}

.gallery-container {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 2rem;
    max-width: 800px;
    margin: 0 auto;
}

.gallery-item {
    background-color: #fff;
    border-radius: 10px;
    overflow: hidden;
    box-shadow: 0 5px 15px rgba(0,0,0,0.1);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    cursor: pointer;
}

.gallery-item:hover {
    transform: translateY(-5px);
    box-shadow: 0 8px 25px rgba(0,0,0,0.15);
}

.gallery-image {
    width: 100%;
    height: 250px;
    object-fit: cover;
    transition: transform 0.3s ease;
}

.gallery-item:hover .gallery-image {
    transform: scale(1.05);
}

/* Modal for enlarged photos */
.modal {
    display: none;
    position: fixed;
    z-index: 1000;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.9);
    backdrop-filter: blur(5px);
}

.modal-content {
    position: relative;
    margin: 2% auto;
    width: 90%;
    max-width: 900px;
    height: 90%;
    display: flex;
    align-items: center;
    justify-content: center;
}

.modal-image {
    max-width: 100%;
    max-height: 100%;
    object-fit: contain;
    border-radius: 10px;
    box-shadow: 0 20px 60px rgba(0,0,0,0.5);
}

.close-modal {
    position: absolute;
    top: -40px;
    right: 0;
    color: #fff;
    font-size: 35px;
    font-weight: bold;
    cursor: pointer;
    transition: color 0.3s ease;
    z-index: 1001;
}

.close-modal:hover {
    color: #396803;
}

/* RSVP Form */
.rsvp-form-section {
    max-width: 600px;
    margin: 0 auto;
    padding: 0 2rem;
}

.rsvp-form {
    background-color: #fff;
    padding: 2rem;
    border-radius: 15px;
    box-shadow: 0 10px 30px rgba(0,0,0,0.1);
}

.form-group {
    margin-bottom: 1.5rem;
}

.form-group label {
    display: block;
    margin-bottom: 0.5rem;
    font-weight: 500;
    color: #333;
}

.form-group h3 {
    font-family: 'Dancing Script', cursive;
    font-size: 2rem;
    font-weight: 600;
    color: #478104;
    margin-bottom: 1rem;
    margin-top: 0;
}

.form-group h4 {
    font-family: 'Playfair Display', serif;
    font-size: 1.1rem;
    font-weight: 600;
    color: #478104;
    margin-bottom: 0.5rem;
    margin-top: 1rem;
}

.form-group h5 {
    font-family: 'Playfair Display', serif;
    font-size: 1rem;
    font-weight: 600;
    color: #478104;
    margin-bottom: 0.5rem;
    margin-top: 1rem;
}

.conversation-intro {
    margin-bottom: 1.5rem;
    color: #666;
    line-height: 1.6;
    font-style: italic;
}

.form-group input[type="text"],
.form-group input[type="email"],
.form-group input[type="tel"],
.form-group select,
.form-group textarea {
    width: 100%;
    padding: 0.75rem;
    border: 2px solid #ddd;
    border-radius: 5px;
    font-size: 1rem;
    transition: border-color 0.3s ease;
}

.form-group input:focus,
.form-group select:focus,
.form-group textarea:focus {
    outline: none;
    border-color: #478104;
}

.form-group textarea {
    resize: vertical;
    min-height: 80px;
}

.radio-group,
.checkbox-group {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
}

.radio-label,
.checkbox-label {
    display: flex;
    align-items: center;
    cursor: pointer;
    padding: 0.5rem;
    border-radius: 5px;
    transition: background-color 0.3s ease;
}

.radio-label:hover,
.checkbox-label:hover {
    background-color: #f9f9f9;
}

.radio-label input,
.checkbox-label input {
    margin-right: 0.5rem;
    width: auto;
}

.submit-btn {
    background-color: #478104;
    color: #fff;
    padding: 1rem 2rem;
    border: none;
    border-radius: 5px;
    font-size: 1.1rem;
    font-weight: 500;
    cursor: pointer;
    transition: background-color 0.3s ease;
    width: 100%;
}

.submit-btn:hover {
    background-color: #396803;
}

/* Form conditional display */
.form-group.hidden {
    display: none;
}

/* Footer */
footer {
    background-color: #333;
    color: #fff;
    text-align: center;
    padding: 1rem 0;
    margin-top: 3rem;
}

/* Responsive design */
@media (max-width: 768px) {
    .hero {
        grid-template-columns: 1fr;
        text-align: center;
    }
    
    .hero-content h1 {
        font-size: 2.8rem;
    }
    
    .couple-names {
        font-size: 1.4rem;
    }
    
    .wedding-details {
        grid-template-columns: 1fr;
    }
    
    nav ul {
        flex-direction: column;
        align-items: center;
        gap: 0.5rem;
    }
    
    nav li {
        margin: 0.25rem 0;
    }
    
    .timeline-item {
        flex-direction: column;
        align-items: flex-start;
        gap: 0.5rem;
    }
    
    .timeline-item .event {
        margin-left: 0;
    }
    
    .info-grid {
        grid-template-columns: 1fr;
    }
    
    .gallery-container {
        grid-template-columns: 1fr;
        gap: 1.5rem;
    }
    
    .gallery-image {
        height: 200px;
    }
    
    .radio-group,
    .checkbox-group {
        gap: 0.75rem;
    }
}

@media (max-width: 480px) {
    main {
        padding: 1rem 0;
    }
    
    .hero-content h1 {
        font-size: 2.2rem;
    }
    
    .page-header h1 {
        font-size: 2.5rem;
    }
    
    .rsvp-form {
        padding: 1.5rem;
    }
}

/* Placeholder for missing image */
#couple-photo {
    background-color: #f0f0f0;
    border: 2px dashed #ccc;
    min-height: 300px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #666;
    font-style: italic;
}

#couple-photo::before {
    content: "Wedding Photo Placeholder";
    font-size: 1.1rem;
}

/* Password Protection Styles */
.password-section {
    display: flex;
    justify-content: center;
    align-items: center;
    min-height: 60vh;
    padding: 2rem;
}

.password-container {
    background-color: #fff;
    padding: 3rem;
    border-radius: 15px;
    box-shadow: 0 10px 30px rgba(0,0,0,0.15);
    text-align: center;
    max-width: 400px;
    width: 100%;
}

.password-container h1 {
    font-family: 'Dancing Script', cursive;
    color: #478104;
    margin-bottom: 1rem;
    font-size: 2.8rem;
    font-weight: 700;
}

.password-container p {
    color: #666;
    margin-bottom: 2rem;
    font-size: 1.1rem;
}

.password-form .form-group {
    margin-bottom: 1.5rem;
}

.password-form input[type="password"] {
    width: 100%;
    padding: 1rem;
    border: 2px solid #ddd;
    border-radius: 8px;
    font-size: 1.1rem;
    text-align: center;
    transition: border-color 0.3s ease;
}

.password-form input[type="password"]:focus {
    outline: none;
    border-color: #478104;
    box-shadow: 0 0 0 3px rgba(46, 84, 3, 0.1);
}

.button-group {
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

.button-group .submit-btn {
    background-color: #478104;
    color: #fff;
    padding: 1rem 2rem;
    border: none;
    border-radius: 8px;
    font-size: 1.1rem;
    font-weight: 500;
    cursor: pointer;
    transition: background-color 0.3s ease;
}

.button-group .submit-btn:hover {
    background-color: #396803;
}

.button-group .back-btn {
    background-color: transparent;
    color: #666;
    padding: 0.75rem 1.5rem;
    border: 2px solid #ddd;
    border-radius: 8px;
    font-size: 1rem;
    cursor: pointer;
    transition: all 0.3s ease;
}

.button-group .back-btn:hover {
    background-color: #f5f5f5;
    border-color: #999;
    color: #333;
}

.error-message {
    background-color: #ffe6e6;
    color: #cc0000;
    padding: 0.75rem;
    border-radius: 5px;
    margin-bottom: 1rem;
    border: 1px solid #ffcccc;
    font-size: 0.95rem;
}

/* Responsive design for password protection */
@media (max-width: 480px) {
    .password-container {
        padding: 2rem;
        margin: 1rem;
    }
    
    .password-container h1 {
        font-size: 1.6rem;
    }
    
    .button-group {
        gap: 0.75rem;
    }
}