/* =====================================================
   RESPONSIVE.CSS - Sadece Mobil Düzeltmeleri
   ===================================================== */

/* HAMBURGER MENU */
.mobile-sidebar-toggle {
    display: none;
    width: 44px;
    height: 44px;
    background: var(--primary-color);
    border: none;
    border-radius: 10px;
    cursor: pointer;
    align-items: center;
    justify-content: center;
}

.mobile-sidebar-toggle i {
    font-size: 22px;
    color: #ffffff;
}

#mobileOverlay {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.5);
    z-index: 9998;
}

#mobileOverlay.active {
    display: block;
}

#mobileSidebar {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 280px;
    height: 100%;
    background: #ffffff;
    z-index: 9999;
    overflow-y: auto;
    box-shadow: 4px 0 20px rgba(0, 0, 0, 0.15);
}

#mobileSidebar.open {
    display: block;
}

.mobile-sidebar-close {
    position: absolute;
    top: 12px;
    right: 12px;
    width: 32px;
    height: 32px;
    background: #f5f5f5;
    border: none;
    border-radius: 50%;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
}

.mobile-sidebar-close i {
    font-size: 18px;
    color: #666;
}

#mobileSidebar .mobile-sidebar-content {
    padding-top: 50px;
}

/* CENTER MENU DROPDOWN */
.center-menu-more {
    display: none;
    position: relative;
}

.center-menu-more-btn {
    background: transparent;
    border: none;
    padding: 10px;
    cursor: pointer;
    color: #666;
    display: flex;
    align-items: center;
}

.center-menu-dropdown {
    display: none;
    position: absolute;
    top: 100%;
    right: 0;
    background: #fff;
    border: 1px solid #eee;
    border-radius: 8px;
    box-shadow: 0 4px 12px rgba(0,0,0,0.15);
    min-width: 160px;
    z-index: 1000;
    padding: 8px 0;
}

.center-menu-dropdown.show {
    display: block;
}

.center-menu-dropdown a {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 10px 16px;
    color: #333;
    text-decoration: none;
    font-size: 14px;
}

.center-menu-dropdown a:hover {
    background: #f5f5f5;
}

.center-menu-dropdown a img {
    width: 16px;
    height: 16px;
}

/* DESKTOP/MOBILE VISIBILITY */
.mobile-only {
    display: none !important;
}

.desktop-only {
    display: inline-flex !important;
}

/* =====================================================
   992px ALTI
   ===================================================== */
@media (max-width: 992px) {
    .mobile-sidebar-toggle {
        display: flex !important;
    }
    
    .left-sidebar {
        display: none !important;
    }
    
    .main-content {
        display: flex !important;
        flex-direction: column !important;
        gap: 20px !important;
        padding: 16px !important;
    }
    
    .center-content {
        width: 100% !important;
    }
    
    .right-sidebar {
        width: 100% !important;
    }
}

/* =====================================================
   768px ALTI
   ===================================================== */
