* {
    box-sizing: border-box;
}

:root {
    --mlc-primary: #c89b2c;
    --mlc-secondary: #1e2329;
    --mlc-text: #555d66;
    --mlc-accent: #f2e7cf;
    --mlc-background: #f8f8f5;
    --mlc-success: #3fae5a;
    --mlc-warning: #f4a825;
    --mlc-error: #d9534f;
    --mlc-sky: #4c8fd6;
    --mlc-white: #ffffff;
    --mlc-panel: #ffffff;
    --mlc-border: rgba(30, 35, 41, .13);
    --mlc-shadow: 0 18px 42px rgba(30, 35, 41, .12);
}

html,
body {
    margin: 0;
    min-height: 100%;
    font-family: Arial, Helvetica, sans-serif;
    background: var(--mlc-background);
    color: var(--mlc-secondary);
    overflow-x: hidden;
}

a {
    color: inherit;
}

/* ===== HEADER ===== */

.topbar {
    min-height: 64px;
    background: #11131a;
    border-bottom: 1px solid rgba(255,255,255,.12);
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 18px;
    padding: 0 24px;
    width: 100%;
    position: relative;
    z-index: 99999;
    overflow: visible;
}

.brand {
    flex: 0 0 auto;
}

.brand a {
    color: #ffffff;
    text-decoration: none;
    font-size: 20px;
    font-weight: 900;
    letter-spacing: .2px;
}

.brand a:hover {
    color: #f2c230;
}

.menu {
    display: flex;
    align-items: center;
    justify-content: flex-end;
    flex-wrap: wrap;
    gap: 8px;
    flex: 1 1 auto;
    min-width: 0;
    overflow: visible;
}

.menu a,
.menu-dropbtn {
    color: #ffffff;
    text-decoration: none;
    font-weight: 800;
    font-size: 15px;
    padding: 10px 12px;
    border-radius: 999px;
    opacity: .95;
    white-space: nowrap;
    transition: background .2s ease, color .2s ease, transform .2s ease;
}

.menu a:hover,
.menu-dropbtn:hover {
    background: rgba(242,194,48,.14);
    color: #f2c230;
    transform: translateY(-1px);
}

.menu-dropdown {
    position: relative;
    overflow: visible;
}

.menu-dropbtn {
    border: 0;
    background: transparent;
    cursor: pointer;
    font-family: inherit;
}

.menu-dropdown-content {
    display: none;
    position: absolute;
    right: 0;
    top: 100%;
    min-width: 200px;
    background: #17171b;
    border: 1px solid rgba(255,255,255,.12);
    border-radius: 16px;
    box-shadow: 0 18px 45px rgba(0,0,0,.45);
    padding: 8px;
    z-index: 100000;
}

.menu-dropdown-content::before {
    content: "";
    position: absolute;
    left: 0;
    right: 0;
    top: -18px;
    height: 18px;
}

.menu-dropdown:hover .menu-dropdown-content,
.menu-dropdown-content:hover,
.menu-dropdown:focus-within .menu-dropdown-content {
    display: block;
}

.menu-dropdown-content a {
    display: block;
    color: #ffffff;
    padding: 11px 14px;
    border-radius: 12px;
    white-space: nowrap;
}

.menu-dropdown-content a:hover {
    background: rgba(242,194,48,.16);
    color: #f2c230;
    transform: none;
}

.lunch-link {
    background: #f2c230;
    color: #101014 !important;
    opacity: 1 !important;
}

.lunch-link:hover {
    background: #ffd84a !important;
    color: #101014 !important;
}

/* ===== MAIN LAYOUT ===== */

.page {
    min-height: calc(100vh - 114px);
    display: grid;
    grid-template-columns: 340px minmax(0, 1fr);
    gap: 18px;
    padding: 18px;
    position: relative;
    z-index: 1;
}

.sidebar,
.map-card,
.lunch-hero,
.payment-card,
.route-state,
.empty-card,
.admin-card,
.content-card {
    background: rgba(255,255,255,.06);
    border: 1px solid rgba(255,255,255,.12);
    border-radius: 20px;
}

.sidebar,
.payment-card,
.route-state,
.empty-card,
.admin-card,
.content-card {
    padding: 24px;
}

.map-card {
    overflow: hidden;
    min-width: 0;
    min-height: 72vh;
    position: relative;
    z-index: 1;
}

.logo {
    width: 100%;
    max-width: 280px;
    margin: 48px auto 28px;
    display: block;
}

.sidebar h1 {
    margin: 0 0 18px;
    font-size: 28px;
}

.sidebar p,
.lunch-hero p,
.payment-card p,
.empty-card p,
.route-state p,
.admin-card p {
    color: #d7d7df;
    line-height: 1.45;
}

.status {
    display: block;
    margin-top: 24px;
    padding: 10px 14px;
    border-radius: 999px;
    font-weight: 800;
    text-align: center;
}

