:root {
    --primary-color: #fff8e7;
    --card-color: #ffffff;
    --secondary-color: #e6c88e;
    --text-color: #4a3c2a;
    --accent-color: #c4a35a;
    --background-color: #f9f7f5;
}

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

/* Improve touch interactions on mobile */
@media (hover: none) and (pointer: coarse) {
    .button,
    .carousel-btn,
    .dot,
    /* .pix-code-box {
        min-height: 44px;
        min-width: 44px;
    } */
    
    .carousel-btn {
        opacity: 0.9;
    }
    
    .carousel-btn:active {
        transform: translateY(-50%) scale(0.95);
    }
    
    .button:active {
        transform: scale(0.98);
    }
    
    /* Better tap targets for mobile */
    .dot {
        height: 10px;
        width: 10px;
        margin: 0 6px;
    }
    
    /* Prevent text selection on interactive elements */
    .button,
    .carousel-btn,
    .dot,
    .close {
        -webkit-user-select: none;
        -moz-user-select: none;
        -ms-user-select: none;
        user-select: none;
        -webkit-tap-highlight-color: transparent;
    }
}

body {
    font-family: 'Montserrat', sans-serif;
    line-height: 1.6;
    color: var(--text-color);
    background-color: var(--background-color);
    -webkit-text-size-adjust: 100%;
    -ms-text-size-adjust: 100%;
    -webkit-overflow-scrolling: touch;
    scroll-behavior: smooth;
}

h1, h2, h3 {
    font-family: 'Playfair Display', serif;
    color: var(--accent-color);
}

.hero {
    height: 100vh;
    background: linear-gradient(rgba(98, 36, 255, 0.0), rgba(0, 0, 0, 0.0)),
                url('/static/images/chez_bisutti_claro_water_color.PNG') center/cover;
    display: flex;
    align-items: center;
    justify-content: center;
    text-align: center;
    color: white;
}

.hero-content {
    padding: 2rem;
}

.hero h1 {
    font-size: 4rem;
    margin-bottom: 1rem;
    color: white;
    text-shadow: 0 2px 0 rgba(0, 0, 0, 0.25);
}

.date {
    font-size: 2.0rem;
    font-family: 'Playfair Display', serif;
    text-shadow: 0 2px 0 rgba(0, 0, 0, 0.25);
}

main {
    max-width: 50%;
    margin: 0 auto;
    padding: 5rem 2rem;
}

.couple-story {
    max-width: 50%;
    margin: 0 auto;
    padding: 5rem 2rem;
    text-align: justify;
    background-color: var(--background-color);
}

.couple-story .container {
    max-width: 100%;
}

.couple-story p {
    font-size: 1.1rem;
    line-height: 1.8;
    color: var(--text-color);
    margin-top: 1rem;
    padding: 0 1.5rem;
}

.photo-gallery {
    max-width: 80%;
    margin: 0 auto;
    padding: 5rem 2rem;
    text-align: center;
    background-color: var(--background-color);
}

.carousel-container {
    position: relative;
    max-width: 800px;
    margin: 2rem auto;
}

.carousel-wrapper {
    position: relative;
    overflow: hidden;
    border-radius: 15px;
    /* box-shadow: 0 8px 30px rgba(0, 0, 0, 0.2); */
    touch-action: pan-y pinch-zoom;
}

.carousel-slides {
    position: relative;
    width: 100%;
    height: 500px;
}

.carousel-slide {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    opacity: 0;
    transition: opacity 0.5s ease-in-out;
}

.carousel-slide.active {
    opacity: 1;
}

.carousel-slide img {
    width: 100%;
    height: 100%;
    object-fit: contain;
    border-radius: 15px;
}

