/* Base Variables & Reset */
:root {
    --bg-main: #f5eedc; /* Beige/Cream from the invitation */
    --bg-card: rgba(255, 255, 255, 0.7);
    --border-glass: rgba(166, 124, 82, 0.2);
    
    --primary: #947040; /* Elegant gold/brown */
    --primary-hover: #725530;
    --text-main: #2b2b2b; /* Dark charcoal for contrast */
    --text-muted: #5a5a5a;
    
    --font-heading: 'Playfair Display', serif;
    --font-body: 'Inter', sans-serif;
    
    --transition: all 0.3s cubic-bezier(0.25, 0.8, 0.25, 1);
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

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

body {
    background-color: var(--bg-main);
    color: var(--text-main);
    font-family: var(--font-body);
    line-height: 1.6;
    overflow-x: hidden;
    background-image: url("data:image/svg+xml,%3Csvg width='100' height='100' viewBox='0 0 100 100' xmlns='http://www.w3.org/2000/svg'%3E%3Cpath d='M11 18c3.866 0 7-3.134 7-7s-3.134-7-7-7-7 3.134-7-7 3.134 7 7 7zm48 25c3.866 0 7-3.134 7-7s-3.134-7-7-7-7 3.134-7 7 3.134 7 7 7zm-43-7c1.657 0 3-1.343 3-3s-1.343-3-3-3-3 1.343-3 3 1.343 3 3 3zm63 31c1.657 0 3-1.343 3-3s-1.343-3-3-3-3 1.343-3 3 1.343 3 3 3zM34 90c1.657 0 3-1.343 3-3s-1.343-3-3-3-3 1.343-3 3 1.343 3 3 3zm56-76c1.657 0 3-1.343 3-3s-1.343-3-3-3-3 1.343-3 3 1.343 3 3 3zM12 86c2.21 0 4-1.79 4-4s-1.79-4-4-4-4 1.79-4 4 1.79 4 4 4zm28-65c2.21 0 4-1.79 4-4s-1.79-4-4-4-4 1.79-4 4 1.79 4 4 4zm23-11c2.76 0 5-2.24 5-5s-2.24-5-5-5-5 2.24-5 5 2.24 5 5 5zm-6 60c2.21 0 4-1.79 4-4s-1.79-4-4-4-4 1.79-4 4 1.79 4 4 4zm29 22c2.76 0 5-2.24 5-5s-2.24-5-5-5-5 2.24-5 5 2.24 5 5 5zM32 63c2.76 0 5-2.24 5-5s-2.24-5-5-5-5 2.24-5 5 2.24 5 5 5zm57-13c2.76 0 5-2.24 5-5s-2.24-5-5-5-5 2.24-5 5 2.24 5 5 5zm-9-21c1.105 0 2-.895 2-2s-.895-2-2-2-2 .895-2 2 .895 2 2 2zM60 91c1.105 0 2-.895 2-2s-.895-2-2-2-2 .895-2 2 .895 2 2 2zM35 41c1.105 0 2-.895 2-2s-.895-2-2-2-2 .895-2 2 .895 2 2 2zM12 60c1.105 0 2-.895 2-2s-.895-2-2-2-2 .895-2 2 .895 2 2 2z' fill='%23947040' fill-opacity='0.03' fill-rule='evenodd'/%3E%3C/svg%3E");
}

/* Typography */
h1, h2, h3, h4 {
    font-family: var(--font-heading);
    font-weight: 500;
}

.section-title {
    font-size: 2.5rem;
    text-align: center;
    margin-bottom: 3rem;
    color: var(--primary);
}

/* Utilities */
.glass-card {
    background: var(--bg-card);
    border: 1px solid var(--border-glass);
    border-radius: 16px;
    box-shadow: 0 10px 40px 0 rgba(148, 112, 64, 0.08);
}

.section-padding {
    padding: 3rem 1.5rem;
}

.container {
    max-width: 1000px;
    margin: 0 auto;
}



/* Hero Section */
.hero {
    position: relative;
    padding: 0;
    margin-bottom: 2rem;
}

.hero-content {
    width: 100%;
}

.invite-image-hero {
    width: calc(100% - 20px);
    max-width: 1080px;
    margin: 0 auto;
    display: block;
}

.invite-image-hero img {
    width: 100%;
    height: auto;
    object-fit: contain;
    display: block;
}

.countdown-action {
    text-align: center;
    margin-top: 2.5rem;
}

/* Buttons */
.btn-primary {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    background: var(--primary);
    color: #fff;
    padding: 1rem 2.5rem;
    border-radius: 50px;
    text-decoration: none;
    font-weight: 600;
    font-size: 1rem;
    border: none;
    cursor: pointer;
    transition: var(--transition);
}

.btn-primary:hover {
    background: var(--primary-hover);
    transform: translateY(-2px);
    box-shadow: 0 10px 20px rgba(148, 112, 64, 0.2);
}

/* Countdown */
.countdown-section {
    padding: 0 1.5rem 4rem;
}

.countdown-container {
    display: flex;
    justify-content: center;
    gap: 1.5rem;
    flex-wrap: wrap;
    max-width: 600px;
    margin: 0 auto;
}

.time-box {
    background: var(--bg-card);
    border: 1px solid var(--border-glass);
    border-radius: 12px;
    padding: 1.5rem 1.5rem;
    min-width: 110px;
    text-align: center;
}

.time-val {
    display: block;
    font-family: var(--font-heading);
    font-size: 2.8rem;
    color: var(--primary);
    line-height: 1;
    margin-bottom: 0.5rem;
}

.time-label {
    font-size: 0.8rem;
    text-transform: uppercase;
    letter-spacing: 2px;
    color: var(--text-muted);
}


/* Details Section */
.details-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 2rem;
    margin-bottom: 1rem;
}