.status.active {
    background: #1f8f4d;
}

.status.inactive {
    background: #666;
}

/* ===== BUTTONS ===== */

.btn,
.payment-card a,
.route-link,
.admin-card button {
    display: inline-block;
    padding: 12px 18px;
    border-radius: 10px;
    background: var(--mlc-primary);
    color: var(--mlc-secondary);
    text-decoration: none;
    font-weight: 800;
    border: 0;
    cursor: pointer;
}

.btn {
    display: block;
    margin-top: 14px;
    text-align: center;
}

.btn:hover,
.payment-card a:hover,
.route-link:hover,
.admin-card button:hover {
    background: var(--mlc-warning);
}

/* ===== LIVE RIDE AREA ===== */

iframe {
    width: 100%;
    height: 100%;
    min-height: 72vh;
    border: 0;
    position: relative;
    z-index: 1;
}

.inactive-screen {
    min-height: 72vh;
    height: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
    text-align: center;
    padding: 32px;
    background:
        radial-gradient(circle at center, rgba(200,155,44,.16), transparent 45%),
        #151720;
}

.inactive-screen h2 {
    font-size: 34px;
    margin: 0 0 12px;
}

.inactive-screen p {
    color: #d7d7df;
    font-size: 17px;
}

/* ===== RIDE DASHBOARD ===== */

.ride-dashboard {
    width: min(760px, 92%);
    margin: 0 auto;
    text-align: center;
    padding: 44px;
    border-radius: 28px;
    background:
        radial-gradient(circle at top, rgba(200,155,44,.18), transparent 42%),
        rgba(255,255,255,.045);
    border: 1px solid rgba(255,255,255,.12);
    box-shadow: 0 24px 60px rgba(0,0,0,.35);
}

.ride-dashboard h1 {
    margin: 18px 0 12px;
    font-size: clamp(2rem, 4vw, 3.4rem);
    line-height: 1.05;
}

.ride-dashboard-text {
    max-width: 660px;
    margin: 0 auto;
    color: #e7e7ef;
    font-size: 1.05rem;
    line-height: 1.6;
}

.status-badge {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    padding: 11px 20px;
    border-radius: 999px;
    font-weight: 900;
    letter-spacing: 1.5px;
    font-size: .85rem;
}

.status-badge.live {
    background: rgba(0,255,132,.14);
    border: 1px solid rgba(0,255,132,.46);
    color: #4dff9f;
    box-shadow: 0 0 26px rgba(0,255,132,.16);
}

.status-badge.offline {
    background: rgba(255,255,255,.07);
    border: 1px solid rgba(255,255,255,.14);
    color: #c7c7d3;
}

.live-dot {
    width: 12px;
    height: 12px;
    border-radius: 50%;
    background: #00ff84;
    animation: pulseDot 1.4s infinite;
}

@keyframes pulseDot {
    0% {
        transform: scale(1);
        opacity: 1;
    }

    50% {
        transform: scale(1.55);
        opacity: .35;
    }

    100% {
        transform: scale(1);
        opacity: 1;
    }
}

.ride-feature-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 14px;
    margin: 32px auto 0;
}

.ride-feature {
    padding: 18px 14px;
    border-radius: 18px;
    background: rgba(255,255,255,.055);
    border: 1px solid rgba(255,255,255,.10);
}

.feature-label {
    display: block;
    margin-bottom: 7px;
    color: #a9a9bb;
    font-size: .78rem;
    text-transform: uppercase;
    letter-spacing: 1px;
}

.ride-feature strong {
    color: #ffffff;
    font-size: 1rem;
}

.ride-dashboard-note {
    margin: 28px auto 0;
    max-width: 620px;
    padding: 17px 20px;
    border-radius: 18px;
    background: rgba(255,203,51,.08);
    border: 1px solid rgba(255,203,51,.22);
    color: #f4e7b5;
    line-height: 1.5;
}

/* ===== CONTENT PAGES ===== */

.content-page {
    min-height: calc(100vh - 114px);
    padding: 32px 18px;
    max-width: 1100px;
    margin: 0 auto;
}

.content-card {
    overflow: auto;
}

.content-card h1 {
    margin-top: 0;
    font-size: 42px;
}

.content-card h2 {
    margin-top: 30px;
    margin-bottom: 10px;
    color: #f2c230;
}

.content-card p,
.content-card li {
    color: #d7d7df;
    line-height: 1.58;
    font-size: 17px;
}

.content-card ul {
    padding-left: 24px;
}

.page-intro {
    text-align: center;
    margin-bottom: 28px;
}

.page-intro.text-left {
    text-align: left;
}

.page-intro p {
    max-width: 820px;
    margin: 0 auto 24px;
}

.page-intro.text-left p {
    margin-left: 0;
    margin-right: 0;
}

/* ===== LUNCH PAGE ===== */

.lunch-hero {
    padding: 36px 28px;
    text-align: center;
    margin-bottom: 24px;
}

