:root {
    --gp-black: #06070a;
    --gp-black-soft: #0d1016;
    --gp-panel: #121620;
    --gp-panel-2: #181d29;
    --gp-blue: #1769e0;
    --gp-blue-light: #3f8cff;
    --gp-silver: #d9dde5;
    --gp-muted: #8f98aa;
    --gp-white: #f8fafc;
    --gp-success: #35c779;
    --gp-warning: #f6b73c;
    --gp-danger: #ef5d67;
    --gp-border: rgba(255, 255, 255, .09);
    --gp-shadow: 0 18px 55px rgba(0, 0, 0, .32);
    --gp-radius: 16px;
}

* { box-sizing: border-box; }
html { min-height: 100%; background: var(--gp-black); }
body {
    margin: 0;
    min-height: 100vh;
    background:
        radial-gradient(circle at 85% 10%, rgba(23, 105, 224, .16), transparent 32%),
        linear-gradient(135deg, #080a0f 0%, #0c1018 52%, #07090d 100%);
    color: var(--gp-white);
    font-family: Inter, "Segoe UI", Roboto, Arial, sans-serif;
    font-size: 15px;
    line-height: 1.5;
}

a { color: inherit; text-decoration: none; }
button, input, select, textarea { font: inherit; }
button { cursor: pointer; }
img { max-width: 100%; }

.gp-shell { min-height: 100vh; }
.gp-sidebar {
    position: fixed;
    inset: 0 auto 0 0;
    width: 266px;
    z-index: 40;
    display: flex;
    flex-direction: column;
    padding: 22px 16px;
    background: rgba(5, 7, 11, .96);
    border-right: 1px solid var(--gp-border);
    backdrop-filter: blur(18px);
}
.gp-brand {
    display: block;
    padding: 7px 10px 18px;
    border-bottom: 1px solid var(--gp-border);
}
.gp-brand img {
    display: block;
    width: 205px;
    height: 82px;
    object-fit: cover;
    object-position: center 58%;
    border-radius: 12px;
}
.gp-brand small {
    display: block;
    margin-top: 8px;
    color: var(--gp-muted);
    letter-spacing: .11em;
    text-transform: uppercase;
    font-size: 10px;
}
.gp-nav { display: grid; gap: 6px; margin-top: 20px; }
.gp-nav-title {
    margin: 13px 12px 4px;
    color: #667084;
    font-size: 10px;
    font-weight: 800;
    letter-spacing: .16em;
    text-transform: uppercase;
}
.gp-nav-link {
    display: flex;
    align-items: center;
    gap: 12px;
    min-height: 44px;
    padding: 10px 12px;
    border-radius: 12px;
    color: #b5bdcb;
    font-weight: 650;
    transition: .18s ease;
}
.gp-nav-link:hover { background: rgba(255,255,255,.055); color: white; transform: translateX(2px); }
.gp-nav-link.active {
    color: white;
    background: linear-gradient(110deg, rgba(23,105,224,.95), rgba(22,72,155,.78));
    box-shadow: 0 10px 25px rgba(15, 83, 185, .25);
}
.gp-nav-icon {
    width: 28px;
    height: 28px;
    display: grid;
    place-items: center;
    border-radius: 8px;
    background: rgba(255,255,255,.07);
    font-size: 15px;
}
.gp-nav-badge {
    margin-left: auto;
    min-width: 22px;
    height: 22px;
    padding: 0 6px;
    display: grid;
    place-items: center;
    border-radius: 999px;
    background: var(--gp-danger);
    color: white;
    font-size: 11px;
    font-weight: 800;
}
.gp-sidebar-footer { margin-top: auto; padding-top: 14px; border-top: 1px solid var(--gp-border); }
.gp-user-card { display: flex; align-items: center; gap: 11px; padding: 10px; }
.gp-user-avatar {
    width: 36px;
    height: 36px;
    display: grid;
    place-items: center;
    border-radius: 50%;
    background: linear-gradient(145deg, var(--gp-blue-light), #173e86);
    font-weight: 850;
}
.gp-user-meta { min-width: 0; flex: 1; }
.gp-user-meta strong, .gp-user-meta small { display: block; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.gp-user-meta small { color: var(--gp-muted); font-size: 11px; }

.gp-main { min-height: 100vh; margin-left: 266px; }
.gp-topbar {
    position: sticky;
    top: 0;
    z-index: 25;
    min-height: 72px;
    padding: 14px 28px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 20px;
    background: rgba(8, 10, 15, .78);
    border-bottom: 1px solid var(--gp-border);
    backdrop-filter: blur(18px);
}
.gp-topbar-title h1 { margin: 0; font-size: 21px; line-height: 1.2; letter-spacing: -.02em; }
.gp-topbar-title p { margin: 4px 0 0; color: var(--gp-muted); font-size: 12px; }
.gp-topbar-actions { display: flex; align-items: center; gap: 9px; }
.gp-mobile-toggle { display: none; }
.gp-content { width: min(1540px, 100%); margin: 0 auto; padding: 28px; }

.gp-page-head {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 18px;
    margin-bottom: 22px;
}
.gp-page-head h2 { margin: 0; font-size: clamp(22px, 2vw, 30px); letter-spacing: -.035em; }
.gp-page-head p { margin: 7px 0 0; color: var(--gp-muted); max-width: 720px; }
.gp-actions { display: flex; flex-wrap: wrap; gap: 10px; }

.gp-btn {
    min-height: 42px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    padding: 9px 15px;
    border: 1px solid transparent;
    border-radius: 11px;
    font-weight: 750;
    transition: .18s ease;
    white-space: nowrap;
}
.gp-btn:hover { transform: translateY(-1px); filter: brightness(1.06); }
.gp-btn-primary { color: white; background: linear-gradient(120deg, var(--gp-blue), #1150ad); box-shadow: 0 10px 24px rgba(23,105,224,.22); }
.gp-btn-secondary { color: var(--gp-silver); background: rgba(255,255,255,.055); border-color: var(--gp-border); }
.gp-btn-danger { color: #ffdfe1; background: rgba(239,93,103,.13); border-color: rgba(239,93,103,.28); }
.gp-btn-success { color: #dbffeb; background: rgba(53,199,121,.15); border-color: rgba(53,199,121,.3); }
.gp-btn-sm { min-height: 34px; padding: 6px 10px; border-radius: 9px; font-size: 12px; }
.gp-icon-btn {
    width: 40px;
    height: 40px;
    display: grid;
    place-items: center;
    border: 1px solid var(--gp-border);
    border-radius: 11px;
    color: var(--gp-silver);
    background: rgba(255,255,255,.04);
}

.gp-card {
    background: linear-gradient(145deg, rgba(23,28,39,.93), rgba(13,16,23,.97));
    border: 1px solid var(--gp-border);
    border-radius: var(--gp-radius);
    box-shadow: var(--gp-shadow);
}
.gp-card-header {
    padding: 18px 20px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 14px;
    border-bottom: 1px solid var(--gp-border);
}
.gp-card-header h3 { margin: 0; font-size: 16px; }
.gp-card-body { padding: 20px; }
.gp-card-footer { padding: 14px 20px; border-top: 1px solid var(--gp-border); }

.gp-metrics { display: grid; grid-template-columns: repeat(5, minmax(0, 1fr)); gap: 14px; margin-bottom: 20px; }
.gp-metric { position: relative; min-height: 126px; padding: 18px; overflow: hidden; }
.gp-metric::after {
    content: "";
    position: absolute;
    width: 100px;
    height: 100px;
    right: -30px;
    top: -32px;
    border-radius: 50%;
    background: rgba(23,105,224,.14);
}
.gp-metric-label { color: var(--gp-muted); font-size: 12px; font-weight: 700; text-transform: uppercase; letter-spacing: .07em; }
.gp-metric-value { margin-top: 12px; font-size: clamp(25px, 2.5vw, 34px); font-weight: 850; letter-spacing: -.04em; }
.gp-metric-hint { margin-top: 5px; color: #788398; font-size: 11px; }
.gp-dashboard-grid { display: grid; grid-template-columns: 1.45fr .85fr; gap: 18px; }

.gp-toolbar {
    display: flex;
    align-items: center;
    gap: 10px;
    flex-wrap: wrap;
    margin-bottom: 16px;
}
.gp-search { position: relative; flex: 1 1 280px; }
.gp-search input { padding-left: 40px; }
.gp-search::before { content: "⌕"; position: absolute; left: 14px; top: 8px; color: var(--gp-muted); font-size: 20px; }

.gp-form-grid { display: grid; grid-template-columns: repeat(12, minmax(0, 1fr)); gap: 16px; }
.gp-col-12 { grid-column: span 12; }
.gp-col-8 { grid-column: span 8; }
.gp-col-6 { grid-column: span 6; }
.gp-col-4 { grid-column: span 4; }
.gp-col-3 { grid-column: span 3; }
.gp-col-2 { grid-column: span 2; }
.gp-field label { display: block; margin-bottom: 7px; color: #c9d0dc; font-size: 12px; font-weight: 750; }
.gp-required::after { content: " *"; color: var(--gp-danger); }
.gp-input, .gp-select, .gp-textarea {
    width: 100%;
    min-height: 43px;
    padding: 10px 12px;
    border: 1px solid rgba(255,255,255,.12);
    border-radius: 10px;
    outline: none;
    color: var(--gp-white);
    background: #0d1119;
    transition: .16s ease;
}
.gp-textarea { min-height: 105px; resize: vertical; }
.gp-input:focus, .gp-select:focus, .gp-textarea:focus { border-color: var(--gp-blue-light); box-shadow: 0 0 0 3px rgba(63,140,255,.12); }
.gp-input::placeholder, .gp-textarea::placeholder { color: #596276; }
.gp-select option { color: #111; background: white; }
.gp-help { margin-top: 6px; color: var(--gp-muted); font-size: 11px; }
.gp-error { margin-top: 6px; color: #ff9ca3; font-size: 12px; }
.gp-check { display: inline-flex; align-items: center; gap: 8px; min-height: 43px; color: #c9d0dc; }
.gp-check input { width: 17px; height: 17px; accent-color: var(--gp-blue); }
.gp-form-actions { display: flex; justify-content: flex-end; gap: 10px; padding-top: 18px; margin-top: 18px; border-top: 1px solid var(--gp-border); }

.gp-table-wrap { width: 100%; overflow-x: auto; }
.gp-table { width: 100%; border-collapse: collapse; min-width: 750px; }
.gp-table th, .gp-table td { padding: 13px 14px; text-align: left; border-bottom: 1px solid rgba(255,255,255,.065); vertical-align: middle; }
.gp-table th { color: #7f899c; font-size: 10px; text-transform: uppercase; letter-spacing: .1em; font-weight: 800; }
.gp-table td { color: #d7dce5; }
.gp-table tbody tr { transition: .15s ease; }
.gp-table tbody tr:hover { background: rgba(255,255,255,.025); }
.gp-table-actions { display: flex; align-items: center; justify-content: flex-end; gap: 7px; }
.gp-table strong { color: white; }
.gp-table-sub { display: block; margin-top: 2px; color: var(--gp-muted); font-size: 11px; }

.gp-badge {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    min-height: 25px;
    padding: 4px 9px;
    border-radius: 999px;
    font-size: 11px;
    font-weight: 800;
    border: 1px solid transparent;
}
.gp-badge-success { color: #a9f3ca; background: rgba(53,199,121,.12); border-color: rgba(53,199,121,.23); }
.gp-badge-warning { color: #ffd88c; background: rgba(246,183,60,.12); border-color: rgba(246,183,60,.24); }
.gp-badge-danger { color: #ffb1b7; background: rgba(239,93,103,.12); border-color: rgba(239,93,103,.25); }
.gp-badge-info { color: #aad0ff; background: rgba(63,140,255,.12); border-color: rgba(63,140,255,.25); }
.gp-badge-muted { color: #a5adbb; background: rgba(255,255,255,.055); border-color: rgba(255,255,255,.1); }
.status-open { color: #aad0ff; background: rgba(63,140,255,.12); border-color: rgba(63,140,255,.25); }
.status-progress { color: #ffd88c; background: rgba(246,183,60,.12); border-color: rgba(246,183,60,.24); }
.status-completed { color: #a9f3ca; background: rgba(53,199,121,.12); border-color: rgba(53,199,121,.23); }
.status-cancelled { color: #ffb1b7; background: rgba(239,93,103,.12); border-color: rgba(239,93,103,.25); }

.gp-alert { display: flex; gap: 11px; padding: 13px 15px; margin-bottom: 15px; border-radius: 12px; border: 1px solid; }
.gp-alert-success { color: #c9f8dd; background: rgba(53,199,121,.11); border-color: rgba(53,199,121,.28); }
.gp-alert-error { color: #ffd0d4; background: rgba(239,93,103,.11); border-color: rgba(239,93,103,.28); }
.gp-alert-warning { color: #ffe4aa; background: rgba(246,183,60,.1); border-color: rgba(246,183,60,.25); }
.gp-alert ul { margin: 4px 0 0; padding-left: 18px; }

.gp-empty { padding: 46px 24px; text-align: center; color: var(--gp-muted); }
.gp-empty-icon { width: 58px; height: 58px; display: grid; place-items: center; margin: 0 auto 12px; border-radius: 18px; background: rgba(23,105,224,.12); color: var(--gp-blue-light); font-size: 25px; }
.gp-empty h3 { margin: 0 0 6px; color: var(--gp-silver); }
.gp-empty p { margin: 0; }

.gp-pagination { margin-top: 18px; }
.pagination { display: flex; flex-wrap: wrap; list-style: none; gap: 5px; padding: 0; margin: 0; }
.page-link { min-width: 35px; min-height: 35px; padding: 7px 10px; display: grid; place-items: center; border-radius: 9px; background: rgba(255,255,255,.05); border: 1px solid var(--gp-border); color: #cbd2de; }
.page-item.active .page-link { background: var(--gp-blue); border-color: var(--gp-blue); color: white; }
.page-item.disabled .page-link { opacity: .4; }

.gp-summary-box { display: grid; gap: 10px; padding: 16px; border-radius: 12px; background: #0c1017; border: 1px solid var(--gp-border); }
.gp-summary-row { display: flex; align-items: center; justify-content: space-between; gap: 16px; color: var(--gp-muted); }
.gp-summary-row strong { color: white; }
.gp-summary-row.total { padding-top: 10px; border-top: 1px solid var(--gp-border); font-size: 18px; }
.gp-summary-row.total strong { color: var(--gp-blue-light); font-size: 24px; }

.gp-item-row { display: grid; grid-template-columns: 2fr 2.2fr .65fr 1fr 1fr auto; gap: 10px; align-items: end; padding: 12px; margin-bottom: 10px; border: 1px solid var(--gp-border); border-radius: 12px; background: rgba(255,255,255,.02); }
.gp-item-row .gp-field label { font-size: 10px; }
.gp-line-total { min-height: 43px; display: flex; align-items: center; justify-content: flex-end; padding: 10px; color: var(--gp-blue-light); font-weight: 850; }

.gp-detail-grid { display: grid; grid-template-columns: repeat(3, minmax(0,1fr)); gap: 12px; }
.gp-detail { padding: 14px; border-radius: 11px; background: rgba(255,255,255,.025); border: 1px solid var(--gp-border); }
.gp-detail span { display: block; margin-bottom: 5px; color: var(--gp-muted); font-size: 10px; text-transform: uppercase; letter-spacing: .09em; font-weight: 800; }
.gp-detail strong { color: white; }

.gp-login-shell {
    min-height: 100vh;
    display: grid;
    grid-template-columns: 1.1fr .9fr;
}
.gp-login-visual {
    position: relative;
    min-height: 100vh;
    display: grid;
    place-items: center;
    padding: 50px;
    overflow: hidden;
    background: #030406;
}
.gp-login-visual::before {
    content: "";
    position: absolute;
    inset: 0;
    background: radial-gradient(circle at 60% 40%, rgba(23,105,224,.24), transparent 38%);
}
.gp-login-visual img { position: relative; width: min(650px, 88%); border-radius: 24px; box-shadow: 0 35px 90px rgba(0,0,0,.6); }
.gp-login-panel { display: grid; place-items: center; padding: 32px; background: linear-gradient(145deg, #111722, #070a10); }
.gp-login-card { width: min(430px, 100%); }
.gp-login-card h1 { margin: 0; font-size: 34px; letter-spacing: -.04em; }
.gp-login-card > p { margin: 8px 0 28px; color: var(--gp-muted); }
.gp-login-form { padding: 24px; }
.gp-login-footer { margin-top: 18px; text-align: center; color: #667084; font-size: 11px; }

.gp-loader {
    position: fixed;
    inset: 0;
    z-index: 9999;
    display: grid;
    place-items: center;
    background: rgba(3, 4, 7, .94);
    transition: opacity .25s ease, visibility .25s ease;
}
.gp-loader.is-hidden { opacity: 0; visibility: hidden; pointer-events: none; }
.gp-loader-content { display: grid; justify-items: center; gap: 15px; }
.gp-loader-icon { position: relative; width: 84px; height: 84px; display: grid; place-items: center; }
.gp-loader-ring {
    position: absolute;
    inset: 0;
    border: 4px solid rgba(255,255,255,.12);
    border-top-color: var(--gp-blue-light);
    border-right-color: #d9dde5;
    border-radius: 50%;
    animation: gp-spin .85s linear infinite;
}
.gp-loader-mark {
    width: 57px;
    height: 57px;
    display: grid;
    place-items: center;
    border-radius: 50%;
    color: white;
    background: linear-gradient(135deg, #d9dde5 0 45%, var(--gp-blue) 46% 100%);
    -webkit-background-clip: text;
    background-clip: text;
    color: transparent;
    font-size: 24px;
    font-weight: 950;
    font-style: italic;
    letter-spacing: -.1em;
    text-shadow: none;
}
.gp-loader p { margin: 0; color: var(--gp-muted); font-size: 12px; letter-spacing: .12em; text-transform: uppercase; }
@keyframes gp-spin { to { transform: rotate(360deg); } }

.gp-overlay { display: none; }
.gp-print-only { display: none; }

@media (max-width: 1180px) {
    .gp-metrics { grid-template-columns: repeat(3, minmax(0,1fr)); }
    .gp-dashboard-grid { grid-template-columns: 1fr; }
    .gp-item-row { grid-template-columns: 1fr 1fr 100px 1fr 1fr auto; }
}

@media (max-width: 920px) {
    .gp-sidebar { transform: translateX(-102%); transition: transform .22s ease; }
    body.gp-menu-open .gp-sidebar { transform: translateX(0); }
    .gp-main { margin-left: 0; }
    .gp-mobile-toggle { display: grid; }
    .gp-overlay { position: fixed; inset: 0; z-index: 35; background: rgba(0,0,0,.62); }
    body.gp-menu-open .gp-overlay { display: block; }
    .gp-login-shell { grid-template-columns: 1fr; }
    .gp-login-visual { display: none; }
    .gp-col-8, .gp-col-6, .gp-col-4, .gp-col-3, .gp-col-2 { grid-column: span 12; }
}

@media (max-width: 680px) {
    .gp-topbar { padding: 12px 15px; }
    .gp-topbar-title p { display: none; }
    .gp-content { padding: 18px 14px 28px; }
    .gp-page-head { flex-direction: column; }
    .gp-page-head .gp-actions, .gp-page-head .gp-btn { width: 100%; }
    .gp-metrics { grid-template-columns: repeat(2, minmax(0,1fr)); }
    .gp-metric { min-height: 110px; }
    .gp-card-body { padding: 15px; }
    .gp-item-row { grid-template-columns: 1fr; }
    .gp-line-total { justify-content: flex-start; }
    .gp-detail-grid { grid-template-columns: 1fr; }
    .gp-form-actions { flex-direction: column-reverse; }
    .gp-form-actions .gp-btn { width: 100%; }
    .gp-login-panel { padding: 20px 14px; }
}

@media print {
    body { background: white; color: #111; }
    .gp-sidebar, .gp-topbar, .gp-page-head .gp-actions, .gp-alert, .no-print, .gp-loader { display: none !important; }
    .gp-main { margin: 0; }
    .gp-content { width: 100%; padding: 0; }
    .gp-card { background: white; color: #111; box-shadow: none; border: 1px solid #ddd; }
    .gp-card-header, .gp-card-footer, .gp-table th, .gp-table td { border-color: #ddd; color: #111; }
    .gp-detail { background: white; border-color: #ddd; }
    .gp-detail strong, .gp-table strong, .gp-summary-row strong { color: #111; }
    .gp-print-only { display: block; }
}