@media (max-width: 768px) {
    .mobile-only {
        display: inline-flex !important;
    }
    
    .desktop-only {
        display: none !important;
    }
    
    /* HEADER */
    .header-top-container {
        display: flex !important;
        flex-direction: column !important;
        height: auto !important;
        padding: 12px 16px !important;
        gap: 12px !important;
    }
    
    .mobile-sidebar-toggle {
        position: absolute !important;
        left: 16px !important;
        top: 12px !important;
        width: 40px !important;
        height: 40px !important;
        z-index: 10 !important;
    }
    
    .logo-container {
        order: 1 !important;
        width: 100% !important;
        display: flex !important;
        justify-content: center !important;
        background-color: transparent !important;
        padding: 8px 50px !important;
        margin: 0 !important;
    }
    
    .logo-container .logo {
        height: 32px !important;
    }
    
    .header-main {
        order: 2 !important;
        width: 100% !important;
        display: flex !important;
        flex-direction: column !important;
        gap: 12px !important;
        padding: 0 !important;
    }
    
    .search-bar {
        width: 100% !important;
        background: rgba(255, 255, 255, 0.2) !important;
        border-radius: 10px !important;
        padding: 12px 16px !important;
    }
    
    .header-actions {
        width: 100% !important;
        justify-content: center !important;
        gap: 12px !important;
    }
    
    .header-actions > .divider {
        display: none !important;
    }
    
    .user-profile .profile-name,
    .user-profile .profile-arrow {
        display: none !important;
    }
    
    .user-profile .login-link,
    .user-profile .register-link {
        padding: 10px 16px !important;
        background: rgba(255, 255, 255, 0.2) !important;
        border-radius: 8px !important;
    }
    
    /* TAG LIST */
    .tag-list {
        flex-wrap: nowrap !important;
        overflow-x: auto !important;
        -webkit-overflow-scrolling: touch;
        scrollbar-width: none;
    }
    
    .tag-list::-webkit-scrollbar {
        display: none;
    }
    
    .header-bottom-container {
        display: flex !important;
        align-items: center !important;
        gap: 12px !important;
    }
    
    .tag-nav-arrows {
        position: static !important;
        flex-shrink: 0 !important;
    }
    
    .tag-nav-arrows button {
        background: transparent !important;
    }
    
    .tag-list {
        flex: 1 !important;
        min-width: 0 !important;
    }
    
    /* MAIN CONTENT */
    .main-content {
        padding: 12px !important;
        margin-top: 0 !important;
    }
    
    /* CENTER MENU - DROPDOWN */
    .center-menu {
        flex-wrap: nowrap !important;
    }
    
    .center-menu-item {
        white-space: nowrap !important;
    }
    
    .center-menu-more {
        display: inline-flex !important;
        margin-left: auto !important;
    }
    
    .center-menu a.desktop-only[href*=takip-entryler] {
        display: none !important;
    }
    
    .center-menu a.desktop-only[href*=istatistikler] {
        display: none !important;
    }
    
    .center-menu-dropdown a {
        display: flex !important;
    }
}

/* =====================================================
   EK DÜZELTMELER
   ===================================================== */

@media (max-width: 768px) {
    /* Etiket okları - boşluk azalt, sağa yasla */
    .tag-nav-arrows {
        gap: 4px !important;
        margin-left: auto !important;
    }
    
    .tag-nav-arrows button {
        width: 28px !important;
        height: 28px !important;
        padding: 4px !important;
    }
    
    .tag-nav-arrows button img {
        width: 16px !important;
        height: 16px !important;
    }
    
    /* Post-meta - üst üste binmeyi önle */
    .post-meta {
        display: flex !important;
        flex-wrap: wrap !important;
        gap: 8px !important;
        font-size: 11px !important;
    }
    
    .post-meta span {
        display: inline-flex !important;
        align-items: center !important;
        gap: 4px !important;
        white-space: nowrap !important;
    }
    
    .post-meta span img {
        width: 12px !important;
        height: 12px !important;
    }
    
    /* Mobile sidebar close button */
    .mobile-sidebar-close {
        display: flex !important;
        position: absolute !important;
        top: 12px !important;
        right: 12px !important;
        width: 32px !important;
        height: 32px !important;
        background: #f0f0f0 !important;
        border: none !important;
        border-radius: 50% !important;
        cursor: pointer !important;
        align-items: center !important;
        justify-content: center !important;
        z-index: 10 !important;
    }
    
    .mobile-sidebar-close i {
        font-size: 16px !important;
        color: #666 !important;
    }
}

/* X IKONU STILI - TEMAYA UYGUN */
.mobile-sidebar-close {
    display: flex !important;
    align-items: center !important;
    justify-content: center !important;
    position: absolute !important;
    top: 16px !important;
    right: 16px !important;
    width: 36px !important;
    height: 36px !important;
    background: var(--primary-color) !important;
    border: none !important;
    border-radius: 50% !important;
    cursor: pointer !important;
    z-index: 10 !important;
    transition: all 0.2s ease !important;
}

.mobile-sidebar-close:hover {
    opacity: 0.9 !important;
    transform: scale(1.05) !important;
}

.mobile-sidebar-close svg {
    width: 18px !important;
    height: 18px !important;
    color: #ffffff !important;
    stroke: #ffffff !important;
}

/* X IKONU TAM ORTALA */
.mobile-sidebar-close {
    display: flex !important;
    align-items: center !important;
    justify-content: center !important;
    padding: 0 !important;
    line-height: 1 !important;
}

.mobile-sidebar-close svg {
    display: block !important;
    margin: 0 !important;
    padding: 0 !important;
}

/* SAG WIDGET ORTA KISIMDAN SONRA */
@media (max-width: 992px) {
    .main-content {
        display: flex !important;
        flex-direction: column !important;
    }
    
    .center-content {
        order: 1 !important;
        width: 100% !important;
    }
    
    .right-sidebar {
        order: 2 !important;
        width: 100% !important;
        margin-top: 20px !important;
    }
}

