@import url('https://fonts.googleapis.com/css2?family=Outfit:wght@300;400;500;600;700;800&family=Plus+Jakarta+Sans:wght@300;400;500;600;700;800&display=swap');

:root {
    /* Clean Light Minimalist Base Palette */
    --bg-base: #f8fafc;
    --bg-surface: #ffffff;
    --bg-card: #ffffff;
    --bg-card-hover: #f1f5f9;
    --bg-sidebar: #ffffff;
    --bg-topbar: rgba(255, 255, 255, 0.95);
    
    /* Clean Borders & Shadows */
    --border-color: #e2e8f0;
    --border-hover: #cbd5e1;
    --border-subtle: #f1f5f9;
    
    /* Eco / Technology Accents */
    --primary: #0d9488;
    --primary-hover: #0f766e;
    --primary-light: #f0fdf4;
    --primary-glow: rgba(13, 148, 136, 0.08);
    --primary-neon: #10b981;
    
    --secondary: #0284c7;
    --secondary-hover: #0369a1;
    --secondary-light: #f0f9ff;
    --secondary-glow: rgba(2, 132, 199, 0.08);
    
    /* Typography & Contrast */
    --text-main: #0f172a;
    --text-muted: #64748b;
    --text-light: #94a3b8;
    --text-dark: #020617;
    
    /* Status Colors */
    --success: #10b981;
    --success-bg: #ecfdf5;
    --warning: #f59e0b;
    --warning-bg: #fffbeb;
    --danger: #ef4444;
    --danger-bg: #fef2f2;
    --info: #0284c7;
    --info-bg: #f0f9ff;
    
    --font-heading: 'Outfit', -apple-system, BlinkMacSystemFont, sans-serif;
    --font-body: 'Plus Jakarta Sans', -apple-system, BlinkMacSystemFont, sans-serif;
    
    --sidebar-width: 260px;
    --sidebar-collapsed-width: 70px;
    --topbar-height: 70px;
    
    --shadow-sm: 0 1px 2px 0 rgba(0, 0, 0, 0.03);
    --shadow-card: 0 1px 3px 0 rgba(15, 23, 42, 0.05), 0 1px 2px -1px rgba(15, 23, 42, 0.03);
    --shadow-card-hover: 0 10px 25px -5px rgba(15, 23, 42, 0.06), 0 8px 10px -6px rgba(15, 23, 42, 0.03);
    --shadow-dropdown: 0 20px 25px -5px rgba(15, 23, 42, 0.08), 0 8px 10px -6px rgba(15, 23, 42, 0.04);
    
    --transition-smooth: all 0.2s cubic-bezier(0.4, 0, 0.2, 1);

    /* Layer Z-Indices */
    --z-content: 1;
    --z-sticky: 100;
    --z-popover: 200;
    --z-transient: 300;
    --z-overlay: 400;
    --z-toast: 500;
    --z-maintenance: 600;
    --z-skip-link: 700;
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    outline: none;
}

:where(a[href], button, input, select, textarea, summary, [tabindex]):focus-visible {
    outline: 3px solid rgba(13, 148, 136, 0.62) !important;
    outline-offset: 3px;
    box-shadow: 0 0 0 5px rgba(16, 185, 129, 0.14);
}

body {
    background-color: var(--bg-base);
    color: var(--text-main);
    font-family: var(--font-body);
    font-size: 0.95rem;
    line-height: 1.6;
    overflow-x: hidden;
    background-image: 
        radial-gradient(circle at 10% 20%, rgba(16, 185, 129, 0.05) 0%, transparent 50%),
        radial-gradient(circle at 90% 80%, rgba(2, 132, 199, 0.04) 0%, transparent 50%),
        radial-gradient(circle at 50% 50%, rgba(255, 255, 255, 0.9) 0%, transparent 100%);
    background-attachment: fixed;
}

.sr-only {
    position: absolute;
    width: 1px;
    height: 1px;
    padding: 0;
    margin: -1px;
    overflow: hidden;
    clip: rect(0, 0, 0, 0);
    white-space: nowrap;
    border: 0;
}

.skip-link {
    position: fixed;
    z-index: var(--z-skip-link);
    top: 0.65rem;
    left: 0.65rem;
    padding: 0.55rem 0.8rem;
    border-radius: 7px;
    background: var(--text-dark);
    color: #fff;
    font-size: 0.82rem;
    font-weight: 700;
    text-decoration: none;
    transform: translateY(-170%);
}

.skip-link:focus {
    transform: translateY(0);
    outline: 3px solid rgba(16, 185, 129, 0.45);
    outline-offset: 2px;
}

.app-main[aria-busy="true"] .app-content {
    cursor: progress;
}

.app-main[aria-busy="true"] .app-content::after {
    content: '';
    position: fixed;
    z-index: var(--z-transient);
    top: 1rem;
    right: 1rem;
    width: 0.75rem;
    height: 0.75rem;
    border: 2px solid rgba(13, 148, 136, 0.22);
    border-top-color: var(--primary);
    border-radius: 50%;
    animation: dashboardBusySpin 0.7s linear infinite;
}

@keyframes dashboardBusySpin {
    to { transform: rotate(360deg); }
}

.header-search {
    position: relative;
    flex: 1 1 340px;
    max-width: 560px;
    margin: 0 1rem;
}

.mobile-header-search-toggle,
.header-search-mobile-close {
    display: none;
}

.topbar-facility-context {
    max-width: 220px;
    overflow: hidden;
    border: 1px solid rgba(16, 185, 129, 0.28);
    border-radius: 6px;
    background: rgba(16, 185, 129, 0.08);
    color: var(--primary);
    font: inherit;
    font-size: 0.76rem;
    font-weight: 700;
    line-height: 1.2;
    text-align: left;
    text-overflow: ellipsis;
    white-space: nowrap;
    cursor: pointer;
}

.topbar-facility-context:not([hidden]) {
    display: inline-block;
    padding: 0.38rem 0.55rem;
}

.topbar-favourite-view {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 32px;
    height: 32px;
    border: 1px solid var(--border-color);
    border-radius: 7px;
    background: transparent;
    color: var(--text-muted);
    cursor: pointer;
}

.topbar-favourite-view:hover,
.topbar-favourite-view:focus-visible,
.topbar-favourite-view.is-active {
    border-color: rgba(245, 158, 11, 0.48);
    background: rgba(245, 158, 11, 0.1);
    color: #b45309;
    outline: none;
}

.header-search-control {
    display: flex;
    align-items: center;
    min-height: 42px;
    gap: 0.55rem;
    padding: 0 0.7rem;
    border: 1px solid var(--border-color);
    border-radius: 10px;
    background: var(--bg-surface);
    color: var(--text-muted);
}

.header-search-control:focus-within {
    border-color: var(--primary-neon);
    box-shadow: 0 0 0 3px rgba(16, 185, 129, 0.12);
}

.header-search-control input {
    width: 100%;
    min-width: 0;
    border: 0;
    outline: 0;
    background: transparent;
    color: var(--text-dark);
    font: inherit;
}

.header-search-control kbd {
    padding: 0.1rem 0.35rem;
    border: 1px solid var(--border-color);
    border-radius: 4px;
    color: var(--text-muted);
    font-size: 0.68rem;
}

.header-search-results {
    position: absolute;
    z-index: var(--z-popover);
    top: calc(100% + 0.45rem);
    right: 0;
    left: 0;
    max-height: min(420px, 60vh);
    overflow-y: auto;
    padding: 0.4rem;
    border: 1px solid var(--border-color);
    border-radius: 10px;
    background: var(--bg-surface);
    box-shadow: 0 18px 34px rgba(15, 23, 42, 0.16);
}

.header-search-status,
.header-search-empty {
    display: block;
    padding: 0.7rem 0.8rem;
    color: var(--text-muted);
    font-size: 0.82rem;
}

.header-search-option {
    display: grid;
    grid-template-columns: auto minmax(0, 1fr);
    gap: 0.6rem;
    width: 100%;
    padding: 0.65rem 0.7rem;
    border: 0;
    border-radius: 7px;
    background: transparent;
    color: var(--text-dark);
    text-align: left;
    cursor: pointer;
}

.header-search-option:hover,
.header-search-option.is-active {
    background: rgba(16, 185, 129, 0.1);
}

.header-search-option-type {
    min-width: 50px;
    color: var(--primary);
    font-size: 0.7rem;
    font-weight: 700;
    text-transform: uppercase;
}

