:root {
    --bg-color: #e4dbd6;
    --ivory: hsl(40, 37%, 96%);
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    -webkit-tap-highlight-color: transparent;
}

body {
    font-family: 'Montserrat', sans-serif;
    background-color: var(--bg-color);
    height: 100vh;
    width: 100vw;
    display: flex;
    justify-content: center;
    align-items: center;
    overflow: hidden;
}

.invitation-container {
    width: 100%;
    height: 100%;
    position: relative;
    display: flex;
    justify-content: center;
    align-items: center;
    background-color: #e4dbd6;
    cursor: pointer;
}

/* ÖNEMLİ: Boş div'lerin tıklanabilmesi için */
#overlayTrigger {
    background: rgba(0, 0, 0, 0.001);
    /* Tamamen şeffaf ama "içerik var" sayılır */
    touch-action: manipulation;
    -webkit-tap-highlight-color: transparent;
    user-select: none;
    -webkit-user-select: none;
}

.main-image {
    width: 100%;
    height: 100%;
    object-fit: cover;
    object-position: center 15%;
    box-shadow: 0 0 50px rgba(0, 0, 0, 0.1);
    transition: opacity 1s ease;
    z-index: 1;
}

.main-video {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
    object-position: center 15%;
    opacity: 0;
    transition: opacity 0.8s ease;
    pointer-events: none;
    z-index: 2;
}

body.is-playing .main-video {
    opacity: 1;
    pointer-events: auto;
}

body.is-playing .main-image,
body.is-playing .shiny-text {
    opacity: 0;
    pointer-events: none;
}

.shiny-text {
    position: absolute;
    bottom: 50px;
    left: 50%;
    transform: translateX(-50%);
    font-size: 15px;
    font-weight: 500;
    color: #fff;
    text-transform: uppercase;
    letter-spacing: 1.5px;
    white-space: nowrap;
    transition: opacity 0.5s ease;
    z-index: 10;

    background: linear-gradient(90deg,
            rgba(0, 0, 0, 0.4) 0%,
            rgb(76, 76, 76) 50%,
            rgba(182, 182, 182, 0.4) 100%);
    background-size: 200% auto;
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    animation: shine 3s linear infinite;
    text-shadow: 0 2px 10px rgba(0, 0, 0, 0.2);
}

@keyframes shine {
    to {
        background-position: 200% center;
    }
}

/* Beyaz Parlama Efekti */
.white-flash {
    position: fixed;
    top: 0;
    left: 0;
    width: 100vw;
    height: 100vh;
    background: white;
    opacity: 0;
    transition: opacity 0.8s ease-in-out;
    pointer-events: none;
    z-index: 9999;
}

.white-flash.active {
    opacity: 1;
}

/* Sayfa Geçiş Efekti (Fade-in) */
.fade-in {
    opacity: 0;
    transition: opacity 1s ease-in;
}

.fade-in.visible {
    opacity: 1;
}

/* Arka Plan Videosu */
.bg-video {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
    z-index: -1;
}

/* Kaydırılabilir İçerik Yapısı */
body.scrollable {
    overflow-y: auto !important;
    height: auto !important;
    display: block !important;
}

.scroll-container {
    width: 100%;
    min-height: 200vh;
    /* Kaydırmayı zorunlu kılmak için */
    display: flex;
    flex-direction: column;
    align-items: center;
}

.spacer-top {
    height: 100vh;
    /* İlk ekran boş veya hero alanı */
    width: 100%;
}

.white-box {
    width: 100%;
    max-width: 550px;
    min-height: 150px;
    background-image: url("assets/coundown.png");
    background-size: 100% 100%;
    /* Görselin kutuya tam oturması için */
    background-position: center;
    background-repeat: no-repeat;
    /* Krem / Fildişi tonu */
    border-radius: 8px 8px 0 0;
    /* Alt köşeleri düz yapıyoruz ki birleşsin */
    box-shadow: 0 -10px 40px rgba(0, 0, 0, 0.05);
    /* Gölgeyi yukarı veriyoruz */
    margin-bottom: 0;
    position: relative;
    z-index: 3;
    /* Üstte kalması için */
    padding: 80px 40px;
    display: flex;
    flex-direction: column;
    align-items: center;
}