/* MAIN CONTENT GRID OVERRIDE - MOBIL */
@media (max-width: 992px) {
    main.main-content.container {
        display: flex !important;
        flex-direction: column !important;
        grid-template-columns: none !important;
    }
    
    main.main-content.container .center-content {
        order: 1 !important;
        width: 100% !important;
    }
    
    main.main-content.container .right-sidebar {
        order: 2 !important;
        width: 100% !important;
        margin-top: 20px !important;
    }
    
    main.main-content.container .left-sidebar {
        display: none !important;
    }
}

/* FORCE BLOCK LAYOUT */
@media screen and (max-width: 992px) {
    .main-content,
    main.main-content,
    main.main-content.container,
    .main-content.container {
        display: block !important;
    }
    
    .main-content > .left-sidebar,
    main.main-content > .left-sidebar {
        display: none !important;
    }
    
    .main-content > .center-content,
    main.main-content > .center-content {
        display: block !important;
        width: 100% !important;
        float: none !important;
    }
    
    .main-content > .right-sidebar,
    main.main-content > .right-sidebar,
    .main-content > aside.right-sidebar {
        display: block !important;
        width: 100% !important;
        float: none !important;
        margin-top: 20px !important;
    }
}

/* =====================================================
   BASLIK SAYFASI (TOPIC) - RESPONSIVE
   ===================================================== */

@media screen and (max-width: 768px) {
    /* Topic Header */
    .topic-header {
        padding: 16px !important;
        margin-bottom: 12px !important;
    }
    
    .topic-header-top {
        flex-direction: column !important;
        align-items: flex-start !important;
        gap: 12px !important;
    }
    
    .topic-title {
        font-size: 18px !important;
        line-height: 1.4 !important;
    }
    
    .topic-header-actions {
        width: 100% !important;
        justify-content: flex-start !important;
        flex-wrap: wrap !important;
        gap: 8px !important;
    }
    
    .topic-header-actions .btn,
    .topic-header-actions .btn-follow,
    #followBtn {
        display: inline-flex !important;
        visibility: visible !important;
        opacity: 1 !important;
        padding: 8px 12px !important;
        font-size: 12px !important;
    }
    
    /* Topic Meta */
    .topic-meta {
        gap: 12px !important;
        margin-bottom: 12px !important;
        padding-bottom: 12px !important;
    }
    
    .topic-meta-item {
        font-size: 11px !important;
    }
    
    /* Topic Filter */
    .topic-filter {
        flex-wrap: wrap !important;
        gap: 8px !important;
    }
    
    .filter-options {
        flex-wrap: wrap !important;
        gap: 6px !important;
    }
    
    .filter-btn {
        padding: 6px 10px !important;
        font-size: 11px !important;
    }
    
    /* Entry Card */
    .entry-card {
        padding: 16px !important;
        margin-bottom: 12px !important;
        border-radius: 10px !important;
    }
    
    .entry-content {
        font-size: 14px !important;
        line-height: 1.6 !important;
        margin-bottom: 16px !important;
    }
    
    /* Entry Footer */
    .entry-footer {
        display: flex !important;
        flex-direction: column !important;
        align-items: flex-start !important;
        gap: 12px !important;
        padding-top: 12px !important;
    }
    
    /* Entry Author Section */
    .entry-author-section {
        display: flex !important;
        align-items: center !important;
        width: 100% !important;
        gap: 8px !important;
        flex-wrap: nowrap !important;
    }
    
    .entry-number {
        font-size: 11px !important;
        padding: 3px 6px !important;
    }
    
    .entry-author {
        gap: 8px !important;
    }
    
    .entry-author-avatar {
        width: 28px !important;
        height: 28px !important;
    }
    
    .entry-author-name {
        font-size: 12px !important;
    }
    
    .entry-author-date {
        font-size: 10px !important;
    }
    
    /* Vote Boxes Wrapper (author satırında) */
    .vote-boxes-wrapper {
        display: flex !important;
        gap: 4px !important;
        margin-left: auto !important;
    }
    
    .vote-boxes-wrapper .vote-box {
        padding: 4px 6px !important;
        font-size: 11px !important;
    }
    
    /* Entry Actions - vote box + action buttons */
    .entry-actions {
        display: flex !important;
        width: 100% !important;
        align-items: center !important;
        flex-wrap: wrap !important;
        gap: 6px !important;
        justify-content: center !important;
    }
    
    .vote-box {
        display: inline-flex !important;
        align-items: center !important;
        gap: 4px !important;
        padding: 4px 6px !important;
        font-size: 11px !important;
        background-color: var(--bg-light) !important;
        border-radius: 6px !important;
    }
    
    .vote-box img {
        width: 14px !important;
        height: 14px !important;
        display: inline-block !important;
    }
    
    .vote-box i {
        font-size: 14px !important;
        display: inline-block !important;
    }
    
    .entry-actions .vote-box {
        order: 1 !important;
    }
    
    /* Action Buttons */
    .entry-actions .action-buttons {
        display: flex !important;
        flex-direction: row !important;
        flex-wrap: wrap !important;
        gap: 4px !important;
        order: 2 !important;
        justify-content: center !important;
        margin-left: auto !important;
    }
    
    .entry-actions .action-buttons button {
        width: 30px !important;
        height: 30px !important;
        padding: 0 !important;
        display: flex !important;
        align-items: center !important;
        justify-content: center !important;
    }
    
    .entry-actions .action-buttons button img {
        width: 14px !important;
        height: 14px !important;
    }
    
    .entry-actions .action-buttons button i {
        font-size: 13px !important;
        color: white !important;
        display: inline-block !important;
    }
}

