/* Dashboard Specific Styles for TeroBazaar */

.dashboard-layout {
    display: flex;
    min-height: 100vh;
    padding-top: var(--nav-height); /* Keep under the fixed header */
    background: var(--bg-color);
}

/* Sidebar Redesign */
.dashboard-sidebar {
    width: 280px;
    background: rgba(15, 15, 15, 0.7);
    backdrop-filter: blur(25px);
    border-right: 1px solid var(--card-border);
    padding: 25px 15px;
    position: fixed;
    height: 100vh;
    top: 0;
    left: 0;
    overflow-y: auto;
    z-index: 1000;
    transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
}

.sidebar-header {
    padding: 20px 15px;
    margin-bottom: 30px;
    border-bottom: 1px solid var(--card-border);
    display: flex;
    flex-direction: column;
    gap: 15px;
}

.sidebar-user {
    display: flex;
    align-items: center;
    gap: 12px;
}

.sidebar-user img {
    width: 45px;
    height: 45px;
    border-radius: 12px;
    border: 1px solid var(--primary);
}

.sidebar-user-info h4 {
    font-size: 0.95rem;
    font-weight: 700;
    color: #fff;
    margin: 0;
}

.sidebar-user-info p {
    font-size: 0.75rem;
    color: var(--text-muted);
    margin: 0;
}

/* Updated Dashboard Classes */
.content-section {
    display: none;
}

.content-section.active {
    display: block;
}

.profile-card-container {
    background: linear-gradient(135deg, rgba(157, 78, 221, 0.2), rgba(0,0,0,0.8)); 
    border-radius: 20px; 
    overflow: hidden; 
    border: 1px solid rgba(255,255,255,0.05); 
    margin-bottom: 30px; 
    position: relative;
}

.profile-banner {
    height: 120px; 
    background-position: center;
    background-size: cover;
    opacity: 0.5;
}

.profile-info-row {
    padding: 25px; 
    display: flex; 
    align-items: flex-end; 
    gap: 20px; 
    margin-top: -60px; 
    position: relative; 
    z-index: 2;
}

.profile-avatar {
    width: 100px; 
    height: 100px; 
    border-radius: 50%; 
    border: 4px solid var(--card-bg); 
    box-shadow: 0 10px 25px rgba(0,0,0,0.5);
}

.info-grid-2col {
    display: grid; 
    grid-template-columns: 1fr 1fr; 
    gap: 30px; 
    margin-bottom: 40px;
}

.vip-card-fancy {
    background: linear-gradient(135deg, rgba(157, 78, 221, 0.1), rgba(0,0,0,0.4)); 
    border: 1px solid rgba(157, 78, 221, 0.3); 
    padding: 30px; 
    border-radius: 20px; 
    box-shadow: 0 10px 30px rgba(0,0,0,0.3); 
    height: 100%; 
    display: flex; 
    flex-direction: column; 
    justify-content: center;
}

/* No mobile-hidden class here, handled in media query */

.sidebar-menu {
    display: flex;
    flex-direction: column;
    gap: 10px;
    margin-top: 20px;
}

.sidebar-link {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 14px 18px;
    color: #aaa;
    border-radius: 14px;
    font-weight: 600;
    font-size: 0.95rem;
    transition: 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    margin-bottom: 4px;
    text-decoration: none;
    position: relative; /* Fixed: Added for absolute badges */
}

.sidebar-link i {
    font-size: 1.4rem;
}

.sidebar-link:hover {
    background: rgba(255, 255, 255, 0.03);
    color: #fff;
    transform: translateX(5px);
}

.sidebar-link.active {
    background: linear-gradient(135deg, var(--primary), var(--primary-light));
    color: #fff;
    box-shadow: 0 8px 20px rgba(157, 78, 221, 0.3);
}

.sidebar-title {
    font-size: 0.7rem;
    color: #555;
    text-transform: uppercase;
    letter-spacing: 2px;
    margin: 30px 0 15px 15px;
    font-weight: 800;
}