/* Countdown Stilleri */
.countdown-section {
    text-align: center;
    width: 100%;
}

.countdown-title {
    font-family: 'Pinyon Script', cursive;
    font-size: 54px;
    color: #c5a059;
    margin-bottom: 5px;
}

.countdown-subtitle {
    font-family: 'Playfair Display', serif;
    font-size: 13px;
    letter-spacing: 3px;
    text-transform: uppercase;
    color: #a18a66;
    margin-bottom: 60px;
}

.countdown-timer {
    display: flex;
    justify-content: center;
    align-items: center;
    margin-top: 40px;
}

.timer-item {
    padding: 0 25px;
    display: flex;
    flex-direction: column;
    align-items: center;
}

.timer-item:not(:last-child) {
    border-right: 1px solid rgba(197, 160, 89, 0.2);
}

.timer-value {
    font-family: 'Pinyon Script', cursive;
    font-size: 44px;
    color: #4a4a4a;
    line-height: 1;
}

.timer-label {
    font-family: 'Playfair Display', serif;
    font-size: 10px;
    letter-spacing: 2px;
    text-transform: uppercase;
    color: #c5a059;
    margin-top: 8px;
    opacity: 0.8;
}

@media (max-width: 480px) {
    .timer-item {
        padding: 0 15px;
    }

    .timer-value {
        font-size: 36px;
    }
}

/* Arka Plan Video Karartma */
.video-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(to bottom,
            rgba(0, 0, 0, 0.3) 0%,
            rgba(0, 0, 0, 0.5) 50%,
            rgba(0, 0, 0, 0.3) 100%);
    z-index: 0;
    pointer-events: none;
}

/* Hero İçerik Stilleri */
.hero-content {
    height: 100%;
    width: 100%;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    text-align: center;
    color: white;
    padding: 20px;
    position: relative;
    z-index: 1;
}

.hero-subtitle {
    font-family: 'Playfair Display', serif;
    font-size: clamp(12px, 3vw, 16px);
    letter-spacing: 5px;
    text-transform: uppercase;
    margin-bottom: 40px;
    opacity: 0.9;
    text-shadow: 0 2px 4px rgba(0, 0, 0, 0.3);
}

.hero-names {
    font-family: 'Pinyon Script', cursive;
    font-size: clamp(60px, 15vw, 100px);
    margin: 10px 0;
    line-height: 1.1;
    text-shadow: 0 2px 10px rgba(0, 0, 0, 0.2);
}

.hero-ampersand {
    font-family: 'Playfair Display', serif;
    font-size: 28px;
    margin: 15px 0;
    font-style: italic;
    opacity: 0.8;
}

.hero-date {
    font-family: 'Playfair Display', serif;
    font-size: clamp(18px, 4vw, 24px);
    letter-spacing: 3px;
    margin-top: 50px;
    border-top: 1px solid rgba(255, 255, 255, 0.3);
    border-bottom: 1px solid rgba(255, 255, 255, 0.3);
    padding: 15px 40px;
    text-shadow: 0 2px 4px rgba(0, 0, 0, 0.3);
}

.hero-footer {
    position: absolute;
    bottom: 50px;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 15px;
    opacity: 0.8;
}

.hero-rsvp {
    font-size: 13px;
    letter-spacing: 4px;
    text-transform: uppercase;
    font-weight: 300;
}

.scroll-icon {
    width: 24px;
    height: 24px;
    animation: bounce 2s infinite;
}

@keyframes bounce {

    0%,
    20%,
    50%,
    80%,
    100% {
        transform: translateY(0);
    }

    40% {
        transform: translateY(-10px);
    }

    60% {
        transform: translateY(-5px);
    }
}