.header-search-option-title,
.header-search-option-meta {
    display: block;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.header-search-option-meta {
    margin-top: 0.08rem;
    color: var(--text-muted);
    font-size: 0.75rem;
}

.header-search-all {
    display: block;
    width: 100%;
    margin-top: 0.25rem;
    padding: 0.6rem 0.7rem;
    border: 0;
    border-top: 1px solid var(--border-color);
    background: transparent;
    color: var(--primary);
    font: inherit;
    font-size: 0.82rem;
    font-weight: 700;
    text-align: left;
    cursor: pointer;
}

.workflow-return-action {
    position: fixed;
    right: 1rem;
    bottom: 1rem;
    z-index: var(--z-transient);
    max-width: calc(100vw - 2rem);
    box-shadow: 0 12px 28px rgba(15, 23, 42, 0.18);
}

@media (max-width: 640px) {
    .workflow-return-action {
        right: 0.75rem;
        bottom: 0.75rem;
        min-height: 44px;
    }
}

@media (max-width: 980px) {
    .header-search {
        order: 3;
        flex-basis: 100%;
        max-width: none;
        margin: 0.45rem 0 0;
    }

    .app-topbar {
        flex-wrap: wrap;
    }
}

@media (max-width: 640px) {
    .mobile-header-search-toggle {
        display: inline-flex;
        align-items: center;
        justify-content: center;
        min-width: 44px;
        min-height: 44px;
    }

    .header-search {
        display: none;
    }

    .header-search.is-mobile-open {
        position: fixed;
        z-index: var(--z-modal);
        inset: 0;
        display: block;
        max-width: none;
        margin: 0;
        padding: max(0.85rem, env(safe-area-inset-top)) 0.85rem 0.85rem;
        background: var(--bg-base);
        overflow-y: auto;
    }

    .header-search.is-mobile-open .header-search-control {
        min-height: 48px;
        padding: 0 0.75rem;
    }

    .header-search.is-mobile-open .header-search-results {
        position: static;
        max-height: calc(100vh - 5.75rem);
        margin-top: 0.65rem;
    }

    .header-search-mobile-close {
        display: inline-flex;
        min-height: 36px;
        align-items: center;
        padding: 0 0.35rem;
        border: 0;
        background: transparent;
        color: var(--primary);
        font: inherit;
        font-size: 0.8rem;
        font-weight: 700;
        cursor: pointer;
    }

    .header-search-control kbd {
        display: none;
    }

    .topbar-facility-context {
        max-width: 145px;
    }
}

@media (hover: none) {
    .btn-icon,
    .btn-secondary,
    .btn-neon,
    .sidebar-group-toggle,
    .sidebar-quick-link,
    .topbar-favourite-view,
    .header-search-option,
    .header-search-all {
        min-height: 44px;
    }

    .btn-icon,
    .topbar-favourite-view,
    .header-search-option,
    .header-search-all {
        min-width: 44px;
    }
}

@media (prefers-reduced-motion: reduce) {
    *,
    *::before,
    *::after {
        scroll-behavior: auto !important;
        transition-duration: 0.01ms !important;
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
    }
}

h1, h2, h3, h4, h5, h6 {
    font-family: var(--font-heading);
    font-weight: 700;
    letter-spacing: -0.02em;
    color: var(--text-dark);
    line-height: 1.2;
}

/* Scrollbar Customization */
::-webkit-scrollbar {
    width: 6px;
    height: 6px;
}
::-webkit-scrollbar-track {
    background: var(--bg-base);
}
::-webkit-scrollbar-thumb {
    background: var(--border-color);
    border-radius: 4px;
}
::-webkit-scrollbar-thumb:hover {
    background: var(--primary);
}

/* Glassmorphism Common Styles */
.glass-panel {
    background: var(--bg-surface);
    backdrop-filter: blur(16px);
    -webkit-backdrop-filter: blur(16px);
    border: 1px solid var(--border-color);
    border-radius: 16px;
}

.glass-card {
    background: var(--bg-card);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    border: 1px solid var(--border-color);
    border-radius: 16px;
    padding: 2rem;
    transition: var(--transition-smooth);
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
}
.glass-card:hover {
    background: var(--bg-card-hover);
    border-color: var(--border-hover);
    transform: translateY(-2px);
    box-shadow: var(--shadow-card-hover);
}
.feature-icon-box {
    width: 54px;
    height: 54px;
    border-radius: 14px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: linear-gradient(135deg, rgba(16, 185, 129, 0.12), rgba(13, 148, 136, 0.04));
    border: 1px solid rgba(16, 185, 129, 0.25);
    color: var(--primary);
    margin-bottom: 0.75rem;
    transition: var(--transition-smooth);
    box-shadow: 0 4px 10px rgba(16, 185, 129, 0.05);
}
.feature-icon-box svg {
    width: 24px;
    height: 24px;
    stroke-width: 2;
    stroke: currentColor;
    fill: none;
}
.glass-card:hover .feature-icon-box {
    background: linear-gradient(135deg, var(--primary-neon), var(--primary));
    color: #ffffff;
    border-color: transparent;
    box-shadow: 0 8px 20px rgba(16, 185, 129, 0.3);
    transform: scale(1.05);
}

/* Buttons */
.btn-neon {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    background: linear-gradient(135deg, var(--primary), #0f766e);
    color: #ffffff;
    font-family: var(--font-heading);
    font-weight: 600;
    padding: 0.75rem 1.75rem;
    border: none;
    border-radius: 8px;
    cursor: pointer;
    transition: var(--transition-smooth);
    box-shadow: 0 4px 15px rgba(13, 148, 136, 0.2);
    text-decoration: none;
}
.btn-neon:hover {
    transform: translateY(-1px);
    box-shadow: 0 6px 20px rgba(16, 185, 129, 0.35);
    background: linear-gradient(135deg, var(--primary-neon), var(--primary));
    color: #ffffff;
}

.btn-secondary {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    background: #ffffff;
    color: var(--text-main);
    border: 1px solid var(--border-color);
    padding: 0.75rem 1.75rem;
    border-radius: 8px;
    cursor: pointer;
    transition: var(--transition-smooth);
    text-decoration: none;
}
.btn-secondary:hover {
    background: rgba(16, 185, 129, 0.05);
    border-color: var(--border-hover);
    color: var(--primary);
}

.btn-icon {
    background: none;
    border: none;
    color: var(--text-muted);
    cursor: pointer;
    padding: 0.5rem;
    border-radius: 6px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    transition: var(--transition-smooth);
}
.btn-icon:hover {
    color: var(--primary-neon);
    background: rgba(16, 185, 129, 0.1);
}

.badge {
    display: inline-flex;
    align-items: center;
    gap: 0.35rem;
    padding: 0.28rem 0.65rem;
    border-radius: 9999px;
    font-size: 0.75rem;
    font-weight: 600;
    line-height: 1;
}
.badge-primary { background: #ccfbf1; color: #0f766e; border: 1px solid #99f6e4; }
.badge-secondary { background: #e0f2fe; color: #0369a1; border: 1px solid #bae6fd; }
.badge-danger { background: #fee2e2; color: #b91c1c; border: 1px solid #fca5a5; }
.badge-warning { background: #fef3c7; color: #b45309; border: 1px solid #fde68a; }
.badge-success { background: #dcfce7; color: #15803d; border: 1px solid #86efac; }
.badge-info { background: #e0f2fe; color: #0369a1; border: 1px solid #bae6fd; }

/* Form Control styling */
.form-group {
    margin-bottom: 1.5rem;
    display: flex;
    flex-direction: column;
    gap: 0.4rem;
}
.form-label {
    display: block;
    font-weight: 600;
    color: var(--text-muted);
    font-size: 0.85rem;
    font-family: var(--font-heading);
}
.input-icon-wrapper {
    position: relative;
    display: flex;
    align-items: center;
    width: 100%;
}
.input-icon-wrapper svg {
    position: absolute;
    left: 14px;
    width: 18px;
    height: 18px;
    color: rgba(13, 148, 136, 0.5);
    pointer-events: none;
    transition: var(--transition-smooth);
}
.form-input {
    width: 100%;
    background: rgba(255, 255, 255, 0.8);
    border: 1px solid var(--border-color);
    color: var(--text-dark);
    padding: 0.8rem 1rem;
    border-radius: 10px;
    font-family: inherit;
    font-size: 0.9rem;
    transition: var(--transition-smooth);
    box-shadow: inset 0 2px 4px rgba(0,0,0,0.01);
}
.input-icon-wrapper .form-input {
    padding-left: 2.75rem;
}
.form-input:hover {
    border-color: var(--border-hover);
    background: #ffffff;
}
.form-input:focus {
    border-color: var(--primary);
    background: #ffffff;
    box-shadow: 0 0 0 4px rgba(13, 148, 136, 0.12), 0 4px 12px rgba(13, 148, 136, 0.05);
}
.input-icon-wrapper:focus-within svg {
    color: var(--primary);
    transform: scale(1.05);
}
.password-toggle-btn {
    position: absolute;
    right: 14px;
    background: none;
    border: none;
    color: var(--text-muted);
    cursor: pointer;
    padding: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: var(--transition-smooth);
}
.password-toggle-btn:hover {
    color: var(--primary);
}
select, select.form-input {
    background-color: #ffffff;
    color: var(--text-dark);
    appearance: auto;
}
.form-input::placeholder {
    color: rgba(0, 0, 0, 0.35);
}

/* ---------------------------------------------------- */
/* LANDING PAGE STYLES */
/* ---------------------------------------------------- */
.lp-body {
    background-color: var(--bg-base);
}

.lp-navbar {
    position: fixed;
    top: 16px;
    left: 1.5rem;
    right: 1.5rem;
    max-width: 1200px;
    margin: 0 auto;
    height: 70px;
    border-radius: 16px;
    z-index: var(--z-sticky);
    background: rgba(255, 255, 255, 0.8);
    backdrop-filter: blur(16px);
    -webkit-backdrop-filter: blur(16px);
    border: 1px solid var(--border-color);
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.04);
    transition: var(--transition-smooth);
}
.lp-navbar .container {
    max-width: 1200px;
    margin: 0 auto;
    height: 100%;
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 0 1.5rem;
}
.lp-logo {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    text-decoration: none;
    font-family: var(--font-heading);
    font-size: 1.5rem;
    font-weight: 800;
    color: var(--text-dark);
}
.lp-logo img {
    width: 214px;
    height: 48px;
    display: block;
    max-width: 100%;
    object-fit: contain;
}
.lp-nav-links {
    display: flex;
    gap: 2rem;
    list-style: none;
}
.lp-nav-links a {
    color: var(--text-muted);
    text-decoration: none;
    font-weight: 500;
    transition: var(--transition-smooth);
}
.lp-nav-links a:hover {
    color: var(--primary-neon);
}

.lp-hero {
    padding: 160px 1.5rem 100px;
    max-width: 1200px;
    margin: 0 auto;
    display: grid;
    grid-template-columns: 1.2fr 1fr;
    gap: 4rem;
    align-items: center;
}
.lp-hero-text h1 {
    font-size: 3.5rem;
    line-height: 1.15;
    margin-bottom: 1.5rem;
    background: linear-gradient(135deg, var(--text-dark) 60%, var(--primary));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
}
.lp-hero-text p {
    font-size: 1.1rem;
    color: var(--text-muted);
    margin-bottom: 2.5rem;
}
.lp-hero-ctas {
    display: flex;
    gap: 1rem;
}
.lp-hero-visual {
    position: relative;
}
.mockup-display {
    width: 100%;
    aspect-ratio: 16/10;
    border-radius: 16px;
    border: 1px solid var(--border-color);
    box-shadow: 0 20px 40px -15px rgba(15, 23, 42, 0.08), 0 0 0 1px rgba(13, 148, 136, 0.05);
    background: #ffffff;
    padding: 12px;
    position: relative;
    overflow: hidden;
}
.mockup-display::after {
    content: '';
    position: absolute;
    top: 0; left: 0; right: 0; bottom: 0;
    background: linear-gradient(135deg, transparent 60%, rgba(13, 148, 136, 0.03));
    pointer-events: none;
}
.mockup-bar {
    height: 16px;
    display: flex;
    gap: 6px;
    margin-bottom: 8px;
}
.mockup-dot {
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.2);
}
.mockup-screen {
    height: calc(100% - 24px);
    background: #0d1210;
    border-radius: 6px;
    overflow: hidden;
    position: relative;
    display: flex;
    flex-direction: column;
}

.lp-features {
    padding: 80px 1.5rem;
    max-width: 1200px;
    margin: 0 auto;
}
.lp-section-header {
    text-align: center;
    margin-bottom: 4rem;
}
.lp-section-header h2 {
    font-size: 2.5rem;
    margin-bottom: 1rem;
}
.lp-section-header p {
    color: var(--text-muted);
    max-width: 600px;
    margin: 0 auto;
}
.features-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 2rem;
}

.lp-pricing {
    padding: 80px 1.5rem;
    max-width: 1200px;
    margin: 0 auto;
}
.pricing-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
    gap: 2rem;
}
.pricing-card {
    display: flex;
    flex-direction: column;
    height: 100%;
}
.pricing-card.featured {
    border-color: var(--primary);
    position: relative;
    transform: scale(1.03);
}
.pricing-card.featured::before {
    content: 'EN POPÜLER';
    position: absolute;
    top: -12px;
    right: 24px;
    background: var(--primary);
    color: var(--bg-base);
    font-size: 0.75rem;
    font-weight: 800;
    padding: 0.25rem 0.75rem;
    border-radius: 9999px;
    letter-spacing: 0.05em;
}
.price-tag {
    font-size: 2.5rem;
    font-weight: 800;
    margin: 1.5rem 0;
    color: #ffffff;
}
.price-tag span {
    font-size: 1rem;
    color: var(--text-muted);
    font-weight: 400;
}
.pricing-features {
    list-style: none;
    margin: 2rem 0;
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
    flex-grow: 1;
}
.pricing-features li {
    display: flex;
    align-items: center;
    gap: 0.75rem;
}
.pricing-features li svg {
    width: 18px;
    height: 18px;
    fill: var(--primary);
}

.lp-contact {
    padding: 80px 1.5rem;
    max-width: 600px;
    margin: 0 auto;
}

.lp-footer {
    border-top: 1px solid var(--border-color);
    padding: 3rem 1.5rem;
    text-align: center;
    color: var(--text-muted);
    background: rgba(0,0,0,0.3);
}

/* ---------------------------------------------------- */
/* LOGIN PAGE STYLES */
/* ---------------------------------------------------- */
.login-wrapper {
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 1.5rem;
}
.login-box {
    width: 100%;
    max-width: 440px;
}
.login-header {
    text-align: center;
    margin-bottom: 2.5rem;
}
.login-logo {
    display: inline-flex;
    align-items: center;
    gap: 0.75rem;
    text-decoration: none;
    font-family: var(--font-heading);
    font-size: 2rem;
    font-weight: 800;
    color: var(--text-dark);
    margin-bottom: 1rem;
}
.login-logo img {
    width: 290px;
    height: 66px;
    display: block;
    max-width: 100%;
    object-fit: contain;
}
.login-header p {
    color: var(--text-muted);
}
.demo-fillers {
    margin-top: 1.5rem;
    border-top: 1px solid var(--border-color);
    padding-top: 1.5rem;
}
.demo-fillers p {
    font-size: 0.8rem;
    color: var(--text-muted);
    margin-bottom: 0.75rem;
    text-align: center;
}
.demo-btn-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 0.5rem;
}
.btn-demo-fill {
    background: rgba(255, 255, 255, 0.03);
    border: 1px solid var(--border-color);
    color: var(--text-muted);
    font-size: 0.75rem;
    padding: 0.5rem;
    border-radius: 6px;
    cursor: pointer;
    font-family: var(--font-heading);
    font-weight: 600;
    transition: var(--transition-smooth);
}
.btn-demo-fill:hover {
    background: rgba(16, 185, 129, 0.1);
    color: var(--primary-neon);
    border-color: var(--primary);
}

/* ---------------------------------------------------- */
/* APP DASHBOARD STRUCTURE */
/* ---------------------------------------------------- */
.app-wrapper {
    display: flex;
    min-height: 100vh;
    background-color: var(--bg-base);
}

/* Sidebar Layout */
.app-sidebar {
    width: var(--sidebar-width);
    height: 100vh;
    position: fixed;
    left: 0;
    top: 0;
    z-index: var(--z-sticky);
    display: flex;
    flex-direction: column;
    border-right: 1px solid var(--border-color);
    background: rgba(255, 255, 255, 0.95);
    backdrop-filter: blur(20px);
    transition: var(--transition-smooth);
}
.app-sidebar.collapsed {
    width: var(--sidebar-collapsed-width);
}
.sidebar-header {
    height: var(--topbar-height);
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 0 1.5rem;
    border-bottom: 1px solid var(--border-color);
}
.app-sidebar.collapsed .sidebar-header {
    padding: 0;
    justify-content: center;
}
.sidebar-logo {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    text-decoration: none;
    font-family: var(--font-heading);
    font-size: 1.25rem;
    font-weight: 800;
    color: var(--text-dark);
}
.app-sidebar.collapsed .sidebar-logo span {
    display: none;
}
.sidebar-logo img {
    width: 28px;
    height: 28px;
    object-fit: contain;
}
.sidebar-nav {
    list-style: none;
    padding: 1.5rem 0.75rem;
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
    flex-grow: 1;
    overflow-y: auto;
}
.sidebar-link {
    display: flex;
    align-items: center;
    gap: 1rem;
    color: var(--text-muted);
    text-decoration: none;
    padding: 0.75rem 1rem;
    border-radius: 8px;
    transition: var(--transition-smooth);
    font-weight: 500;
}
.sidebar-link svg {
    width: 20px;
    height: 20px;
    fill: currentColor;
    flex-shrink: 0;
}
.nav-icon {
    --icon-color: #10b981;
    --icon-bg: rgba(16, 185, 129, 0.12);
    --icon-border: rgba(16, 185, 129, 0.34);
    width: 24px;
    min-width: 24px;
    height: 24px;
    border-radius: 7px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border: 1px solid var(--icon-border);
    background: var(--icon-bg);
    color: var(--icon-color);
    line-height: 1;
}
.nav-icon[data-icon="DB"],
.nav-icon[data-icon="OZ"],
.nav-icon[data-icon="RP"] { --icon-color: #38bdf8; --icon-bg: rgba(56, 189, 248, 0.12); --icon-border: rgba(56, 189, 248, 0.35); }
.nav-icon[data-icon="FR"],
.nav-icon[data-icon="TS"],
.nav-icon[data-icon="MH"],
.nav-icon[data-icon="KU"] { --icon-color: #10b981; --icon-bg: rgba(16, 185, 129, 0.12); --icon-border: rgba(16, 185, 129, 0.35); }
.nav-icon[data-icon="AR"],
.nav-icon[data-icon="EV"],
.nav-icon[data-icon="ED"] { --icon-color: #60a5fa; --icon-bg: rgba(96, 165, 250, 0.12); --icon-border: rgba(96, 165, 250, 0.35); }
.nav-icon[data-icon="KR"],
.nav-icon[data-icon="BS"],
.nav-icon[data-icon="BG"],
.nav-icon[data-icon="IZ"],
.nav-icon[data-icon="KT"] { --icon-color: #06b6d4; --icon-bg: rgba(6, 182, 212, 0.13); --icon-border: rgba(6, 182, 212, 0.36); }
.nav-icon[data-icon="YK"],
.nav-icon[data-icon="CD"],
.nav-icon[data-icon="DN"],
.nav-icon[data-icon="RA"],
.nav-icon[data-icon="MV"] { --icon-color: #f59e0b; --icon-bg: rgba(245, 158, 11, 0.13); --icon-border: rgba(245, 158, 11, 0.36); }
.nav-icon[data-icon="MS"],
.nav-icon[data-icon="EP"],
.nav-icon[data-icon="TK"] { --icon-color: #f472b6; --icon-bg: rgba(244, 114, 182, 0.13); --icon-border: rgba(244, 114, 182, 0.36); }
.nav-icon[data-icon="AI"],
.nav-icon[data-icon="MK"],
.nav-icon[data-icon="AY"] { --icon-color: #22d3ee; --icon-bg: rgba(34, 211, 238, 0.12); --icon-border: rgba(34, 211, 238, 0.35); }
.nav-icon svg {
    width: 15px;
    height: 15px;
    stroke: currentColor;
    fill: none;
    stroke-width: 2;
    stroke-linecap: round;
    stroke-linejoin: round;
}
.sidebar-link:hover, .sidebar-link.active {
    color: var(--primary-neon);
    background: rgba(16, 185, 129, 0.08);
}
.sidebar-quick-access {
    padding: 0.2rem 0.25rem 0.6rem;
    border-bottom: 1px solid var(--border-color);
}
.sidebar-quick-heading {
    padding: 0.35rem 0.6rem;
    color: var(--text-muted);
    font-size: 0.68rem;
    font-weight: 800;
    letter-spacing: 0.04em;
    text-transform: uppercase;
}
.sidebar-quick-list {
    display: grid;
    gap: 0.2rem;
}
.sidebar-quick-link {
    display: grid;
    grid-template-columns: 1.1rem minmax(0, 1fr);
    align-items: center;
    gap: 0.5rem;
    width: 100%;
    min-height: 36px;
    padding: 0.45rem 0.6rem;
    border: 0;
    border-radius: 7px;
    background: transparent;
    color: var(--text-muted);
    font: inherit;
    font-size: 0.78rem;
    text-align: left;
    cursor: pointer;
}
.sidebar-quick-link:hover,
.sidebar-quick-link:focus-visible {
    background: rgba(16, 185, 129, 0.08);
    color: var(--primary-neon);
    outline: none;
}
.sidebar-quick-link span:last-child {
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}
.sidebar-quick-icon {
    color: var(--primary-neon);
    font-size: 0.88rem;
}
.work-center-card {
    min-width: 0;
    padding: 1.1rem;
}
.work-center-card-heading {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 1rem;
    margin-bottom: 0.7rem;
}
.work-center-card-heading h4 {
    margin: 0.12rem 0 0;
}
.work-center-eyebrow {
    color: var(--primary);
    font-size: 0.68rem;
    font-weight: 800;
    letter-spacing: 0.05em;
}
.work-center-item {
    display: grid;
    grid-template-columns: auto minmax(0, 1fr) auto;
    align-items: center;
    gap: 0.65rem;
    width: 100%;
    min-height: 58px;
    padding: 0.7rem 0;
    border: 0;
    border-top: 1px solid var(--border-color);
    background: transparent;
    color: var(--text-main);
    font: inherit;
    text-align: left;
    cursor: pointer;
}
.work-center-item:hover b,
.work-center-item:focus-visible b {
    color: var(--primary);
}
.work-center-item:focus-visible {
    outline: 2px solid rgba(16, 185, 129, 0.45);
    outline-offset: 2px;
}
.work-center-item b,
.work-center-item small {
    display: block;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}
.work-center-item small {
    margin-top: 0.12rem;
    color: var(--text-muted);
    font-size: 0.75rem;
}
.work-center-item-status {
    min-width: 4.3rem;
    padding: 0.2rem 0.38rem;
    border-radius: 999px;
    background: rgba(245, 158, 11, 0.12);
    color: #a16207;
    font-size: 0.68rem;
    font-weight: 800;
    text-align: center;
}
.work-center-item-status.is-overdue {
    background: rgba(220, 38, 38, 0.1);
    color: var(--danger);
}
.work-center-item-status.is-workflow {
    background: rgba(16, 185, 129, 0.1);
    color: var(--primary);
}
.work-center-empty {
    margin: 1rem 0 0;
    color: var(--text-muted);
    font-size: 0.84rem;
}
.app-sidebar.collapsed .sidebar-quick-heading,
.app-sidebar.collapsed .sidebar-quick-link span:last-child {
    display: none;
}
.app-sidebar.collapsed .sidebar-quick-access {
    padding-inline: 0;
}
.app-sidebar.collapsed .sidebar-quick-link {
    grid-template-columns: 1fr;
    justify-items: center;
}
.sidebar-nav-group {
    display: flex;
    flex-direction: column;
    gap: 0.25rem;
}
.sidebar-group-toggle {
    width: 100%;
    border: 0;
    background: transparent;
    color: var(--text-muted);
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 0.5rem;
    padding: 0.45rem 0.85rem;
    border-radius: 8px;
    cursor: pointer;
    font-size: 0.72rem;
    font-weight: 800;
    letter-spacing: 0;
    text-transform: uppercase;
}
.sidebar-group-toggle:hover,
.sidebar-group-toggle:focus-visible {
    color: var(--text-dark);
    background: rgba(15, 23, 42, 0.04);
    outline: none;
}
.sidebar-group-chevron {
    transition: transform 0.2s ease;
}
.sidebar-nav-group.is-open .sidebar-group-chevron {
    transform: rotate(180deg);
}
.sidebar-group-items {
    list-style: none;
    display: flex;
    flex-direction: column;
    gap: 0.25rem;
    margin: 0;
    padding: 0;
}
.app-sidebar.collapsed .sidebar-link span:not(.nav-icon) {
    display: none;
}
.app-sidebar.collapsed .sidebar-group-toggle {
    display: none;
}
.app-sidebar.collapsed .sidebar-link {
    justify-content: center;
    padding: 0.75rem;
}
.sidebar-footer {
    padding: 1rem;
    border-top: 1px solid var(--border-color);
}
.table-search-input {
    width: 100%;
    min-width: 220px;
}

.table-search-clear {
    margin-left: 0.5rem;
    border: 1px solid var(--border-color);
    border-radius: 8px;
    background: rgba(255, 255, 255, 0.86);
    color: var(--text-muted);
    cursor: pointer;
    font-size: 0.78rem;
    font-weight: 700;
    padding: 0.48rem 0.7rem;
}

.table-search-clear:hover,
.table-search-clear:focus-visible {
    border-color: rgba(13, 148, 136, 0.35);
    color: var(--primary);
}

.table-filter-summary {
    display: block;
    width: 100%;
    margin-top: 0.35rem;
    color: var(--text-muted);
    font-size: 0.76rem;
    line-height: 1.35;
}

.modal-open {
    overflow: hidden;
}

.report-tabs {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
    margin: -0.5rem 0 1.5rem;
}

.report-tab-btn {
    border: 1px solid var(--border-color);
    border-radius: 8px;
    background: rgba(255, 255, 255, 0.82);
    color: var(--text-muted);
    cursor: pointer;
    font-size: 0.82rem;
    font-weight: 700;
    padding: 0.55rem 0.85rem;
    transition: var(--transition-smooth);
}

.report-tab-btn.active,
.report-tab-btn:hover,
.report-tab-btn:focus-visible {
    background: rgba(13, 148, 136, 0.1);
    border-color: rgba(13, 148, 136, 0.35);
    color: var(--primary);
}

.report-tab-panel[hidden] {
    display: none !important;
}

.row-actions-menu {
    position: relative;
    display: inline-block;
}

.row-actions-menu summary {
    list-style: none;
    cursor: pointer;
    border: 1px solid var(--border-color);
    border-radius: 8px;
    padding: 0.3rem 0.6rem;
    color: var(--text-muted);
    background: rgba(255, 255, 255, 0.8);
    font-size: 0.75rem;
    font-weight: 700;
}

.row-actions-menu summary::-webkit-details-marker {
    display: none;
}

.row-actions-menu[open] summary {
    color: var(--primary-neon);
    border-color: rgba(16, 185, 129, 0.35);
}

.row-actions-list {
    position: absolute;
    right: 0;
    top: calc(100% + 0.35rem);
    z-index: 50;
    min-width: 180px;
    display: flex;
    flex-direction: column;
    gap: 0.35rem;
    padding: 0.5rem;
    border: 1px solid var(--border-color);
    border-radius: 8px;
    background: #ffffff;
    box-shadow: 0 18px 45px rgba(15, 23, 42, 0.16);
}

.row-action-danger {
    color: var(--danger) !important;
    border-color: rgba(220, 38, 38, 0.25) !important;
    background: rgba(220, 38, 38, 0.05) !important;
}
.user-profile-badge {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    overflow: hidden;
}
.app-sidebar.collapsed .user-profile-badge {
    justify-content: center;
}
.user-avatar {
    width: 36px;
    height: 36px;
    border-radius: 50%;
    background: linear-gradient(135deg, var(--primary), var(--secondary));
    color: var(--bg-base);
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 700;
    font-size: 0.95rem;
}
.user-profile-info {
    display: flex;
    flex-direction: column;
}
.app-sidebar.collapsed .user-profile-info {
    display: none;
}
.user-name {
    font-weight: 600;
    color: var(--text-dark);
    font-size: 0.85rem;
    white-space: nowrap;
    text-overflow: ellipsis;
    overflow: hidden;
}
.user-role {
    font-size: 0.75rem;
    color: var(--text-muted);
}

/* Content Area */
.app-main {
    flex-grow: 1;
    margin-left: var(--sidebar-width);
    transition: var(--transition-smooth);
    min-height: 100vh;
    display: flex;
    flex-direction: column;
    min-width: 0;
}
.app-sidebar.collapsed + .app-main {
    margin-left: var(--sidebar-collapsed-width);
}

/* Top bar Layout */
.app-topbar {
    height: var(--topbar-height);
    border-bottom: 1px solid var(--border-color);
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 0 2rem;
    background: rgba(255, 255, 255, 0.85);
    backdrop-filter: blur(12px);
    position: sticky;
    top: 0;
    z-index: var(--z-sticky);
}
.topbar-left {
    display: flex;
    align-items: center;
    gap: 1.5rem;
}
.topbar-title {
    font-size: 1.25rem;
    font-weight: 600;
}
.topbar-right {
    display: flex;
    align-items: center;
    gap: 1rem;
}
.system-status-indicator {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    font-size: 0.8rem;
    background: rgba(16, 185, 129, 0.08);
    border: 1px solid rgba(16, 185, 129, 0.2);
    padding: 0.35rem 0.75rem;
    border-radius: 6px;
    color: var(--primary-neon);
}
.api-health-indicator {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    max-width: 240px;
    padding: 0.35rem 0.75rem;
    border: 1px solid rgba(245, 158, 11, 0.35);
    border-radius: 6px;
    background: rgba(245, 158, 11, 0.1);
    color: var(--warning);
    font-size: 0.8rem;
    font-weight: 600;
}
.api-health-indicator.is-error {
    border-color: rgba(220, 38, 38, 0.35);
    background: rgba(220, 38, 38, 0.1);
    color: var(--danger);
}
.api-health-indicator .status-dot {
    flex: 0 0 auto;
    background: currentColor;
    box-shadow: 0 0 8px currentColor;
}
.status-dot {
    width: 6px;
    height: 6px;
    border-radius: 50%;
    background: var(--primary-neon);
    box-shadow: 0 0 8px var(--primary-neon);
}
.status-dot.sim {
    background: var(--warning);
    box-shadow: 0 0 8px var(--warning);
}

/* Main Body View */
.app-content {
    flex-grow: 1;
    padding: 2rem;
    min-width: 0;
}
.view-section {
    display: none;
}
.view-section.active {
    display: block;
    animation: fadeIn 0.4s ease;
}

.module-grid {
    display: grid;
    grid-template-columns: minmax(260px, 360px) minmax(0, 1fr);
    gap: 1.25rem;
    align-items: start;
}

.module-form-panel {
    padding: 1.25rem;
}

.module-form-panel h3 {
    font-size: 1rem;
    margin-bottom: 1rem;
}

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

/* Metrics and Grid styling */
.metrics-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
    gap: 1.5rem;
    margin-bottom: 2rem;
}
.metric-card {
    display: flex;
    align-items: center;
    justify-content: space-between;
}
.metric-details h4 {
    font-size: 0.8rem;
    color: var(--text-muted);
    font-weight: 500;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    margin-bottom: 0.25rem;
}
.metric-value {
    font-size: 1.75rem;
    font-weight: 800;
    color: var(--text-dark);
    line-height: 1.2;
}
.metric-icon {
    width: 48px;
    height: 48px;
    border-radius: 12px;
    background: rgba(255, 255, 255, 0.03);
    border: 1px solid var(--border-color);
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--primary-neon);
}
.metric-glyph,
.ui-glyph {
    --icon-color: #10b981;
    --icon-bg: rgba(16, 185, 129, 0.12);
    --icon-border: rgba(16, 185, 129, 0.34);
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border: 1px solid var(--icon-border);
    background: var(--icon-bg);
    color: var(--icon-color);
    line-height: 1;
}
.ui-glyph[data-icon="AR"],
.ui-glyph[data-icon="EV"],
.ui-glyph[data-icon="ED"] { --icon-color: #60a5fa; --icon-bg: rgba(96, 165, 250, 0.12); --icon-border: rgba(96, 165, 250, 0.35); }
.ui-glyph[data-icon="PDF"],
.ui-glyph[data-icon="XL"],
.ui-glyph[data-icon="BG"],
.ui-glyph[data-icon="BS"],
.ui-glyph[data-icon="IZ"] { --icon-color: #06b6d4; --icon-bg: rgba(6, 182, 212, 0.13); --icon-border: rgba(6, 182, 212, 0.36); }
.ui-glyph[data-icon="RA"],
.ui-glyph[data-icon="RS"],
.ui-glyph[data-icon="MV"],
.ui-glyph[data-icon="CD"] { --icon-color: #f59e0b; --icon-bg: rgba(245, 158, 11, 0.13); --icon-border: rgba(245, 158, 11, 0.36); }
.ui-glyph[data-icon="AI"],
.ui-glyph[data-icon="UP"] { --icon-color: #22d3ee; --icon-bg: rgba(34, 211, 238, 0.12); --icon-border: rgba(34, 211, 238, 0.35); }
.ui-glyph[data-icon="AT"] { --icon-color: #34d399; --icon-bg: rgba(52, 211, 153, 0.13); --icon-border: rgba(52, 211, 153, 0.36); }
.metric-glyph svg,
.ui-glyph svg {
    stroke: currentColor;
    fill: none;
    stroke-width: 2;
    stroke-linecap: round;
    stroke-linejoin: round;
}
.metric-glyph {
    width: 30px;
    height: 30px;
    border-radius: 9px;
}
.metric-glyph svg {
    width: 18px;
    height: 18px;
}
.ui-glyph {
    width: 22px;
    height: 22px;
    border-radius: 7px;
    margin-right: 0.35rem;
    vertical-align: middle;
}
.ui-glyph svg {
    width: 14px;
    height: 14px;
}
.btn-icon .ui-glyph,
.map-control-btn .ui-glyph {
    margin-right: 0;
}

/* Color emoji icon mode: keeps the original lively dashboard feel without raw emoji bytes. */
.nav-icon {
    border: 0;
    background: transparent;
    color: inherit;
    font-size: 1.12rem;
    width: 24px;
    min-width: 24px;
    height: 24px;
    font-family: "Segoe UI Emoji", "Apple Color Emoji", "Noto Color Emoji", sans-serif;
}
.metric-glyph,
.ui-glyph {
    border: 0;
    background: transparent;
    color: inherit;
    font-family: "Segoe UI Emoji", "Apple Color Emoji", "Noto Color Emoji", sans-serif;
}
.metric-glyph {
    width: auto;
    height: auto;
    font-size: 1.6rem;
}
.ui-glyph {
    width: auto;
    height: auto;
    font-size: 1rem;
    margin-right: 0.35rem;
}
.btn-icon .ui-glyph,
.map-control-btn .ui-glyph {
    margin-right: 0;
}
.metric-card:hover .metric-icon {
    border-color: var(--primary);
    background: rgba(16, 185, 129, 0.05);
}

/* Content grid split panels */
.dashboard-grid {
    display: grid;
    grid-template-columns: 1.5fr 1fr;
    gap: 1.5rem;
    margin-bottom: 2rem;
}

/* Data Table Styles */
.table-responsive {
    width: 100%;
    overflow-x: auto;
    border-radius: 8px;
    border: 1px solid var(--border-color);
}
.custom-table {
    width: 100%;
    border-collapse: collapse;
    text-align: left;
    font-size: 0.9rem;
}
.custom-table th {
    background: rgba(255, 255, 255, 0.05);
    border-bottom: 1px solid var(--border-color);
    padding: 1rem;
    font-weight: 600;
    color: var(--text-dark);
    font-family: var(--font-heading);
}
.custom-table td {
    padding: 1rem;
    border-bottom: 1px solid rgba(255, 255, 255, 0.03);
    color: var(--text-main);
    vertical-align: middle;
}
.custom-table tr:last-child td {
    border-bottom: none;
}
.custom-table tr:hover td {
    background: rgba(255, 255, 255, 0.01);
}

/* Flex/Layout utilities for dashboard pages */
.panel-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 1.5rem;
    flex-wrap: wrap;
    gap: 1rem;
}
.panel-actions {
    display: flex;
    gap: 0.75rem;
}

/* Split screen styling (eg for Map/GIS and Checklists) */
.split-view-container {
    display: grid;
    grid-template-columns: 1.2fr 1fr;
    gap: 1.5rem;
    min-height: 500px;
}
.split-left, .split-right {
    height: 100%;
    display: flex;
    flex-direction: column;
}
.split-left {
    position: relative;
}

/* Live Map Simulator Styles */
.map-canvas-sim {
    flex-grow: 1;
    background: #090e14;
    border-radius: 12px;
    border: 1px solid var(--border-color);
    position: relative;
    overflow: hidden;
    display: flex;
    align-items: center;
    justify-content: center;
    background-image: 
        radial-gradient(#1e293b 1px, transparent 1px),
        linear-gradient(rgba(16, 185, 129, 0.05) 1px, transparent 1px),
        linear-gradient(90deg, rgba(16, 185, 129, 0.05) 1px, transparent 1px);
    background-size: 20px 20px, 40px 40px, 40px 40px;
}
.map-overlay-tools {
    position: absolute;
    top: 1rem;
    left: 1rem;
    z-index: 10;
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
}
.map-overlay-badge {
    position: absolute;
    bottom: 1rem;
    right: 1rem;
    background: rgba(15, 23, 42, 0.85);
    backdrop-filter: blur(8px);
    padding: 0.5rem 1rem;
    border-radius: 6px;
    border: 1px solid var(--border-color);
    font-size: 0.8rem;
    color: var(--text-muted);
}
.map-control-btn {
    background: rgba(15, 23, 42, 0.85);
    border: 1px solid var(--border-color);
    color: #ffffff;
    width: 36px;
    height: 36px;
    border-radius: 6px;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    font-size: 1.1rem;
    transition: var(--transition-smooth);
}
.map-control-btn:hover {
    background: var(--primary);
    border-color: var(--primary);
    color: var(--bg-base);
}

.map-facility-node {
    position: absolute;
    width: 14px;
    height: 14px;
    border-radius: 50%;
    background: var(--primary-neon);
    box-shadow: 0 0 15px var(--primary-neon);
    cursor: pointer;
}
.map-facility-buffer {
    position: absolute;
    border-radius: 50%;
    border: 1px dashed var(--secondary);
    background: rgba(14, 165, 233, 0.1);
    pointer-events: none;
    transform: translate(-50%, -50%);
}
.map-polygon-marker {
    position: absolute;
    width: 8px;
    height: 8px;
    background: #ffffff;
    border: 2px solid var(--primary);
    border-radius: 50%;
    cursor: move;
}

/* Drag & Drop Transfer Lists */
.drag-container {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
    gap: 1.5rem;
}
.drag-column {
    background: rgba(10, 15, 12, 0.5);
    border: 1px solid var(--border-color);
    border-radius: 12px;
    padding: 1rem;
    min-height: 300px;
}
.drag-column-title {
    font-size: 0.95rem;
    font-weight: 600;
    margin-bottom: 1rem;
    padding-bottom: 0.5rem;
    border-bottom: 1px solid var(--border-color);
    display: flex;
    align-items: center;
    justify-content: space-between;
}
.drag-list {
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
    min-height: 250px;
}
.drag-item {
    background: var(--bg-card);
    border: 1px solid var(--border-color);
    border-radius: 8px;
    padding: 0.75rem;
    cursor: grab;
    user-select: none;
    transition: var(--transition-smooth);
    display: flex;
    align-items: center;
    justify-content: space-between;
}
.drag-item:active {
    cursor: grabbing;
    opacity: 0.5;
}
.drag-item:hover {
    border-color: var(--primary);
    background: var(--bg-card-hover);
}

/* Modals */
.modal-overlay {
    position: fixed;
    top: 0; left: 0; right: 0; bottom: 0;
    background: rgba(0, 0, 0, 0.8);
    backdrop-filter: blur(4px);
    z-index: var(--z-overlay);
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 1rem;
    overflow-y: auto;
    opacity: 0;
    pointer-events: none;
    transition: var(--transition-smooth);
}
.modal-overlay.active {
    opacity: 1;
    pointer-events: auto;
}
.modal-content {
    width: 100%;
    max-width: 500px;
    max-height: calc(100vh - 2rem);
    overflow-y: auto;
    transform: scale(0.95);
    transition: var(--transition-smooth);
}
.modal-overlay.active .modal-content {
    transform: scale(1);
}

#addWasteModal .modal-content {
    background: #ffffff;
    border: 1px solid rgba(13, 148, 136, 0.22);
    box-shadow: 0 24px 70px rgba(15, 23, 42, 0.28);
    opacity: 1;
}

#addWasteModal.active {
    display: flex !important;
    opacity: 1 !important;
    pointer-events: auto !important;
    background: rgba(15, 23, 42, 0.72) !important;
}

#addWasteModal .waste-modal-content {
    width: 95%;
    max-width: 800px;
    max-height: 90vh;
    overflow-y: auto;
    padding: 2.5rem;
    color: var(--text-dark);
    background-color: #ffffff !important;
    background-image: none !important;
    backdrop-filter: none !important;
    -webkit-backdrop-filter: none !important;
    transform: scale(0.95);
}

#addWasteModal.active .waste-modal-content {
    transform: scale(1);
}

#addWasteModal .form-label,
#addWasteModal h3 {
    color: var(--text-dark);
}

#addWasteModal .form-input {
    background: #ffffff;
    color: var(--text-dark);
    border-color: rgba(13, 148, 136, 0.28);
}

.modal-content::-webkit-scrollbar {
    width: 8px;
}

.modal-content::-webkit-scrollbar-thumb {
    background: rgba(15, 118, 110, 0.28);
    border-radius: 999px;
}
.modal-discard-confirmation {
    position: sticky;
    bottom: 0;
    z-index: 2;
    margin: 1rem 0 0;
    padding: 1rem;
    border: 1px solid rgba(245, 158, 11, 0.55);
    border-radius: var(--radius-md, 12px);
    background: color-mix(in srgb, var(--bg-card, #172033) 94%, #f59e0b 6%);
    box-shadow: 0 12px 30px rgba(15, 23, 42, 0.22);
}
.modal-discard-confirmation p {
    margin: 0.45rem 0 0;
    color: var(--text-muted);
}
.modal-discard-actions {
    display: flex;
    flex-wrap: wrap;
    justify-content: flex-end;
    gap: 0.6rem;
    margin-top: 0.9rem;
}
@media (max-width: 390px) {
    .modal-discard-actions > button {
        width: 100%;
    }
}
.modal-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 1.5rem;
}
.modal-body {
    margin-bottom: 1.5rem;
}
.modal-footer {
    display: flex;
    justify-content: flex-end;
    gap: 0.75rem;
}

/* Rich Text / Markdown Report Editor Mock */
.report-editor {
    display: flex;
    flex-direction: column;
    border: 1px solid var(--border-color);
    border-radius: 12px;
    background: rgba(255, 255, 255, 0.7);
    overflow: hidden;
    height: calc(100vh - 280px);
}
.editor-toolbar {
    background: rgba(255, 255, 255, 0.95);
    padding: 0.5rem;
    border-bottom: 1px solid var(--border-color);
    display: flex;
    gap: 0.25rem;
    flex-wrap: wrap;
}
.editor-btn {
    background: none;
    border: none;
    color: var(--text-muted);
    padding: 0.35rem 0.6rem;
    border-radius: 4px;
    cursor: pointer;
    font-size: 0.85rem;
    font-weight: 600;
    transition: var(--transition-smooth);
}
.editor-btn:hover {
    color: #ffffff;
    background: rgba(255,255,255,0.05);
}
.editor-btn.active {
    color: var(--primary-neon);
    background: rgba(16, 185, 129, 0.1);
}
.editor-textarea {
    flex-grow: 1;
    background: transparent;
    border: none;
    color: var(--text-main);
    padding: 1.5rem;
    resize: none;
    font-family: var(--font-body);
    font-size: 0.95rem;
    line-height: 1.6;
}

/* ---------------------------------------------------- */
/* NEW DASHBOARD WIDGETS & VISUAL STYLING */
/* ---------------------------------------------------- */

.dashboard-welcome {
    background: linear-gradient(135deg, rgba(16, 185, 129, 0.15) 0%, rgba(14, 165, 233, 0.05) 100%);
    border: 1px solid var(--border-color);
    padding: 1.5rem 2rem;
    border-radius: 16px;
    margin-bottom: 2rem;
    display: flex;
    justify-content: space-between;
    align-items: center;
}
.dashboard-welcome-text h2 {
    font-size: 1.75rem;
    margin-bottom: 0.25rem;
    background: linear-gradient(135deg, var(--text-dark), var(--primary));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
}
.dashboard-welcome-text p {
    color: var(--text-muted);
    font-size: 0.9rem;
}

/* Todo interactive checklist styling */
.todo-card {
    padding: 1.5rem;
}
.todo-input-group {
    display: flex;
    gap: 0.5rem;
    margin-bottom: 1.25rem;
}
.todo-list {
    list-style: none;
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
    max-height: 320px;
    overflow-y: auto;
    padding-right: 0.25rem;
}
.todo-item {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 0.75rem 1rem;
    background: rgba(255, 255, 255, 0.85);
    border: 1px solid var(--border-color);
    border-radius: 8px;
    transition: var(--transition-smooth);
}
.todo-item:hover {
    background: rgba(16, 185, 129, 0.04);
    border-color: var(--border-hover);
}
.todo-left {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    flex-grow: 1;
}
.todo-checkbox {
    width: 18px;
    height: 18px;
    accent-color: var(--primary-neon);
    cursor: pointer;
}
.todo-text {
    font-size: 0.88rem;
    color: var(--text-main);
    transition: var(--transition-smooth);
    cursor: pointer;
}
.todo-item.completed .todo-text {
    text-decoration: line-through;
    color: var(--text-muted);
    opacity: 0.6;
}
.todo-item.completed {
    border-color: rgba(255, 255, 255, 0.03);
    background: rgba(0, 0, 0, 0.1);
}

/* Timeline/Alert flow styling */
.timeline-feed {
    display: flex;
    flex-direction: column;
    gap: 1rem;
}
.timeline-item {
    display: flex;
    gap: 1rem;
    padding-bottom: 1rem;
    border-bottom: 1px solid rgba(255, 255, 255, 0.03);
}
.timeline-item:last-child {
    border-bottom: none;
    padding-bottom: 0;
}
.timeline-badge {
    width: 32px;
    height: 32px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
    font-size: 0.95rem;
}
.timeline-badge.danger { background: rgba(239, 68, 68, 0.15); color: var(--danger); border: 1px solid rgba(239, 68, 68, 0.3); }
.timeline-badge.warning { background: rgba(245, 158, 11, 0.15); color: var(--warning); border: 1px solid rgba(245, 158, 11, 0.3); }
.timeline-badge.info { background: rgba(14, 165, 233, 0.15); color: var(--secondary); border: 1px solid rgba(14, 165, 233, 0.3); }

.timeline-content {
    flex-grow: 1;
    display: flex;
    flex-direction: column;
    gap: 0.25rem;
}
.timeline-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
}
.timeline-title {
    font-size: 0.9rem;
    font-weight: 600;
    color: var(--text-dark);
}
.timeline-time {
    font-size: 0.75rem;
    color: var(--text-muted);
}
.timeline-desc {
    font-size: 0.82rem;
    color: var(--text-muted);
}
.timeline-actions {
    margin-top: 0.5rem;
}

/* Custom CSS visual charts / metrics */
.sa-stats-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 1rem;
    margin-top: 1rem;
}
.sa-stat-box {
    background: rgba(255, 255, 255, 0.02);
    border: 1px solid var(--border-color);
    border-radius: 10px;
    padding: 1rem;
    text-align: center;
}
.sa-stat-num {
    font-size: 1.5rem;
    font-weight: 800;
    color: var(--primary-neon);
}
.sa-stat-label {
    font-size: 0.75rem;
    color: var(--text-muted);
}

.chart-bar-container {
    display: flex;
    flex-direction: column;
    gap: 0.4rem;
    margin-top: 0.75rem;
}
.chart-bar-label {
    display: flex;
    justify-content: space-between;
    font-size: 0.8rem;
}
.chart-bar-bg {
    height: 10px;
    background: rgba(255, 255, 255, 0.04);
    border-radius: 5px;
    overflow: hidden;
    border: 1px solid rgba(255,255,255,0.02);
}
.chart-bar-fill {
    height: 100%;
    border-radius: 5px;
    transition: width 1s ease-in-out;
}

/* Circular chart simulator */
.circular-chart-box {
    display: flex;
    align-items: center;
    gap: 1.5rem;
    background: rgba(255, 255, 255, 0.02);
    border: 1px solid var(--border-color);
    border-radius: 12px;
    padding: 1.25rem;
}
.circular-progress-mock {
    width: 60px;
    height: 60px;
    border-radius: 50%;
    background: conic-gradient(var(--primary-neon) 0% var(--credit-pct, 0%), rgba(16,185,129,0.08) var(--credit-pct, 0%) 100%);
    display: flex;
    align-items: center;
    justify-content: center;
    position: relative;
}
.circular-progress-mock::after {
    content: attr(data-percent);
    position: absolute;
    width: 48px;
    height: 48px;
    background: #ffffff;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 0.8rem;
    font-weight: 700;
    color: var(--text-dark);
}

/* ---------------------------------------------------- */
/* PREMIUM RISK MATRIX, API SIMULATOR & CHARTS STYLES */
/* ---------------------------------------------------- */

/* 5x5 Risk Matrix */
.risk-matrix-container {
    display: flex;
    gap: 2rem;
    align-items: center;
    justify-content: center;
    margin-top: 1.5rem;
}
.matrix-y-axis {
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    height: 250px;
    font-weight: 600;
    font-size: 0.8rem;
    color: var(--text-muted);
    padding-right: 0.5rem;
    text-align: right;
    writing-mode: vertical-rl;
    transform: rotate(180deg);
}
.matrix-block {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
}
.matrix-grid-5x5 {
    display: grid;
    grid-template-columns: repeat(5, 50px);
    grid-template-rows: repeat(5, 50px);
    gap: 4px;
    background: rgba(255, 255, 255, 0.7);
    border: 1px solid var(--border-color);
    padding: 6px;
    border-radius: 8px;
    position: relative;
}
.matrix-cell {
    border-radius: 4px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 0.75rem;
    font-weight: 700;
    color: #ffffff;
    text-shadow: 0 1px 2px rgba(0,0,0,0.5);
    transition: var(--transition-smooth);
}
/* Matrix Colors (standard risk grids) */
.m-green { background: rgba(16, 185, 129, 0.4); border: 1px solid rgba(16, 185, 129, 0.6); }
.m-green:hover { background: rgba(16, 185, 129, 0.6); }
.m-yellow { background: rgba(245, 158, 11, 0.4); border: 1px solid rgba(245, 158, 11, 0.6); }
.m-yellow:hover { background: rgba(245, 158, 11, 0.6); }
.m-orange { background: rgba(249, 115, 22, 0.55); border: 1px solid rgba(249, 115, 22, 0.75); }
.m-orange:hover { background: rgba(249, 115, 22, 0.75); }
.m-red { background: rgba(239, 68, 68, 0.5); border: 1px solid rgba(239, 68, 68, 0.7); }
.m-red:hover { background: rgba(239, 68, 68, 0.7); }

.matrix-x-axis {
    display: flex;
    justify-content: space-between;
    width: 250px;
    margin-left: 6px;
    margin-top: 0.5rem;
    font-weight: 600;
    font-size: 0.8rem;
    color: var(--text-muted);
}
.matrix-active-marker {
    position: absolute;
    width: 16px;
    height: 16px;
    background: #ffffff;
    border: 3px solid var(--primary-neon);
    border-radius: 50%;
    box-shadow: 0 0 15px var(--primary-neon);
    transform: translate(-50%, -50%);
    pointer-events: none;
    transition: all 0.3s cubic-bezier(0.18, 0.89, 0.32, 1.28);
    z-index: 10;
    animation: markerPulse 1.5s infinite;
}
@keyframes markerPulse {
    0% { transform: translate(-50%, -50%) scale(1); box-shadow: 0 0 10px var(--primary-neon); }
    50% { transform: translate(-50%, -50%) scale(1.2); box-shadow: 0 0 25px var(--primary-neon); }
    100% { transform: translate(-50%, -50%) scale(1); box-shadow: 0 0 10px var(--primary-neon); }
}

.map-overlay-tools {
    position: absolute;
    top: 1rem;
    left: 1rem;
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
    z-index: var(--z-popover);
}
.map-control-btn {
    background: rgba(255, 255, 255, 0.95);
    border: 1px solid var(--border-color);
    padding: 0.5rem 0.75rem;
    border-radius: 8px;
    font-size: 0.85rem;
    font-weight: 600;
    color: var(--text-dark);
    cursor: pointer;
    box-shadow: 0 2px 4px rgba(0,0,0,0.1);
    transition: var(--transition-smooth);
}
.map-control-btn:hover {
    background: var(--bg-card);
    border-color: var(--primary);
    color: var(--primary-neon);
}

/* API Status Indicator Leds */
.api-connection-status {
    background: rgba(255,255,255,0.9);
    border: 1px solid var(--border-color);
    border-radius: 12px;
    padding: 1.25rem;
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
}
.status-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    font-size: 0.85rem;
}
.status-led-group {
    display: flex;
    align-items: center;
    gap: 0.5rem;
}
.status-led {
    width: 8px;
    height: 8px;
    border-radius: 50%;
    display: inline-block;
}
.status-led.green {
    background: var(--primary-neon);
    box-shadow: 0 0 8px var(--primary-neon);
    animation: ledBlink 2s infinite;
}
.status-led.yellow {
    background: var(--warning);
    box-shadow: 0 0 8px var(--warning);
}
.status-led.red {
    background: var(--danger);
    box-shadow: 0 0 8px var(--danger);
}
@keyframes ledBlink {
    0%, 100% { opacity: 1; }
    50% { opacity: 0.4; }
}

/* API simulated logger console */
.api-logger-console {
    background: #040907 !important;
    border-color: rgba(52, 211, 153, 0.3) !important;
    font-family: 'Courier New', Courier, monospace;
    font-size: 0.8rem;
    line-height: 1.4;
    max-height: 180px !important;
}

/* News feed Resmi Gazete styles */
.news-feed-list {
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
    margin-top: 1rem;
}
.news-feed-item {
    background: rgba(255, 255, 255, 0.01);
    border: 1px solid var(--border-color);
    border-radius: 8px;
    padding: 0.75rem;
    transition: var(--transition-smooth);
    cursor: pointer;
}
.news-feed-item:hover {
    background: rgba(16, 185, 129, 0.04);
    border-color: var(--border-hover);
    transform: translateX(2px);
}
.news-feed-date {
    font-size: 0.7rem;
    font-weight: 700;
    color: var(--secondary);
    text-transform: uppercase;
}
.news-feed-title {
    font-size: 0.85rem;
    font-weight: 600;
    color: var(--text-dark);
    margin: 2px 0;
}
.news-feed-desc {
    font-size: 0.78rem;
    color: var(--text-muted);
    line-height: 1.4;
}

/* Waste Stats Header Visuals */
.waste-stats-header {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 1.5rem;
    margin-bottom: 1.5rem;
}
.waste-stat-card {
    background: rgba(255, 255, 255, 0.85);
    border: 1px solid var(--border-color);
    border-radius: 12px;
    padding: 1.25rem;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
}
.waste-stat-card-title {
    font-size: 0.8rem;
    color: var(--text-muted);
    font-weight: 600;
    text-transform: uppercase;
}
.waste-stat-card-value {
    font-size: 1.5rem;
    font-weight: 800;
    color: var(--text-dark);
    margin: 0.25rem 0;
}

.sa-email-grid {
    grid-template-columns: minmax(0, 1.1fr) minmax(320px, 0.9fr);
}

.email-preview-box {
    border: 1px solid var(--border-color);
    background: rgba(255, 255, 255, 0.86);
    border-radius: 8px;
    padding: 1.25rem;
}

.email-preview-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 0.75rem;
    margin-bottom: 1rem;
}

.email-preview-count {
    font-size: 0.78rem;
    color: var(--text-muted);
    font-weight: 700;
}

.email-preview-title {
    color: var(--text-dark);
    font-family: var(--font-heading);
    font-size: 1.2rem;
    font-weight: 800;
    margin-bottom: 0.35rem;
}

.email-preview-subject {
    color: var(--primary);
    font-size: 0.86rem;
    font-weight: 700;
    margin-bottom: 1rem;
}

/* UI/UX Pro Max Enhanced Component Styles */
.cmd-palette-item {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 0.65rem 0.85rem;
    border-radius: 8px;
    background: rgba(255, 255, 255, 0.4);
    border: 1px solid transparent;
    cursor: pointer;
    transition: all 0.15s ease;
}
.cmd-palette-item:hover, .cmd-palette-item.active {
    background: rgba(14, 165, 233, 0.08);
    border-color: rgba(14, 165, 233, 0.3);
    transform: translateX(3px);
}

.wizard-steps-nav {
    display: flex;
    gap: 0.5rem;
    background: rgba(0, 0, 0, 0.03);
    padding: 0.35rem;
    border-radius: 10px;
    margin-bottom: 1.25rem;
    border: 1px solid var(--border-color);
}
.wizard-step-btn {
    flex: 1;
    padding: 0.5rem 0.75rem;
    border: none;
    border-radius: 7px;
    background: transparent;
    font-size: 0.82rem;
    font-weight: 600;
    color: var(--text-muted);
    cursor: pointer;
    transition: all 0.2s ease;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.35rem;
}
.wizard-step-btn.active {
    background: #ffffff;
    color: var(--primary);
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.08);
}
.wizard-step-btn.completed {
    color: var(--success);
}

.drag-drop-zone {
    border: 2px dashed var(--border-color);
    border-radius: 12px;
    padding: 1.5rem;
    text-align: center;
    background: rgba(255, 255, 255, 0.4);
    cursor: pointer;
    transition: all 0.2s ease;
}
.drag-drop-zone:hover, .drag-drop-zone.dragover {
    border-color: var(--primary);
    background: rgba(14, 165, 233, 0.05);
}

/* Timeline Audit Log */
.audit-timeline {
    position: relative;
    padding-left: 1.5rem;
    margin: 1rem 0;
}
.audit-timeline::before {
    content: '';
    position: absolute;
    left: 7px;
    top: 0;
    bottom: 0;
    width: 2px;
    background: var(--border-color);
}
.timeline-item {
    position: relative;
    margin-bottom: 1.25rem;
}
.timeline-dot {
    position: absolute;
    left: -1.5rem;
    top: 4px;
    width: 16px;
    height: 16px;
    border-radius: 50%;
    background: var(--primary);
    border: 3px solid #ffffff;
    box-shadow: 0 0 0 2px rgba(14, 165, 233, 0.2);
}

.email-preview-body {
    min-height: 140px;
    color: var(--text-main);
    line-height: 1.65;
    white-space: pre-wrap;
}

.email-preview-details {
    border-top: 1px solid var(--border-color);
    color: var(--text-muted);
    display: grid;
    gap: 0.5rem;
    font-size: 0.78rem;
    margin-top: 1rem;
    padding-top: 1rem;
}

.waste-code-field {
    position: relative;
}

.waste-code-list,
.waste-code-suggestions {
    background: rgba(255, 255, 255, 0.96);
    border: 1px solid var(--border-color);
    border-radius: 8px;
    display: grid;
    gap: 0.35rem;
    left: 0;
    margin-top: 0;
    max-height: min(240px, 42vh);
    overflow-y: auto;
    padding: 0.5rem;
    position: absolute;
    right: 0;
    top: calc(100% + 0.4rem);
    z-index: 25;
    box-shadow: 0 18px 36px rgba(15, 23, 42, 0.18);
}

.waste-code-list[hidden],
.waste-code-suggestions[hidden] {
    display: none;
}

.waste-code-option {
    align-items: center;
    background: rgba(15, 23, 42, 0.03);
    border: 1px solid rgba(15, 23, 42, 0.08);
    border-radius: 6px;
    color: var(--text-main);
    cursor: pointer;
    display: grid;
    gap: 0.5rem;
    grid-template-columns: 86px minmax(0, 1fr) 38px;
    padding: 0.55rem 0.7rem;
    text-align: left;
    width: 100%;
}

.waste-code-option:hover {
    border-color: rgba(16, 185, 129, 0.35);
    background: rgba(16, 185, 129, 0.07);
}

.waste-code-option.hazardous {
    background: rgba(239, 68, 68, 0.08);
    border-color: rgba(239, 68, 68, 0.18);
}

.waste-code-option-code {
    color: var(--text-dark);
    font-family: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, monospace;
    font-size: 0.78rem;
    font-weight: 800;
}

.waste-code-option-label {
    font-size: 0.78rem;
    line-height: 1.35;
    overflow-wrap: anywhere;
}

.waste-code-option-meta {
    display: flex;
    justify-content: flex-end;
}

.waste-code-pill,
.waste-code-badge-marker {
    background: rgba(15, 23, 42, 0.08);
    border: 1px solid rgba(15, 23, 42, 0.12);
    border-radius: 999px;
    color: var(--text-dark);
    font-size: 0.68rem;
    font-weight: 800;
    margin-left: 0.4rem;
    padding: 0.12rem 0.42rem;
}

.waste-code-badge.hazardous {
    background: rgba(239, 68, 68, 0.12) !important;
    border: 1px solid rgba(239, 68, 68, 0.22);
    color: #991b1b !important;
}

.waste-code-empty {
    color: var(--text-muted);
    font-size: 0.82rem;
    padding: 0.75rem;
    text-align: center;
}

/* Credit package storefront */
.credit-shop-grid {
    grid-template-columns: 1.35fr 0.95fr;
}

.credit-admin-grid {
    grid-template-columns: minmax(320px, 0.85fr) minmax(0, 1.15fr);
}

.search-panel,
.search-results-panel {
    padding: 1.5rem;
    margin-bottom: 1.5rem;
}

.search-form {
    display: grid;
    grid-template-columns: repeat(4, minmax(160px, 1fr));
    gap: 1rem;
    align-items: end;
}

.search-field {
    display: flex;
    flex-direction: column;
    gap: 0.4rem;
}

.search-field-main {
    grid-column: span 2;
}

.search-field label {
    color: var(--text-muted);
    font-family: var(--font-heading);
    font-size: 0.78rem;
    font-weight: 700;
}

.search-field input,
.search-field select {
    width: 100%;
}

.search-type-row {
    display: flex;
    flex-wrap: wrap;
    gap: 0.75rem;
    grid-column: span 3;
    min-height: 42px;
    align-items: center;
}

.search-type-row label {
    align-items: center;
    color: var(--text-main);
    display: inline-flex;
    font-size: 0.86rem;
    gap: 0.35rem;
}

.search-actions {
    display: flex;
    justify-content: flex-end;
    gap: 0.75rem;
}

.search-result-list {
    display: grid;
    gap: 0.75rem;
}

.search-result-item {
    align-items: center;
    background: rgba(255, 255, 255, 0.62);
    border: 1px solid var(--border-color);
    border-radius: 8px;
    display: flex;
    gap: 1rem;
    justify-content: space-between;
    padding: 1rem;
}

.search-result-title {
    color: var(--text-dark);
    font-family: var(--font-heading);
    font-size: 0.98rem;
    font-weight: 800;
    margin-bottom: 0.35rem;
}

.search-result-meta {
    color: var(--text-muted);
    display: flex;
    flex-wrap: wrap;
    font-size: 0.82rem;
    gap: 0.85rem;
}

.search-result-badges {
    display: flex;
    flex-wrap: wrap;
    gap: 0.45rem;
    justify-content: flex-end;
}

.search-empty {
    border: 1px dashed var(--border-color);
    border-radius: 8px;
    color: var(--text-muted);
    padding: 1.5rem;
    text-align: center;
}

.credit-pack-groups {
    display: grid;
    gap: 1.25rem;
}

.credit-pack-group {
    display: grid;
    gap: 1rem;
}

.credit-pack-group-header {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 1rem;
    padding: 1rem 1.1rem;
    border: 1px solid var(--border-color);
    border-radius: 10px;
    background: rgba(255, 255, 255, 0.65);
}

.credit-pack-group-header h4 {
    font-size: 1rem;
    margin-bottom: 0.25rem;
}

.credit-pack-group-header p {
    font-size: 0.82rem;
    color: var(--text-muted);
}

.credit-pack-group-header.tone-sms {
    border-left: 4px solid var(--secondary);
}

.credit-pack-group-header.tone-ai {
    border-left: 4px solid var(--primary-neon);
}

.credit-filter-group {
    display: inline-flex;
    gap: 0.35rem;
    padding: 0.25rem;
    border: 1px solid var(--border-color);
    border-radius: 10px;
    background: rgba(255, 255, 255, 0.6);
}

.credit-filter-btn {
    border: none;
    background: transparent;
    color: var(--text-muted);
    font-family: var(--font-heading);
    font-weight: 700;
    font-size: 0.8rem;
    padding: 0.45rem 0.8rem;
    border-radius: 8px;
    cursor: pointer;
    transition: var(--transition-smooth);
}

.credit-filter-btn:hover,
.credit-filter-btn.active {
    background: rgba(16, 185, 129, 0.1);
    color: var(--primary-neon);
}

.credit-pack-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 1rem;
}

.credit-pack-card {
    display: flex;
    flex-direction: column;
    gap: 0.9rem;
    min-height: 100%;
}

.credit-pack-card-head {
    display: flex;
    justify-content: space-between;
    gap: 1rem;
    align-items: flex-start;
}

.credit-pack-eyebrow {
    font-size: 0.72rem;
    font-weight: 800;
    letter-spacing: 0;
    color: var(--primary);
    text-transform: uppercase;
    margin-bottom: 0.2rem;
}

.credit-pack-card h4 {
    font-size: 1rem;
    margin: 0;
}

.credit-pack-price {
    font-size: 1rem;
    font-weight: 800;
    color: var(--text-dark);
    text-align: right;
    white-space: nowrap;
}

.credit-pack-amount {
    font-size: 1.35rem;
    font-weight: 800;
    color: var(--text-dark);
}

.credit-pack-description {
    font-size: 0.86rem;
    color: var(--text-muted);
    min-height: 44px;
}

.credit-pack-features {
    list-style: none;
    display: grid;
    gap: 0.5rem;
}

.credit-pack-features li {
    position: relative;
    padding-left: 1rem;
    font-size: 0.82rem;
    color: var(--text-main);
}

.credit-pack-features li::before {
    content: '';
    position: absolute;
    left: 0;
    top: 0.55rem;
    width: 0.4rem;
    height: 0.4rem;
    border-radius: 50%;
    background: var(--primary-neon);
}

.credit-pack-action {
    margin-top: auto;
    width: 100%;
}

.credit-pack-empty {
    padding: 1rem;
    border: 1px dashed var(--border-color);
    border-radius: 10px;
    color: var(--text-muted);
    text-align: center;
    font-size: 0.85rem;
}

/* ---------------------------------------------------- */
/* RESPONSIVE DESIGN - MOBILE-FIRST ADJUSTMENTS */
/* ---------------------------------------------------- */
@media (max-width: 992px) {
    .lp-hero {
        grid-template-columns: 1fr;
        text-align: center;
        padding-top: 120px;
        gap: 3rem;
    }
    .lp-hero-text h1 {
        font-size: 2.5rem;
    }
    .lp-hero-ctas {
        justify-content: center;
    }
    .lp-nav-links {
        display: none;
    }
    .pricing-card.featured {
        transform: none;
        margin: 0;
    }
    .pricing-card.featured::before {
        top: 12px;
        right: 12px;
    }
    
    .app-sidebar {
        transform: translateX(-100%);
    }
    .app-sidebar.mobile-active {
        transform: translateX(0);
        width: var(--sidebar-width) !important;
    }
    .app-sidebar.mobile-active .sidebar-logo span,
    .app-sidebar.mobile-active .sidebar-link span,
    .app-sidebar.mobile-active .user-profile-info {
        display: block !important;
    }
    .app-sidebar.mobile-active .sidebar-group-toggle {
        display: flex !important;
    }
    .app-main {
        margin-left: 0 !important;
    }
    
    .dashboard-grid {
        grid-template-columns: 1fr;
    }
    .credit-shop-grid {
        grid-template-columns: 1fr;
    }
    .credit-admin-grid {
        grid-template-columns: 1fr;
    }
    .module-grid {
        grid-template-columns: 1fr;
    }
    .search-form {
        grid-template-columns: 1fr;
    }
    .search-field-main,
    .search-type-row {
        grid-column: auto;
    }
    .search-actions {
        justify-content: stretch;
    }
    .search-actions button {
        flex: 1;
    }
    .search-result-item {
        align-items: flex-start;
        flex-direction: column;
    }
    .search-result-badges {
        justify-content: flex-start;
    }
    .split-view-container {
        grid-template-columns: 1fr;
        height: auto;
    }
    .split-left, .split-right {
        height: 500px;
    }
    .drag-container {
        grid-template-columns: 1fr;
    }
    .report-tabs {
        flex-wrap: nowrap;
        overflow-x: auto;
        padding-bottom: 0.2rem;
    }
    .report-tab-btn {
        flex: 0 0 auto;
        white-space: nowrap;
    }
    .transfer-assign-panel {
        grid-template-columns: 1fr;
    }
    .kanban-quick-move {
        grid-template-columns: 1fr;
        min-width: 100%;
    }
    .f360-category-btn {
        display: none;
    }
    .f360-category-select {
        display: block;
    }
    .f360-tabs-container {
        gap: 0.35rem !important;
        margin-bottom: 1rem !important;
    }
    .f360-tabs-container .btn-secondary {
        font-size: 0.78rem !important;
        padding: 0.42rem 0.65rem !important;
        white-space: nowrap;
    }
}

@media (max-width: 576px) {
    .app-topbar {
        padding: 0 1rem;
    }
    .app-content {
        padding: 1rem;
    }
    .metrics-grid {
        grid-template-columns: 1fr;
    }
    .panel-header {
        flex-direction: column;
        align-items: flex-start;
        gap: 1rem;
    }
    .panel-actions {
        width: 100%;
    }
    .panel-actions .btn-neon,
    .panel-actions .btn-secondary {
        flex-grow: 1;
    }
    .credit-pack-grid {
        grid-template-columns: 1fr;
    }
}

/* ==================================================== */
/* 4. SUPER ADMIN ADVANCED SETTINGS & MAINTENANCE MODE */
/* ==================================================== */

/* Maintenance Overlay Screen */
.maintenance-overlay {
    position: fixed;
    inset: 0;
    width: 100%;
    min-width: 100vw;
    height: 100%;
    min-height: 100vh;
    background-color: var(--bg-base);
    z-index: var(--z-maintenance);
    display: none;
    align-items: center;
    justify-content: center;
    text-align: center;
    padding: 2rem;
    box-sizing: border-box;
    overflow: auto;
    background-image: 
        radial-gradient(circle at 10% 20%, rgba(16, 185, 129, 0.05) 0%, transparent 50%),
        radial-gradient(circle at 90% 80%, rgba(2, 132, 199, 0.04) 0%, transparent 50%);
}

.maintenance-overlay.active {
    display: flex;
}

.maintenance-card {
    width: min(520px, calc(100vw - 2rem));
    max-width: 520px;
    padding: 3rem 2rem;
    border: 1px solid var(--border-hover);
    box-shadow: var(--shadow-neon);
    animation: bounceIn 0.6s cubic-bezier(0.175, 0.885, 0.32, 1.275);
    margin: auto;
}

.maintenance-icon {
    font-size: 4rem;
    margin-bottom: 1.5rem;
    animation: spinSlow 6s linear infinite;
    display: inline-block;
}

@keyframes spinSlow {
    from { transform: rotate(0deg); }
    to { transform: rotate(360deg); }
}

@keyframes bounceIn {
    0% { transform: scale(0.3); opacity: 0; }
    50% { transform: scale(1.05); opacity: 0.8; }
    70% { transform: scale(0.9); opacity: 0.9; }
    100% { transform: scale(1); opacity: 1; }
}

/* Database tools action buttons alignment */
.db-tools-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(120px, 1fr));
    gap: 0.75rem;
    margin-top: 1rem;
}

