/* SOM dashboard shell (shared with portal embed pages) */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

:root {
    --sidebar-width: 260px;
    --sidebar-collapsed-width: 72px;
    --topbar-height: 56px;
    --subheader-height: 48px;
    
    /* Açık Tema */
    --bg: #f8fafc;
    --bg-secondary: #f1f5f9;
    --bg-elevated: #ffffff;
    --text: #0f172a;
    --text-secondary: #334155;
    --muted: #64748b;
    --border: #e2e8f0;
    --border-strong: #cbd5e1;
    
    --primary: #2563eb;
    --primary-hover: #1d4ed8;
    --primary-light: #dbeafe;
    --primary-muted: rgba(37, 99, 235, 0.1);
    
    --success: #10b981;
    --success-light: #d1fae5;
    --danger: #ef4444;
    --danger-light: #fee2e2;
    --warning: #f59e0b;
    --warning-light: #fed7aa;
    --info: #8b5cf6;
    --info-light: #ede9fe;
    
    --shadow-sm: 0 1px 2px 0 rgb(0 0 0 / 0.05);
    --shadow-md: 0 4px 6px -1px rgb(0 0 0 / 0.1), 0 2px 4px -2px rgb(0 0 0 / 0.1);
    --shadow-lg: 0 10px 15px -3px rgb(0 0 0 / 0.1), 0 4px 6px -4px rgb(0 0 0 / 0.1);
    
    --font-mono: 'SF Mono', 'Monaco', 'Inconsolata', 'Fira Code', monospace;
    --transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

[data-theme="dark"] {
    --bg: #0f172a;
    --bg-secondary: #1e293b;
    --bg-elevated: #1e293b;
    --text: #f8fafc;
    --text-secondary: #cbd5e1;
    --muted: #94a3b8;
    --border: #334155;
    --border-strong: #475569;
}

body {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', 'Inter', system-ui, sans-serif;
    background: var(--bg);
    color: var(--text);
    margin: 0;
    min-height: 100vh;
}

/* Layout */
.som-layout {
    display: flex;
    width: 100%;
    min-height: 100vh;
}

/* ========== SIDEBAR ========== */
.som-sidebar {
    width: var(--sidebar-width);
    height: 100vh;
    position: fixed;
    left: 0;
    top: 0;
    background: var(--bg-elevated);
    border-right: 1px solid var(--border);
    display: flex;
    flex-direction: column;
    z-index: 1000;
    transition: width 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

.som-sidebar.collapsed {
    width: var(--sidebar-collapsed-width);
}

.sidebar-header {
    height: var(--topbar-height);
    padding: 0 20px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    border-bottom: 1px solid var(--border);
}

.sidebar-logo {
    display: flex;
    align-items: center;
    gap: 12px;
    font-size: 1.25rem;
    font-weight: 900;
}

.logo-icon {
    width: 30px;
    height: 30px;
    object-fit: contain;
    display: block;
}

.logo-text {
    color: var(--primary);
}

.sidebar-toggle {
    width: 32px;
    height: 32px;
    border: none;
    background: transparent;
    border-radius: 6px;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--text-secondary);
    transition: all 0.2s;
}

.sidebar-toggle:hover {
    background: var(--bg-secondary);
    color: var(--text);
}

.sidebar-quick-actions {
    padding: 16px;
    border-bottom: 1px solid var(--border);
}

.btn-quick-action {
    width: 100%;
    height: 40px;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    background: linear-gradient(135deg, var(--primary), var(--primary-hover));
    color: white;
    border: none;
    border-radius: 8px;
    font-weight: 600;
    font-size: 0.875rem;
    cursor: pointer;
    transition: all 0.2s;
}

.btn-quick-action:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(37, 99, 235, 0.3);
}

a.btn-quick-action {
    text-decoration: none;
    color: #fff;
    box-sizing: border-box;
}

.sidebar-nav {
    flex: 1;
    overflow-y: auto;
    padding: 16px 0;
    scrollbar-width: thin;
}

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

.nav-section-title {
    padding: 8px 20px;
    font-size: 0.75rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    color: var(--muted);
}

.nav-item {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 10px 20px;
    margin: 2px 12px;
    border-radius: 8px;
    color: var(--text-secondary);
    text-decoration: none;
    font-size: 0.9rem;
    font-weight: 500;
    transition: all 0.15s;
    position: relative;
    cursor: pointer;
}