@media screen and (max-width: 480px) {
    .topic-header {
        padding: 12px !important;
    }
    
    .topic-title {
        font-size: 16px !important;
    }
    
    .topic-header-actions .btn {
        padding: 6px 10px !important;
        font-size: 11px !important;
    }
    
    .entry-card {
        padding: 12px !important;
    }
    
    .entry-content {
        font-size: 13px !important;
    }
    
    .entry-actions .action-buttons button {
        width: 28px !important;
        height: 28px !important;
    }
}

/* =====================================================
   HEADER DROPDOWNLAR - RESPONSIVE
   ===================================================== */
@media screen and (max-width: 768px) {
    /* Bildirim ve mesaj dropdownları */
    .notifications-dropdown,
    .messages-dropdown,
    .profile-dropdown {
        position: fixed !important;
        top: auto !important;
        bottom: 0 !important;
        left: 0 !important;
        right: 0 !important;
        width: 100% !important;
        max-width: 100% !important;
        max-height: 70vh !important;
        border-radius: 16px 16px 0 0 !important;
        z-index: 10000 !important;
    }
    
    .header-actions .dropdown-menu,
    .user-dropdown {
        position: fixed !important;
        top: auto !important;
        bottom: 0 !important;
        left: 0 !important;
        right: 0 !important;
        width: 100% !important;
        max-width: 100% !important;
        border-radius: 16px 16px 0 0 !important;
    }
}

/* =====================================================
   ONLINE SAYFASI - RESPONSIVE
   ===================================================== */
@media screen and (max-width: 768px) {
    .online-users-container,
    .online-users-list {
        padding: 12px !important;
    }
    
    .online-user-item {
        flex-direction: column !important;
        align-items: flex-start !important;
        gap: 8px !important;
        padding: 12px !important;
    }
    
    .online-user-info {
        width: 100% !important;
    }
    
    .online-user-actions {
        width: 100% !important;
        justify-content: flex-end !important;
    }
}

/* =====================================================
   MESAJLAR SAYFASI - RESPONSIVE
   ===================================================== */
@media screen and (max-width: 768px) {
    .messages-container {
        flex-direction: column !important;
    }
    
    .messages-sidebar,
    .conversations-list {
        width: 100% !important;
        max-width: 100% !important;
        border-right: none !important;
        border-bottom: 1px solid var(--border-color) !important;
    }
    
    .messages-content,
    .message-detail {
        width: 100% !important;
    }
    
    .conversation-item {
        padding: 12px !important;
    }
    
    .message-input-container {
        padding: 12px !important;
    }
    
    .message-input-container textarea {
        font-size: 14px !important;
    }
}

/* =====================================================
   PROFIL SAYFASI - RESPONSIVE
   ===================================================== */