/* Main Content */
.dashboard-main {
    flex: 1;
    margin-left: 280px; /* Same as sidebar width */
    padding: 40px;
    overflow-y: auto;
    transition: all 0.3s ease;
    width: 100%;
}

/* Mobile Toggle */
.mobile-toggle {
    display: none;
    position: fixed;
    bottom: 20px;
    right: 20px;
    width: 60px;
    height: 60px;
    background: var(--primary);
    color: white;
    border-radius: 50%;
    align-items: center;
    justify-content: center;
    font-size: 1.8rem;
    box-shadow: 0 4px 15px rgba(0,0,0,0.3);
    z-index: 2000;
    cursor: pointer;
}

.dashboard-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 40px;
}

.dashboard-header h1 {
    font-size: 2rem;
    margin-bottom: 5px;
}

/* Stats Grid */
.stats-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
    gap: 25px;
    margin-bottom: 40px;
}

.stat-card {
    background: var(--card-bg);
    border: 1px solid var(--card-border);
    padding: 25px;
    border-radius: 16px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    transition: var(--transition);
}

.stat-card:hover {
    box-shadow: 0 10px 30px var(--primary-glow);
    border-color: rgba(157, 78, 221, 0.3);
}

.stat-info h3 {
    font-size: 0.9rem;
    color: var(--text-muted);
    font-weight: 500;
    margin-bottom: 10px;
}

.stat-info .value {
    font-size: 1.8rem;
    font-weight: 700;
    color: white;
}

.stat-info .trend.up {
    color: var(--success);
    font-size: 0.85rem;
    display: flex;
    align-items: center;
    gap: 5px;
    margin-top: 5px;
}

.stat-info .trend.down {
    color: var(--alert);
    font-size: 0.85rem;
    display: flex;
    align-items: center;
    gap: 5px;
    margin-top: 5px;
}

.stat-icon {
    width: 60px;
    height: 60px;
    background: rgba(157, 78, 221, 0.1);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--primary-light);
    font-size: 1.8rem;
}

/* Data Tables */
.data-section {
    background: var(--card-bg);
    border: 1px solid var(--card-border);
    border-radius: 16px;
    padding: 25px;
    margin-bottom: 40px;
}

.data-section-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 20px;
}

.table-responsive {
    overflow-x: auto;
}

.data-table {
    width: 100%;
    border-collapse: collapse;
}

.data-table th, .data-table td {
    padding: 15px;
    text-align: left;
    border-bottom: 1px solid var(--card-border);
}

.data-table th {
    color: var(--text-muted);
    font-weight: 500;
    font-size: 0.9rem;
    text-transform: uppercase;
}

.data-table td {
    font-size: 0.95rem;
}

.data-table tbody tr:hover {
    background: rgba(255,255,255,0.02);
}

.status-badge {
    padding: 6px 14px;
    border-radius: 20px;
    font-size: 0.85rem;
    font-weight: 700;
    text-transform: capitalize;
    display: inline-block;
    transition: 0.3s;
}

.status-badge:hover {
    filter: brightness(1.1);
    transform: scale(1.05);
}