.carousel-btn {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    background-color: rgba(255, 255, 255, 0.8);
    border: none;
    font-size: 1.5rem;
    padding: 1rem;
    cursor: pointer;
    border-radius: 50%;
    transition: all 0.3s ease;
    z-index: 10;
    color: var(--text-color);
    width: 50px;
    height: 50px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.carousel-btn:hover {
    background-color: rgba(255, 255, 255, 0.95);
    transform: translateY(-50%) scale(1.1);
}

.carousel-prev {
    left: 20px;
}

.carousel-next {
    right: 20px;
}

.carousel-dots {
    text-align: center;
    margin-top: 1.5rem;
}

.dot {
    height: 12px;
    width: 12px;
    margin: 0 5px;
    background-color: rgba(196, 163, 90, 0.4);
    border-radius: 50%;
    display: inline-block;
    cursor: pointer;
    transition: all 0.3s ease;
}

.dot.active {
    background-color: var(--accent-color);
    transform: scale(1.2);
}

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

section {
    margin-bottom: 0rem;
}

h2 {
    font-size: 2.5rem;
    text-align: center;
    margin-bottom: 2rem;
    position: relative;
}

h2::after {
    content: '';
    display: block;
    width: 50px;
    height: 2px;
    background-color: var(--secondary-color);
    margin: 1rem auto;
}

.details h2 {
    margin-bottom: 0;
}

.details p {
    padding: 0 1.5rem;
    font-size: 1.1rem;
}

.venue-info h3 {
    color: var(--text-color);
}

.venue-info, .hotel-info {
    text-align: center;
    padding: 2rem 0;
    padding-top: 0;
    /* background-color: var(--primary-color); */
    border-radius: 10px;
    margin-bottom: 2rem;
}

.hotel-info p{
    margin-bottom: 0.5rem;
    text-align: justify;
}

.hotel-info h3 {
    color: var(--text-color);
    /* font-weight: 400; */
    font-size: 1.1rem;
}

.hotel-image {
    width: 100%;
    max-width: 500px;
    height: 250px;
    object-fit: cover;
    border-radius: 10px;
    margin: 1rem 0;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.1);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.hotel-image:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 25px rgba(0, 0, 0, 0.15);
}

.activities, .gifts {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 2rem;
}

@media (max-width: 600px) {
    .activities, .gifts {
        grid-template-columns: 1fr;
        gap: 1.5rem;
    }
}

.activity-card, .gift-card {
    background-color: var(--card-color);
    padding: 1.5rem;
    border-radius: 10px;
    text-align: center;
}

.distance, .price {
    color: var(--accent-color);
    font-weight: 500;
    margin-top: 0.5rem;
}

.button {
    display: inline-block;
    padding: 0.8rem 1.5rem;
    background-color: var(--accent-color);
    color: white;
    text-decoration: none;
    border-radius: 5px;
    transition: background-color 0.3s;
    border: 0;
}

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

.rsvp-form {
    max-width: 600px;
    margin: 0 auto;
    padding: 2rem;
    background-color: var(--card-color);
    border-radius: 10px;
}

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

label {
    display: block;
    margin-bottom: 0.5rem;
    font-weight: 500;
}

input[type="text"],
input[type="email"],
input[type="number"],
textarea {
    width: 100%;
    padding: 0.8rem;
    border: 1px solid var(--secondary-color);
    border-radius: 5px;
    font-family: 'Montserrat', sans-serif;
    font-size: 16px; /* Prevents zoom on iOS */
    -webkit-appearance: none;
    -moz-appearance: none;
    appearance: none;
}

input[type="text"]:focus,
input[type="email"]:focus,
input[type="number"]:focus,
textarea:focus {
    outline: none;
    border-color: var(--accent-color);
    box-shadow: 0 0 0 2px rgba(196, 163, 90, 0.2);
}

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

.radio-group label {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    font-weight: normal;
}

.success-message {
    background-color: #d4edda;
    color: #155724;
    padding: 1rem;
    border-radius: 5px;
    margin-bottom: 1rem;
    text-align: center;
}

footer {
    text-align: center;
    padding: 2rem;
    background-color: var(--primary-color);
    margin-top: 5rem;
}

.countdown-container {
    background: linear-gradient(135deg, rgba(246, 241, 230, 0.95) 0%, rgba(220, 207, 178, 0.95) 100%);
    padding: 5rem 2rem;
    text-align: center;
    margin-bottom: 2rem;
    position: relative;
    overflow: hidden;
}

/* .countdown-container::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: url('data:image/svg+xml,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 1000 100" fill="%23ffffff" opacity="0.1"><polygon points="0,0 1000,0 1000,100 0,50"/></svg>') repeat-x;
    pointer-events: none;
} */

