:root {
    --border: #d9dee7;
    --text: #1f2937;
    --muted: #667085;
    --surface: #ffffff;
    --sidebar: #171717;
    --blue: #0d6efd;
}

body {
    color: var(--text);
    background: #f3f5f8;
    font-size: 14px;
}

.app-shell {
    min-height: 100vh;
    display: flex;
}

.sidebar {
    width: 250px;
    background: var(--sidebar);
    color: #fff;
    flex: 0 0 250px;
}

.brand {
    height: 58px;
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 0 18px;
    border-bottom: 1px solid rgba(255, 255, 255, .14);
    font-weight: 700;
}

.brand img {
    width: 34px;
    height: 34px;
    object-fit: contain;
    border-radius: 6px;
    background: #fff;
}

.user-panel {
    display: flex;
    gap: 10px;
    align-items: center;
    padding: 18px;
    background: rgba(255, 255, 255, .06);
}

.user-panel i { font-size: 28px; }

.nav-menu { padding: 12px; }
.nav-section {
    color: #c8ced8;
    font-size: 12px;
    text-transform: uppercase;
    margin: 14px 8px 6px;
}

.nav-menu a {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 9px 10px;
    color: #f5f5f5;
    text-decoration: none;
    border-radius: 6px;
}

.nav-menu a:hover { background: rgba(255, 255, 255, .1); }
.nav-menu i { width: 18px; }

.main-content {
    min-width: 0;
    flex: 1;
    display: flex;
    flex-direction: column;
}

.topbar {
    height: 58px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 0 18px;
    background: #fff;
    border-bottom: 1px solid var(--border);
}

.content-wrap { padding: 18px; flex: 1; }
.page-title-row {
    display: flex;
    justify-content: space-between;
    gap: 12px;
    align-items: center;
    margin-bottom: 14px;
}

.page-title-row h1 { font-size: 24px; margin: 0; font-weight: 700; }
.breadcrumb-lite { color: var(--muted); font-size: 13px; }

.panel {
    background: var(--surface);
    border: 1px solid var(--border);
    border-radius: 6px;
    padding: 16px;
}

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

.panel-toolbar h2 { font-size: 18px; margin: 0; }
.panel-toolbar p { color: var(--muted); margin: 3px 0 0; }
.panel-title { font-weight: 700; margin-bottom: 12px; }

.stat-grid {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 14px;
}

.stat-card {
    background: #fff;
    border: 1px solid var(--border);
    border-radius: 6px;
    padding: 18px;
    display: grid;
    grid-template-columns: 1fr auto;
    gap: 6px;
    align-items: center;
}

.stat-card strong { font-size: 32px; line-height: 1; }
.stat-card span { color: var(--muted); }
.stat-card i { grid-row: 1 / span 2; grid-column: 2; font-size: 28px; }

.table-actions { display: inline-flex; gap: 6px; }
.empty-state {
    border: 1px dashed var(--border);
    color: var(--muted);
    padding: 26px;
    text-align: center;
    border-radius: 6px;
    background: #fafbfc;
}

