/* --- GENEL AYARLAR VE DEĞİŞKENLER --- */
:root { --primary-font: 'Montserrat', sans-serif; --cursive-font: 'Great Vibes', cursive; --primary-color: #6a5acd; --secondary-color: #f4f4f4; --dark-color: #333; --light-color: #fff; --text-color: #555; }
* { margin: 0; padding: 0; box-sizing: border-box; }
html { scroll-behavior: smooth; }
body { font-family: var(--primary-font); line-height: 1.7; color: var(--text-color); overflow-x: hidden; }

/* TÜM SAYFAYI TIKLANABİLİR YAPAN DÜZELTME */
body > section { position: relative; z-index: 2; }

.container { max-width: 1100px; margin: auto; padding: 0 2rem; }
.section-padding { padding: 6rem 0; }
.section-title { font-size: 2.5rem; text-align: center; margin-bottom: 2.5rem; font-weight: 700; color: var(--primary-color); }
.cursive-font { font-family: var(--cursive-font); }

/* --- YÜKLEME EKRANI (PRELOADER) --- */
.preloader { position: fixed; top: 0; left: 0; width: 100%; height: 100%; background-color: var(--light-color); z-index: 9999; display: flex; justify-content: center; align-items: center; transition: opacity 0.75s ease, visibility 0.75s ease; pointer-events: none; }
.preloader.hidden { opacity: 0; visibility: hidden; }
.loader-icon { width: 50px; height: 50px; border: 5px solid var(--secondary-color); border-top-color: var(--primary-color); border-radius: 50%; animation: spin 1s linear infinite; }
@keyframes spin { to { transform: rotate(360deg); } }

/* --- MÜZİK BUTONU --- */
.music-button { position: fixed; top: 20px; right: 20px; z-index: 1000; background-color: rgba(255, 255, 255, 0.8); color: var(--primary-color); border: none; border-radius: 50%; width: 45px; height: 45px; font-size: 1.2rem; cursor: pointer; box-shadow: 0 2px 10px rgba(0,0,0,0.2); display: flex; justify-content: center; align-items: center; transition: transform 0.3s ease; }
.music-button:hover { transform: scale(1.1); }

/* --- ANA KARŞILAMA BÖLÜMÜ (HERO) --- */
.hero { height: 100vh; background: linear-gradient(rgba(0, 0, 0, 0.6), rgba(0, 0, 0, 0.6)), url('images/arkaplan.jpg') no-repeat center center/cover; color: var(--light-color); display: flex; justify-content: center; align-items: center; text-align: center; position: relative; }
#particles-js { position: absolute; top: 0; left: 0; width: 100%; height: 100%; z-index: 1; }
.hero-content { position: relative; z-index: 2; animation: fadeInDown 2s ease-out; padding: 0 1rem; }
.hero-content h1 { font-size: 6rem; margin-bottom: 0.5rem; }
.hero-content p { font-size: 1.5rem; }
.scroll-down { position: absolute; bottom: 2rem; left: 50%; z-index: 2; transform: translateX(-50%); }
.scroll-down span { display: block; width: 24px; height: 24px; border-left: 2px solid var(--light-color); border-bottom: 2px solid var(--light-color); transform: rotate(-45deg); animation: bounce 2s infinite; }
@keyframes bounce { 0%, 20%, 50%, 80%, 100% { transform: translateY(0) rotate(-45deg); } 40% { transform: translateY(-20px) rotate(-45deg); } 60% { transform: translateY(-10px) rotate(-45deg); } }
@keyframes fadeInDown { from { opacity: 0; transform: translateY(-50px); } to { opacity: 1; transform: translateY(0); } }

/* --- DİĞER BÖLÜMLER --- */
.families, .details, .rsvp { background: var(--secondary-color); }
.timeline-section, .gallery-section { background: var(--light-color); }
.family-grid { display: grid; grid-template-columns: repeat(2, 1fr); gap: 2rem; text-align: center; align-items: start; }
.family-title { font-family: var(--cursive-font); font-size: 2.5rem; color: var(--primary-color); }
.parent-names { font-size: 1.2rem; font-weight: 700; color: var(--dark-color); }
.details-grid { display: grid; grid-template-columns: repeat(2, 1fr); gap: 2rem; align-items: stretch; }
.ceremony-block { display: flex; flex-direction: column; background: var(--light-color); border-radius: 15px; box-shadow: 0 10px 30px rgba(0, 0, 0, 0.1); overflow: hidden; transition: transform 0.3s ease, box-shadow 0.3s ease; }
.ceremony-block:hover { transform: translateY(-10px); box-shadow: 0 15px 35px rgba(0, 0, 0, 0.15); }
.detail-card { padding: 2.5rem; text-align: center; flex-grow: 1; }
.card-icon { font-size: 2.5rem; color: var(--primary-color); margin-bottom: 1rem; }
.detail-card h3 { color: var(--primary-color); margin-bottom: 1.5rem; font-size: 1.6rem; }
.detail-card p { font-size: 1rem; margin-bottom: 0.7rem; color: var(--text-color); }
.detail-card i { margin-right: 8px; }
.map-container { width: 100%; height: 300px; }
.map-container iframe { width: 100%; height: 100%; border: none; }
.timeline-tabs { text-align: center; margin-bottom: 3rem; }
.tab-link { padding: 10px 20px; cursor: pointer; border: 2px solid var(--primary-color); background-color: var(--light-color); color: var(--primary-color); margin: 0 5px; border-radius: 50px; font-weight: bold; transition: background-color 0.3s, color 0.3s; font-size: 1rem; }
.tab-link:hover { background-color: #f0eaff; }
.tab-link.active { background-color: var(--primary-color); color: var(--light-color); }
.tab-content { display: none; }
.tab-content.active { display: block; }
.timeline { position: relative; max-width: 800px; margin: 0 auto; }
.timeline::after { content: ''; position: absolute; width: 4px; background-color: var(--primary-color); opacity: 0.3; top: 0; bottom: 0; left: 50%; margin-left: -2px; }
.timeline-item { padding: 10px 40px; position: relative; background-color: inherit; width: 50%; }
.timeline-item:nth-child(odd) { left: 0; }
.timeline-item:nth-child(even) { left: 50%; }
.timeline-item::after { content: ''; position: absolute; width: 20px; height: 20px; right: -10px; background-color: var(--light-color); border: 4px solid var(--primary-color); top: 20px; border-radius: 50%; z-index: 1; }
.timeline-item:nth-child(even)::after { left: -10px; }
.timeline-icon { position: absolute; z-index: 2; top: 18px; width: 24px; height: 24px; font-size: 1.2rem; color: var(--primary-color); text-align: center; line-height: 24px; }
.timeline-item:nth-child(odd) .timeline-icon { right: -34px; }
.timeline-item:nth-child(even) .timeline-icon { left: -34px; }
.timeline-content { padding: 20px 30px; background-color: var(--secondary-color); position: relative; border-radius: 10px; }
.timeline-content h3 { font-size: 1.3rem; color: var(--dark-color); }
.timeline-content p { font-size: 0.9rem; }
.gallery-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(300px, 1fr)); gap: 1.5rem; }
.gallery-item { height: 250px; border-radius: 15px; overflow: hidden; box-shadow: 0 5px 15px rgba(0,0,0,0.1); cursor: pointer; transition: transform 0.3s ease, box-shadow 0.3s ease; }
.gallery-item:hover { transform: scale(1.05); box-shadow: 0 10px 25px rgba(0,0,0,0.2); }
.gallery-item img { width: 100%; height: 100%; object-fit: cover; transition: transform 0.3s ease; }
.gallery-item:hover img { transform: scale(1.1); }
.modal { display: none; position: fixed; z-index: 1001; padding-top: 60px; left: 0; top: 0; width: 100%; height: 100%; overflow: auto; background-color: rgba(0, 0, 0, 0.95); }
.modal-content { margin: auto; display: block; width: auto; height: auto; max-width: 85vw; max-height: 85vh; }
#modal-image { width: 100%; height: 100%; object-fit: contain; animation-name: zoom; animation-duration: 0.5s; }
@keyframes zoom { from { transform: scale(0.8); opacity: 0; } to { transform: scale(1); opacity: 1; } }
.close-btn { position: absolute; top: 15px; right: 35px; color: #f1f1f1; font-size: 40px; font-weight: bold; transition: 0.3s; cursor: pointer; }
.prev-btn, .next-btn { cursor: pointer; position: absolute; top: 50%; width: auto; padding: 16px; margin-top: -50px; color: white; font-weight: bold; font-size: 20px; transition: 0.6s ease; border-radius: 0 3px 3px 0; user-select: none; background-color: rgba(0, 0, 0, 0.3); }
.next-btn { right: 0; border-radius: 3px 0 0 3px; }
.prev-btn:hover, .next-btn:hover { background-color: rgba(0, 0, 0, 0.8); }
.countdown-section { background: linear-gradient(rgba(0,0,0,0.7), rgba(0,0,0,0.7)), url('images/arkaplan.jpg') no-repeat center center/cover; background-attachment: fixed; color: var(--light-color); }
.countdown-section .section-title { color: var(--light-color); }
#countdown { display: flex; justify-content: center; gap: 1.5rem; text-align: center; }
#countdown div { background: rgba(255, 255, 255, 0.1); padding: 1rem; border-radius: 10px; min-width: 120px; }
#countdown span { display: block; font-size: 4rem; font-weight: 700; }
.subtitle { text-align: center; max-width: 700px; margin: -2rem auto 2.5rem; color: var(--text-color); }
.rsvp-form { max-width: 700px; margin: auto; background: var(--light-color); padding: 2.5rem; border-radius: 15px; box-shadow: 0 10px 30px rgba(0,0,0,0.1); }
.form-group { display: flex; gap: 1.5rem; margin-bottom: 1.5rem; }
.form-group input, .form-group select, .form-group textarea { width: 100%; padding: 1rem; border: 1px solid #ddd; border-radius: 8px; font-family: var(--primary-font); font-size: 1rem; }
.form-group textarea { resize: vertical; min-height: 120px; }
.btn { width: 100%; border: none; padding: 1.2rem; font-size: 1.1rem; cursor: pointer; margin-top: 0; border-radius: 8px; background: var(--primary-color); color: var(--light-color); transition: background-color 0.3s ease; }
.btn:hover { background-color: #5a4ab9; }
footer { padding: 3rem; text-align: center; background: var(--dark-color); color: var(--light-color); font-size: 2rem; }

/* --- MOBİL UYUMLULUK (GENİŞ EKRANLI TELEFONLAR VE TABLETLER) --- */
@media (max-width: 768px) {
    .section-padding { padding: 4rem 1rem; }
    .section-title { font-size: 2.2rem; }
    .container { padding: 0 1.5rem; }
    .hero-content h1 { font-size: 4rem; }
    .hero-content p { font-size: 1.2rem; }
    .family-grid, .gallery-grid { grid-template-columns: 1fr; }
    
    /* İSTEK: Tören kartları tabletlerde ve büyük telefonlarda yan yana kalsın */
    .details-grid { grid-template-columns: repeat(2, 1fr); gap: 1rem; }
    .detail-card { padding: 2rem 1.5rem; }

    .timeline::after { left: 20px; }
    .timeline-item { width: 100%; padding-left: 70px; padding-right: 15px; }
    .timeline-item:nth-child(even), .timeline-item:nth-child(odd) { left: 0; }
    .timeline-item::after { left: 10px; }
    .timeline-item .timeline-icon { left: 20px; transform: translateX(-50%); }

    #countdown { flex-wrap: wrap; gap: 1rem; }
    #countdown div { min-width: 130px; padding: 0.8rem; }
    #countdown span { font-size: 3rem; }
    .form-group { flex-direction: column; gap: 1rem; }
    .tab-link { font-size: 0.9rem; padding: 8px 15px; margin: 0 3px; }
    .family-card { margin-bottom: 2rem; }
}

/* --- MOBİL UYUMLULUK (KÜÇÜK EKRANLI TELEFONLAR) --- */
@media (max-width: 500px) {
    .section-padding { padding: 3rem 1rem; }
    .section-title { font-size: 1.8rem; margin-bottom: 2rem; }
    .hero-content h1 { font-size: 3rem; }
    .hero-content p { font-size: 1rem; }

    /* İSTEK & DÜZELTME: Tören kartları en küçük ekranlarda da yan yana */
    .details-grid { grid-template-columns: repeat(2, 1fr); gap: 0.5rem; }
    .detail-card { padding: 1.5rem 1rem; }
    .detail-card h3 { font-size: 1.1rem; }
    .detail-card p { font-size: 0.8rem; word-break: break-word; } /* Yazıların taşmasını engeller */
    .map-container { height: 200px; }
    
    #countdown { gap: 0.5rem; }
    #countdown div { min-width: calc(50% - 0.5rem); }
    #countdown span { font-size: 2.2rem; }
    .tab-link { display: block; width: 100%; margin-bottom: 0.5rem; }
    .timeline::after { left: 15px; }
    .timeline-item { padding-left: 55px; }
    .timeline-item::after { left: 5px; }
    .timeline-item .timeline-icon { left: 15px; transform: translateX(-50%); }
    .timeline-content h3 { font-size: 1.1rem; }
    .rsvp-form { padding: 2rem 1.5rem; }
    .gallery-grid { grid-template-columns: repeat(2, 1fr); gap: 0.5rem; }
    .gallery-item { height: 180px; }
    footer { font-size: 1.5rem; }
}