@media screen and (max-width: 768px) {
    /* Profile cover - shorter on mobile */
    .profile-cover {
        height: 120px !important;
    }
    
    /* Header card - NO overflow hidden (avatar needs to overflow upward) */
    .profile-header-card {
        padding: 0 16px 16px !important;
        border-radius: 12px !important;
        overflow: visible !important;
    }
    
    /* Top section - stack vertically, center */
    .profile-top-section {
        flex-direction: column !important;
        align-items: center !important;
        text-align: center !important;
    }
    
    /* Avatar + name - stack vertically */
    .profile-info-left {
        flex-direction: column !important;
        align-items: center !important;
        text-align: center !important;
        margin-top: -40px !important;
        gap: 12px !important;
        width: 100% !important;
    }
    
    /* Avatar size */
    .profile-avatar-large {
        width: 80px !important;
        height: 80px !important;
    }
    
    /* Name centered */
    .profile-name-section {
        text-align: center !important;
    }
    
    .profile-display-name {
        font-size: 20px !important;
    }
    
    .profile-username {
        justify-content: center !important;
        flex-wrap: wrap !important;
    }
    
    /* Action buttons */
    .profile-actions {
        justify-content: center !important;
        flex-wrap: wrap !important;
        gap: 8px !important;
        width: 100% !important;
    }
    
    .profile-actions button,
    .profile-actions a {
        font-size: 13px !important;
        padding: 8px 14px !important;
    }
    
    /* Stats - wrap on small screens */
    .profile-stats {
        justify-content: center !important;
        flex-wrap: wrap !important;
        gap: 12px 16px !important;
    }
    
    .profile-stats .stat-item {
        min-width: 55px !important;
    }
    
    /* Bio centered */
    .profile-bio {
        text-align: center !important;
    }
    
    .profile-meta {
        justify-content: center !important;
        flex-wrap: wrap !important;
    }
    
    /* Tabs - WRAP to multiple lines so all tabs are visible */
    .profile-tabs {
        flex-wrap: wrap !important;
        justify-content: center !important;
        gap: 6px !important;
        overflow: visible !important;
    }
    
    .profile-tab {
        white-space: nowrap !important;
        flex-shrink: 0 !important;
        padding: 8px 12px !important;
        font-size: 12px !important;
    }
    
    /* Content grid - single column, FULL WIDTH */
    .profile-content-grid {
        grid-template-columns: 1fr !important;
        gap: 16px !important;
        width: 100% !important;
    }
    
    /* Entries column - full width */
    .entries-column {
        width: 100% !important;
        min-width: 0 !important;
    }
    
    /* Sidebar AFTER entries (not before) */
    .profile-sidebar {
        order: 1 !important;
        width: 100% !important;
    }
    
    /* Entry cards - full width */
    .entry-card {
        width: 100% !important;
        box-sizing: border-box !important;
    }
    
    /* Entry footer responsive */
    .entry-footer {
        flex-wrap: wrap !important;
        gap: 8px !important;
    }
    
    .entry-actions {
        flex-wrap: wrap !important;
        gap: 6px !important;
    }
    
    /* Sidebar widgets - full width */
    .sidebar-widget {
        width: 100% !important;
        box-sizing: border-box !important;
    }
    
    /* Statu badge centered */
    .profile-statu-badge {
        text-align: center !important;
    }
}

/* =====================================================
   AYARLAR SAYFASI - RESPONSIVE
   ===================================================== */
@media screen and (max-width: 768px) {
    .settings-container {
        flex-direction: column !important;
    }
    
    .settings-sidebar,
    .settings-menu {
        width: 100% !important;
        border-right: none !important;
        border-bottom: 1px solid var(--border-color) !important;
    }
    
    .settings-tabs,
    .settings-menu-list {
        display: flex !important;
        flex-direction: row !important;
        overflow-x: auto !important;
        -webkit-overflow-scrolling: touch !important;
        gap: 0 !important;
        padding: 0 !important;
    }
    
    .settings-tabs::-webkit-scrollbar,
    .settings-menu-list::-webkit-scrollbar {
        display: none !important;
    }
    
    .settings-tab,
    .settings-menu-item {
        white-space: nowrap !important;
        flex-shrink: 0 !important;
        padding: 12px 16px !important;
        font-size: 13px !important;
        border-bottom: none !important;
        border-right: 1px solid var(--border-color) !important;
    }
    
    .settings-tab:last-child,
    .settings-menu-item:last-child {
        border-right: none !important;
    }
    
    .settings-content {
        width: 100% !important;
        padding: 16px !important;
    }
    
    .settings-form .form-group {
        margin-bottom: 16px !important;
    }
    
    .settings-form input,
    .settings-form select,
    .settings-form textarea {
        font-size: 14px !important;
    }
}

