/* CSS Reset & Base */
*, *::before, *::after {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

:root {
    --color-navy: #1a2744;
    --color-navy-light: #2d3e5f;
    --color-cream: #f5f2eb;
    --color-cream-dark: #e8e4d9;
    --color-gray: #6b7280;
    --color-gray-light: #9ca3af;
    --color-white: #ffffff;
    --color-accent: #8b7355;
    --color-success: #059669;

    --font-serif: 'Georgia', 'Times New Roman', serif;
    --font-sans: 'Segoe UI', system-ui, -apple-system, sans-serif;

    --shadow-sm: 0 1px 2px rgba(0, 0, 0, 0.05);
    --shadow-md: 0 4px 6px rgba(0, 0, 0, 0.1);
    --shadow-lg: 0 10px 15px rgba(0, 0, 0, 0.1);

    --radius: 8px;
    --radius-lg: 12px;
}

html {
    font-size: 16px;
    scroll-behavior: smooth;
}

body {
    font-family: var(--font-sans);
    background-color: var(--color-cream);
    color: var(--color-navy);
    line-height: 1.6;
    min-height: 100vh;
    display: flex;
    flex-direction: column;
}

/* Navigation */
.nav {
    background-color: var(--color-navy);
    color: var(--color-white);
    padding: 1rem 2rem;
    display: flex;
    justify-content: space-between;
    align-items: center;
    position: sticky;
    top: 0;
    z-index: 100;
}

.nav-brand {
    font-family: var(--font-serif);
    font-size: 1.5rem;
    color: var(--color-white);
    text-decoration: none;
}

.nav-links {
    display: flex;
    gap: 2rem;
}

.nav-links a {
    color: var(--color-cream);
    text-decoration: none;
    font-weight: 500;
    transition: color 0.2s;
}

.nav-links a:hover {
    color: var(--color-white);
}

/* Container */
.container {
    flex: 1;
    width: 100%;
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 1rem;
}

/* Hero Section */
.hero {
    text-align: center;
    padding: 4rem 2rem;
    background: linear-gradient(to bottom, var(--color-navy), var(--color-navy-light));
    color: var(--color-white);
    margin: 0 -1rem;
}

.hero h1 {
    font-family: var(--font-serif);
    font-size: 1.5rem;
    font-weight: 400;
    margin-bottom: 0.5rem;
    color: var(--color-cream);
}

.hero .name {
    font-family: var(--font-serif);
    font-size: 3rem;
    font-weight: 600;
    margin-bottom: 2rem;
}

.hero-placeholder {
    width: 200px;
    height: 200px;
    border-radius: 50%;
    background-color: var(--color-cream-dark);
    margin: 0 auto;
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--color-gray);
    font-style: italic;
}

/* Info Section */
.info-section {
    padding: 3rem 2rem;
    text-align: center;
}

.info-section h2 {
    font-family: var(--font-serif);
    font-size: 2rem;
    margin-bottom: 2rem;
    color: var(--color-navy);
}

.info-card {
    background-color: var(--color-white);
    border-radius: var(--radius-lg);
    padding: 2rem;
    max-width: 500px;
    margin: 0 auto 2rem;
    box-shadow: var(--shadow-md);
}

.info-item {
    padding: 1rem 0;
    border-bottom: 1px solid var(--color-cream-dark);
    display: flex;
    justify-content: space-between;
    align-items: center;
}

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

.info-item strong {
    color: var(--color-navy);
}

.info-item span {
    color: var(--color-gray);
}

/* Bio Section */
.bio-section {
    padding: 3rem 2rem;
    background-color: var(--color-white);
    margin: 0 -1rem;
}

.bio-section h2 {
    font-family: var(--font-serif);
    font-size: 2rem;
    margin-bottom: 1.5rem;
    text-align: center;
    color: var(--color-navy);
}

.bio {
    max-width: 700px;
    margin: 0 auto;
    text-align: center;
    color: var(--color-gray);
    font-size: 1.125rem;
    line-height: 1.8;
}

/* CTA Section */
.cta-section {
    padding: 3rem 2rem;
    text-align: center;
}

.cta-section h2 {
    font-family: var(--font-serif);
    font-size: 2rem;
    margin-bottom: 1rem;
    color: var(--color-navy);
}

.cta-section p {
    color: var(--color-gray);
    margin-bottom: 2rem;
}

.cta-buttons {
    display: flex;
    gap: 1rem;
    justify-content: center;
    flex-wrap: wrap;
}

/* Buttons */
.btn {
    display: inline-block;
    padding: 0.875rem 2rem;
    border-radius: var(--radius);
    font-weight: 600;
    text-decoration: none;
    cursor: pointer;
    border: none;
    font-size: 1rem;
    transition: all 0.2s;
}

.btn-primary {
    background-color: var(--color-navy);
    color: var(--color-white);
}

.btn-primary:hover {
    background-color: var(--color-navy-light);
}

.btn-secondary {
    background-color: var(--color-cream-dark);
    color: var(--color-navy);
}

.btn-secondary:hover {
    background-color: var(--color-cream);
}

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

.form-section h1 {
    font-family: var(--font-serif);
    font-size: 2rem;
    margin-bottom: 0.5rem;
    text-align: center;
    color: var(--color-navy);
}

.form-intro {
    text-align: center;
    color: var(--color-gray);
    margin-bottom: 2rem;
}

.rsvp-form {
    background-color: var(--color-white);
    padding: 2rem;
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow-md);
}

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

.form-row {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 1rem;
}

label {
    display: block;
    margin-bottom: 0.5rem;
    font-weight: 500;
    color: var(--color-navy);
}

.required {
    color: #dc2626;
}

