/* --- VARIABLES & GENERAL STYLES --- */
:root {
    /* EDIT: Your Colors */
    --color-primary: #4a4e69; /* Muted dark blue/purple */
    --color-secondary: #f2e9e4; /* Very light, warm beige */
    --color-dark: #22223b; /* Darkest color for text */
    --color-accent: #c9ada7; /* Muted pink/rose */
    --color-light: #ffffff;

    /* EDIT: Your Fonts */
    --font-heading: 'Cormorant Garamond', serif;
    --font-body: 'Lato', sans-serif;

    --shadow: 0 10px 30px rgba(0,0,0,0.1);
}

* {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
    scroll-behavior: smooth;
}

body {
    font-family: var(--font-body);
    background-color: var(--color-light);
    color: var(--color-dark);
    line-height: 1.8;
}

.container {
    max-width: 1100px;
    margin: 0 auto;
    padding: 0 1.5rem;
}

h1, h2, h3 {
    font-family: var(--font-heading);
    font-weight: 700;
}

h2 {
    font-size: 3rem;
    text-align: center;
    margin-bottom: 2rem;
    color: var(--color-primary);
}

p {
    font-size: 1.1rem;
    margin-bottom: 1rem;
}

section {
    padding: 6rem 0;
}

/* --- LANGUAGE SWITCHER --- */
.language-switcher {
    position: absolute;
    top: 20px;
    right: 20px;
    z-index: 100;
}

.lang-btn {
    background-color: rgba(255, 255, 255, 0.2);
    border: 1px solid #fff;
    color: #fff;
    padding: 0.5rem 0.8rem;
    margin-left: 0.5rem;
    border-radius: 5px;
    cursor: pointer;
    font-family: var(--font-body);
    font-weight: 700;
    transition: background-color 0.3s;
}

.lang-btn:hover {
    background-color: rgba(255, 255, 255, 0.4);
}

.lang-btn.active {
    background-color: #fff;
    color: var(--color-primary);
}


/* --- HERO SECTION --- */
.hero {
    height: 100vh;
    display: flex;
    justify-content: center;
    align-items: center;
    text-align: center;
    color: var(--color-light);
    position: relative;
    /* EDIT: Replace this placeholder background image URL with your own */
    background-image: linear-gradient(rgba(0,0,0,0.5), rgba(0,0,0,0.5)), url('https://images.unsplash.com/photo-1523438943993-1289547d6e46?q=80&w=1887&auto=format&fit=crop');
    background-size: cover;
    background-position: center;
    background-attachment: fixed; /* Parallax effect */
}

.hero-content h1 {
    font-size: 5rem;
    margin-bottom: 0.5rem;
    letter-spacing: 2px;
}

.hero-content p {
    font-size: 1.5rem;
    font-weight: 300;
    margin-bottom: 2rem;
}

/* --- COUNTDOWN TIMER --- */
#countdown {
    display: flex;
    justify-content: center;
    gap: 1.5rem;
    margin-top: 2rem;
}

#countdown > div {
    background: rgba(0,0,0,0.4);
    padding: 1rem 1.5rem;
    border-radius: 8px;
    min-width: 100px;
}

#countdown span {
    display: block;
    font-size: 2.5rem;
    font-weight: 700;
}

#countdown span.label {
    font-size: 0.8rem;
    font-weight: 300;
    text-transform: uppercase;
    letter-spacing: 1px;
}

/* --- STICKY NAVIGATION --- */
#navbar {
    background-color: var(--color-light);
    padding: 1rem 0;
    position: sticky;
    top: -1px; /* The -1px trick prevents a 1px gap on some browsers */
    z-index: 1000;
    box-shadow: var(--shadow);
    display: none; /* Hidden by default, shown with JS */
    opacity: 0;
    transition: opacity 0.5s ease-in-out;
}

#navbar.visible {
    display: block;
}

#navbar.scrolled {
    opacity: 1;
}

#navbar .container {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 2rem;
}

#navbar a {
    text-decoration: none;
    color: var(--color-primary);
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 1px;
    font-size: 0.9rem;
    position: relative;
    padding: 0.5rem 0;
}

#navbar a::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 0;
    height: 2px;
    background-color: var(--color-accent);
    transition: width 0.3s ease-in-out;
}

#navbar a:hover::after {
    width: 100%;
}

/* --- STORY SECTION --- */
#story {
    background-color: var(--color-secondary);
}

.story-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 4rem;
    align-items: center;
}

.image-content img {
    width: 100%;
    border-radius: 8px;
    box-shadow: var(--shadow);
}

/* --- DETAILS, DRESS CODE, & UNLOCK SECTIONS --- */
#details, #dresscode, #unlock {
    text-align: center;
}

.details-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 2rem;
    margin: 3rem 0;
}