.nav-item i {
    width: 20px;
    height: 20px;
    flex-shrink: 0;
}

.nav-item:hover {
    background: var(--bg-secondary);
    color: var(--text);
}

.nav-item.active {
    background: var(--primary-light);
    color: var(--primary);
    font-weight: 600;
}

.nav-item.active::before {
    content: '';
    position: absolute;
    left: 0;
    top: 50%;
    transform: translateY(-50%);
    width: 3px;
    height: 60%;
    background: var(--primary);
    border-radius: 0 3px 3px 0;
}

.badge {
    padding: 2px 8px;
    border-radius: 999px;
    font-size: 0.7rem;
    font-weight: 700;
    margin-left: auto;
}

.badge-primary { background: var(--primary); color: white; }
.badge-danger { background: var(--danger); color: white; }
.badge-success { background: var(--success); color: white; }
.badge-warning { background: var(--warning); color: white; }
.badge-info { background: var(--info); color: white; }

.sidebar-footer {
    padding: 16px;
    border-top: 1px solid var(--border);
}

.user-profile-mini {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 8px;
    border-radius: 8px;
    width: 100%;
    box-sizing: border-box;
}

.user-profile-mini:hover {
    background: var(--bg-secondary);
}

.user-profile-mini__link {
    display: flex;
    align-items: center;
    gap: 12px;
    flex: 1;
    min-width: 0;
    text-decoration: none;
    color: inherit;
    cursor: pointer;
}
.user-profile-mini__logout {
    width: 28px !important;
    height: 28px !important;
    min-width: 28px;
    margin-left: auto;
    flex-shrink: 0;
    text-decoration: none;
}

.user-profile-mini__link:hover {
    opacity: 0.92;
}

.avatar-sm {
    width: 36px;
    height: 36px;
    border-radius: 50%;
}

.user-info {
    flex: 1;
    min-width: 0;
}

.user-name {
    font-size: 0.875rem;
    font-weight: 600;
    color: var(--text);
}

