:root {
    color-scheme: light;
    --ink: #1f2933;
    --muted: #667085;
    --line: #ffd5b8;
    --panel: #ffffff;
    --bg: #fff7ed;
    --brand: #fc8019;
    --brand-dark: #d95f00;
    --brand-soft: #fff0df;
    --warning: #b45309;
    --success: #15803d;
    --shadow: 0 20px 55px rgba(252, 128, 25, 0.18);
    font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
}

* {
    box-sizing: border-box;
}

body {
    margin: 0;
    color: var(--ink);
    background: linear-gradient(180deg, #fff1df 0, var(--bg) 280px, #ffffff 100%);
    padding-bottom: 86px;
}

button,
input {
    font: inherit;
}

button {
    transition: transform 0.18s ease, box-shadow 0.18s ease, background 0.18s ease, border-color 0.18s ease;
}

button:hover:not(:disabled) {
    transform: translateY(-1px);
}

button:disabled {
    cursor: wait;
    opacity: 0.65;
}

.app-shell {
    width: min(1180px, 100%);
    min-height: 100vh;
    margin: 0 auto;
    padding: 18px;
    display: grid;
    grid-template-columns: minmax(300px, 410px) minmax(0, 1fr);
    gap: 16px;
    align-content: start;
}

.topbar,
.summary-grid,
.app-view {
    grid-column: 1 / -1;
}

.topbar {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 16px;
    animation: slideDown 0.5s ease both;
}

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

.brand-icon {
    display: grid;
    width: 44px;
    height: 44px;
    place-items: center;
    border-radius: 8px;
    color: #fff;
    background: linear-gradient(135deg, var(--brand), #ffb25b);
    box-shadow: 0 12px 28px rgba(252, 128, 25, 0.24);
    font-weight: 950;
}

.topbar-brand strong {
    display: block;
    font-size: 1.05rem;
}
.driver-actions {
    display: flex;
    align-items: center;
    gap: 8px;
}

.driver-badge {
    max-width: 220px;
    color: var(--brand-dark);
    font-size: 0.86rem;
    font-weight: 800;
    text-align: right;
}

.eyebrow {
    margin: 0 0 4px;
    color: var(--brand-dark);
    font-size: 0.78rem;
    font-weight: 850;
    letter-spacing: 0.08em;
    text-transform: uppercase;
}

h1,
h2,
h3,
p {
    margin-top: 0;
}

h1 {
    margin-bottom: 0;
    font-size: clamp(1.8rem, 5vw, 2.65rem);
    letter-spacing: 0;
}

.icon-button {
    width: 46px;
    height: 46px;
    border: 0;
    border-radius: 8px;
    color: #fff;
    background: linear-gradient(135deg, var(--brand), #ff9f43);
    box-shadow: var(--shadow);
    cursor: pointer;
    font-weight: 900;
}

.icon-button.muted {
    color: var(--ink);
    background: #fff3e6;
}

.logout-icon {
    color: #fff;
    background: #111827;
}

.logout-icon svg {
    width: 21px;
    height: 21px;
    fill: none;
    stroke: currentColor;
    stroke-width: 2;
    stroke-linecap: round;
    stroke-linejoin: round;
}

.icon-button.is-active {
    color: #fff;
    background: #111827;
}

.app-view {
    display: none;
}

.app-view.is-active {
    display: grid;
    gap: 16px;
    animation: fadeLift 0.35s ease both;
}

.task-view.is-active {
    grid-template-columns: minmax(300px, 410px) minmax(0, 1fr);
    align-items: start;
}

.work-panel {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 14px;
    border: 1px solid var(--line);
    border-radius: 8px;
    padding: 16px;
    background: rgba(255, 255, 255, 0.96);
    box-shadow: 0 12px 30px rgba(252, 128, 25, 0.1);
}

.work-panel h2 {
    margin-bottom: 0;
    font-size: 1.25rem;
}

.summary-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 10px;
}

.summary-grid article,
.order-card,
.detail-panel {
    border: 1px solid var(--line);
    border-radius: 8px;
    background: rgba(255, 255, 255, 0.96);
}

.summary-grid article {
    padding: 14px;
    animation: fadeLift 0.5s ease both;
}

.summary-grid strong {
    display: block;
    font-size: 1.35rem;
}

.summary-grid span {
    color: var(--muted);
    font-size: 0.84rem;
}

.filters {
    grid-column: 1;
    display: grid;
    grid-template-columns: repeat(5, minmax(78px, 1fr));
    gap: 7px;
    overflow-x: auto;
}

.filter-button {
    min-height: 40px;
    border: 1px solid var(--line);
    border-radius: 8px;
    color: var(--muted);
    background: var(--panel);
    cursor: pointer;
    font-size: 0.86rem;
    font-weight: 760;
}

.filter-button.is-active {
    color: #fff;
    border-color: var(--brand);
    background: var(--brand);
}

.badge.nearby {
    color: #7c2d12;
    background: #ffedd5;
}

.order-card.is-offer {
    border-color: #fc8019;
    background: linear-gradient(180deg, #fff7ed, #fff);
}

.order-list {
    grid-column: 1;
    display: grid;
    gap: 12px;
}

.order-card {
    padding: 14px;
    box-shadow: 0 10px 28px rgba(252, 128, 25, 0.09);
    cursor: pointer;
    text-align: left;
    animation: fadeLift 0.34s ease both;
}

.order-card:hover {
    box-shadow: var(--shadow);
}

.order-card.is-active {
    border-color: var(--brand);
    outline: 3px solid rgba(252, 128, 25, 0.18);
}

.order-head,
.detail-head,
.row {
    display: flex;
    justify-content: space-between;
    gap: 12px;
}

.order-card h2 {
    margin-bottom: 4px;
    font-size: 1.02rem;
}

.order-card p,
.detail-panel p {
    color: var(--muted);
    line-height: 1.45;
}

.badge {
    align-self: flex-start;
    white-space: nowrap;
    border-radius: 999px;
    padding: 4px 9px;
    color: var(--success);
    background: #dcfce7;
    font-size: 0.74rem;
    font-weight: 850;
}

.badge.picked_up {
    color: var(--warning);
    background: #fef3c7;
}

.badge.delivered {
    color: #1e3a8a;
    background: #dbeafe;
}

.meta-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 8px;
    margin-top: 12px;
}

.meta-grid strong {
    display: block;
    font-size: 0.92rem;
}

.meta-grid span {
    color: var(--muted);
    font-size: 0.75rem;
}

.detail-panel {
    grid-column: 2;
    grid-row: 1 / span 3;
    min-height: 570px;
    overflow: hidden;
    box-shadow: var(--shadow);
}

.bottom-nav {
    position: fixed;
    left: 50%;
    bottom: 12px;
    z-index: 15;
    transform: translateX(-50%);
    width: min(520px, calc(100vw - 24px));
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 8px;
    padding: 8px;
    border: 1px solid var(--line);
    border-radius: 8px;
    background: rgba(255, 255, 255, 0.96);
    box-shadow: var(--shadow);
    backdrop-filter: blur(10px);
}

.bottom-nav-button {
    min-height: 44px;
    border: 0;
    border-radius: 8px;
    color: var(--muted);
    background: transparent;
    cursor: pointer;
    font-weight: 850;
}

.bottom-nav-button.is-active {
    color: #fff;
    background: var(--brand);
}

.detail-content {
    display: grid;
    gap: 18px;
    padding: 18px;
}

.store-cover {
    width: 100%;
    aspect-ratio: 16 / 7;
    border-radius: 8px;
    object-fit: cover;
    background: #fff1df;
}

.detail-head {
    align-items: flex-start;
}

.detail-head h2 {
    margin-bottom: 4px;
    font-size: 1.45rem;
}

.section {
    border-top: 1px solid var(--line);
    padding-top: 15px;
}

.section h3 {
    margin-bottom: 10px;
    font-size: 0.95rem;
}

.items {
    display: grid;
    gap: 8px;
    margin-bottom: 10px;
}

.store-block {
    display: grid;
    grid-template-columns: 56px 1fr;
    gap: 12px;
    align-items: start;
}

.store-logo,
.item-image {
    width: 56px;
    height: 56px;
    border-radius: 8px;
    object-fit: cover;
    background: #fff1df;
}

.item-row {
    display: grid;
    grid-template-columns: 56px minmax(0, 1fr) auto;
    gap: 12px;
    align-items: center;
    padding: 8px;
    border: 1px solid var(--line);
    border-radius: 8px;
}

.item-row strong,
.item-row small {
    display: block;
}

.item-row small {
    margin-top: 3px;
    color: var(--muted);
    font-size: 0.78rem;
    line-height: 1.35;
}

.item-row span {
    color: var(--ink);
    font-weight: 850;
    white-space: nowrap;
}

.item-image.placeholder::before {
    content: "";
    display: block;
    width: 18px;
    height: 18px;
    margin: 19px auto;
    border-radius: 50%;
    background: var(--brand);
    opacity: 0.35;
}

.timeline {
    display: grid;
    gap: 10px;
    margin: 0;
    padding: 0;
    list-style: none;
}

.timeline li {
    display: flex;
    justify-content: space-between;
    gap: 12px;
    border-left: 3px solid var(--brand);
    padding-left: 10px;
}

.timeline span {
    color: var(--muted);
    font-size: 0.84rem;
    text-align: right;
}

.image-gallery {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(96px, 1fr));
    gap: 10px;
}

.image-gallery img {
    width: 100%;
    aspect-ratio: 1;
    border-radius: 8px;
    object-fit: cover;
    background: #fff1df;
}

.row {
    align-items: baseline;
    color: var(--muted);
}

.row strong {
    color: var(--ink);
}

.actions {
    position: sticky;
    bottom: 0;
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 10px;
    padding: 14px 18px 18px;
    border-top: 1px solid var(--line);
    background: rgba(255, 255, 255, 0.96);
    backdrop-filter: blur(8px);
}

.action-button {
    min-height: 46px;
    border: 0;
    border-radius: 8px;
    color: #fff;
    background: linear-gradient(135deg, var(--brand), #ff9f43);
    cursor: pointer;
    font-weight: 850;
    box-shadow: 0 12px 26px rgba(252, 128, 25, 0.22);
}

.action-button.secondary {
    color: var(--ink);
    background: #fff3e6;
    box-shadow: none;
}

.actions.is-complete {
    grid-template-columns: 1fr;
    color: var(--muted);
    font-size: 0.9rem;
    font-weight: 750;
    text-align: center;
}

.detail-panel a {
    color: var(--brand-dark);
    font-weight: 800;
    text-decoration: none;
}

.empty-state {
    display: grid;
    min-height: 360px;
    place-content: center;
    padding: 24px;
    text-align: center;
}

.toast {
    position: fixed;
    left: 50%;
    bottom: 18px;
    z-index: 30;
    transform: translateX(-50%) translateY(80px);
    max-width: min(420px, calc(100vw - 28px));
    border-radius: 8px;
    padding: 12px 14px;
    color: #fff;
    background: #111827;
    box-shadow: var(--shadow);
    opacity: 0;
    transition: 0.22s ease;
}

.toast.is-visible {
    transform: translateX(-50%) translateY(0);
    opacity: 1;
}

.login-panel {
    position: fixed;
    inset: 0;
    z-index: 20;
    display: grid;
    place-items: center;
    padding: 18px;
    overflow: hidden;
    background:
        linear-gradient(115deg, rgba(255, 255, 255, 0.94) 0 36%, rgba(255, 247, 237, 0.9) 36% 62%, rgba(252, 128, 25, 0.88) 62% 100%),
        repeating-linear-gradient(90deg, rgba(255,255,255,0.25) 0 28px, rgba(255,255,255,0) 28px 56px);
}

.login-panel::before,
.login-panel::after {
    content: "";
    position: absolute;
    left: -12%;
    right: -12%;
    height: 86px;
    background: repeating-linear-gradient(90deg, rgba(31, 41, 51, 0.08) 0 42px, transparent 42px 84px);
    transform: rotate(-7deg);
    animation: roadMove 10s linear infinite;
    pointer-events: none;
}

.login-panel::before {
    top: 16%;
}

.login-panel::after {
    bottom: 12%;
    animation-duration: 14s;
    opacity: 0.45;
}

.login-panel.is-hidden {
    display: none;
}

.login-card {
    position: relative;
    z-index: 1;
    width: min(430px, 100%);
    border: 1px solid rgba(255, 255, 255, 0.72);
    border-radius: 8px;
    padding: 24px;
    background: rgba(255, 255, 255, 0.96);
    box-shadow: 0 28px 80px rgba(105, 48, 0, 0.22);
    animation: loginPop 0.58s cubic-bezier(.2,.9,.2,1.15) both;
}

.login-card::after {
    content: "Fast. Fresh. Delivered.";
    position: absolute;
    right: 18px;
    top: 18px;
    color: rgba(252, 128, 25, 0.16);
    font-size: 0.8rem;
    font-weight: 900;
    letter-spacing: 0.12em;
    text-transform: uppercase;
    pointer-events: none;
}

.login-brand-mark {
    display: grid;
    width: 54px;
    height: 54px;
    place-items: center;
    margin-bottom: 12px;
    border-radius: 8px;
    color: #fff;
    background: linear-gradient(135deg, var(--brand), #ffb25b);
    box-shadow: 0 14px 34px rgba(252, 128, 25, 0.34);
    font-size: 1.45rem;
    font-weight: 950;
    animation: pulseMark 1.8s ease-in-out infinite;
}

.login-card h2 {
    margin-bottom: 18px;
    font-size: 1.7rem;
}

.login-card label {
    display: grid;
    gap: 7px;
    margin-bottom: 14px;
    color: var(--muted);
    font-size: 0.9rem;
    font-weight: 750;
}

.login-card input {
    width: 100%;
    min-height: 48px;
    border: 1px solid var(--line);
    border-radius: 8px;
    padding: 10px 12px;
    color: var(--ink);
    background: #fffaf5;
    font: inherit;
    outline: 0;
    transition: border-color 0.18s ease, box-shadow 0.18s ease, background 0.18s ease;
}

.login-card input:focus {
    border-color: var(--brand);
    background: #fff;
    box-shadow: 0 0 0 4px rgba(252, 128, 25, 0.13);
}

.login-hint {
    margin: 14px 0 0;
    color: var(--muted);
    font-size: 0.86rem;
    line-height: 1.45;
}

@keyframes loginPop {
    from {
        opacity: 0;
        transform: translateY(28px) scale(0.96);
    }
    to {
        opacity: 1;
        transform: translateY(0) scale(1);
    }
}

@keyframes roadMove {
    from {
        background-position-x: 0;
    }
    to {
        background-position-x: 168px;
    }
}

@keyframes pulseMark {
    0%, 100% {
        transform: translateY(0) scale(1);
    }
    50% {
        transform: translateY(-3px) scale(1.03);
    }
}

@keyframes fadeLift {
    from {
        opacity: 0;
        transform: translateY(12px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes slideDown {
    from {
        opacity: 0;
        transform: translateY(-12px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@media (prefers-reduced-motion: reduce) {
    *,
    *::before,
    *::after {
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
        scroll-behavior: auto !important;
        transition-duration: 0.01ms !important;
    }
}

@media (max-width: 840px) {
    .app-shell {
        grid-template-columns: 1fr;
        padding: 14px;
    }

    .task-view.is-active {
        grid-template-columns: 1fr;
    }

    .detail-panel {
        grid-column: 1;
        grid-row: auto;
        min-height: auto;
    }
}

@media (max-width: 520px) {
    .summary-grid,
    .meta-grid,
    .actions {
        grid-template-columns: 1fr;
    }

    .work-panel {
        align-items: stretch;
        flex-direction: column;
    }

    .item-row {
        grid-template-columns: 48px minmax(0, 1fr);
    }

    .item-row span {
        grid-column: 2;
    }

    .order-head,
    .detail-head {
        flex-direction: column;
    }

    .topbar {
        align-items: flex-start;
    }


.driver-actions {
        flex-wrap: wrap;
        justify-content: flex-end;
    }

    .login-card::after {
        display: none;
    }
}
/* Swiggy-style animated app refresh */
:root {
    --ink: #171412;
    --muted: #77685c;
    --line: #ffe0c2;
    --panel: #ffffff;
    --bg: #fff8f1;
    --brand: #fc8019;
    --brand-dark: #c65100;
    --brand-soft: #fff1e1;
    --success: #169b62;
    --shadow: 0 18px 46px rgba(87, 45, 9, 0.14);
}

body {
    min-height: 100vh;
    background:
        linear-gradient(135deg, rgba(252, 128, 25, 0.14) 0 18%, transparent 18% 100%),
        repeating-linear-gradient(90deg, rgba(252, 128, 25, 0.055) 0 1px, transparent 1px 34px),
        linear-gradient(180deg, #fff3e5 0, #fffaf6 42%, #ffffff 100%);
}

.app-shell {
    padding-top: 16px;
}

.topbar {
    position: sticky;
    top: 0;
    z-index: 12;
    margin: -16px -18px 0;
    padding: 12px 18px;
    border-bottom: 1px solid rgba(252, 128, 25, 0.14);
    background: rgba(255, 250, 246, 0.9);
    backdrop-filter: blur(16px);
}

.brand-icon,
.login-brand-mark {
    background: #fc8019;
    box-shadow: 0 12px 30px rgba(252, 128, 25, 0.34);
}

.dashboard-hero {
    position: relative;
    display: grid;
    grid-template-columns: minmax(0, 1.1fr) minmax(220px, 0.7fr);
    gap: 18px;
    min-height: 218px;
    overflow: hidden;
    border-radius: 8px;
    padding: clamp(18px, 4vw, 28px);
    color: #fff;
    background:
        linear-gradient(120deg, rgba(23, 20, 18, 0.88), rgba(111, 52, 0, 0.72) 42%, rgba(252, 128, 25, 0.98)),
        repeating-linear-gradient(100deg, rgba(255,255,255,0.14) 0 1px, transparent 1px 34px);
    box-shadow: 0 24px 64px rgba(252, 128, 25, 0.24);
    isolation: isolate;
}

.dashboard-hero::before {
    content: "";
    position: absolute;
    inset: auto -20% -42px -20%;
    height: 92px;
    background: repeating-linear-gradient(90deg, rgba(255,255,255,0.26) 0 42px, transparent 42px 86px);
    transform: rotate(-4deg);
    animation: roadMove 9s linear infinite;
    opacity: 0.58;
    z-index: -1;
}

.dashboard-hero::after {
    content: "";
    position: absolute;
    inset: 0;
    background: linear-gradient(105deg, transparent 0 34%, rgba(255,255,255,0.2) 46%, transparent 60% 100%);
    transform: translateX(-110%);
    animation: heroSweep 4.8s ease-in-out infinite;
    pointer-events: none;
}

.dashboard-copy {
    display: grid;
    align-content: center;
    max-width: 560px;
}

.dashboard-hero .eyebrow {
    color: #ffe7cd;
}

.dashboard-hero h1 {
    margin: 0;
    max-width: 12ch;
    font-size: clamp(2rem, 5vw, 3.45rem);
    line-height: 0.98;
}

.hero-copy {
    max-width: 440px;
    margin: 12px 0 0;
    color: rgba(255, 255, 255, 0.88);
    line-height: 1.5;
}

.hero-rider {
    position: relative;
    min-height: 170px;
    display: grid;
    place-items: center;
}

.rider-card {
    display: grid;
    width: min(152px, 42vw);
    aspect-ratio: 1.18;
    place-items: center;
    border: 3px solid rgba(255, 255, 255, 0.72);
    border-radius: 8px;
    color: #fc8019;
    background: #fff;
    box-shadow: 0 28px 58px rgba(54, 25, 0, 0.25);
    font-size: 2.25rem;
    font-weight: 950;
    animation: floatDelivery 2.4s ease-in-out infinite;
}

.route-dot {
    position: absolute;
    width: 12px;
    height: 12px;
    border-radius: 999px;
    background: #fff;
    box-shadow: 0 0 0 8px rgba(255,255,255,0.14);
    animation: pulseMark 1.7s ease-in-out infinite;
}

.route-dot-one { left: 8%; top: 22%; }
.route-dot-two { right: 13%; top: 28%; animation-delay: 0.35s; }
.route-dot-three { left: 28%; bottom: 12%; animation-delay: 0.7s; }

.status-card {
    border: 0;
    background: #fff;
    box-shadow: var(--shadow);
}

.status-note {
    margin: 6px 0 0;
    color: var(--muted);
    font-size: 0.9rem;
}

.work-controls {
    display: grid;
    grid-template-columns: minmax(160px, 1fr) auto;
    align-items: end;
    gap: 12px;
}

.sound-select-label {
    display: grid;
    gap: 6px;
    color: var(--muted);
    font-size: 0.78rem;
    font-weight: 850;
}

.sound-select-label select {
    min-height: 46px;
    min-width: 168px;
    border: 1px solid #ffe2c8;
    border-radius: 8px;
    padding: 0 12px;
    color: var(--ink);
    background: #fff8f1;
    font: inherit;
    font-weight: 850;
    outline: 0;
}

.summary-grid {
    gap: 12px;
}

.summary-grid article {
    position: relative;
    min-height: 128px;
    display: grid;
    align-content: space-between;
    padding: 16px;
    overflow: hidden;
    border: 0;
    box-shadow: var(--shadow);
}

.summary-grid article::after {
    content: "";
    position: absolute;
    inset: auto -18px -32px auto;
    width: 92px;
    height: 92px;
    border-radius: 999px;
    background: rgba(252, 128, 25, 0.12);
}

.summary-icon {
    display: grid;
    width: 38px;
    height: 38px;
    place-items: center;
    border-radius: 8px;
    color: #fc8019;
    background: #fff1e1;
    font-size: 1.08rem;
    font-weight: 900;
}

.order-card,
.detail-panel,
.filter-button {
    border-color: #ffe2c8;
    box-shadow: 0 12px 28px rgba(87, 45, 9, 0.08);
}

.order-card.is-active,
.filter-button.is-active {
    border-color: #fc8019;
}

.bottom-nav {
    width: min(430px, calc(100vw - 26px));
    padding: 8px;
    border: 1px solid rgba(252, 128, 25, 0.18);
    border-radius: 8px;
    background: rgba(255, 255, 255, 0.94);
    box-shadow: 0 18px 52px rgba(35, 23, 14, 0.18);
    backdrop-filter: blur(18px);
}

.bottom-nav-button {
    display: grid;
    place-items: center;
    gap: 3px;
    min-height: 54px;
    border-radius: 8px;
    font-size: 0.76rem;
    font-weight: 850;
}

.bottom-nav-button span {
    font-size: 1.12rem;
    line-height: 1;
}

.bottom-nav-button strong {
    font-size: 0.76rem;
}

.bottom-nav-button.is-active {
    background: #fc8019;
    box-shadow: 0 12px 24px rgba(252, 128, 25, 0.26);
}

.install-prompt {
    position: fixed;
    inset: 0;
    z-index: 80;
    display: grid;
    place-items: center;
    padding: 18px;
    background: rgba(20, 16, 13, 0.62);
    backdrop-filter: blur(6px);
    opacity: 0;
    transition: opacity 0.22s ease;
}

.install-prompt[hidden] {
    display: none;
}

.install-prompt.is-visible {
    opacity: 1;
}

.install-card {
    position: relative;
    width: min(410px, 100%);
    padding: 28px 24px 22px;
    border: 1px solid rgba(252, 128, 25, 0.24);
    border-radius: 22px;
    background: #fff;
    color: #241a14;
    box-shadow: 0 28px 80px rgba(23, 20, 18, 0.32);
    text-align: center;
    transform: translateY(18px) scale(0.97);
    transition: transform 0.22s ease;
}

.install-prompt.is-visible .install-card {
    transform: translateY(0) scale(1);
}

.install-app-icon {
    width: 82px;
    height: 82px;
    margin-bottom: 12px;
    border-radius: 20px;
    box-shadow: 0 12px 28px rgba(252, 128, 25, 0.25);
}

.install-eyebrow {
    display: block;
    color: #fc8019;
    font-size: 0.72rem;
    font-weight: 900;
    letter-spacing: 0.12em;
}

.install-copy strong {
    display: block;
    margin-top: 5px;
    font-size: 1.45rem;
}

.install-copy p {
    margin: 8px 0 16px;
    color: #74665d;
    font-size: 0.92rem;
    line-height: 1.5;
}

.install-benefits {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 8px;
    margin: 0 0 18px;
    padding: 0;
    list-style: none;
}

.install-benefits li {
    padding: 10px 5px;
    border-radius: 12px;
    background: #fff5eb;
    color: #6d5545;
    font-size: 0.72rem;
    font-weight: 800;
}

.install-benefits span {
    display: block;
    margin-bottom: 4px;
    font-size: 1.2rem;
}

.install-action,
.install-close,
.install-later {
    min-height: 38px;
    border: 0;
    border-radius: 8px;
    cursor: pointer;
    font-weight: 850;
}

.action-popup {
    position: fixed;
    inset: 0;
    z-index: 90;
    display: grid;
    place-items: center;
    padding: 18px;
    background: rgba(20, 16, 13, 0.66);
    backdrop-filter: blur(7px);
}

.action-popup[hidden] { display: none; }

.action-popup-card {
    width: min(410px, 100%);
    padding: 28px 24px 22px;
    border-radius: 22px;
    background: #fff;
    box-shadow: 0 28px 80px rgba(23, 20, 18, 0.34);
    text-align: center;
}

.action-popup-icon {
    width: 64px;
    height: 64px;
    display: grid;
    place-items: center;
    margin: 0 auto 14px;
    border-radius: 18px;
    background: #fff1e5;
    font-size: 1.8rem;
}

.action-popup-card h2 { margin: 0; font-size: 1.35rem; }
.action-popup-card p { margin: 10px 0 20px; color: #74665d; line-height: 1.55; }

.action-popup-primary,
.action-popup-secondary {
    width: 100%;
    min-height: 48px;
    border: 0;
    border-radius: 10px;
    cursor: pointer;
    font-weight: 850;
}

.action-popup-primary { color: #fff; background: #fc8019; }
.action-popup-secondary { margin-top: 8px; color: #675950; background: #f4efeb; }

.install-action {
    width: 100%;
    min-height: 50px;
    padding: 0 18px;
    color: #fff;
    background: #fc8019;
}

.install-close {
    position: absolute;
    top: 12px;
    right: 12px;
    width: 38px;
    color: #6f625a;
    background: #f5f0ec;
}

.install-later {
    margin-top: 8px;
    padding: 0 14px;
    color: #796b62;
    background: transparent;
}

.map-preview {
    width: 100%;
    min-height: 240px;
    border: 0;
    border-radius: 8px;
    background: #fff1e1;
}

.locked-section {
    border: 1px dashed rgba(252, 128, 25, 0.45);
    border-radius: 8px;
    padding: 14px;
    background: #fff8f1;
}

.offer-popup {
    position: fixed;
    right: 18px;
    top: 86px;
    z-index: 40;
    display: grid;
    grid-template-columns: auto minmax(0, 1fr);
    gap: 14px;
    width: min(390px, calc(100vw - 28px));
    padding: 16px;
    border: 1px solid rgba(252, 128, 25, 0.28);
    border-radius: 8px;
    color: #171412;
    background: #fff;
    box-shadow: 0 24px 70px rgba(87, 45, 9, 0.28);
    animation: offerSlide 0.24s ease both;
}

.offer-popup h2 {
    margin: 0 0 5px;
    font-size: 1.35rem;
}

.offer-popup p {
    margin-bottom: 0;
    color: var(--muted);
}

.offer-pulse {
    width: 52px;
    height: 52px;
    border-radius: 8px;
    background: #fc8019;
    box-shadow: 0 0 0 10px rgba(252, 128, 25, 0.14);
    animation: pulseMark 1.2s ease-in-out infinite;
}

.offer-pulse::before {
    content: "!";
    display: grid;
    height: 100%;
    place-items: center;
    color: #fff;
    font-size: 1.6rem;
    font-weight: 950;
}

.offer-popup-actions {
    grid-column: 1 / -1;
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 10px;
}

.delivery-celebration {
    position: fixed;
    left: 50%;
    top: 92px;
    z-index: 45;
    transform: translateX(-50%);
    display: grid;
    grid-template-columns: auto minmax(0, 1fr) auto;
    align-items: center;
    gap: 14px;
    width: min(520px, calc(100vw - 28px));
    padding: 16px;
    border: 1px solid rgba(252, 128, 25, 0.26);
    border-radius: 8px;
    color: #171412;
    background:
        linear-gradient(135deg, #fff 0 64%, #fff1e1 64% 100%);
    box-shadow: 0 28px 80px rgba(87, 45, 9, 0.28);
    animation: celebrationDrop 0.34s cubic-bezier(.2,.9,.2,1.12) both;
}

.delivery-celebration-mark {
    display: grid;
    width: 58px;
    height: 58px;
    place-items: center;
    border-radius: 8px;
    color: #fff;
    background: #16a34a;
    box-shadow: 0 12px 28px rgba(22, 163, 74, 0.28);
    font-weight: 950;
}

.delivery-celebration h2,
.delivery-celebration p {
    margin-bottom: 0;
}

.delivery-celebration p {
    color: var(--muted);
}

.delivery-celebration button {
    min-height: 38px;
    border: 0;
    border-radius: 8px;
    padding: 0 12px;
    color: #fff;
    background: #171412;
    cursor: pointer;
    font-weight: 850;
}

@keyframes offerSlide {
    from {
        opacity: 0;
        transform: translateY(-12px) scale(0.98);
    }
    to {
        opacity: 1;
        transform: translateY(0) scale(1);
    }
}

@keyframes celebrationDrop {
    from {
        opacity: 0;
        transform: translateX(-50%) translateY(-18px) scale(0.96);
    }
    to {
        opacity: 1;
        transform: translateX(-50%) translateY(0) scale(1);
    }
}

.login-panel {
    background:
        linear-gradient(115deg, rgba(255, 255, 255, 0.96) 0 32%, rgba(255, 244, 231, 0.94) 32% 58%, rgba(252, 128, 25, 0.94) 58% 100%),
        repeating-linear-gradient(90deg, rgba(23,20,18,0.06) 0 1px, transparent 1px 36px);
}

.login-panel.is-register-mode {
    background:
        linear-gradient(120deg, rgba(23, 20, 18, 0.94) 0 34%, rgba(252, 128, 25, 0.94) 34% 68%, rgba(255, 244, 231, 0.96) 68% 100%),
        repeating-linear-gradient(90deg, rgba(255,255,255,0.08) 0 1px, transparent 1px 38px);
}

.login-card {
    box-shadow: 0 30px 90px rgba(78, 37, 0, 0.24);
}

.login-panel.is-login-mode .login-card {
    width: min(420px, 100%);
}

.login-panel.is-register-mode .login-card {
    width: min(560px, 100%);
    border-color: rgba(23, 20, 18, 0.12);
    background:
        linear-gradient(180deg, #171412 0 118px, rgba(255,255,255,0.98) 118px 100%);
}

.login-panel.is-register-mode .login-card-head,
.login-panel.is-register-mode .login-subtitle {
    color: #fff;
}

.login-panel.is-register-mode .eyebrow {
    color: #ffd9b0;
}

.login-panel.is-register-mode .login-brand-mark {
    color: #171412;
    background: #fff;
}

.auth-switch {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 6px;
    margin-bottom: 16px;
    padding: 5px;
    border: 1px solid var(--line);
    border-radius: 8px;
    background: #fff8f1;
}

.auth-switch button {
    min-height: 38px;
    border: 0;
    border-radius: 8px;
    color: var(--muted);
    background: transparent;
    cursor: pointer;
    font-weight: 900;
}

.auth-switch button.is-active {
    color: #fff;
    background: #fc8019;
    box-shadow: 0 10px 22px rgba(252, 128, 25, 0.22);
}

.register-fields {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 0 10px;
    animation: fadeLift 0.24s ease both;
}

.register-fields[hidden] {
    display: none;
}

.register-fields label:last-child {
    grid-column: 1 / -1;
}

.login-card-head {
    display: flex;
    align-items: center;
    gap: 14px;
    margin-bottom: 8px;
}

.login-card-head .login-brand-mark {
    flex: 0 0 auto;
    margin-bottom: 0;
}

.login-card-head h2 {
    margin-bottom: 0;
    line-height: 1.1;
}

.login-subtitle {
    margin: 0 0 18px;
    color: var(--muted);
    line-height: 1.45;
}

.password-wrap {
    display: grid;
    grid-template-columns: minmax(0, 1fr) auto;
    align-items: center;
    gap: 4px;
    border: 1px solid var(--line);
    border-radius: 8px;
    background: #fffaf5;
    transition: border-color 0.18s ease, box-shadow 0.18s ease, background 0.18s ease;
}

.password-wrap:focus-within {
    border-color: var(--brand);
    background: #fff;
    box-shadow: 0 0 0 4px rgba(252, 128, 25, 0.13);
}

.login-card .password-wrap input {
    border: 0;
    background: transparent;
    box-shadow: none;
}

.login-card .password-wrap input:focus {
    box-shadow: none;
}

.password-toggle {
    min-width: 56px;
    min-height: 38px;
    margin-right: 5px;
    border: 0;
    border-radius: 8px;
    color: var(--brand-dark);
    background: #fff1e1;
    cursor: pointer;
    font-size: 0.82rem;
    font-weight: 900;
}

.remember-row {
    display: flex !important;
    grid-template-columns: none !important;
    align-items: center;
    gap: 10px;
    margin: 2px 0 16px !important;
    color: var(--ink) !important;
}

.login-card .remember-row input {
    width: 18px;
    min-height: 18px;
    height: 18px;
    flex: 0 0 18px;
    padding: 0;
    border-radius: 4px;
    accent-color: var(--brand);
}

@keyframes heroSweep {
    0%, 35% { transform: translateX(-110%); }
    60%, 100% { transform: translateX(110%); }
}

@keyframes floatDelivery {
    0%, 100% { transform: translateY(0) rotate(-2deg); }
    50% { transform: translateY(-10px) rotate(2deg); }
}

@media (max-width: 720px) {
    .dashboard-hero {
        grid-template-columns: 1fr;
        min-height: 0;
    }

    .hero-rider {
        min-height: 118px;
    }

    .dashboard-hero h1 {
        max-width: 11ch;
    }

    .offer-popup {
        left: 14px;
        right: 14px;
        top: 78px;
        width: auto;
    }

    .delivery-celebration {
        top: 76px;
        grid-template-columns: auto minmax(0, 1fr);
    }

    .delivery-celebration button {
        grid-column: 1 / -1;
    }

}

@media (max-width: 520px) {
    .topbar {
        margin-left: -14px;
        margin-right: -14px;
    }

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

    .summary-grid article {
        min-height: 118px;
    }

    .work-controls,
    .register-fields {
        grid-template-columns: 1fr;
    }

    .sound-select-label select {
        width: 100%;
    }
}
