:root {
    --sidebar-width: 250px;
    --header-height: 50px;
    --navbar-height: 56px;
}
[data-bs-theme="dark"] {
    --bs-body-bg: #1a1d20;
    --bs-body-color: #e1e4e8;
    --bs-card-bg: #24292e;
    --bs-border-color: #3a3f44;
    --btn-default: #1d4ed8;
    --btn-secondary: #334155;
    --btn-tertiary: #1e293b;
    --btn-success: #15803d;
    --btn-danger: #b91c1c;
    --btn-warning: #ffc107;
    --btn-light-dark: #f8fafc;
    --toast-success: #15803d;
    --toast-danger: #b91c1c;
    --toast-warning: #ffc107;
    --toast-brand: #1d4ed8;
}
[data-bs-theme="light"] {
    --bs-body-bg: #f5f7f9;
    --bs-body-color: #24292e;
    --bs-card-bg: #ffffff;
    --bs-border-color: #dee2e6;
    --btn-default: #3b82f6;
    --btn-secondary: #e2e8f0;
    --btn-tertiary: #f8fafc;
    --btn-success: #22c55e;
    --btn-danger: #ef4444;
    --btn-warning: #ffc107;
    --btn-light-dark: #1e293b;
    --toast-success: #22c55e;
    --toast-danger: #ef4444;
    --toast-warning: #ffc107;
    --toast-brand: #3b82f6;
}
body {
    font-size: 14px;
    padding-top: var(--header-height);
}
.header {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    height: var(--header-height);
    background-color: var(--bs-body-bg);
    border-bottom: 1px solid var(--bs-border-color);
    display: flex;
    justify-content: flex-end;
    align-items: center;
    padding: 0 2rem;
    z-index: 1040;
}
body.authenticated .header {
    left: var(--sidebar-width);
}
.header a {
    color: var(--bs-body-color);
    text-decoration: none;
    transition: color 0.2s;
}
.header a:hover {
    color: var(--bs-primary);
}
.navbar-logo {
    height: 35px;
    transition: opacity 0.2s;
}
.navbar-logo:hover {
    opacity: 0.8;
}
.sidebar {
    position: fixed;
    top: 0;
    bottom: 0;
    left: 0;
    width: var(--sidebar-width);
    padding: 0;
    overflow-y: auto;
    background-color: var(--bs-card-bg);
    border-right: 1px solid var(--bs-border-color);
    z-index: 1050;
    transition: transform 0.3s ease-in-out;
}
.mobile-menu-toggle {
    display: none;
    background: none;
    border: none;
    font-size: 1.5rem;
    color: var(--bs-body-color);
    cursor: pointer;
    padding: 0.25rem;
}
.sidebar-overlay {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background-color: rgba(0, 0, 0, 0.5);
    z-index: 1040;
}
.sidebar-overlay.show {
    display: block;
}
@media (max-width: 991.98px) {
    .mobile-menu-toggle {
        display: block;
    }
    .sidebar {
        transform: translateX(-100%);
    }
    .sidebar.show {
        transform: translateX(0);
    }
    .header {
        left: 0 !important;
    }
    main {
        margin-left: 0 !important;
        padding: 1rem;
    }
    footer {
        margin-left: 0 !important;
        padding: 1rem;
        flex-direction: column;
        gap: 0.5rem;
        text-align: center;
    }
    footer .text-end {
        text-align: center !important;
    }
    .form-group, .mb-3 {
        flex-direction: column;
    }
    .form-group label, .mb-3 label {
        width: 100%;
        text-align: left;
        padding-right: 0;
        padding-bottom: 0.25rem;
    }
    .form-group .form-text,
    .mb-3 .form-text {
        margin-left: 0;
    }
    .detail-row {
        flex-direction: column;
    }
    .detail-label {
        width: 100%;
        margin-bottom: 0.25rem;
    }
    .d-mobile-none {
        display: none !important;
    }
}
@media (max-width: 575.98px) {
    .header {
        padding: 0.75rem 1rem;
    }
    main {
        padding: 0.75rem;
    }
    .btn-group {
        flex-direction: column;
        width: 100%;
    }
    .btn-group .btn {
        width: 100%;
        margin: 0.125rem 0;
    }
}
.sidebar-logo {
    display: flex;
    justify-content: center;
    align-items: center;
    padding: 1.5rem 1rem;
    width: 100%;
}
.sidebar-logo a {
    display: flex;
    justify-content: center;
}
.sidebar-logo img {
    height: 50px;
    max-width: 90%;
}
.nav-section {
    margin-bottom: 0.5rem;
}
.nav-section-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 0.5rem 1rem;
    cursor: pointer;
    font-size: 0.75rem;
    font-weight: 600;
    text-transform: uppercase;
    color: var(--bs-secondary);
    transition: background-color 0.2s;
}
.nav-section-header:hover {
    background-color: rgba(var(--bs-primary-rgb), 0.05);
}
.nav-section-header i {
    transition: transform 0.2s;
}
.nav-section-header.collapsed i {
    transform: rotate(-90deg);
}
.nav-section-content {
    overflow: hidden;
    transition: max-height 0.3s ease;
}
.sidebar .nav-link {
    color: var(--bs-body-color);
    padding: 0.5rem 1rem 0.5rem 2rem;
    border-radius: 0;
    display: flex;
    align-items: center;
    text-decoration: none;
    transition: all 0.2s;
}
.sidebar .nav-link i {
    min-width: 24px;
    font-size: 1.1rem;
    margin-right: 0.5rem;
}
.sidebar .nav-link:hover {
    background-color: rgba(var(--bs-primary-rgb), 0.1);
}
.sidebar .nav-link.active {
    background-color: var(--bs-primary);
    color: white;
}
main {
    margin-left: var(--sidebar-width);
    padding: 2rem;
    min-height: calc(100vh - var(--header-height) - 60px);
}
.breadcrumb {
    background-color: transparent;
    padding: 0;
    margin-bottom: 1rem;
    font-size: 0.9rem;
    display: flex;
    align-items: center;
}
.breadcrumb-item {
    display: flex;
    align-items: center;
}
.breadcrumb-item + .breadcrumb-item::before {
    content: ">";
    font-size: 1.2rem;
    display: flex;
    align-items: center;
}
.card {
    background-color: var(--bs-card-bg);
    border: 1px solid var(--bs-border-color);
    box-shadow: 0 2px 4px rgba(0,0,0,0.1);
}
.theme-toggle {
    cursor: pointer;
}
.toast-container {
    position: fixed;
    bottom: 20px;
    right: 20px;
    z-index: 1055;
    display: flex;
    flex-direction: column-reverse;
    gap: 0.75rem;
}
.toast {
    min-width: 350px;
    max-width: 400px;
    border-radius: 0.5rem;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
    overflow: hidden;
}
.toast-body {
    word-wrap: break-word;
    white-space: normal;
}
.toast-solid {
    display: flex;
    align-items: center;
    padding: 1rem;
    color: white;
}
.toast-solid .toast-icon {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
    width: 1.75rem;
    height: 1.75rem;
    background: rgba(255, 255, 255, 0.2);
    border-radius: 0.375rem;
}
.toast-solid .toast-icon i {
    font-size: 1.1rem;
}
.toast-solid .toast-message {
    margin-left: 0.75rem;
    font-size: 0.875rem;
    flex-grow: 1;
}
.toast-solid .toast-close {
    margin-left: auto;
    display: flex;
    align-items: center;
    justify-content: center;
    width: 2rem;
    height: 2rem;
    background: transparent;
    border: none;
    color: rgba(255, 255, 255, 0.8);
    border-radius: 0.375rem;
    cursor: pointer;
    transition: all 0.15s ease;
}
.toast-solid .toast-close:hover {
    background: rgba(255, 255, 255, 0.2);
    color: white;
}
.toast-success { background-color: var(--toast-success) !important; }
.toast-danger { background-color: var(--toast-danger) !important; }
.toast-warning { background-color: var(--toast-warning) !important; }
.toast-info { background-color: var(--toast-brand) !important; }
.action-split-btn {
    display: inline-flex;
    box-shadow: 0 1px 2px rgba(0, 0, 0, 0.05);
}
.action-split-btn .btn-action-main {
    display: inline-flex;
    align-items: center;
    gap: 0.375rem;
    padding: 0.375rem 0.75rem;
    font-size: 0.8125rem;
    font-weight: 500;
    color: white;
    background-color: var(--btn-default);
    border: 1px solid var(--btn-default);
    border-right: 1px solid rgba(255, 255, 255, 0.2);
    border-radius: 0.375rem 0 0 0.375rem;
    text-decoration: none;
}
.action-split-btn .btn-action-main:hover {
    color: white;
    filter: brightness(1.1);
}
.action-split-btn .btn-action-dropdown {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 2rem;
    padding: 0.375rem;
    color: white;
    background-color: var(--btn-default);
    border: 1px solid var(--btn-default);
    border-left: none;
    border-radius: 0 0.375rem 0.375rem 0;
    cursor: pointer;
}
.action-split-btn .btn-action-dropdown:hover {
    filter: brightness(1.1);
}
.action-dropdown-menu {
    min-width: 140px;
    padding: 0.5rem;
    background: var(--bs-body-bg);
    border: 1px solid var(--bs-border-color);
    border-radius: 0.375rem;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
}
.action-dropdown-menu .dropdown-item {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.5rem 0.75rem;
    font-size: 0.875rem;
    border-radius: 0.25rem;
    border: none;
    background: transparent;
    width: 100%;
    text-align: left;
    cursor: pointer;
}
.action-dropdown-menu .dropdown-item:hover {
    background: var(--bs-tertiary-bg);
}
.action-dropdown-menu .dropdown-item.text-danger:hover {
    background: rgba(220, 53, 69, 0.1);
}
.action-single-btn {
    display: inline-flex;
    align-items: center;
    gap: 0.375rem;
    padding: 0.375rem 0.75rem;
    font-size: 0.8125rem;
    font-weight: 500;
    color: white;
    background-color: var(--btn-danger);
    border: 1px solid var(--btn-danger);
    border-radius: 0.375rem;
    cursor: pointer;
}
.action-single-btn:hover {
    filter: brightness(1.1);
}
.detail-row {
    display: flex;
    border-bottom: 1px solid var(--bs-border-color);
    padding: 0.75rem 0;
}
.detail-row:last-child {
    border-bottom: none;
}
.detail-label {
    font-weight: 600;
    width: 200px;
    flex-shrink: 0;
}
.detail-value {
    flex: 1;
}
.form-container {
    max-width: 800px;
    margin: 2rem auto;
}
.form-container .card {
    box-shadow: 0 4px 6px rgba(0,0,0,0.1);
}
.form-group {
    margin-bottom: 1.5rem;
}
.form-control, .form-select {
    background-color: var(--bs-card-bg);
    border: 1px solid var(--bs-border-color);
    color: var(--bs-body-color);
    padding: 0.5rem 0.75rem;
    font-size: 0.875rem;
    border-radius: 0.25rem;
    transition: all 0.15s ease-in-out;
}
.form-control:focus, .form-select:focus {
    background-color: var(--bs-card-bg);
    border-color: var(--bs-border-color);
    color: var(--bs-body-color);
    box-shadow: 0 0 0 0.15rem rgba(255, 255, 255, 0.1);
    outline: none;
}
[data-bs-theme="light"] .form-control:focus,
[data-bs-theme="light"] .form-select:focus {
    box-shadow: 0 0 0 0.15rem rgba(0, 0, 0, 0.1);
}
.form-control:hover:not(:focus), .form-select:hover:not(:focus) {
    border-color: var(--bs-border-color);
}
.form-label {
    font-weight: 400;
    margin-bottom: 0;
    color: var(--bs-body-color);
    font-size: 0.875rem;
    text-align: right;
    padding-right: 1rem;
}
.form-group label.required::after,
.mb-3 label.required::after,
label.required::after,
form p label:has(+ input:required)::after,
form p label:has(+ select:required)::after,
form p label:has(+ textarea:required)::after {
    content: " *";
    color: #dc3545;
    font-weight: bold;
}
[data-bs-theme="dark"] .form-select {
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='16' height='16' fill='%23e1e4e8' viewBox='0 0 16 16'%3E%3Cpath fill-rule='evenodd' d='M1.646 4.646a.5.5 0 0 1 .708 0L8 10.293l5.646-5.647a.5.5 0 0 1 .708.708l-6 6a.5.5 0 0 1-.708 0l-6-6a.5.5 0 0 1 0-.708z'/%3E%3C/svg%3E") !important;
}
[data-bs-theme="light"] .form-select {
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='16' height='16' fill='%23212529' viewBox='0 0 16 16'%3E%3Cpath fill-rule='evenodd' d='M1.646 4.646a.5.5 0 0 1 .708 0L8 10.293l5.646-5.647a.5.5 0 0 1 .708.708l-6 6a.5.5 0 0 1-.708 0l-6-6a.5.5 0 0 1 0-.708z'/%3E%3C/svg%3E") !important;
}
.form-select {
    background-repeat: no-repeat !important;
    background-position: right 0.75rem center !important;
    background-size: 16px 12px !important;
    padding-right: 2.5rem !important;
}
.form-group, .mb-3 {
    display: flex;
    align-items: start;
    margin-bottom: 1rem;
}
.form-group label, .mb-3 label {
    width: 200px;
    flex-shrink: 0;
    padding-top: 0.5rem;
}
.form-group .form-control,
.form-group .form-select,
.mb-3 .form-control,
.mb-3 .form-select {
    flex: 1;
}
.form-group .form-text,
.mb-3 .form-text {
    flex: 1;
    margin-left: 200px;
    margin-top: 0.25rem;
}
.form-select:not([multiple]) {
    padding-right: 2.5rem;
    background-position: right 0.75rem center;
    background-size: 16px 12px;
    appearance: none;
    background-image: url("data:svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 16 16'%3e%3cpath fill='none' stroke='%23dee2e6' stroke-linecap='round' stroke-linejoin='round' stroke-width='2' d='M2 5l6 6 6-6'/%3e%3c/svg%3e");
}
.form-select[multiple] {
    border-radius: 0.375rem;
    padding: 0.5rem;
    min-height: 300px;
    background-color: var(--bs-card-bg);
    border: 1px solid var(--bs-border-color);
}
.form-select[multiple] option {
    padding: 0.5rem 0.75rem;
    margin: 0.2rem 0.3rem;
    border-radius: 0.25rem;
    border: 1px solid var(--bs-border-color);
    background-color: var(--bs-card-bg);
    color: var(--bs-body-color);
    cursor: pointer;
}
.form-select[multiple] option:hover {
    background-color: rgba(var(--bs-primary-rgb), 0.1);
    border-color: var(--bs-primary);
}
.form-select[multiple] option:checked {
    background: linear-gradient(135deg, #0d6efd 0%, #0a58ca 100%);
    color: white;
    border-color: #0d6efd;
    font-weight: 500;
}
.form-select[multiple] option:checked::before {
    content: "\2713 ";
    margin-right: 0.5rem;
}
.form-text {
    font-size: 0.875rem;
    color: #6c757d;
    margin-top: 0.25rem;
}
textarea.form-control {
    min-height: 100px;
}
.form-container .card-body p {
    margin-bottom: 1.5rem;
}
.form-container .card-body p:last-child {
    margin-bottom: 0;
}
.table-container {
    background: var(--bs-card-bg);
    border: 1px solid var(--bs-border-color);
    border-radius: 0.5rem;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.1);
    overflow: visible;
}
.table-container .table {
    margin-bottom: 0;
}
.table-container .table-responsive {
    overflow-x: auto;
}
.table {
    background-color: transparent;
    border-collapse: separate;
    border-spacing: 0;
    font-size: 0.875rem;
}
.table thead th,
.table thead th.asc,
.table thead th.desc,
.table thead th.orderable,
.table thead th.sorted,
.table thead th[class*="success"],
.table thead th[class*="table-"] {
    background-color: var(--bs-tertiary-bg) !important;
    background: var(--bs-tertiary-bg) !important;
    border-bottom: 1px solid var(--bs-border-color);
    border-top: none;
    font-weight: 600;
    font-size: 0.8125rem;
    padding: 0.875rem 1rem;
    color: var(--bs-body-color) !important;
}
.table thead th a,
.table thead th a:hover,
.table thead th a:focus,
.table thead th a:active {
    color: var(--bs-body-color) !important;
    text-decoration: none;
    background: transparent !important;
}
.table tbody tr {
    background-color: var(--bs-card-bg);
    transition: background-color 0.15s;
}
.table tbody td {
    padding: 0.875rem 1rem;
    border-bottom: 1px solid var(--bs-border-color);
    vertical-align: middle;
}
.table tbody tr:last-child td {
    border-bottom: none;
}
.table tbody tr:hover {
    background-color: var(--bs-tertiary-bg);
}
.table a {
    color: var(--bs-body-color);
    text-decoration: none;
    transition: opacity 0.15s;
}
.table a:hover {
    opacity: 0.7;
    text-decoration: none;
}
.table-footer {
    display: flex;
    align-items: center;
    justify-content: space-between;
    flex-wrap: wrap;
    gap: 1rem;
    padding: 0.75rem 1rem;
    background: var(--bs-card-bg);
    border-top: 1px solid var(--bs-border-color);
    font-size: 0.875rem;
}
.table-footer .table-info {
    color: var(--bs-secondary-color);
}
.table-footer .table-info strong {
    color: var(--bs-body-color);
}
.page-size-selector {
    display: flex;
    align-items: center;
    gap: 0.5rem;
}
.page-size-selector label {
    color: var(--bs-secondary-color);
    font-size: 0.875rem;
    margin: 0;
}
.page-size-selector select {
    background-color: var(--bs-tertiary-bg);
    border: 1px solid var(--bs-border-color);
    color: var(--bs-body-color);
    font-size: 0.875rem;
    padding: 0.375rem 0.75rem;
    border-radius: 0.375rem;
    cursor: pointer;
    min-width: 70px;
}
.page-size-selector select:focus {
    outline: none;
    border-color: var(--btn-primary);
}
.btn {
    padding: 0.5rem 1rem;
    font-size: 0.875rem;
    border-radius: 0.25rem;
    font-weight: 500;
    transition: all 0.15s ease-in-out;
    border: none;
}
.btn-primary { background-color: var(--btn-default); border-color: var(--btn-default); }
.btn-secondary { background-color: var(--btn-secondary); border-color: var(--btn-secondary); }
.btn-success { background-color: var(--btn-success); border-color: var(--btn-success); }
.btn-danger { background-color: var(--btn-danger); border-color: var(--btn-danger); }
.btn-warning { background-color: var(--btn-warning); border-color: var(--btn-warning); }
.btn-primary, .btn-success,
button[type="submit"]:not(.btn-danger):not(.btn-warning):not(.btn-secondary),
a[href*="create"]:not(.btn-danger):not(.btn-warning):not(.btn-secondary) {
    background-color: var(--btn-success);
    color: white;
}
.btn-primary:hover, .btn-success:hover,
button[type="submit"]:not(.btn-danger):not(.btn-warning):not(.btn-secondary):hover {
    filter: brightness(0.9);
}
.btn-warning,
a[href*="edit"].btn,
a[href*="update"].btn {
    background-color: var(--btn-warning);
    color: #000;
}
.btn-warning:hover,
a[href*="edit"].btn:hover,
a[href*="update"].btn:hover {
    filter: brightness(0.9);
}
.btn-danger,
a[href*="delete"].btn {
    background-color: var(--btn-danger);
    color: white;
}
.btn-danger:hover,
a[href*="delete"].btn:hover {
    filter: brightness(0.9);
}
.btn-secondary, .btn-outline-secondary {
    background-color: var(--btn-secondary);
    color: white;
    border: 1px solid var(--btn-secondary);
}
.btn-secondary:hover, .btn-outline-secondary:hover {
    filter: brightness(0.9);
}
.btn-outline-secondary {
    background-color: transparent;
    color: var(--bs-body-color);
}
.btn-outline-secondary:hover {
    background-color: #6c757d;
    color: white;
}
.table .btn {
    padding: 0.25rem 0.75rem;
    font-size: 0.8rem;
}
.table .btn-group .btn {
    margin: 0 0.125rem;
}
.badge {
    padding: 0.35rem 0.65rem;
    font-size: 0.75rem;
    font-weight: 600;
    border-radius: 0.25rem;
}
.badge-success {
    background-color: #28a745;
    color: white;
}
.badge-warning {
    background-color: #ffc107;
    color: #000;
}
.badge-danger {
    background-color: #dc3545;
    color: white;
}
.badge-info {
    background-color: #17a2b8;
    color: white;
}
.status-icon {
    font-size: 1.2rem;
    color: #28a745;
}
.status-icon.active {
    color: #28a745;
}
.status-icon.inactive {
    color: #6c757d;
}
code {
    background-color: var(--bs-card-bg);
    color: #e83e8c;
    padding: 0.2rem 0.4rem;
    border-radius: 0.25rem;
    font-size: 0.875rem;
}
.pagination {
    margin: 0;
    gap: 0;
}
.pagination .page-link {
    background-color: var(--bs-tertiary-bg);
    border: 1px solid var(--bs-border-color);
    color: var(--bs-body-color);
    padding: 0.375rem 0.75rem;
    font-size: 0.875rem;
    line-height: 1.5;
    min-width: 2.25rem;
    text-align: center;
    transition: all 0.15s;
}
.pagination .page-link:hover {
    background-color: var(--bs-secondary-bg);
    border-color: var(--bs-border-color);
    color: var(--bs-body-color);
}
.pagination .page-item:first-child .page-link {
    border-radius: 0.375rem 0 0 0.375rem;
}
.pagination .page-item:last-child .page-link {
    border-radius: 0 0.375rem 0.375rem 0;
}
.pagination .page-item.active .page-link {
    background-color: var(--btn-primary);
    border-color: var(--btn-primary);
    color: white;
}
.pagination .page-item.disabled .page-link {
    background-color: var(--bs-tertiary-bg);
    border-color: var(--bs-border-color);
    color: var(--bs-secondary-color);
    opacity: 0.5;
}
footer {
    background-color: transparent;
    border-top: 1px solid var(--bs-border-color);
    padding: 1rem 2rem;
    margin-left: var(--sidebar-width);
    display: flex;
    justify-content: space-between;
    align-items: center;
}
footer a {
    color: var(--bs-body-color);
    text-decoration: none;
}
footer a:hover {
    color: var(--bs-primary);
}
.header-breadcrumb {
    overflow: hidden;
}
.header-breadcrumb .breadcrumb {
    margin-bottom: 0;
    background-color: transparent;
    padding: 0;
    flex-wrap: nowrap;
    overflow: hidden;
}
.header-breadcrumb .breadcrumb-item {
    font-size: 0.875rem;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}