.lunch-hero h1 {
    margin: 0 0 14px;
    font-size: 42px;
}

.lunch-hero p {
    max-width: 760px;
    margin: 0 auto 24px;
    font-size: 18px;
}

.primary-pay-btn {
    display: inline-block;
    padding: 16px 26px;
    border-radius: 999px;
    background: #f2c230;
    color: #11131a;
    text-decoration: none;
    font-weight: 900;
    font-size: 18px;
}

.primary-pay-btn:hover {
    background: #ffd95a;
}

.payment-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 18px;
}

.payment-card h2,
.route-state h2,
.empty-card h2 {
    margin: 0 0 12px;
    font-size: 26px;
}

.payment-card p {
    margin: 0 0 14px;
}

.pay-handle {
    background: rgba(0,0,0,.25);
    border: 1px solid rgba(255,255,255,.12);
    border-radius: 12px;
    padding: 13px 14px;
    margin: 0 0 14px;
    font-size: 20px;
    font-weight: 900;
    word-break: break-word;
}

/* ===== ROUTES ===== */

.route-state {
    margin-bottom: 22px;
}

.route-city-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 16px;
}

.route-city-card {
    background: rgba(0,0,0,.22);
    border: 1px solid rgba(255,255,255,.1);
    border-radius: 16px;
    padding: 18px;
}

.route-city-card h3 {
    margin: 0 0 12px;
    font-size: 22px;
}

.route-link {
    display: block;
    margin-top: 10px;
    text-align: center;
}

.muted {
    color: #aaa !important;
}

code {
    background: rgba(0,0,0,.35);
    border: 1px solid rgba(255,255,255,.12);
    padding: 2px 6px;
    border-radius: 6px;
}

/* ===== ADMIN ===== */

.admin-page {
    min-height: 100vh;
    padding: 24px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.admin-card {
    width: 100%;
    max-width: 720px;
}

.admin-card h1 {
    margin-top: 0;
}

.admin-card textarea {
    width: 100%;
    min-height: 160px;
    border-radius: 12px;
    border: 1px solid rgba(255,255,255,.18);
    background: rgba(0,0,0,.3);
    color: #fff;
    padding: 14px;
    font-size: 16px;
    resize: vertical;
}

.admin-card button {
    width: 100%;
    margin-top: 14px;
    font-size: 17px;
}

.admin-card .ride-start-form {
    display: grid;
    gap: 14px;
}

.admin-card .ride-start-form > label:not(.notify-choice) {
    display: grid;
    gap: 7px;
    font-weight: 800;
}

.admin-card .ride-start-form input[type="text"] {
    width: 100%;
    box-sizing: border-box;
    border-radius: 10px;
    padding: 13px 14px;
    font-size: 16px;
}

.admin-card .ride-start-form .notify-choice {
    display: flex;
    align-items: center;
    gap: 10px;
    font-weight: 800;
}

.admin-card .ride-start-form .notify-choice input {
    flex: 0 0 auto;
    width: 20px;
    height: 20px;
}

.admin-card .secondary-button {
    background: #333844;
}

.current-link {
    margin: 18px 0;
    padding: 14px;
    border-radius: 12px;
    background: rgba(0,0,0,.25);
    word-break: break-word;
}

.success {
    margin-top: 15px;
    color: #7dffac;
    font-weight: 800;
}

.error {
    margin-top: 15px;
    color: #ff7676;
    font-weight: 800;
}

.admin-links {
    margin-top: 20px;
}

/* ===== FOOTER ===== */

.footer {
    min-height: 50px;
    background: #11131a;
    border-top: 1px solid rgba(255,255,255,.12);
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 18px;
    flex-wrap: wrap;
    color: #bdbdc8;
    font-size: 14px;
    padding: 12px;
    text-align: center;
}

.footer-links {
    display: inline-flex;
    gap: 12px;
}

.footer-links a {
    color: #d7d7df;
    text-decoration: none;
}

.footer-links a:hover {
    color: #f2c230;
}

/* ===== MOBILE ===== */

@media (max-width: 900px) {
    .topbar {
        height: auto;
        min-height: auto;
        align-items: flex-start;
        flex-direction: column;
        gap: 12px;
        padding: 16px 18px;
    }

    .menu {
        width: 100%;
        justify-content: flex-start;
        flex-wrap: wrap;
        gap: 10px;
    }

    .menu-dropdown-content {
        left: 0;
        right: auto;
    }

    .page {
        grid-template-columns: 1fr;
    }

    .sidebar {
        text-align: center;
    }

    .logo {
        margin-top: 20px;
    }

    .ride-dashboard {
        padding: 30px 20px;
    }

    .ride-feature-grid {
        grid-template-columns: 1fr;
    }
}

@media (max-width: 750px) {
    .content-card {
        padding: 22px;
    }

    .content-card h1,
    .lunch-hero h1 {
        font-size: 34px;
    }

    .menu a,
    .menu-dropbtn {
        font-size: 14px;
        padding: 9px 11px;
    }
}

/* ===== REDESIGNED HOME + ADMIN ===== */

.login-link {
    border: 1px solid rgba(255,255,255,.22);
    background: rgba(255,255,255,.07);
}

.home-shell {
    display: grid;
    gap: 18px;
    padding: 18px;
}

.home-hero {
    display: grid;
    grid-template-columns: minmax(220px, 340px) minmax(0, 1fr);
    gap: 18px;
}

.home-logo-panel,
.home-live-panel,
.home-map-panel,
.home-card,
.admin-status-card,
.admin-action-grid a {
    background: rgba(255,255,255,.06);
    border: 1px solid rgba(255,255,255,.12);
    border-radius: 18px;
}

.home-logo-panel {
    display: grid;
    place-items: center;
    padding: 26px;
}

.home-logo {
    width: min(100%, 280px);
    display: block;
}

.home-live-panel {
    padding: 34px;
    display: flex;
    flex-direction: column;
    justify-content: center;
}

.eyebrow {
    margin: 0 0 10px;
    color: #f2c230 !important;
    font-weight: 900;
    text-transform: uppercase;
    letter-spacing: .08em;
    font-size: 13px;
}

.home-live-panel h1 {
    margin: 0 0 12px;
    font-size: clamp(34px, 6vw, 64px);
    line-height: 1;
}

.home-live-panel p {
    max-width: 760px;
    margin: 0;
    color: #d7d7df;
    font-size: 18px;
    line-height: 1.5;
}

.home-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    margin-top: 24px;
}