/* Legislation admin managers */
.admin-crud-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 1rem;
    gap: 1rem;
}

.admin-crud-form {
    border-top: 1px solid var(--border-color);
    padding-top: 1.5rem;
    margin-top: 1.5rem;
}

/* ==================================================== */
/* 5. FIRMA ADMIN (DANIŞMAN KOORDİNATÖRÜ) YENİ EKRANLARI */
/* ==================================================== */

/* Tesis 360 Modalı Sekmeli Menü */
.tab-menu {
    display: flex;
    gap: 0.5rem;
    border-bottom: 1px solid var(--border-color);
    margin-bottom: 1.5rem;
    padding-bottom: 0.5rem;
    overflow-x: auto;
}

.tab-btn {
    background: none;
    border: 1px solid transparent;
    color: var(--text-muted);
    font-family: var(--font-heading);
    font-weight: 600;
    font-size: 0.85rem;
    padding: 0.5rem 1rem;
    border-radius: 8px;
    cursor: pointer;
    transition: var(--transition-smooth);
    white-space: nowrap;
}

.tab-btn:hover {
    color: var(--primary-neon);
    background: rgba(16, 185, 129, 0.05);
}

.tab-btn.active {
    color: #ffffff;
    background: var(--primary);
    border-color: var(--primary);
}