.details-section {
    width: 100%;
    background-color: var(--ivory);
    padding: 60px 20px 100px 20px;
    /* padding-top azaltıldı birleşim için */
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
    position: relative;
    z-index: 2;
    border-radius: 0 0 8px 8px;
    /* Alt köşeleri yuvarlatıyoruz */
}

.welcome-text {
    font-family: 'Pinyon Script', cursive;
    font-size: 54px;
    color: #c5a059;
    margin-bottom: 30px;
}

.invite-description {
    font-family: 'Playfair Display', serif;
    font-size: 1.1rem;
    line-height: 1.8;
    color: #a18a66;
    max-width: 600px;
    margin-bottom: 40px;
    font-style: italic;
}

.photo-slider-container {
    width: 100%;
    max-width: 400px;
    /* Slider genişliği bir fotoğraf kadar */
    position: relative;
    margin-top: 20px;
}

.photo-slider {
    display: flex;
    gap: 0;
    width: 100%;
    overflow-x: auto;
    scroll-snap-type: x mandatory;
    scrollbar-width: none;
    /* Firefox */
    -ms-overflow-style: none;
    /* IE/Edge */
}

.photo-slider::-webkit-scrollbar {
    display: none;
    /* Chrome/Safari */
}

.photo-item {
    flex: 0 0 100%;
    scroll-snap-align: center;
    aspect-ratio: 2 / 3;
    overflow: hidden;
    border-radius: 4px;
    padding: 0 10px;
    /* Hafif yan boşluk */
}

.photo-item img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    border-radius: 4px;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.1);
}

.slider-dots {
    display: flex;
    justify-content: center;
    gap: 8px;
    margin-top: 20px;
}

.dot {
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background: #e4dbd6;
    transition: all 0.3s ease;
}

.dot.active {
    background: #c5a059;
    transform: scale(1.2);
}

@media (max-width: 600px) {
    .photo-slider-container {
        max-width: 100%;
    }
}

.events-section {
    width: 100%;
    background-color: var(--ivory);
    padding: 20px 20px 100px 20px;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 30px;
    position: relative;
    z-index: 2;
}

.event-card {
    background: white;
    width: 100%;
    max-width: 400px;
    padding: 40px 30px;
    border-radius: 12px;
    text-align: center;
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.03);
    border: 1px solid rgba(197, 160, 89, 0.1);
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 15px;
}

.event-icon {
    width: 40px;
    height: 40px;
    color: #c5a059;
    margin-bottom: 10px;
}

.event-title {
    font-family: 'Playfair Display', serif;
    font-size: 24px;
    color: #4a4a4a;
    letter-spacing: 2px;
    text-transform: uppercase;
}

.event-time {
    font-family: 'Montserrat', sans-serif;
    font-size: 18px;
    font-weight: 600;
    color: #c5a059;
}

.event-location {
    font-family: 'Montserrat', sans-serif;
    font-size: 14px;
    color: #8a8a8a;
    line-height: 1.6;
}

.maps-button {
    margin-top: 20px;
    padding: 15px 40px;
    background-color: #c5a059;
    color: white;
    text-decoration: none;
    font-family: 'Montserrat', sans-serif;
    font-size: 13px;
    font-weight: 500;
    letter-spacing: 2px;
    text-transform: uppercase;
    border-radius: 50px;
    transition: all 0.3s ease;
    box-shadow: 0 4px 15px rgba(197, 160, 89, 0.3);
}

.maps-button:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(197, 160, 89, 0.4);
}

.venue-section {
    width: 125%;
    background-color: rgb(197, 164, 109);
    padding: 80px 20px 100px 20px;
    display: flex;
    flex-direction: column;
    align-items: center;
    position: relative;
    z-index: 2;
}

.venue-card {
    background: white;
    width: 100%;
    max-width: 600px;
    border-radius: 20px;
    padding: 40px;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.1);
    text-align: center;
    display: flex;
    flex-direction: column;
    gap: 20px;
    margin-top: 40px;
}