.status-badge.pending { background: #ffb703 !important; color: #111 !important; }
.status-badge.processing { background: #0077b6 !important; color: #fff !important; }
.status-badge.shipped { background: #9d4edd !important; color: #fff !important; }
.status-badge.delivered, .status-badge.approved { background: #2b9348 !important; color: #fff !important; }
.status-badge.cancelled, .status-badge.rejected { background: #ff4d4f !important; color: #fff !important; }

/* Action Buttons in Table */
.btn-action {
    background: transparent;
    border: none;
    color: var(--text-muted);
    font-size: 1.2rem;
    cursor: pointer;
    margin-right: 10px;
    transition: var(--transition);
}

.btn-action.approve:hover { color: var(--success); }
.btn-action.reject:hover { color: var(--alert); }
.btn-action.edit:hover { color: var(--primary-light); }

/* Forms in Dashboard */
.form-group {
    margin-bottom: 20px;
}

.form-group label {
    display: block;
    margin-bottom: 8px;
    color: var(--text-muted);
    font-weight: 500;
}

.form-group input, .form-group select, .form-group textarea {
    width: 100%;
    background: rgba(255,255,255,0.05);
    border: 1px solid rgba(255,255,255,0.1);
    color: white;
    padding: 12px 15px;
    border-radius: 10px;
    outline: none;
    font-family: 'Inter', sans-serif;
}

.form-group select option {
    background: #1a1a1a;
    color: white;
    padding: 10px;
}

.form-group input:focus, .form-group select:focus, .form-group textarea:focus {
    border-color: var(--primary);
    background: rgba(157, 78, 221, 0.05);
}

@media (max-width: 900px) {
    .dashboard-layout {
        padding-top: 70px;
        flex-direction: column;
    }

    .dashboard-sidebar {
        width: 280px;
        transform: translateX(-100%);
        left: 0;
        z-index: 3001;
    }

    .dashboard-sidebar.active {
        transform: translateX(0);
    }

    .dashboard-main {
        margin-left: 0;
        padding: 20px 15px 100px;
    }

    .info-grid-2col {
        grid-template-columns: 1fr;
    }

    .stats-grid {
        grid-template-columns: 1fr;
    }

    .dashboard-header {
        flex-direction: column;
        align-items: flex-start;
        gap: 15px;
    }

    .dashboard-header .btn-primary {
        width: 100%;
    }

    .mobile-toggle {
        display: flex;
        position: fixed;
        bottom: 80px;
        right: 20px;
        width: 55px;
        height: 55px;
        background: var(--primary);
        color: white;
        border-radius: 50%;
        align-items: center;
        justify-content: center;
        font-size: 1.5rem;
        z-index: 2000;
        box-shadow: 0 10px 25px var(--primary-glow);
    }

    .profile-info-row {
        flex-direction: column;
        align-items: center;
        text-align: center;
        margin-top: -50px;
    }

    .profile-avatar {
        width: 120px;
        height: 120px;
    }

    .stat-card {
        padding: 20px;
    }
}

/* Enhanced Chat UI */
.chat-container {
    display: grid; 
    grid-template-columns: 280px 1fr; 
    gap: 0; 
    height: 600px; 
    padding: 0; 
    background: #0a0a0a; 
    border-radius: 20px; 
    overflow: hidden; 
    border: 1px solid var(--card-border);
}

.chat-list {
    background: #111;
    border-right: 1px solid var(--card-border);
    overflow-y: auto;
}

.chat-item {
    padding: 18px 15px;
    border-bottom: 1px solid rgba(255,255,255,0.02);
    cursor: pointer;
    transition: 0.2s;
}

.chat-item:hover, .chat-item.active {
    background: rgba(157, 78, 221, 0.15);
    border-left: 4px solid var(--primary);
}

.chat-content {
    display: flex;
    flex-direction: column;
    background: #050505;
}

.chat-messages {
    flex: 1;
    padding: 20px;
    overflow-y: auto;
    display: flex;
    flex-direction: column;
    gap: 15px;
}

.chat-message {
    max-width: 85%;
    padding: 14px 18px;
    border-radius: 18px;
    font-size: 0.95rem;
    position: relative;
    line-height: 1.5;
}

.chat-message.sent {
    align-self: flex-end;
    background: linear-gradient(135deg, var(--primary), #b366ff);
    color: white;
    border-bottom-right-radius: 4px;
    box-shadow: 0 5px 15px rgba(157, 78, 221, 0.2);
}

.chat-message.received {
    align-self: flex-start;
    background: #252525;
    color: #fff;
    border-bottom-left-radius: 4px;
    border: 1px solid rgba(255,255,255,0.05);
}

@media (max-width: 768px) {
    .chat-container {
        grid-template-columns: 1fr;
        height: 70vh; /* Adjust height for mobile */
        border-radius: 15px;
    }
    .chat-list {
        display: none;
    }
    .chat-list.mobile-show {
        display: block;
        position: absolute;
        width: 100%;
        height: 100%;
        z-index: 10;
        background: #0a0a0a;
    }
}

/* Animations for Dashboard Sections */
.module-section, .content-section {
    animation: slideUpFade 0.5s ease forwards;
}

@keyframes slideUpFade {
    from {
        opacity: 0;
        transform: translateY(20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* Seller Settings Specific Enhancements */
.seller-profile-banner {
    height: 150px;
    background: linear-gradient(135deg, var(--primary), #3a0ca3);
    border-radius: 20px 20px 0 0;
}

/* Help Center Grid Layout */
.help-grid {
    display: grid;
    grid-template-columns: minmax(0, 1.6fr) minmax(0, 1fr);
    gap: 40px;
    align-items: start;
    width: 100%;
    max-width: 100%;
}

@media screen and (max-width: 1024px) {
    .help-grid {
        grid-template-columns: 1fr;
        gap: 30px;
    }
}

@media screen and (max-width: 768px) {
    .help-grid {
        grid-template-columns: 1fr;
        gap: 20px;
    }
    .help-card-premium {
        padding: 20px;
    }
}

/* Premium Help Center Styles */
.help-card-premium {
    background: linear-gradient(145deg, rgba(25, 25, 25, 0.9), rgba(10, 10, 10, 0.95));
    border: 1px solid rgba(157, 78, 221, 0.15);
    border-radius: 24px;
    padding: 35px;
    box-shadow: 0 20px 40px rgba(0,0,0,0.4);
    position: relative;
    overflow: hidden;
    transition: 0.3s cubic-bezier(0.175, 0.885, 0.32, 1.275);
}

.help-card-premium::before {
    content: '';
    position: absolute;
    top: 0; left: 0; width: 100%; height: 4px;
    background: linear-gradient(90deg, transparent, var(--primary), transparent);
    opacity: 0.5;
}

.help-card-premium:hover {
    border-color: var(--primary);
    box-shadow: 0 30px 60px rgba(157, 78, 221, 0.1);
    transform: translateY(-5px);
}

.contact-pill {
    padding: 20px;
    background: rgba(255, 255, 255, 0.03);
    border: 1px solid rgba(255, 255, 255, 0.05);
    border-radius: 18px;
    display: flex;
    gap: 15px;
    align-items: center;
    transition: 0.3s ease;
    cursor: pointer;
    text-decoration: none;
    color: inherit;
}

.contact-pill:hover {
    background: rgba(157, 78, 221, 0.08);
    border-color: rgba(157, 78, 221, 0.3);
    transform: scale(1.02);
}

.contact-icon-box {
    width: 50px;
    height: 50px;
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.6rem;
    box-shadow: 0 5px 15px rgba(0,0,0,0.2);
}

.ticket-select {
    width: 100%;
    height: 55px;
    background: rgba(255,255,255,0.03) !important;
    border: 1px solid rgba(255,255,255,0.1) !important;
    border-radius: 14px !important;
    color: white !important;
    padding: 0 20px !important;
    font-size: 0.95rem;
    outline: none;
    transition: 0.3s;
}

.ticket-select:focus {
    border-color: var(--primary) !important;
    background: rgba(157, 78, 221, 0.05) !important;
}

.ticket-textarea {
    width: 100%;
    height: 160px;
    background: rgba(255,255,255,0.03) !important;
    border: 1px solid rgba(255,255,255,0.1) !important;
    border-radius: 14px !important;
    color: white !important;
    padding: 20px !important;
    font-size: 0.95rem;
    resize: none;
    outline: none;
    transition: 0.3s;
    line-height: 1.6;
}

.ticket-textarea:focus {
    border-color: var(--primary) !important;
    background: rgba(157, 78, 221, 0.05) !important;
}

.help-faq-item {
    padding: 15px;
    border-radius: 12px;
    border-left: 3px solid transparent;
    transition: 0.3s;
    cursor: pointer;
}

.help-faq-item:hover {
    background: rgba(255,255,255,0.02);
    border-left-color: var(--primary);
    padding-left: 20px;
}