/* =====================================================
   HEADER PROFIL FOTO - KUCULT
   ===================================================== */
@media screen and (max-width: 768px) {
    .header-actions .user-profile img,
    .header-actions .profile-avatar,
    .user-profile .profile-avatar {
        width: 32px !important;
        height: 32px !important;
    }
    
    .user-profile {
        padding: 4px !important;
    }
}

/* =====================================================
   ONLINE SAYFASI - SAG WIDGET ALTA
   ===================================================== */
@media screen and (max-width: 992px) {
    .online-page .main-content,
    .online-users-page .main-content {
        display: flex !important;
        flex-direction: column !important;
    }
    
    .online-page .center-content,
    .online-users-page .center-content {
        order: 1 !important;
        width: 100% !important;
    }
    
    .online-page .right-sidebar,
    .online-users-page .right-sidebar {
        order: 2 !important;
        width: 100% !important;
        margin-top: 20px !important;
    }
}

/* =====================================================
   MESAJLAR SAYFASI - DUZELTME
   ===================================================== */
@media screen and (max-width: 768px) {
    .messages-page .main-content {
        display: flex !important;
        flex-direction: column !important;
    }
    
    .messages-page .center-content {
        width: 100% !important;
        order: 1 !important;
    }
    
    .messages-wrapper,
    .messages-container {
        display: flex !important;
        flex-direction: column !important;
        width: 100% !important;
    }
    
    .messages-list,
    .conversations-sidebar {
        width: 100% !important;
        max-height: 300px !important;
        overflow-y: auto !important;
        border-right: none !important;
        border-bottom: 1px solid var(--border-color) !important;
    }
    
    .message-content,
    .message-detail-container {
        width: 100% !important;
    }
}

/* =====================================================
   HEADER DROPDOWNLAR - SADECE ACIK MENULER
   ===================================================== */
@media screen and (max-width: 768px) {
    /* Sadece acik dropdown menuler */
    .dropdown-menu.show,
    .notifications-dropdown.show,
    .notifications-dropdown.active,
    .messages-dropdown.show,
    .messages-dropdown.active,
    .profile-dropdown.show,
    .user-dropdown.show {
        position: fixed !important;
        top: auto !important;
        bottom: 0 !important;
        left: 0 !important;
        right: 0 !important;
        width: 100vw !important;
        max-width: 100vw !important;
        max-height: 70vh !important;
        overflow-y: auto !important;
        border-radius: 16px 16px 0 0 !important;
        box-shadow: 0 -4px 20px rgba(0,0,0,0.15) !important;
        z-index: 10001 !important;
    }
}

/* =====================================================
   MESAJLAR SAYFASI - DETAYLI DUZELTME
   ===================================================== */
@media screen and (max-width: 992px) {
    .messages-sidebar {
        display: block !important;
        width: 100% !important;
        position: relative !important;
        max-height: none !important;
        border-right: none !important;
        margin-bottom: 16px !important;
    }
    
    .messages-center {
        width: 100% !important;
    }
    
    .messages-list-container {
        max-height: 250px !important;
        overflow-y: auto !important;
    }
}

/* =====================================================
   ONLINE/GENEL SOHBET SAYFASI - DUZELTME
   ===================================================== */
@media screen and (max-width: 992px) {
    .online-page .main-content,
    .chat-page .main-content {
        display: block !important;
    }
    
    .online-page .left-sidebar,
    .chat-page .left-sidebar {
        display: none !important;
    }
    
    .online-page .center-content,
    .chat-page .center-content {
        width: 100% !important;
        float: none !important;
    }
    
    .online-page .right-sidebar,
    .chat-page .right-sidebar {
        width: 100% !important;
        float: none !important;
        margin-top: 20px !important;
    }
    
    /* Chat box */
    .chat-container,
    .chat-box {
        width: 100% !important;
        max-width: 100% !important;
    }
    
    .chat-messages {
        max-height: 400px !important;
    }
    
    .chat-input-container {
        padding: 12px !important;
    }
    
    .online-users-widget {
        width: 100% !important;
    }
}

/* =====================================================
   HEADER DROPDOWNLAR - RESPONSIVE
   ===================================================== */