.user-job-title {
    font-size: 0.75rem;
    color: var(--muted);
    margin-top: 2px;
    line-height: 1.3;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.user-status {
    font-size: 0.75rem;
    color: var(--muted);
    display: flex;
    align-items: center;
    gap: 6px;
}

.status-dot {
    width: 6px;
    height: 6px;
    border-radius: 50%;
}
.status-online { background: var(--success); }
.status-away { background: var(--warning); }
.status-busy { background: var(--danger); }

/* Collapsed Sidebar */
.som-sidebar.collapsed .logo-text,
.som-sidebar.collapsed .nav-item span:not(.status-indicator),
.som-sidebar.collapsed .nav-section-title,
.som-sidebar.collapsed .user-info,
.som-sidebar.collapsed .badge {
    display: none;
}
.som-sidebar.collapsed .nav-item {
    justify-content: center;
}

/* ========== TOPBAR ========== */
.som-topbar {
    height: var(--topbar-height);
    background: var(--bg-elevated);
    border-bottom: 1px solid var(--border);
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 0 24px;
    position: fixed;
    top: 0;
    left: var(--sidebar-width);
    right: 0;
    z-index: 999;
    transition: left 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    overflow: visible;
}

/* Bildirim kartı açıkken üst bar + açılır menü her şeyin üstünde (ör. gömülü sohbet FAB) */
.som-topbar.som-topbar--notif-open {
    z-index: 20100;
}

.global-search {
    width: 400px;
    height: 40px;
    background: var(--bg-secondary);
    border: 1px solid var(--border);
    border-radius: 8px;
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 0 16px;
    transition: all 0.2s;
}
.global-search:focus-within {
    background: var(--bg-elevated);
    border-color: var(--primary);
    box-shadow: 0 0 0 3px var(--primary-muted);
}
.search-input {
    flex: 1;
    border: none;
    background: transparent;
    font-size: 0.875rem;
    outline: none;
    color: var(--text);
}
.kbd {
    padding: 2px 6px;
    background: var(--bg);
    border: 1px solid var(--border);
    border-radius: 4px;
    font-size: 0.7rem;
    font-family: monospace;
    color: var(--muted);
}
.topbar-right {
    display: flex;
    align-items: center;
    gap: 8px;
    overflow: visible;
    position: relative;
    z-index: 2;
}

.topbar-dropdown {
    position: relative;
}

.topbar-dropdown.som-topbar-notif {
    z-index: 1;
}

.topbar-dropdown.som-topbar-notif.som-topbar-notif--open {
    z-index: 20000;
}

.som-topbar-notif__trigger {
    position: relative;
}

.som-topbar-notif__badge {
    position: absolute;
    top: 4px;
    right: 4px;
    min-width: 18px;
    height: 18px;
    padding: 0 5px;
    background: var(--primary);
    color: #fff;
    border-radius: 999px;
    font-size: 0.65rem;
    font-weight: 700;
    display: flex;
    align-items: center;
    justify-content: center;
    line-height: 1;
    border: 2px solid var(--bg-elevated);
    box-sizing: border-box;
}

.som-topbar-notif__badge[hidden] {
    display: none !important;
}

.som-chat-nav-badge {
    margin-left: auto;
    min-width: 18px;
    height: 18px;
    padding: 0 5px;
    border-radius: 999px;
    background: #ef4444;
    color: #fff;
    font-size: 0.65rem;
    font-weight: 700;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    line-height: 1;
}

.som-chat-nav-badge[hidden] {
    display: none !important;
}

/* Bildirim paneli — Bootstrap kartına benzer; transition yok (kayma hissi olmasın) */
.som-topbar-notif__panel.som-bs-card {
    position: absolute;
    right: 0;
    top: calc(100% + 6px);
    width: min(400px, calc(100vw - 40px));
    max-height: min(440px, 75vh);
    min-width: 280px;
    background: var(--bg-elevated);
    border: 1px solid var(--border-strong);
    border-radius: 0.5rem;
    box-shadow: 0 0.75rem 1.5rem rgba(15, 23, 42, 0.18);
    z-index: 20001;
    flex-direction: column;
    overflow: hidden;
    transition: none;
    transform: none;
    animation: none;
    will-change: auto;
}

[data-theme="dark"] .som-topbar-notif__panel.som-bs-card {
    box-shadow: 0 0.5rem 1.25rem rgba(0, 0, 0, 0.45);
}

.som-topbar-notif__panel:not([hidden]) {
    display: flex;
}

.som-topbar-notif__panel[hidden] {
    display: none !important;
}

.som-bs-card-header {
    padding: 0.75rem 1rem;
    background: var(--bg-secondary);
    border-bottom: 1px solid var(--border);
    flex-shrink: 0;
    border-radius: 0.5rem 0.5rem 0 0;
}

.som-bs-card-title {
    margin: 0;
    font-size: 1rem;
    font-weight: 600;
    color: var(--text);
    line-height: 1.4;
}

.som-bs-card-body {
    padding: 0;
    flex: 1;
    min-height: 0;
    display: flex;
    flex-direction: column;
    overflow: hidden;
}

.som-bs-card-body .som-topbar-notif__list {
    overflow-y: auto;
    flex: 1;
    min-height: 0;
    max-height: min(360px, 60vh);
}

.som-topbar-notif__err {
    padding: 16px 14px;
    text-align: center;
    font-size: 0.85rem;
    color: var(--danger);
}

.som-topbar-notif__item {
    display: block;
    width: 100%;
    text-align: left;
    padding: 12px 14px;
    border: none;
    border-bottom: 1px solid var(--border);
    background: var(--bg-elevated);
    cursor: pointer;
    font-size: 0.875rem;
    color: inherit;
    font-family: inherit;
    text-decoration: none;
    box-sizing: border-box;
}

.som-topbar-notif__item:last-child {
    border-bottom: none;
}

.som-topbar-notif__item:hover {
    background: var(--bg-secondary);
}

.som-topbar-notif__item--unread {
    background: var(--primary-muted);
}

.som-topbar-notif__item-title {
    font-weight: 700;
    margin: 0 0 4px;
    color: var(--text);
}

.som-topbar-notif__item-body {
    margin: 0;
    font-size: 0.8125rem;
    color: var(--text-secondary);
    line-height: 1.4;
}

.som-topbar-notif__item-meta {
    margin-top: 6px;
    font-size: 0.7rem;
    color: var(--muted);
}

a.topbar-user.som-topbar-profile-link {
    text-decoration: none;
    color: inherit;
}

.visually-hidden {
    position: absolute !important;
    width: 1px !important;
    height: 1px !important;
    padding: 0 !important;
    margin: -1px !important;
    overflow: hidden !important;
    clip: rect(0, 0, 0, 0) !important;
    white-space: nowrap !important;
    border: 0 !important;
}
.btn-icon {
    width: 40px;
    height: 40px;
    border: none;
    background: transparent;
    border-radius: 8px;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--text-secondary);
    transition: all 0.2s;
    position: relative;
}
.btn-icon:hover {
    background: var(--bg-secondary);
    color: var(--text);
}
.badge-dot {
    position: absolute;
    top: 8px;
    right: 8px;
    width: 18px;
    height: 18px;
    background: var(--danger);
    color: white;
    border-radius: 999px;
    font-size: 0.7rem;
    font-weight: 700;
    display: flex;
    align-items: center;
    justify-content: center;
    border: 2px solid var(--bg-elevated);
}
.topbar-user {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 6px 12px;
    border-radius: 8px;
    cursor: pointer;
    transition: all 0.2s;
    text-decoration: none;
    color: inherit;
}
.topbar-user:hover {
    background: var(--bg-secondary);
}
.avatar-xs {
    width: 32px;
    height: 32px;
    border-radius: 50%;
}

