:root {
    --navy-950: #0b1422;
    --navy-900: #101d30;
    --navy-850: #16253a;
    --navy-800: #1c2e46;

    --steel-700: #334d68;
    --steel-600: #496781;
    --steel-500: #68839a;

    --blue-600: #275d8c;
    --blue-500: #3477aa;
    --blue-100: #eaf2f8;

    --surface: #ffffff;
    --surface-soft: #f5f7fa;
    --surface-alt: #eef2f6;

    --text: #1f2937;
    --text-soft: #667085;
    --text-light: #98a2b3;

    --border: #dbe2ea;

    --success: #297a58;
    --success-bg: #e8f5ee;

    --danger: #a43c3c;
    --danger-bg: #faecec;

    --warning: #94651f;
    --warning-bg: #fff5dd;

    --sidebar-width: 255px;

    --shadow-sm:
        0 1px 3px rgba(16, 24, 40, 0.08);

    --shadow-md:
        0 8px 24px rgba(16, 24, 40, 0.10);

    --radius: 8px;
}


* {
    box-sizing: border-box;
}


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


body {
    font-family:
        Inter,
        "Segoe UI",
        Arial,
        sans-serif;

    color: var(--text);
    background: var(--surface-soft);
}


/* =========================================================
   AUTHENTICATION
   ========================================================= */

.auth-body {
    min-height: 100vh;
    background: var(--surface-soft);
}


.auth-shell {
    min-height: 100vh;
    display: grid;
    grid-template-columns: 42% 58%;
}


.auth-brand-panel {
    background:
        linear-gradient(
            145deg,
            var(--navy-950),
            var(--navy-800)
        );

    display: flex;
    align-items: center;
    justify-content: center;

    padding: 50px;
}


.auth-brand {
    max-width: 430px;
    color: white;
}


.ram-mark {
    display: block;

    width: auto;
    height: auto;

    padding: 0;

    border: 0;
    background: transparent;

    font-size: 34px;
    font-weight: 700;
    letter-spacing: 7px;

    margin-bottom: 18px;
}


/* =========================================================
   RAM BRAND LOGO
   ========================================================= */

.ram-brand-logo {
    display: block;
    object-fit: cover;
    background: #ffffff;
    border-radius: 18px;
    box-shadow:
        0 6px 18px rgba(16, 24, 40, .12);
}

.ram-login-logo {
    width: 104px;
    height: 104px;
    margin-bottom: 18px;
}

.registration-brand-line {
    display: flex;
    align-items: center;
    gap: 11px;
    margin-bottom: 8px;
}

.ram-registration-logo {
    width: 42px;
    height: 42px;
    border-radius: 10px;
    flex: 0 0 auto;
}

.registration-brand-line .auth-eyebrow {
    display: inline-flex;
    align-items: center;
}

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

.ram-sidebar-logo-image {
    width: 48px;
    height: 48px;
    border-radius: 12px;
    flex: 0 0 auto;
}


.auth-brand h1 {
    margin:
        0 0 12px;

    font-size: 34px;
    font-weight: 600;
    letter-spacing: -.5px;
}


.auth-brand p {
    margin: 0;

    color:
        rgba(255,255,255,.65);

    font-size: 16px;
    line-height: 1.7;
}


.auth-form-panel {
    display: flex;
    align-items: center;
    justify-content: center;

    padding: 45px;
}


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

    background: white;

    border: 1px solid var(--border);
    border-radius: 10px;

    padding: 42px;

    box-shadow: var(--shadow-sm);
}


.registration-wrapper {
    min-height: 100vh;

    display: flex;
    justify-content: center;
    align-items: center;

    padding: 50px 20px;
}


.registration-card {
    width: 100%;
    max-width: 900px;

    background: white;

    border:
        1px solid
        var(--border);

    border-radius: 10px;

    padding: 42px;

    box-shadow:
        var(--shadow-sm);
}


.auth-heading {
    margin-bottom: 30px;
}


.auth-eyebrow {
    color: var(--blue-600);

    font-size: 11px;
    font-weight: 700;
    letter-spacing: 1.5px;
}


.auth-heading h2 {
    margin:
        8px 0 8px;

    font-size: 26px;
    font-weight: 600;
}


.auth-heading p {
    margin: 0;

    color:
        var(--text-soft);

    font-size: 14px;
    line-height: 1.6;
}


.auth-footer-link {
    text-align: center;
    margin-top: 24px;

    color:
        var(--text-soft);

    font-size: 14px;
}


.auth-footer-link a {
    color: var(--blue-600);
    text-decoration: none;
    font-weight: 600;
}