.venue-img {
    width: 100%;
    max-width: 480px;
    margin: 0 auto;
    border-radius: 12px;
    display: block;
}

.venue-info-divider {
    width: 60px;
    height: 1px;
    background: rgba(197, 160, 89, 0.3);
    margin: 15px auto;
}

.map-container {
    width: 100%;
    height: 280px;
    border-radius: 12px;
    overflow: hidden;
    margin: 20px 0;
}

.map-container iframe {
    width: 100%;
    height: 100%;
    filter: sepia(0.2) contrast(0.9) brightness(1.05);
    /* Tasarımla uyumlu olması için filtre eklendi */
}

.venue-link {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    text-decoration: none;
    color: #4a4a4a;
    font-family: 'Montserrat', sans-serif;
    font-size: 13px;
    font-weight: 500;
    letter-spacing: 2px;
    text-transform: uppercase;
    transition: all 0.3s ease;
    border-bottom: 2px solid rgba(197, 160, 89, 0.3);
    padding-bottom: 5px;
    margin: 0 auto;
}

.venue-link:hover {
    color: #c5a059;
    border-bottom-color: #c5a059;
}

@media (min-width: 1024px) {
    .main-image {
        width: auto;
        max-width: 600px;
        height: 90vh;
        object-fit: contain;
        border-radius: 8px;
    }
}

/* Upload ve Galeri Bölümü */
.upload-gallery-section {
    width: 100%;
    background: linear-gradient(135deg, rgba(255, 255, 255, 0.95), rgba(253, 248, 238, 0.95));
    padding: 60px 20px;
    display: flex;
    justify-content: center;
    position: relative;
    z-index: 3;
}

.upload-container {
    width: 100%;
    max-width: 600px;
}

.gallery-title {
    font-family: 'Pinyon Script', cursive;
    font-size: 48px;
    color: #c5a059;
    text-align: center;
    margin-bottom: 30px;
}

.upload-area {
    border: 3px dashed #c5a059;
    border-radius: 15px;
    padding: 40px 20px;
    text-align: center;
    cursor: pointer;
    transition: all 0.3s ease;
    background: rgba(253, 248, 238, 0.5);
    margin-bottom: 30px;
}

.upload-area:hover {
    border-color: #a18a66;
    background: rgba(197, 160, 89, 0.05);
    transform: translateY(-2px);
}

.upload-area.drag-over {
    border-color: #8a7d4f;
    background: rgba(197, 160, 89, 0.1);
    box-shadow: 0 5px 20px rgba(197, 160, 89, 0.2);
}

.upload-icon {
    width: 50px;
    height: 50px;
    color: #c5a059;
    margin: 0 auto 15px;
}

.upload-text {
    font-family: 'Montserrat', sans-serif;
    font-size: 16px;
    font-weight: 600;
    color: #4a4a4a;
    margin-bottom: 8px;
}

.upload-subtext {
    font-family: 'Montserrat', sans-serif;
    font-size: 13px;
    color: #8a8a8a;
}

.gallery-container {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(120px, 1fr));
    gap: 15px;
    margin-bottom: 30px;
    min-height: 0;
    contain: layout style paint;
}

.gallery-item {
    position: relative;
    border-radius: 10px;
    overflow: hidden;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
    aspect-ratio: 1;
    animation: slideIn 0.3s ease;
    will-change: transform;
    backface-visibility: hidden;
    -webkit-backface-visibility: hidden;
}

@keyframes slideIn {
    from {
        opacity: 0;
        transform: scale(0.8);
    }
    to {
        opacity: 1;
        transform: scale(1);
    }
}

.gallery-item img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.3s ease;
}

.gallery-item:hover img {
    transform: scale(1.05);
}

