/* ================= ГЛОБАЛЬНЫЕ ПЕРЕМЕННЫЕ ================= */
:root {
    --primary-red: #E62E2E;
    --primary-blue: #4A65F0;
    --text-dark: #1A1A1A;
    --text-gray: #666666;
    --text-light: #95a5a6;
    --bg-light: #F5F6F8;
    --white: #FFFFFF;
    --border-color: #E0E0E0;
}

/* ================= СБРОС СТИЛЕЙ ================= */
* { margin: 0; padding: 0; box-sizing: border-box; font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif; }
body { background-color: var(--bg-light); color: var(--text-dark); }

/* ================= ШАПКА (HEADER) ================= */
.main-header { background: var(--white); padding: 15px 0; box-shadow: 0 2px 10px rgba(0,0,0,0.05); position: sticky; top: 0; z-index: 100; }
.header-container { max-width: 1200px; margin: 0 auto; padding: 0 15px; display: flex; align-items: center; justify-content: space-between; gap: 20px; }

.logo { font-size: 24px; font-weight: bold; color: var(--text-dark); text-decoration: none; display: flex; align-items: center; gap: 10px; }
.logo i { color: var(--primary-red); }

/* ПОИСК ВА ТИЛ БЛОКИ */
.header-search-lang { display: flex; align-items: center; gap: 15px; flex-grow: 1; }
.search-bar { display: flex; align-items: center; background: var(--white); border: 1px solid var(--primary-red); border-radius: 8px; padding: 8px 12px; flex-grow: 1; box-shadow: 0 2px 8px rgba(230, 46, 46, 0.05); }
.search-bar i { color: var(--primary-red); } 

.location-select { cursor: pointer; font-size: 14px; display: flex; align-items: center; gap: 8px; font-weight: 500; white-space: nowrap; transition: 0.3s; color: var(--text-dark); }
.search-divider { width: 1px; height: 20px; background: var(--primary-red); margin: 0 12px; opacity: 0.3; } 
.search-bar input { border: none; background: transparent; width: 100%; outline: none; font-size: 14px; color: var(--text-dark); }
.search-icon-main { cursor: pointer; font-size: 16px; margin-left: 8px; }

/* ТИЛ ТУГМАСИ */
.lang-switch { border: 1px solid var(--primary-red); color: var(--primary-red); background: var(--white); padding: 8px 12px; border-radius: 8px; cursor: pointer; font-size: 14px; font-weight: bold; }

.header-actions { display: flex; align-items: center; gap: 20px; }
.action-btn { display: flex; flex-direction: column; align-items: center; color: var(--text-gray); text-decoration: none; font-size: 12px; gap: 5px; transition: 0.3s; }
.action-btn i { font-size: 20px; }
.action-btn:hover, .action-btn.active { color: var(--primary-red); }