input[type="text"],
input[type="email"],
input[type="tel"],
input[type="number"],
select,
textarea {
    width: 100%;
    padding: 0.75rem 1rem;
    border: 1px solid var(--color-cream-dark);
    border-radius: var(--radius);
    font-size: 1rem;
    font-family: inherit;
    transition: border-color 0.2s, box-shadow 0.2s;
}

input:focus,
select:focus,
textarea:focus {
    outline: none;
    border-color: var(--color-navy);
    box-shadow: 0 0 0 3px rgba(26, 39, 68, 0.1);
}

textarea {
    resize: vertical;
    min-height: 100px;
}

/* Upload Area */
.upload-area {
    border: 2px dashed var(--color-cream-dark);
    border-radius: var(--radius);
    padding: 2rem;
    text-align: center;
    cursor: pointer;
    transition: all 0.2s;
    position: relative;
}

.upload-area:hover,
.upload-area.drag-over {
    border-color: var(--color-navy);
    background-color: rgba(26, 39, 68, 0.02);
}

.upload-input {
    position: absolute;
    width: 100%;
    height: 100%;
    top: 0;
    left: 0;
    opacity: 0;
    cursor: pointer;
}

.upload-placeholder {
    color: var(--color-gray);
}

.upload-placeholder svg {
    margin-bottom: 1rem;
    opacity: 0.5;
}

.upload-placeholder p {
    font-weight: 500;
    margin-bottom: 0.5rem;
}

.upload-hint {
    font-size: 0.875rem;
    color: var(--color-gray-light);
}

.upload-preview {
    display: none;
}

.upload-preview img,
.upload-preview video {
    max-width: 100%;
    max-height: 200px;
    border-radius: var(--radius);
}

.upload-preview .file-name {
    margin-top: 0.5rem;
    font-size: 0.875rem;
    color: var(--color-gray);
}

.btn-submit {
    width: 100%;
    padding: 1rem;
    font-size: 1.125rem;
}

/* Thank You Section */
.thank-you-section {
    padding: 4rem 2rem;
    display: flex;
    justify-content: center;
    align-items: center;
    min-height: 60vh;
}

.thank-you-card {
    background-color: var(--color-white);
    padding: 3rem;
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow-lg);
    text-align: center;
    max-width: 500px;
}

.check-icon {
    color: var(--color-success);
    margin-bottom: 1.5rem;
}

.thank-you-card h1 {
    font-family: var(--font-serif);
    font-size: 2rem;
    margin-bottom: 1rem;
    color: var(--color-navy);
}

.thank-you-card p {
    color: var(--color-gray);
    margin-bottom: 2rem;
}

.thank-you-actions {
    display: flex;
    gap: 1rem;
    justify-content: center;
}

/* Gallery Section */
.gallery-section {
    padding: 3rem 2rem;
}

.gallery-section h1 {
    font-family: var(--font-serif);
    font-size: 2rem;
    margin-bottom: 0.5rem;
    text-align: center;
    color: var(--color-navy);
}

.gallery-intro {
    text-align: center;
    color: var(--color-gray);
    margin-bottom: 2rem;
}

.gallery-empty {
    text-align: center;
    padding: 4rem 2rem;
    background-color: var(--color-white);
    border-radius: var(--radius-lg);
}

.gallery-empty p {
    color: var(--color-gray);
    margin-bottom: 1.5rem;
}

.gallery-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
    gap: 1.5rem;
    margin-bottom: 2rem;
}

.gallery-item {
    background-color: var(--color-white);
    border-radius: var(--radius-lg);
    overflow: hidden;
    box-shadow: var(--shadow-md);
    transition: transform 0.2s, box-shadow 0.2s;
}

.gallery-item:hover {
    transform: translateY(-4px);
    box-shadow: var(--shadow-lg);
}

.gallery-item img,
.gallery-item video {
    width: 100%;
    height: 250px;
    object-fit: cover;
    display: block;
    cursor: pointer;
}

.gallery-item video {
    cursor: default;
}

.gallery-item-info {
    padding: 1rem;
}

.gallery-item-info .uploader {
    font-weight: 600;
    color: var(--color-navy);
}

.gallery-item-info .message {
    color: var(--color-gray);
    font-size: 0.875rem;
    margin-top: 0.5rem;
    line-height: 1.5;
}

.gallery-cta {
    text-align: center;
    padding: 2rem 0;
}

/* Lightbox */
.lightbox {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.9);
    display: none;
    justify-content: center;
    align-items: center;
    flex-direction: column;
    z-index: 1000;
    padding: 2rem;
}

.lightbox.active {
    display: flex;
}

.lightbox-close {
    position: absolute;
    top: 1rem;
    right: 1rem;
    background: none;
    border: none;
    color: var(--color-white);
    font-size: 2rem;
    cursor: pointer;
    padding: 0.5rem;
    line-height: 1;
}

.lightbox-content img {
    max-width: 90vw;
    max-height: 80vh;
    border-radius: var(--radius);
}

.lightbox-info {
    color: var(--color-white);
    text-align: center;
    margin-top: 1rem;
}

.lightbox-info strong {
    display: block;
    margin-bottom: 0.5rem;
}

/* Footer */
.footer {
    background-color: var(--color-navy);
    color: var(--color-cream);
    text-align: center;
    padding: 2rem;
    margin-top: auto;
}

/* Responsive */
@media (max-width: 768px) {
    .nav {
        flex-direction: column;
        gap: 1rem;
    }

    .nav-links {
        gap: 1rem;
    }

    .hero .name {
        font-size: 2rem;
    }

    .form-row {
        grid-template-columns: 1fr;
    }

    .thank-you-actions,
    .cta-buttons {
        flex-direction: column;
    }

    .gallery-grid {
        grid-template-columns: 1fr;
    }
}
