/* Base Styles */
:root {
    --color-primary: #fff9f9;
    --color-secondary: #f8e3e3;
    --color-accent: #d4af37;
    --color-text: #333;
    --color-light-text: #555;
    --color-background: #fff;
    --font-primary: 'Lora', serif;
    --font-secondary: 'Playfair Display', serif;
    --font-accent: 'Great Vibes', cursive;
    --animation-duration: 1s;
    scroll-behavior: smooth;
}

/* Animation Keyframes */
@keyframes fadeIn {
    from { opacity: 0; transform: translateY(20px); }
    to { opacity: 1; transform: translateY(0); }
}

@keyframes slideInLeft {
    from { opacity: 0; transform: translateX(-30px); }
    to { opacity: 1; transform: translateX(0); }
}

@keyframes slideInRight {
    from { opacity: 0; transform: translateX(30px); }
    to { opacity: 1; transform: translateX(0); }
}

@keyframes pulse {
    0% { transform: scale(1); }
    50% { transform: scale(1.05); }
    100% { transform: scale(1); }
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: var(--font-primary);
    color: var(--color-text);
    background-color: var(--color-primary);
    line-height: 1.6;
    opacity: 0;
    transition: opacity 0.8s ease;
}

html.no-animations *,
body.preload * {
    -webkit-animation: none !important;
    -moz-animation: none !important;
    -ms-animation: none !important;
    animation: none !important;
    -webkit-transition: none !important;
    -moz-transition: none !important;
    -ms-transition: none !important;
    transition: background-color 0.5s ease !important;
    scroll-behavior: auto !important;
}

body.loaded {
    opacity: 1;
}

h1, h2, h3 {
    font-family: var(--font-accent);
    color: var(--color-text);
    text-align: center;
    margin-bottom: 1rem;
}

h1 {
    font-size: 2.5rem;
}

h2 {
    font-size: 2rem;
}

h3 {
    font-size: 1.8rem;
    font-family: var(--font-secondary);
    font-weight: 500;
}

p {
    margin-bottom: 1rem;
    text-align: center;
}

img {
    max-width: 100%;
    height: auto;
    display: block;
}

section {
    padding: 2rem 1rem;
    margin-bottom: 2rem;
    background-color: var(--color-background);
    border-radius: 8px;
}

/* Language Selector */
.language-selector {
    position: fixed;
    top: 20px;
    right: 20px;
    z-index: 100;
    display: flex;
    gap: 5px;
}

.lang-btn {
    background-color: var(--color-background);
    border: 1px solid var(--color-accent);
    color: var(--color-accent);
    font-family: var(--font-primary);
    font-size: 0.8rem;
    padding: 5px 10px;
    border-radius: 4px;
    cursor: pointer;
    transition: all 0.3s ease;
}

.lang-btn:hover, .lang-btn.active {
    background-color: var(--color-accent);
    color: var(--color-background);
}

/* Back Button - Estilo do site principal */
.back-button {
    position: fixed;
    bottom: 30px;
    left: 30px;
    z-index: 1000;
    display: flex;
    align-items: center;
    gap: 8px;
    background-color: #E63946; /* cor accent do site principal */
    color: #ffffff;
    padding: 12px 20px;
    border-radius: 50px;
    text-decoration: none;
    font-weight: 600;
    font-size: 0.9rem;
    box-shadow: 0 4px 15px rgba(230, 57, 70, 0.3);
    transition: all 0.3s ease;
    opacity: 0;
    transform: translateY(20px);
    pointer-events: none;
}

.back-button.visible {
    opacity: 1;
    transform: translateY(0);
    pointer-events: auto;
}

.back-button:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(230, 57, 70, 0.4);
    background-color: #d32f3f;
}

.back-button svg {
    transition: transform 0.3s ease;
}

.back-button:hover svg {
    transform: translateX(-3px);
}

/* Responsivo para mobile */
@media (max-width: 768px) {
    .back-button {
        bottom: 20px;
        left: 20px;
        padding: 10px 16px;
        font-size: 0.8rem;
    }
    
    .back-button svg {
        width: 20px;
        height: 20px;
    }
}

/* Header Section */
.hero {
    position: relative;
    height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
    margin-bottom: 2rem;

}

