* {
    box-sizing: border-box;
}

body {
    margin: 0;
    font-family: "Segoe UI", Tahoma, Geneva, Verdana, sans-serif;
    background: linear-gradient(180deg, #ecfeff 0%, #f8fafc 100%);
    color: #0f172a;
}

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

.page-shell {
    display: grid;
    grid-template-columns: 290px minmax(0, 1fr);
    min-height: 100vh;
}

.portal-login-page .page-shell {
    grid-template-columns: 1fr;
}

.portal-login-page .sidebar {
    display: none;
}

.portal-login-page .content {
    min-height: 100vh;
    padding: 24px;
}

.portal-shell,
.login-shell {
    min-height: calc(100vh - 56px);
    display: grid;
    align-items: center;
}

.portal-shell {
    padding: 24px;
}

.portal-hero {
    display: grid;
    grid-template-columns: 1.5fr 0.75fr;
    gap: 24px;
    align-items: center;
    background: linear-gradient(135deg, rgba(15, 118, 110, 0.12), rgba(14, 165, 164, 0.04) 52%, rgba(255, 255, 255, 0.9));
    border: 1px solid rgba(13, 148, 136, 0.18);
    border-radius: 30px;
    padding: 32px;
    box-shadow: 0 24px 50px rgba(15, 23, 42, 0.08);
}

.portal-copy h1 {
    margin: 0;
    font-size: clamp(2.2rem, 3vw, 4rem);
    line-height: 1.08;
    max-width: 680px;
}

.portal-copy .hero-copy {
    margin: 18px 0 0;
    color: #475569;
    line-height: 1.7;
    max-width: 620px;
}

.portal-card {
    background: rgba(15, 23, 42, 0.96);
    color: #f8fafc;
    border-radius: 26px;
    padding: 22px;
    box-shadow: 0 32px 48px rgba(15, 23, 42, 0.2);
}

.portal-card-head {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 12px;
    margin-bottom: 16px;
    color: #cbd5e1;
    font-size: 12px;
    letter-spacing: 0.08em;
    text-transform: uppercase;
}

.portal-card ul {
    list-style: none;
    margin: 0;
    padding: 0;
    display: grid;
    gap: 12px;
    color: #e2e8f0;
}

.portal-card li {
    padding: 12px 14px;
    border-radius: 14px;
    background: rgba(148, 163, 184, 0.08);
}

.login-shell {
    grid-template-columns: 1.2fr 0.8fr;
    gap: 28px;
    padding: 24px;
}

.login-panel {
    background: rgba(255, 255, 255, 0.9);
    border: 1px solid rgba(148, 163, 184, 0.16);
    border-radius: 30px;
    padding: 32px;
    box-shadow: 0 24px 50px rgba(15, 23, 42, 0.08);
}

.left-panel {
    background: linear-gradient(135deg, rgba(15, 118, 110, 0.12), rgba(30, 41, 59, 0.96));
    color: #f8fafc;
}

.brand-lockup {
    display: flex;
    align-items: center;
    gap: 16px;
    margin-bottom: 24px;
}

.brand-badge {
    width: 52px;
    height: 52px;
    border-radius: 18px;
    display: grid;
    place-items: center;
    background: linear-gradient(135deg, #99f6e4, #14b8a6);
    color: #042f2e;
    font-size: 26px;
    font-weight: 900;
}

.left-panel h1 {
    margin: 0;
    font-size: clamp(2rem, 2vw, 3rem);
    line-height: 1.12;
}

.left-panel p {
    color: rgba(248, 250, 252, 0.82);
    line-height: 1.7;
}

.login-metrics {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 14px;
    margin-top: 28px;
}

.login-metrics div {
    padding: 18px 14px;
    border-radius: 18px;
    background: rgba(148, 163, 184, 0.08);
    display: grid;
    gap: 8px;
}

.login-metrics strong {
    font-size: 28px;
    line-height: 1;
}

.form-header {
    margin-bottom: 18px;
}

.form-header h3 {
    margin: 0;
    font-size: 32px;
}

.login-form {
    display: grid;
    gap: 16px;
}

.login-form label {
    font-weight: 700;
    color: #334155;
}

.login-form input {
    width: 100%;
    padding: 15px 16px;
    border: 1px solid #cbd5e1;
    border-radius: 14px;
    background: #fff;
    font: inherit;
}

.login-form .alert {
    padding: 12px 14px;
    border-radius: 12px;
    background: #fef2f2;
    color: #991b1b;
    font-weight: 600;
}

.login-form small {
    color: #dc2626;
}

.wide {
    width: 100%;
}

.portal-login-page {
    background: #f2f2e9;
}

.portal-login-page .content {
    display: grid;
    place-items: center;
    padding: clamp(18px, 5vw, 64px);
    background-image: radial-gradient(rgba(18, 60, 50, 0.07) 0.7px, transparent 0.7px);
    background-size: 14px 14px;
}

.portal-login-page .login-shell {
    width: min(1040px, 100%);
    min-height: 570px;
    grid-template-columns: 0.92fr 1.08fr;
    align-items: stretch;
    gap: 0;
    padding: 0;
    overflow: hidden;
    border: 1px solid #dce1d6;
    border-radius: 8px;
    background: #fffefa;
    box-shadow: 0 28px 75px rgba(15, 48, 38, 0.13);
}

.portal-login-page .login-panel {
    min-width: 0;
    display: flex;
    flex-direction: column;
    justify-content: center;
    border: 0;
    border-radius: 0;
    box-shadow: none;
}

.portal-login-page .left-panel {
    position: relative;
    isolation: isolate;
    overflow: hidden;
    padding: clamp(30px, 5vw, 58px);
    background: linear-gradient(145deg, #123c32 0%, #0c3028 65%, #285942 100%);
}

.portal-login-page .left-panel::after {
    position: absolute;
    z-index: -1;
    right: -128px;
    bottom: -148px;
    width: 340px;
    height: 340px;
    border: 1px solid rgba(200, 223, 145, 0.24);
    border-radius: 50%;
    box-shadow: 0 0 0 32px rgba(200, 223, 145, 0.04), 0 0 0 68px rgba(200, 223, 145, 0.035);
    content: "";
}

.portal-login-page .brand-lockup {
    min-height: 44px;
    margin: 0 0 auto;
    padding-bottom: clamp(44px, 8vh, 88px);
}

.login-logo {
    display: block;
    width: 118px;
    max-height: 42px;
    object-fit: contain;
    object-position: left center;
    filter: brightness(0) invert(1);
}

.brand-divider {
    width: 1px;
    height: 24px;
    background: rgba(255, 255, 255, 0.32);
}

.brand-label {
    color: #d9e2d5;
    font-size: 9px;
    font-weight: 800;
}

.portal-login-page .left-panel .eyebrow {
    margin-bottom: 14px;
    color: #c8df91;
}

.portal-login-page .left-panel h1 {
    max-width: 400px;
    font: 400 clamp(36px, 4vw, 51px)/1.08 Georgia, "Times New Roman", serif;
}

.login-intro {
    max-width: 390px;
    margin: 18px 0 28px;
    color: #d7e2d8;
    font-size: 14px;
    line-height: 1.75;
}

.access-note {
    display: flex;
    align-items: flex-start;
    gap: 12px;
    max-width: 390px;
    padding: 15px 16px;
    border: 1px solid rgba(200, 223, 145, 0.22);
    border-radius: 5px;
    background: rgba(255, 255, 255, 0.06);
}

.access-dot {
    flex: 0 0 8px;
    width: 8px;
    height: 8px;
    margin-top: 5px;
    border-radius: 50%;
    background: #c8df91;
}

.access-note p,
.other-users-note {
    margin: 0;
    color: #eff3e9;
    font-size: 12px;
    line-height: 1.6;
}

.other-users-note {
    margin-top: 18px;
    color: #b9c9be;
}

.portal-login-page .form-panel {
    padding: clamp(30px, 5.5vw, 68px);
    background: #fffefa;
}

.portal-login-page .form-header {
    margin-bottom: 30px;
}

.portal-login-page .form-header .eyebrow {
    margin-bottom: 10px;
}

.portal-login-page .form-header h3 {
    color: #173b30;
    font: 400 clamp(30px, 3.4vw, 40px)/1.12 Georgia, "Times New Roman", serif;
}

.portal-login-page .form-header > p:last-child {
    margin: 11px 0 0;
    color: #68766c;
    font-size: 13px;
}

.portal-login-page .login-form {
    gap: 20px;
}

.login-field {
    display: grid;
    gap: 8px;
}

.portal-login-page .login-form label {
    color: #34483d;
    font-size: 12px;
}

.portal-login-page .login-form input {
    min-height: 50px;
    padding: 13px 15px;
    border: 1px solid #d0d8cd;
    border-radius: 4px;
    background: #fff;
    color: #18382e;
    font-size: 14px;
    transition: border-color 140ms ease, box-shadow 140ms ease;
}

.portal-login-page .login-form input::placeholder {
    color: #9aa69b;
}

.portal-login-page .login-form input:focus {
    border-color: #26755a;
    outline: 0;
    box-shadow: 0 0 0 3px rgba(38, 117, 90, 0.14);
}

.portal-login-page .login-form .button.primary {
    min-height: 50px;
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 12px;
    border: 0;
    border-radius: 4px;
    background: #174b39;
    font: inherit;
    font-size: 13px;
    cursor: pointer;
    transition: background 140ms ease, transform 140ms ease;
}

.portal-login-page .login-form .button.primary:hover {
    background: #23684d;
}

.portal-login-page .login-form .button.primary:active {
    transform: translateY(1px);
}

.portal-login-page .login-form .alert {
    margin: 0;
    border: 1px solid #e6bcb2;
    border-radius: 4px;
    font-size: 12px;
    line-height: 1.55;
}

.portal-login-page .login-form .alert ul,
.field-error ul {
    margin: 0;
    padding-left: 18px;
}

.field-error {
    color: #a33f2f;
    font-size: 11px;
    line-height: 1.5;
}

.login-footer {
    display: flex;
    flex-wrap: wrap;
    justify-content: space-between;
    gap: 8px 18px;
    margin-top: 26px;
    padding-top: 18px;
    border-top: 1px solid #e6e9e0;
    color: #737e74;
    font-size: 11px;
}

.login-footer a {
    color: #23684d;
    font-weight: 750;
}

.portal-login-page .login-shell .eyebrow,
.portal-login-page .login-shell .login-footer {
    letter-spacing: 0;
}

@media (max-width: 760px) {
    .portal-login-page .content {
        padding: 16px;
    }

    .portal-login-page .login-shell {
        width: min(520px, 100%);
        grid-template-columns: 1fr;
    }

    .portal-login-page .left-panel {
        min-height: 310px;
        padding: 28px;
    }

    .portal-login-page .brand-lockup {
        margin-bottom: 48px;
        padding-bottom: 0;
    }

    .portal-login-page .left-panel h1 {
        max-width: 450px;
        font-size: 38px;
    }

    .login-intro {
        margin: 12px 0 16px;
    }

    .other-users-note {
        margin-top: 12px;
    }

    .portal-login-page .form-panel {
        padding: 30px 28px;
    }

    .portal-login-page .form-header {
        margin-bottom: 22px;
    }
}

@media (max-width: 380px) {
    .portal-login-page .content {
        padding: 0;
    }

    .portal-login-page .login-shell {
        border: 0;
        border-radius: 0;
    }

    .portal-login-page .left-panel,
    .portal-login-page .form-panel {
        padding: 24px 20px;
    }

    .brand-label {
        font-size: 8px;
    }
}

.sidebar {
    padding: 24px;
    background: #0f172a;
    color: #f8fafc;
}

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

.brand-icon {
    width: 52px;
    height: 52px;
    border-radius: 16px;
    display: grid;
    place-items: center;
    background: linear-gradient(135deg, #0f766e, #0ea5a4);
    font-weight: 800;
}

.brand-card h1 {
    margin: 0;
    font-size: 20px;
}

.brand-card p {
    margin: 4px 0 0;
    color: #cbd5e1;
    font-size: 13px;
}

.nav-links {
    display: grid;
    gap: 10px;
}

.nav-links a {
    padding: 14px 16px;
    border-radius: 16px;
    background: rgba(255, 255, 255, 0.05);
}

.nav-links a:hover {
    background: rgba(255, 255, 255, 0.1);
}

.content {
    padding: 28px;
}

.hero,
.section-card,
.panel-card,
.stat-card {
    background: rgba(255, 255, 255, 0.9);
    border: 1px solid rgba(148, 163, 184, 0.15);
    box-shadow: 0 16px 32px rgba(15, 23, 42, 0.06);
}

.hero {
    display: flex;
    justify-content: space-between;
    gap: 24px;
    align-items: flex-start;
    padding: 28px;
    border-radius: 30px;
}

.hero-splash {
    background: linear-gradient(135deg, rgba(15, 118, 110, 0.12), rgba(14, 165, 164, 0.04), rgba(255, 255, 255, 0.9));
    border: 1px solid rgba(13, 148, 136, 0.14);
    position: relative;
    overflow: hidden;
}

.hero-splash::after {
    content: "";
    position: absolute;
    inset: 0 auto 0 auto;
    width: 340px;
    background: radial-gradient(circle, rgba(20, 184, 166, 0.18), transparent 70%);
    transform: translateX(120px);
    pointer-events: none;
}

.hero-copy-wrap {
    position: relative;
    z-index: 1;
    flex: 1.4;
}

.status-pills {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    margin-top: 18px;
}

.status-pill {
    display: inline-flex;
    align-items: center;
    padding: 8px 12px;
    border-radius: 999px;
    background: rgba(15, 118, 110, 0.08);
    color: #115e59;
    font-size: 12px;
    font-weight: 700;
}

.status-pill.success {
    background: rgba(34, 197, 94, 0.12);
    color: #166534;
}

.hero-panel {
    position: relative;
    z-index: 1;
    min-width: 280px;
    max-width: 330px;
    flex: 0.8;
    padding: 18px 18px 14px;
    border-radius: 24px;
    background: rgba(15, 23, 42, 0.92);
    color: #f8fafc;
    box-shadow: 0 18px 36px rgba(15, 23, 42, 0.22);
}

.hero-panel-head {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 18px;
    color: #cbd5e1;
    font-size: 12px;
    letter-spacing: 0.08em;
    text-transform: uppercase;
}

.dot-status {
    display: inline-block;
    width: 10px;
    height: 10px;
    border-radius: 50%;
    background: #34d399;
    box-shadow: 0 0 0 6px rgba(52, 211, 153, 0.18);
}

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

.hero-panel-grid div {
    padding: 12px;
    border-radius: 16px;
    background: rgba(148, 163, 184, 0.08);
}

.hero-panel-grid strong,
.small-summary strong {
    display: block;
    font-size: 24px;
    line-height: 1.2;
}

.hero-panel-grid span,
.small-summary span {
    display: block;
    color: #cbd5e1;
    font-size: 12px;
    margin-top: 4px;
}

.small-summary {
    margin-top: 16px;
    padding-top: 14px;
    border-top: 1px solid rgba(148, 163, 184, 0.18);
}

.hero.compact {
    margin-bottom: 20px;
}

.eyebrow {
    margin: 0 0 10px;
    color: #0f766e;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.08em;
    font-size: 12px;
}

.hero h2 {
    margin: 0;
    max-width: 760px;
    font-size: 32px;
    line-height: 1.2;
}

.hero-copy {
    margin: 14px 0 0;
    max-width: 760px;
    color: #475569;
    line-height: 1.6;
}

.hero-actions {
    display: flex;
    gap: 12px;
    flex-wrap: wrap;
}

.button {
    padding: 14px 18px;
    border-radius: 16px;
    font-weight: 700;
}

.button.primary {
    background: #0f766e;
    color: white;
}

.button.secondary {
    border: 1px solid #0f766e;
    color: #0f766e;
}

.stats-grid,
.panel-grid,
.receipt-grid,
.three-column {
    display: grid;
    gap: 16px;
}

.stats-grid {
    grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
    margin-top: 22px;
}

.stat-card {
    padding: 20px;
    border-radius: 24px;
}

.stat-card span,
.mini-stat span {
    display: block;
    color: #64748b;
    font-size: 13px;
    margin-bottom: 8px;
}

.stat-card strong,
.mini-stat strong {
    font-size: 28px;
}

.section-block,
.two-column,
.three-column {
    margin-top: 24px;
}

.section-heading h3 {
    margin: 0;
    font-size: 22px;
}

.section-heading p {
    margin: 8px 0 0;
    color: #64748b;
}

.panel-grid {
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    margin-top: 16px;
}

.panel-card {
    border-radius: 24px;
    padding: 22px;
}

.panel-card h4 {
    margin: 0 0 10px;
    font-size: 18px;
}

.panel-card p {
    margin: 0 0 16px;
    color: #64748b;
    line-height: 1.5;
}

.panel-links {
    display: flex;
    gap: 12px;
    flex-wrap: wrap;
}

.panel-links a,
.inline-links a {
    padding: 10px 14px;
    border-radius: 14px;
    background: #ecfeff;
    color: #0f766e;
    font-weight: 600;
}

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

.section-card {
    border-radius: 24px;
    padding: 22px;
}

.receipt-grid {
    grid-template-columns: repeat(3, minmax(0, 1fr));
    margin-top: 16px;
}

.mini-stat {
    padding: 18px;
    border-radius: 18px;
    background: #f8fafc;
}

.inline-links {
    display: flex;
    gap: 12px;
    margin-top: 16px;
    flex-wrap: wrap;
}

.control-list {
    margin: 16px 0 0;
    padding-left: 18px;
    color: #475569;
    line-height: 1.8;
}

.three-column {
    grid-template-columns: repeat(3, minmax(0, 1fr));
}

.data-table {
    display: grid;
    gap: 12px;
    margin-top: 18px;
}

.data-head,
.data-row {
    display: grid;
    grid-template-columns: 1.7fr 1.1fr 1.2fr 0.8fr 0.9fr;
    gap: 14px;
    align-items: center;
}

.data-head {
    padding: 0 8px 8px;
    color: #64748b;
    font-size: 13px;
    font-weight: 700;
}

.data-row {
    padding: 16px;
    border-radius: 18px;
    background: #f8fafc;
}

.action-links {
    display: flex;
    gap: 12px;
    flex-wrap: wrap;
}

.action-links a {
    color: #0f766e;
    font-weight: 700;
}

.action-links .danger-link {
    color: #dc2626;
}

.users-grid {
    grid-template-columns: 1fr 1.2fr 1fr 0.8fr 0.8fr 1fr;
}

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

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

.two-row-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
}

.form-field {
    display: grid;
    gap: 8px;
}

.form-field label {
    font-weight: 700;
}

.form-field input,
.form-field select,
.form-field textarea {
    width: 100%;
    padding: 14px 16px;
    border-radius: 16px;
    border: 1px solid #cbd5e1;
    background: #fff;
    font: inherit;
}

.onboarding-hero {
    align-items: center;
    padding: 28px 28px 24px;
}

.hero-metrics {
    display: grid;
    grid-template-columns: repeat(3, minmax(80px, 1fr));
    gap: 12px;
    min-width: min(100%, 320px);
}

.metric {
    padding: 16px 14px;
    border-radius: 18px;
    background: rgba(15, 118, 110, 0.08);
    border: 1px solid rgba(15, 118, 110, 0.12);
    text-align: center;
}

.metric strong {
    display: block;
    font-size: 26px;
    color: #0f766e;
}

.metric span {
    display: block;
    font-size: 12px;
    font-weight: 700;
    color: #334155;
    margin-top: 6px;
    text-transform: uppercase;
    letter-spacing: 0.04em;
}

.onboarding-shell {
    display: grid;
    grid-template-columns: minmax(0, 1.8fr) minmax(260px, 0.8fr);
    gap: 22px;
    margin-top: 22px;
}

.onboarding-main,
.onboarding-side {
    min-height: 100%;
}

.onboarding-form {
    display: grid;
    gap: 22px;
}

.form-section {
    padding: 6px 2px;
}

.section-header {
    display: flex;
    align-items: center;
    gap: 14px;
    margin-bottom: 18px;
}

.section-badge {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 42px;
    height: 42px;
    border-radius: 14px;
    background: linear-gradient(135deg, #0f766e, #14b8a6);
    color: #fff;
    font-size: 12px;
    font-weight: 800;
}

.section-header h3 {
    margin: 0;
    font-size: 22px;
}

.section-header p {
    margin: 6px 0 0;
    color: #64748b;
}

.checkbox-field {
    display: flex;
    flex-direction: row-reverse;
    align-items: center;
    justify-content: flex-start;
    gap: 12px;
    padding: 14px 16px;
    border: 1px solid #dbe7f0;
    border-radius: 16px;
    background: #f8fafc;
}

.checkbox-field input {
    width: 18px;
    height: 18px;
    margin: 0;
}

.checkbox-field label {
    margin: 0;
    font-weight: 600;
}

.aligned-actions {
    margin-top: 4px;
}

.onboarding-side {
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    gap: 20px;
    background: linear-gradient(180deg, rgba(15, 118, 110, 0.04), rgba(255, 255, 255, 0.96));
}

.side-summary h3 {
    margin: 0;
    font-size: 26px;
}

.check-list {
    margin: 0;
    padding-left: 18px;
    color: #475569;
    line-height: 1.9;
}

.mini-panel {
    padding: 18px 18px 16px;
    border-radius: 18px;
    background: rgba(15, 23, 42, 0.92);
    color: #e2e8f0;
}

.mini-panel span {
    display: block;
    color: #94a3b8;
    font-size: 12px;
    letter-spacing: 0.08em;
    text-transform: uppercase;
    margin-bottom: 8px;
}

.mini-panel strong {
    display: block;
    line-height: 1.5;
    font-size: 16px;
}

@media (max-width: 900px) {
    .onboarding-shell {
        grid-template-columns: 1fr;
    }
}

@media (max-width: 640px) {
    .hero-metrics {
        grid-template-columns: repeat(3, minmax(70px, 1fr));
    }

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

    .onboarding-hero {
        flex-direction: column;
    }
}

.select-search {
    border-color: #99f6e4 !important;
    background: #f0fdfa !important;
}

.form-actions {
    display: flex;
    gap: 12px;
    flex-wrap: wrap;
    margin-top: 8px;
}

.button.danger {
    background: #dc2626;
    color: #fff;
}

.error-text {
    color: #dc2626;
}

.error-banner {
    padding: 14px 16px;
    border-radius: 16px;
    background: #fef2f2;
    color: #dc2626;
    font-weight: 600;
}

.filter-card {
    margin-bottom: 18px;
}

.filter-form {
    display: grid;
    grid-template-columns: minmax(220px, 1fr) minmax(180px, 260px) auto;
    gap: 14px;
    align-items: end;
}

.filter-form label {
    display: block;
    margin-bottom: 8px;
    font-weight: 800;
}

.filter-form input,
.filter-form select {
    width: 100%;
    padding: 14px 16px;
    border: 1px solid #cbd5e1;
    border-radius: 16px;
    background: #fff;
    font: inherit;
}

.filter-actions {
    display: flex;
    gap: 10px;
    flex-wrap: wrap;
}

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

.simple-table table {
    width: 100%;
    border-collapse: collapse;
    margin-top: 12px;
}

.simple-table th,
.simple-table td {
    text-align: left;
    padding: 14px 12px;
    border-bottom: 1px solid #e2e8f0;
}

.simple-table th {
    color: #64748b;
    font-size: 13px;
    text-transform: uppercase;
    letter-spacing: 0.04em;
}

.muted {
    color: #64748b;
    font-size: 13px;
}

.row-actions {
    display: flex;
    align-items: center;
    gap: 8px;
    flex-wrap: wrap;
}

.row-actions.stacked {
    align-items: flex-start;
}

.row-actions form {
    margin: 0;
}

.small-action {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border: 0;
    cursor: pointer;
    padding: 9px 12px;
    border-radius: 12px;
    background: #ecfeff;
    color: #0f766e;
    font: inherit;
    font-size: 13px;
    font-weight: 800;
}

.small-action.ghost {
    background: #f8fafc;
    color: #334155;
}

.small-action.success {
    background: #dcfce7;
    color: #15803d;
}

.small-action.danger {
    background: #fef2f2;
    color: #dc2626;
}

.status-badge {
    display: inline-flex;
    padding: 8px 11px;
    border-radius: 999px;
    background: #f8fafc;
    color: #334155;
    font-size: 12px;
    font-weight: 800;
    text-transform: capitalize;
}

.status-pending,
.status-requested {
    background: #fef3c7;
    color: #b45309;
}

.status-received,
.status-accepted,
.status-received_at_station,
.status-payment_confirmed,
.status-waiting_loading,
.status-loaded,
.status-approved,
.status-agent,
.status-manager,
.status-admin {
    background: #ccfbf1;
    color: #0f766e;
}

.status-in_transit,
.status-departed,
.status-driver {
    background: #dbeafe;
    color: #2563eb;
}

.status-arrived_destination,
.status-ready_for_pickup {
    background: #fef3c7;
    color: #b45309;
}

.status-delivered,
.status-picked_up,
.status-paid,
.status-user {
    background: #dcfce7;
    color: #15803d;
}

.status-cancelled,
.status-rejected {
    background: #fee2e2;
    color: #dc2626;
}

.table-list {
    display: grid;
    gap: 12px;
    margin-top: 16px;
}

.table-row {
    display: grid;
    gap: 4px;
    padding: 14px;
    border-radius: 16px;
    background: #f8fafc;
}

.table-row span {
    color: #475569;
}

.table-row em {
    font-style: normal;
    color: #0f766e;
    font-weight: 700;
}

.operations-alerts {
    margin-top: 22px;
}

.operations-alerts .mini-stat {
    color: inherit;
    text-decoration: none;
    transition: transform .15s ease, box-shadow .15s ease;
}

.operations-alerts .mini-stat:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 20px rgba(15, 118, 110, .12);
}

@media (max-width: 1080px) {
    .page-shell {
        grid-template-columns: 1fr;
    }

    .sidebar {
        padding-bottom: 12px;
    }

    .hero,
    .two-column,
    .three-column {
        grid-template-columns: 1fr;
        display: grid;
    }

    .form-grid,
    .data-head,
    .data-row,
    .filter-form {
        grid-template-columns: 1fr;
    }
}

@media (max-width: 640px) {
    .content { min-width: 0; padding: 16px; }
    .hero-panel { min-width: 0; width: 100%; }
    .receipt-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
    .data-row, .panel-card, .mini-stat { overflow-wrap: anywhere; }
    .nav-links { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); }
}
/* Role workspaces use the same visual system as company management. */
.workspace-section { margin-top: 22px; padding: 24px; min-width: 0; }
.workspace-section h3 { margin: 0 0 16px; }
.workspace-form { display: grid; gap: 14px; max-width: 640px; margin: 18px 0; }
.workspace-form label { display: grid; gap: 7px; font-weight: 600; }
.workspace-form input, .workspace-form select { width: 100%; min-width: 0; padding: 14px; border: 1px solid #cbd5e1; border-radius: 12px; font: inherit; background: white; }
.workspace-form [role=status] { line-height: 1.5; overflow-wrap: anywhere; }
.workspace-event { padding: 12px 16px; border-left: 3px solid #0f766e; margin: 12px 0; background: #f0fdfa; }

/* Shared controls remain usable with narrow screens, zoom and keyboards. */
.language-switch { display: flex; justify-content: flex-end; align-items: center; flex-wrap: wrap; gap: 10px; padding: 10px 24px; background: #fff; border-bottom: 1px solid #e2e8f0; }
.language-switch select { min-height: 44px; max-width: 100%; border: 1px solid #cbd5e1; border-radius: 10px; padding: 8px 12px; font: inherit; }
.language-switch .button { min-height: 44px; padding: 10px 16px; }
.content, .section-card, .table-card, .hero-copy-wrap, .form-field { min-width: 0; }
.content { max-width: 1680px; width: 100%; }
.simple-table { max-width: 100%; overflow-x: auto; overscroll-behavior-x: contain; }
.simple-table table { min-width: 720px; }
.table-wrap { width: 100%; max-width: 100%; min-width: 0; overflow-x: auto; overscroll-behavior-x: contain; }
.table-wrap table { width: 100%; min-width: 720px; border-collapse: collapse; }
.table-wrap th, .table-wrap td { padding: 12px; text-align: left; vertical-align: top; overflow-wrap: anywhere; }
.simple-table th, .simple-table td { overflow-wrap: anywhere; }
.hero-actions, .form-actions, .row-actions { flex-wrap: wrap; }
input, select, textarea { max-width: 100%; font-size: max(16px, 1em); }
button, .button, .small-action { touch-action: manipulation; }
button:focus-visible, a:focus-visible, input:focus-visible, select:focus-visible, textarea:focus-visible { outline: 3px solid #14b8a6; outline-offset: 3px; }
@media (min-width: 1081px) { .sidebar { position: sticky; top: 0; max-height: 100dvh; overflow-y: auto; align-self: start; } }
@media (max-width: 760px) {
  .language-switch { padding: 8px 16px; }
  .hero { padding: 22px; }
  .workspace-section { padding: 18px; }
  .hero-actions .button, .form-actions .button { flex: 1 1 160px; text-align: center; }
  .workspace-form button { white-space: normal; }
  .simple-table { border-radius: 12px; }
}
@media (prefers-reduced-motion: reduce) { *, *::before, *::after { scroll-behavior: auto !important; transition: none !important; animation: none !important; } }
