/* assets/css/admin.css - GÜNCELLENMİŞ TAM KOD */

:root {
    --sidebar-width: 270px;
    --header-height: 70px;
    --card-shadow: 0 5px 20px rgba(0,0,0,0.03);
    --card-radius: 16px;
    --transition-speed: 0.3s;
}

/* --- GENEL YAPI --- */
body.admin-sayfa {
    background-color: #F3F4F6;
    overflow-x: hidden;
}

.panel-wrapper {
    display: flex;
    width: 100%;
    min-height: 100vh;
}

/* --- SIDEBAR (YAN MENÜ) --- */
.sidebar {
    width: var(--sidebar-width);
    background: #FFFFFF;
    height: 100vh;
    position: fixed;
    top: 0;
    left: 0;
    z-index: 1000;
    display: flex;
    flex-direction: column;
    border-right: 1px solid rgba(0,0,0,0.03);
    transition: transform var(--transition-speed) ease;
    box-shadow: 5px 0 25px rgba(0,0,0,0.02);
}

.sidebar-logo {
    height: var(--header-height);
    display: flex;
    align-items: center;
    padding: 0 30px;
    border-bottom: 1px solid #f8f9fa;
}
.sidebar-logo img { height: 36px; }

.sidebar nav {
    flex: 1;
    padding: 20px;
    overflow-y: auto;
}

.sidebar nav a {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 14px 18px;
    color: var(--text-sub);
    font-weight: 500;
    border-radius: 12px;
    margin-bottom: 5px;
    transition: all 0.2s;
    font-size: 0.95rem;
}

.sidebar nav a i {
    font-size: 1.1rem;
    width: 24px;
    text-align: center;
    color: #b2bec3;
    transition: 0.2s;
}

.sidebar nav a:hover, .sidebar nav a.active {
    background: rgba(255, 107, 107, 0.08);
    color: var(--primary);
    font-weight: 600;
}
.sidebar nav a:hover i, .sidebar nav a.active i { color: var(--primary); }

.sidebar-footer {
    padding: 20px;
    text-align: center;
    font-size: 0.8rem;
    color: #ccc;
    border-top: 1px solid #f8f9fa;
}

/* --- İÇERİK ALANI --- */
.panel-content {
    flex: 1;
    margin-left: var(--sidebar-width);
    padding: 30px;
    transition: margin-left var(--transition-speed) ease;
    width: calc(100% - var(--sidebar-width));
}

/* --- HEADER --- */
.panel-header {
    background: #FFFFFF;
    height: var(--header-height);
    border-radius: var(--card-radius);
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 0 25px;
    margin-bottom: 30px;
    box-shadow: var(--card-shadow);
    position: sticky;
    top: 20px;
    z-index: 900;
}

.btn-menu-toggle {
    background: none; border: none; font-size: 1.4rem; color: var(--dark); cursor: pointer;
    display: none;
}

/* --- KARTLAR VE GRİD --- */
.dash-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
    gap: 25px;
    margin-bottom: 30px;
}

.panel-split-grid {
    display: grid;
    grid-template-columns: 2fr 1fr;
    gap: 25px;
    align-items: start;
}

.kart {
    background: #FFFFFF;
    border-radius: var(--card-radius);
    padding: 30px;
    box-shadow: var(--card-shadow);
    border: 1px solid rgba(0,0,0,0.01);
    position: relative;
    margin-bottom: 25px;
}

.dash-kart {
    display: flex;
    align-items: center;
    justify-content: space-between;
    background: #fff;
    padding: 25px;
    border-radius: var(--card-radius);
    box-shadow: var(--card-shadow);
    transition: transform 0.2s;
}
.dash-kart:hover { transform: translateY(-5px); }

/* --- TABLOLAR --- */
.tablo-kapsayici {
    width: 100%;
    overflow-x: auto;
    border-radius: 12px;
    border: 1px solid #f1f2f6;
}