@media (max-width: 767.98px) {
    .header-breadcrumb {
        display: none;
    }
}
.breadcrumb {
    margin-bottom: 0;
    background-color: transparent;
    padding: 0;
}
.breadcrumb-item {
    font-size: 0.9rem;
}
.breadcrumb-item a {
    color: var(--bs-body-color);
    text-decoration: none;
}
.breadcrumb-item a:hover {
    color: var(--bs-primary);
}
.breadcrumb-item.active {
    color: var(--bs-primary);
    font-weight: 500;
}
.port-badge {
    display: inline-block;
    padding: 0.25rem 0.75rem;
    border-radius: 0.25rem;
    font-size: 0.875rem;
    font-weight: 500;
    margin: 0.25rem;
}
.port-open {
    background-color: var(--btn-success);
    color: white;
}
.port-filtered {
    background-color: var(--btn-warning);
    color: #000;
}
.port-closed {
    background-color: var(--btn-danger);
    color: white;
}
.code-block {
    padding: 1rem;
    border-radius: 0.25rem;
    font-family: 'Courier New', monospace;
}
[data-bs-theme="dark"] .code-block {
    background-color: #0d1117 !important;
    color: #c9d1d9 !important;
}
[data-bs-theme="dark"] .code-block code {
    color: #c9d1d9 !important;
    background-color: transparent !important;
}
[data-bs-theme="light"] .code-block {
    background-color: #f8f9fa !important;
    color: #212529 !important;
    border: 1px solid var(--bs-border-color);
}
[data-bs-theme="light"] .code-block code {
    color: #212529 !important;
    background-color: transparent !important;
}
.choices {
    margin-bottom: 0;
    font-size: 0.875rem;
    width: 100%;
}
.choices__inner {
    background-color: var(--bs-card-bg);
    border: 1px solid var(--bs-border-color);
    border-radius: 0.25rem;
    padding: 0.375rem 0.5rem;
    min-height: 38px;
    font-size: 0.875rem;
    width: 100%;
}
.choices__inner:focus {
    border-color: var(--bs-border-color);
    box-shadow: 0 0 0 0.15rem rgba(255, 255, 255, 0.1);
}
[data-bs-theme="light"] .choices__inner:focus {
    box-shadow: 0 0 0 0.15rem rgba(0, 0, 0, 0.1);
}
.choices__list--multiple .choices__item {
    background-color: #2d333b;
    border: 1px solid #444c56;
    color: #f0f6fc;
    border-radius: 0.25rem;
    padding: 0.35rem 0.6rem;
    margin: 0.125rem;
    font-size: 0.875rem;
    display: inline-flex;
    align-items: center;
    font-weight: 500;
}
[data-bs-theme="light"] .choices__list--multiple .choices__item {
    background-color: #f6f8fa;
    border: 1px solid #d0d7de;
    color: #24292f;
}
.choices__list--multiple .choices__item.is-highlighted {
    background-color: #0d6efd;
    border-color: #0d6efd;
    color: white;
}
.choices__button {
    border-left: 1px solid #444c56;
    margin-left: 0.5rem;
    padding: 0 !important;
    opacity: 1;
    background: none !important;
    border-top: none;
    border-bottom: none;
    border-right: none;
    width: 20px;
    height: 20px;
    position: relative;
    display: inline-flex;
    align-items: center;
    justify-content: center;
}
.choices__button {
    font-size: 0 !important;
    line-height: 0 !important;
    color: transparent !important;
    text-indent: -9999px;
}
.choices__button > * {
    display: none !important;
    visibility: hidden !important;
}
.choices__button::before {
    content: "\00d7" !important;
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    font-size: 18px !important;
    line-height: 1 !important;
    font-weight: 400 !important;
    display: block !important;
    visibility: visible !important;
    text-indent: 0;
    z-index: 100;
}
[data-bs-theme="dark"] .choices__button {
    border-left-color: #444c56;
}
[data-bs-theme="dark"] .choices__button::before {
    color: #e1e4e8 !important;
}
[data-bs-theme="light"] .choices__button {
    border-left-color: #d0d7de;
}
[data-bs-theme="light"] .choices__button::before {
    color: #24292f !important;
}
.choices__button:hover::before {
    color: #dc3545 !important;
}
.choices__list--dropdown {
    background-color: var(--bs-card-bg) !important;
    border: 1px solid var(--bs-border-color) !important;
    border-radius: 0.25rem;
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.3);
    z-index: 1060;
}
.choices__list--dropdown .choices__item {
    padding: 0.5rem 0.75rem;
    color: var(--bs-body-color) !important;
    font-size: 0.875rem;
    background-color: var(--bs-card-bg) !important;
}
.choices__list--dropdown .choices__item--selectable {
    background-color: var(--bs-card-bg) !important;
    color: var(--bs-body-color) !important;
}
.choices__list--dropdown .choices__item--selectable.is-highlighted {
    background-color: rgba(13, 110, 253, 0.15) !important;
    color: var(--bs-body-color) !important;
}
[data-bs-theme="dark"] .choices__list--dropdown {
    background-color: #24292e !important;
}
[data-bs-theme="dark"] .choices__list--dropdown .choices__item {
    background-color: #24292e !important;
    color: #e1e4e8 !important;
}
[data-bs-theme="dark"] .choices__list--dropdown .choices__item--selectable {
    background-color: #24292e !important;
}
[data-bs-theme="light"] .choices__list--dropdown {
    background-color: #ffffff !important;
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
}
[data-bs-theme="light"] .choices__list--dropdown .choices__item {
    background-color: #ffffff !important;
    color: #24292e !important;
}
[data-bs-theme="light"] .choices__list--dropdown .choices__item--selectable.is-highlighted {
    background-color: rgba(13, 110, 253, 0.1) !important;
}
.choices[data-type*="select-multiple"] .choices__list--dropdown {
    background-color: var(--bs-card-bg) !important;
}
.choices[data-type*="select-multiple"][aria-expanded="true"] .choices__list--dropdown {
    background-color: var(--bs-card-bg) !important;
}
.choices__input {
    background-color: transparent;
    color: var(--bs-body-color);
    font-size: 0.875rem;
    padding: 0.25rem 0;
}
.choices__input::placeholder {
    color: #8b949e;
    opacity: 1;
}
.choices__placeholder {
    color: #8b949e;
    opacity: 1;
}
[data-bs-theme="light"] .choices__input::placeholder {
    color: #57606a;
}
[data-bs-theme="light"] .choices__placeholder {
    color: #57606a;
}
[data-bs-theme="dark"] .choices__list--dropdown .choices__input {
    background-color: #24292e !important;
    color: #e1e4e8 !important;
    border-color: #444c56 !important;
}
[data-bs-theme="dark"] .choices__input {
    background-color: transparent !important;
    color: #e1e4e8 !important;
}
.detail-card {
    background: var(--bs-card-bg);
    border: 1px solid var(--bs-border-color);
    border-radius: 0.5rem;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.1);
    overflow: hidden;
}
.detail-card-header {
    padding: 0.875rem 1rem;
    background: var(--bs-tertiary-bg);
    border-bottom: 1px solid var(--bs-border-color);
    font-weight: 600;
    font-size: 0.875rem;
}
.detail-card-body {
    padding: 0;
}
.detail-item {
    display: flex;
    padding: 0.875rem 1rem;
    border-bottom: 1px solid var(--bs-border-color);
    font-size: 0.875rem;
    transition: background-color 0.15s;
}
.detail-item:last-child {
    border-bottom: none;
}
.detail-item:hover {
    background: var(--bs-tertiary-bg);
}
.detail-item-label {
    width: 180px;
    flex-shrink: 0;
    font-weight: 500;
    color: var(--bs-secondary-color);
}
.detail-item-value {
    flex: 1;
    color: var(--bs-body-color);
}
@media (max-width: 767.98px) {
    .detail-item {
        flex-direction: column;
        gap: 0.25rem;
    }
    .detail-item-label {
        width: 100%;
    }
}
.stat-card {
    background: var(--bs-card-bg);
    border: 1px solid var(--bs-border-color);
    border-radius: 0.5rem;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.1);
    padding: 1.25rem;
    text-align: center;
    transition: transform 0.15s, box-shadow 0.15s;
}
.stat-card:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
}
.stat-card-icon {
    font-size: 2.5rem;
    margin-bottom: 0.75rem;
    opacity: 0.9;
}
.stat-card-value {
    font-size: 1.75rem;
    font-weight: 600;
    margin-bottom: 0.25rem;
    color: var(--bs-body-color);
}
.stat-card-label {
    font-size: 0.8125rem;
    color: var(--bs-secondary-color);
    margin: 0;
}
.stat-card.stat-success .stat-card-icon { color: var(--btn-success); }
.stat-card.stat-danger .stat-card-icon { color: var(--btn-danger); }
.stat-card.stat-warning .stat-card-icon { color: var(--btn-warning); }
.stat-card.stat-primary .stat-card-icon { color: var(--btn-default); }
.stat-card.stat-info .stat-card-icon { color: #17a2b8; }
.stat-card.stat-secondary .stat-card-icon { color: var(--bs-secondary-color); }
.form-card {
    background: var(--bs-card-bg);
    border: 1px solid var(--bs-border-color);
    border-radius: 0.5rem;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.1);
    overflow: visible;
}
.form-card-header {
    padding: 1rem 1.25rem;
    border-bottom: 1px solid var(--bs-border-color);
    background: var(--bs-tertiary-bg);
    font-weight: 600;
    font-size: 0.9375rem;
}
.form-card-body {
    padding: 1.5rem;
}
.form-card-body .form-group,
.form-card-body .mb-3 {
    display: block;
}
.form-card-body .form-group label,
.form-card-body .mb-3 label {
    width: auto;
    padding-top: 0;
}
.form-card-body .form-help,
.form-card-body .form-text,
.form-card-body small.text-muted {
    margin-left: 0;
    display: block;
    margin-top: 0.375rem;
}
.form-card-body .form-group:last-child {
    margin-bottom: 0;
}
.form-group {
    margin-bottom: 1.25rem;
}
.form-group > label {
    display: block;
    font-weight: 500;
    font-size: 0.875rem;
    margin-bottom: 0.5rem;
    color: var(--bs-body-color);
}
.form-group > label.required::after {
    content: " *";
    color: var(--btn-danger);
}
.form-help {
    font-size: 0.8125rem;
    color: var(--bs-secondary-color);
    margin-top: 0.375rem;
}
.form-actions {
    display: flex;
    gap: 0.75rem;
    padding-top: 1.5rem;
    margin-top: 0.5rem;
}
.form-check-modern {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.25rem 0;
}
.form-check-modern input[type="checkbox"],
.form-check-modern input[type="radio"] {
    width: 1.125rem;
    height: 1.125rem;
    margin: 0;
    cursor: pointer;
}
.form-check-modern label {
    margin: 0;
    cursor: pointer;
    font-weight: 400;
}
.choices[data-type*="select-one"] .choices__inner {
    background: var(--bs-card-bg);
    border: 1px solid var(--bs-border-color);
    border-radius: 0.375rem;
    padding: 0.5rem 0.75rem;
    min-height: auto;
}
.choices[data-type*="select-one"] .choices__list--single {
    padding: 0;
}
.choices[data-type*="select-one"] .choices__item {
    font-size: 0.875rem;
}
.choices[data-type*="select-one"]::after {
    border-color: var(--bs-body-color) transparent transparent transparent;
}
.choices[data-type*="select-one"].is-open::after {
    border-color: transparent transparent var(--bs-body-color) transparent;
}
.filter-panel {
    position: relative;
    display: inline-block;
    margin-bottom: 1rem;
}
.filter-dropdown {
    position: absolute !important;
    top: 100%;
    left: 0;
    z-index: 1050;
    margin-top: 0.5rem;
    background: var(--bs-card-bg);
    border: 1px solid var(--bs-border-color);
    border-radius: 0.5rem;
    box-shadow: 0 0.5rem 1rem rgba(0, 0, 0, 0.15);
    padding: 1rem;
    min-width: 900px;
    max-width: 1100px;
    opacity: 0;
    transform: translateY(-10px);
    transition: opacity 0.2s ease, transform 0.2s ease;
    pointer-events: none;
}
.filter-dropdown.show {
    opacity: 1;
    transform: translateY(0);
    pointer-events: auto;
}
.filter-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
    gap: 1rem;
    margin-bottom: 1rem;
}
.filter-item label {
    display: block;
    font-weight: 500;
    font-size: 0.875rem;
    margin-bottom: 0.5rem;
    color: var(--bs-body-color);
    white-space: nowrap;
}
.filter-item input,
.filter-item select {
    width: 100%;
    background-color: var(--bs-card-bg);
    border: 1px solid var(--bs-border-color);
    color: var(--bs-body-color);
    padding: 0.5rem 0.75rem;
    font-size: 0.875rem;
    border-radius: 0.25rem;
    transition: all 0.15s ease-in-out;
}
.filter-item input:focus,
.filter-item select:focus {
    background-color: var(--bs-card-bg);
    border-color: var(--bs-border-color);
    color: var(--bs-body-color);
    box-shadow: 0 0 0 0.15rem rgba(255, 255, 255, 0.1);
    outline: none;
}
.filter-widget {
    display: flex;
    gap: 0.5rem;
    align-items: center;
    color: var(--bs-secondary-color);
    font-size: 0.875rem;
}
.filter-widget input {
    flex: 1;
    width: auto;
    min-width: 80px;
}
.filter-buttons {
    display: flex;
    gap: 0.5rem;
    justify-content: flex-end;
    padding-top: 1rem;
    border-top: 1px solid var(--bs-border-color);
}
@media (max-width: 991.98px) {
    .filter-dropdown {
        min-width: 100%;
        max-width: 100%;
        left: 0;
        right: 0;
        position: fixed !important;
        top: auto;
        bottom: 0;
        max-height: 70vh;
        overflow-y: auto;
        border-radius: 1rem 1rem 0 0;
        margin-top: 0;
    }
    .filter-grid {
        grid-template-columns: 1fr;
    }
    .btn {
        min-height: 44px;
        min-width: 44px;
    }
    .nav-link {
        min-height: 44px;
        padding: 0.75rem 1rem;
    }
    .dropdown-item {
        padding: 0.75rem 1rem;
    }
}
@media (max-width: 575.98px) {
    .toast-container {
        left: 1rem;
        right: 1rem;
    }
    .toast {
        min-width: auto;
        max-width: 100%;
        width: 100%;
    }
}
@media (max-width: 480px) {
    .sidebar {
        width: 85%;
        max-width: 280px;
    }
    .header {
        padding: 0.5rem 0.75rem;
    }
    main {
        padding: 0.5rem;
    }
    .btn {
        padding: 0.625rem 0.875rem;
        font-size: 0.8125rem;
    }
    .table {
        font-size: 0.75rem;
    }
    .table thead th,
    .table tbody td {
        padding: 0.5rem;
    }
    .badge {
        padding: 0.25rem 0.5rem;
        font-size: 0.6875rem;
    }
    .pagination .page-link {
        padding: 0.25rem 0.5rem;
        font-size: 0.75rem;
    }
}
.login-container {
    min-height: calc(100vh - var(--header-height) - 60px);
    display: flex;
    align-items: stretch;
}
.login-container .row {
    min-height: calc(100vh - var(--header-height) - 60px);
    width: 100%;
    margin: 0;
}
.logo-section {
    display: flex;
    align-items: center;
    justify-content: flex-end;
    padding: 2rem;
}
.form-section {
    display: flex;
    align-items: center;
    justify-content: flex-start;
    padding: 2rem;
}
.login-card {
    width: 100%;
    max-width: 400px;
}
.logo-section > div {
    width: 100%;
    max-width: 550px;
}
.logo-section img {
    width: 100%;
    height: auto;
}
@media (max-width: 767.98px) {
    .login-container .row {
        flex-direction: column;
    }
    .logo-section {
        flex: 0 0 auto;
        justify-content: center !important;
        padding: 2rem 1.5rem 1rem !important;
    }
    .logo-section > div {
        max-width: 260px;
        text-align: center;
    }
    .form-section {
        flex: 1;
        justify-content: center !important;
        align-items: flex-start;
        padding: 1rem 1.5rem 2rem !important;
    }
    .login-card {
        margin: 0 auto;
    }
}
@media (max-width: 480px) {
    .logo-section {
        padding: 1.5rem 1rem 0.5rem !important;
    }
    .logo-section > div {
        max-width: 200px;
    }
    .form-section {
        padding: 0.5rem 1rem 1.5rem !important;
    }
    .login-card {
        max-width: 95%;
    }
    body:not(.authenticated) .logo-section,
    body:not(.authenticated) .form-section {
        padding: 1rem !important;
    }
    body:not(.authenticated) .logo-section {
        padding-top: 1.5rem !important;
    }
    body:not(.authenticated) .logo-section img {
        max-width: 60%;
    }
    body:not(.authenticated) .login-card {
        max-width: 95%;
    }
}
[data-bs-theme="dark"] .logo-dark {
    display: block !important;
}
[data-bs-theme="dark"] .logo-light {
    display: none !important;
}
[data-bs-theme="light"] .logo-dark {
    display: none !important;
}
[data-bs-theme="light"] .logo-light {
    display: block !important;
}
.login-card .mb-3,
.login-card .form-group {
    display: block;
}
.login-card .mb-3 label,
.login-card .form-group label {
    width: auto;
    text-align: left;
    padding-right: 0;
    padding-top: 0;
    margin-bottom: 0.5rem;
}
.table-scroll-wrapper {
    position: relative;
    overflow: hidden;
}
.table-scroll-wrapper .table-responsive {
    scrollbar-width: thin;
    -webkit-overflow-scrolling: touch;
}
.table-scroll-wrapper::before,
.table-scroll-wrapper::after {
    content: '';
    position: absolute;
    top: 0;
    bottom: 0;
    width: 20px;
    pointer-events: none;
    opacity: 0;
    transition: opacity 0.2s ease;
    z-index: 10;
}
.table-scroll-wrapper::before {
    left: 0;
    background: linear-gradient(to right, var(--bs-body-bg), transparent);
}
.table-scroll-wrapper::after {
    right: 0;
    background: linear-gradient(to left, var(--bs-body-bg), transparent);
}
.table-scroll-wrapper.scroll-left::before {
    opacity: 1;
}
.table-scroll-wrapper.scroll-right::after {
    opacity: 1;
}
.table .col-priority-3 { }
.table .col-priority-2 { }
.table .col-priority-1 { }
.table .col-priority-0 { }
@media (max-width: 991.98px) {
    .table .col-priority-3 {
        display: none !important;
    }
}
@media (max-width: 767.98px) {
    .table .col-priority-2,
    .table .col-priority-3 {
        display: none !important;
    }
}
@media (max-width: 575.98px) {
    .table .col-priority-1,
    .table .col-priority-2,
    .table .col-priority-3 {
        display: none !important;
    }
    .table-card-mobile thead {
        display: none;
    }
    .table-card-mobile tbody tr {
        display: block;
        background: var(--bs-card-bg);
        border: 1px solid var(--bs-border-color);
        border-radius: 0.5rem;
        margin-bottom: 0.75rem;
        padding: 0.75rem;
    }
    .table-card-mobile tbody td {
        display: flex;
        justify-content: space-between;
        align-items: center;
        padding: 0.5rem 0;
        border: none;
        border-bottom: 1px solid var(--bs-border-color);
    }
    .table-card-mobile tbody td:last-child {
        border-bottom: none;
    }
    .table-card-mobile tbody td::before {
        content: attr(data-label);
        font-weight: 600;
        color: var(--bs-secondary-color);
        font-size: 0.75rem;
        text-transform: uppercase;
        flex-shrink: 0;
        margin-right: 1rem;
    }
    .table-card-mobile tbody td:has(.form-check) {
        justify-content: flex-end;
    }
    .table-card-mobile tbody td:has(.form-check)::before {
        display: none;
    }
}
@media (max-width: 767.98px) {
    .form-control,
    .form-select,
    .btn {
        min-height: 48px;
        font-size: 16px !important;
    }
    input[type="text"],
    input[type="email"],
    input[type="password"],
    input[type="number"],
    input[type="search"],
    input[type="tel"],
    input[type="url"],
    textarea,
    select {
        font-size: 16px !important;
    }
    .form-label {
        font-size: 0.875rem;
        margin-bottom: 0.5rem;
    }
    .invalid-feedback,
    .valid-feedback {
        font-size: 0.8125rem;
        padding: 0.5rem;
        margin-top: 0.375rem;
        border-radius: 0.25rem;
    }
    .invalid-feedback {
        background-color: rgba(220, 53, 69, 0.1);
    }
    .valid-feedback {
        background-color: rgba(40, 167, 69, 0.1);
    }
    .btn-group-mobile-stack {
        display: flex;
        flex-direction: column;
        gap: 0.5rem;
    }
    .btn-group-mobile-stack .btn {
        width: 100%;
    }
    .form-row-mobile {
        flex-direction: column;
    }
    .form-row-mobile > [class*="col-"] {
        width: 100%;
        padding-left: 0;
        padding-right: 0;
        margin-bottom: 1rem;
    }
}
.bottom-nav {
    display: none;
    position: fixed;
    bottom: 0;
    left: 0;
    right: 0;
    background: var(--bs-card-bg);
    border-top: 1px solid var(--bs-border-color);
    z-index: 1050;
    padding-bottom: env(safe-area-inset-bottom, 0);
}
.bottom-nav-items {
    display: flex;
    justify-content: space-around;
    align-items: center;
    padding: 0.5rem 0;
}
.bottom-nav-item {
    display: flex;
    flex-direction: column;
    align-items: center;
    padding: 0.5rem 1rem;
    color: var(--bs-secondary-color);
    text-decoration: none;
    font-size: 0.6875rem;
    min-width: 64px;
    transition: color 0.2s;
}
.bottom-nav-item i {
    font-size: 1.25rem;
    margin-bottom: 0.125rem;
}
.bottom-nav-item.active,
.bottom-nav-item:hover {
    color: var(--bs-primary);
}
@media (max-width: 575.98px) {
    body.has-bottom-nav {
        padding-bottom: calc(60px + env(safe-area-inset-bottom, 0));
    }
    body.has-bottom-nav .bottom-nav {
        display: block;
    }
    body.has-bottom-nav footer {
        margin-bottom: calc(60px + env(safe-area-inset-bottom, 0));
    }
}
@media (max-width: 767.98px) {
    .breadcrumb-truncate .breadcrumb-item:not(:last-child):not(:first-child) {
        max-width: 60px;
        overflow: hidden;
        text-overflow: ellipsis;
        white-space: nowrap;
    }
    .breadcrumb-truncate .breadcrumb-item:not(:last-child):not(:first-child)::after {
        content: '...';
    }
}
@media (max-width: 991.98px) {
    .sidebar .nav-link,
    .sidebar .nav-section-header {
        min-height: 48px;
        display: flex;
        align-items: center;
    }
}
@media (max-width: 575.98px) {
    .modal-fullscreen-mobile .modal-dialog {
        margin: 0;
        width: 100%;
        max-width: 100%;
        height: 100%;
        max-height: 100%;
    }
    .modal-fullscreen-mobile .modal-content {
        height: 100%;
        border: none;
        border-radius: 0;
    }
    .modal-fullscreen-mobile .modal-body {
        overflow-y: auto;
        -webkit-overflow-scrolling: touch;
    }
}
.modal-bottom-sheet .modal-dialog {
    position: fixed;
    bottom: 0;
    left: 0;
    right: 0;
    margin: 0;
    max-width: 100%;
    transform: translateY(100%);
    transition: transform 0.3s ease-out;
}
.modal-bottom-sheet.show .modal-dialog {
    transform: translateY(0);
}
.modal-bottom-sheet .modal-content {
    border-radius: 1rem 1rem 0 0;
    border-bottom: none;
    max-height: 90vh;
    padding-bottom: env(safe-area-inset-bottom, 0);
}
.modal-bottom-sheet .modal-header {
    border-radius: 1rem 1rem 0 0;
}
.modal-bottom-sheet .modal-header::before {
    content: '';
    position: absolute;
    top: 8px;
    left: 50%;
    transform: translateX(-50%);
    width: 40px;
    height: 4px;
    background: var(--bs-border-color);
    border-radius: 2px;
}
.modal-bottom-sheet .modal-body {
    overflow-y: auto;
    -webkit-overflow-scrolling: touch;
    max-height: calc(90vh - 120px);
}
.modal-sticky-footer .modal-footer {
    position: sticky;
    bottom: 0;
    background: var(--bs-card-bg);
    border-top: 1px solid var(--bs-border-color);
    padding-bottom: calc(1rem + env(safe-area-inset-bottom, 0));
    margin-top: auto;
}
.stat-cards-scroll {
    display: flex;
    gap: 1rem;
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
    scrollbar-width: none;
    padding-bottom: 0.5rem;
    margin: 0 -1rem;
    padding-left: 1rem;
    padding-right: 1rem;
}
.stat-cards-scroll::-webkit-scrollbar {
    display: none;
}
.stat-cards-scroll .stat-card {
    flex: 0 0 auto;
    min-width: 140px;
    max-width: 180px;
}
@media (max-width: 575.98px) {
    .card {
        border-radius: 0;
        border-left: none;
        border-right: none;
        margin-left: -1rem;
        margin-right: -1rem;
        width: calc(100% + 2rem);
    }
    .card-edge-to-edge {
        border-radius: 0;
        border-left: none;
        border-right: none;
    }
    .card-body {
        padding: 1rem;
    }
    .card-header,
    .card-footer {
        padding: 0.75rem 1rem;
    }
}
@media (max-width: 767.98px) {
    .card-stack-mobile > .card {
        margin-bottom: 1rem;
    }
    .card-stack-mobile > .card:last-child {
        margin-bottom: 0;
    }
}
.btn {
    min-height: 38px;
}
@media (max-width: 767.98px) {
    .btn {
        min-height: 44px;
        padding: 0.625rem 1rem;
    }
    .btn-sm {
        min-height: 38px;
        padding: 0.5rem 0.75rem;
    }
}
.btn-icon {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 44px;
    height: 44px;
    padding: 0;
    border-radius: 50%;
}
.btn-icon i {
    font-size: 1.25rem;
}
.fab {
    position: fixed;
    bottom: 1.5rem;
    right: 1.5rem;
    width: 56px;
    height: 56px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.3);
    z-index: 1040;
    transition: transform 0.2s, box-shadow 0.2s;
}
.fab:hover {
    transform: scale(1.05);
    box-shadow: 0 6px 16px rgba(0, 0, 0, 0.4);
}
.fab:active {
    transform: scale(0.95);
}
.fab i {
    font-size: 1.5rem;
}
@media (max-width: 575.98px) {
    body.has-bottom-nav .fab {
        bottom: calc(70px + env(safe-area-inset-bottom, 0));
    }
    .fab {
        right: 1rem;
        bottom: 1rem;
    }
}
@media (max-width: 767.98px) {
    h1, .h1 { font-size: 1.75rem; }
    h2, .h2 { font-size: 1.5rem; }
    h3, .h3 { font-size: 1.25rem; }
    h4, .h4 { font-size: 1.125rem; }
    h5, .h5 { font-size: 1rem; }
    h6, .h6 { font-size: 0.875rem; }
    body {
        line-height: 1.6;
    }
    p, li {
        line-height: 1.7;
    }
}
@media (max-width: 575.98px) {
    h1, .h1 { font-size: 1.5rem; }
    h2, .h2 { font-size: 1.375rem; }
    h3, .h3 { font-size: 1.125rem; }
    .text-truncate-mobile {
        max-width: 100%;
        overflow: hidden;
        text-overflow: ellipsis;
        white-space: nowrap;
    }
}
pre, code {
    word-break: break-word;
    overflow-wrap: break-word;
}
@media (max-width: 575.98px) {
    pre {
        font-size: 0.75rem;
        padding: 0.75rem;
        margin-left: -1rem;
        margin-right: -1rem;
        border-radius: 0;
    }
    .code-block {
        border-radius: 0;
        margin-left: -1rem;
        margin-right: -1rem;
        padding: 0.75rem 1rem;
    }
}
@media (max-width: 767.98px) {
    main {
        padding: 1rem;
    }
    .container-fluid {
        padding-left: 1rem;
        padding-right: 1rem;
    }
    .section-spacing {
        margin-bottom: 1.5rem;
    }
    .gap-3 { gap: 0.75rem !important; }
    .gap-4 { gap: 1rem !important; }
    .p-4 { padding: 1rem !important; }
    .p-5 { padding: 1.5rem !important; }
    .px-4 { padding-left: 1rem !important; padding-right: 1rem !important; }
    .px-5 { padding-left: 1.5rem !important; padding-right: 1.5rem !important; }
    .py-4 { padding-top: 1rem !important; padding-bottom: 1rem !important; }
    .py-5 { padding-top: 1.5rem !important; padding-bottom: 1.5rem !important; }
}
@media (max-width: 575.98px) {
    main {
        padding: 0.75rem;
    }
    .container-fluid {
        padding-left: 0.75rem;
        padding-right: 0.75rem;
    }
    .section-spacing {
        margin-bottom: 1rem;
    }
}
@supports (padding: env(safe-area-inset-bottom)) {
    .safe-area-bottom {
        padding-bottom: env(safe-area-inset-bottom, 0);
    }
    .safe-area-top {
        padding-top: env(safe-area-inset-top, 0);
    }
    @media (max-width: 575.98px) {
        footer {
            padding-bottom: calc(1rem + env(safe-area-inset-bottom, 0));
        }
    }
}
.touch-action-pan-y {
    touch-action: pan-y;
}
.touch-action-manipulation {
    touch-action: manipulation;
}
@keyframes swipeHint {
    0%, 100% { transform: translateX(0); }
    50% { transform: translateX(-10px); }
}
.table-scroll-wrapper.show-hint .table-responsive {
    animation: swipeHint 1s ease-in-out 2;
}
.btn:active,
.nav-link:active,
.list-group-item:active {
    opacity: 0.8;
}
.no-select {
    -webkit-user-select: none;
    user-select: none;
    -webkit-touch-callout: none;
}
