/* ============================================
   DASHBOARD — Dedicated Styles
   ============================================ */

.dashboard-body {
    display: flex;
    background: var(--gray-100);
}

.dashboard-body .navbar {
    display: none;
}

/* ============================================
   SIDEBAR
   ============================================ */

.sidebar {
    width: 260px;
    height: 100vh;
    position: fixed;
    left: 0;
    top: 0;
    background: var(--dark);
    display: flex;
    flex-direction: column;
    z-index: 100;
    transition: width 0.3s ease;
    overflow-x: hidden;
}

.sidebar.collapsed {
    width: 72px;
}

.sidebar-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 20px 20px 0;
    margin-bottom: 30px;
}

.sidebar-header .logo {
    font-size: 1.15rem;
    white-space: nowrap;
}

.sidebar-toggle {
    width: 32px;
    height: 32px;
    border: none;
    background: rgba(255, 255, 255, 0.06);
    color: var(--gray);
    border-radius: 8px;
    cursor: pointer;
    transition: var(--transition);
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
}

.sidebar-toggle:hover {
    background: rgba(255, 255, 255, 0.12);
    color: var(--white);
}

.sidebar.collapsed .sidebar-toggle i {
    transform: rotate(180deg);
}

.sidebar.collapsed .sidebar-header .logo span,
.sidebar.collapsed .sidebar-header .logo i+*:not(span) {
    display: none;
}

/* Sidebar Nav */
.sidebar-nav {
    flex: 1;
    padding: 0 12px;
    overflow-y: auto;
}

.nav-section {
    margin-bottom: 24px;
}

.nav-section-title {
    display: block;
    font-size: 0.7rem;
    text-transform: uppercase;
    letter-spacing: 1.5px;
    color: var(--dark-600);
    padding: 0 12px;
    margin-bottom: 8px;
    font-weight: 700;
}

.sidebar.collapsed .nav-section-title {
    opacity: 0;
    height: 0;
    margin: 0;
    overflow: hidden;
}

.nav-item {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 10px 14px;
    border-radius: 8px;
    color: var(--gray);
    font-size: 0.88rem;
    font-weight: 500;
    transition: var(--transition);
    margin-bottom: 2px;
    white-space: nowrap;
}

.nav-item:hover {
    background: rgba(255, 255, 255, 0.06);
    color: var(--white);
}

.nav-item.active {
    background: rgba(37, 99, 235, 0.15);
    color: var(--primary-light);
}

.nav-item i {
    width: 20px;
    text-align: center;
    flex-shrink: 0;
    font-size: 1rem;
}

.sidebar.collapsed .nav-item span {
    display: none;
}

/* Sidebar User */
.sidebar-user {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 20px;
    border-top: 1px solid rgba(255, 255, 255, 0.06);
    margin-top: auto;
}

.sidebar-user .avatar {
    width: 36px;
    height: 36px;
    font-size: 0.75rem;
}

.user-info strong {
    display: block;
    font-size: 0.85rem;
    color: var(--white);
}

.user-info span {
    font-size: 0.75rem;
    color: var(--gray);
}

.sidebar.collapsed .user-info {
    display: none;
}

/* ============================================
   DASHBOARD MAIN
   ============================================ */

.dashboard-main {
    margin-left: 260px;
    flex: 1;
    padding: 0 32px 40px;
    min-height: 100vh;
    transition: margin-left 0.3s ease;
}

.sidebar.collapsed~.dashboard-main {
    margin-left: 72px;
}

/* Top Bar */
.dashboard-topbar {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 24px 0;
    position: sticky;
    top: 0;
    background: var(--gray-100);
    z-index: 50;
    margin-bottom: 8px;
}

.topbar-left {
    display: flex;
    align-items: center;
    gap: 16px;
}

.topbar-left h1 {
    font-size: 1.6rem;
    font-weight: 800;
    color: var(--dark);
    letter-spacing: -0.5px;
}

.mobile-sidebar-toggle {
    display: none;
    width: 40px;
    height: 40px;
    border: none;
    background: var(--white);
    border-radius: 8px;
    cursor: pointer;
    font-size: 1.1rem;
    color: var(--dark-600);
    box-shadow: var(--shadow-sm);
    align-items: center;
    justify-content: center;
}

.topbar-right {
    display: flex;
    align-items: center;
    gap: 16px;
}