.tab-content {
    display: none;
    animation: fadeIn 0.3s ease;
}

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

.f360-category-switch {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    flex-wrap: wrap;
    margin-bottom: 0.75rem;
}

.f360-category-btn {
    border: 1px solid var(--border-color);
    background: rgba(255, 255, 255, 0.78);
    color: var(--text-muted);
    border-radius: 8px;
    padding: 0.55rem 0.85rem;
    cursor: pointer;
    font-weight: 700;
}

.f360-category-btn.active,
.f360-category-btn:hover,
.f360-category-btn:focus-visible {
    color: var(--primary-neon);
    border-color: rgba(16, 185, 129, 0.45);
    background: rgba(16, 185, 129, 0.08);
    outline: none;
}

.f360-category-select {
    display: none;
    max-width: 100%;
    margin-bottom: 0;
}

.f360-tabs-container button[hidden] {
    display: none !important;
}

/* Dikey Canlı Faaliyet Akışı (Activity Log Timeline) */
.activity-feed-card {
    display: flex;
    flex-direction: column;
    height: 100%;
}

.activity-feed-container {
    max-height: 480px;
    overflow-y: auto;
    padding-right: 0.5rem;
    margin-top: 1rem;
}

.transfer-assign-panel {
    grid-column: 1 / -1;
    display: grid;
    grid-template-columns: minmax(180px, 1.2fr) minmax(180px, 1fr) minmax(180px, 1fr) auto;
    gap: 0.75rem;
    align-items: center;
    padding: 1rem;
    border: 1px solid rgba(16, 185, 129, 0.22);
    border-radius: 8px;
    background: rgba(16, 185, 129, 0.06);
}