@media screen and (max-width: 768px) {
    .header-dropdown {
        position: fixed !important;
        top: auto !important;
        bottom: 0 !important;
        left: 0 !important;
        right: 0 !important;
        width: 100% !important;
        max-width: 100% !important;
        max-height: 70vh !important;
        overflow-y: auto !important;
        border-radius: 16px 16px 0 0 !important;
        box-shadow: 0 -4px 20px rgba(0,0,0,0.15) !important;
        z-index: 10000 !important;
    }
    
    .header-dropdown.message-dropdown,
    .header-dropdown.notification-dropdown,
    .header-dropdown.profile-dropdown {
        min-width: 100% !important;
    }
}

/* =====================================================
   ONLINE SAYFASI - USERS-SECTION ALTA
   ===================================================== */
@media screen and (max-width: 992px) {
    .online-users-container {
        display: flex !important;
        flex-direction: column !important;
    }
    
    .global-chat-section {
        order: 1 !important;
        width: 100% !important;
    }
    
    .users-section {
        order: 2 !important;
        width: 100% !important;
        margin-top: 20px !important;
    }
}

/* =====================================================
   MESAJLAR SAYFASI - RESPONSIVE
   ===================================================== */
@media screen and (max-width: 992px) {
    /* Ana container */
    .messages-sidebar {
        position: static !important;
        width: 100% !important;
        height: auto !important;
        max-height: none !important;
        border-right: none !important;
        border-bottom: 1px solid var(--border-color) !important;
    }
    
    .messages-list-container {
        max-height: 250px !important;
        overflow-y: auto !important;
    }
    
    .messages-center {
        width: 100% !important;
    }
    
    .message-view-container {
        width: 100% !important;
    }
    
    .messages-content {
        min-height: 300px !important;
    }
}

@media screen and (max-width: 768px) {
    .messages-header {
        padding: 12px !important;
    }
    
    .messages-header-title {
        font-size: 16px !important;
    }
    
    .messages-list .message-item {
        padding: 10px 12px !important;
    }
    
    .message-view-header {
        padding: 12px !important;
    }
    
    .message-input-container {
        padding: 12px !important;
    }
    
    .message-input-container textarea {
        font-size: 14px !important;
    }
}

/* =====================================================
   MESAJLAR SAYFASI - MAIN CONTENT OVERRIDE
   ===================================================== */
@media screen and (max-width: 992px) {
    /* Mesajlar sayfasinda left-sidebar gorunur olsun */
    .messages-sidebar.left-sidebar {
        display: block !important;
        width: 100% !important;
        position: static !important;
        height: auto !important;
        max-height: none !important;
        border-right: none !important;
        border-bottom: 1px solid var(--border-color) !important;
        margin-bottom: 16px !important;
    }
}

/* =====================================================
   MESAJLAR SAYFASI - GUCLU OVERRIDE
   ===================================================== */
@media screen and (max-width: 992px) {
    /* Main content flex column */
    body .main-content.container {
        display: flex !important;
        flex-direction: column !important;
    }
    
    /* Messages sidebar gorunur ve tam genislik */
    body aside.left-sidebar.messages-sidebar,
    body .left-sidebar.messages-sidebar,
    body .messages-sidebar {
        display: block !important;
        width: 100% !important;
        min-width: 100% !important;
        max-width: 100% !important;
        height: auto !important;
        max-height: none !important;
        position: static !important;
        border-right: none !important;
        border-bottom: 1px solid var(--border-color) !important;
        margin-bottom: 16px !important;
        order: 1 !important;
    }
    
    body .messages-sidebar .messages-list-container {
        max-height: 200px !important;
        overflow-y: auto !important;
    }
    
    body .center-content.messages-center,
    body .messages-center {
        width: 100% !important;
        order: 2 !important;
    }
}

/* Logo boyut override - admin panelden yuklenen logolar icin */
.logo-container {
    padding: 12px 20px !important;
    margin-left: 0 !important;
    display: flex !important;
    align-items: center !important;
    flex-shrink: 0 !important;
    max-width: 220px !important;
    box-sizing: border-box !important;
    overflow: hidden !important;
}
img.logo,
.logo-container img.logo,
.logo-container .logo {
    width: auto !important;
    max-width: 160px !important;
    height: auto !important;
    max-height: 40px !important;
    object-fit: contain !important;
    display: block !important;
}
.footer-logo {
    width: auto !important;
    max-width: 160px !important;
    height: auto !important;
    max-height: 36px !important;
    object-fit: contain !important;
}