.countdown-container h2 {
    font-size: 2.5rem;
    margin-bottom: 2rem;
    background: linear-gradient(135deg, #c4a35a 0%, #8b7355 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    text-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
    position: relative;
    z-index: 1;
}

.countdown {
    display: flex;
    justify-content: center;
    gap: 3rem;
    max-width: 900px;
    margin: 0 auto;
    position: relative;
    z-index: 1;
}

.countdown-item {
    display: flex;
    flex-direction: column;
    align-items: center;
    background: linear-gradient(145deg, #ffffff 0%, #f8f8f8 100%);
    padding: 1.5rem 1.5rem;
    border-radius: 20px;
    box-shadow: 
        0 20px 40px rgba(196, 163, 90, 0.15),
        0 8px 16px rgba(0, 0, 0, 0.1),
        inset 0 1px 0 rgba(255, 255, 255, 0.8);
    position: relative;
    border: 1px solid rgba(196, 163, 90, 0.2);
    min-width: 120px;
}

.countdown-item span:first-child {
    font-family: 'Playfair Display', serif;
    font-size: 2.5rem;
    font-weight: 700;
    /* background: linear-gradient(135deg, #c4a35a 0%, #8b7355 50%, #c4a35a 100%); */
    /* -webkit-background-clip: text; */
    /* -webkit-text-fill-color: transparent; */
    background-clip: text;
    line-height: 1;
    margin-bottom: 0.5rem;
    /* text-shadow: 0 2px 4px rgba(0, 0, 0, 0.1); */
    display: block;
    position: relative;
    color: var(--accent-color);
}

.countdown-label {
    font-family: 'Montserrat', sans-serif;
    font-size: 0.9rem;
    color: #8b7355;
    text-transform: uppercase;
    letter-spacing: 2px;
    font-weight: 500;
    position: relative;
}

/* .countdown-label::after {
    content: '';
    position: absolute;
    bottom: -8px;
    left: 50%;
    transform: translateX(-50%);
    width: 30px;
    height: 2px;
    background: linear-gradient(135deg, #c4a35a, #8b7355);
    border-radius: 1px;
} */

.map-container {
    margin-top: 2rem;
    border-radius: 10px;
    overflow: hidden;
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
}

.map-container iframe {
    display: block;
    width: 100%;
    height: 450px;
    border: none;
}

/* Schedule Section Styles */
.schedule {
    padding: 0rem 2rem;
    /* background-color: #fafafa; */
}

.schedule p {
    font-size: 1.1rem;
    padding: 0 1.5rem;
}

.timeline {
    max-width: 800px;
    margin: 2rem auto;
    position: relative;
}

.timeline::before {
    content: '';
    position: absolute;
    left: 50%;
    transform: translateX(-50%);
    width: 2px;
    height: 100%;
    background-color: #e0e0e0;
}

.timeline-item {
    display: flex;
    justify-content: center;
    align-items: center;
    margin-bottom: 2rem;
    position: relative;
}

.timeline-item:last-child {
    margin-bottom: 0;
}

.time {
    background-color: #fff;
    padding: 0.5rem 1rem;
    border-radius: 20px;
    box-shadow: 0 2px 4px rgba(0,0,0,0.1);
    font-weight: 500;
    color: #333;
    margin: 0 1rem;
    min-width: 80px;
    text-align: center;
}

.event {
    background-color: #fff;
    padding: 1.5rem;
    border-radius: 8px;
    box-shadow: 0 2px 4px rgba(0,0,0,0.1);
    flex: 1;
    max-width: 400px;
}

.event h3 {
    margin: 0 0 0.5rem 0;
    color: #333;
    font-family: 'Playfair Display', serif;
}

.event p {
    margin: 0;
    color: #666;
}

/* Tablet styles */
@media (max-width: 1024px) {
    main {
        max-width: 70%;
        padding: 4rem 2rem;
    }
    
    .couple-story {
        max-width: 70%;
        padding: 4rem 2rem;
    }
    
    .photo-gallery {
        max-width: 90%;
        padding: 4rem 2rem;
    }
    
    .schedule {
        padding: 0rem 2rem;
    }
    
    .countdown-container {
        padding: 4rem 2rem;
        margin-bottom: 2rem;
    }
    
    section {
        margin-bottom: 0rem;
    }
    
    .hero h1 {
        font-size: 3.5rem;
    }
    
    .countdown-item {
        min-width: 110px;
        padding: 1.5rem 1.2rem;
    }
}

/* Mobile styles */
@media (max-width: 768px) {
    .hero {
        height: 100vh;
        min-height: 600px;
    }
    
    .hero h1 {
        font-size: 2.5rem;
        line-height: 1.2;
        margin-bottom: 1rem;
    }
    
    .date {
        font-size: 2.0rem;
    }
    
    .hero-content {
        padding: 1rem;
    }
    
    main {
        max-width: 95%;
        padding: 3rem 1rem;
    }
    
    .couple-story {
        max-width: 95%;
        padding: 3rem 1rem;
    }
    
    .photo-gallery {
        max-width: 95%;
        padding: 3rem 1rem;
    }
    
    .schedule {
        padding: 0rem 1rem;
    }
    
    .countdown-container {
        padding: 3rem 1rem;
        margin-bottom: 2rem;
    }
    
    h2 {
        font-size: 2rem;
        margin-bottom: 1.5rem;
    }
    
    section {
        margin-bottom: 0rem;
    }
    
    .venue-info, .hotel-info {
        padding: 1.5rem 1rem;
        margin-bottom: 1.5rem;
    }

    .hotel-image {
        height: 200px;
        max-width: 100%;
    }
    
    .activities, .gifts {
        grid-template-columns: 1fr;
        gap: 1.5rem;
    }
    
    .activity-card, .gift-card {
        padding: 1.5rem;
    }
    
    .carousel-container {
        max-width: 95%;
        margin: 1.5rem auto;
    }
    
    .carousel-slides {
        height: 250px;
    }
    
    .carousel-slide img {
        height: 250px;
        object-fit: contain;
    }
    
    .carousel-btn {
        width: 40px;
        height: 40px;
        font-size: 1.2rem;
        padding: 0.5rem;
    }
    
    .carousel-prev {
        left: 10px;
    }
    
    .carousel-next {
        right: 10px;
    }
    
    .dot {
        height: 10px;
        width: 10px;
        margin: 0 5px;
    }
    
    .countdown {
        gap: 1rem;
        flex-wrap: wrap;
        justify-content: center;
    }
    
    .countdown-container {
        padding: 2rem 1rem;
    }
    
    .countdown-container h2 {
        font-size: 2rem;
        margin-bottom: 1.5rem;
    }
    
    .countdown-item {
        padding: 1rem 0.8rem;
        min-width: 80px;
        flex: 1;
        max-width: 120px;
    }
    
    .countdown-item span:first-child {
        font-size: 2rem;
    }
    
    .countdown-label {
        font-size: 0.7rem;
        letter-spacing: 1px;
    }
    
    .map-container iframe {
        height: 300px;
    }
    
    .timeline::before {
        left: 30px;
    }
    
    .timeline-item {
        flex-direction: column;
        align-items: flex-start;
        padding-left: 60px;
        margin-bottom: 1.5rem;
    }
    
    .time {
        margin-bottom: 0.5rem;
        margin-left: -30px;
    }
    
    .event {
        width: 100%;
        padding: 1rem;
    }
    
    .rsvp-form {
        padding: 1.5rem;
        margin: 0 1rem;
    }

    .modal-content {
        margin: 10% auto;
        width: 95%;
        padding: 1.5rem;
    }

    #qrCodeImage {
        max-width: 200px;
        max-height: 200px;
    }

    .pix-code-box {
        font-size: 0.8rem;
        padding: 0.8rem;
    }
    
    footer {
        padding: 2rem 1rem;
    }

    .hotel-info h3 {
        text-align: left;
    }
}

/* Small mobile styles */
@media (max-width: 480px) {
    .accommodations a {
        margin-top: 1rem;
    }

    .hero h1 {
        font-size: 2rem;
        line-height: 1.1;
    }
    
    .date {
        font-size: 1.5rem;
    }
    
    .hero-content {
        padding: 0.5rem;
    }
    
    main, .couple-story, .photo-gallery {
        max-width: 100%;
        padding: 1.5rem 0.5rem;
    }
    
    h2 {
        font-size: 1.8rem;
        margin-bottom: 1rem;
    }
    
    .venue-info, .hotel-info {
        padding: 1rem 0.5rem;
    }

    .hotel-image {
        height: 180px;
        margin: 0.5rem 0;
    }
    
    .activity-card, .gift-card {
        padding: 1rem;
    }
    
    .carousel-slides {
        height: 200px;
    }
    
    .carousel-slide img {
        height: 200px;
        object-fit: contain;
    }
    
    .carousel-btn {
        width: 35px;
        height: 35px;
        font-size: 1rem;
    }
    
    .carousel-prev {
        left: 5px;
    }
    
    .carousel-next {
        right: 5px;
    }
    
    .dot {
        height: 8px;
        width: 8px;
        margin: 0 4px;
    }
    
    .countdown-container {
        padding: 1.5rem 0.5rem;
    }
    
    .countdown-container h2 {
        font-size: 1.8rem;
        margin-bottom: 1rem;
    }
    
    .countdown {
        gap: 0.5rem;
    }
    
    .countdown-item {
        padding: 0.8rem 0.5rem;
        min-width: 70px;
        max-width: 100px;
    }
    
    .countdown-item span:first-child {
        font-size: 1.8rem;
    }
    
    .countdown-label {
        font-size: 0.6rem;
        letter-spacing: 0.5px;
    }
    
    .timeline-item {
        padding-left: 50px;
    }
    
    .time {
        margin-left: -20px;
        font-size: 0.9rem;
        padding: 0.4rem 0.8rem;
    }
    
    .event {
        padding: 0.8rem;
    }
    
    .event h3 {
        font-size: 1.1rem;
    }
    
    .event p {
        font-size: 0.9rem;
    }
    
    .rsvp-form {
        padding: 1rem;
        margin: 0 0.5rem;
    }
    
    .form-group {
        margin-bottom: 1rem;
    }
    
    input[type="text"],
    input[type="email"],
    input[type="number"],
    textarea {
        padding: 0.6rem;
        font-size: 1rem;
    }
    
    .button {
        padding: 0.7rem 1.2rem;
        font-size: 0.9rem;
    }
    
    .modal-content {
        margin: 5% auto;
        width: 98%;
        padding: 1rem;
    }
    
    #qrCodeImage {
        max-width: 180px;
        max-height: 180px;
    }
    
    .close {
        font-size: 1.5rem;
        right: 0.5rem;
        top: 0.5rem;
    }

    .hotel-info h3 {
        text-align: left;
    }
}

