:root {
    --navy: #0a1628;
    --navy-mid: #132240;
    --navy-light: #1e3a5f;
    --saffron: #ff6b00;
    --saffron-light: #ff8c3a;
    --gold: #c9a84c;
    --green: #1a7a4a;
    --green-light: #22a060;
    --red: #c0392b;
    --red-light: #e74c3c;
    --amber: #d4830a;
    --amber-light: #f0a020;
    --blue: #1565c0;
    --white: #ffffff;
    --off-white: #f5f6fa;
    --gray-50: #f8f9fc;
    --gray-100: #eef0f5;
    --gray-200: #dde0e9;
    --gray-300: #bcc2d0;
    --gray-400: #98a1b3;
    --gray-500: #7a849a;
    --gray-700: #3d4a5c;
    --text-primary: #0d1b2a;
    --text-secondary: #4a5568;
    --sidebar-width: 264px;
    --header-height: 68px;
    --radius-sm: 8px;
    --radius: 10px;
    --radius-md: 14px;
    --radius-lg: 20px;
    --shadow-sm: 0 1px 3px rgba(10, 22, 40, 0.08);
    --shadow-md: 0 10px 30px rgba(10, 22, 40, 0.08);
    --shadow-lg: 0 18px 44px rgba(10, 22, 40, 0.14);
    --transition: 0.2s ease;
}

*,
*::before,
*::after {
    box-sizing: border-box;
}

html,
body {
    margin: 0;
    min-height: 100%;
}

body {
    font-family: "Noto Sans", "Noto Sans Devanagari", sans-serif;
    background:
        radial-gradient(circle at top right, rgba(255, 107, 0, 0.06), transparent 24%),
        linear-gradient(180deg, #fbfcfe 0%, #f3f6fb 100%);
    color: var(--text-primary);
    line-height: 1.5;
}

a {
    color: inherit;
    text-decoration: none;
}

button,
input,
select,
textarea {
    font: inherit;
}

[x-cloak] {
    display: none !important;
}

.app-body {
    overflow-x: hidden;
    overflow-y: auto;
}

.app-overlay {
    background: rgba(10, 22, 40, 0.55);
    backdrop-filter: blur(6px);
}

.app-main {
    margin-left: 0;
    min-height: 100dvh;
    display: flex;
    flex-direction: column;
    transition: margin-left var(--transition);
}

.app-header {
    position: sticky;
    top: 0;
    z-index: 40;
    height: var(--header-height);
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
    padding: 0 20px;
    background: rgba(255, 255, 255, 0.94);
    backdrop-filter: blur(12px);
    border-bottom: 1px solid rgba(221, 224, 233, 0.9);
    box-shadow: var(--shadow-sm);
}

.app-header-left,
.app-header-right {
    display: flex;
    align-items: center;
    gap: 14px;
}

.mobile-toggle {
    width: 42px;
    height: 42px;
    border: 1px solid var(--gray-200);
    border-radius: var(--radius);
    background: var(--white);
    color: var(--navy-light);
    display: inline-flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: all var(--transition);
}

.mobile-toggle:hover {
    background: var(--gray-50);
}

.app-title-group {
    display: flex;
    flex-direction: row;
    gap: 10px;
    align-items: baseline;
}

.app-title {
    font-size: 1rem;
    font-weight: 700;
    color: var(--text-primary);
    line-height: 1.2;
}

.app-title .muted-inline {
    color: var(--gray-500);
    font-size: 0.8rem;
    font-weight: 500;
    margin-left: 8px;
    text-transform: uppercase;
    letter-spacing: 0.08em;
}

.app-subtitle {
    font-size: 0.72rem;
    font-weight: 700;
    color: var(--gray-500);
    text-transform: uppercase;
    letter-spacing: 0.16em;
}

.header-search {
    position: relative;
    width: min(340px, 48vw);
    display: flex;
    align-items: center;
    gap: 10px;
}

.header-search span {
    position: absolute;
    top: 50%;
    left: 14px;
    transform: translateY(-50%);
    color: var(--gray-400);
    font-size: 0.76rem;
}

.header-search input {
    width: 100%;
    height: 42px;
    border: 1.5px solid var(--gray-200);
    border-radius: 999px;
    background: var(--gray-50);
    padding: 0 16px 0 40px;
    font-size: 0.82rem;
    color: var(--text-primary);
    transition: all var(--transition);
}

.header-search input::placeholder {
    color: var(--gray-400);
}

.header-search input:focus {
    outline: none;
    border-color: var(--navy-light);
    box-shadow: 0 0 0 3px rgba(30, 58, 95, 0.08);
    background: var(--white);
}

.header-icon-btn {
    width: 38px;
    height: 38px;
    border-radius: var(--radius);
    border: 1px solid var(--gray-200);
    background: var(--white);
    color: var(--gray-500);
    display: inline-flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    position: relative;
    transition: all var(--transition);
}

.header-icon-btn:hover {
    color: var(--navy-light);
    background: var(--gray-50);
}

.notif-dot {
    position: absolute;
    top: 8px;
    right: 8px;
    width: 8px;
    height: 8px;
    border-radius: 999px;
    background: var(--red);
    border: 2px solid var(--white);
}

.page-scroll {
    flex: 1;
    overflow-x: hidden;
    overflow-y: visible;
    min-height: 0;
}

.page-container {
    max-width: 1480px;
    width: 100%;
    margin: 0 auto;
    padding: 22px 20px 32px;
}

.overflow-hidden {
    overflow: hidden !important;
}

.message-banner {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 12px 14px;
    border-radius: var(--radius-md);
    border: 1px solid transparent;
    font-size: 0.84rem;
    font-weight: 600;
    box-shadow: var(--shadow-sm);
}

.message-banner.success {
    background: #edf8f1;
    color: var(--green);
    border-color: #cde8d7;
}

.message-banner.error {
    background: #fceeee;
    color: var(--red);
    border-color: #f3c9c4;
}

#sidebar {
    position: fixed;
    top: 0;
    left: 0;
    bottom: 0;
    width: var(--sidebar-width);
    background: linear-gradient(180deg, var(--navy) 0%, #0d1f38 100%);
    color: var(--white);
    display: flex;
    flex-direction: column;
    z-index: 50;
    box-shadow: 12px 0 40px rgba(10, 22, 40, 0.2);
}

.sidebar-header {
    padding: 18px 18px 14px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.08);
}

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

.sidebar-brand-text h2 {
    margin: 0;
}

.sidebar-brand-icon {
    width: 42px;
    height: 42px;
    border-radius: 12px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    background: linear-gradient(135deg, var(--saffron), var(--gold));
    color: var(--white);
    font-size: 1.1rem;
    box-shadow: 0 6px 14px rgba(255, 107, 0, 0.24);
}

.sidebar-brand-text h1 {
    margin: 0;
    font-size: 1rem;
    font-weight: 700;
    letter-spacing: -0.02em;
}

.sidebar-brand-text p {
    margin: 2px 0 0;
    font-size: 0.63rem;
    color: rgba(255, 255, 255, 0.58);
    text-transform: uppercase;
    letter-spacing: 0.14em;
}

.sidebar-user-card {
    margin: 16px 18px 12px;
    padding: 14px;
    border-radius: var(--radius-md);
    background: rgba(255, 255, 255, 0.06);
    border: 1px solid rgba(255, 255, 255, 0.08);
}

.sidebar-user {
    margin: 12px 18px;
    padding: 12px;
    background: rgba(255, 255, 255, 0.05);
    border-radius: var(--radius);
    border: 1px solid rgba(255, 255, 255, 0.08);
}

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