.topbar-right .search-box {
    max-width: 280px;
}

.topbar-icon {
    width: 42px;
    height: 42px;
    border: none;
    background: var(--white);
    border-radius: 10px;
    cursor: pointer;
    font-size: 1.05rem;
    color: var(--dark-600);
    position: relative;
    box-shadow: var(--shadow-sm);
    transition: var(--transition);
    display: flex;
    align-items: center;
    justify-content: center;
}

.topbar-icon:hover {
    color: var(--primary);
    box-shadow: var(--shadow-md);
}

.notification-badge {
    position: absolute;
    top: -4px;
    right: -4px;
    background: var(--red);
    color: var(--white);
    font-size: 0.65rem;
    font-weight: 700;
    width: 18px;
    height: 18px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    border: 2px solid var(--gray-100);
}

/* ============================================
   STAT CARDS
   ============================================ */

.stats-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 20px;
    margin-bottom: 28px;
}

.stat-card {
    background: var(--white);
    border-radius: var(--radius-lg);
    padding: 24px;
    display: flex;
    align-items: center;
    gap: 18px;
    box-shadow: var(--shadow-sm);
    border: 1px solid var(--gray-light);
    transition: var(--transition);
    overflow: hidden;
    position: relative;
}

.stat-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 4px;
    height: 100%;
    border-radius: 0 4px 4px 0;
}

.stat-card-blue::before {
    background: var(--primary);
}

.stat-card-green::before {
    background: var(--green);
}

.stat-card-purple::before {
    background: var(--purple);
}

.stat-card-orange::before {
    background: var(--orange);
}

.stat-card:hover {
    transform: translateY(-3px);
    box-shadow: var(--shadow-md);
}

.stat-card-icon {
    width: 52px;
    height: 52px;
    border-radius: var(--radius-md);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.3rem;
    flex-shrink: 0;
}

.stat-card-blue .stat-card-icon {
    background: rgba(37, 99, 235, 0.1);
    color: var(--primary);
}

.stat-card-green .stat-card-icon {
    background: rgba(16, 185, 129, 0.1);
    color: var(--green);
}

.stat-card-purple .stat-card-icon {
    background: rgba(124, 58, 237, 0.1);
    color: var(--purple);
}

.stat-card-orange .stat-card-icon {
    background: rgba(245, 158, 11, 0.1);
    color: var(--orange);
}

.stat-card-label {
    font-size: 0.8rem;
    color: var(--gray);
    text-transform: uppercase;
    letter-spacing: 0.5px;
    font-weight: 600;
}

.stat-card-number {
    font-size: 1.8rem;
    font-weight: 800;
    color: var(--dark);
    letter-spacing: -1px;
    margin: 4px 0;
}

.stat-card-change {
    font-size: 0.78rem;
    font-weight: 600;
    display: inline-flex;
    align-items: center;
    gap: 4px;
}

.stat-card-change.positive {
    color: var(--green);
}

.stat-card-change.neutral {
    color: var(--gray);
}

.stat-card-change.negative {
    color: var(--red);
}

/* ============================================
   DASHBOARD GRID
   ============================================ */

.dashboard-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 24px;
    margin-bottom: 24px;
}

.dash-card {
    background: var(--white);
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow-sm);
    border: 1px solid var(--gray-light);
    overflow: hidden;
}

.dash-card-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 20px 24px;
    border-bottom: 1px solid var(--gray-100);
}

.dash-card-header h3 {
    font-size: 1rem;
    font-weight: 700;
    color: var(--dark);
    display: flex;
    align-items: center;
    gap: 8px;
}

.dash-card-header h3 i {
    color: var(--primary);
}

.dash-card-link {
    font-size: 0.82rem;
    color: var(--primary);
    font-weight: 600;
    transition: var(--transition);
}

.dash-card-link:hover {
    text-decoration: underline;
}

.dash-card-body {
    padding: 24px;
}

/* ============================================
   SKILL DISTRIBUTION (Bar Chart)
   ============================================ */

.skill-distribution {
    display: flex;
    align-items: flex-end;
    gap: 12px;
    height: 200px;
    padding-top: 10px;
}

.skill-dist-item {
    flex: 1;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 10px;
    height: 100%;
}

.skill-dist-bar {
    flex: 1;
    width: 100%;
    background: var(--gray-100);
    border-radius: 6px 6px 0 0;
    display: flex;
    align-items: flex-end;
    overflow: hidden;
}