.live-ride-details {
    display: grid;
    gap: 6px;
    width: min(100%, 560px);
    margin-top: 20px;
    padding: 15px 16px;
    border-radius: 14px;
    background: rgba(0,0,0,.22);
    border: 1px solid rgba(255,255,255,.1);
}

.live-ride-details strong {
    font-size: 18px;
}

.live-ride-details span {
    color: #d7d7df;
}

.home-actions .btn {
    width: auto;
    margin: 0;
}

.secondary-button {
    background: #333844 !important;
}

.home-map-panel {
    overflow: hidden;
    min-height: 60vh;
}

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

.rider-bio-section {
    background: rgba(255,255,255,.06);
    border: 1px solid rgba(255,255,255,.12);
    border-radius: 18px;
    padding: 26px;
}

.section-heading {
    max-width: 760px;
    margin-bottom: 18px;
}

.section-heading h2 {
    margin: 0 0 8px;
    font-size: clamp(28px, 4vw, 42px);
}

.section-heading p {
    margin: 0;
    color: #d7d7df;
    line-height: 1.5;
}

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

.rider-bio-card {
    position: relative;
    padding: 20px;
    border-radius: 16px;
    background: rgba(0,0,0,.22);
    border: 1px solid rgba(255,255,255,.1);
}

.rider-bio-card span {
    display: block;
    width: 18px;
    height: 18px;
    border-radius: 50%;
    margin-bottom: 14px;
}

.rider-bio-card h3 {
    margin: 0 0 8px;
    font-size: 24px;
}

.rider-bio-card p {
    margin: 0;
    color: #d7d7df;
    line-height: 1.5;
}

.home-card {
    display: block;
    padding: 22px;
    text-decoration: none;
    color: #fff;
}

.home-card span {
    display: block;
    color: #f2c230;
    font-size: 13px;
    font-weight: 900;
    text-transform: uppercase;
    margin-bottom: 8px;
}

.home-card strong {
    display: block;
    font-size: 22px;
    margin-bottom: 8px;
}

.home-card p {
    margin: 0;
    color: #d7d7df;
    line-height: 1.45;
}

.admin-home {
    min-height: 100vh;
    padding: 24px;
    background: #0b0b0f;
}

.admin-hero {
    display: grid;
    grid-template-columns: minmax(0, 1fr) 260px;
    gap: 18px;
    align-items: stretch;
    margin-bottom: 18px;
    padding: 28px;
    background: rgba(255,255,255,.06);
    border: 1px solid rgba(255,255,255,.12);
    border-radius: 18px;
}

.admin-hero h1 {
    margin: 0 0 10px;
    font-size: clamp(32px, 5vw, 56px);
}

.admin-hero p {
    color: #d7d7df;
}

.admin-status-card {
    padding: 18px;
    display: grid;
    align-content: center;
    gap: 12px;
}

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

.admin-action-grid a {
    color: #fff;
    text-decoration: none;
    padding: 22px;
}

.admin-action-grid strong,
.admin-action-grid span {
    display: block;
}

.admin-action-grid strong {
    font-size: 22px;
    margin-bottom: 8px;
}

.admin-action-grid span {
    color: #d7d7df;
}

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

.rider-form label {
    display: grid;
    gap: 6px;
    font-weight: 800;
}