.detail-card {
    padding: 3rem 2rem;
    text-align: center;
}

.icon-wrapper {
    font-size: 2.5rem;
    color: var(--primary);
    margin-bottom: 1.5rem;
}

.detail-card h3 {
    font-size: 1.5rem;
    margin-bottom: 1.5rem;
    color: var(--text-main);
}

.large-detail {
    font-size: 1.3rem !important;
    color: var(--text-muted);
    margin-bottom: 0.8rem !important;
}

.highlight-text {
    font-size: 1.4rem !important;
    color: var(--text-main);
    font-weight: 600;
}

.card-actions {
    margin-top: 2.5rem;
}

/* Photo Share Section */
.photo-share-card {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 4rem;
    padding: 4rem;
    align-items: center;
}

.share-content {
    text-align: center;
}

.share-content p {
    color: var(--text-muted);
    margin-bottom: 2rem;
    font-size: 1.1rem;
}

.collage {
    position: relative;
    height: 350px;
}

.pic {
    position: absolute;
    border-radius: 12px;
    background-size: cover;
    background-position: center;
    box-shadow: 0 10px 30px rgba(0,0,0,0.1);
    border: 6px solid #fff;
    transition: transform 0.5s;
}

.pic1 {
    width: 60%;
    height: 70%;
    top: 0;
    left: 0;
    background-image: url('../img/photo1.jpg');
    z-index: 2;
    transform: rotate(-5deg);
}

.pic2 {
    width: 50%;
    height: 60%;
    bottom: 0;
    right: 10%;
    background-image: url('../img/photo2.jpg');
    z-index: 3;
    transform: rotate(5deg);
}

.pic3 {
    width: 45%;
    height: 55%;
    top: -10%;
    right: 0;
    background-image: url('../img/photo3.jpg');
    z-index: 1;
    transform: rotate(15deg);
}

.photo-share-card:hover .pic1 { transform: rotate(-8deg) scale(1.05); }
.photo-share-card:hover .pic2 { transform: rotate(8deg) scale(1.05); }
.photo-share-card:hover .pic3 { transform: rotate(18deg) scale(1.05); }


/* RSVP Form */
.rsvp-wrapper {
    max-width: 700px;
    margin: 0 auto;
    padding: 4rem;
}

.rsvp-desc {
    text-align: center;
    color: var(--text-muted);
    margin-bottom: 3rem;
}

.form-group {
    position: relative;
    margin-bottom: 2.5rem;
}

