:root {
    --primary-color: #5D5C61;
    --accent-color: #B1A296;
    /* Gold/Beige */
    --accent-dark: #8e8075;
    --bg-color: #F8F5F2;
    /* Cream */
    --white: #FFFFFF;
    --text-color: #333333;
    --font-heading: 'Great Vibes', cursive;
    --font-body: 'Lato', sans-serif;
    --shadow: 0 10px 30px rgba(0, 0, 0, 0.05);
    --radius: 12px;
}

* {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

body {
    font-family: var(--font-body);
    /* Fixed variable usage */
    background-color: var(--bg-color);
    /* Fixed variable usage */
    color: var(--text-color);
    /* Fixed variable usage */
    line-height: 1.6;
    background-image: radial-gradient(#e6e6e6 1px, transparent 1px);
    background-size: 20px 20px;
}

.container {
    max-width: 900px;
    /* Increased width slightly */
    margin: 0 auto;
    padding: 20px;
    overflow-x: hidden;
}

/* Header */
.hero {
    text-align: center;
    margin-bottom: 20px;
    animation: fadeIn 1s ease-out;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 2rem;
    justify-content: center;
    min-height: 85vh;
}

.home-actions {
    display: flex;
    flex-direction: column;
    gap: 1rem;
    width: 100%;
    align-items: center;
}

@media (min-width: 900px) {
    .container {
        max-width: 1200px;
    }

    .hero {
        flex-direction: row;
        text-align: left;
        gap: 4rem;
    }

    .invitation-card-container {
        width: 60%;
        max-width: none;
    }

    .home-actions {
        width: 35%;
        display: flex;
        flex-direction: column;
        justify-content: center;
        align-items: center;
        /* Center buttons horizontally */
        gap: 1.5rem;
    }
}

.invitation-card-container {
    background: var(--white);
    padding: 15px;
    box-shadow: var(--shadow);
    border-radius: var(--radius);
    transition: transform 0.3s ease;
    /* Height handled by content now to avoid overlap */
    width: 100%;
    max-width: 600px;
    /* Constrain width for aesthetic */
    display: flex;
    align-items: center;
    justify-content: center;
}



.invitation-card-container:hover {
    transform: scale(1.01);
}

.invitation-image {
    max-width: 100%;
    height: auto;
    border-radius: 4px;
    display: block;
}

/* Forms */
.rsvp-section {
    background: rgba(255, 255, 255, 0.9);
    backdrop-filter: blur(10px);
    padding: 40px;
    border-radius: var(--radius);
    box-shadow: var(--shadow);
    margin-bottom: 60px;
    border: 1px solid rgba(255, 255, 255, 0.5);
}

.rsvp-section h2,
.guests-section h2 {
    font-family: var(--font-heading);
    text-align: center;
    margin-bottom: 30px;
    font-size: 3rem;
    /* Larger font for Great Vibes */
    color: var(--primary-color);
}

.form-group {
    margin-bottom: 20px;
}

label {
    display: block;
    margin-bottom: 8px;
    font-weight: 700;
    color: var(--primary-color);
    font-size: 0.9rem;
    text-transform: uppercase;
    letter-spacing: 1px;
}

input[type="text"],
input[type="number"],
textarea {
    width: 100%;
    padding: 12px;
    border: 1px solid #d1d1d1;
    border-radius: 4px;
    font-family: var(--font-body);
    font-size: 1rem;
    transition: all 0.3s ease;
    background: #fdfdfd;
}

input[type="text"]:focus,
input[type="number"]:focus,
textarea:focus {
    border-color: var(--accent-color);
    outline: none;
    box-shadow: 0 0 0 3px rgba(177, 162, 150, 0.2);
}

.radio-group {
    display: flex;
    gap: 30px;
    justify-content: center;
    margin: 20px 0;
}

.radio-option {
    display: flex;
    align-items: center;
    cursor: pointer;
    font-weight: 400;
}

.radio-option input {
    margin-right: 8px;
    accent-color: var(--accent-color);
    width: 20px;
    height: 20px;
}

.submit-btn {
    display: inline-block;
    /* Fit to text */
    min-width: 200px;
    /* Minimum width for consistency */
    padding: 18px 40px;
    background-color: var(--accent-color);
    color: var(--white);
    border: none;
    border-radius: 50px;
    /* Pill shape */
    font-size: 1.5rem;
    /* Larger for script font */
    cursor: pointer;
    transition: all 0.3s ease;
    font-family: var(--font-heading);
    font-weight: 400;
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
}

.submit-btn:hover {
    background-color: var(--accent-dark);
    transform: translateY(-2px);
    box-shadow: 0 6px 12px rgba(0, 0, 0, 0.15);
}

/* Search Box */
.search-box {
    margin-bottom: 30px;
}

.subtitle {
    text-align: center;
    color: #888;
    margin-bottom: 20px;
}

/* Guest List Items */
.guests-list-container {
    display: flex;
    flex-direction: column;
    gap: 15px;
}

.guest-list-item {
    background: var(--white);
    padding: 20px;
    border-radius: var(--radius);
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.02);
    display: flex;
    justify-content: space-between;
    align-items: center;
    transition: transform 0.2s;
    border-left: 5px solid #ccc;
}

.guest-list-item:hover {
    transform: translateX(5px);
}

.guest-list-item.status-confirmed {
    border-left-color: #4CAF50;
}

.guest-list-item.status-declined {
    border-left-color: #F44336;
}

.guest-list-item.status-pending {
    border-left-color: #FFC107;
}

.guest-info {
    display: flex;
    flex-direction: column;
}

.guest-name-text {
    font-weight: 700;
    font-size: 1.1rem;
}

.guest-status-badge {
    font-size: 0.85rem;
    color: #666;
    margin-top: 5px;
}

.edit-btn {
    padding: 8px 16px;
    background-color: var(--primary-color);
    color: white;
    border: none;
    border-radius: 20px;
    cursor: pointer;
    font-size: 0.9rem;
    transition: background 0.2s;
}

.edit-btn:hover {
    background-color: #444;
}

/* Modal */
.modal {
    display: none;
    position: fixed;
    z-index: 1000;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.5);
    backdrop-filter: blur(5px);
}