.rider-form input:not([type="checkbox"]):not([type="color"]) {
    width: 100%;
    border-radius: 10px;
    border: 1px solid rgba(255,255,255,.18);
    background: rgba(0,0,0,.3);
    color: #fff;
    padding: 12px;
}

.rider-bio-field,
.content-form label {
    grid-column: 1 / -1;
}

.rider-bio-field textarea {
    min-height: 110px;
}

.rider-form button {
    grid-column: 1 / -1;
}

.check-row {
    display: flex !important;
    align-items: center;
    gap: 10px !important;
}

.rider-list {
    display: grid;
    gap: 12px;
}

.rider-row {
    display: grid;
    grid-template-columns: 18px minmax(0, 1fr) auto;
    gap: 12px;
    align-items: center;
    padding: 12px;
    border-radius: 12px;
    background: rgba(0,0,0,.2);
}

.rider-row span {
    width: 18px;
    height: 18px;
    border-radius: 50%;
}

.rider-row p {
    margin: 4px 0 0;
}

.rider-row-actions {
    display: grid;
    justify-items: end;
    gap: 6px;
}

.rider-row-actions a {
    color: #f2c230;
    font-weight: 800;
}

.login-card {
    max-width: 520px;
}

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

.login-form label {
    display: grid;
    gap: 6px;
    font-weight: 800;
}

.login-form input:not([type="checkbox"]) {
    width: 100%;
    border-radius: 10px;
    border: 1px solid rgba(255,255,255,.18);
    background: rgba(0,0,0,.3);
    color: #fff;
    padding: 13px 14px;
    font-size: 16px;
}

.admin-wide-card {
    max-width: 860px;
}

.content-form {
    display: grid;
    gap: 14px;
}

.content-form label {
    display: grid;
    gap: 7px;
    font-weight: 800;
}

.content-form input {
    width: 100%;
    border-radius: 10px;
    border: 1px solid rgba(255,255,255,.18);
    background: rgba(0,0,0,.3);
    color: #fff;
    padding: 13px 14px;
    font-size: 16px;
}

.content-form textarea {
    min-height: 110px;
}

@media (max-width: 900px) {
    .topbar {
        position: sticky;
        top: 0;
        align-items: stretch;
    }

    .menu {
        flex-wrap: nowrap;
        overflow-x: auto;
        padding-bottom: 4px;
    }

    .home-hero,
    .admin-hero,
    .home-card-grid,
    .rider-bio-grid,
    .admin-action-grid,
    .rider-form {
        grid-template-columns: 1fr;
    }

    .home-live-panel {
        padding: 24px;
    }
}

/* ===== FUN MIDLIFE CYCLES WORDPRESS THEME ===== */

body {
    background:
        linear-gradient(180deg, rgba(30,35,41,.05), rgba(248,248,245,0) 240px),
        var(--mlc-background);
    color: var(--mlc-secondary);
}

.topbar {
    min-height: 92px;
    background: var(--mlc-secondary);
    border-bottom: 4px solid var(--mlc-primary);
    padding: 18px clamp(16px, 4vw, 64px);
    box-shadow: 0 12px 30px rgba(30,35,41,.18);
}

.brand a {
    display: inline-flex;
    align-items: center;
    color: var(--mlc-accent);
    font-size: clamp(22px, 3vw, 32px);
    font-weight: 900;
    letter-spacing: 0;
    text-transform: uppercase;
}

.brand a::before {
    display: none;
}

.topbar-logo {
    width: 54px;
    height: 54px;
    object-fit: contain;
    margin-right: 12px;
    filter: drop-shadow(0 6px 12px rgba(0,0,0,.24));
}

.brand a:hover,
.menu a:hover,
.menu-dropbtn:hover,
.menu-dropdown-content a:hover,
.footer-links a:hover {
    color: var(--mlc-primary);
}

.menu {
    gap: 10px;
}

.menu a,
.menu-dropbtn {
    color: var(--mlc-primary);
    border-radius: 4px;
    font-size: 16px;
    font-weight: 800;
    padding: 10px 11px;
}

.menu a:hover,
.menu-dropbtn:hover {
    background: rgba(200,155,44,.12);
    transform: none;
}

.menu-dropdown-content {
    background: var(--mlc-secondary);
    border-color: rgba(242,231,207,.2);
    border-radius: 6px;
}

.lunch-link {
    background: var(--mlc-primary);
    color: var(--mlc-secondary) !important;
    border-radius: 999px !important;
}

.lunch-link:hover,
.primary-pay-btn:hover {
    background: var(--mlc-warning) !important;
    color: var(--mlc-secondary) !important;
}

.login-link {
    color: var(--mlc-accent) !important;
    border-color: rgba(242,231,207,.55);
    background: transparent;
    border-radius: 999px !important;
}

.home-shell,
.page,
.content-page,
.admin-home {
    width: min(100%, 1180px);
    margin: 0 auto;
    padding: clamp(16px, 3vw, 34px);
}