/* =========================================================
   FORMS
   ========================================================= */

.form-grid {
    display: grid;

    grid-template-columns:
        repeat(2, minmax(0, 1fr));

    gap: 20px;
}


.form-group {
    display: flex;
    flex-direction: column;

    gap: 8px;

    margin-bottom: 20px;
}


.form-group label {
    font-size: 13px;
    font-weight: 600;

    color: #344054;
}


.form-group input,
.form-group select,
.form-group textarea {
    width: 100%;

    border:
        1px solid
        #ccd5df;

    border-radius: 6px;

    background: white;

    padding:
        11px 12px;

    color:
        var(--text);

    font-size: 14px;

    outline: none;

    transition:
        border-color .15s,
        box-shadow .15s;
}


.form-group input:focus,
.form-group select:focus,
.form-group textarea:focus {
    border-color:
        var(--blue-500);

    box-shadow:
        0 0 0 3px
        rgba(52,119,170,.12);
}


.form-group small {
    color:
        var(--text-soft);

    font-size: 11px;
    line-height: 1.5;
}


/* =========================================================
   BUTTONS
   ========================================================= */

.btn {
    appearance: none;

    border:
        1px solid transparent;

    border-radius: 6px;

    padding:
        11px 18px;

    cursor: pointer;

    font-size: 13px;
    font-weight: 600;

    transition:
        background .15s,
        border-color .15s;
}


.btn-primary {
    background:
        var(--navy-800);

    color: white;
}


.btn-primary:hover {
    background:
        var(--navy-950);
}


.btn-full {
    width: 100%;
}


/* =========================================================
   ALERTS
   ========================================================= */

.alert {
    border-radius: 6px;

    padding:
        12px 14px;

    margin-bottom: 18px;

    font-size: 13px;

    border:
        1px solid transparent;
}


.alert-danger {
    background:
        var(--danger-bg);

    border-color:
        #efcccc;

    color:
        var(--danger);
}


.alert-success {
    background:
        var(--success-bg);

    border-color:
        #c6e8d6;

    color:
        var(--success);
}


.alert-warning {
    background:
        var(--warning-bg);

    color:
        var(--warning);
}


/* =========================================================
   MAIN APPLICATION
   ========================================================= */

.app-layout {
    min-height: 100vh;
}


.sidebar {
    width:
        var(--sidebar-width);

    position: fixed;

    left: 0;
    top: 0;
    bottom: 0;

    background:
        var(--navy-950);

    color: white;

    display: flex;
    flex-direction: column;

    z-index: 1000;
}


.sidebar-brand {
    padding:
        28px 24px 26px;

    border-bottom:
        1px solid
        rgba(255,255,255,.08);
}


.sidebar-logo {
    font-size: 28px;
    font-weight: 700;
    letter-spacing: 5px;
}


.sidebar-subtitle {
    margin-top: 6px;

    font-size: 11px;
    letter-spacing: .5px;

    color:
        rgba(255,255,255,.55);
}


.sidebar-menu {
    flex: 1;

    padding:
        20px 12px;

    overflow-y: auto;
}


.menu-item {
    width: 100%;

    display: flex;
    align-items: center;

    gap: 12px;

    padding:
        12px 13px;

    margin-bottom: 3px;

    border: 0;

    border-radius: 6px;

    background: transparent;

    color:
        rgba(255,255,255,.70);

    text-decoration: none;

    font-size: 13px;

    cursor: pointer;

    text-align: left;
}


.menu-item:hover,
.menu-item.active {
    background:
        rgba(255,255,255,.08);

    color: white;
}


.menu-icon {
    width: 21px;

    font-size: 15px;

    text-align: center;
}


.menu-arrow {
    margin-left: auto;
}


.submenu {
    display: none;

    margin:
        2px 0 10px 36px;

    border-left:
        1px solid
        rgba(255,255,255,.10);
}


.submenu.open {
    display: block;
}


.submenu a {
    display: block;

    padding:
        9px 13px;

    color:
        rgba(255,255,255,.55);

    font-size: 12px;

    text-decoration: none;
}


.submenu a:hover {
    color: white;
}


.sidebar-footer {
    padding:
        16px 22px;

    border-top:
        1px solid
        rgba(255,255,255,.08);

    color:
        rgba(255,255,255,.35);

    font-size: 10px;
    letter-spacing: .5px;
}


.main-area {
    margin-left:
        var(--sidebar-width);

    min-height: 100vh;
}


.top-header {
    min-height: 76px;

    background: white;

    border-bottom:
        1px solid
        var(--border);

    display: flex;
    align-items: center;
    justify-content: space-between;

    padding:
        13px 28px;

    position: sticky;
    top: 0;

    z-index: 500;
}