.form-group input[type="text"],
.form-group textarea,
.form-group select {
    width: 100%;
    padding: 1rem 0;
    background: transparent;
    border: none;
    border-bottom: 1px solid var(--border-glass);
    color: var(--text-main);
    font-size: 1rem;
    font-family: var(--font-body);
    transition: var(--transition);
}

.form-group input:focus,
.form-group textarea:focus,
.form-group select:focus {
    outline: none;
    border-bottom-color: var(--primary);
}

.form-group label {
    position: absolute;
    top: 1rem;
    left: 0;
    color: var(--text-muted);
    transition: var(--transition);
    pointer-events: none;
}

.form-group input:focus ~ label,
.form-group input:valid ~ label,
.form-group textarea:focus ~ label,
.form-group textarea:not(:placeholder-shown) ~ label {
    top: -1.2rem;
    font-size: 0.8rem;
    color: var(--primary);
}

/* Hide placeholders */
.form-group input::placeholder,
.form-group textarea::placeholder {
    color: transparent;
}

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

/* Select Styling */
.guest-group label {
    position: static;
    display: block;
    margin-bottom: 0.5rem;
    font-size: 0.9rem;
    color: var(--text-muted);
}

select option {
    background: #fff;
    color: var(--text-main);
}

/* Radio Buttons */
.radio-label {
    margin-bottom: 1rem;
    color: var(--text-muted);
}

.radio-group {
    display: flex;
    gap: 1rem;
}

.radio-group input[type="radio"] {
    display: none;
}

.radio-btn {
    flex: 1;
    position: static !important;
    text-align: center;
    padding: 1rem;
    border: 1px solid var(--border-glass);
    border-radius: 8px;
    cursor: pointer;
    color: var(--text-muted) !important;
    font-size: 1rem !important;
    pointer-events: auto !important;
    background: #fff;
    transition: var(--transition);
}

.radio-group input:checked + .radio-btn {
    background: rgba(148, 112, 64, 0.1);
    border-color: var(--primary);
    color: var(--primary) !important;
}

.submit-btn {
    width: 100%;
    justify-content: center;
    margin-top: 1rem;
}

.form-message {
    margin-top: 1.5rem;
    text-align: center;
    padding: 1rem;
    border-radius: 8px;
    display: none;
}

.form-message.success {
    display: block;
    background: rgba(46, 204, 113, 0.1);
    color: #2ecc71;
    border: 1px solid rgba(46, 204, 113, 0.2);
}

.form-message.error {
    display: block;
    background: rgba(231, 76, 60, 0.1);
    color: #e74c3c;
    border: 1px solid rgba(231, 76, 60, 0.2);
}

/* Footer */
footer {
    text-align: center;
    padding: 4rem 1.5rem 8rem;
    border-top: 1px solid var(--border-glass);
}

.footer-names {
    font-size: 2rem;
    color: var(--primary);
    margin-bottom: 0.5rem;
}

.footer-credit {
    margin-top: 2rem;
    font-size: 0.85rem;
    color: var(--text-muted);
}

.footer-credit a {
    color: var(--primary);
    text-decoration: none;
    font-weight: 500;
}

.footer-credit a:hover {
    text-decoration: underline;
}

/* Animations */
.scroll-element {
    opacity: 0;
    transform: translateY(30px);
    transition: opacity 0.8s ease-out, transform 0.8s ease-out;
}

.scroll-element.scrolled {
    opacity: 1;
    transform: translateY(0);
}

.delay-1 { transition-delay: 0.2s; }

.fade-up {
    animation: fadeUpAnim 1s ease-out forwards;
}

@keyframes fadeUpAnim {
    from { opacity: 0; transform: translateY(30px); }
    to { opacity: 1; transform: translateY(0); }
}

/* Responsive */
@media (max-width: 768px) {
    .glass-nav {
        display: none;
    }
    
    .photo-share-card {
        grid-template-columns: 1fr;
        padding: 2rem;
        gap: 2.5rem;
    }
    
    .collage {
        height: 250px;
    }
    
    .rsvp-wrapper {
        padding: 2rem 1.5rem;
    }
    
    .radio-group {
        flex-direction: column;
    }
    
    .names {
        font-size: 3.5rem;
    }
}