.home-hero {
    grid-template-columns: minmax(220px, 360px) minmax(0, 1fr);
}

.sidebar,
.map-card,
.lunch-hero,
.payment-card,
.route-state,
.empty-card,
.admin-card,
.content-card,
.home-logo-panel,
.home-live-panel,
.home-map-panel,
.home-card,
.rider-bio-section,
.admin-hero,
.admin-status-card,
.admin-action-grid a {
    background: var(--mlc-panel);
    border: 1px solid var(--mlc-border);
    border-radius: 8px;
    box-shadow: var(--mlc-shadow);
}

.home-logo-panel {
    background:
        linear-gradient(180deg, rgba(242,231,207,.78), rgba(255,255,255,.92)),
        var(--mlc-panel);
}

.home-logo {
    filter: drop-shadow(0 12px 26px rgba(30,35,41,.18));
}

.home-live-panel {
    position: relative;
    overflow: hidden;
    min-height: 310px;
    border-left: 7px solid var(--mlc-primary);
}

.home-live-panel::after {
    content: "";
    position: absolute;
    right: -80px;
    bottom: -80px;
    width: 240px;
    height: 240px;
    border: 24px solid rgba(76,143,214,.12);
    border-radius: 50%;
}

.eyebrow,
.home-card span,
.content-card h2,
.storage-diagnostics dt,
.rider-row-actions a {
    color: var(--mlc-primary) !important;
    font-style: italic;
    letter-spacing: .08em;
}

.home-live-panel h1,
.ride-dashboard h1,
.content-card h1,
.lunch-hero h1,
.admin-hero h1,
.admin-card h1,
.section-heading h2 {
    color: var(--mlc-secondary);
    font-weight: 900;
}

.home-live-panel h1 {
    max-width: 850px;
    font-size: clamp(42px, 7vw, 76px);
    line-height: .96;
}

.home-live-panel p,
.home-card p,
.rider-bio-card p,
.section-heading p,
.content-card p,
.content-card li,
.sidebar p,
.lunch-hero p,
.payment-card p,
.empty-card p,
.route-state p,
.admin-card p,
.admin-hero p,
.admin-action-grid span {
    color: var(--mlc-text);
}

.btn,
.payment-card a,
.route-link,
.admin-card button,
.primary-pay-btn {
    background: var(--mlc-primary);
    color: var(--mlc-secondary);
    border-radius: 4px;
    box-shadow: 0 10px 22px rgba(200,155,44,.25);
}

.btn:hover,
.payment-card a:hover,
.route-link:hover,
.admin-card button:hover {
    background: var(--mlc-warning);
    color: var(--mlc-secondary);
}

.secondary-button {
    background: var(--mlc-secondary) !important;
    color: var(--mlc-accent) !important;
    box-shadow: none !important;
}

.home-map-panel {
    min-height: 54vh;
}

.inactive-screen {
    min-height: 54vh;
    background:
        linear-gradient(110deg, rgba(30,35,41,.9), rgba(30,35,41,.76)),
        var(--mlc-secondary);
}

.ride-dashboard {
    border-radius: 8px;
    background: rgba(248,248,245,.96);
    border: 1px solid rgba(242,231,207,.8);
    box-shadow: 0 24px 60px rgba(0,0,0,.28);
}

.ride-dashboard h1 {
    color: var(--mlc-secondary);
}

.ride-dashboard-text {
    color: var(--mlc-text);
}

.status-badge.offline {
    background: var(--mlc-secondary);
    border-color: var(--mlc-secondary);
    color: var(--mlc-accent);
}

.status-badge.live {
    background: rgba(63,174,90,.12);
    border-color: var(--mlc-success);
    color: var(--mlc-success);
}

.live-dot {
    background: var(--mlc-success);
}

.home-card,
.admin-action-grid a {
    transition: transform .2s ease, border-color .2s ease, box-shadow .2s ease;
}

.home-card:hover,
.admin-action-grid a:hover {
    transform: translateY(-3px);
    border-color: rgba(200,155,44,.5);
    box-shadow: 0 22px 46px rgba(30,35,41,.16);
}

.home-card strong,
.rider-bio-card h3,
.route-city-card h3,
.payment-card h2,
.route-state h2,
.empty-card h2 {
    color: var(--mlc-secondary);
}

.rider-bio-card,
.route-city-card,
.rider-row,
.current-link,
.live-ride-details,
.pay-handle {
    background: rgba(30,35,41,.04);
    border-color: var(--mlc-border);
}

.rider-bio-card span,
.rider-row span {
    box-shadow: 0 0 0 4px rgba(30,35,41,.07);
}

.footer {
    background: var(--mlc-secondary);
    border-top: 4px solid var(--mlc-primary);
    color: var(--mlc-accent);
}

.footer-links a {
    color: var(--mlc-accent);
}

.admin-home,
.admin-page {
    background:
        linear-gradient(180deg, rgba(30,35,41,.04), rgba(248,248,245,0) 240px),
        var(--mlc-background);
}