.hero-image {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.hero-overlay {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(255, 255, 255, 0.6);
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    padding: 2rem;
    text-align: center;
}

.invitation-title {
    padding-top: 10rem;
    color: var(--color-text);
    font-size: 2.5rem;
    line-height: 1;
    animation: fadeIn calc(var(--animation-duration) * 1.2) ease-out;
}

.invitation-names {
    margin-top: -1rem;
    font-family: var(--font-secondary);
    font-size: 1.5rem;
    color: var(--color-text);
    font-weight: 500;
    animation: fadeIn calc(var(--animation-duration) * 1.5) ease-out;
}

/* Date and Location Section */
.date-location {
    text-align: center;
    padding: 3rem 1rem;
    background-color: var(--color-secondary);
}

.wedding-date {
    font-size: 2.2rem;
    color: var(--color-text);
    margin-bottom: 1rem;
    animation: slideInLeft var(--animation-duration) ease-out;
}

.wedding-location {
    font-family: var(--font-secondary);
    font-size: 1.3rem;
    color: var(--color-light-text);
    animation: slideInRight var(--animation-duration) ease-out;
}

/* Countdown Section */
.countdown-section {
    text-align: center;
    padding: 2rem 1rem;
}

.countdown-section h3 {
    animation: fadeIn var(--animation-duration) ease-out;
}

.countdown-timer {
    display: flex;
    justify-content: center;
    gap: 15px;
    margin: 2rem 0;
    animation: fadeIn calc(var(--animation-duration) * 1.2) ease-out;
}

.countdown-item {
    display: flex;
    flex-direction: column;
    align-items: center;
    min-width: 60px;
}

.countdown-item span:first-child {
    font-size: 2rem;
    font-family: var(--font-secondary);
    color: var(--color-accent);
    font-weight: 600;
}

.countdown-label {
    font-size: 0.9rem;
    color: var(--color-light-text);
    text-transform: uppercase;
}

.section-image {
    margin: 2rem auto;
    border-radius: 8px;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.1);
    max-height: 660px;
    object-fit: cover;
    width: 100%;
    animation: fadeIn var(--animation-duration) ease-out;
    overflow: visible;
}

.countdown-section .section-image,
.info-section .section-image {
    margin: 2rem -1rem;
    width: calc(100% + 2rem);
    max-width: none;
    border-radius: 0;
    max-height: 400px;
    object-fit: cover;
    object-position: 50% 20%;
}

/* Parallax Wrapper - responsivo para mobile e desktop */
.parallax-wrapper {
    position: relative;
    overflow: hidden;
    margin: 2rem -1rem;
    width: calc(100% + 2rem);
    height: 300px; /* altura fixa para mobile */
    background-color: var(--color-secondary);
}

.parallax-image {
    position: absolute;
    top: -20%;
    left: 0;
    width: 100%;
    height: 140%; /* muito maior para permitir movimento sem mostrar fundo */
    object-fit: cover;
    object-position: 50% 20%;
    will-change: transform;
    transition: transform 0.1s ease-out;
    margin: 0;
    max-height: none;
    border-radius: 0;
    box-shadow: none;
}

/* Reception & Accommodation Sections */
.reception-section, .accommodation-section {
    background-color: var(--color-secondary);
    padding: 2rem 1rem;
    text-align: center;
}

/* Info Section */
.info-section {
    text-align: center;
    padding: 2rem 1rem;
}

.info-link {
    display: inline-block;
    margin: 1rem 0;
    color: var(--color-accent);
    text-decoration: none;
    font-weight: 500;
    border-bottom: 1px solid var(--color-accent);
    padding-bottom: 2px;
    transition: all 0.3s ease;
}

.info-link:hover {
    color: var(--color-text);
    border-bottom-color: var(--color-text);
}

/* RSVP Section */
.rsvp-section {
    background-color: var(--color-secondary);
    padding: 2rem 1rem;
    text-align: center;
    transition: background-color 0.5s ease;
    position: relative;
    overflow: hidden;
}

.rsvp-section::after {
    content: "";
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 5px;
    background: linear-gradient(90deg, transparent, transparent);
    transform: scaleX(0);
    transform-origin: left;
    transition: transform 0.6s ease, background 0.6s ease;
}

.rsvp-section.accept-selected {
    background-color: rgba(232, 245, 233, 0.3);
}