.sidebar-user-avatar {
    width: 42px;
    height: 42px;
    border-radius: 30px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    background: linear-gradient(135deg, var(--blue), #2684e0);
    color: var(--white);
    font-size: 0.9rem;
    font-weight: 700;
    flex-shrink: 0;
}

.sidebar_profile {
    width: 100%;
}

p.sidebar-user-name {
    font-size: 13px;
    font-weight: 600;
    color: white;
    margin: 0;
}

p.sidebar-user-role {
    font-size: 11px;
    color: rgba(255, 255, 255, 0.5);
    margin-top: 2px;
}

p.sidebar-user-dept {
    font-size: 10px;
    color: var(--saffron-light);
    margin-top: 2px;
}

.sidebar-user-role {
    margin: 2px 0 0;
    font-size: 0.68rem;
    color: var(--saffron-light);
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.08em;
}

.sidebar-user-org {
    margin: 3px 0 0;
    font-size: 0.66rem;
    color: rgba(255, 255, 255, 0.5);
}

.sidebar-nav {
    flex: 1;
    overflow-y: auto;
    padding: 8px 0 14px;
}

.nav-section-label {
    padding: 10px 18px 6px;
    font-size: 0.61rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.2em;
    color: rgba(255, 255, 255, 0.34);
}

.nav-link {
    margin: 0 12px 4px;
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 10px 12px;
    border-radius: 12px;
    color: rgba(255, 255, 255, 0.66);
    font-size: 0.83rem;
    font-weight: 600;
    transition: all var(--transition);
}

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

.nav-link.active {
    background: rgba(255, 107, 0, 0.18);
    color: var(--white);
    box-shadow: inset 3px 0 0 var(--saffron);
}

.nav-link i {
    width: 18px;
    text-align: center;
    color: inherit;
}

.nav-badge {
    margin-left: auto;
    min-width: 20px;
    padding: 2px 7px;
    border-radius: 999px;
    font-size: 0.62rem;
    font-weight: 700;
    text-align: center;
}

.nav-badge.red {
    background: rgba(231, 76, 60, 0.2);
    color: #ffc4be;
}

.nav-badge.amber {
    background: rgba(212, 131, 10, 0.2);
    color: #ffd8a1;
}

.nav-badge.green {
    background: rgba(34, 160, 96, 0.18);
    color: #c8f1da;
}

.sidebar-footer {
    padding: 14px 16px 16px;
    border-top: 1px solid rgba(255, 255, 255, 0.08);
    background: rgba(7, 15, 28, 0.35);
}

.lang-toggle {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 6px;
}

.lang-btn {
    min-height: 34px;
    border-radius: var(--radius-sm);
    border: 1px solid rgba(255, 255, 255, 0.1);
    background: rgba(255, 255, 255, 0.05);
    color: rgba(255, 255, 255, 0.58);
    font-size: 0.72rem;
    font-weight: 700;
    cursor: pointer;
    transition: all var(--transition);
}

.lang-btn.active,
.lang-btn:hover {
    background: var(--saffron);
    border-color: var(--saffron);
    color: var(--white);
}

.logout-btn {
    width: 100%;
    margin-top: 10px;
    min-height: 38px;
    border-radius: var(--radius);
    border: 1px solid rgba(231, 76, 60, 0.34);
    background: rgba(231, 76, 60, 0.14);
    color: #ffb8af;
    font-size: 0.74rem;
    font-weight: 700;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    cursor: pointer;
    transition: all var(--transition);
}

.logout-btn:hover {
    background: rgba(231, 76, 60, 0.22);
    color: var(--white);
}

.page-stack {
    display: flex;
    flex-direction: column;
    gap: 22px;
}

.page-hero {
    position: relative;
    overflow: hidden;
    padding: 24px 26px;
    border-radius: var(--radius-lg);
    background: linear-gradient(135deg, var(--navy) 0%, var(--navy-light) 100%);
    color: var(--white);
    box-shadow: var(--shadow-md);
}

.page-hero::before,
.page-hero::after {
    content: "";
    position: absolute;
    border-radius: 999px;
    pointer-events: none;
}

.page-hero::before {
    top: -48px;
    right: -44px;
    width: 200px;
    height: 200px;
    background: radial-gradient(circle, rgba(255, 107, 0, 0.2), transparent 66%);
}

.page-hero::after {
    left: -48px;
    bottom: -58px;
    width: 220px;
    height: 220px;
    background: radial-gradient(circle, rgba(201, 168, 76, 0.12), transparent 68%);
}

.page-hero-inner {
    position: relative;
    z-index: 1;
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 16px;
}

.page-kicker {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    margin-bottom: 10px;
    font-size: 0.64rem;
    font-weight: 700;
    letter-spacing: 0.18em;
    text-transform: uppercase;
    color: rgba(255, 255, 255, 0.68);
}

.page-kicker::before {
    content: "";
    width: 28px;
    height: 1px;
    background: linear-gradient(90deg, var(--saffron), rgba(255, 255, 255, 0.5));
}

.page-heading {
    max-width: 720px;
}

.page-heading h1,
.page-heading h2 {
    margin: 0;
    font-size: clamp(1.55rem, 1.2rem + 1vw, 2.1rem);
    font-weight: 700;
    letter-spacing: -0.03em;
}

.page-heading p {
    margin: 8px 0 0;
    max-width: 640px;
    font-size: 0.9rem;
    color: rgba(255, 255, 255, 0.72);
}

.page-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    justify-content: flex-end;
}

.action-button {
    min-height: 42px;
    padding: 0 16px;
    border-radius: var(--radius);
    border: 1px solid transparent;
    display: inline-flex;
    align-items: center;
    gap: 8px;
    cursor: pointer;
    font-size: 0.78rem;
    font-weight: 700;
    letter-spacing: 0.04em;
    text-transform: uppercase;
    transition: all var(--transition);
    white-space: nowrap;
}

.action-button-primary {
    background: linear-gradient(135deg, var(--saffron), var(--saffron-light));
    color: var(--white);
    box-shadow: 0 10px 22px rgba(255, 107, 0, 0.24);
}

.action-button-primary:hover {
    transform: translateY(-1px);
    box-shadow: 0 14px 28px rgba(255, 107, 0, 0.3);
}

.action-button-secondary {
    background: rgba(255, 255, 255, 0.12);
    border-color: rgba(255, 255, 255, 0.18);
    color: var(--white);
}

.action-button-secondary:hover {
    background: rgba(255, 255, 255, 0.18);
}

.action-button-outline {
    background: var(--white);
    color: var(--text-secondary);
    border-color: var(--gray-200);
}

.action-button-outline:hover {
    background: var(--gray-50);
}

.metric-grid {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 16px;
}

.metric-card {
    position: relative;
    overflow: hidden;
    background: rgba(255, 255, 255, 0.96);
    border: 1px solid var(--gray-100);
    border-radius: var(--radius-md);
    padding: 18px 18px 20px;
    box-shadow: var(--shadow-sm);
    transition: all var(--transition);
}

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

.metric-card::before {
    content: "";
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 4px;
}

.metric-card.total::before {
    background: var(--blue);
}

.metric-card.pending::before {
    background: var(--amber);
}

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

.metric-card.urgent::before {
    background: var(--red);
}

.metric-eyebrow {
    margin: 0 0 8px;
    color: var(--gray-500);
    font-size: 0.68rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.14em;
}

.metric-value {
    margin: 0;
    font-size: 2rem;
    font-weight: 700;
    line-height: 1;
    color: var(--text-primary);
}

.metric-meta {
    margin-top: 8px;
    font-size: 0.75rem;
    color: var(--gray-500);
}

.metric-icon {
    position: absolute;
    right: 16px;
    bottom: 16px;
    font-size: 1.6rem;
    opacity: 0.14;
}

.metric-card.total .metric-value,
.metric-card.total .metric-icon {
    color: var(--blue);
}

.metric-card.pending .metric-value,
.metric-card.pending .metric-icon {
    color: var(--amber);
}

.metric-card.approved .metric-value,
.metric-card.approved .metric-icon {
    color: var(--green);
}

.metric-card.urgent .metric-value,
.metric-card.urgent .metric-icon {
    color: var(--red);
}

.content-grid-two {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 20px;
    align-items: stretch;
}

.content-grid-aside {
    display: grid;
    grid-template-columns: minmax(0, 1.85fr) minmax(280px, 0.9fr);
    gap: 20px;
}