.transfer-assign-panel strong,
.transfer-assign-panel span {
    display: block;
}

.transfer-assign-panel span {
    color: var(--text-muted);
    font-size: 0.82rem;
    margin-top: 0.2rem;
}

.kanban-quick-move {
    min-width: 100%;
    display: grid;
    grid-template-columns: minmax(180px, 1.2fr) minmax(180px, 1fr) minmax(180px, 1fr) auto;
    gap: 0.75rem;
    align-items: center;
    padding: 1rem;
    border: 1px solid rgba(59, 130, 246, 0.22);
    border-radius: 8px;
    background: rgba(59, 130, 246, 0.06);
}

.kanban-quick-move strong,
.kanban-quick-move span {
    display: block;
}

.kanban-quick-move span {
    color: var(--text-muted);
    font-size: 0.82rem;
    margin-top: 0.2rem;
}

.activity-item {
    position: relative;
    padding-left: 2rem;
    padding-bottom: 1.5rem;
}

.activity-item::before {
    content: '';
    position: absolute;
    left: 7px;
    top: 6px;
    bottom: 0;
    width: 2px;
    background: var(--border-color);
}

.activity-item:last-child::before {
    display: none;
}

.activity-badge {
    position: absolute;
    left: 0;
    top: 4px;
    width: 16px;
    height: 16px;
    border-radius: 50%;
    background: var(--primary-neon);
    border: 3px solid var(--bg-base);
    box-shadow: 0 0 0 2px var(--border-color);
}