.btn-primary { background: var(--primary-red); color: var(--white); border: none; padding: 12px 20px; border-radius: 8px; font-weight: bold; cursor: pointer; text-decoration: none; display: inline-block; text-align: center; transition: 0.3s; }
.btn-primary:hover { background: #C82323; }

/* ================= ОСНОВНОЙ КОНТЕНТ (HOME) ================= */
.main-content { max-width: 1200px; margin: 20px auto; padding: 0 15px; }

/* КАТЕГОРИИ МЕНЮСИ */
.categories-section { margin-bottom: 20px; }
.category-scroll { display: flex; gap: 20px; overflow-x: auto; padding: 15px 5px; scrollbar-width: none; -ms-overflow-style: none; }
.category-scroll::-webkit-scrollbar { display: none; }
.category-item { text-align: center; text-decoration: none; color: var(--text-gray); min-width: 85px; transition: transform 0.3s ease; }
.category-item:hover { transform: translateY(-5px); }
.category-item span { font-size: 13px; font-weight: 600; display: block; margin-top: 8px; transition: color 0.3s; }

.cat-icon-circle { width: 70px; height: 70px; background: var(--white); border-radius: 50%; display: flex; align-items: center; justify-content: center; margin: 0 auto; box-shadow: 0 4px 15px rgba(0,0,0,0.06); border: 2px solid transparent; transition: all 0.3s ease; }
.cat-icon-circle img { width: 40px; height: 40px; object-fit: contain; }
.all-cars-icon { font-size: 24px; color: var(--text-dark); }
/* АКТИВ КАТЕГОРИЯ ҚИЗИЛ БЎЛАДИ */
.category-item.active .cat-icon-circle { border-color: var(--primary-red); background: rgba(230, 46, 46, 0.05); box-shadow: 0 6px 18px rgba(230, 46, 46, 0.15); }
.category-item.active span { color: var(--primary-red); }

/* ДИНАМИК ФИЛЬТР (CATEGORY.PHP ДАН ОЛИНДИ) */
.filter-wrapper { background: var(--white); border-radius: 12px; box-shadow: 0 4px 15px rgba(0,0,0,0.05); padding: 20px; margin-bottom: 30px; border: 1px solid var(--border-color); }
.filter-grid { display: flex; flex-wrap: wrap; gap: 16px; align-items: flex-end; }
.filter-item { display: flex; flex-direction: column; gap: 8px; flex: 1 1 calc(25% - 16px); min-width: 180px; }
.filter-label { font-size: 12px; font-weight: 700; color: var(--text-gray); text-transform: uppercase; letter-spacing: 0.5px; }
.filter-input-box { display: flex; align-items: center; background: var(--bg-light); border: 1px solid var(--border-color); border-radius: 8px; overflow: hidden; transition: 0.2s ease; }
.filter-input-box:focus-within { border-color: var(--primary-red); box-shadow: 0 0 0 3px rgba(230, 46, 46, 0.1); }
.filter-input { width: 100%; height: 42px; border: none; background: transparent; padding: 0 14px; font-size: 14px; color: var(--text-dark); outline: none; }
select.filter-input { cursor: pointer; appearance: none; }
.filter-separator { color: var(--text-light); padding: 0 5px; }
.filter-btn { height: 44px; background: var(--primary-red); color: #fff; border: none; border-radius: 8px; font-weight: bold; font-size: 15px; cursor: pointer; transition: 0.2s; display: flex; align-items: center; justify-content: center; gap: 8px; width: 100%; }
.filter-btn:hover { background: #C82323; transform: translateY(-1px); }
.mobile-filter-toggle { display: none; }

/* ДИНАМИК МАРКАЛАР СЕТКАСИ (БРЕНДЛАР) */
.child-cats-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(200px, 1fr)); gap: 10px; margin-bottom: 25px; }
.child-cat-card { background: var(--white); border: 1px solid var(--border-color); border-radius: 8px; padding: 12px 16px; display: flex; justify-content: space-between; align-items: center; text-decoration: none; color: var(--text-dark); transition: 0.2s; position: relative; overflow: hidden; }
.child-cat-card:hover { border-color: var(--primary-red); box-shadow: 0 4px 10px rgba(230, 46, 46, 0.1); transform: translateY(-2px); }
.child-cat-info { display: flex; align-items: center; justify-content: space-between; width: 100%; z-index: 2; position: relative; }
.child-cat-title { font-size: 14px; font-weight: 600; flex-grow: 1; }
.child-cat-count { font-size: 12px; color: var(--text-light); background: transparent; padding: 0; font-weight: 500; margin-left: 8px; }
.child-cat-img { height: 30px; width: 30px; object-fit: contain; margin-left: 10px; transition: 0.2s; }
.child-cat-card:hover .child-cat-img { transform: scale(1.05); }

/* КАРТОЧКИ АВТО */
.section-title { font-size: 22px; margin-bottom: 15px; color: var(--text-dark); font-weight: 800; }
.cards-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 12px; padding: 10px 0; }
.car-card { background: var(--white); border-radius: 12px; overflow: hidden; position: relative; box-shadow: 0 4px 12px rgba(0,0,0,0.06); transition: box-shadow 0.3s ease, transform 0.3s ease; display: flex; flex-direction: column; border: 1px solid #f1f1f1; }
.car-card:hover { box-shadow: 0 8px 25px rgba(0,0,0,0.12); transform: translateY(-3px); }
.card-image { position: relative; width: 100%; padding-top: 65%; }
.card-image img { position: absolute; top: 0; left: 0; width: 100%; height: 100%; object-fit: cover; }
.fav-btn { position: absolute; top: 10px; right: 10px; background: rgba(255,255,255,0.85); color: var(--text-light); border: none; width: 32px; height: 32px; border-radius: 50%; cursor: pointer; z-index: 10; display: flex; align-items: center; justify-content: center; box-shadow: 0 2px 8px rgba(0,0,0,0.15); transition: 0.2s; backdrop-filter: blur(4px); }
.fav-btn:hover, .fav-btn.active { background: var(--primary-red); color: var(--white); transform: scale(1.1); }
.badge-vip { position: absolute; top: 10px; left: 10px; background: #F1C40F; color: #000; font-size: 11px; font-weight: bold; padding: 4px 8px; border-radius: 4px; z-index: 2; }
.card-content { padding: 12px; flex-grow: 1; display: flex; flex-direction: column; }
.card-link { text-decoration: none; color: inherit; display: block; flex-grow: 1; }
.car-title { font-size: 15px; margin-bottom: 6px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; font-weight: 700; color: #2C3E50; }
.car-title .year { color: var(--text-light); font-weight: 500; }
.car-price { font-size: 18px; font-weight: 800; margin-bottom: 10px; color: var(--primary-red); }
.car-price span { font-size: 13px; font-weight: 600; color: var(--text-light); }
.car-tags { display: flex; gap: 6px; flex-wrap: wrap; margin-bottom: 12px; }
.tag { background: var(--bg-light); padding: 4px 8px; border-radius: 6px; font-size: 11px; color: #495057; font-weight: 500; }
.car-location { margin-top: auto; font-size: 12px; color: var(--text-light); display: flex; align-items: center; gap: 5px; border-top: 1px solid #f1f1f1; padding-top: 8px; }

/* ================= ДЕТАЛЬНАЯ СТРАНИЦА (DETAIL.PHP) ================= */
.full-screen-wrapper { max-width: 1100px !important; width: 100%; padding: 0 15px; margin: 20px auto; }
.ad-detail-container { width: 100%; margin: 0; }
.ad-main-content { background: var(--white); padding: 30px; border-radius: 16px; box-shadow: 0 4px 20px rgba(0,0,0,0.04); width: 100%; }

.ad-gallery { margin-bottom: 25px; }
.main-image-box { position: relative; width: 100%; padding-top: 50%; border-radius: 16px; overflow: hidden; background: #e9e9e9; }
.main-image-box img { position: absolute; top: 0; left: 0; width: 100%; height: 100%; object-fit: cover; transition: transform 0.3s; }
.main-image-box img:hover { transform: scale(1.02); }

.gallery-actions { position: absolute; top: 15px; left: 15px; right: 15px; display: flex; justify-content: space-between; z-index: 10; }
.back-btn { background: rgba(0,0,0,0.5); color: #fff; border: none; padding: 8px 15px; border-radius: 20px; cursor: pointer; backdrop-filter: blur(5px); font-weight: 600; display: flex; align-items: center; gap: 8px; }
.right-actions { display: flex; gap: 10px; }
.icon-btn { background: rgba(0,0,0,0.5); color: #fff; border: none; width: 38px; height: 38px; border-radius: 50%; cursor: pointer; backdrop-filter: blur(5px); font-size: 18px; display: flex; align-items: center; justify-content: center; }
.icon-btn:hover { background: var(--primary-red); }

.image-counter { position: absolute; bottom: 15px; right: 15px; background: rgba(0,0,0,0.6); color: #fff; padding: 4px 10px; border-radius: 8px; font-size: 13px; font-weight: 600; }

.thumbnail-list { display: flex; gap: 10px; margin-top: 15px; overflow-x: auto; scrollbar-width: none; }
.thumbnail-list::-webkit-scrollbar { display: none; }
.thumb-item { width: 90px; height: 65px; border-radius: 8px; overflow: hidden; cursor: pointer; border: 2px solid transparent; opacity: 0.6; transition: 0.2s; flex-shrink: 0; }
.thumb-item img { width: 100%; height: 100%; object-fit: cover; }
.thumb-item.active { border-color: var(--primary-red); opacity: 1; }

.fullscreen-modal { background-color: #000000 !important; } 
.fullscreen-modal .close-fullscreen { position: absolute !important; top: 20px !important; right: 30px !important; color: #ffffff !important; font-size: 45px !important; font-weight: 300 !important; cursor: pointer !important; z-index: 100000 !important; transition: color 0.2s; }
.fullscreen-modal .close-fullscreen:hover { color: var(--primary-red) !important; }
#fullScreenImage { max-width: 90vw !important; max-height: 75vh !important; object-fit: contain !important; margin: auto; }
.fs-thumb-item { border-radius: 6px !important; }

.ad-header-info { margin-bottom: 25px; border-bottom: 1px solid #E5E7EB; padding-bottom: 20px; }
.ad-title { font-size: 28px; font-weight: 800; color: #111; margin-bottom: 10px; line-height: 1.3; }
.ad-price { font-size: 36px; font-weight: 900; }
.ad-price span { font-size: 20px; font-weight: 700; text-transform: uppercase; }
.ad-price.price-red { color: var(--primary-red); }

.section-subtitle { font-size: 22px; font-weight: 700; color: #111; margin-bottom: 15px; border-left: 4px solid var(--primary-red); padding-left: 10px; }
.ad-characteristics { margin-bottom: 30px; }
.char-grid-wrapper { display: grid; grid-template-columns: 1fr 1fr; column-gap: 40px; row-gap: 15px; }
.char-row { display: flex; justify-content: space-between; border-bottom: 1px dashed #E5E7EB; padding-bottom: 8px; }
.char-label { color: #6B7280; font-size: 15px; }
.char-value { color: #111; font-size: 15px; font-weight: 600; text-align: right; }

.ad-description-block { margin-bottom: 35px; }
.description-text { font-size: 16px; line-height: 1.7; color: #374151; background: #F9FAFB; padding: 20px; border-radius: 12px; }

.seller-profile-card { display: flex; align-items: center; background: var(--white); padding: 20px; border-radius: 16px; text-decoration: none; color: inherit; transition: 0.2s; margin-bottom: 30px; border: 1px solid #E5E7EB; justify-content: space-between; box-shadow: 0 2px 10px rgba(0,0,0,0.02); }
.seller-profile-card:hover { border-color: var(--primary-red); box-shadow: 0 4px 15px rgba(230,46,46,0.1); }
.seller-avatar { width: 70px; height: 70px; border-radius: 50%; object-fit: cover; margin-right: 15px; }
.seller-info { flex-grow: 1; display: flex; flex-direction: column; gap: 4px; }
.seller-name-row { display: flex; align-items: center; gap: 8px; }
.seller-name-row h4 { font-size: 20px; font-weight: 700; color: #111; margin: 0; }
.online-dot { width: 10px; height: 10px; background: #10B981; border-radius: 50%; }
.verified-badge { color: #3B82F6; font-size: 18px; }
.seller-date { font-size: 14px; color: #6B7280; }
.verify-text { font-size: 12px; color: #059669; font-weight: 600; background: #D1FAE5; padding: 3px 8px; border-radius: 6px; display: inline-block; align-self: flex-start; margin-top: 4px; }
.profile-link-text { color: var(--primary-red); font-size: 15px; font-weight: 700; display: flex; align-items: center; gap: 5px; }

.similar-ads-block { margin-top: 40px; border-top: 2px solid #F3F4F6; padding-top: 30px; }

.sticky-action-bar { position: fixed; bottom: 0; left: 0; right: 0; background: #fff; padding: 15px 15px 25px 15px; box-shadow: 0 -4px 20px rgba(0,0,0,0.08); z-index: 1000; }
.action-buttons-container { max-width: 1000px; margin: 0 auto; display: flex; gap: 15px; justify-content: center; }
.action-btn-main { flex: 1; display: flex; align-items: center; justify-content: center; gap: 12px; padding: 14px 10px; border-radius: 12px; text-decoration: none; font-weight: 700; font-size: 15px; transition: 0.2s; color: #fff; max-width: 300px; }
.action-btn-main i { font-size: 22px; }
.btn-text { text-align: left; line-height: 1.2; font-size: 14px;}
.red-btn { background: #E62E2E; } .red-btn:hover { background: #C82323; }
.green-btn { background: #25D366; } .green-btn:hover { background: #1EBE5D; }
.gray-btn { background: #F3F4F6; color: #374151; border: 1px solid #E5E7EB; } .gray-btn i { color: #6B7280; } .gray-btn:hover { background: #E5E7EB; }

.report-block { margin-bottom: 40px; }
.report-block button { background: none; border: none; color: #9CA3AF; font-size: 14px; cursor: pointer; display: flex; align-items: center; gap: 8px; }
.report-block button:hover { color: var(--primary-red); }

/* ================= ГЛАВНЫЙ ПОДВАЛ (FOOTER) ================= */
.main-footer { background: var(--white); padding: 50px 0 30px 0; margin-top: 50px; border-top: 1px solid var(--border-color); padding-bottom: 120px; }
.footer-container { max-width: 1200px; margin: 0 auto; padding: 0 15px; display: grid; grid-template-columns: 2fr 1fr 1fr 1.5fr; gap: 30px; }
.footer-col h4 { font-size: 18px; margin-bottom: 20px; color: var(--text-dark); }
.footer-col.brand-col p { color: var(--text-gray); font-size: 14px; line-height: 1.6; margin-top: 15px; max-width: 280px; }
.footer-col ul { list-style: none; }
.footer-col ul li { margin-bottom: 12px; }
.footer-col ul li a { color: var(--text-gray); text-decoration: none; font-size: 14px; transition: 0.3s; }
.footer-col ul li a:hover { color: var(--primary-red); padding-left: 5px; }

/* ================= МОБИЛЬНОЕ НИЖНЕЕ МЕНЮ ================= */
.mobile-bottom-nav { display: none; }

/* ================= АДАПТАЦИЯ (МОБИЛ ВА ПЛАНШЕТ) ================= */
@media (max-width: 1024px) {
    .cards-grid { grid-template-columns: repeat(3, 1fr); }
}

@media (max-width: 768px) {
    .desktop-only { display: none !important; }
    
    .header-container { flex-direction: row; flex-wrap: nowrap; gap: 8px; align-items: center; justify-content: space-between; padding: 0 10px;}
    .logo { font-size: 20px; flex-shrink: 0; } 
    .header-search-lang { display: flex; width: 100%; gap: 8px; align-items: center; }
    .search-bar { padding: 6px 10px; height: 40px; border: 1px solid var(--primary-red); }
    .location-select { padding-right: 6px; margin-right: 6px; border-right: 1px solid rgba(230, 46, 46, 0.3); }
    .search-divider { display: none; }
    .lang-switch { display: flex !important; align-items: center; justify-content: center; height: 40px; padding: 0 10px; font-size: 13px; flex-shrink: 0; }

    .category-scroll { display: grid; grid-template-columns: repeat(4, 1fr); gap: 15px 10px; overflow-x: visible; padding: 10px 5px; }
    .category-item { min-width: auto; }
    .cat-icon-circle { width: 55px; height: 55px; border-radius: 18px; } 
    .cat-icon-circle img { width: 28px; height: 28px; }
    .category-item span { font-size: 11px; margin-top: 6px; }

    .child-cats-grid { grid-template-columns: repeat(2, 1fr); }
    .child-cat-card { padding: 10px 12px; }
    .child-cat-img { height: 30px; width: 30px; }

    .mobile-filter-toggle { display: flex; width: 100%; padding: 14px; background: var(--primary-red); border: none; border-radius: 8px; align-items: center; justify-content: center; gap: 8px; font-weight: bold; color: #fff; margin-bottom: 20px; cursor: pointer; transition: 0.2s; box-shadow: 0 4px 10px rgba(230, 46, 46, 0.2); }
    .mobile-filter-toggle:active { background: #C82323; }
    .filter-wrapper { display: none; border: none; box-shadow: none; padding: 0; margin-bottom: 20px; background: transparent; }
    .filter-wrapper.show-mobile { display: block; animation: fadeIn 0.3s ease; }
    .filter-item { flex: 1 1 100%; min-width: 100%; }

    .mobile-bottom-nav { display: flex; justify-content: space-around; align-items: center; position: fixed; bottom: 0; left: 0; right: 0; background: var(--white); box-shadow: 0 -2px 10px rgba(0,0,0,0.1); padding: 5px 0; z-index: 1000; }
    .nav-item { display: flex; flex-direction: column; align-items: center; justify-content: center; text-decoration: none; color: var(--text-gray); font-size: 10px; gap: 4px; width: 60px; height: 50px; }
    .nav-item i { font-size: 20px; }
    .nav-item.active { color: var(--primary-red); }
    .fab-btn { position: relative; top: -20px; }
    .fab-circle { background: var(--primary-red); color: var(--white); width: 55px; height: 55px; border-radius: 50%; display: flex; align-items: center; justify-content: center; box-shadow: 0 4px 10px rgba(230, 46, 46, 0.4); }
    .fab-circle i { font-size: 24px; color: var(--white); }
    
    .cards-grid { grid-template-columns: repeat(2, 1fr); gap: 10px; }
    .car-title { font-size: 13px; }
    .car-price { font-size: 16px; }
    .card-content { padding: 10px; }
    .tag { font-size: 10px; padding: 3px 6px; }
    .car-location { font-size: 11px; }

    .footer-container { grid-template-columns: 1fr 1fr; gap: 20px; }
    .footer-col.brand-col, .footer-col.app-col { grid-column: span 2; }
    
    .full-screen-wrapper { padding: 0; margin-top: 0; }
    .ad-main-content { border-radius: 0; padding: 0; box-shadow: none; }
    
    .main-image-box { border-radius: 0; padding-top: 70%; }
    .gallery-actions { top: 10px; left: 10px; right: 10px;}
    
    .ad-header-info { padding: 15px; margin-bottom: 10px; border-bottom: 8px solid #F3F4F6; }
    .ad-title { font-size: 22px; }
    .ad-price { font-size: 26px; }
    
    .ad-characteristics { padding: 0 15px; margin-bottom: 20px; border-bottom: 8px solid #F3F4F6; padding-bottom: 20px;}
    .char-grid-wrapper { grid-template-columns: 1fr; column-gap: 0; }
    .char-row { padding-bottom: 12px; margin-bottom: 8px; }
    
    .ad-description-block { padding: 0 15px 20px 15px; border-bottom: 8px solid #F3F4F6; }
    
    .seller-profile-card { margin: 15px; border: 1px solid #E5E7EB; display: block; position: relative; }
    .seller-avatar { width: 50px; height: 50px; margin-bottom: 10px; }
    .profile-link-text { position: absolute; right: 15px; top: 25px; font-size: 13px; }
    
    .similar-ads-block { padding: 15px; }

    .sticky-action-bar { padding: 10px 10px 15px 10px; }
    .action-btn-main { padding: 10px 5px; gap: 5px; }
    .btn-text { font-size: 11px; }
    .action-btn-main i { font-size: 18px; }
}

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

/* ================= МОДАЛЬНОЕ ОКНО ЛОКАЦИИ ================= */
.modal { display: none; position: fixed; z-index: 2000; left: 0; top: 0; width: 100%; height: 100%; background: rgba(0,0,0,0.6); backdrop-filter: blur(3px); }
.modal-content { background: var(--white); margin: 5% auto; padding: 25px; width: 80%; max-width: 800px; border-radius: 15px; max-height: 85vh; overflow-y: auto; animation: slideDown 0.3s ease; }
@keyframes slideDown { from {transform: translateY(-50px); opacity: 0;} to {transform: translateY(0); opacity: 1;} }
.modal-header { display: flex; justify-content: space-between; align-items: center; border-bottom: 1px solid #eee; padding-bottom: 15px; margin-bottom: 20px; }
.close-modal { font-size: 28px; cursor: pointer; color: #999; }
.close-modal:hover { color: var(--text-dark); }
.location-grid { display: grid; grid-template-columns: 1fr; gap: 20px; }
.city-list { display: grid; grid-template-columns: repeat(auto-fill, minmax(150px, 1fr)); gap: 10px; }
.loc-item { text-decoration: none; color: #444; font-size: 14px; padding: 8px 12px; border-radius: 6px; background: #f9f9f9; transition: 0.2s; }
.loc-item:hover { background: var(--primary-red); color: var(--white); }
.all-loc { font-weight: bold; background: #eee; text-align: center; }

/* ================= СОЦ-СЕТЛАР ТУГМАЛАРИ ================= */
.social-links { display: flex; gap: 12px; margin-top: 15px; }
.social-btn { width: 38px; height: 38px; border-radius: 10px; display: flex; align-items: center; justify-content: center; color: #fff !important; text-decoration: none; font-size: 18px; transition: all 0.3s ease; box-shadow: 0 4px 10px rgba(0,0,0,0.1); }
.social-btn.tg { background: #0088cc; }
.social-btn.inst { background: linear-gradient(45deg, #f09433, #e6683c, #dc2743, #cc2366, #bc1888); }
.social-btn.yt { background: #ff0000; }
.social-btn.fb { background: #1877f2; }
.social-btn:hover { transform: translateY(-4px); box-shadow: 0 6px 15px rgba(0,0,0,0.15); filter: brightness(1.1); }

@media (max-width: 768px) {
    .social-links { justify-content: flex-start; gap: 10px; }
    .social-btn { width: 35px; height: 35px; font-size: 16px; }
}

/* ================= ПРИЛОЖЕНИЕ ТУГМАЛАРИ ================= */
.app-btn { display: flex; align-items: center; background: #171A21; color: #FFFFFF !important; text-decoration: none !important; padding: 10px 18px; border-radius: 10px; margin-bottom: 12px; gap: 12px; transition: all 0.3s ease; max-width: 200px; border: 1px solid rgba(255,255,255,0.1); }
.app-btn:hover { background: #000000; transform: translateY(-3px); box-shadow: 0 5px 15px rgba(0, 0, 0, 0.2); }
.app-btn i { font-size: 28px; }
.app-btn .text { display: flex; flex-direction: column; line-height: 1.2; }
.app-btn .text small { font-size: 10px; text-transform: uppercase; opacity: 0.8; }
.app-btn .text span { font-size: 16px; font-weight: 700; }
@media (max-width: 768px) { .app-btn { max-width: 100%; justify-content: center; } }

/* ================= АВТОРИЗАЦИЯ САҲИФАСИ ================= */
.auth-page { background: linear-gradient(135deg, #f6f8fd 0%, #eef2f6 100%); min-height: 100vh; display: flex; align-items: center; justify-content: center; }
.auth-container { width: 100%; max-width: 450px; padding: 20px; position: relative; }
.auth-back-btn { position: absolute; top: -40px; left: 20px; color: var(--text-gray); text-decoration: none; font-size: 14px; font-weight: 700; display: flex; align-items: center; gap: 8px; transition: 0.3s; }
.auth-back-btn:hover { color: var(--primary-red); transform: translateX(-5px); }
.auth-box { background: var(--white); border-radius: 24px; padding: 40px; box-shadow: 0 15px 35px rgba(0,0,0,0.06); border: 1px solid rgba(255,255,255,0.8); }

.fade-in-up { animation: fadeInUp 0.6s cubic-bezier(0.16, 1, 0.3, 1) forwards; }
@keyframes fadeInUp { from { opacity: 0; transform: translateY(30px); } to { opacity: 1; transform: translateY(0); } }

.auth-header { text-align: center; margin-bottom: 35px; }
.auth-logo { font-size: 28px; font-weight: 800; color: var(--text-dark); margin-bottom: 15px; display: flex; align-items: center; justify-content: center; gap: 10px; }
.auth-logo i { color: var(--primary-red); }
.auth-header h2 { font-size: 26px; color: var(--text-dark); margin-bottom: 8px; font-weight: 800; }
.auth-header p { color: var(--text-gray); font-size: 15px; line-height: 1.5; }
.auth-form { display: flex; flex-direction: column; gap: 20px; }

.input-group { position: relative; width: 100%; }
.input-icon { position: absolute; left: 18px; top: 50%; transform: translateY(-50%); color: var(--text-light); font-size: 18px; transition: 0.3s; z-index: 2; }
.input-group input { width: 100%; padding: 18px 16px 18px 50px; font-size: 16px; font-weight: 600; border: 2px solid #E5E7EB; border-radius: 14px; background: #F9FAFB; color: var(--text-dark); outline: none; transition: all 0.3s ease; }
.input-group input:focus { background: var(--white); border-color: var(--primary-red); box-shadow: 0 0 0 4px rgba(230, 46, 46, 0.1); }
.input-group input:focus ~ .input-icon { color: var(--primary-red); }
.input-group label { position: absolute; left: 50px; top: 50%; transform: translateY(-50%); color: var(--text-light); font-size: 16px; pointer-events: none; transition: 0.3s ease; background: transparent; padding: 0 4px; }
.input-group input:focus ~ label, .input-group input:not(:placeholder-shown) ~ label { top: 0; left: 15px; font-size: 12px; color: var(--primary-red); background: var(--white); font-weight: 700; }

.auth-submit-btn { width: 100%; padding: 16px; font-size: 16px; border-radius: 14px; display: flex; align-items: center; justify-content: center; gap: 10px; margin-top: 10px; position: relative; overflow: hidden; background: var(--primary-red); color: white; border: none; font-weight: bold; cursor: pointer;}
.auth-submit-btn::after { content: ''; position: absolute; top: 0; left: -100%; width: 50%; height: 100%; background: linear-gradient(90deg, transparent, rgba(255,255,255,0.3), transparent); transition: 0.5s; }
.auth-submit-btn:hover::after { left: 100%; }

.error-text { background: #FEE2E2; color: #DC2626; padding: 12px; border-radius: 10px; font-size: 14px; font-weight: 600; text-align: center; border: 1px solid #FCA5A5; animation: shake 0.4s ease-in-out; }
@keyframes shake { 0%, 100% { transform: translateX(0); } 25% { transform: translateX(-5px); } 50% { transform: translateX(5px); } 75% { transform: translateX(-5px); } }

.spinner { width: 20px; height: 20px; border: 3px solid rgba(255,255,255,0.3); border-top-color: white; border-radius: 50%; animation: spin 1s linear infinite; }
@keyframes spin { to { transform: rotate(360deg); } }

@media (max-width: 480px) { .auth-box { padding: 30px 20px; } .auth-header h2 { font-size: 22px; } .auth-back-btn { top: -30px; left: 10px; } }

/* ================= ҚЎШИМЧА АВТОРИЗАЦИЯ ================= */
.toggle-password { position: absolute; right: 18px; top: 50%; transform: translateY(-50%); color: var(--text-light); font-size: 18px; cursor: pointer; transition: color 0.3s ease; z-index: 10; }
.toggle-password:hover { color: var(--primary-red); }
.auth-footer-link { margin-top: 25px; text-align: center; }
.auth-footer-link a { color: var(--primary-blue); text-decoration: none; font-size: 14px; font-weight: 600; transition: color 0.3s ease; }
.auth-footer-link a:hover { color: var(--primary-red); text-decoration: underline; }

/* ================= АВАТАР ЮКЛАШ ================= */
.avatar-upload-box { display: flex; flex-direction: column; align-items: center; justify-content: center; margin-bottom: 25px; }
.avatar-preview { width: 100px; height: 100px; border-radius: 50%; background-color: #F3F4F6; border: 2px dashed #CBD5E1; display: flex; align-items: center; justify-content: center; overflow: hidden; cursor: pointer; position: relative; transition: 0.3s; }
.avatar-preview:hover { border-color: var(--primary-red); background-color: #FEF2F2; }
.avatar-preview img { width: 100%; height: 100%; object-fit: cover; display: none; }
.avatar-preview i { font-size: 30px; color: #9CA3AF; }
.avatar-preview:hover i { color: var(--primary-red); }
.avatar-upload-label { margin-top: 10px; font-size: 14px; color: var(--text-gray); font-weight: 600; }
input[type="file"] { display: none; }

/* ================= AUTO.TJ ЛИЧНЫЙ КАБИНЕТ ================= */
.atj-cabinet-main { background: var(--bg-light); padding: 40px 0; min-height: 600px; }
.atj-container { max-width: 1200px; margin: 0 auto; padding: 0 15px; }

.atj-user-header { background: var(--white); padding: 25px; border-radius: 12px; display: flex; justify-content: space-between; align-items: center; box-shadow: 0 2px 10px rgba(0,0,0,0.05); margin-bottom: 25px; }
.atj-user-flex { display: flex; align-items: center; gap: 20px; }
.atj-main-avatar { width: 70px; height: 70px; border-radius: 50%; object-fit: cover; border: 2px solid var(--border-color); }
.atj-user-info h1 { margin: 0; font-size: 22px; color: var(--text-dark); }
.atj-user-info p { margin: 5px 0 0; color: var(--text-gray); font-size: 14px; }
.atj-balance-box { text-align: right; }
.atj-label { display: block; font-size: 12px; color: var(--text-light); }
.atj-amount { display: block; font-size: 24px; font-weight: 800; color: #28a745; margin: 5px 0; }
.atj-top-up { color: #28a745; text-decoration: none; font-size: 13px; font-weight: 600; border: 1px solid #28a745; padding: 4px 15px; border-radius: 6px; }

.atj-content-grid { display: grid; grid-template-columns: 280px 1fr; gap: 25px; }

.atj-nav-menu { list-style: none; padding: 15px; background: var(--white); border-radius: 12px; box-shadow: 0 2px 10px rgba(0,0,0,0.05); margin: 0; }
.atj-nav-menu li a { display: flex; align-items: center; gap: 12px; padding: 12px 15px; color: var(--text-gray); text-decoration: none; border-radius: 8px; font-weight: 600; font-size: 15px; margin-bottom: 2px; transition: 0.2s;}
.atj-nav-menu li a:hover { background: #f8f9fa; color: var(--primary-red); }
.atj-nav-menu li a.active { background: var(--primary-red); color: var(--white); }
.atj-nav-menu li a i { width: 20px; text-align: center; font-size: 16px; }
.atj-logout { border-top: 1px solid #f0f0f0; margin-top: 10px; padding-top: 10px !important; }
.atj-logout a { color: var(--primary-red) !important; }

.atj-stats-row { display: grid; grid-template-columns: 1fr 1fr; gap: 20px; }
.atj-stat-card { background: var(--white); padding: 30px; border-radius: 12px; box-shadow: 0 2px 10px rgba(0,0,0,0.05); display: flex; justify-content: space-between; align-items: center; }
.atj-stat-txt span { display: block; color: var(--text-light); font-size: 14px; }
.atj-stat-txt strong { display: block; font-size: 32px; font-weight: 800; margin-top: 8px; color: var(--text-dark); }
.icon-blue { color: var(--primary-blue); font-size: 40px; opacity: 0.1; }
.icon-red { color: var(--primary-red); font-size: 40px; opacity: 0.1; }

.atj-quick-actions { background: var(--white); padding: 30px; border-radius: 12px; margin-top: 25px; box-shadow: 0 2px 10px rgba(0,0,0,0.05); }
.atj-quick-actions h3 { margin: 0 0 20px; font-size: 18px; color: var(--text-dark); }
.atj-btn-row { display: flex; gap: 15px; }
.atj-btn-red { background: var(--primary-red); color: var(--white); padding: 12px 25px; border-radius: 8px; text-decoration: none; font-weight: 700; transition: 0.2s; }
.atj-btn-red:hover { background: #C82323; }
.atj-btn-gray { background: #f0f2f5; color: var(--text-dark); padding: 12px 25px; border-radius: 8px; text-decoration: none; font-weight: 700; transition: 0.2s; }
.atj-btn-gray:hover { background: #e2e6ea; }

.atj-verification-alert { background: #fff5f5; border: 1px solid #fed7d7; padding: 15px 20px; border-radius: 12px; margin-top: 25px; display: flex; align-items: center; gap: 15px; }
.atj-verification-alert i { color: var(--primary-red); font-size: 18px; }
.atj-verification-alert span { font-size: 14px; color: #9b2c2c; flex-grow: 1; }
.atj-verification-alert a { background: var(--primary-red); color: #fff; text-decoration: none; padding: 6px 15px; border-radius: 6px; font-size: 13px; font-weight: 600; transition: 0.2s; }
.atj-verification-alert a:hover { background: #C82323; }

.admin-link a { background: #111827 !important; color: #fbbf24 !important; margin-bottom: 15px !important; }
.admin-link a:hover { background: #1f2937 !important; }

.badge-role { font-size: 11px; padding: 2px 8px; border-radius: 4px; font-weight: 700; text-transform: uppercase; display: inline-block; margin-top: 5px; }
.badge-role.admin { background: #fee2e2; color: #dc2626; }
.badge-role.moder { background: #dcfce7; color: #16a34a; }

@media (max-width: 850px) {
    .atj-content-grid { grid-template-columns: 1fr; }
    .atj-stats-row { grid-template-columns: 1fr; }
    .atj-user-header { flex-direction: column; text-align: center; gap: 20px; }
    .atj-balance-box { text-align: center; }
}