/* ========== MAIN CONTENT ========== */
.som-main {
    margin-left: var(--sidebar-width);
    margin-top: var(--topbar-height);
    min-height: calc(100vh - var(--topbar-height));
    background: var(--bg);
    transition: margin-left 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    width: 100%;
}

.som-subheader {
    height: var(--subheader-height);
    background: var(--bg-elevated);
    border-bottom: 1px solid var(--border);
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 0 32px;
}

.som-dash-range-modal {
    z-index: 10060;
}
.som-dash-range-modal__box {
    max-width: 420px;
}
.som-dash-range-modal__lead {
    margin: -4px 0 16px;
    font-size: 0.82rem;
    line-height: 1.45;
    color: var(--text-secondary);
}
.som-dash-range-modal__form {
    margin: 0;
}
.som-dash-range-modal__presets {
    display: flex;
    flex-direction: column;
    gap: 10px;
    margin-bottom: 14px;
    font-size: 0.875rem;
}
.som-dash-range-modal__presets label {
    display: flex;
    align-items: center;
    gap: 10px;
    cursor: pointer;
    color: var(--text);
}
.som-dash-range-modal__custom {
    display: flex;
    flex-direction: column;
    gap: 10px;
    margin-bottom: 16px;
}
.som-dash-range-modal__date-lbl {
    display: flex;
    flex-direction: column;
    gap: 4px;
    font-size: 0.78rem;
    font-weight: 600;
    color: var(--muted);
}
.som-dash-range-modal__date-lbl .inp,
.som-dash-range-modal__box .inp {
    width: 100%;
    max-width: none;
    box-sizing: border-box;
    padding: 10px 12px;
    border: 1px solid var(--border);
    border-radius: 8px;
    font: inherit;
    font-size: 0.9rem;
    font-weight: 400;
    background: var(--bg);
    color: var(--text);
}
.som-dash-range-modal__actions {
    display: flex;
    justify-content: flex-end;
    gap: 10px;
    flex-wrap: wrap;
    margin-top: 4px;
}
.som-dash-range-card-hint {
    font-size: 0.8rem;
    color: var(--muted);
    font-weight: 500;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    max-width: 220px;
}

.breadcrumb {
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 0.875rem;
}
.breadcrumb-item {
    color: var(--muted);
    text-decoration: none;
}
.breadcrumb-item.active {
    color: var(--text);
    font-weight: 600;
}

.som-content {
    padding: 32px;
    max-width: 1600px;
    margin: 0 auto;
}

/* Buttons */
.btn {
    padding: 8px 16px;
    border-radius: 8px;
    font-size: 0.875rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.2s;
    border: none;
    display: inline-flex;
    align-items: center;
    gap: 8px;
}
.btn-primary {
    background: var(--primary);
    color: white;
}
.btn-primary:hover {
    background: var(--primary-hover);
    transform: translateY(-1px);
}
.btn-secondary {
    background: var(--bg-secondary);
    color: var(--text);
    border: 1px solid var(--border);
}
.btn-secondary:hover {
    background: var(--bg);
}
.btn-danger {
    background: var(--danger);
    color: white;
}
.btn-sm {
    padding: 6px 12px;
    font-size: 0.75rem;
}