.presentear-btn {
    margin-top: 1rem;
    width: 100%;
    cursor: pointer;
}

/* Modal Styles */
.modal {
    display: none;
    position: fixed;
    z-index: 1000;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    overflow: auto;
    background-color: rgba(0, 0, 0, 0.5);
    backdrop-filter: blur(5px);
}

.modal-content {
    background-color: var(--card-color);
    margin: 5% auto;
    padding: 2rem;
    border-radius: 15px;
    width: 90%;
    max-width: 500px;
    position: relative;
    text-align: center;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.3);
    animation: modalSlideIn 0.3s ease-out;
}

@keyframes modalSlideIn {
    from {
        opacity: 0;
        transform: translateY(-50px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.close {
    color: var(--text-color);
    float: right;
    font-size: 2rem;
    font-weight: bold;
    cursor: pointer;
    position: absolute;
    right: 1rem;
    top: 1rem;
    transition: color 0.3s;
}

.close:hover {
    color: var(--accent-color);
}

#qrCodeContainer {
    margin: 2rem 0;
    display: flex;
    justify-content: center;
}

#qrCodeImage {
    max-width: 250px;
    max-height: 250px;
    border-radius: 10px;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.1);
}

.pix-code-container {
    margin-top: 2rem;
}

.pix-code-container p {
    font-weight: 500;
    margin-bottom: 1rem;
    color: var(--accent-color);
}