.admin-card textarea,
.rider-form input:not([type="checkbox"]):not([type="color"]),
.login-form input:not([type="checkbox"]),
.content-form input,
.content-form textarea,
.ride-start-form input {
    background: var(--mlc-white);
    border: 1px solid rgba(85,93,102,.28);
    color: var(--mlc-secondary);
}

.success,
.status.active {
    color: var(--mlc-white);
    background: var(--mlc-success);
}

.error,
.ride-stop-form button {
    color: var(--mlc-white) !important;
    background: var(--mlc-error) !important;
}

.status.inactive {
    background: var(--mlc-text);
    color: var(--mlc-white);
}

.muted {
    color: var(--mlc-text) !important;
}

code {
    background: rgba(30,35,41,.06);
    border-color: var(--mlc-border);
    color: var(--mlc-secondary);
}

@media (max-width: 900px) {
    .topbar {
        background: var(--mlc-secondary);
        padding: 14px 16px;
    }

    .brand a::before {
        width: 8px;
        height: 34px;
        margin-right: 10px;
    }

    .topbar-logo {
        width: 42px;
        height: 42px;
        margin-right: 9px;
    }

    .menu {
        flex-wrap: nowrap;
        overflow-x: auto;
    }

    .home-live-panel h1 {
        font-size: clamp(36px, 12vw, 54px);
    }
}

/* ===== QUICK RIDE SHORTCUT ===== */

.quick-ride-page {
    min-height: 100vh;
    display: grid;
    place-items: center;
    padding: 18px;
    background:
        linear-gradient(180deg, rgba(30,35,41,.06), rgba(248,248,245,0) 260px),
        var(--mlc-background);
}

.quick-ride-card {
    width: min(100%, 560px);
    background: var(--mlc-panel);
    border: 1px solid var(--mlc-border);
    border-radius: 8px;
    box-shadow: var(--mlc-shadow);
    padding: clamp(22px, 5vw, 34px);
}

.quick-ride-card h1 {
    margin: 0 0 16px;
    color: var(--mlc-secondary);
    font-size: clamp(40px, 12vw, 64px);
    line-height: .95;
}

.quick-status {
    display: grid;
    gap: 6px;
    margin: 18px 0;
    padding: 16px;
    border-radius: 8px;
}

.quick-status strong {
    font-size: 20px;
    letter-spacing: .08em;
}

.quick-status span,
.quick-meta span {
    color: var(--mlc-text);
    line-height: 1.45;
}

.quick-status.is-live {
    background: rgba(63,174,90,.12);
    border: 1px solid rgba(63,174,90,.36);
}

.quick-status.is-live strong {
    color: var(--mlc-success);
}

.quick-status.is-offline {
    background: rgba(30,35,41,.05);
    border: 1px solid var(--mlc-border);
}

.quick-status.is-offline strong {
    color: var(--mlc-secondary);
}

.quick-ride-form {
    display: grid;
    gap: 14px;
}

.quick-ride-form label {
    display: grid;
    gap: 7px;
    color: var(--mlc-secondary);
    font-weight: 900;
}

.quick-ride-form input {
    width: 100%;
    min-height: 52px;
    border-radius: 6px;
    border: 1px solid rgba(85,93,102,.28);
    background: var(--mlc-white);
    color: var(--mlc-secondary);
    padding: 13px 14px;
    font-size: 17px;
}

.quick-ride-form button {
    min-height: 58px;
    border: 0;
    border-radius: 6px;
    background: var(--mlc-success);
    color: var(--mlc-white);
    font-size: 20px;
    font-weight: 900;
    cursor: pointer;
}

.quick-ride-form button:hover {
    filter: brightness(.96);
}

.quick-ride-form.stop-form button {
    background: var(--mlc-error);
}

.quick-links,
.quick-footer-links,
.quick-meta {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    margin-top: 14px;
}

.quick-links a,
.quick-footer-links a {
    color: var(--mlc-secondary);
    font-weight: 900;
}

.quick-meta {
    padding-top: 14px;
    border-top: 1px solid var(--mlc-border);
}

@media (max-width: 560px) {
    .quick-ride-page {
        align-items: start;
        padding: 10px;
    }

    .quick-ride-card {
        min-height: calc(100vh - 20px);
        display: flex;
        flex-direction: column;
        justify-content: center;
    }
}

/* ===== FOCUSED TRACKER VIEW ===== */

.tracker-shell {
    width: 100%;
    min-height: calc(100vh - 82px);
    padding: 0;
}

.tracker-shell .home-map-panel {
    width: 100%;
    min-height: calc(100vh - 82px);
    border: 0;
    border-radius: 0;
    box-shadow: none;
}

.tracker-shell iframe {
    min-height: calc(100vh - 82px);
}