/* KPI Cards */
.kpi-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 20px;
    margin-bottom: 32px;
}
.kpi-card {
    background: var(--bg-elevated);
    border-radius: 12px;
    padding: 24px;
    display: flex;
    gap: 20px;
    border: 1px solid var(--border);
    transition: all 0.3s;
}
.kpi-card:hover {
    transform: translateY(-4px);
    box-shadow: var(--shadow-md);
}
.kpi-icon {
    width: 56px;
    height: 56px;
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.5rem;
}
.kpi-primary .kpi-icon { background: var(--primary-light); color: var(--primary); }
.kpi-danger .kpi-icon { background: var(--danger-light); color: var(--danger); }
.kpi-warning .kpi-icon { background: var(--warning-light); color: var(--warning); }
.kpi-success .kpi-icon { background: var(--success-light); color: var(--success); }
.kpi-info .kpi-icon { background: var(--info-light); color: var(--info); }
.kpi-content { flex: 1; }
.kpi-label {
    font-size: 0.75rem;
    font-weight: 600;
    color: var(--muted);
    text-transform: uppercase;
    letter-spacing: 0.05em;
    margin-bottom: 4px;
}
.kpi-value {
    font-size: 2rem;
    font-weight: 800;
    line-height: 1.2;
    margin-bottom: 8px;
}
.kpi-change {
    font-size: 0.7rem;
    display: flex;
    align-items: center;
    gap: 4px;
}
.kpi-change.positive { color: var(--success); }
.kpi-change.negative { color: var(--danger); }
.kpi-change.neutral { color: var(--muted); }

/* Dashboard Grid */
.dashboard-grid {
    display: grid;
    grid-template-columns: repeat(12, 1fr);
    gap: 24px;
    margin-bottom: 32px;
}
.card-8 { grid-column: span 8; }
.card-6 { grid-column: span 6; }
.card-4 { grid-column: span 4; }
.card-12 { grid-column: span 12; }

.dashboard-card {
    background: var(--bg-elevated);
    border-radius: 12px;
    border: 1px solid var(--border);
    overflow: hidden;
    transition: all 0.3s;
}
.dashboard-card:hover {
    box-shadow: var(--shadow-md);
}
.card-header {
    padding: 20px 24px;
    border-bottom: 1px solid var(--border);
    display: flex;
    align-items: center;
    justify-content: space-between;
}
.card-title {
    font-size: 1rem;
    font-weight: 700;
    margin: 0;
}
.card-actions {
    display: flex;
    gap: 8px;
}
.card-body {
    padding: 24px;
}
.card-body.p-0 { padding: 0; }

/* Table */
.table-wrapper {
    overflow-x: auto;
}
.data-table {
    width: 100%;
    border-collapse: collapse;
}
.data-table th {
    padding: 14px 16px;
    text-align: left;
    font-size: 0.75rem;
    font-weight: 700;
    color: var(--text-secondary);
    text-transform: uppercase;
    letter-spacing: 0.05em;
    border-bottom: 2px solid var(--border);
}
.data-table td {
    padding: 14px 16px;
    font-size: 0.875rem;
    border-bottom: 1px solid var(--border);
}
.data-table tbody tr {
    transition: all 0.2s;
}
.data-table tbody tr:hover {
    background: var(--bg-secondary);
    cursor: pointer;
}