.dept_block {
    display: flex;
    flex-direction: column;
    gap: 15px;
}

.surface-card {
    background: rgba(255, 255, 255, 0.98);
    border: 1px solid rgba(221, 224, 233, 0.85);
    border-radius: var(--radius-md);
    box-shadow: var(--shadow-sm);
    overflow: hidden;
    display: flex;
    flex-direction: column;
    height: 100%;
}

.surface-card > .surface-body.relative,
.vertical_manage > .surface-body.relative {
    flex: 1;
    display: flex;
    flex-direction: column;
}

.vertical_manage {
    flex: 1;
    display: flex;
    flex-direction: column;
    min-height: 0;
}

.surface-card > [x-show*="pagination"] {
    margin-top: auto;
}

.surface-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    padding: 14px 18px;
    border-bottom: 1px solid var(--gray-100);
}

.surface-title {
    display: flex;
    align-items: center;
    gap: 10px;
    margin: 0;
    font-size: 0.86rem;
    font-weight: 700;
    color: var(--text-primary);
}

.surface-title-bar {
    width: 4px;
    height: 18px;
    border-radius: 999px;
    background: var(--saffron);
}

.surface-subtitle {
    font-size: 0.72rem;
    color: var(--gray-500);
    font-weight: 600;
}

.surface-action {
    font-size: 0.76rem;
    font-weight: 700;
    color: var(--blue);
}

.surface-action:hover {
    text-decoration: underline;
}

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

.section-title {
    margin: 0;
    font-size: 0.96rem;
    font-weight: 700;
    color: var(--text-primary);
}

.section-actions {
    display: flex;
    align-items: center;
    gap: 10px;
    flex-wrap: wrap;
}

.section-action-btn {
    min-height: 34px;
    padding: 0 12px;
    border-radius: var(--radius-sm);
    border: 1px solid var(--gray-200);
    background: var(--white);
    color: var(--text-secondary);
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    cursor: pointer;
    font-size: 0.76rem;
    font-weight: 700;
    transition: all var(--transition);
    white-space: nowrap;
}

.section-action-btn:hover {
    background: var(--gray-50);
}

.section-action-btn.primary {
    background: linear-gradient(135deg, var(--navy), var(--navy-light));
    border-color: transparent;
    color: var(--white);
}

.section-action-btn.primary:hover {
    filter: brightness(1.04);
}

.surface-body {
    padding: 18px;
}

.table-shell {
    background: rgba(255, 255, 255, 0.98);
    border: 1px solid rgba(221, 224, 233, 0.88);
    border-radius: var(--radius-md);
    box-shadow: var(--shadow-sm);
    overflow: hidden;
}

.table-toolbar {
    padding: 16px 18px;
    border-bottom: 1px solid var(--gray-100);
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
}

.table-title {
    margin: 0;
    font-size: 0.92rem;
    font-weight: 700;
    color: var(--text-primary);
}

.table-title span {
    color: var(--gray-500);
    font-weight: 500;
}

.table-filters {
    display: flex;
    align-items: center;
    gap: 10px;
    flex-wrap: wrap;
}

.panel-toolbar {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    margin-bottom: 14px;
}

.panel-note {
    font-size: 0.74rem;
    color: var(--gray-500);
}

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

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

thead th {
    text-align: left;
    background: var(--gray-50);
    color: var(--gray-500);
    font-size: 0.68rem;
    font-weight: 700;
    letter-spacing: 0.12em;
    text-transform: uppercase;
    padding: 12px 14px;
    border-bottom: 1px solid var(--gray-200);
    white-space: nowrap;
}

tbody td {
    padding: 13px 14px;
    border-bottom: 1px solid var(--gray-100);
    font-size: 0.84rem;
    color: var(--text-secondary);
    vertical-align: top;
    min-width: 105px;
}

tbody tr:last-child td {
    border-bottom: none;
}

tbody tr:hover td {
    background: #fbfcfe;
}

.table-row-link {
    cursor: pointer;
}

.mono-code {
    font-family: "IBM Plex Mono", monospace;
    font-size: 0.74rem;
    color: var(--navy-light);
    font-weight: 600;
}

.item-title {
    margin: 0;
    font-size: 0.86rem;
    font-weight: 700;
    color: var(--text-primary);
    line-height: 1.35;
}

.item-subtitle {
    margin: 3px 0 0;
    font-size: 0.72rem;
    color: var(--gray-500);
}

.status-badge {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 4px 10px;
    border-radius: 999px;
    font-size: 0.69rem;
    font-weight: 700;
    letter-spacing: 0.02em;
    border: 1px solid transparent;
    white-space: nowrap;
}

.status-badge::before {
    content: "";
    width: 6px;
    height: 6px;
    border-radius: 999px;
    background: currentColor;
}

.badge-pending {
    background: #fff4e6;
    color: var(--amber);
    border-color: #ffd9a0;
}

.badge-review {
    background: #e8f0fe;
    color: var(--blue);
    border-color: #a8c4f0;
}

.badge-approved {
    background: #e8f5ee;
    color: var(--green);
    border-color: #a8dcc0;
}

.badge-urgent {
    background: #fdecea;
    color: var(--red);
    border-color: #f5b8b4;
}

.badge-neutral {
    background: var(--gray-50);
    color: var(--gray-700);
    border-color: var(--gray-200);
}

.chip-row {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
}

.chip {
    display: inline-flex;
    align-items: center;
    gap: 5px;
    padding: 4px 10px;
    border-radius: 999px;
    font-size: 0.68rem;
    font-weight: 700;
}

.chip.dept {
    background: #ede7f6;
    color: #5e35b1;
}

.chip.year {
    background: #e3f2fd;
    color: #0277bd;
}

.chip.type {
    background: #e8f5ee;
    color: var(--green);
}