.rsvp-section.accept-selected::after {
    background: linear-gradient(90deg, #4CAF50, var(--color-accent));
    transform: scaleX(1);
}

.rsvp-section.decline-selected {
    background-color: rgba(255, 235, 238, 0.3);
}

.rsvp-section.decline-selected::after {
    background: linear-gradient(90deg, #F44336, var(--color-accent));
    transform: scaleX(1);
}

.rsvp-question {
    font-size: 1.3rem;
    margin: 2rem 0 1.5rem;
    font-family: var(--font-secondary);
    font-weight: 500;
    animation: fadeIn var(--animation-duration) ease-out;
    color: var(--color-text);
    position: relative;
    display: inline-block;
}

.rsvp-question::after {
    content: '';
    position: absolute;
    width: 50%;
    height: 2px;
    background: var(--color-accent);
    bottom: -8px;
    left: 25%;
    transition: width 0.3s ease;
}

.rsvp-options {
    display: flex;
    justify-content: center;
    gap: 2rem;
    margin-bottom: 2rem;
    animation: fadeIn calc(var(--animation-duration) * 1.2) ease-out;
}

.rsvp-option {
    display: flex;
    flex-direction: column;
    align-items: center;
    cursor: pointer;
    transition: all 0.3s ease;
    padding: 1.5rem;
    border-radius: 12px;
    border: 2px solid transparent;
    min-width: 150px;
    position: relative;
    overflow: hidden;
}

.rsvp-option:hover {
    transform: translateY(-5px);
    background-color: rgba(255, 255, 255, 0.5);
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.08);
}

.rsvp-option.active {
    border: 2px solid var(--color-accent);
    background-color: rgba(255, 255, 255, 0.7);
    box-shadow: 0 5px 20px rgba(212, 175, 55, 0.25);
    transform: translateY(-5px);
}

.rsvp-option.active::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 4px;
    height: 100%;
    background-color: var(--color-accent);
}

.rsvp-option.active.accept {
    background-color: rgba(232, 245, 233, 0.8);
    border-color: #4CAF50;
}

.rsvp-option.active.accept::before {
    background-color: #4CAF50;
}

.rsvp-option.active.decline {
    background-color: rgba(255, 235, 238, 0.8);
    border-color: #F44336;
}

.rsvp-option.active.decline::before {
    background-color: #F44336;
}

.emoji {
    font-size: 2.5rem;
    margin-bottom: 0.8rem;
    transition: transform 0.3s ease;
}

.rsvp-option.active .emoji {
    transform: scale(1.2);
}

/* Decline Message Styles */
.decline-message {
    max-width: 600px;
    margin: 1.5rem auto 0;
    text-align: center;
    opacity: 0;
    transform: translateY(20px);
    transition: opacity 0.5s ease, transform 0.5s ease;
    padding: 1.5rem;
    border-radius: 10px;
    background-color: rgba(255, 235, 238, 0.3);
    border-left: 4px solid #F44336;
    box-shadow: 0 5px 15px rgba(244, 67, 54, 0.1);
}

.decline-message.message-visible {
    opacity: 1;
    transform: translateY(0);
}

.decline-message p {
    color: #333;
    font-size: 1.1rem;
    line-height: 1.6;
    font-style: italic;
}

/* Form Styles */
.rsvp-form {
    max-width: 600px;
    margin: 1.5rem auto 0;
    text-align: left;
    opacity: 0;
    transform: translateY(20px);
    transition: opacity 0.5s ease, transform 0.5s ease;
    padding: 1.5rem;
    border-radius: 10px;
    background-color: rgba(255, 255, 255, 0.7);

}

.rsvp-form.form-visible {
    opacity: 1;
    transform: translateY(0);
}

.form-group {
    margin-bottom: 1.5rem;
}

label {
    display: block;
    margin-bottom: 0.5rem;
    font-weight: 500;
}

input[type="text"],
input[type="number"],
textarea {
    width: 100%;
    padding: 10px;
    border: 1px solid #ddd;
    border-radius: 4px;
    font-family: var(--font-primary);
}

.checkbox-group, .radio-group {
    display: flex;
    align-items: center;
    margin-bottom: 0.5rem;
}

.checkbox-group input, .radio-group input {
    margin-right: 10px;
}

.hidden {
    display: none;
}

.submit-btn {
    background-color: var(--color-accent);
    color: white;
    border: none;
    padding: 12px 30px;
    font-size: 1.1rem;
    border-radius: 4px;
    cursor: pointer;
    transition: all 0.3s ease;
    font-family: var(--font-secondary);
    margin-top: 1rem;
    position: relative;
    overflow: hidden;
}