.activity-badge.risk { background: var(--warning) !important; }
.activity-badge.waste { background: var(--secondary) !important; }
.activity-badge.visit { background: var(--info) !important; }
.activity-badge.api { background: var(--success) !important; }
.activity-badge.doc { background: #06b6d4 !important; } /* Cyan for doc */

.activity-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 0.25rem;
}

.activity-user {
    font-weight: 700;
    font-size: 0.85rem;
    color: var(--text-dark);
}

.activity-time {
    font-size: 0.72rem;
    color: var(--text-muted);
}

.activity-text {
    font-size: 0.8rem;
    color: var(--text-main);
    line-height: 1.4;
}

/* Firma Raporlama Modülü Analitik Barlar */
.reporting-metrics-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 1.5rem;
    margin-bottom: 2rem;
}

.report-bar-container {
    margin-bottom: 1rem;
}

.report-bar-label {
    display: flex;
    justify-content: space-between;
    font-size: 0.82rem;
    margin-bottom: 0.25rem;
    color: var(--text-muted);
}

.report-bar-bg {
    height: 10px;
    background: rgba(16, 185, 129, 0.05);
    border: 1px solid var(--border-color);
    border-radius: 6px;
    overflow: hidden;
}

.report-bar-fill {
    height: 100%;
    border-radius: 6px;
    transition: width 0.8s ease-in-out;
}

/* ==================================================== */
/* 6. ÇED KANBAN PANOSU (EIA WORKFLOWS) */
/* ==================================================== */

.kanban-board {
    display: flex;
    gap: 1.5rem;
    overflow-x: auto;
    padding-bottom: 1rem;
    min-height: 600px;
    align-items: flex-start;
}

.kanban-column {
    flex: 0 0 300px;
    background: rgba(255, 255, 255, 0.4);
    border: 1px solid var(--border-color);
    border-radius: 12px;
    display: flex;
    flex-direction: column;
}

.kanban-column-header {
    padding: 1rem;
    border-bottom: 1px solid var(--border-color);
    display: flex;
    justify-content: space-between;
    align-items: center;
    background: rgba(255, 255, 255, 0.6);
    border-radius: 12px 12px 0 0;
}

.kanban-column-title {
    font-size: 0.95rem;
    font-weight: 700;
    color: var(--text-dark);
}

.kanban-column-count {
    background: var(--bg-base);
    color: var(--text-muted);
    font-size: 0.75rem;
    font-weight: 800;
    padding: 0.2rem 0.5rem;
    border-radius: 99px;
    border: 1px solid var(--border-color);
}

.kanban-cards {
    padding: 1rem;
    display: flex;
    flex-direction: column;
    gap: 1rem;
    overflow-y: auto;
    flex-grow: 1;
}

.kanban-card {
    background: #ffffff;
    border: 1px solid var(--border-color);
    border-radius: 8px;
    padding: 1rem;
    cursor: grab;
    transition: var(--transition-smooth);
    position: relative;
    box-shadow: 0 2px 8px rgba(0,0,0,0.02);
}

.kanban-card:active {
    cursor: grabbing;
}

.kanban-card:hover {
    transform: translateY(-2px);
    box-shadow: var(--shadow-neon);
    border-color: var(--border-hover);
}

.kanban-card.overdue {
    border-color: var(--danger);
    animation: pulse-red 2s infinite;
}

@keyframes pulse-red {
    0% { box-shadow: 0 0 0 0 rgba(220, 38, 38, 0.4); }
    70% { box-shadow: 0 0 0 10px rgba(220, 38, 38, 0); }
    100% { box-shadow: 0 0 0 0 rgba(220, 38, 38, 0); }
}

.kanban-card-title {
    font-size: 0.9rem;
    font-weight: 700;
    color: var(--text-dark);
    margin-bottom: 0.5rem;
}

.kanban-card-firm {
    font-size: 0.75rem;
    color: var(--text-muted);
    margin-bottom: 0.75rem;
    display: flex;
    align-items: center;
    gap: 0.25rem;
}

.kanban-timer {
    display: inline-flex;
    align-items: center;
    gap: 0.4rem;
    font-size: 0.75rem;
    font-weight: 700;
    padding: 0.25rem 0.5rem;
    border-radius: 4px;
}

.kanban-timer.timer-red { background: rgba(220, 38, 38, 0.1); color: var(--danger); }
.kanban-timer.timer-yellow { background: rgba(245, 158, 11, 0.1); color: var(--warning); }
.kanban-timer.timer-green { background: rgba(16, 185, 129, 0.1); color: var(--primary-neon); }

/* Switch View Container */
.eia-view-switch {
    display: flex;
    gap: 0.5rem;
    margin-bottom: 1.5rem;
}

/* ==================================================== */
/* 7. DOCUMENTS GRID/FOLDER VIEW */
/* ==================================================== */

.doc-folders-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
    gap: 1.5rem;
}

.doc-folder-card {
    padding: 1.5rem;
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
    transition: var(--transition-smooth);
    border: 1px solid var(--border-color);
}

.doc-folder-card:hover {
    transform: translateY(-5px);
    box-shadow: var(--shadow-neon);
    border-color: var(--primary-neon);
}

.folder-icon {
    font-size: 3.5rem;
    margin-bottom: 1rem;
    line-height: 1;
}

.folder-title {
    font-size: 1.1rem;
    font-weight: 700;
    color: var(--text-dark);
    margin-bottom: 0.25rem;
}

.folder-meta {
    font-size: 0.8rem;
    color: var(--text-muted);
    background: var(--bg-base);
    padding: 0.25rem 0.75rem;
    border-radius: 99px;
    margin-bottom: 1rem;
}

.folder-docs {
    width: 100%;
    text-align: left;
    background: rgba(255,255,255,0.02);
    border-radius: 8px;
    padding: 0.75rem;
    min-height: 80px;
    flex-grow: 1;
}

.mini-doc-item {
    font-size: 0.75rem;
    color: var(--text-main);
    padding: 0.25rem 0;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    border-bottom: 1px solid rgba(255,255,255,0.05);
}

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

/* Kanban layout and scroll fix */
.kanban-board {
    display: flex;
    gap: 1rem;
    overflow-x: auto;
    overflow-y: hidden;
    padding-bottom: 1rem;
    min-height: 400px;
    width: 100%;
    box-sizing: border-box;
    scroll-behavior: smooth;
    -webkit-overflow-scrolling: touch;
}

.kanban-board::-webkit-scrollbar {
    height: 10px;
}
.kanban-board::-webkit-scrollbar-track {
    background: rgba(0, 0, 0, 0.05);
    border-radius: 5px;
}
.kanban-board::-webkit-scrollbar-thumb {
    background: var(--primary);
    border-radius: 5px;
}
.kanban-board::-webkit-scrollbar-thumb:hover {
    background: var(--primary-neon);
}

.kanban-column {
    min-width: 320px;
    flex: 0 0 320px;
    background: rgba(255,255,255,0.4);
    border: 1px solid var(--border-color);
    border-radius: 12px;
    padding: 1rem;
    display: flex;
    flex-direction: column;
}
.kanban-column-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 1rem;
    padding-bottom: 0.5rem;
    border-bottom: 1px solid var(--border-color);
}
.kanban-column-title {
    font-weight: 600;
    color: var(--text-dark);
}
.kanban-column-count {
    background: var(--bg-base);
    color: var(--primary);
    font-size: 0.75rem;
    padding: 0.15rem 0.5rem;
    border-radius: 10px;
    border: 1px solid var(--border-color);
    font-weight: 700;
}
.kanban-cards {
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
    min-height: 100px;
}
.kanban-card {
    background: var(--bg-card);
    border: 1px solid var(--border-color);
    padding: 1rem;
    border-radius: 8px;
    cursor: pointer;
    transition: var(--transition-smooth);
}
.kanban-card:hover {
    transform: translateY(-2px);
    box-shadow: var(--shadow-neon);
    border-color: var(--primary);
}
.kanban-card-title {
    font-weight: 600;
    margin-bottom: 0.25rem;
    color: var(--text-dark);
}
.kanban-card-firm {
    font-size: 0.8rem;
    color: var(--text-muted);
    margin-bottom: 0.75rem;
}
.kanban-timer {
    display: inline-flex;
    align-items: center;
    gap: 0.25rem;
    font-size: 0.75rem;
    padding: 0.25rem 0.5rem;
    border-radius: 6px;
    font-weight: 600;
}
.kanban-timer.timer-green { background: rgba(16, 185, 129, 0.1); color: var(--success); }
.kanban-timer.timer-yellow { background: rgba(245, 158, 11, 0.1); color: var(--warning); }
.kanban-timer.timer-red { background: rgba(239, 68, 68, 0.1); color: var(--danger); }
.kanban-card.overdue { border-color: var(--danger); }

/* Sidebar nav alignments and fixes to prevent shifts */
.sidebar-nav {
    padding: 1.5rem 0.75rem !important;
}
.sidebar-nav li {
    width: 100% !important;
    margin: 0 !important;
    padding: 0 !important;
    list-style: none !important;
}
.sidebar-link {
    display: flex !important;
    align-items: center !important;
    justify-content: flex-start !important;
    padding: 0.75rem 1rem !important;
    margin: 0 !important;
    gap: 1rem !important;
}
.sidebar-link span:not(.nav-icon) {
    margin: 0 !important;
    padding: 0 !important;
}