.chip.ai {
    background: linear-gradient(135deg, #fff3e0, #ffe0b2);
    color: var(--saffron);
}

.chip.dark {
    background: rgba(10, 22, 40, 0.06);
    color: var(--navy-light);
}

.folder-panel {
    display: flex;
    flex-direction: column;
    gap: 18px;
}

.folder-section-title {
    margin: 0 0 10px;
    font-size: 0.66rem;
    font-weight: 700;
    letter-spacing: 0.18em;
    text-transform: uppercase;
    color: var(--gray-500);
}

.folder-section-head {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 10px;
    margin-bottom: 10px;
}

.folder-inline-action {
    min-height: 28px;
    padding: 0 10px;
    border-radius: 999px;
    border: 1px solid var(--gray-200);
    background: var(--white);
    color: var(--navy-light);
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 6px;
    cursor: pointer;
    font-size: 0.67rem;
    font-weight: 700;
    transition: all var(--transition);
    white-space: nowrap;
}

.folder-inline-action:hover {
    background: var(--gray-50);
}

.folder-list {
    display: flex;
    flex-direction: column;
    gap: 6px;
}

.folder-link {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 10px;
    padding: 10px 12px;
    border-radius: var(--radius);
    color: var(--text-secondary);
    transition: all var(--transition);
}

.folder-link:hover {
    background: var(--gray-50);
}

.folder-link.active {
    background: #eef4ff;
    color: var(--navy-light);
    font-weight: 700;
}

.folder-link-main {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    min-width: 0;
}

.folder-link-main span:last-child {
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.folder-count {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    font-size: 0.68rem;
    font-weight: 700;
    color: var(--gray-500);
}

.folder-action {
    width: 28px;
    height: 28px;
    border-radius: 8px;
    border: none;
    background: transparent;
    color: var(--red);
    display: inline-flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    opacity: 0;
    transition: all var(--transition);
}

.folder-link:hover .folder-action {
    opacity: 1;
}

.folder-action:hover {
    background: #fdecea;
}

.form-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 16px;
}

.form-stack {
    display: flex;
    flex-direction: column;
    gap: 16px;
}

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

.form-label {
    font-size: 0.68rem;
    font-weight: 700;
    color: var(--gray-500);
    text-transform: uppercase;
    letter-spacing: 0.14em;
}

.form-control,
.form-select,
.form-textarea {
    width: 100%;
    min-height: 44px;
    border: 1.5px solid var(--gray-200);
    border-radius: var(--radius);
    background: var(--white);
    color: var(--text-primary);
    padding: 0 14px;
    font-size: 0.88rem;
    transition: all var(--transition);
}

.form-textarea {
    min-height: 110px;
    padding: 12px 14px;
    resize: vertical;
}

.form-control:focus,
.form-select:focus,
.form-textarea:focus {
    outline: none;
    border-color: var(--navy-light);
    box-shadow: 0 0 0 3px rgba(30, 58, 95, 0.08);
}

.form-select {
    appearance: none;
    background-image: linear-gradient(45deg, transparent 50%, var(--gray-500) 50%), linear-gradient(135deg, var(--gray-500) 50%, transparent 50%);
    background-position: calc(100% - 18px) calc(50% - 3px), calc(100% - 12px) calc(50% - 3px);
    background-size: 6px 6px, 6px 6px;
    background-repeat: no-repeat;
    padding-right: 34px;
    cursor: pointer;
}

.filter-control {
    min-width: 150px;
    min-height: 38px;
    border: 1px solid var(--gray-200);
    border-radius: 999px;
    background: var(--gray-50);
    color: var(--text-secondary);
    padding: 0 14px;
    font-size: 0.76rem;
    font-weight: 600;
}

.filter-control:focus {
    outline: none;
    border-color: var(--navy-light);
}

.btn-row,
.modal-actions {
    display: flex;
    align-items: center;
    gap: 10px;
    flex-wrap: wrap;
}

.btn {
    min-height: 40px;
    padding: 0 16px;
    border: none;
    border-radius: var(--radius);
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    cursor: pointer;
    font-size: 0.78rem;
    font-weight: 700;
    letter-spacing: 0.05em;
    text-transform: uppercase;
    transition: all var(--transition);
}

.btn-primary {
    background: linear-gradient(135deg, var(--navy), var(--navy-light));
    color: var(--white);
    box-shadow: 0 6px 18px rgba(10, 22, 40, 0.18);
}

.btn-primary:hover {
    transform: translateY(-1px);
}

.btn-saffron {
    background: linear-gradient(135deg, var(--saffron), var(--saffron-light));
    color: var(--white);
    box-shadow: 0 10px 22px rgba(255, 107, 0, 0.22);
}

.btn-success {
    background: var(--green);
    color: var(--white);
}

.btn-danger {
    background: var(--red);
    color: var(--white);
}

.btn-warning {
    background: var(--amber);
    color: var(--white);
}

.btn-outline {
    background: var(--white);
    color: var(--text-secondary);
    border: 1px solid var(--gray-200);
}

.btn-muted {
    background: var(--gray-50);
    color: var(--gray-700);
}

.btn:hover {
    filter: brightness(1.02);
}

.mini-action {
    width: 34px;
    height: 34px;
    border-radius: var(--radius-sm);
    border: 1px solid var(--gray-200);
    background: var(--white);
    color: var(--gray-500);
    display: inline-flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: all var(--transition);
}

.mini-action:hover {
    background: var(--gray-50);
    color: var(--navy-light);
}

.mini-action.danger {
    color: var(--red);
    border-color: #f2d2cf;
    background: #fff9f8;
}

.mini-action.danger:hover {
    background: #fdecea;
}

.modal-card {
    width: 100%;
    max-width: 560px;
    border-radius: var(--radius-lg);
    background: var(--white);
    box-shadow: var(--shadow-lg);
    border: 1px solid rgba(221, 224, 233, 0.7);
    overflow: hidden;
}

.modal-header {
    padding: 18px 22px;
    border-bottom: 1px solid var(--gray-100);
}

.modal-title {
    margin: 0;
    font-size: 1rem;
    font-weight: 700;
    color: var(--text-primary);
}

.modal-copy {
    margin: 6px 0 0;
    font-size: 0.76rem;
    color: var(--gray-500);
}

.modal-body {
    padding: 20px 22px;
}

.modal-footer {
    padding: 18px 22px 22px;
    border-top: 1px solid var(--gray-100);
}

.empty-state {
    min-height: 150px;
    border: 1.5px dashed var(--gray-200);
    border-radius: var(--radius-md);
    background: linear-gradient(180deg, #ffffff 0%, #fbfcfe 100%);
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 10px;
    text-align: center;
    padding: 20px;
}

.empty-state-icon {
    width: 48px;
    height: 48px;
    border-radius: 14px;
    background: var(--gray-50);
    color: var(--gray-400);
    display: inline-flex;
    align-items: center;
    justify-content: center;
    font-size: 1.1rem;
}

.empty-state h4,
.empty-state p {
    margin: 0;
}

.empty-state h4 {
    font-size: 0.85rem;
    color: var(--text-primary);
}

.empty-state p {
    font-size: 0.75rem;
    color: var(--gray-500);
}

.activity-list,
.timeline-list,
.notification-list {
    display: flex;
    flex-direction: column;
    gap: 14px;
    flex: 1;
}

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

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

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

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

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

.activity-dot.red {
    background: var(--red);
}

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

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

.activity-content p,
.activity-content small {
    margin: 0;
}

.activity-content p {
    font-size: 0.82rem;
    color: var(--text-secondary);
}

.activity-content p strong {
    color: var(--text-primary);
}

.activity-content small {
    display: block;
    margin-top: 4px;
    font-size: 0.7rem;
    color: var(--gray-500);
}

.workload-list {
    display: flex;
    flex-direction: column;
    gap: 16px;
}

.workload-row {
    display: grid;
    grid-template-columns: 120px minmax(0, 1fr) auto;
    align-items: center;
    gap: 12px;
}

.workload-row span {
    font-size: 0.78rem;
    color: var(--text-secondary);
}

.workload-row strong {
    font-size: 0.8rem;
    color: var(--text-primary);
}

.progress-bar {
    height: 7px;
    border-radius: 999px;
    overflow: hidden;
    background: var(--gray-100);
}

.progress-fill {
    height: 100%;
    border-radius: 999px;
    background: linear-gradient(90deg, var(--saffron), var(--gold));
}

.notification-item {
    display: flex;
    gap: 12px;
    padding-bottom: 14px;
    border-bottom: 1px solid var(--gray-100);
}

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

.notification-icon {
    width: 38px;
    height: 38px;
    border-radius: 12px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
}

.notification-icon.orange {
    background: #fff4e6;
    color: var(--amber);
}

.notification-icon.red {
    background: #fdecea;
    color: var(--red);
}

.notification-icon.green {
    background: #e8f5ee;
    color: var(--green);
}

.notification-icon.blue {
    background: #e8f0fe;
    color: var(--blue);
}

.notification-copy {
    flex: 1;
}

.notification-copy h4,
.notification-copy p,
.notification-time {
    margin: 0;
}

.notification-copy h4 {
    font-size: 0.82rem;
    color: var(--text-primary);
}

.notification-copy p {
    margin-top: 2px;
    font-size: 0.74rem;
    color: var(--gray-500);
}

.notification-time {
    font-size: 0.68rem;
    color: var(--gray-500);
    white-space: nowrap;
}

.page-breadcrumb {
    display: flex;
    align-items: center;
    gap: 6px;
    font-size: 0.75rem;
    color: var(--gray-500);
}

.page-breadcrumb a {
    color: var(--blue);
    cursor: pointer;
}

.page-breadcrumb a:hover {
    text-decoration: underline;
}

.file-detail-header {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 16px;
    margin-bottom: 20px;
}

.file-detail-heading {
    min-width: 0;
}

.file-detail-title-row {
    display: flex;
    align-items: center;
    gap: 12px;
    flex-wrap: wrap;
    margin-bottom: 6px;
}

.file-detail-title {
    margin: 0;
    font-size: 1.25rem;
    font-weight: 700;
    color: var(--text-primary);
}

.file-detail-header-actions {
    display: flex;
    gap: 10px;
    flex-shrink: 0;
    flex-wrap: wrap;
}

.file-detail-layout,
.detail-layout {
    display: grid;
    grid-template-columns: minmax(0, 1.8fr) minmax(280px, 0.82fr);
    gap: 20px;
}

.file-detail-column {
    display: flex;
    flex-direction: column;
    gap: 16px;
}

.panel {
    background: rgba(255, 255, 255, 0.98);
    border: 1px solid rgba(221, 224, 233, 0.88);
    border-radius: var(--radius-md);
    box-shadow: var(--shadow-sm);
    overflow: hidden;
}

.panel-header {
    padding: 14px 18px;
    border-bottom: 1px solid var(--gray-100);
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
}

.panel-title {
    font-size: 0.88rem;
    font-weight: 700;
    color: var(--text-primary);
}

.panel-subtitle {
    font-size: 0.7rem;
    color: var(--gray-500);
    font-weight: 600;
}

.panel-action {
    font-size: 0.76rem;
    font-weight: 700;
    color: var(--blue);
    background: transparent;
    border: none;
    cursor: pointer;
}

.panel-action:hover {
    text-decoration: underline;
}

.panel-body {
    padding: 18px;
}

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

.btn-sm {
    min-height: 34px;
    padding: 0 12px;
    font-size: 0.72rem;
}

.badge {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 4px 10px;
    border-radius: 999px;
    font-size: 0.7rem;
    font-weight: 700;
    border: 1px solid transparent;
    white-space: nowrap;
}

.badge::before {
    content: "";
    width: 6px;
    height: 6px;
    border-radius: 999px;
    background: currentColor;
}

.badge.pending {
    background: #fff4e6;
    color: var(--amber);
    border-color: #ffd9a0;
}

.badge.review {
    background: #e8f0fe;
    color: var(--blue);
    border-color: #a8c4f0;
}

.badge.approved {
    background: #e8f5ee;
    color: var(--green);
    border-color: #a8dcc0;
}

.badge.urgent {
    background: #fdecea;
    color: var(--red);
    border-color: #f5b8b4;
}

.sla-indicator {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 4px 10px;
    border-radius: 999px;
    font-size: 0.68rem;
    font-weight: 700;
    border: 1px solid transparent;
    white-space: nowrap;
}

.sla-warn {
    background: #fff7eb;
    color: var(--amber);
    border-color: #fde1b0;
}

.sla-ok {
    background: #ecf7f0;
    color: var(--green);
    border-color: #ccead8;
}

.sla-breach {
    background: #fdecea;
    color: var(--red);
    border-color: #f5b8b4;
}

.file-meta-grid,
.detail-meta-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 14px 18px;
}

.meta-item,
.detail-meta-item {
    padding: 14px;
    border-radius: var(--radius);
    background: linear-gradient(180deg, #ffffff 0%, #fafbfd 100%);
    border: 1px solid var(--gray-100);
}

.meta-item label,
.detail-label {
    margin: 0 0 4px;
    font-size: 0.68rem;
    font-weight: 700;
    color: var(--gray-500);
    text-transform: uppercase;
    letter-spacing: 0.14em;
    display: block;
}

.meta-item span,
.detail-value {
    margin: 0;
    font-size: 0.87rem;
    font-weight: 600;
    color: var(--text-primary);
}

.meta-link-button {
    border: none;
    background: transparent;
    padding: 0;
    font-size: 0.84rem;
    font-weight: 600;
    color: var(--blue);
    cursor: pointer;
}

.meta-link-button:hover {
    text-decoration: underline;
}

.priority-trigger {
    min-height: 30px;
    padding: 0 10px;
    border-radius: 999px;
    border: 1px solid transparent;
    background: var(--white);
    font-size: 0.7rem;
    font-weight: 700;
    cursor: pointer;
}

.priority-high {
    color: var(--red);
    background: #fdecea;
    border-color: #f5b8b4;
}

.priority-medium {
    color: var(--amber);
    background: #fff4e6;
    border-color: #ffd9a0;
}

.priority-low {
    color: var(--blue);
    background: #e8f0fe;
    border-color: #a8c4f0;
}

.meta-dropdown {
    position: absolute;
    left: 0;
    z-index: 50;
    margin-top: 8px;
    width: 150px;
    border-radius: 16px;
    border: 1px solid var(--gray-100);
    background: var(--white);
    padding: 6px;
    box-shadow: var(--shadow-lg);
}

.meta-dropdown-wide {
    width: 260px;
}

.meta-dropdown-title {
    margin: 0 0 8px;
    padding: 0 8px 8px;
    border-bottom: 1px solid var(--gray-100);
    font-size: 0.64rem;
    font-weight: 700;
    color: var(--gray-500);
    text-transform: uppercase;
    letter-spacing: 0.18em;
}

.meta-dropdown-list {
    max-height: 192px;
    overflow-y: auto;
}

.meta-dropdown-item {
    width: 100%;
    border: none;
    background: transparent;
    border-radius: 12px;
    padding: 10px 12px;
    text-align: left;
    font-size: 0.78rem;
    font-weight: 600;
    color: var(--text-secondary);
    cursor: pointer;
}

.meta-dropdown-item:hover {
    background: var(--gray-50);
}

.meta-dropdown-item.danger {
    color: var(--red);
}

.meta-dropdown-item.warning {
    color: var(--amber);
}

.meta-dropdown-item.info {
    color: var(--blue);
}

.meta-dropdown-empty {
    display: block;
    padding: 8px 10px;
    font-size: 0.74rem;
    color: var(--gray-500);
}

.amount-inline {
    display: inline-flex;
    align-items: center;
    gap: 8px;
}

.amount-symbol {
    color: var(--green);
    font-weight: 700;
}

.amount-input {
    width: 128px;
    min-height: 34px;
    border-radius: 8px;
    border: 1px solid var(--gray-200);
    padding: 0 10px;
    font-size: 0.82rem;
    font-weight: 700;
    color: var(--green);
}

.amount-input:focus {
    outline: none;
    border-color: var(--navy-light);
}

.doc-preview {
    margin-top: 16px;
    min-height: 240px;
    border-radius: var(--radius-md);
    border: 1px solid var(--gray-200);
    background: var(--gray-50);
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    text-align: center;
    gap: 10px;
    padding: 24px;
}

.doc-preview .doc-icon {
    width: 54px;
    height: 54px;
    border-radius: 16px;
    background: var(--white);
    color: var(--blue);
    box-shadow: var(--shadow-sm);
    display: inline-flex;
    align-items: center;
    justify-content: center;
    font-size: 1.4rem;
}

.doc-preview .doc-label {
    margin: 0;
    font-size: 0.84rem;
    font-weight: 700;
    color: var(--text-primary);
}

.doc-preview .doc-sub {
    margin: 0;
    font-size: 0.72rem;
    color: var(--gray-500);
}

.action-bar {
    display: flex;
    gap: 10px;
    flex-wrap: wrap;
    margin-top: 16px;
}

.noting-thread {
    display: flex;
    flex-direction: column;
    gap: 12px;
    max-height: 420px;
    overflow-y: auto;
    padding-right: 4px;
}

.note-item {
    display: flex;
    gap: 12px;
    align-items: flex-start;
}

.note-avatar {
    width: 34px;
    height: 34px;
    border-radius: 50%;
    background: var(--blue);
    color: var(--white);
    font-size: 0.72rem;
    font-weight: 700;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
}

.note-bubble {
    flex: 1;
    background: var(--gray-50);
    border: 1px solid var(--gray-200);
    border-radius: 0 var(--radius-md) var(--radius-md) var(--radius-md);
    padding: 12px 14px;
}

.note-bubble.own {
    background: #fff9f1;
    border-color: #f3d8aa;
}

.note-meta {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    align-items: center;
    margin-bottom: 6px;
}

.note-author {
    font-size: 0.78rem;
    font-weight: 700;
    color: var(--text-primary);
}

.note-role {
    font-size: 0.68rem;
    color: var(--gray-500);
}

.note-time {
    margin-left: auto;
    font-size: 0.66rem;
    color: var(--gray-500);
}

.note-text {
    margin: 0;
    font-size: 0.82rem;
    color: var(--text-secondary);
}

.note-seal {
    margin-top: 8px;
    display: inline-flex;
    align-items: center;
    gap: 6px;
    font-size: 0.66rem;
    color: var(--green);
    font-weight: 700;
}

.note-input-area {
    margin-top: 16px;
}

.note-input {
    width: 100%;
    min-height: 82px;
    border-radius: var(--radius);
    border: 1.5px solid var(--gray-200);
    background: var(--white);
    padding: 12px 14px;
    font-size: 0.84rem;
    resize: vertical;
}

.note-input:focus {
    outline: none;
    border-color: var(--navy-light);
    box-shadow: 0 0 0 3px rgba(30, 58, 95, 0.08);
}

.note-actions {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 12px;
    margin-top: 10px;
    flex-wrap: wrap;
}

.note-chip {
    border: none;
    background: var(--gray-50);
    color: var(--gray-700);
    border: 1px solid var(--gray-200);
    cursor: pointer;
}

.note-chip:hover {
    background: var(--white);
}

.timeline {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.timeline-item {
    display: flex;
    gap: 12px;
    position: relative;
    padding-bottom: 14px;
}

.timeline-item:last-child {
    padding-bottom: 0;
}

.timeline-item:not(:last-child)::before {
    content: "";
    position: absolute;
    top: 36px;
    left: 16px;
    bottom: 0;
    width: 2px;
    background: var(--gray-200);
}

.timeline-avatar {
    width: 34px;
    height: 34px;
    border-radius: 50%;
    color: var(--white);
    display: inline-flex;
    align-items: center;
    justify-content: center;
    font-size: 0.72rem;
    font-weight: 700;
    flex-shrink: 0;
    position: relative;
    z-index: 1;
}

.timeline-avatar.navy {
    background: var(--navy-light);
}

.timeline-avatar.blue {
    background: var(--blue);
}

.timeline-avatar.amber {
    background: var(--amber);
}

.timeline-avatar.green {
    background: var(--green);
}

.timeline-avatar.gray {
    background: var(--gray-300);
    color: var(--gray-700);
}

.timeline-content {
    flex: 1;
    min-width: 0;
}

.timeline-header {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 10px;
}

.timeline-action {
    font-size: 0.8rem;
    font-weight: 700;
    color: var(--text-primary);
}

.timeline-time {
    font-size: 0.68rem;
    color: var(--gray-500);
    font-weight: 600;
}

.timeline-officer {
    font-size: 0.76rem;
    color: var(--text-secondary);
    margin-top: 2px;
}

.timeline-note {
    margin-top: 8px;
    padding: 8px 10px;
    border-radius: 10px;
    background: var(--gray-50);
    border-left: 3px solid var(--gray-300);
    font-size: 0.74rem;
    color: var(--text-secondary);
    line-height: 1.5;
}

.timeline-note.green-border {
    border-left-color: var(--green);
}

.timeline-note.amber-border {
    border-left-color: var(--amber);
}

.timeline-note.red-border {
    border-left-color: var(--red);
}

.timeline-pagination {
    margin-top: 18px;
    padding-top: 16px;
    border-top: 1px solid var(--gray-100);
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    flex-wrap: wrap;
}

.timeline-pagination-copy {
    margin: 0;
    font-size: 0.72rem;
    color: var(--gray-500);
    font-weight: 600;
}

.timeline-pagination-links {
    display: flex;
    align-items: center;
    gap: 8px;
    flex-wrap: wrap;
}

.timeline-page-btn,
.timeline-page-ellipsis {
    min-width: 34px;
    min-height: 34px;
    padding: 0 12px;
    border-radius: 10px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    font-size: 0.72rem;
    font-weight: 700;
}

.timeline-page-btn {
    border: 1px solid var(--gray-200);
    background: var(--white);
    color: var(--text-secondary);
    transition: all var(--transition);
}

.timeline-page-btn:hover {
    background: var(--gray-50);
}

.timeline-page-btn.is-active {
    background: linear-gradient(135deg, var(--saffron), var(--saffron-light));
    border-color: transparent;
    color: var(--white);
    box-shadow: 0 8px 18px rgba(255, 107, 0, 0.2);
}

.timeline-page-btn.is-disabled {
    background: var(--gray-50);
    color: var(--gray-300);
    cursor: not-allowed;
}

.timeline-page-ellipsis {
    color: var(--gray-400);
}

.attachment-list {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.attachment-item {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 8px 10px;
    background: var(--gray-50);
    border-radius: var(--radius);
    border: 1px solid var(--gray-200);
}

.attachment-icon {
    width: 38px;
    height: 38px;
    border-radius: 12px;
    background: var(--white);
    color: var(--blue);
    display: inline-flex;
    align-items: center;
    justify-content: center;
    box-shadow: var(--shadow-sm);
    flex-shrink: 0;
}

.attachment-copy {
    flex: 1;
    min-width: 0;
}

.attachment-title {
    font-size: 0.78rem;
    font-weight: 600;
    color: var(--text-primary);
    word-break: break-word;
}

.attachment-meta {
    font-size: 0.68rem;
    color: var(--gray-500);
    margin-top: 2px;
}

.upload-zone {
    position: relative;
    overflow: hidden;
    border: 2px dashed var(--gray-300);
    border-radius: var(--radius-lg);
    background: linear-gradient(180deg, #fbfcfe 0%, #f6f8fc 100%);
    padding: 46px 20px;
    text-align: center;
    transition: all var(--transition);
}

.upload-zone.active,
.upload-zone:hover {
    border-color: var(--saffron);
    background: linear-gradient(180deg, #fff8f2 0%, #fbfcfe 100%);
}

.upload-zone-icon {
    width: 74px;
    height: 74px;
    border-radius: 50%;
    background: var(--white);
    color: var(--navy-light);
    box-shadow: var(--shadow-sm);
    display: inline-flex;
    align-items: center;
    justify-content: center;
    font-size: 1.7rem;
    margin-bottom: 16px;
}

.upload-zone h3,
.upload-zone p {
    margin: 0;
}

.upload-zone h3 {
    font-size: 0.98rem;
    color: var(--text-primary);
}

.upload-zone p {
    margin-top: 6px;
    font-size: 0.76rem;
    color: var(--gray-500);
}

.upload-file-item {
    display: flex;
    align-items: center;
    gap: 14px;
    padding: 14px;
    border: 1px solid var(--gray-100);
    border-radius: var(--radius-md);
    background: var(--white);
}

.upload-file-icon {
    width: 42px;
    height: 42px;
    border-radius: 12px;
    background: #eef4ff;
    color: var(--blue);
    display: inline-flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
}

.login-shell {
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 24px;
    background: linear-gradient(145deg, var(--navy) 0%, #0d2447 54%, #18345a 100%);
    position: relative;
    overflow: hidden;
}

.login-shell::before,
.login-shell::after {
    content: "";
    position: absolute;
    border-radius: 999px;
    filter: blur(10px);
}

.login-shell::before {
    top: -90px;
    left: -70px;
    width: 280px;
    height: 280px;
    background: radial-gradient(circle, rgba(255, 107, 0, 0.14), transparent 70%);
}

.login-shell::after {
    right: -90px;
    bottom: -100px;
    width: 320px;
    height: 320px;
    background: radial-gradient(circle, rgba(201, 168, 76, 0.12), transparent 72%);
}

.login-shell-bar {
    position: absolute;
    left: 0;
    right: 0;
    bottom: 0;
    height: 3px;
    background: linear-gradient(90deg, var(--saffron), var(--white), var(--green));
}

.login-gov-banner {
    position: absolute;
    top: 28px;
    left: 50%;
    transform: translateX(-50%);
    display: flex;
    align-items: center;
    gap: 10px;
    color: rgba(255, 255, 255, 0.78);
    font-size: 0.76rem;
    text-align: left;
}

.login-gov-banner strong {
    display: block;
}

.login-card {
    position: relative;
    z-index: 1;
    width: min(100%, 480px);
    padding: 34px 34px 30px;
    border-radius: 24px;
    background: rgba(255, 255, 255, 0.97);
    box-shadow: 0 26px 64px rgba(0, 0, 0, 0.34);
    margin-top: 40px;
}

.login-brand {
    display: flex;
    align-items: center;
    gap: 14px;
    margin-bottom: 10px;
}

.login-brand-icon {
    width: 56px;
    height: 56px;
    border-radius: 14px;
    background: linear-gradient(135deg, var(--saffron), var(--gold));
    display: inline-flex;
    align-items: center;
    justify-content: center;
    color: var(--white);
    font-size: 1.5rem;
    box-shadow: 0 8px 18px rgba(255, 107, 0, 0.26);
}

.login-brand h1 {
    margin: 0;
    font-size: 1.5rem;
    font-weight: 700;
    color: var(--navy);
}

.login-brand p {
    margin: 4px 0 0;
    font-size: 0.7rem;
    color: var(--gray-500);
    letter-spacing: 0.02em;
}

.login-divider {
    height: 1px;
    background: var(--gray-100);
    margin: 18px 0;
}

.login-subtitle {
    margin: 0 0 20px;
    color: var(--gray-500);
    font-size: 0.85rem;
}

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

.login-footer {
    margin-top: 18px;
    font-size: 0.7rem;
    text-align: center;
    color: var(--gray-500);
}

.login-footer strong {
    color: var(--red);
    font-weight: 700;
}

.input-field-custom {
    width: 100%;
    min-height: 46px;
    border: 1px solid var(--gray-200);
    border-radius: 12px;
    background: var(--gray-50);
    padding: 0 16px;
    color: var(--text-primary);
    font-size: 0.9rem;
    transition: all var(--transition);
}

.input-field-custom:focus {
    outline: none;
    background: var(--white);
    border-color: var(--navy-light);
    box-shadow: 0 0 0 4px rgba(255, 107, 0, 0.08);
}

.lang-btn.active {
    box-shadow: var(--shadow-sm);
}

@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(8px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.animate-fade-in {
    animation: fadeIn 0.3s ease-out forwards;
}

/* Local utility fallback for layouts that previously depended on the Tailwind CDN. */
.mobile-toggle {
    display: none;
}

.hidden {
    display: none !important;
}

.block {
    display: block;
}

.flex {
    display: flex;
}

.grid {
    display: grid;
}

.fixed {
    position: fixed;
}

.absolute {
    position: absolute;
}

.relative {
    position: relative;
}

.opacity-0 {
    opacity: 0 !important;
}

.inset-0 {
    top: 0;
    right: 0;
    bottom: 0;
    left: 0;
}

.left-0 {
    left: 0;
}

.z-20 {
    z-index: 20;
}

.z-40 {
    z-index: 40;
}

.z-50 {
    z-index: 50;
}

.z-\[100\] {
    z-index: 100;
}

.z-\[110\] {
    z-index: 110;
}

.flex-col {
    flex-direction: column;
}

.flex-1 {
    flex: 1 1 0%;
}

.items-center {
    align-items: center;
}

.items-start {
    align-items: flex-start;
}

.items-end {
    align-items: flex-end;
}

.justify-between {
    justify-content: space-between;
}

.justify-center {
    justify-content: center;
}

.justify-end {
    justify-content: flex-end;
}

.gap-1 {
    gap: 0.25rem;
}

.gap-2 {
    gap: 0.5rem;
}

.gap-3 {
    gap: 0.75rem;
}

.gap-4 {
    gap: 1rem;
}

.gap-5 {
    gap: 1.25rem;
}

.space-y-3> :not([hidden])~ :not([hidden]) {
    margin-top: 0.75rem;
}

.mx-auto {
    margin-left: auto;
    margin-right: auto;
}

.mt-1 {
    margin-top: 0.25rem;
}

.mt-2 {
    margin-top: 0.5rem;
}

.mt-4 {
    margin-top: 1rem;
}

.mt-5 {
    margin-top: 1.25rem;
}

.mt-6 {
    margin-top: 1.5rem;
}

.mb-2 {
    margin-bottom: 0.5rem;
}

.mb-3 {
    margin-bottom: 0.75rem;
}

.mb-4 {
    margin-bottom: 1rem;
}

.mb-5 {
    margin-bottom: 1.25rem;
}

.mb-6 {
    margin-bottom: 1.5rem;
}

.p-1 {
    padding: 0.25rem;
}

.p-2 {
    padding: 0.5rem;
}

.p-3 {
    padding: 0.75rem;
}

.p-4 {
    padding: 1rem;
}

.p-5 {
    padding: 1.25rem;
}

.px-1 {
    padding-left: 0.25rem;
    padding-right: 0.25rem;
}

.px-2 {
    padding-left: 0.5rem;
    padding-right: 0.5rem;
}

.px-3 {
    padding-left: 0.75rem;
    padding-right: 0.75rem;
}

.px-3\.5 {
    padding-left: 0.875rem;
    padding-right: 0.875rem;
}

.py-1 {
    padding-top: 0.25rem;
    padding-bottom: 0.25rem;
}

.py-2 {
    padding-top: 0.5rem;
    padding-bottom: 0.5rem;
}

.pt-2\.5 {
    padding-top: 0.625rem;
}

.pb-2 {
    padding-bottom: 0.5rem;
}

.pl-8 {
    padding-left: 2rem;
}

.pr-8 {
    padding-right: 2rem;
}

.w-full {
    width: 100%;
}

.w-64 {
    width: 16rem;
}

.w-36 {
    width: 9rem;
}

.w-28 {
    width: 7rem;
}

.w-12 {
    width: 3rem;
}

.w-10 {
    width: 2.5rem;
}

.w-5 {
    width: 1.25rem;
}

.w-2 {
    width: 0.5rem;
}

.w-2\.5 {
    width: 0.625rem;
}

.h-full {
    height: 100%;
}

.h-10 {
    height: 2.5rem;
}

.h-9 {
    height: 2.25rem;
}

.h-5 {
    height: 1.25rem;
}

.h-2 {
    height: 0.5rem;
}

.h-2\.5 {
    height: 0.625rem;
}

.min-w-0 {
    min-width: 0;
}

.max-w-\[360px\] {
    max-width: 360px;
}

.max-h-48 {
    max-height: 12rem;
}

.min-h-0 {
    min-height: 0;
}

.min-h-\[680px\] {
    min-height: 680px;
}

.min-h-\[760px\] {
    min-height: 760px;
}

.overflow-auto {
    overflow: auto;
}

.overflow-y-auto {
    overflow-y: auto;
}

.cursor-pointer {
    cursor: pointer;
}

.cursor-not-allowed {
    cursor: not-allowed;
}

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

.text-right {
    text-align: right;
}

.text-center {
    text-align: center;
}

.text-sm {
    font-size: 0.875rem;
}

.text-2xl {
    font-size: 1.5rem;
}

.text-\[11px\] {
    font-size: 11px;
}

.text-\[0\.64rem\] {
    font-size: 0.64rem;
}

.text-\[0\.7rem\] {
    font-size: 0.7rem;
}

.text-\[0\.72rem\] {
    font-size: 0.72rem;
}

.text-\[0\.75rem\] {
    font-size: 0.75rem;
}

.text-\[0\.78rem\] {
    font-size: 0.78rem;
}

.font-bold {
    font-weight: 700;
}

.font-semibold {
    font-weight: 600;
}

.uppercase {
    text-transform: uppercase;
}

.tracking-\[0\.14em\] {
    letter-spacing: 0.14em;
}

.tracking-\[0\.16em\] {
    letter-spacing: 0.16em;
}

.tracking-\[0\.18em\] {
    letter-spacing: 0.18em;
}

.truncate {
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.whitespace-nowrap {
    white-space: nowrap;
}

.rounded {
    border-radius: 0.25rem;
}

.rounded-md {
    border-radius: 0.375rem;
}

.rounded-lg {
    border-radius: 0.5rem;
}

.rounded-xl {
    border-radius: 0.75rem;
}

.rounded-2xl {
    border-radius: 1rem;
}

.rounded-full {
    border-radius: 9999px;
}

.rounded-\[14px\] {
    border-radius: 14px;
}

.border {
    border-width: 1px;
    border-style: solid;
    border-color: var(--gray-200);
}

.border-b {
    border-bottom-width: 1px;
    border-bottom-style: solid;
    border-bottom-color: var(--gray-100);
}

.border-4 {
    border-width: 4px;
    border-style: solid;
}

.border-dashed {
    border-style: dashed;
}

.border-transparent {
    border-color: transparent;
}

.border-slate-50 {
    border-color: var(--gray-100);
}

.border-slate-100 {
    border-color: var(--gray-100);
}

.border-slate-200 {
    border-color: var(--gray-200);
}

.border-slate-300 {
    border-color: var(--gray-300);
}

.border-orange-400 {
    border-color: var(--saffron-light);
}

.border-orange-500 {
    border-color: var(--saffron);
}

.border-amber-100 {
    border-color: #f7e0b0;
}

.border-emerald-100 {
    border-color: #bee6d0;
}

.bg-white {
    background: #ffffff;
}

.bg-white\/75 {
    background: rgba(255, 255, 255, 0.75);
}

.bg-slate-50 {
    background: var(--gray-50);
}

.bg-slate-900\/60 {
    background: rgba(10, 22, 40, 0.6);
}

.bg-orange-500 {
    background: var(--saffron);
}

.bg-orange-50 {
    background: #fff4e6;
}

.bg-red-50 {
    background: #fdecea;
}

.bg-amber-50 {
    background: #fff4e6;
}

.bg-emerald-50 {
    background: #e8f5ee;
}

.text-white {
    color: #ffffff;
}

.text-slate-300 {
    color: var(--gray-300);
}

.text-slate-400 {
    color: var(--gray-500);
}

.text-slate-500 {
    color: var(--gray-500);
}

.text-slate-600 {
    color: var(--text-secondary);
}

.text-slate-700 {
    color: var(--gray-700);
}

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

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

.text-orange-300 {
    color: #ffb37b;
}

.text-orange-400 {
    color: var(--saffron-light);
}

.text-orange-500 {
    color: var(--saffron);
}

.text-orange-600 {
    color: #cf5a00;
}

.text-blue-500 {
    color: var(--blue);
}

.text-blue-600 {
    color: var(--blue);
}

.text-blue-700 {
    color: #104b90;
}

.text-emerald-500 {
    color: var(--green-light);
}

.text-emerald-600 {
    color: var(--green);
}

.text-red-500 {
    color: var(--red-light);
}

.text-red-600 {
    color: var(--red);
}

.text-yellow-400 {
    color: #d5a400;
}

.backdrop-blur-sm {
    backdrop-filter: blur(4px);
    -webkit-backdrop-filter: blur(4px);
}

.backdrop-blur-md {
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
}

.backdrop-blur-\[2px\] {
    backdrop-filter: blur(2px);
    -webkit-backdrop-filter: blur(2px);
}

.shadow-xl {
    box-shadow: var(--shadow-lg);
}

.transition,
.transition-all {
    transition: all var(--transition);
}

.animate-spin {
    animation: spin 1s linear infinite;
}

.animate-pulse {
    animation: pulse 1.5s ease-in-out infinite;
}

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

@keyframes pulse {

    0%,
    100% {
        opacity: 1;
    }

    50% {
        opacity: 0.55;
    }
}

@media (min-width: 640px) {
    .sm\:flex-row {
        flex-direction: row;
    }

    .sm\:items-center {
        align-items: center;
    }

    .sm\:justify-between {
        justify-content: space-between;
    }

    .sm\:grid-cols-2 {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    .sm\:grid-cols-3 {
        grid-template-columns: repeat(3, minmax(0, 1fr));
    }
}

@media (min-width: 768px) {
    .md\:grid-cols-2 {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }
}

@media (min-width: 1280px) {
    .xl\:grid-cols-3 {
        grid-template-columns: repeat(3, minmax(0, 1fr));
    }

    .xl\:grid-cols-4 {
        grid-template-columns: repeat(3, minmax(0, 1fr));
    }

    .xl\:grid-cols-\[300px_minmax\(0\,1fr\)\] {
        grid-template-columns: 300px minmax(0, 1fr);
    }

    .xl\:grid-cols-\[minmax\(0\,1\.7fr\)_340px\] {
        grid-template-columns: minmax(0, 1.7fr) 340px;
    }

    .xl\:grid-cols-\[minmax\(0\,1fr\)_minmax\(0\,1fr\)\] {
        grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
    }
}

@media (min-width: 1024px) {
    .app-main {
        margin-left: var(--sidebar-width);
    }

    .page-container {
        padding: 24px 24px 36px;
    }
}

@media (max-width: 1180px) {
    .metric-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    .content-grid-aside,
    .detail-layout,
    .file-detail-layout {
        grid-template-columns: 1fr;
    }
}

@media (max-width: 1023px) {
    .mobile-toggle {
        display: inline-flex;
    }

    .app-main {
        margin-left: 0;
    }

    #sidebar {
        width: min(86vw, 320px);
        transform: translateX(-100%);
        transition: transform var(--transition);
    }

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

    .header-search {
        display: none;
    }
}

@media (max-width: 860px) {

    .content-grid-two,
    .metric-grid,
    .form-grid,
    .file-meta-grid {
        grid-template-columns: 1fr;
    }

    .page-hero-inner,
    .table-toolbar,
    .panel-toolbar,
    .app-header,
    .file-detail-header,
    .panel-header,
    .note-actions {
        flex-direction: column;
        align-items: flex-start;
    }

    .page-actions,
    .app-header-right,
    .section-actions {
        width: 100%;
        justify-content: flex-start;
    }

    .app-header-right {
        flex-wrap: wrap;
    }

    .table-filters {
        width: 100%;
    }

    .file-detail-header-actions,
    .action-bar {
        width: 100%;
    }
}

@media (max-width: 640px) {
    .page-container {
        padding: 16px 14px 24px;
    }

    .page-hero {
        padding: 20px 18px;
        border-radius: 18px;
    }

    .login-card {
        padding: 28px 22px 24px;
    }

    .login-gov-banner {
        width: calc(100% - 36px);
        top: 18px;
    }

    .folder-link,
    .surface-body,
    .surface-header,
    .panel-body,
    .panel-header,
    .table-toolbar {
        padding-left: 14px;
        padding-right: 14px;
    }

    .page-actions {
        flex-direction: column;
        align-items: stretch;
    }

    .page-actions .action-button,
    .section-actions .section-action-btn,
    .btn-row .btn {
        width: 100%;
        justify-content: center;
    }

    .app-header {
        padding: 10px 14px;
        height: auto;
    }

    .app-header-left,
    .app-header-right {
        width: 100%;
    }

    .timeline-header,
    .timeline-pagination {
        flex-direction: column;
        align-items: flex-start;
    }

    .page-breadcrumb,
    .file-detail-title-row,
    .attachment-item {
        flex-wrap: wrap;
    }

    .timeline-pagination-links {
        width: 100%;
    }

    thead th,
    tbody td {
        padding-left: 10px;
        padding-right: 10px;
    }
}

/* Scrollbars */
.custom-scrollbar::-webkit-scrollbar,
::-webkit-scrollbar {
    width: 6px;
    height: 6px;
}

.custom-scrollbar::-webkit-scrollbar-track,
::-webkit-scrollbar-track {
    background: transparent;
}

.custom-scrollbar::-webkit-scrollbar-thumb,
::-webkit-scrollbar-thumb {
    background: rgba(122, 132, 154, 0.28);
    border-radius: 999px;
}

.custom-scrollbar::-webkit-scrollbar-thumb:hover,
::-webkit-scrollbar-thumb:hover {
    background: rgba(122, 132, 154, 0.5);
}