.top-header-left {
    display: flex;
    align-items: center;

    gap: 16px;
}


.top-header h1 {
    margin: 0;

    font-size: 19px;
    font-weight: 600;
}


.header-context {
    margin-top: 4px;

    font-size: 11px;

    color:
        var(--text-soft);
}


.sidebar-toggle {
    display: none;

    background: transparent;
    border: 0;

    font-size: 19px;

    cursor: pointer;
}


.logged-user {
    display: flex;
    align-items: center;

    gap: 11px;
}


.user-avatar {
    width: 38px;
    height: 38px;

    border-radius: 50%;

    background:
        var(--navy-800);

    color: white;

    display: flex;
    align-items: center;
    justify-content: center;

    font-weight: 600;
}


.user-details {
    display: flex;
    flex-direction: column;
}


.user-details strong {
    font-size: 13px;
}


.user-details span {
    margin-top: 2px;

    font-size: 11px;

    color:
        var(--text-soft);
}


.logout-button {
    margin-left: 10px;

    padding:
        8px 12px;

    border:
        1px solid
        var(--border);

    border-radius: 5px;

    color:
        var(--text);

    font-size: 11px;

    text-decoration: none;
}


.logout-button:hover {
    background:
        var(--surface-soft);
}


.content-area {
    padding: 28px;
}


.content-card {
    background: white;

    border:
        1px solid
        var(--border);

    border-radius:
        var(--radius);

    box-shadow:
        var(--shadow-sm);

    padding: 22px;
}


.content-card h2 {
    margin-top: 0;

    font-size: 17px;
}


/* =========================================================
   DATA TABLES - USED BY UPCOMING MODULES
   ========================================================= */

.table-card {
    background: white;

    border:
        1px solid
        var(--border);

    border-radius:
        var(--radius);

    overflow: hidden;
}


.table-responsive {
    /*
     * Keep RAM data tables compact. Approximately five data rows remain
     * visible at once; additional records are available through the table's
     * own scrollbar instead of extending the entire page.
     */
    max-height: 355px;
    overflow: auto;
    scrollbar-gutter: stable;
}


/*
 * Keep column headings visible while the user scrolls a table.
 */
.table-responsive .data-table thead th {
    position: sticky;
    top: 0;
    z-index: 3;
}


/*
 * Give normal RAM rows a consistent working height. Rows can still grow
 * when their content genuinely needs more space.
 */
.table-responsive .data-table tbody tr {
    min-height: 56px;
}


.data-table {
    width: 100%;

    border-collapse:
        collapse;

    font-size: 12px;
}


.data-table th {
    background:
        var(--surface-alt);

    color:
        #475467;

    font-size: 11px;

    letter-spacing: .35px;

    text-align: left;

    padding:
        12px 14px;

    border-bottom:
        1px solid
        var(--border);
}


.data-table td {
    padding:
        12px 14px;

    border-bottom:
        1px solid
        #edf0f3;

    vertical-align: middle;
}


.data-table tbody tr:hover {
    background:
        #fafbfc;
}


/* =========================================================
   STATUS BADGES
   ========================================================= */

.badge {
    display:
        inline-flex;

    padding:
        4px 8px;

    border-radius: 20px;

    font-size: 10px;
    font-weight: 600;
}


.badge-success {
    background:
        var(--success-bg);

    color:
        var(--success);
}


.badge-danger {
    background:
        var(--danger-bg);

    color:
        var(--danger);
}


.badge-warning {
    background:
        var(--warning-bg);

    color:
        var(--warning);
}


.badge-neutral {
    background:
        var(--surface-alt);

    color:
        var(--steel-700);
}


/* =========================================================
   RESPONSIVE
   ========================================================= */

@media (
    max-width: 900px
) {

    .auth-shell {
        grid-template-columns: 1fr;
    }


    .auth-brand-panel {
        min-height: 250px;

        padding: 35px;
    }


    .auth-form-panel {
        padding: 30px 20px;
    }


    .form-grid {
        grid-template-columns:
            1fr;
    }


    .sidebar {
        transform:
            translateX(-100%);

        transition:
            transform .2s ease;
    }


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


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


    .sidebar-toggle {
        display: block;
    }


    .user-details {
        display: none;
    }


    .content-area {
        padding: 18px;
    }


    .ram-login-logo {
        width: 84px;
        height: 84px;
        border-radius: 16px;
    }

    .ram-registration-logo {
        width: 38px;
        height: 38px;
        border-radius: 9px;
    }

}