.detail-item {
    background-color: var(--color-secondary);
    padding: 2rem;
    border-radius: 8px;
}

.detail-item h3 {
    font-size: 2rem;
    color: var(--color-primary);
    margin-bottom: 1rem;
}

.map-container {
    margin-top: 3rem;
    border-radius: 8px;
    overflow: hidden; /* Ensures the iframe corners are rounded */
    box-shadow: var(--shadow);
}

/* --- GALLERY SECTION --- */
#gallery {
    background-color: var(--color-secondary);
}

.gallery-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 1rem;
}

.gallery-item img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    border-radius: 8px;
    transition: transform 0.3s, box-shadow 0.3s;
}

.gallery-item img:hover {
    transform: scale(1.05);
    box-shadow: var(--shadow);
}

/* --- RSVP & UNLOCK SECTIONS --- */
#rsvp, #unlock {
    text-align: center;
}

/* --- CUSTOM RSVP FORM STYLING --- */
.rsvp-form {
    max-width: 700px;
    margin: 2rem auto 0;
    text-align: left;
    background: #ffffff;
    padding: 2.5rem;
    border-radius: 8px;
    box-shadow: var(--shadow);
}
/* The unlock section needs a lighter background for the form container */
#unlock .rsvp-form {
    background: var(--color-secondary);
}


.form-group {
    margin-bottom: 1.5rem;
}

.form-group label {
    display: block;
    margin-bottom: 0.5rem;
    font-weight: 700;
    color: var(--color-primary);
}

.form-group input[type="text"],
.form-group input[type="email"],
.form-group select,
.form-group textarea {
    width: 100%;
    padding: 0.8rem 1rem;
    border: 1px solid #ccc;
    border-radius: 5px;
    font-family: var(--font-body);
    font-size: 1rem;
    transition: border-color 0.3s, box-shadow 0.3s;
}

.form-group input[type="text"]:focus,
.form-group input[type="email"]:focus,
.form-group select:focus,
.form-group textarea:focus {
    outline: none;
    border-color: var(--color-accent);
    box-shadow: 0 0 5px rgba(192, 159, 128, 0.5);
}

.form-group input[readonly] {
    background-color: #f1f1f1;
    cursor: not-allowed;
}

.radio-group label {
    display: inline-block;
    margin-right: 1.5rem;
    font-weight: 400;
    cursor: pointer;
}

.radio-group input[type="radio"] {
    margin-right: 0.5rem;
}

.form-button {
    display: block;
    width: 100%;
    padding: 1rem;
    background-color: var(--color-accent);
    color: white;
    border: none;
    border-radius: 5px;
    font-size: 1.2rem;
    font-weight: 700;
    cursor: pointer;
    transition: background-color 0.3s;
}

.form-button:hover {
    background-color: #a88a6d; /* A slightly darker shade of the accent color */
}

.lookup-error-message {
    color: #D32F2F; /* A shade of red */
    background-color: #FFCDD2; /* Light red background */
    border: 1px solid #D32F2F;
    padding: 0.8rem 1rem;
    margin-top: 1rem;
    border-radius: 5px;
    text-align: center;
}

/* --- FOOTER --- */
footer {
    background-color: var(--color-primary);
    color: white;
    padding: 3rem 0;
    display: flex;
    justify-content: center;
    align-items: center;
    text-align: center;
}
footer p {
    font-size: 1.5rem;
    font-family: var(--font-heading);
    margin: 0;
}

/* --- SCROLL ANIMATION (Fade-in effect) --- */
.fade-in {
    opacity: 0;
    transform: translateY(20px);
    transition: opacity 0.8s ease-out, transform 0.8s ease-out;
}

.fade-in.is-visible {
    opacity: 1;
    transform: translateY(0);
}

/* --- RESPONSIVE DESIGN --- */
@media(max-width: 900px) {
    .story-grid {
        grid-template-columns: 1fr;
    }
    .image-content {
        order: -1; /* Puts the image on top on mobile */
    }
    .gallery-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media(max-width: 768px) {
    h1 { font-size: 3.5rem; }
    h2 { font-size: 2.5rem; }
    #navbar .container {
        gap: 1.2rem;
        flex-wrap: wrap; /* Allow nav items to wrap */
        justify-content: center;
    }
    #navbar a { font-size: 0.8rem; }
    #countdown { flex-wrap: wrap; }
    .details-grid { grid-template-columns: 1fr; }
}

@media(max-width: 480px) {
    .language-switcher {
        top: 10px;
        right: 10px;
    }
    #countdown > div {
        min-width: 80px;
        padding: 0.8rem;
    }
    #countdown span { font-size: 2rem; }
    .gallery-grid { grid-template-columns: 1fr; }
    .rsvp-form { padding: 1.5rem; }
}