.bar-row { display: grid; grid-template-columns: 160px 1fr 70px; gap: 10px; align-items: center; margin: 12px 0; }
.bar-row div { height: 18px; border: 1px solid #b7c6e7; background: #eef4ff; }
.bar-row b { display: block; height: 100%; background: repeating-linear-gradient(135deg, #7aa8ff, #7aa8ff 4px, #4f83e6 4px, #4f83e6 8px); }
.bar-row em { font-style: normal; color: var(--muted); text-align: right; }
.compact-list { padding-left: 18px; }
.tips-box { background: #fff; border: 1px solid var(--border); border-radius: 6px; padding: 14px 16px; }
.tips-box i { color: #f59f00; margin-right: 8px; }
.footer { display: flex; justify-content: space-between; border-top: 1px solid var(--border); padding: 12px 18px; background: #fff; color: var(--muted); }

.login-page { min-height: 100vh; display: grid; place-items: center; background: #fff; }
.login-shell { width: min(980px, 92vw); display: grid; grid-template-columns: 1.1fr .9fr; gap: 70px; align-items: center; }
.login-copy h1 { font-size: 52px; font-weight: 800; margin-bottom: 28px; }
.login-copy p { font-size: 18px; line-height: 1.7; max-width: 520px; }
.login-panel h2 { font-size: 34px; font-weight: 800; }
.login-panel p { color: var(--muted); }
.login-panel small { display: block; margin-top: 36px; color: var(--muted); }
.input-icon { position: relative; }
.input-icon i { position: absolute; left: 12px; top: 50%; transform: translateY(-50%); color: #6b7280; }
.input-icon .form-control { padding-left: 38px; }
.login-page-v2 {
    background:
        linear-gradient(135deg, rgba(13, 110, 253, .08), rgba(25, 135, 84, .08)),
        #f5f7fb;
}
.login-card-v2 {
    width: min(1080px, 94vw);
    min-height: 620px;
    display: grid;
    grid-template-columns: 1.05fr .95fr;
    background: #fff;
    border: 1px solid var(--border);
    border-radius: 16px;
    overflow: hidden;
    box-shadow: 0 24px 70px rgba(15, 23, 42, .13);
}
.login-brand-panel {
    padding: 54px;
    display: flex;
    flex-direction: column;
    justify-content: center;
    background: #101828;
    color: #fff;
}
.login-logo-wrap {
    width: 82px;
    height: 82px;
    border-radius: 18px;
    display: grid;
    place-items: center;
    background: #fff;
    color: var(--blue);
    margin-bottom: 28px;
}
.login-logo-wrap img { width: 64px; height: 64px; object-fit: contain; }
.login-logo-wrap i { font-size: 34px; }
.login-kicker { color: #93c5fd; font-weight: 700; text-transform: uppercase; font-size: 12px; margin: 0 0 12px; }
.login-brand-panel h1 { font-size: 46px; font-weight: 800; margin: 0 0 12px; }
.login-brand-panel h2 { font-size: 21px; line-height: 1.45; font-weight: 600; margin: 0 0 16px; color: #e5e7eb; }
.login-brand-panel p { color: #cbd5e1; line-height: 1.75; max-width: 520px; }
.login-contact-list { display: grid; gap: 10px; margin-top: 26px; color: #dbeafe; }
.login-contact-list span { display: flex; gap: 10px; align-items: flex-start; }
.login-contact-list i { margin-top: 3px; color: #60a5fa; width: 16px; }
.login-form-panel { padding: 54px; display: flex; flex-direction: column; justify-content: center; }
.login-form-heading { display: flex; gap: 14px; align-items: flex-start; margin-bottom: 28px; }
.login-form-heading span { width: 44px; height: 44px; border-radius: 12px; display: grid; place-items: center; background: #eff6ff; color: var(--blue); }
.login-form-heading h2 { font-size: 28px; font-weight: 800; margin: 0; }
.login-form-heading p { margin: 4px 0 0; color: var(--muted); }
.login-form-panel small { display: block; margin-top: 28px; color: var(--muted); }
.auth-body-simdataker {
    min-height: 100vh;
    margin: 0;
    background: linear-gradient(135deg, #f0f9ff 0%, #ffffff 48%, #ecfdf5 100%);
    color: #1e293b;
    font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
    -webkit-font-smoothing: antialiased;
}
.auth-page-simdataker {
    min-height: 100vh;
    padding: 32px 16px;
    display: flex;
    align-items: center;
    justify-content: center;
}
.auth-card-simdataker {
    width: min(1152px, 100%);
    min-height: calc(100vh - 64px);
    display: grid;
    grid-template-columns: .95fr 1.05fr;
    overflow: hidden;
    border: 1px solid #e2e8f0;
    border-radius: 16px;
    background: #fff;
    box-shadow: 0 10px 30px rgba(15, 23, 42, .08);
}
.auth-info-simdataker {
    background: #0f172a;
    color: #fff;
    padding: 48px 40px;
}
.auth-info-inner {
    height: 100%;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    gap: 36px;
}
.auth-logo-simdataker,
.auth-logo-placeholder-simdataker {
    width: 96px;
    height: 96px;
    margin-bottom: 32px;
    border-radius: 16px;
    background: rgba(255, 255, 255, .1);
    border: 1px solid rgba(255, 255, 255, .1);
    object-fit: contain;
    padding: 8px;
}
.auth-logo-placeholder-simdataker {
    display: flex;
    align-items: center;
    justify-content: center;
    color: #bae6fd;
    background: rgba(14, 165, 233, .2);
    font-size: 42px;
}
.auth-info-simdataker h1 {
    margin: 0;
    font-size: 30px;
    line-height: 1.2;
    font-weight: 800;
    letter-spacing: 0;
}
.auth-info-simdataker p {
    max-width: 448px;
    margin: 16px 0 0;
    color: #cbd5e1;
    font-size: 14px;
    line-height: 1.65;
}
.auth-info-simdataker .auth-desc-simdataker {
    margin-top: 10px;
    color: #94a3b8;
}
.auth-feature-grid-simdataker {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 12px;
    color: #cbd5e1;
    font-size: 14px;
}
.auth-feature-grid-simdataker div {
    min-height: 104px;
    padding: 16px;
    border: 1px solid rgba(255, 255, 255, .1);
    border-radius: 12px;
    background: rgba(255, 255, 255, .05);
}
.auth-feature-grid-simdataker i {
    display: block;
    margin-bottom: 12px;
    color: #86efac;
    font-size: 20px;
}
.auth-feature-grid-simdataker div:nth-child(2) i { color: #7dd3fc; }
.auth-form-simdataker {
    padding: 32px 48px;
    display: flex;
    align-items: center;
}
.auth-form-box-simdataker {
    width: min(448px, 100%);
    margin: 0 auto;
}
.auth-form-heading-simdataker {
    margin-bottom: 32px;
    text-align: left;
}
.auth-lock-simdataker {
    width: 48px;
    height: 48px;
    margin-bottom: 16px;
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: #e0f2fe;
    color: #0284c7;
}
.auth-form-heading-simdataker h2 {
    margin: 0;
    color: #0f172a;
    font-size: 24px;
    line-height: 1.35;
    font-weight: 800;
}
.auth-form-heading-simdataker p {
    margin: 8px 0 0;
    color: #64748b;
    font-size: 14px;
}
.auth-login-form-simdataker {
    display: grid;
    gap: 20px;
}
.auth-login-form-simdataker label {
    display: block;
    margin-bottom: 6px;
    color: #334155;
    font-size: 14px;
    font-weight: 600;
}
.auth-input-wrap-simdataker {
    position: relative;
}
.auth-input-wrap-simdataker i {
    position: absolute;
    left: 12px;
    top: 50%;
    transform: translateY(-50%);
    color: #94a3b8;
    pointer-events: none;
}
.auth-input-wrap-simdataker input {
    width: 100%;
    min-height: 42px;
    border: 1px solid #cbd5e1;
    border-radius: 8px;
    padding: 10px 12px 10px 40px;
    color: #1e293b;
    font-size: 14px;
    outline: none;
    transition: border-color .15s ease, box-shadow .15s ease;
}
.auth-input-wrap-simdataker input:focus {
    border-color: #0ea5e9;
    box-shadow: 0 0 0 4px #e0f2fe;
}
.auth-submit-simdataker {
    width: 100%;
    min-height: 42px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    border: 0;
    border-radius: 8px;
    background: #0ea5e9;
    color: #fff;
    font-size: 14px;
    font-weight: 700;
    box-shadow: 0 1px 2px rgba(15, 23, 42, .08);
    transition: background .15s ease, box-shadow .15s ease;
}
.auth-submit-simdataker:hover { background: #0284c7; }
.auth-submit-simdataker:focus {
    outline: none;
    box-shadow: 0 0 0 4px #e0f2fe;
}
.auth-contact-simdataker {
    display: grid;
    gap: 4px;
    margin-top: 26px;
    color: #64748b;
    font-size: 12px;
}
.setup-card { width: min(520px, 92vw); background: #fff; border: 1px solid var(--border); padding: 24px; border-radius: 8px; }
.guide-list li { margin-bottom: 8px; }
.upload-box {
    border: 1px solid var(--border);
    border-radius: 8px;
    padding: 14px;
    background: #fafbfc;
}
.upload-preview-card {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 10px;
    border: 1px solid var(--border);
    border-radius: 8px;
    background: #fff;
}
.upload-preview-card img {
    width: 96px;
    height: 72px;
    object-fit: contain;
    border-radius: 6px;
    background: #f1f5f9;
}
.upload-preview-card.is-document i {
    width: 46px;
    height: 46px;
    display: grid;
    place-items: center;
    border-radius: 8px;
    background: #eef2ff;
    color: #4338ca;
    font-size: 22px;
}
.upload-preview-card span {
    min-width: 0;
    overflow-wrap: anywhere;
    color: var(--text);
}
.log-view {
    max-height: 68vh;
    overflow: auto;
    background: #111827;
    color: #d1d5db;
    border-radius: 6px;
    padding: 14px;
    font-size: 12px;
    line-height: 1.55;
    white-space: pre-wrap;
}

@media (max-width: 992px) {
    .sidebar { position: fixed; left: -260px; top: 0; bottom: 0; z-index: 1000; transition: left .2s ease; }
    .sidebar.is-open { left: 0; }
    .stat-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
    .login-shell { grid-template-columns: 1fr; gap: 28px; }
    .login-card-v2 { grid-template-columns: 1fr; }
    .login-brand-panel, .login-form-panel { padding: 34px; }
    .auth-card-simdataker { grid-template-columns: 1fr; min-height: auto; }
    .auth-info-simdataker { padding: 32px 24px; }
    .auth-form-simdataker { padding: 32px 24px; }
    .auth-logo-simdataker, .auth-logo-placeholder-simdataker { width: 80px; height: 80px; margin-bottom: 24px; }
    .auth-feature-grid-simdataker { grid-template-columns: 1fr; }
}

@media (max-width: 576px) {
    .stat-grid { grid-template-columns: 1fr; }
    .page-title-row, .panel-toolbar, .footer { flex-direction: column; align-items: flex-start; }
    .login-copy h1 { font-size: 40px; }
}

@media print {
    .sidebar, .topbar, .page-title-row, .btn, .dataTables_length, .dataTables_filter, .dataTables_info, .dataTables_paginate { display: none !important; }
    .main-content, .content-wrap { padding: 0; display: block; }
    .panel { border: none; }
}