.skill-dist-fill {
    width: 100%;
    border-radius: 6px 6px 0 0;
    transition: height 1s ease;
    min-height: 10px;
}

.skill-dist-item span {
    font-size: 0.72rem;
    font-weight: 600;
    color: var(--dark-600);
    text-align: center;
}

/* ============================================
   HIRING PIPELINE (Funnel)
   ============================================ */

.pipeline {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.pipeline-stage {
    display: flex;
}

.pipeline-bar {
    padding: 14px 20px;
    background: var(--gradient-primary);
    border-radius: 8px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    color: var(--white);
    font-size: 0.85rem;
    min-width: 100px;
    transition: width 1s ease;
}

.pipeline-bar span {
    font-weight: 500;
}

.pipeline-bar strong {
    font-weight: 800;
}

.pipeline-stage:nth-child(2) .pipeline-bar {
    background: linear-gradient(135deg, #3b82f6, #6366f1);
}

.pipeline-stage:nth-child(3) .pipeline-bar {
    background: linear-gradient(135deg, #6366f1, #8b5cf6);
}

.pipeline-stage:nth-child(4) .pipeline-bar {
    background: linear-gradient(135deg, #8b5cf6, #a855f7);
}

.pipeline-stage:nth-child(5) .pipeline-bar {
    background: linear-gradient(135deg, #a855f7, #c084fc);
}

/* ============================================
   ACTIVITY FEED
   ============================================ */

.activity-feed {
    display: flex;
    flex-direction: column;
    gap: 0;
}

.activity-item {
    display: flex;
    align-items: flex-start;
    gap: 14px;
    padding: 14px 0;
    border-bottom: 1px solid var(--gray-100);
}

.activity-item:last-child {
    border-bottom: none;
    padding-bottom: 0;
}

.activity-item:first-child {
    padding-top: 0;
}

.activity-dot {
    width: 10px;
    height: 10px;
    border-radius: 50%;
    margin-top: 6px;
    flex-shrink: 0;
}

.dot-green {
    background: var(--green);
}

.dot-blue {
    background: var(--primary);
}

.dot-purple {
    background: var(--purple);
}

.dot-orange {
    background: var(--orange);
}

.activity-content {
    font-size: 0.88rem;
    color: var(--dark-600);
    line-height: 1.5;
}

.activity-content strong {
    color: var(--dark);
}

.activity-time {
    display: block;
    font-size: 0.75rem;
    color: var(--gray);
    margin-top: 2px;
}

/* ============================================
   TOP CANDIDATES
   ============================================ */

.top-candidates {
    display: flex;
    flex-direction: column;
    gap: 0;
}

.top-candidate {
    display: flex;
    align-items: center;
    gap: 14px;
    padding: 14px 0;
    border-bottom: 1px solid var(--gray-100);
    transition: var(--transition);
}

.top-candidate:last-child {
    border-bottom: none;
    padding-bottom: 0;
}

.top-candidate:first-child {
    padding-top: 0;
}

.top-candidate:hover {
    padding-left: 6px;
}

.top-candidate-info {
    flex: 1;
}

.top-candidate-info strong {
    display: block;
    font-size: 0.9rem;
    color: var(--dark);
}

.top-candidate-info span {
    font-size: 0.78rem;
    color: var(--gray);
}

/* ============================================
   RESPONSIVE — DASHBOARD
   ============================================ */

@media (max-width: 1100px) {
    .stats-grid {
        grid-template-columns: repeat(2, 1fr);
    }

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

@media (max-width: 768px) {
    .sidebar {
        transform: translateX(-100%);
    }

    .sidebar.mobile-open {
        transform: translateX(0);
    }

    .dashboard-main {
        margin-left: 0;
        padding: 0 16px 32px;
    }

    .mobile-sidebar-toggle {
        display: flex;
    }

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

    .topbar-right .search-box {
        display: none;
    }

    .topbar-left h1 {
        font-size: 1.3rem;
    }
}

/* ===========================
   REPORTS PAGE — Charts & KPIs
   =========================== */

.line-chart,
.donut-chart-wrap {
    background: var(--glass-bg);
    border-radius: var(--radius);
    padding: 24px;
}

.chart-svg {
    width: 100%;
    overflow: visible;
}

.chart-grid-line {
    stroke: #e2e8f0;
    stroke-dasharray: 4 4;
}

.chart-area-fill {
    fill: url(#areaGradient);
    opacity: .45;
}

.chart-line {
    fill: none;
    stroke: var(--primary);
    stroke-width: 2.5;
    stroke-linecap: round;
    stroke-linejoin: round;
}

.chart-dot {
    fill: var(--primary);
    stroke: #fff;
    stroke-width: 2;
    transition: r .2s;
    cursor: pointer;
}

.chart-dot:hover {
    r: 7;
}

.chart-x-axis,
.chart-y-axis {
    fill: #64748b;
    font-size: 11px;
}

.donut-svg {
    display: block;
    margin: 0 auto;
}

.donut-segment {
    transition: opacity .2s;
    cursor: pointer;
}

.donut-segment:hover {
    opacity: .8;
}

.donut-center text {
    font-weight: 700;
}

.donut-legend {
    display: flex;
    flex-wrap: wrap;
    gap: 12px;
    justify-content: center;
    margin-top: 16px;
}

.donut-legend span {
    display: flex;
    align-items: center;
    gap: 6px;
    font-size: .85rem;
    color: #475569;
}

.legend-dot {
    width: 10px;
    height: 10px;
    border-radius: 50%;
    display: inline-block;
}

.chart-legend {
    display: flex;
    gap: 16px;
}

.legend-item {
    display: flex;
    align-items: center;
    gap: 6px;
    font-size: .82rem;
    color: #64748b;
}

.dept-row {
    display: flex;
    align-items: center;
    gap: 16px;
    margin-bottom: 14px;
}

.dept-label {
    min-width: 110px;
    font-size: .88rem;
    font-weight: 500;
    color: #334155;
    text-align: right;
}

.dept-bar {
    flex: 1;
    height: 24px;
    background: #f1f5f9;
    border-radius: 12px;
    overflow: hidden;
}

.dept-bar-fill {
    height: 100%;
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: flex-end;
    padding-right: 10px;
    font-size: .75rem;
    color: #fff;
    font-weight: 600;
    transition: width .8s ease;
}

.hire-item {
    display: flex;
    align-items: center;
    gap: 14px;
    padding: 12px 0;
    border-bottom: 1px solid #f1f5f9;
}

.hire-item:last-child {
    border-bottom: none;
}

.hire-info strong {
    display: block;
    font-size: .92rem;
}

.hire-info span {
    font-size: .82rem;
    color: #64748b;
}

.hire-meta {
    margin-left: auto;
    text-align: right;
}

.hire-meta .badge {
    font-size: .75rem;
    padding: 3px 10px;
    border-radius: 50px;
    background: var(--primary);
    color: #fff;
}

/* ===========================
   SKILL ANALYTICS PAGE
   =========================== */

/* Supply vs Demand bars */
.supply-demand-chart {
    display: flex;
    flex-direction: column;
    gap: 14px;
}

.sd-row {
    display: grid;
    grid-template-columns: 130px 1fr 100px;
    align-items: center;
    gap: 14px;
}

.sd-label {
    font-size: .88rem;
    font-weight: 600;
    color: #334155;
    text-align: right;
}

.sd-bars {
    display: flex;
    flex-direction: column;
    gap: 4px;
}

.sd-bar {
    height: 20px;
    border-radius: 10px;
    display: flex;
    align-items: center;
    justify-content: flex-end;
    padding-right: 10px;
    font-size: .72rem;
    font-weight: 600;
    color: #fff;
    transition: width .8s ease;
}

.sd-supply {
    background: linear-gradient(90deg, var(--primary), #60a5fa);
}

.sd-demand {
    background: linear-gradient(90deg, var(--orange), #fbbf24);
}

.sd-status {
    font-size: .78rem;
    font-weight: 600;
    display: flex;
    align-items: center;
    gap: 4px;
}

.sd-surplus {
    color: var(--green);
}

.sd-deficit {
    color: var(--red);
}

.sd-balanced {
    color: var(--primary);
}

/* Skill Heatmap */
.skill-heatmap {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    margin-bottom: 16px;
}

.heatmap-tag {
    padding: 8px 14px;
    border-radius: 50px;
    font-size: .82rem;
    font-weight: 600;
    display: inline-flex;
    align-items: center;
    gap: 8px;
    transition: transform .2s;
    cursor: default;
}

.heatmap-tag:hover {
    transform: scale(1.08);
}

.heatmap-tag span {
    font-size: .7rem;
    opacity: .8;
}

.heat-5 {
    background: #dc2626;
    color: #fff;
}

.heat-4 {
    background: #f97316;
    color: #fff;
}

.heat-3 {
    background: #eab308;
    color: #1e293b;
}

.heat-2 {
    background: #22c55e;
    color: #fff;
}

.heat-1 {
    background: #38bdf8;
    color: #fff;
}

.heat-0 {
    background: #e2e8f0;
    color: #475569;
}

.heatmap-legend {
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: .8rem;
    color: #64748b;
    justify-content: center;
}

.heat-scale {
    display: flex;
    gap: 2px;
}

.heat-block {
    width: 24px;
    height: 12px;
    border-radius: 3px;
}

.heat-bg-0 {
    background: #e2e8f0;
}

.heat-bg-1 {
    background: #38bdf8;
}

.heat-bg-2 {
    background: #22c55e;
}

.heat-bg-3 {
    background: #eab308;
}

.heat-bg-4 {
    background: #f97316;
}

.heat-bg-5 {
    background: #dc2626;
}

/* Insight Cards */
.insight-cards {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
    gap: 16px;
}

.insight-card {
    padding: 20px;
    border-radius: var(--radius);
    border-left: 4px solid;
    background: #fff;
    box-shadow: 0 1px 4px rgba(0, 0, 0, .06);
}

.insight-critical {
    border-left-color: var(--red);
}

.insight-warning {
    border-left-color: var(--orange);
}

.insight-success {
    border-left-color: var(--green);
}

.insight-header {
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: .78rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: .5px;
    margin-bottom: 8px;
}

.insight-critical .insight-header {
    color: var(--red);
}

.insight-warning .insight-header {
    color: var(--orange);
}

.insight-success .insight-header {
    color: var(--green);
}

.insight-card h4 {
    font-size: 1rem;
    margin-bottom: 6px;
}

.insight-card p {
    font-size: .84rem;
    color: #64748b;
    line-height: 1.5;
    margin-bottom: 12px;
}

.insight-metric {
    display: flex;
    justify-content: space-between;
    font-size: .8rem;
    font-weight: 600;
    color: #475569;
    padding-top: 10px;
    border-top: 1px solid #f1f5f9;
}

/* Trending Skills */
.trending-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
    gap: 12px;
}

.trending-item {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 14px 18px;
    border-radius: var(--radius);
    background: #f8fafc;
    transition: transform .2s, box-shadow .2s;
}

.trending-item:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(0, 0, 0, .08);
}

.trending-icon {
    width: 36px;
    height: 36px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: .85rem;
    color: #fff;
    flex-shrink: 0;
}

.trending-up .trending-icon {
    background: var(--green);
}

.trending-stable .trending-icon {
    background: var(--primary);
}

.trending-down .trending-icon {
    background: var(--red);
}

.trending-info strong {
    display: block;
    font-size: .9rem;
}

.trending-info span {
    font-size: .78rem;
    color: #64748b;
}

.trending-badge {
    margin-left: auto;
    font-size: .72rem;
    font-weight: 700;
    padding: 3px 10px;
    border-radius: 50px;
    text-transform: uppercase;
    letter-spacing: .5px;
}

.trending-hot {
    background: #fef2f2;
    color: var(--red);
}

.trending-rising {
    background: #f0fdf4;
    color: var(--green);
}

.trending-stable-badge {
    background: #eff6ff;
    color: var(--primary);
}

.trending-cooling {
    background: #fefce8;
    color: #a16207;
}

/* ===========================
   SETTINGS PAGE
   =========================== */

.settings-layout {
    display: flex;
    flex-direction: column;
    gap: 24px;
}

.settings-section .dash-card-body {
    padding: 24px;
}

.settings-form {
    display: flex;
    flex-direction: column;
    gap: 18px;
}

.settings-row {
    width: 100%;
}

.settings-row.two-col {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 16px;
}

.avatar-row {
    display: flex;
    justify-content: flex-start;
}

.settings-avatar-edit {
    display: flex;
    align-items: center;
    gap: 20px;
}

.avatar-lg {
    width: 64px;
    height: 64px;
    font-size: 1.4rem;
}

.form-group {
    display: flex;
    flex-direction: column;
    gap: 6px;
}

.form-group label {
    font-size: .85rem;
    font-weight: 600;
    color: #334155;
}

.form-input {
    padding: 10px 14px;
    border: 1.5px solid #e2e8f0;
    border-radius: 10px;
    font-size: .9rem;
    transition: border-color .2s, box-shadow .2s;
    background: #fff;
    color: #1e293b;
    outline: none;
    width: 100%;
    box-sizing: border-box;
}

.form-input:focus {
    border-color: var(--primary);
    box-shadow: 0 0 0 3px rgba(37, 99, 235, .12);
}

.form-textarea {
    resize: vertical;
    min-height: 70px;
}

.form-select {
    padding: 10px 14px;
    border: 1.5px solid #e2e8f0;
    border-radius: 10px;
    font-size: .9rem;
    background: #fff;
    color: #1e293b;
    outline: none;
    cursor: pointer;
    transition: border-color .2s;
}

.form-select:focus {
    border-color: var(--primary);
    box-shadow: 0 0 0 3px rgba(37, 99, 235, .12);
}

.form-hint {
    font-size: .78rem;
    color: #94a3b8;
    margin-top: 2px;
}

/* Toggle Switches */
.toggle-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 14px 0;
    border-bottom: 1px solid #f1f5f9;
}

.toggle-row:last-child {
    border-bottom: none;
    padding-bottom: 0;
}

.toggle-info strong {
    display: block;
    font-size: .9rem;
    color: #1e293b;
}

.toggle-info span {
    font-size: .82rem;
    color: #64748b;
}

.toggle-switch {
    position: relative;
    display: inline-block;
    width: 48px;
    height: 26px;
    flex-shrink: 0;
}

.toggle-switch input {
    opacity: 0;
    width: 0;
    height: 0;
}

.toggle-slider {
    position: absolute;
    cursor: pointer;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: #cbd5e1;
    border-radius: 26px;
    transition: background .3s;
}

.toggle-slider::before {
    content: "";
    position: absolute;
    width: 20px;
    height: 20px;
    left: 3px;
    bottom: 3px;
    background: #fff;
    border-radius: 50%;
    transition: transform .3s;
    box-shadow: 0 1px 3px rgba(0, 0, 0, .15);
}

.toggle-switch input:checked+.toggle-slider {
    background: var(--primary);
}

.toggle-switch input:checked+.toggle-slider::before {
    transform: translateX(22px);
}

/* Range Slider */
.range-group {
    display: flex;
    align-items: center;
    gap: 14px;
}

.form-range {
    flex: 1;
    height: 6px;
    border-radius: 3px;
    background: #e2e8f0;
    outline: none;
    -webkit-appearance: none;
    appearance: none;
}

.form-range::-webkit-slider-thumb {
    -webkit-appearance: none;
    width: 20px;
    height: 20px;
    border-radius: 50%;
    background: var(--primary);
    cursor: pointer;
    box-shadow: 0 2px 6px rgba(37, 99, 235, .3);
}

.range-value {
    font-size: .9rem;
    font-weight: 700;
    color: var(--primary);
    min-width: 40px;
    text-align: center;
}

/* Theme Selector */
.theme-selector {
    display: flex;
    gap: 16px;
}

.theme-option {
    cursor: pointer;
    text-align: center;
    padding: 8px;
    border-radius: var(--radius);
    border: 2px solid transparent;
    transition: border-color .2s;
}

.theme-option.active,
.theme-option:hover {
    border-color: var(--primary);
}

.theme-preview {
    width: 80px;
    height: 56px;
    border-radius: 8px;
    overflow: hidden;
    margin-bottom: 6px;
    position: relative;
}

.tp-nav {
    height: 12px;
}

.tp-body {
    padding: 4px;
    display: flex;
    gap: 3px;
    height: 100%;
}

.tp-block {
    flex: 1;
    border-radius: 3px;
}

.theme-light-preview {
    border: 1px solid #e2e8f0;
}

.theme-light-preview .tp-nav {
    background: #fff;
    border-bottom: 1px solid #e2e8f0;
}

.theme-light-preview .tp-body {
    background: #f8fafc;
}

.theme-light-preview .tp-block {
    background: #fff;
}

.theme-dark-preview {
    border: 1px solid #334155;
}

.theme-dark-preview .tp-nav {
    background: #1e293b;
}

.theme-dark-preview .tp-body {
    background: #0f172a;
}

.theme-dark-preview .tp-block {
    background: #1e293b;
}

.theme-system-preview {
    border: 1px solid #e2e8f0;
    background: linear-gradient(135deg, #f8fafc 50%, #1e293b 50%);
}

.theme-system-preview .tp-nav {
    background: linear-gradient(90deg, #fff 50%, #1e293b 50%);
}

.theme-system-preview .tp-body {
    background: transparent;
}

.theme-system-preview .tp-block {
    background: linear-gradient(135deg, #fff 50%, #334155 50%);
}

.theme-option span {
    font-size: .8rem;
    font-weight: 600;
    color: #475569;
}

/* Danger Zone */
.danger-section {
    border: 1.5px solid #fecaca;
}

.danger-section .dash-card-header h3 {
    color: var(--red);
}

.danger-actions {
    display: flex;
    flex-direction: column;
    gap: 16px;
}

.danger-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 16px 0;
    border-bottom: 1px solid #fef2f2;
}

.danger-row:last-child {
    border-bottom: none;
    padding-bottom: 0;
}

.danger-info strong {
    display: block;
    font-size: .9rem;
    color: #1e293b;
}

.danger-info p {
    font-size: .82rem;
    color: #64748b;
    margin-top: 2px;
}

.btn-danger-outline {
    background: transparent;
    border: 1.5px solid var(--red);
    color: var(--red);
    padding: 8px 18px;
    border-radius: 10px;
    font-size: .85rem;
    font-weight: 600;
    cursor: pointer;
    transition: all .2s;
}

.btn-danger-outline:hover {
    background: var(--red);
    color: #fff;
}

.btn-danger {
    background: var(--red);
    color: #fff;
    border: none;
    padding: 8px 18px;
    border-radius: 10px;
    font-size: .85rem;
    font-weight: 600;
    cursor: pointer;
    transition: all .2s;
}

.btn-danger:hover {
    background: #dc2626;
    box-shadow: 0 4px 12px rgba(239, 68, 68, .3);
}

.btn-outline {
    background: transparent;
    border: 1.5px solid #e2e8f0;
    color: #475569;
    padding: 8px 18px;
    border-radius: 10px;
    font-size: .85rem;
    font-weight: 600;
    cursor: pointer;
    transition: all .2s;
}

.btn-outline:hover {
    border-color: var(--primary);
    color: var(--primary);
}

.btn-sm {
    padding: 6px 14px;
    font-size: .82rem;
}

/* ===========================
   HELP PAGE
   =========================== */

.help-search-section {
    margin-bottom: 24px;
}

.help-search-wrap {
    position: relative;
    max-width: 600px;
    margin: 0 auto;
}

.help-search-wrap i {
    position: absolute;
    left: 16px;
    top: 50%;
    transform: translateY(-50%);
    color: #94a3b8;
    font-size: 1rem;
}

.help-search-input {
    padding-left: 44px !important;
    font-size: 1rem !important;
    height: 50px;
    border-radius: 50px !important;
    box-shadow: 0 4px 16px rgba(0, 0, 0, .06);
}

.help-quick-links {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
    gap: 16px;
    margin-bottom: 28px;
}

.help-quick-card {
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
    padding: 24px 16px;
    border-radius: var(--radius);
    background: var(--glass-bg);
    backdrop-filter: blur(12px);
    border: 1px solid rgba(255, 255, 255, .3);
    text-decoration: none;
    color: #1e293b;
    transition: transform .2s, box-shadow .2s;
}

.help-quick-card:hover {
    transform: translateY(-4px);
    box-shadow: 0 8px 24px rgba(0, 0, 0, .1);
}

.hq-icon {
    width: 48px;
    height: 48px;
    border-radius: 14px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #fff;
    font-size: 1.2rem;
    margin-bottom: 10px;
}

.help-quick-card strong {
    font-size: .92rem;
}

.help-quick-card span {
    font-size: .78rem;
    color: #64748b;
}

/* Steps Guide */
.steps-guide {
    display: flex;
    flex-direction: column;
    gap: 20px;
}

.step-guide-item {
    display: flex;
    gap: 16px;
    align-items: flex-start;
}

.step-number {
    width: 36px;
    height: 36px;
    border-radius: 50%;
    background: linear-gradient(135deg, var(--primary), var(--purple));
    color: #fff;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 700;
    font-size: .9rem;
    flex-shrink: 0;
}

.step-content h4 {
    font-size: .95rem;
    margin-bottom: 4px;
}

.step-content p {
    font-size: .85rem;
    color: #475569;
    line-height: 1.6;
}

.step-content a {
    color: var(--primary);
    font-weight: 500;
    text-decoration: underline;
}

/* FAQ Accordion */
.faq-list {
    display: flex;
    flex-direction: column;
    gap: 4px;
}

.faq-item {
    border: 1px solid #f1f5f9;
    border-radius: 10px;
    overflow: hidden;
    transition: border-color .2s;
}

.faq-item.active {
    border-color: var(--primary);
}

.faq-question {
    width: 100%;
    padding: 16px 20px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    background: #f8fafc;
    border: none;
    cursor: pointer;
    font-size: .9rem;
    font-weight: 600;
    color: #1e293b;
    transition: background .2s;
    text-align: left;
}

.faq-question:hover {
    background: #f1f5f9;
}

.faq-question i {
    transition: transform .3s;
    color: #64748b;
    font-size: .8rem;
}

.faq-item.active .faq-question i {
    transform: rotate(180deg);
    color: var(--primary);
}

.faq-answer {
    max-height: 0;
    overflow: hidden;
    transition: max-height .35s ease, padding .35s ease;
    padding: 0 20px;
}

.faq-item.active .faq-answer {
    max-height: 200px;
    padding: 12px 20px 20px;
}

.faq-answer p {
    font-size: .88rem;
    color: #475569;
    line-height: 1.7;
}

.faq-answer a {
    color: var(--primary);
    font-weight: 500;
}

.faq-item.hidden {
    display: none;
}

/* Keyboard Shortcuts */
.shortcuts-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
    gap: 12px;
}

.shortcut-item {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 12px 16px;
    background: #f8fafc;
    border-radius: 10px;
    gap: 10px;
}

.shortcut-keys {
    display: flex;
    align-items: center;
    gap: 4px;
    flex-shrink: 0;
}

kbd {
    display: inline-block;
    padding: 3px 8px;
    background: #fff;
    border: 1px solid #d1d5db;
    border-radius: 5px;
    font-size: .78rem;
    font-weight: 600;
    font-family: inherit;
    color: #334155;
    box-shadow: 0 1px 2px rgba(0, 0, 0, .08);
}

.shortcut-item span {
    font-size: .84rem;
    color: #475569;
}

/* Contact Section */
.contact-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 16px;
    margin-bottom: 28px;
}

.contact-method {
    text-align: center;
    padding: 24px 16px;
    border-radius: var(--radius);
    background: #f8fafc;
    transition: transform .2s;
}

.contact-method:hover {
    transform: translateY(-2px);
}

.contact-icon {
    width: 50px;
    height: 50px;
    border-radius: 50%;
    background: linear-gradient(135deg, var(--primary), var(--purple));
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 12px;
    color: #fff;
    font-size: 1.2rem;
}

.contact-method h4 {
    font-size: .95rem;
    margin-bottom: 4px;
}

.contact-method p {
    font-size: .82rem;
    color: #64748b;
    margin-bottom: 10px;
}

.contact-method span {
    font-size: .78rem;
    color: #94a3b8;
}

.support-form-wrap {
    border-top: 1px solid #f1f5f9;
    padding-top: 24px;
}

.support-form-wrap h4 {
    font-size: 1rem;
    margin-bottom: 16px;
    display: flex;
    align-items: center;
    gap: 8px;
    color: #1e293b;
}

.support-form {
    display: flex;
    flex-direction: column;
    gap: 14px;
    max-width: 640px;
}

/* ===========================
   RESPONSIVE — New Pages
   =========================== */

@media (max-width: 768px) {
    .sd-row {
        grid-template-columns: 1fr;
        gap: 4px;
    }

    .sd-label {
        text-align: left;
    }

    .sd-status {
        justify-self: start;
    }

    .settings-row.two-col {
        grid-template-columns: 1fr;
    }

    .insight-cards {
        grid-template-columns: 1fr;
    }

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

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

    .help-quick-links {
        grid-template-columns: 1fr 1fr;
    }

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

    .danger-row {
        flex-direction: column;
        align-items: flex-start;
        gap: 10px;
    }

    .theme-selector {
        flex-wrap: wrap;
    }
}