:root {
    --bg-body: #FAFAFA;
    --bg-card: #FFFFFF;
    --text-main: #111111;
    --text-muted: #666666;
    --accent: #111111;
    --border-light: #E5E5E5;
    --radius: 10px;
    --shadow-soft: 0 10px 30px rgba(0,0,0,0.04);
    --font-main: 'Inter', sans-serif;
    --glass: rgba(255, 255, 255, 0.85);
}

* { box-sizing: border-box; -webkit-font-smoothing: antialiased; }

body {
    margin: 0;
    font-family: var(--font-main);
    background-color: var(--bg-body);
    color: var(--text-main);
    padding-bottom: 85px; 
}

.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
}

/* 1. HEADER */
.main-header {
    position: sticky;
    top: 0;
    z-index: 100;
    background: var(--glass);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    border-bottom: 1px solid rgba(0,0,0,0.03);
    height: 70px;
    display: flex;
    align-items: center;
}

.header-inner {
    display: flex;
    justify-content: space-between;
    align-items: center;
    width: 100%;
}

.logo { font-size: 1.2rem; font-weight: 700; letter-spacing: -0.5px; color: var(--text-main); }
.logo span { font-weight: 300; color: var(--text-muted); }

.desktop-nav { display: none; gap: 30px; }
.desktop-nav a {
    text-decoration: none;
    color: var(--text-muted);
    font-size: 0.95rem;
    font-weight: 500;
    transition: color 0.3s;
}
.desktop-nav a:hover, .desktop-nav a.active { color: var(--text-main); }

.mobile-header-title { display: block; width: 100%; text-align: center; font-weight: 600; }

/* 2. KATEGORİ */
.category-bar {
    margin-top: 20px;
    margin-bottom: 30px;
    display: flex;
    gap: 10px;
    overflow-x: auto;
    padding-bottom: 5px;
    scrollbar-width: none;
}
.category-bar::-webkit-scrollbar { display: none; }

.cat-pill {
    background: transparent;
    border: 1px solid var(--border-light);
    padding: 10px 24px;
    border-radius: var(--radius);
    font-family: var(--font-main);
    font-size: 0.9rem;
    color: var(--text-muted);
    cursor: pointer;
    transition: all 0.3s ease;
    white-space: nowrap;
}
.cat-pill.active { background: var(--text-main); color: #fff; border-color: var(--text-main); }

/* 3. ÜRÜN KARTLARI */
.product-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 20px;
}

.card {
    background: var(--bg-card);
    border-radius: var(--radius);
    overflow: hidden;
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    border: 1px solid transparent;
    cursor: pointer;
}
.card:hover { transform: translateY(-5px); box-shadow: var(--shadow-soft); border-color: var(--border-light); }

.card-img-wrapper { width: 100%; padding-top: 100%; position: relative; background: #f4f4f4; }
.card-img { position: absolute; top: 0; left: 0; width: 100%; height: 100%; object-fit: cover; transition: transform 0.5s ease; }
.card:hover .card-img { transform: scale(1.05); }

.card-info { padding: 15px; }
.card-title { font-size: 1rem; font-weight: 600; margin: 0 0 5px 0; color: var(--text-main); }
.card-meta { font-size: 0.85rem; color: var(--text-muted); }

/* 4. MODAL */
.modal-overlay {
    display: none;
    position: fixed;
    top: 0; left: 0; width: 100%; height: 100%;
    background: rgba(0,0,0,0.6);
    backdrop-filter: blur(8px);
    -webkit-backdrop-filter: blur(8px);
    z-index: 20000 !important; 
    align-items: center; justify-content: center;
    padding: 20px;
    overscroll-behavior: contain;
}

.modal-card {
    background: #fff;
    width: 100%;
    max-width: 500px;
    border-radius: 16px;
    position: relative;
    box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.25);
    display: flex;
    flex-direction: column;
    max-height: 90vh;
    overflow-y: auto;
    -webkit-overflow-scrolling: touch;
}
.modal-card::-webkit-scrollbar { display: none; }

.modal-body { padding: 20px; padding-bottom: 80px; }
.modal-body img { width: 100%; border-radius: 12px; margin-bottom: 20px; display: block; object-fit: cover; }
.modal-body h2 { margin: 0 0 10px 0; font-size: 1.4rem; font-weight: 700; color: #111; }
.modal-body p { line-height: 1.6; color: #555; }

.close-btn {
    position: absolute; top: 15px; right: 15px; z-index: 10;
    width: 36px; height: 36px;
    background-color: rgba(255, 255, 255, 0.9);
    border-radius: 50%; border: none;
    box-shadow: 0 4px 12px rgba(0,0,0,0.15);
    display: flex; align-items: center; justify-content: center;
    font-size: 20px; color: #333; cursor: pointer;
}

.modal-footer { padding: 20px; background: #fff; border-top: 1px solid #f0f0f0; margin-top: auto; }
.modal-footer h4 { margin: 0 0 20px 0; font-size: 1.1rem; color: #111; }

.input-group { position: relative; margin-bottom: 20px; }
.input-group input, .input-group textarea {
    width: 100%; padding: 12px 15px;
    border: 1px solid #e5e5e5; border-radius: 10px;
    font-family: var(--font-main); font-size: 0.95rem;
}
.input-group input:focus, .input-group textarea:focus { outline: none; border-color: #111; }
.input-group label {
    position: absolute; left: 15px; top: 12px; color: #999;
    font-size: 0.95rem; pointer-events: none; transition: all 0.3s;
}
.input-group input:focus + label,
.input-group input:not(:placeholder-shown) + label,
.input-group textarea:focus + label,
.input-group textarea:not(:placeholder-shown) + label {
    top: -10px; left: 10px; font-size: 0.75rem; background: #fff; padding: 0 5px; color: #111;
}

.btn-black {
    width: 100%; padding: 15px;
    background: #111; color: #fff;
    border: none; border-radius: 10px;
    font-size: 1rem; font-weight: 600; cursor: pointer;
}

/* 5. BOTTOM NAV */
.bottom-nav {
    display: flex; justify-content: space-around; align-items: center;
    position: fixed; bottom: 20px; left: 20px; right: 20px;
    height: 65px;
    background: rgba(255, 255, 255, 0.95);
    backdrop-filter: blur(10px); -webkit-backdrop-filter: blur(10px);
    border-radius: 10px;
    box-shadow: 0 10px 40px rgba(0,0,0,0.1);
    z-index: 100;
    border: 1px solid rgba(0,0,0,0.05);
}

.nav-item {
    display: flex; flex-direction: column; align-items: center; justify-content: center;
    text-decoration: none; color: #999; font-size: 11px; font-weight: 500;
    width: 100%; height: 100%;
}
.nav-item.active { color: #111; }
.nav-item svg { margin-bottom: 4px; stroke: #999; }
.nav-item.active svg { stroke: #111; transform: translateY(-2px); }

/* --- MENÜ GİZLEME KURALI (Modal açılınca çalışır) --- */
body.modal-open .bottom-nav {
    display: none !important;
}

/* RESPONSIVE */
@media (min-width: 768px) { .product-grid { grid-template-columns: repeat(3, 1fr); } }
@media (min-width: 1024px) {
    .product-grid { grid-template-columns: repeat(4, 1fr); }
    .bottom-nav { display: none !important; }
    .desktop-nav { display: flex !important; }
    .mobile-header-title { display: none; }
    .logo { font-size: 1.5rem; }
    body { padding-bottom: 0; }
}
@media (max-width: 480px) {
    .modal-overlay { padding: 10px; }
    .modal-card { max-height: 95vh; }
}