.modal-content {
    background-color: #fff;
    margin: 10% auto;
    padding: 30px;
    border: 1px solid #888;
    width: 90%;
    max-width: 500px;
    border-radius: var(--radius);
    box-shadow: 0 20px 50px rgba(0, 0, 0, 0.2);
    position: relative;
    animation: fadeIn 0.3s;
}

.close-modal {
    position: absolute;
    top: 15px;
    right: 20px;
    color: #aaa;
    font-size: 28px;
    font-weight: bold;
    cursor: pointer;
}

.close-modal:hover {
    color: #000;
}

@media (max-width: 600px) {
    .guest-list-item {
        flex-direction: column;
        align-items: flex-start;
        gap: 15px;
    }

    .edit-btn {
        width: 100%;
    }
}

/* Infos Page Redesign */

.info-page-header {
    text-align: center;
    margin-bottom: 3rem;
    animation: fadeIn 0.8s ease-out;
}

.info-page-header h1 {
    font-family: var(--font-heading);
    font-size: 4rem;
    color: var(--primary-color);
    margin-bottom: 0.5rem;
}

.info-page-subtitle {
    font-size: 1.2rem;
    color: var(--accent-dark);
    text-transform: uppercase;
    letter-spacing: 2px;
}

.info-grid {
    display: grid;
    grid-template-columns: 1fr;
    gap: 2rem;
    padding-bottom: 4rem;
}

@media (min-width: 768px) {
    .info-grid {
        grid-template-columns: repeat(2, 1fr);
        align-items: start;
    }

    /* Make the timeline (first item) span full width or stay on left? 
       Let's make the first card (Timeline) span 2 columns if we want it prominent, 
       or just keep 2 columns. Let's go with 2 columns, maybe Timeline is tall.
       Actually, a "Schedule" spanning full width at top might be nice, 
       but let's stick to a clean 2-column masonry-ish feel or just standard grid.
       
       Let's make the "Date & Heure" card span full width for emphasis.
    */
    .info-card.full-width {
        grid-column: span 2;
    }
}

.info-card {
    background: var(--white);
    padding: 2.5rem;
    border-radius: var(--radius);
    box-shadow: var(--shadow);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    border-top: 4px solid var(--accent-color);
    height: 100%;
}

.info-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 15px 35px rgba(0, 0, 0, 0.1);
}

.info-card h2 {
    font-family: var(--font-heading);
    color: var(--primary-color);
    font-size: 2.2rem;
    margin-bottom: 1.5rem;
    border-bottom: 1px solid #eee;
    padding-bottom: 0.5rem;
    display: flex;
    align-items: center;
    gap: 1rem;
}

.info-card h2 i {
    color: var(--accent-color);
    font-size: 1.5rem;
}

/* Timeline Styles */
.timeline {
    position: relative;
    padding-left: 20px;
}

.timeline::before {
    content: '';
    position: absolute;
    left: 0;
    top: 10px;
    bottom: 10px;
    width: 2px;
    background: var(--accent-color);
}

.timeline-item {
    position: relative;
    padding-left: 30px;
    margin-bottom: 2rem;
}

.timeline-item:last-child {
    margin-bottom: 0;
}

.timeline-marker {
    position: absolute;
    left: -9px;
    top: 0;
    width: 20px;
    height: 20px;
    background: var(--white);
    border: 3px solid var(--accent-color);
    border-radius: 50%;
    z-index: 1;
}

.timeline-time {
    font-weight: 700;
    color: var(--accent-dark);
    font-size: 0.9rem;
    text-transform: uppercase;
    letter-spacing: 1px;
    margin-bottom: 0.2rem;
}

.timeline-content strong {
    font-size: 1.2rem;
    color: var(--primary-color);
    display: block;
}

/* Locations & other text */
.location-item {
    margin-bottom: 2rem;
}

.location-item:last-child {
    margin-bottom: 0;
}

.address-link {
    display: inline-block;
    margin-top: 0.5rem;
    color: var(--text-color);
    text-decoration: none;
    border-bottom: 1px dashed var(--accent-color);
    transition: all 0.3s;
}

.address-link:hover {
    color: var(--accent-color);
    border-bottom-style: solid;
}

.info-text {
    white-space: pre-line;
    color: #555;
    line-height: 1.8;
}

/* Back Link Adjustments */
.back-link-container {
    margin: 20px 0;
}

.back-link {
    text-decoration: none;
    color: var(--primary-color);
    font-weight: 700;
    transition: color 0.3s;
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
}

.back-link:hover {
    color: var(--accent-color);
}

@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(20px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}