/* Video Thumbnail Placeholder */
.video-thumbnail {
    width: 100%;
    height: 100%;
    background: linear-gradient(135deg, #4a4a4a, #2a2a2a);
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 10px;
}

.video-thumbnail svg {
    width: 50px;
    height: 50px;
    filter: drop-shadow(0 2px 4px rgba(0, 0, 0, 0.5));
}

/* Video Loader */
.video-thumbnail-loader {
    width: 100%;
    height: 100%;
    background: linear-gradient(135deg, #4a4a4a, #2a2a2a);
    border-radius: 10px;
}

/* Video Play Overlay (Thumbnail'in üzerindeki play button) */
.video-play-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
    background: rgba(0, 0, 0, 0.4);
    border-radius: 10px;
    transition: background 0.3s ease;
}

.gallery-item:hover .video-play-overlay {
    background: rgba(0, 0, 0, 0.6);
}

.video-play-overlay svg {
    width: 50px;
    height: 50px;
    filter: drop-shadow(0 2px 4px rgba(0, 0, 0, 0.5));
}

.gallery-item .remove-btn {
    position: absolute;
    top: 5px;
    right: 5px;
    width: 28px;
    height: 28px;
    background: rgba(0, 0, 0, 0.7);
    color: white;
    border: none;
    border-radius: 50%;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 18px;
    opacity: 0;
    transition: opacity 0.2s ease;
}

.gallery-item:hover .remove-btn {
    opacity: 1;
}

.gallery-item .remove-btn:hover {
    background: rgba(0, 0, 0, 0.9);
}

.empty-gallery-message {
    text-align: center;
    color: #8a8a8a;
    font-family: 'Montserrat', sans-serif;
    font-size: 13px;
    padding: 20px 0;
    display: none;
}

.gallery-container.empty .empty-gallery-message {
    display: block;
}

@media (max-width: 600px) {
    .gallery-container {
        grid-template-columns: repeat(auto-fill, minmax(100px, 1fr));
        gap: 12px;
    }

    .gallery-title {
        font-size: 40px;
    }

    .upload-area {
        padding: 30px 15px;
    }

    .upload-text {
        font-size: 14px;
    }
}

/* Upload Progress Bar */
.upload-progress {
    margin-top: 20px;
    padding: 15px;
    background: rgba(253, 248, 238, 0.7);
    border-radius: 8px;
}

.progress-bar {
    width: 100%;
    height: 8px;
    background: rgba(197, 160, 89, 0.2);
    border-radius: 10px;
    overflow: hidden;
    margin-bottom: 10px;
}

.progress-fill {
    height: 100%;
    background: linear-gradient(90deg, #c5a059, #d4af6a);
    width: 0%;
    transition: width 0.2s ease;
    border-radius: 10px;
    box-shadow: 0 0 8px rgba(197, 160, 89, 0.5);
}

.progress-text {
    font-family: 'Montserrat', sans-serif;
    font-size: 12px;
    color: #c5a059;
    text-align: center;
    margin: 0;
}

/* Tam Ekran Modal (Lightbox) */
.fullscreen-modal {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.95);
    z-index: 10000;
    animation: fadeIn 0.3s ease;
}

.fullscreen-modal.active {
    display: flex;
    align-items: center;
    justify-content: center;
}

@keyframes fadeIn {
    from {
        opacity: 0;
    }
    to {
        opacity: 1;
    }
}

.modal-content {
    position: relative;
    width: 90%;
    height: 90%;
    max-width: 1200px;
    max-height: 800px;
}

.modal-media {
    width: 100%;
    height: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
}

.modal-media img {
    max-width: 100%;
    max-height: 100%;
    object-fit: contain;
    border-radius: 8px;
}

.modal-media video {
    max-width: 100%;
    max-height: 100%;
    border-radius: 8px;
}

.modal-close {
    position: absolute;
    top: -40px;
    right: 0;
    background: none;
    border: none;
    color: white;
    font-size: 40px;
    cursor: pointer;
    transition: transform 0.2s ease;
    z-index: 10001;
}

.modal-close:hover {
    transform: scale(1.1);
}

@media (max-width: 768px) {
    .modal-content {
        width: 95%;
        height: 95%;
    }

    .modal-close {
        top: 10px;
        right: 10px;
        font-size: 30px;
    }
}