.submit-btn:hover {
    background-color: #c6a22e;
    transform: translateY(-2px);
    box-shadow: 0 5px 15px rgba(212, 175, 55, 0.25);
}

.submit-btn:before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(
        90deg,
        rgba(255, 255, 255, 0.2),
        rgba(255, 255, 255, 0)
    );
    transition: left 0.7s ease;
}

.submit-btn:hover:before {
    left: 100%;
}

/* Map Section */
.map-section {
    padding: 2rem 1rem;
    text-align: center;
}

.google-map {
    border-radius: 8px;
    overflow: hidden;
    margin-top: 1rem;
}

/* Final Message Section */
.final-section {
    position: relative;
    height: 50vh;
    margin-bottom: 0;
    padding: 0;
    border-radius: 0;
    box-shadow: none;
}

.final-image {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.final-overlay {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(255, 255, 255, 0.7);
    display: flex;
    justify-content: center;
    align-items: center;
    padding: 2rem;
}

.final-message {
    font-family: var(--font-accent);
    font-size: 1.8rem;
    color: var(--color-text);
    text-align: center;
    max-width: 600px;
    line-height: 1.4;
    animation: pulse 3s infinite;
}

/* Footer */
.footer {
    background-color: var(--color-secondary);
    padding: 1rem;
    text-align: center;
    color: var(--color-light-text);
    font-size: 0.9rem;
}

/* Scroll Animation Classes */
.no-animations * {
    transition: none !important;
    animation: none !important;
}

.fade-in-element {
    opacity: 0 !important;
    transform: translateY(20px) !important;
    transition: opacity 0.8s cubic-bezier(0.215, 0.61, 0.355, 1), transform 0.8s cubic-bezier(0.215, 0.61, 0.355, 1) !important;
    will-change: opacity, transform;
    transition-delay: 0.1s !important;
    visibility: hidden;
    pointer-events: none;
}

.fade-in-element.visible {
    opacity: 1 !important;
    transform: translateY(0) !important;
    visibility: visible;
    pointer-events: auto;
}

/* Reset for scrolled state - only apply after animations have run */
html.scrolled .fade-in-element:not(.visible) {
    opacity: 0 !important;
}

/* Media Queries */
@media (min-width: 768px) {
    h1 {
        font-size: 3.5rem;
    }
    
    h2 {
        font-size: 2.8rem;
    }
    
    h3 {
        font-size: 2.2rem;
    }
    
    section {
        padding: 3rem 2rem;
    }
    
    .invitation-title {
        font-size: 3.5rem;
        padding-top: 10rem;
    }
    
    .invitation-names {
        font-size: 2rem;
    }
    
    .countdown-item {
        min-width: 80px;
    }
    
    .countdown-item span:first-child {
        font-size: 3rem;
    }
    
    .countdown-label {
        font-size: 1rem;
    }
    
    .final-message {
        font-size: 2.5rem;
    }
}

@media (min-width: 900px) {
    h1 {
        font-size: 3.5rem;
    }
    
    h2 {
        font-size: 2.8rem;
    }
    
    h3 {
        font-size: 2.2rem;
    }
    
    section {
        padding: 3rem 2rem;
    }
    
    .invitation-title {
        font-size: 3.5rem;
        padding-top: 10rem;
    }
    
    .invitation-names {
        font-size: 2rem;
    }
    
    .countdown-item {
        min-width: 80px;
    }
    
    .countdown-item span:first-child {
        font-size: 3rem;
    }
    
    .countdown-label {
        font-size: 1rem;
    }
    
    .final-message {
        font-size: 2.5rem;
    }
    
    .hero-image {
        object-position: center;
    }
    
    .section-image {
        max-width: 100%;  
    }
    
    .countdown-section .section-image,
    .info-section .section-image {
        width: 100vw;
        max-width: 100vw;
        margin-left: calc(-50vw + 50%);
        margin-right: calc(-50vw + 50%);
        max-height: 500px;
    }
    
    .rsvp-form {
        padding: 2rem 2rem;
    }
    
    /* Parallax para tablet e desktop - efeito similar */
    .parallax-wrapper {
        height: 550px;
        width: 100vw;
        margin-left: calc(-50vw + 50%);
        margin-right: calc(-50vw + 50%);
        margin-top: 4rem;
        margin-bottom: 4rem;
        border-radius: 0;
    }
    
    .parallax-image {
        height: 100%; /* mais espaço para movimento */
        top: -25%;
    }
}