.tracker-shell .inactive-screen {
    position: relative;
    min-height: calc(100vh - 82px);
    overflow: hidden;
    background:
        linear-gradient(110deg, rgba(30,35,41,.94), rgba(30,35,41,.82)),
        var(--mlc-secondary);
}

.tracker-shell .inactive-screen::before {
    content: "";
    position: absolute;
    inset: 0;
    background-image: var(--offline-logo);
    background-repeat: no-repeat;
    background-position: center;
    background-size: min(48vw, 520px);
    opacity: .13;
    filter: grayscale(.05);
}

.tracker-shell .ride-dashboard {
    position: relative;
    z-index: 1;
    width: min(560px, calc(100% - 32px));
    padding: clamp(24px, 5vw, 42px);
}

.offline-logo {
    display: block;
    width: min(180px, 52vw);
    margin: 0 auto 18px;
}

.tracker-shell .ride-dashboard h1 {
    font-size: clamp(34px, 7vw, 56px);
}

.tracker-shell .ride-dashboard-text {
    color: var(--mlc-text);
}

.topbar {
    min-height: 82px;
}

.topbar .menu {
    flex: 0 0 auto;
}

.topbar .menu a {
    font-size: 17px;
}

@media (max-width: 700px) {
    .tracker-shell,
    .tracker-shell .home-map-panel,
    .tracker-shell iframe,
    .tracker-shell .inactive-screen {
        min-height: calc(100vh - 108px);
    }

    .topbar .menu {
        width: auto;
        justify-content: flex-start;
        overflow: visible;
    }
}

/* ===== STANDALONE / EMBED CONTENT PAGES ===== */

.standalone-shell,
.embed-shell {
    width: min(100%, 1120px);
    margin: 0 auto;
    padding: clamp(18px, 4vw, 42px);
}

.embed-body {
    background: transparent;
}

.embed-shell {
    padding: 0;
}

.standalone-shell .content-card,
.embed-shell .content-card {
    width: 100%;
    max-width: none;
    margin: 0;
}

.embed-shell .content-card {
    border: 0;
    border-radius: 0;
    box-shadow: none;
    background: transparent;
    padding: 0;
}

.embed-shell .page-intro {
    margin-bottom: 20px;
}

.embed-shell .page-intro h1 {
    font-size: clamp(32px, 5vw, 52px);
}

.steve-link-list {
    display: grid;
    gap: 16px;
}

.steve-audit-note {
    margin: 0 0 28px;
    padding: 18px;
    border-left: 5px solid var(--mlc-warning);
    border-radius: 6px;
    background: rgba(200,155,44,.1);
}

.steve-audit-note p {
    margin: 6px 0 0;
}

.steve-link-group + .steve-link-group {
    margin-top: 34px;
}

.steve-link-group > h2 {
    margin-bottom: 14px;
}

.steve-link-card {
    display: grid;
    gap: 14px;
    padding: 18px;
    border-radius: 8px;
    background: rgba(30,35,41,.04);
    border: 1px solid var(--mlc-border);
}

.steve-link-card.is-legacy {
    opacity: .82;
    border-style: dashed;
}

.steve-link-heading {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 18px;
}

.steve-link-card h3 {
    margin: 0 0 6px;
    color: var(--mlc-secondary);
}

.steve-link-card p {
    margin: 0;
}

.steve-link-card label {
    display: grid;
    gap: 6px;
    color: var(--mlc-secondary);
    font-weight: 900;
}

.steve-link-card input,
.steve-link-card textarea {
    width: 100%;
    border-radius: 6px;
    border: 1px solid rgba(85,93,102,.28);
    background: var(--mlc-white);
    color: var(--mlc-secondary);
    padding: 12px;
    font: inherit;
}

.steve-link-card textarea {
    min-height: 92px;
    resize: vertical;
}

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

.steve-link-actions .btn {
    width: auto;
    margin: 0;
}

.steve-page-status {
    flex: 0 0 auto;
    padding: 6px 10px;
    border-radius: 999px;
    font-size: .78rem;
    font-weight: 900;
    letter-spacing: .06em;
    text-transform: uppercase;
}

.steve-page-status.current {
    color: #176a37;
    background: rgba(63,174,90,.14);
}

.steve-page-status.legacy {
    color: #8b3f2f;
    background: rgba(183,78,57,.12);
}

.steve-embed-details {
    padding-top: 12px;
    border-top: 1px solid var(--mlc-border);
}

.steve-embed-details summary {
    cursor: pointer;
    color: var(--mlc-secondary);
    font-weight: 900;
}

.steve-embed-details label {
    margin-top: 14px;
}

.text-button {
    margin-top: 10px;
    padding: 0;
    border: 0;
    background: transparent;
    color: var(--mlc-secondary);
    font: inherit;
    font-weight: 900;
    text-decoration: underline;
    cursor: pointer;
}

@media (max-width: 640px) {
    .steve-link-heading {
        display: grid;
    }

    .steve-page-status {
        justify-self: start;
    }
}