/* Credits Welcome Card Styling - Differentiates from Dashboard */
.credits-welcome {
    background: linear-gradient(135deg, rgba(6, 182, 212, 0.12) 0%, rgba(14, 165, 233, 0.05) 100%);
    border: 1px solid rgba(6, 182, 212, 0.25);
    padding: 1.5rem 2rem;
    border-radius: 16px;
    margin-bottom: 2rem;
    display: flex;
    justify-content: space-between;
    align-items: center;
}
.credits-welcome-text h2 {
    font-size: 1.75rem;
    margin-bottom: 0.25rem;
    background: linear-gradient(135deg, var(--text-dark), #06b6d4);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    font-family: var(--font-heading);
    font-weight: 700;
}
.credits-welcome-text p {
    color: var(--text-muted);
    font-size: 0.9rem;
}
.credits-welcome .badge-primary {
    cursor: pointer;
    transition: var(--transition-smooth);
}
.credits-welcome .badge-primary:hover {
    background: rgba(6, 182, 212, 0.25);
    border-color: rgba(6, 182, 212, 0.5);
    transform: translateY(-1px);
}

/* Profile and User Settings UI Enhancements */
.form-input-icon-wrapper {
    position: relative;
    width: 100%;
}

.form-input-icon-wrapper .form-input {
    padding-left: 2.75rem !important;
}

.form-input-icon-wrapper .input-icon {
    position: absolute;
    left: 1rem;
    top: 50%;
    transform: translateY(-50%);
    font-size: 1.1rem;
    color: var(--text-muted);
    transition: var(--transition-smooth);
    pointer-events: none;
    line-height: 1;
}

.form-input-icon-wrapper .form-input:focus + .input-icon {
    color: var(--primary);
    filter: drop-shadow(0 0 4px var(--primary-glow));
}

.user-meta-cell {
    display: flex;
    align-items: center;
    gap: 0.85rem;
}

.avatar-circle {
    width: 38px;
    height: 38px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 700;
    font-size: 0.9rem;
    font-family: var(--font-heading);
    color: #ffffff;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.05);
    flex-shrink: 0;
    text-transform: uppercase;
}

.user-details-wrapper {
    display: flex;
    flex-direction: column;
    gap: 0.15rem;
}

.user-details-wrapper .user-name-text {
    font-weight: 700;
    color: var(--text-dark);
    font-size: 0.9rem;
}

.user-details-wrapper .user-email-text {
    font-size: 0.8rem;
    color: var(--text-muted);
}

/* ==================================================== */
/* MESSAGING SYSTEM REDESIGN STYLES */
/* ==================================================== */

.messaging-layout {
    display: grid;
    grid-template-columns: 350px 1fr;
    gap: 1.5rem;
    height: calc(100vh - 220px);
    min-height: 500px;
    align-items: stretch;
}

.messaging-sidebar {
    display: flex;
    flex-direction: column;
    height: 100%;
    overflow: hidden;
    padding: 1.25rem 0 0 0;
}

.messaging-tabs {
    display: flex;
    border-bottom: 1px solid var(--border-color);
    padding: 0 1.25rem;
    gap: 1rem;
}

.msg-tab {
    background: none;
    border: none;
    padding: 0.75rem 0.25rem;
    font-family: var(--font-heading);
    font-weight: 600;
    font-size: 0.9rem;
    color: var(--text-muted);
    cursor: pointer;
    position: relative;
    transition: var(--transition-smooth);
}

.msg-tab:hover {
    color: var(--primary);
}

.msg-tab.active {
    color: var(--primary-neon);
}

.msg-tab.active::after {
    content: '';
    position: absolute;
    bottom: -1px;
    left: 0;
    right: 0;
    height: 2px;
    background: var(--primary-neon);
    box-shadow: 0 0 8px var(--primary-neon);
}

.messaging-search {
    padding: 1rem 1.25rem;
}

.messaging-list {
    flex-grow: 1;
    overflow-y: auto;
    padding: 0 0.5rem 1.25rem 0.5rem;
}

.message-card {
    display: flex;
    gap: 0.75rem;
    padding: 1rem 1rem;
    margin: 0 0.75rem 0.5rem 0.75rem;
    border-radius: 12px;
    border: 1px solid transparent;
    cursor: pointer;
    transition: var(--transition-smooth);
    position: relative;
}

.message-card:hover {
    background: rgba(16, 185, 129, 0.04);
    border-color: rgba(16, 185, 129, 0.08);
}

.message-card.active {
    background: rgba(13, 148, 136, 0.06);
    border-color: rgba(13, 148, 136, 0.15);
}

.message-card-body {
    flex-grow: 1;
    min-width: 0;
}

.message-card-header {
    display: flex;
    justify-content: space-between;
    align-items: baseline;
    gap: 0.5rem;
    margin-bottom: 0.25rem;
}

.message-card-name {
    font-weight: 600;
    font-size: 0.875rem;
    color: var(--text-dark);
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.message-card-date {
    font-size: 0.75rem;
    color: var(--text-muted);
    white-space: nowrap;
}

.message-card-subject {
    font-size: 0.825rem;
    font-weight: 600;
    color: var(--text-main);
    margin-bottom: 0.15rem;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.message-card-preview {
    font-size: 0.775rem;
    color: var(--text-muted);
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.unread-dot {
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background-color: var(--primary-neon);
    box-shadow: 0 0 8px var(--primary-neon);
    position: absolute;
    right: 1rem;
    bottom: 1.2rem;
}

.message-card.unread .message-card-subject {
    color: var(--text-dark);
    font-weight: 700;
}

.messaging-content {
    display: flex;
    flex-direction: column;
    height: 100%;
    overflow: hidden;
}

.messaging-placeholder {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    flex-grow: 1;
    color: var(--text-muted);
    text-align: center;
    padding: 2rem;
}

.placeholder-icon {
    width: 80px;
    height: 80px;
    border-radius: 50%;
    background: rgba(16, 185, 129, 0.06);
    border: 1px solid var(--border-color);
    display: flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 1.25rem;
    color: var(--primary);
    animation: pulse 2s infinite ease-in-out;
}

.messaging-form-wrapper,
.messaging-detail-wrapper {
    display: flex;
    flex-direction: column;
    height: 100%;
    padding: 1.5rem;
    overflow-y: auto;
}

.messaging-form-wrapper .content-header,
.detail-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    border-bottom: 1px solid var(--border-color);
    padding-bottom: 1.25rem;
    margin-bottom: 1.5rem;
}

.messaging-form-wrapper form {
    display: flex;
    flex-direction: column;
    gap: 1.25rem;
    flex-grow: 1;
}

.messaging-form-wrapper form .form-actions {
    display: flex;
    justify-content: flex-end;
    gap: 0.75rem;
    margin-top: auto;
    padding-top: 1rem;
}

.btn-close {
    background: none;
    border: none;
    font-size: 1.75rem;
    color: var(--text-muted);
    cursor: pointer;
    transition: var(--transition-smooth);
    line-height: 1;
}

.btn-close:hover {
    color: var(--danger);
}

.detail-header .sender-info {
    display: flex;
    align-items: center;
    gap: 0.75rem;
}

.detail-header .sender-info h4 {
    font-size: 1rem;
    margin-bottom: 0.1rem;
}

.detail-header .sender-info span {
    font-size: 0.8rem;
    color: var(--text-muted);
}

.detail-header .msg-meta {
    display: flex;
    flex-direction: column;
    align-items: flex-end;
    gap: 0.4rem;
}

.detail-header .msg-meta #detailDate {
    font-size: 0.8rem;
    color: var(--text-muted);
}

.detail-body {
    padding: 0.5rem 0;
}

.detail-body h3 {
    font-size: 1.25rem;
    margin-bottom: 1.25rem;
    color: var(--text-dark);
}

.detail-text {
    font-size: 0.95rem;
    line-height: 1.7;
    color: var(--text-main);
    white-space: pre-wrap;
    background: rgba(255, 255, 255, 0.4);
    border: 1px solid var(--border-color);
    border-radius: 12px;
    padding: 1.5rem;
}

@keyframes pulse {
    0% { transform: scale(1); box-shadow: 0 0 0 0 rgba(16, 185, 129, 0.2); }
    70% { transform: scale(1.05); box-shadow: 0 0 0 10px rgba(16, 185, 129, 0); }
    100% { transform: scale(1); box-shadow: 0 0 0 0 rgba(16, 185, 129, 0); }
}

@media (max-width: 992px) {
    .messaging-layout {
        grid-template-columns: 1fr;
        height: auto;
    }
    .messaging-sidebar {
        height: 400px;
    }
}

/* Premium Info & Description Card */
.premium-info-card {
    display: flex;
    gap: 1.25rem;
    align-items: flex-start;
    background: linear-gradient(135deg, rgba(255, 255, 255, 0.75), rgba(255, 255, 255, 0.45));
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    border: 1px solid var(--border-color);
    border-radius: 14px;
    padding: 1.25rem 1.5rem;
    margin-bottom: 1.5rem;
    box-shadow: 0 4px 20px rgba(16, 185, 129, 0.04);
    transition: var(--transition-smooth);
}

.premium-info-card:hover {
    border-color: var(--border-hover);
    box-shadow: 0 6px 24px rgba(16, 185, 129, 0.08);
    transform: translateY(-1px);
}

.premium-info-card .card-icon {
    font-size: 1.75rem;
    color: var(--primary);
    display: flex;
    align-items: center;
    justify-content: center;
    background: rgba(13, 148, 136, 0.08);
    border-radius: 10px;
    height: 48px;
    width: 48px;
    flex-shrink: 0;
}

.premium-info-card .card-content {
    display: flex;
    flex-direction: column;
    gap: 0.25rem;
}

.premium-info-card .card-title {
    font-family: var(--font-heading);
    font-size: 1.05rem;
    font-weight: 700;
    color: var(--text-dark);
}

.premium-info-card .card-description {
    font-size: 0.88rem;
    color: var(--text-muted);
    line-height: 1.5;
}

/* ---------------------------------------------------- */
/* SKELETON LOADERS & EMPTY STATES & RESPONSIVE TABLES */
/* ---------------------------------------------------- */

/* Automatic Responsive Tables on Mobile */
@media (max-width: 768px) {
    table {
        display: block !important;
        width: 100% !important;
        overflow-x: auto !important;
        -webkit-overflow-scrolling: touch;
        border-collapse: collapse;
    }
}

/* Skeleton Shimmer Animation */
@keyframes skeleton-shimmer {
    0% { background-position: -200% 0; }
    100% { background-position: 200% 0; }
}

.skeleton-row td {
    padding: 1rem !important;
}

.skeleton-line {
    display: inline-block;
    height: 16px;
    border-radius: 6px;
    background: linear-gradient(90deg, 
        rgba(16, 185, 129, 0.05) 25%, 
        rgba(16, 185, 129, 0.15) 50%, 
        rgba(16, 185, 129, 0.05) 75%
    );
    background-size: 200% 100%;
    animation: skeleton-shimmer 1.5s infinite ease-in-out;
}

/* Empty State Styling */
.empty-state-card {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 3.5rem 2rem;
    text-align: center;
    gap: 0.75rem;
}

.empty-state-icon {
    width: 64px;
    height: 64px;
    border-radius: 50%;
    background: rgba(16, 185, 129, 0.08);
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--primary);
    border: 1px dashed rgba(16, 185, 129, 0.3);
    margin-bottom: 0.5rem;
    transition: var(--transition-smooth);
}

.empty-state-card:hover .empty-state-icon {
    transform: scale(1.05);
    background: rgba(16, 185, 129, 0.12);
    border-color: var(--primary);
}

/* ---------------------------------------------------- */
/* PREMIUM FORM CONTROLS & MODERNIZATION */
/* ---------------------------------------------------- */

/* Gelişmiş Select (Seçim Kutusu) Tasarımı */
select.form-input {
    appearance: none !important;
    -webkit-appearance: none !important;
    -moz-appearance: none !important;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' fill='none' viewBox='0 0 24 24' stroke='%230d9488' stroke-width='2.5'%3E%3Cpath stroke-linecap='round' stroke-linejoin='round' d='M19 9l-7 7-7-7'/%3E%3C/svg%3E") !important;
    background-repeat: no-repeat !important;
    background-position: right 1rem center !important;
    background-size: 1.1rem !important;
    padding-right: 2.75rem !important;
    cursor: pointer;
}

select.form-input option {
    background-color: #0f172a !important;
    color: #ffffff !important;
    padding: 0.75rem !important;
}

/* Premium Range (Kaydırıcı / Slider) Tasarımı */
input[type="range"].form-input,
.form-group input[type="range"] {
    -webkit-appearance: none !important;
    appearance: none !important;
    width: 100%;
    height: 6px !important;
    background: rgba(16, 185, 129, 0.1) !important;
    border: 1px solid rgba(16, 185, 129, 0.15) !important;
    border-radius: 3px !important;
    outline: none !important;
    padding: 0 !important;
    margin: 12px 0 !important;
    box-shadow: none !important;
    transition: background 0.3s ease, border-color 0.3s ease;
}

input[type="range"].form-input:hover,
.form-group input[type="range"]:hover {
    background: rgba(16, 185, 129, 0.15) !important;
    border-color: rgba(16, 185, 129, 0.25) !important;
}

/* Webkit (Chrome, Safari, Edge) Slider Thumb */
input[type="range"].form-input::-webkit-slider-thumb,
.form-group input[type="range"]::-webkit-slider-thumb {
    -webkit-appearance: none !important;
    appearance: none !important;
    width: 18px !important;
    height: 18px !important;
    border-radius: 50% !important;
    background: var(--primary-neon) !important;
    cursor: pointer !important;
    border: 2px solid #ffffff !important;
    box-shadow: 0 0 10px var(--primary-neon), 0 2px 4px rgba(0,0,0,0.3) !important;
    transition: transform 0.1s ease, background-color 0.1s ease !important;
}

input[type="range"].form-input::-webkit-slider-thumb:hover,
.form-group input[type="range"]::-webkit-slider-thumb:hover {
    transform: scale(1.2) !important;
    background: #ffffff !important;
    border-color: var(--primary-neon) !important;
}

/* Firefox Slider Thumb */
input[type="range"].form-input::-moz-range-thumb,
.form-group input[type="range"]::-moz-range-thumb {
    width: 18px !important;
    height: 18px !important;
    border-radius: 50% !important;
    background: var(--primary-neon) !important;
    cursor: pointer !important;
    border: 2px solid #ffffff !important;
    box-shadow: 0 0 10px var(--primary-neon), 0 2px 4px rgba(0,0,0,0.3) !important;
    transition: transform 0.1s ease, background-color 0.1s ease !important;
}

input[type="range"].form-input::-moz-range-thumb:hover,
.form-group input[type="range"]::-moz-range-thumb:hover {
    transform: scale(1.2) !important;
    background: #ffffff !important;
    border-color: var(--primary-neon) !important;
}

/* Dosya Girişi (File Input) Tasarımı */
input[type="file"].form-input {
    padding: 0.5rem 0.75rem !important;
    cursor: pointer !important;
    display: flex !important;
    align-items: center !important;
}

input[type="file"].form-input::file-selector-button {
    background: var(--primary) !important;
    color: #ffffff !important;
    border: none !important;
    padding: 0.4rem 0.8rem !important;
    border-radius: 6px !important;
    margin-right: 1rem !important;
    cursor: pointer !important;
    font-size: 0.8rem !important;
    font-weight: 600 !important;
    transition: var(--transition-smooth) !important;
}

input[type="file"].form-input::file-selector-button:hover {
    background: var(--primary-neon) !important;
    box-shadow: 0 0 8px var(--primary-neon) !important;
}

/* Özel Onay ve Radyo Kutuları (Checkbox & Radio) Tasarımı */
input[type="checkbox"]:not(.toggle-switch), 
input[type="radio"] {
    position: relative !important;
    width: 1.2rem !important;
    height: 1.2rem !important;
    color: var(--primary) !important;
    border: 1.5px solid var(--border-color) !important;
    border-radius: 4px !important;
    appearance: none !important;
    -webkit-appearance: none !important;
    outline: 0 !important;
    cursor: pointer !important;
    transition: background 175ms cubic-bezier(0.1, 0.1, 0.25, 1), border-color 175ms ease, box-shadow 175ms ease !important;
    background-color: rgba(15, 23, 42, 0.6) !important;
    vertical-align: middle !important;
    display: inline-grid !important;
    place-content: center !important;
    margin: 0 !important;
}

input[type="radio"] {
    border-radius: 50% !important;
}

input[type="checkbox"]:not(.toggle-switch)::before {
    content: "" !important;
    width: 0.65rem !important;
    height: 0.65rem !important;
    clip-path: polygon(14% 44%, 0 58%, 33% 90%, 100% 16%, 86% 2%, 33% 62%) !important;
    transform: scale(0) !important;
    transform-origin: bottom left !important;
    transition: 120ms transform ease-in-out !important;
    background-color: #ffffff !important;
}

input[type="checkbox"]:not(.toggle-switch):checked::before {
    transform: scale(1) !important;
}

input[type="radio"]::before {
    content: "" !important;
    width: 0.5rem !important;
    height: 0.5rem !important;
    border-radius: 50% !important;
    transform: scale(0) !important;
    transition: 120ms transform ease-in-out !important;
    background-color: #ffffff !important;
}

input[type="radio"]:checked::before {
    transform: scale(1) !important;
}

input[type="checkbox"]:not(.toggle-switch):checked, 
input[type="radio"]:checked {
    background-color: var(--primary) !important;
    border-color: var(--primary) !important;
    box-shadow: 0 0 8px rgba(13, 148, 136, 0.4) !important;
}

input[type="checkbox"]:not(.toggle-switch):focus-visible, 
input[type="radio"]:focus-visible {
    outline: 2px solid var(--primary) !important;
    outline-offset: 2px !important;
}

/* Genel Girdilerde Premium Hover & Focus Efektleri */
.form-input:focus {
    border-color: var(--primary-neon) !important;
    background: #ffffff !important;
    box-shadow: 0 0 0 4px rgba(13, 148, 136, 0.15), 0 4px 12px rgba(13, 148, 136, 0.1) !important;
}

/* AI Advisor Premium Styles */
.advisor-grid {
    grid-template-columns: 300px 1fr;
}

@media (max-width: 992px) {
    .advisor-grid {
        grid-template-columns: 1fr !important;
    }
}

#advisorHistoryList button {
    background: rgba(255, 255, 255, 0.45);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    transition: all 0.25s cubic-bezier(0.4, 0, 0.2, 1);
}

#advisorHistoryList button:hover {
    transform: translateY(-2px);
    border-color: var(--primary-neon) !important;
    box-shadow: 0 4px 15px rgba(16, 185, 129, 0.1);
    background: rgba(255, 255, 255, 0.7);
}

#advisorStepsList li {
    font-weight: 500;
    transition: color 0.3s ease;
}

#advisorStepsList .bullet {
    transition: background 0.3s ease, box-shadow 0.3s ease;
}

/* Markdown Render Container */
.markdown-body h1, .markdown-body h2, .markdown-body h3 {
    margin-top: 1.5rem;
    margin-bottom: 0.75rem;
    font-weight: 700;
}

.markdown-body p {
    margin-bottom: 1rem;
    line-height: 1.625;
}

.markdown-body ul {
    margin-bottom: 1rem;
    padding-left: 1.5rem;
}

.markdown-body table {
    width: 100%;
    border-collapse: collapse;
    margin: 1.5rem 0;
}