/* Badges */
.badge-status, .badge-severity {
    padding: 4px 10px;
    border-radius: 6px;
    font-size: 0.7rem;
    font-weight: 600;
    display: inline-flex;
    align-items: center;
    gap: 4px;
}
.status-open { background: #fef3c7; color: #92400e; }
.status-inprogress { background: #dbeafe; color: #1e40af; }
.status-resolved { background: #dcfce7; color: #166534; }
.status-closed { background: #f1f5f9; color: #475569; }
.severity-critical { background: #fee2e2; color: #991b1b; }
.severity-high { background: #fed7aa; color: #9a3412; }
.severity-medium { background: #fef3c7; color: #92400e; }
.severity-low { background: #e0f2fe; color: #075985; }

/* Activity Feed */
.activity-list {
    display: flex;
    flex-direction: column;
    gap: 16px;
}
.activity-item {
    display: flex;
    gap: 12px;
    align-items: flex-start;
}
.activity-icon {
    width: 32px;
    height: 32px;
    border-radius: 8px;
    background: var(--bg-secondary);
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
}
.activity-content {
    flex: 1;
}
.activity-title {
    font-weight: 600;
    font-size: 0.875rem;
    margin-bottom: 2px;
}
.activity-time {
    font-size: 0.7rem;
    color: var(--muted);
}

/* Top Teams */
.team-list {
    display: flex;
    flex-direction: column;
    gap: 16px;
}
.team-item {
    display: flex;
    align-items: center;
    gap: 12px;
}
.team-avatar {
    width: 40px;
    height: 40px;
    border-radius: 10px;
    background: var(--bg-secondary);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.2rem;
    color: var(--primary);
}
.team-avatar i {
    width: 20px;
    height: 20px;
}
.team-info {
    flex: 1;
}
.team-name {
    font-weight: 600;
    font-size: 0.875rem;
}
.team-stats {
    font-size: 0.7rem;
    color: var(--muted);
}
.team-progress {
    width: 80px;
    height: 6px;
    background: var(--bg-secondary);
    border-radius: 3px;
    overflow: hidden;
}
.team-progress-bar {
    height: 100%;
    background: var(--primary);
    border-radius: 3px;
}

canvas {
    max-height: 280px;
    width: 100% !important;
}

/* Uygulama modalı (alert / onay) */
.som-app-modal {
    position: fixed;
    inset: 0;
    z-index: 10050;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 24px;
    box-sizing: border-box;
}
.som-app-modal[hidden] {
    display: none !important;
}
.som-app-modal__backdrop {
    position: absolute;
    inset: 0;
    background: rgba(15, 23, 42, 0.45);
    cursor: pointer;
}
.som-app-modal__box {
    position: relative;
    z-index: 1;
    width: 100%;
    max-width: 420px;
    background: var(--bg-elevated);
    border: 1px solid var(--border);
    border-radius: 12px;
    box-shadow: var(--shadow-lg);
    padding: 22px 22px 18px;
}
.som-app-modal__title {
    margin: 0 0 10px;
    font-size: 1.05rem;
    font-weight: 700;
    color: var(--text);
}
.som-app-modal__body {
    margin: 0 0 20px;
    font-size: 0.9rem;
    line-height: 1.5;
    color: var(--text-secondary);
    white-space: pre-wrap;
    word-break: break-word;
}
.som-app-modal__actions {
    display: flex;
    justify-content: flex-end;
    gap: 10px;
    flex-wrap: wrap;
}
.som-app-modal__actions .btn {
    min-width: 88px;
}

/* Toast Notifications */
.toast-container {
    position: fixed;
    bottom: 24px;
    right: 24px;
    z-index: 9999;
    display: flex;
    flex-direction: column;
    gap: 12px;
}
.toast {
    background: var(--bg-elevated);
    border: 1px solid var(--border);
    border-radius: 8px;
    padding: 16px;
    display: flex;
    align-items: center;
    gap: 12px;
    box-shadow: var(--shadow-lg);
    min-width: 300px;
    animation: slideIn 0.3s ease-out;
}
@keyframes slideIn {
    from {
        transform: translateX(400px);
        opacity: 0;
    }
    to {
        transform: translateX(0);
        opacity: 1;
    }
}
.toast-icon {
    width: 32px;
    height: 32px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
}
.toast-success .toast-icon {
    background: var(--success-light);
    color: var(--success);
}
.toast-message {
    flex: 1;
    font-size: 0.875rem;
    font-weight: 500;
}
.toast-close {
    width: 24px;
    height: 24px;
    border: none;
    background: transparent;
    cursor: pointer;
    border-radius: 4px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--muted);
}
.toast-close:hover {
    background: var(--bg-secondary);
}

@media (max-width: 1024px) {
    .dashboard-grid {
        display: flex;
        flex-direction: column;
    }
    .global-search {
        width: 300px;
    }
}

@media (max-width: 768px) {
    .som-sidebar {
        width: var(--sidebar-collapsed-width);
    }
    .som-main {
        margin-left: var(--sidebar-collapsed-width);
    }
    .som-topbar {
        left: var(--sidebar-collapsed-width);
    }
    .global-search {
        width: 200px;
    }
}