.pix-code-box {
    background-color: var(--background-color);
    border: 2px dashed var(--accent-color);
    border-radius: 10px;
    padding: 1rem;
    cursor: pointer;
    transition: all 0.3s ease;
    position: relative;
    word-break: break-all;
    font-family: monospace;
    font-size: 0.9rem;
}

.pix-code-box:hover {
    background-color: var(--secondary-color);
    border-color: var(--text-color);
}

.copy-hint {
    display: block;
    font-size: 0.8rem;
    color: var(--accent-color);
    margin-top: 0.5rem;
    font-family: 'Montserrat', sans-serif;
}

.copy-message {
    display: none;
    background-color: #d4edda;
    color: #155724;
    padding: 0.5rem 1rem;
    border-radius: 5px;
    margin-top: 1rem;
    font-size: 0.9rem;
} 

.em-breve {
    font-size: 1.2rem;
    color: var(--text-color);
    text-align: center;
    margin-top: 2rem;
}

.things-to-do {
    margin-bottom: 2rem;
}

.things-to-do p {
    font-size: 1.1rem;
}

.gift-registry {
    margin-bottom: 4rem;
    text-align: center;
}

/* Section divider styles */
.section-divider {
    text-align: center;
    margin: 3rem 0 0 0;
    padding: 1rem 0;
}

.tsuru-divider {
    max-width: 700px;
    width: 85vw;
    height: auto;
    opacity: 0.7;
    transition: opacity 0.3s ease;
}

.tsuru-divider:hover {
    opacity: 1;
}

.accommodations p {
    font-size: 1.1rem;
}