.tablo-standart {
    width: 100%;
    border-collapse: collapse;
    background: #fff;
    min-width: 600px;
}

.tablo-standart th {
    text-align: left;
    padding: 18px 20px;
    background: #f8f9fa;
    color: var(--text-sub);
    font-weight: 600;
    font-size: 0.85rem;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    border-bottom: 1px solid #eee;
}

.tablo-standart td {
    padding: 18px 20px;
    border-bottom: 1px solid #f1f2f6;
    color: var(--dark);
    vertical-align: middle;
}

.tablo-standart tr:last-child td { border-bottom: none; }
.tablo-standart tr:hover { background-color: #fafbff; }

/* Etiketler */
.etiket { padding: 6px 12px; border-radius: 30px; font-size: 0.75rem; font-weight: 700; display: inline-block; }
.etiket-standart { background: #e3fbf4; color: var(--success); }
.etiket-premium { background: #fff4e6; color: var(--warning); }
.etiket-koyu { background: #dfe6e9; color: var(--dark); }

/* --- LOGIN SAYFASI (DÜZELTİLMİŞ) --- */
.login-body {
    background-color: #fff;
    font-family: 'Outfit', sans-serif;
    overflow-x: hidden;
}

.login-container {
    min-height: 100vh;
}

.login-row {
    min-height: 100vh;
}

/* SOL TARAF: GÖRSEL */
.login-bg-side {
    position: relative;
    background-size: cover;
    background-position: center;
    min-height: 100vh;
    display: flex;
    align-items: center; /* Dikey ortalama */
    justify-content: center; /* Yatay ortalama */
    padding: 40px;
    text-align: center;
}

.login-bg-overlay {
    position: absolute;
    top: 0; left: 0; right: 0; bottom: 0;
    background: linear-gradient(135deg, rgba(0, 0, 0, 0.5) 0%, rgba(0, 0, 0, 0.85) 100%);
    z-index: 1;
    backdrop-filter: blur(3px);
}

.login-bg-text {
    position: relative;
    z-index: 2;
    color: white;
    max-width: 600px;
    animation: fadeInUp 1s ease-out;
}

.login-bg-text h2 {
    font-size: 3.5rem;
    font-weight: 800;
    line-height: 1.1;
    margin-bottom: 25px;
    text-shadow: 0 4px 15px rgba(0,0,0,0.5);
}

.login-bg-text p {
    font-size: 1.25rem;
    opacity: 0.95;
    font-weight: 400;
    line-height: 1.6;
    text-shadow: 0 2px 10px rgba(0,0,0,0.5);
}

/* SAĞ TARAF: FORM */
.login-form-side {
    display: flex;
    align-items: center;
    justify-content: center;
    background-color: #ffffff;
    padding: 40px;
}

.login-wrapper {
    width: 100%;
    max-width: 400px;
    animation: fadeInRight 1s ease-out;
}

/* LOGO ORTALAMA ÇÖZÜMÜ */
.login-brand {
    display: block;
    text-align: center;
    margin-bottom: 30px;
    text-decoration: none;
}

.login-brand img {
    height: 70px;
    object-fit: contain;
    /* Global stildeki display:block'u ezip ortalamak için: */
    margin: 0 auto; 
    display: block;
}

/* FORM ELEMANLARI */
.form-floating > .form-control {
    border: 2px solid #f1f2f6;
    border-radius: 12px;
    height: 55px;
    font-size: 1rem;
    padding-left: 20px;
    transition: all 0.3s;
    background-color: #fcfcfc;
}

.form-floating > .form-control:focus {
    border-color: #FF6B6B;
    background-color: #fff;
    box-shadow: 0 0 0 4px rgba(255, 107, 107, 0.1);
}

.form-floating > label {
    padding-left: 20px;
    color: #95a5a6;
}

.btn-login {
    height: 55px;
    font-size: 1.1rem;
    font-weight: 700;
    border-radius: 12px;
    background: linear-gradient(135deg, #FF6B6B 0%, #EE5253 100%);
    border: none;
    box-shadow: 0 10px 20px rgba(255, 107, 107, 0.3);
    transition: all 0.3s;
    letter-spacing: 0.5px;
    color: white;
}

.btn-login:hover {
    transform: translateY(-3px);
    box-shadow: 0 15px 30px rgba(255, 107, 107, 0.4);
    color: white;
}

.login-footer {
    text-align: center;
    margin-top: 30px;
    font-size: 0.9rem;
    color: #b2bec3;
}

.login-footer a {
    color: #FF6B6B;
    font-weight: 600;
    text-decoration: none;
    margin-left: 5px;
}

/* ANİMASYONLAR */
@keyframes fadeInUp {
    from { opacity: 0; transform: translateY(30px); }
    to { opacity: 1; transform: translateY(0); }
}

@keyframes fadeInRight {
    from { opacity: 0; transform: translateX(30px); }
    to { opacity: 1; transform: translateX(0); }
}

/* RESPONSIVE */
@media (max-width: 991px) {
    /* Gridleri tek kolona düşür */
    .panel-split-grid { grid-template-columns: 1fr; }
    
    .login-bg-side { display: none; }
    .login-form-side { padding: 20px; background-color: #fff; }
    .login-wrapper { padding: 20px; }
}

@media (max-width: 768px) {
    .sidebar { transform: translateX(-100%); box-shadow: 10px 0 30px rgba(0,0,0,0.1); }
    .sidebar.aktif { transform: translateX(0); }
    .panel-content { margin-left: 0; width: 100%; padding: 20px; }
    .btn-menu-toggle { display: block; }
    .panel-header { padding: 0 15px; }
    .kart { padding: 20px; }
}

.sidebar-overlay {
    position: fixed; top: 0; left: 0; width: 100%; height: 100%;
    background: rgba(0,0,0,0.5); z-index: 999;
    display: none; opacity: 0; transition: opacity 0.3s;
    backdrop-filter: blur(2px);
}
.sidebar-overlay.aktif { display: block; opacity: 1; }
/* --- ANA SAYFAYA DÖN BUTONU (YENİ) --- */
.back-home-wrap {
    margin-top: 20px;
    padding-top: 20px;
    border-top: 1px solid #f1f2f6; /* Üstüne ince bir çizgi */
    text-align: center;
}

.btn-back-home {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    color: #95a5a6; /* Gri tonu (Göz yormaz) */
    font-size: 0.9rem;
    font-weight: 500;
    text-decoration: none;
    padding: 8px 15px;
    border-radius: 30px;
    transition: all 0.3s ease;
    background-color: transparent;
}

.btn-back-home:hover {
    color: var(--primary); /* Hoverda ana renk (Kırmızı/Mercan) */
    background-color: rgba(255, 107, 107, 0.05); /* Çok hafif kırmızı arka plan */
    transform: translateX(-5px); /* Sola doğru hafif kayma efekti */
}

.btn-back-home i {
    font-size: 0.8rem;
    transition: transform 0.3s;
}

/* Mobilde çizgi biraz daha belirgin olsun */
@media (max-width: 991px) {
    .back-home-wrap {
        margin-top: 15px;
        padding-top: 15px;
    }
}
/* --- PROFESYONEL SIDEBAR (GÜNCEL) --- */
.sidebar {
    width: var(--sidebar-width);
    background: #ffffff;
    height: 100vh;
    position: fixed;
    top: 0;
    left: 0;
    z-index: 1000;
    display: flex;
    flex-direction: column;
    border-right: 1px solid rgba(0,0,0,0.04);
    box-shadow: 5px 0 25px rgba(0,0,0,0.03);
    transition: all 0.3s ease;
}

/* 1. LOGO ORTALAMA */
.sidebar-logo {
    height: 90px; /* Biraz daha yüksek */
    display: flex;
    align-items: center;
    justify-content: center; /* Yatayda Ortala */
    padding: 0 20px;
    border-bottom: 1px solid rgba(0,0,0,0.03);
}

.sidebar-logo img {
    height: 45px;
    object-fit: contain;
    transition: 0.3s;
}

.sidebar-logo a { display: flex; justify-content: center; width: 100%; }

/* 2. MENÜ ALANI & SCROLLBAR GİZLEME */
.sidebar-menu {
    flex: 1;
    padding: 20px 15px;
    overflow-y: auto; /* Kaydırmaya izin ver */
    
    /* Scrollbar'ı Gizle (Chrome, Safari, Opera) */
    -ms-overflow-style: none;  /* IE ve Edge */
    scrollbar-width: none;  /* Firefox */
}
.sidebar-menu::-webkit-scrollbar {
    display: none;
}

/* 3. MENÜ LİNKLERİ (ITEM) */
.menu-item {
    display: flex;
    align-items: center;
    justify-content: space-between; /* Ok işareti için */
    padding: 14px 18px;
    color: #636e72;
    font-weight: 600;
    font-size: 0.95rem;
    border-radius: 12px;
    margin-bottom: 5px;
    transition: all 0.25s ease;
    text-decoration: none;
    cursor: pointer;
    position: relative;
}

.menu-item-content {
    display: flex;
    align-items: center;
    gap: 12px;
}

.menu-item i.menu-icon {
    font-size: 1.1rem;
    width: 24px;
    text-align: center;
    color: #b2bec3;
    transition: 0.3s;
}

/* Hover ve Aktif Durumları */
.menu-item:hover, .menu-item.active, .menu-dropdown.open .dropdown-toggle {
    background: rgba(255, 107, 107, 0.08); /* Hafif Ana Renk */
    color: var(--primary);
}

.menu-item:hover i.menu-icon, 
.menu-item.active i.menu-icon,
.menu-dropdown.open .dropdown-toggle i.menu-icon {
    color: var(--primary);
}

/* 4. DROPDOWN (ALT MENÜ) YAPISI */
.menu-dropdown {
    margin-bottom: 5px;
}

.dropdown-arrow {
    font-size: 0.8rem;
    transition: transform 0.3s ease;
    color: #b2bec3;
}

/* Açıkken Ok Dönsün */
.menu-dropdown.open .dropdown-arrow {
    transform: rotate(180deg);
    color: var(--primary);
}

.submenu {
    max-height: 0;
    overflow: hidden;
    transition: max-height 0.3s ease-in-out;
    padding-left: 15px; /* Girinti */
}

.menu-dropdown.open .submenu {
    max-height: 500px; /* Yeterince büyük bir değer */
}

.submenu a {
    display: block;
    padding: 10px 15px 10px 42px; /* İkon hizasına denk gelsin */
    font-size: 0.9rem;
    color: #7f8c8d;
    border-radius: 10px;
    margin-top: 2px;
    text-decoration: none;
    transition: 0.2s;
    position: relative;
}

/* Alt menü çizgileri */
.submenu a::before {
    content: '';
    position: absolute;
    left: 26px;
    top: 50%;
    width: 6px;
    height: 6px;
    background: #dfe6e9;
    border-radius: 50%;
    transform: translateY(-50%);
    transition: 0.2s;
}

.submenu a:hover, .submenu a.active {
    color: var(--dark);
    background: rgba(0,0,0,0.02);
}

.submenu a:hover::before, .submenu a.active::before {
    background: var(--primary);
}

/* FOOTER */
.sidebar-footer {
    padding: 20px;
    text-align: center;
    font-size: 0.75rem;
    color: #dfe6e9;
    background: #fff;
    border-top: 1px solid rgba(0,0,0,0.03);
}