
:root {
    --bg-page: #020617;
    --bg-card: rgba(15, 23, 42, 0.85);
    --border-subtle: rgba(148, 163, 184, 0.5);
    --text-main: #e5e7eb;
    --text-muted: #9ca3af;
    --accent: #38bdf8;
    --accent-soft: rgba(56, 189, 248, 0.2);
    --danger: #fb7185;
    --radius-large: 22px;
    --radius-pill: 999px;
    --shadow-soft: 0 24px 60px rgba(15, 23, 42, 0.85);
}

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

html, body {
    margin: 0;
    padding: 0;
}

body {
    min-height: 100vh;
    background:
        radial-gradient(circle at top left, #0f172a 0, transparent 55%),
        radial-gradient(circle at center right, #0369a1 0, transparent 55%),
        radial-gradient(circle at bottom, #4f46e5 0, transparent 60%),
        #020617;
    font-family: system-ui, -apple-system, BlinkMacSystemFont, sans-serif;
    color: var(--text-main);
}

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

.app {
    max-width: 1120px;
    margin: 0 auto;
    padding: 24px 16px 32px;
}

/* Header */

.app-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 10px 18px;
    margin-bottom: 24px;
    border-radius: var(--radius-pill);
    background: linear-gradient(120deg, rgba(15,23,42,0.9), rgba(30,64,175,0.55));
    backdrop-filter: blur(30px) saturate(140%);
    border: 1px solid rgba(148,163,184,0.55);
    box-shadow: var(--shadow-soft);
}

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

.brand-mark {
    width: 34px;
    height: 34px;
    border-radius: 999px;
    border: 1px solid rgba(248,250,252,0.25);
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 600;
    font-size: 14px;
    background: radial-gradient(circle at top, #e0f2fe, #38bdf8);
    color: #0f172a;
}

.brand-text {
    display: flex;
    flex-direction: column;
}

.brand-name {
    font-size: 16px;
    font-weight: 600;
}

.brand-subtitle {
    font-size: 12px;
    color: rgba(226,232,240,0.85);
}

.app-nav {
    display: flex;
    align-items: center;
    gap: 12px;
    font-size: 13px;
}

.nav-link {
    padding: 6px 12px;
    border-radius: var(--radius-pill);
    border: 1px solid transparent;
    color: var(--text-muted);
    background: rgba(15,23,42,0.6);
}

.nav-link:hover {
    border-color: rgba(148,163,184,0.7);
    background: rgba(15,23,42,0.9);
    color: var(--text-main);
}

.nav-link-quiet {
    background: transparent;
    border-color: transparent;
}

.nav-divider {
    width: 1px;
    height: 20px;
    background: rgba(148, 163, 184, 0.6);
}

.nav-user {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
}

.nav-user-name {
    font-size: 13px;
    font-weight: 500;
}

.nav-user-id {
    font-size: 11px;
    color: var(--text-muted);
}

/* Main & footer */

.app-main {
    display: flex;
    flex-direction: column;
    gap: 20px;
    margin-bottom: 24px;
}

.app-footer {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    justify-content: space-between;
    align-items: center;
    font-size: 11px;
    color: rgba(148,163,184,0.9);
    padding: 8px 4px 0;
    border-top: 1px solid rgba(30,64,175,0.7);
}

.footer-dot {
    margin: 0 8px;
}

/* Card */

.card {
    background: radial-gradient(circle at top left, rgba(15,23,42,0.92), rgba(15,23,42,0.85));
    border-radius: var(--radius-large);
    border: 1px solid rgba(148,163,184,0.5);
    box-shadow: var(--shadow-soft);
    padding: 24px 24px 22px;
    backdrop-filter: blur(26px) saturate(150%);
}

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

.card-actions {
    display: flex;
    gap: 8px;
    flex-wrap: wrap;
    justify-content: flex-end;
}

/* Text */

.page-title {
    font-size: 24px;
    margin: 0 0 6px;
}

.page-subtitle {
    margin: 0;
    font-size: 13px;
    color: var(--text-muted);
}

.section-title {
    font-size: 18px;
    margin: 0 0 4px;
}

.section-subtitle {
    margin: 0;
    font-size: 13px;
    color: var(--text-muted);
}

.summary-title {
    font-size: 16px;
    margin: 0 0 6px;
}

.summary-text {
    margin: 0 0 16px;
    font-size: 13px;
    color: var(--text-muted);
}

.text-muted {
    font-size: 13px;
    color: var(--text-muted);
}

/* Summary grid */

.summary-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
    gap: 16px;
}

.summary-card {
    padding: 18px;
    border-radius: 18px;
    border: 1px solid rgba(148,163,184,0.5);
    background: linear-gradient(135deg, rgba(15,23,42,0.9), rgba(15,23,42,0.75));
}

/* Buttons */

.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border-radius: var(--radius-pill);
    border: 1px solid transparent;
    padding: 8px 16px;
    font-size: 13px;
    cursor: pointer;
    background: transparent;
    color: var(--text-main);
    transition: background-color 0.18s ease, border-color 0.18s ease,
        color 0.18s ease, box-shadow 0.18s ease, transform 0.1s ease;
}

.btn-primary {
    background: linear-gradient(135deg, #38bdf8, #22c55e);
    color: #0f172a;
    border-color: transparent;
    box-shadow: 0 18px 45px rgba(56, 189, 248, 0.5);
}

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

.btn-secondary {
    background: rgba(15,23,42,0.9);
    border-color: rgba(148,163,184,0.75);
}

.btn-ghost {
    background: transparent;
    border-color: rgba(148,163,184,0.6);
}

.btn-full {
    width: 100%;
}

/* Auth */

.auth-layout {
    display: flex;
    justify-content: center;
    align-items: center;
    min-height: 68vh;
}

.auth-card {
    max-width: 420px;
    width: 100%;
}

.auth-header {
    margin-bottom: 20px;
}

.auth-badge {
    display: inline-flex;
    align-items: center;
    padding: 4px 10px;
    border-radius: var(--radius-pill);
    background: rgba(56,189,248,0.16);
    color: #e0f2fe;
    font-size: 11px;
    font-weight: 500;
    margin-bottom: 10px;
}

.auth-title {
    margin: 0 0 6px;
    font-size: 22px;
}

.auth-subtitle {
    margin: 0;
    font-size: 13px;
    color: var(--text-muted);
}

.auth-form {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

/* Fields */

.field-label {
    font-size: 12px;
    font-weight: 500;
    margin-bottom: 4px;
}

.field-input {
    width: 100%;
    border-radius: 12px;
    border: 1px solid rgba(148,163,184,0.85);
    padding: 10px 12px;
    font-size: 14px;
    outline: none;
    background: rgba(15,23,42,0.9);
    color: var(--text-main);
}

.field-input:focus {
    border-color: #38bdf8;
    box-shadow: 0 0 0 2px var(--accent-soft);
}

/* Flash */

.flash-container {
    display: flex;
    flex-direction: column;
    gap: 8px;
    margin-bottom: 6px;
}

.flash {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 9px 12px;
    border-radius: 12px;
    font-size: 12px;
    border: 1px solid rgba(148,163,184,0.7);
    background: rgba(15,23,42,0.85);
}

.flash-error {
    border-color: rgba(251, 113, 133, 0.7);
    background: rgba(127, 29, 54, 0.9);
}

.flash-dot {
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background: var(--danger);
}

/* Month list */

.month-grid {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.month-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 12px;
    padding: 10px 12px;
    border-radius: 18px;
    background: rgba(15,23,42,0.9);
}

.month-label {
    font-size: 14px;
    font-weight: 500;
}

.month-links {
    display: flex;
    flex-wrap: wrap;
    gap: 6px;
}

.chip-link {
    display: inline-flex;
    align-items: center;
    padding: 6px 12px;
    border-radius: var(--radius-pill);
    font-size: 12px;
    border: 1px solid rgba(148,163,184,0.75);
    background: rgba(15,23,42,0.9);
}

.chip-link-muted {
    color: var(--text-muted);
}

/* Tables */

.table-wrapper {
    width: 100%;
    overflow-x: auto;
    margin-top: 8px;
}

.data-table {
    width: 100%;
    border-collapse: collapse;
    border-radius: 16px;
    overflow: hidden;
    font-size: 13px;
}

.data-table thead {
    background: rgba(30,64,175,0.9);
}

.data-table th,
.data-table td {
    padding: 10px 12px;
    border-bottom: 1px solid rgba(30,64,175,0.8);
    text-align: left;
    white-space: nowrap;
}

.data-table th {
    font-weight: 600;
}

.total-badge {
    margin-top: 18px;
    display: inline-flex;
    align-items: baseline;
    gap: 6px;
    padding: 8px 12px;
    border-radius: var(--radius-pill);
    background: rgba(56,189,248,0.18);
    color: #e0f2fe;
    font-size: 13px;
}

.note-block {
    margin-top: 18px;
    padding: 12px 14px;
    border-radius: 16px;
    background: rgba(15,23,42,0.9);
    border: 1px solid rgba(148,163,184,0.6);
}

.note-title {
    font-size: 13px;
    font-weight: 600;
    margin: 0 0 4px;
}

.note-text {
    margin: 0;
    font-size: 13px;
    color: var(--text-muted);
}

/* Responsive */

@media (max-width: 720px) {
    .app-header {
        flex-direction: column;
        align-items: flex-start;
        gap: 10px;
        border-radius: 24px;
    }

    .app-nav {
        width: 100%;
        justify-content: space-between;
        flex-wrap: wrap;
        row-gap: 6px;
    }

    .card {
        padding: 18px 16px 16px;
    }

    .page-title {
        font-size: 20px;
    }

    .auth-layout {
        min-height: 60vh;
    }

    .month-row {
        flex-direction: column;
        align-items: flex-start;
    }

    .card-header {
        flex-direction: column;
        align-items: flex-start;
    }

    .card-actions {
        width: 100%;
        justify-content: flex-start;
    }
}

/* Earned Header */

.nav-earned {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    padding: 4px 10px;
    border-radius: 12px;
    background: rgba(56, 189, 248, 0.16);
    border: 1px solid rgba(56, 189, 248, 0.3);
}

.nav-earned-label {
    font-size: 10px;
    color: var(--text-muted);
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.nav-earned-value {
    font-size: 14px;
    font-weight: 600;
    color: var(--accent);
}

/* Salary Card Layout */

.salary-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(350px, 1fr));
    gap: 16px;
    margin-top: 16px;
}

.salary-card {
    background: radial-gradient(circle at top left, rgba(15,23,42,0.92), rgba(15,23,42,0.85));
    border-radius: var(--radius-large);
    border: 1px solid rgba(148,163,184,0.5);
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.4);
    padding: 20px;
    backdrop-filter: blur(20px) saturate(150%);
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.salary-label {
    font-size: 14px;
    color: var(--text-muted);
    font-weight: 500;
}

.salary-value {
    font-size: 20px;
    font-weight: 700;
    color: var(--text-main);
}

.salary-value-accent {
    color: var(--accent);
}

.salary-value-danger {
    color: var(--danger);
}