.markdown-body th {
    background-color: rgba(16, 185, 129, 0.08);
    font-weight: 700;
    border: 1px solid var(--border-color, #e2e8f0);
}

.markdown-body td, .markdown-body th {
    padding: 10px 12px;
    border: 1px solid var(--border-color, #e2e8f0);
    font-size: 0.88rem;
}

.markdown-body blockquote {
    margin: 1.5rem 0;
    padding: 0.75rem 1.25rem;
    background: #fffbeb;
    border-left: 4px solid #f59e0b;
    color: #b45309;
    border-radius: 6px;
}

/* Premium Skeleton Loader Styles */
@keyframes skeleton-pulse {
    0% {
        opacity: 0.6;
        background-color: rgba(226, 232, 240, 0.4);
    }
    50% {
        opacity: 1;
        background-color: rgba(203, 213, 225, 0.7);
    }
    100% {
        opacity: 0.6;
        background-color: rgba(226, 232, 240, 0.4);
    }
}

.skeleton {
    animation: skeleton-pulse 1.5s infinite ease-in-out;
    border-radius: 4px;
    display: inline-block;
    width: 100%;
}

.skeleton-text {
    height: 12px;
    margin-bottom: 8px;
}

.skeleton-text:last-child {
    margin-bottom: 0;
    width: 70%;
}

.skeleton-title {
    height: 20px;
    margin-bottom: 12px;
    width: 40%;
}

.skeleton-rect {
    height: 100px;
}

/* Global Toast Notification System Styles */
.toast-container {
    position: fixed;
    top: 24px;
    right: 24px;
    z-index: var(--z-toast);
    display: flex;
    flex-direction: column;
    gap: 12px;
    max-width: 380px;
    width: 100%;
    pointer-events: none;
}

.toast {
    background: rgba(255, 255, 255, 0.85);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    border: 1px solid rgba(226, 232, 240, 0.8);
    border-radius: 12px;
    padding: 1rem 1.25rem;
    box-shadow: 0 10px 25px -5px rgba(0, 0, 0, 0.1), 0 8px 10px -6px rgba(0, 0, 0, 0.1);
    display: flex;
    align-items: start;
    gap: 0.75rem;
    transform: translateX(120%);
    transition: transform 0.35s cubic-bezier(0.16, 1, 0.3, 1);
    pointer-events: auto;
}

.toast.show {
    transform: translateX(0);
}

.toast-icon {
    font-size: 1.25rem;
    line-height: 1;
}

.toast-content {
    flex-grow: 1;
}

.toast-title {
    font-weight: 700;
    font-size: 0.9rem;
    color: var(--text-dark, #1e293b);
    margin-bottom: 0.2rem;
}

.toast-message {
    font-size: 0.82rem;
    color: var(--text-muted, #64748b);
    line-height: 1.4;
}

.toast-close {
    background: none;
    border: none;
    color: var(--text-muted, #94a3b8);
    cursor: pointer;
    font-size: 1.1rem;
    padding: 0;
    line-height: 1;
    margin-left: 0.5rem;
}

.toast-close:hover {
    color: var(--text-dark, #1e293b);
}

.toast-success {
    border-left: 4px solid var(--success, #10b981);
}

.toast-error {
    border-left: 4px solid var(--danger, #ef4444);
}

.toast-info {
    border-left: 4px solid var(--info, #3b82f6);
}

.carbon-manual-item-form {
    grid-template-columns: minmax(260px, 1.7fr) minmax(120px, 0.75fr) minmax(105px, 0.6fr) minmax(160px, 0.95fr) !important;
}

.carbon-manual-item-form .form-input {
    height: 44px !important;
    min-height: 44px;
    padding-top: 0 !important;
    padding-bottom: 0 !important;
    line-height: 42px;
    font-size: 0.9rem;
    box-sizing: border-box;
}

.carbon-manual-type-field select {
    min-width: 0;
    text-overflow: ellipsis;
}

.carbon-manual-type-select {
    padding-left: 0.85rem !important;
    padding-right: 2.35rem !important;
    background-position: right 0.85rem center !important;
    white-space: nowrap;
}

.carbon-manual-actions {
    grid-column: 1 / -1 !important;
}

.carbon-manual-not-field {
    grid-column: 1 / -1 !important;
}

@media (max-width: 900px) {
    .carbon-manual-item-form {
        grid-template-columns: repeat(2, minmax(0, 1fr)) !important;
    }

    .carbon-manual-type-field,
    .carbon-manual-not-field,
    .carbon-manual-actions {
        grid-column: 1 / -1 !important;
    }
}

@media (max-width: 560px) {
    .carbon-manual-item-form {
        grid-template-columns: 1fr !important;
    }
}

/* Mevzuat yönetimi: araçları günlük operasyon sırasına göre grupla. */
#saLegislation .legislation-admin-tabs {
    display: flex;
    gap: 0.45rem;
    flex-wrap: wrap;
    margin-top: 0.85rem;
    padding: 0.4rem;
    width: fit-content;
    max-width: 100%;
    border: 1px solid var(--border-color);
    border-radius: 12px;
    background: rgba(15, 23, 42, 0.18);
}

#saLegislation .legislation-admin-tab {
    min-height: 40px;
    border-radius: 8px;
    font-size: 0.82rem;
    white-space: nowrap;
}

#saLegislation .legislation-admin-tab.active {
    background: rgba(20, 184, 166, 0.13);
    box-shadow: inset 0 0 0 1px rgba(20, 184, 166, 0.24);
}

#saLegislation .legislation-control-intro {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 1rem;
    flex-wrap: wrap;
    margin: 0 0 1rem;
    padding: 1rem;
    border: 1px solid rgba(20, 184, 166, 0.25);
    border-radius: 10px;
    background: rgba(20, 184, 166, 0.07);
}

#saLegislation .legislation-control-intro h4 {
    margin: 0 0 0.35rem;
}

#saLegislation .legislation-control-intro p {
    max-width: 720px;
    margin: 0;
    color: var(--text-muted);
    font-size: 0.85rem;
    line-height: 1.5;
}

#saLegislation .legislation-control-actions {
    display: flex;
    gap: 0.5rem;
    flex-wrap: wrap;
}

#saLegislation [data-leg-workspace-action][hidden],
#saLegislation [data-leg-workspace][hidden] {
    display: none !important;
}

#saLegislation .legislation-row-actions {
    position: relative;
}

#saLegislation .legislation-row-actions summary {
    min-height: 28px;
    padding: 0.22rem 0.5rem;
    border: 1px solid var(--border-color);
    border-radius: 6px;
    color: var(--text-muted);
    cursor: pointer;
    font-size: 0.72rem;
    list-style: none;
}

#saLegislation .legislation-row-actions summary::-webkit-details-marker {
    display: none;
}

#saLegislation .legislation-row-actions summary::after {
    content: '⌄';
    margin-left: 0.35rem;
}

#saLegislation .legislation-row-actions[open] > div {
    position: absolute;
    z-index: 4;
    top: calc(100% + 0.25rem);
    right: 0;
    display: flex;
    gap: 0.35rem;
    flex-wrap: wrap;
    min-width: 180px;
    padding: 0.5rem;
    border: 1px solid var(--border-color);
    border-radius: 8px;
    background: var(--bg-surface, #fff);
    box-shadow: 0 10px 24px rgba(15, 23, 42, 0.18);
}

/* Bildirimler: satırların gerçek düğme olması klavye erişimini ve CSP uyumunu korur. */
.notification-item {
    display: flex;
    width: 100%;
    min-height: 72px;
    align-items: center;
    gap: 0.75rem;
    padding: 0.75rem 1rem;
    border: 0;
    border-bottom: 1px solid var(--border-color);
    background: transparent;
    color: inherit;
    cursor: pointer;
    font: inherit;
    text-align: left;
    transition: background-color 0.2s ease, opacity 0.2s ease;
}

.notification-item:hover,
.notification-item:focus-visible {
    background: var(--bg-hover);
}

.notification-item:disabled {
    cursor: wait;
    opacity: 0.6;
}

.notification-item-content {
    display: grid;
    flex: 1;
    gap: 0.25rem;
    min-width: 0;
}

.notification-item-title {
    font-size: 0.85rem;
}

.notification-item-message {
    overflow: hidden;
    color: var(--text-muted);
    font-size: 0.82rem;
    line-height: 1.35;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.notification-item-date,
.notification-item-icon {
    color: var(--text-muted);
    font-size: 0.72rem;
}

.notification-item-meta {
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.notification-item-category {
    display: inline-flex;
    width: fit-content;
    align-items: center;
    min-height: 20px;
    padding: 0 0.4rem;
    border-radius: 999px;
    background: color-mix(in srgb, var(--primary-neon) 12%, transparent);
    color: var(--text-muted);
    font-size: 0.68rem;
    font-weight: 700;
}

.notification-item-category-warning {
    background: color-mix(in srgb, var(--warning, #d97706) 15%, transparent);
    color: var(--warning, #a16207);
}

.notification-item-category-critical {
    background: color-mix(in srgb, var(--danger, #dc2626) 14%, transparent);
    color: var(--danger, #b91c1c);
}

.notification-item-icon {
    display: flex;
    opacity: 0.7;
}

.notification-item-managed {
    display: flex;
    align-items: stretch;
    gap: 0.45rem;
    border-bottom: 1px solid var(--border-color);
}

.notification-item-managed .notification-item {
    border-bottom: 0;
}

.notification-item-management-actions {
    display: flex;
    flex: 0 0 auto;
    align-items: center;
    gap: 0.35rem;
    padding: 0.5rem 0.75rem 0.5rem 0;
}

.notification-management-button {
    min-height: 34px;
    padding: 0.35rem 0.55rem;
    border: 1px solid var(--border-color);
    border-radius: 7px;
    background: transparent;
    color: var(--text-muted);
    cursor: pointer;
    font: inherit;
    font-size: 0.74rem;
}

.notification-management-button:hover,
.notification-management-button:focus-visible {
    border-color: var(--primary-neon);
    color: var(--primary-neon);
    outline: none;
}

.notification-management-button:disabled {
    cursor: wait;
    opacity: 0.6;
}

@media (max-width: 640px) {
    .notification-item-managed {
        align-items: flex-start;
    }

    .notification-item-management-actions {
        flex-direction: column;
        padding: 0.6rem 0.6rem 0.6rem 0;
    }
}

.notification-list-message {
    padding: 1rem;
    color: var(--text-muted);
    font-size: 0.8rem;
    text-align: center;
}

.notification-list-message-error {
    color: var(--danger, #ef4444);
}

.notification-retry-button {
    display: block;
    margin: 0 auto 1rem;
}

.dashboard-choice-option {
    display: flex;
    align-items: flex-start;
    gap: 0.65rem;
    margin: 0.5rem 0;
    padding: 0.75rem;
    border: 1px solid var(--border-color);
    border-radius: 8px;
    cursor: pointer;
}

.dashboard-choice-option:has(input:checked) {
    border-color: var(--primary-neon);
    background: color-mix(in srgb, var(--primary-neon) 10%, transparent);
}

.dashboard-choice-option input {
    margin-top: 0.2rem;
    accent-color: var(--primary-neon);
}

.dashboard-choice-option span {
    display: grid;
    gap: 0.2rem;
}

.dashboard-choice-option-description {
    color: var(--text-muted);
    font-size: 0.82rem;
    line-height: 1.35;
}

.form-error {
    margin-top: 0.75rem;
    padding: 0.65rem 0.75rem;
    border: 1px solid color-mix(in srgb, var(--danger, #dc2626) 32%, transparent);
    border-radius: 8px;
    background: color-mix(in srgb, var(--danger, #dc2626) 8%, transparent);
    color: var(--danger, #b91c1c);
    font-size: 0.82rem;
    line-height: 1.4;
}

.form-error[hidden] {
    display: none;
}

@media (max-width: 680px) {
    #saLegislation .legislation-admin-tabs {
        width: 100%;
        overflow-x: auto;
        flex-wrap: nowrap;
    }

    #saLegislation .legislation-control-actions {
        width: 100%;
    }

    #saLegislation .legislation-control-actions button {
        flex: 1 1 190px;
        min-height: 44px;
    }
}

/* Superadmin Redesign Component Styles */
.sa-quick-actions {
    display: flex;
    gap: 0.75rem;
    flex-wrap: wrap;
    align-items: center;
    margin-top: 1rem;
    padding: 0.85rem 1.25rem;
    border: 1px solid var(--border-color);
    border-radius: 12px;
    background: var(--bg-surface);
    box-shadow: var(--shadow-card);
}

.sa-quick-action-btn {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.5rem 1rem;
    border: 1px solid var(--border-color);
    border-radius: 8px;
    background: #ffffff;
    color: var(--text-dark);
    font: inherit;
    font-size: 0.85rem;
    font-weight: 600;
    cursor: pointer;
    transition: var(--transition-smooth);
}

.sa-quick-action-btn:hover,
.sa-quick-action-btn:focus-visible {
    border-color: var(--primary-neon);
    background: rgba(16, 185, 129, 0.08);
    color: var(--primary);
    box-shadow: 0 4px 12px rgba(16, 185, 129, 0.12);
}

.sa-kpi-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
    gap: 1.25rem;
    margin-bottom: 1.5rem;
}

.kpi-trend-badge {
    display: inline-flex;
    align-items: center;
    gap: 0.25rem;
    padding: 0.2rem 0.55rem;
    border-radius: 999px;
    background: rgba(16, 185, 129, 0.12);
    color: #059669;
    font-size: 0.75rem;
    font-weight: 700;
}

.sa-usage-container {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 1.25rem;
    margin-bottom: 1.5rem;
}

@media (max-width: 768px) {
    .sa-usage-container {
        grid-template-columns: 1fr;
    }
}

.sa-usage-card {
    padding: 1.25rem;
    border: 1px solid var(--border-color);
    border-radius: 14px;
    background: var(--bg-surface);
    box-shadow: var(--shadow-card);
}

.sa-usage-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 0.75rem;
}

.sa-usage-title {
    font-size: 0.9rem;
    font-weight: 700;
    color: var(--text-dark);
}

.sa-usage-num {
    font-size: 1.25rem;
    font-weight: 800;
    color: var(--primary);
}

.sa-usage-bar-track {
    width: 100%;
    height: 8px;
    border-radius: 999px;
    background: rgba(226, 232, 240, 0.8);
    overflow: hidden;
}

.sa-usage-bar-fill {
    height: 100%;
    border-radius: 999px;
    background: linear-gradient(90deg, var(--primary), var(--primary-neon));
    transition: width 0.6s ease;
}

/* Modal Tab Navigation Styles */
.modal-tab-nav {
    display: flex;
    gap: 0.5rem;
    padding: 0.35rem;
    border: 1px solid var(--border-color);
    border-radius: 12px;
    background: rgba(248, 250, 252, 0.9);
    margin-top: 1rem;
    margin-bottom: 1.25rem;
}

.modal-tab-btn {
    display: inline-flex;
    align-items: center;
    gap: 0.45rem;
    padding: 0.5rem 0.9rem;
    border: 0;
    border-radius: 8px;
    background: transparent;
    color: var(--text-muted);
    font: inherit;
    font-size: 0.83rem;
    font-weight: 600;
    cursor: pointer;
    transition: var(--transition-smooth);
}

.modal-tab-btn:hover {
    color: var(--text-dark);
    background: rgba(226, 232, 240, 0.6);
}

.modal-tab-btn.active {
    background: #ffffff;
    color: var(--primary);
    box-shadow: 0 2px 8px rgba(15, 23, 42, 0.08);
}

/* Superadmin Facilities Table & Grid Styles */
.sa-facilities-table {
    width: 100%;
    border-collapse: separate;
    border-spacing: 0;
    font-size: 0.88rem;
}

.sa-facilities-table th {
    padding: 0.9rem 1.1rem;
    border-bottom: 2px solid var(--border-color);
    background: rgba(248, 250, 252, 0.9);
    color: var(--text-dark);
    font-family: var(--font-heading);
    font-weight: 700;
    font-size: 0.82rem;
    text-align: left;
    white-space: nowrap;
}

.sa-facilities-table td {
    padding: 1rem 1.1rem;
    border-bottom: 1px solid var(--border-color);
    color: var(--text-main);
    vertical-align: middle;
}

.sa-facilities-table tr:hover td {
    background: rgba(16, 185, 129, 0.03);
}

.sa-facility-name-cell {
    min-width: 240px;
}

.sa-facility-firm-cell {
    min-width: 180px;
}

.sa-facility-user-cell {
    min-width: 150px;
}

.sa-facility-status-cell {
    min-width: 100px;
}

.sa-facility-actions-cell {
    min-width: 120px;
    text-align: right;
}

/* Facilities Grid Layout */
.sa-facilities-grid-container {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
    gap: 1.25rem;
    padding: 0.5rem 0;
}

.sa-facility-card {
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    padding: 1.25rem;
    border: 1px solid var(--border-color);
    border-radius: 14px;
    background: var(--bg-surface);
    box-shadow: var(--shadow-card);
    transition: var(--transition-smooth);
}

.sa-facility-card:hover {
    border-color: var(--border-hover);
    box-shadow: var(--shadow-neon);
    transform: translateY(-2px);
}



