/* logistics v2 — cache-bust */
:root {
    --brand: #1565c0;
    --brand-dark: #0d47a1;
    --accent: #ff7043;
    --bg: #f4f6fb;
}

html, body {
    font-family: 'Cairo', sans-serif;
    background: var(--bg);
    margin: 0;
}

h1, h2, h3, h4 { font-weight: 700; }

a { text-decoration: none; }

/* ===== shell ===== */
.app-shell { display: flex; min-height: 100vh; }

.app-sidebar {
    width: 240px;
    background: linear-gradient(180deg, var(--brand-dark), var(--brand));
    color: #fff;
    flex-shrink: 0;
    display: flex;
    flex-direction: column;
}

.app-sidebar .brand {
    font-size: 1.2rem;
    font-weight: 700;
    padding: 18px 16px;
    border-bottom: 1px solid rgba(255,255,255,.15);
}

.app-main { flex: 1; display: flex; flex-direction: column; min-width: 0; }

.app-topbar {
    height: 60px;
    background: #fff;
    border-bottom: 1px solid #e6e9f0;
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 0 20px;
}

.app-topbar .company { font-weight: 700; color: var(--brand-dark); }

.app-content { padding: 22px; flex: 1; }

/* ===== nav ===== */
.nav-list { list-style: none; padding: 10px; margin: 0; }
.nav-list a {
    display: block;
    color: #e8eefc;
    padding: 11px 14px;
    border-radius: 10px;
    margin-bottom: 4px;
    transition: .15s;
}
.nav-list a:hover { background: rgba(255,255,255,.12); }
.nav-list a.active { background: #fff; color: var(--brand-dark); font-weight: 700; }

/* ===== cards ===== */
.card-soft {
    background: #fff;
    border: 1px solid #e6e9f0;
    border-radius: 14px;
    padding: 16px;
    box-shadow: 0 1px 3px rgba(20,40,80,.04);
}

.stat-card { text-align: center; }
.stat-card .num { font-size: 2rem; font-weight: 700; color: var(--brand-dark); }
.stat-card .lbl { color: #65718a; font-size: .9rem; }

/* ===== shipment progress ===== */
.track-bar { height: 8px; background: #e9edf5; border-radius: 6px; overflow: hidden; }
.track-bar > span {
    display: block; height: 100%;
    background: linear-gradient(90deg, var(--accent), #ff5722);
    border-radius: 6px;
}

.status-pill {
    display: inline-block; padding: 3px 12px; border-radius: 999px;
    font-size: .82rem; font-weight: 600; background: #eef3fb; color: var(--brand-dark);
}

/* ===== timeline ===== */
.timeline { list-style: none; padding: 0; margin: 0; position: relative; }
.timeline li { position: relative; padding: 0 28px 22px 0; }
.timeline li::before {
    content: ''; position: absolute; right: 7px; top: 4px; bottom: -4px;
    width: 2px; background: #d8e0ee;
}
.timeline li:last-child::before { display: none; }
.timeline .dot {
    position: absolute; right: 0; top: 2px;
    width: 16px; height: 16px; border-radius: 50%;
    background: var(--accent); border: 3px solid #fff; box-shadow: 0 0 0 2px var(--accent);
}
.timeline .t-title { font-weight: 600; }
.timeline .t-time { color: #8a93a6; font-size: .8rem; }

/* ===== login (dazzling) ===== */
.auth {
    position: fixed; inset: 0; overflow: hidden;
    display: flex; align-items: center; justify-content: center;
    background: radial-gradient(1200px 600px at 80% -10%, #1e88e5 0%, transparent 60%),
                radial-gradient(1000px 700px at -10% 110%, #00bcd4 0%, transparent 55%),
                linear-gradient(135deg, #0a2a66 0%, #0d47a1 50%, #16358a 100%);
    font-family: 'Cairo', sans-serif;
}

/* floating colored orbs */
.auth-orb { position: absolute; border-radius: 50%; filter: blur(70px); opacity: .5; animation: floatOrb 16s ease-in-out infinite; }
.auth-orb.o1 { width: 420px; height: 420px; background: #ff7043; top: -120px; right: -80px; }
.auth-orb.o2 { width: 360px; height: 360px; background: #26c6da; bottom: -120px; left: -60px; animation-delay: -5s; }
.auth-orb.o3 { width: 280px; height: 280px; background: #7e57c2; top: 40%; left: 12%; animation-delay: -9s; }

/* faint moving cargo emojis */
.auth-emoji { position: absolute; font-size: 2.4rem; opacity: .14; animation: drift 22s linear infinite; }

.auth-card {
    position: relative; z-index: 2;
    width: 940px; max-width: 94vw;
    display: grid; grid-template-columns: 1.05fr .95fr;
    border-radius: 26px; overflow: hidden;
    box-shadow: 0 40px 90px rgba(0,0,0,.45);
    animation: fadeUp .7s cubic-bezier(.2,.7,.2,1) both;
}

.auth-hero {
    position: relative; color: #fff; padding: 52px 44px;
    background: linear-gradient(150deg, rgba(13,71,161,.55), rgba(10,42,102,.35));
    backdrop-filter: blur(4px);
    display: flex; flex-direction: column; justify-content: center;
    border-left: 1px solid rgba(255,255,255,.12);
}
.auth-hero .truck { font-size: 4.2rem; margin-bottom: 10px; animation: bob 3.2s ease-in-out infinite; }
.auth-hero h1 { font-size: 2.1rem; font-weight: 700; margin: 0 0 6px; }
.auth-hero p.lead { opacity: .9; margin-bottom: 26px; font-size: 1.02rem; }
.auth-feat { display: flex; align-items: center; gap: 12px; margin: 12px 0; font-weight: 600; }
.auth-feat .ic {
    width: 40px; height: 40px; border-radius: 12px; flex-shrink: 0;
    display: grid; place-items: center; font-size: 1.2rem;
    background: rgba(255,255,255,.16); border: 1px solid rgba(255,255,255,.18);
}

.auth-form { background: #fff; padding: 52px 46px; display: flex; flex-direction: column; justify-content: center; }
.auth-form h3 { font-weight: 700; color: var(--brand-dark); margin-bottom: 4px; }
.auth-form .sub { color: #7a869a; margin-bottom: 26px; }

.auth-field { position: relative; margin-bottom: 16px; }
.auth-field .fi {
    position: absolute; top: 50%; right: 14px; transform: translateY(-50%);
    font-size: 1.05rem; opacity: .55; pointer-events: none;
}
.auth-field input {
    width: 100%; padding: 13px 44px 13px 14px;
    border: 1.5px solid #e3e8f0; border-radius: 13px; font-size: 1rem;
    transition: .18s; background: #f8fafc;
}
.auth-field input:focus {
    outline: none; border-color: var(--brand); background: #fff;
    box-shadow: 0 0 0 4px rgba(21,101,192,.12);
}

.auth-btn {
    width: 100%; padding: 14px; border: none; border-radius: 13px;
    font-size: 1.05rem; font-weight: 700; color: #fff; cursor: pointer;
    background: linear-gradient(135deg, #ff7a45, #ff5722);
    box-shadow: 0 10px 24px rgba(255,87,34,.38); transition: .18s;
}
.auth-btn:hover:not(:disabled) { transform: translateY(-2px); box-shadow: 0 14px 30px rgba(255,87,34,.5); }
.auth-btn:disabled { opacity: .7; cursor: default; }

.auth-hint { margin-top: 18px; font-size: .85rem; color: #95a0b3; text-align: center; }

@media (max-width: 780px) {
    .auth-card { grid-template-columns: 1fr; }
    .auth-hero { display: none; }
}

@keyframes floatOrb { 0%,100% { transform: translate(0,0) scale(1); } 50% { transform: translate(20px,-30px) scale(1.08); } }
@keyframes bob { 0%,100% { transform: translateY(0) rotate(-2deg); } 50% { transform: translateY(-10px) rotate(2deg); } }
@keyframes fadeUp { from { opacity: 0; transform: translateY(22px); } to { opacity: 1; transform: none; } }
@keyframes drift { from { transform: translateY(0); } to { transform: translateY(-120vh); } }

/* ===== landing ===== */
.lp { font-family: 'Cairo', sans-serif; color: #14223d; }
.lp-nav { position: sticky; top: 0; z-index: 20; display: flex; align-items: center; justify-content: space-between;
          padding: 14px 28px; background: rgba(255,255,255,.92); backdrop-filter: blur(8px); border-bottom: 1px solid #eef1f6; }
.lp-brand { font-weight: 800; font-size: 1.3rem; color: #0d47a1; }
.lp-nav .acts { display: flex; gap: 10px; }
.lp-btn { padding: 10px 18px; border-radius: 12px; font-weight: 700; text-decoration: none; display: inline-block; transition: .15s; border: none; cursor: pointer; }
.lp-btn.primary { background: linear-gradient(135deg, #ff7a45, #ff5722); color: #fff; box-shadow: 0 10px 22px rgba(255,87,34,.35); }
.lp-btn.primary:hover { transform: translateY(-2px); }
.lp-btn.ghost { background: #eef3fb; color: #0d47a1; }

.lp-hero { position: relative; overflow: hidden; color: #fff; padding: 70px 24px 90px; text-align: center;
           background: radial-gradient(900px 500px at 80% -10%, #1e88e5 0%, transparent 60%),
                       radial-gradient(800px 500px at -10% 110%, #00bcd4 0%, transparent 55%),
                       linear-gradient(135deg, #0a2a66, #0d47a1 55%, #16358a); }
.lp-hero .truck { font-size: 64px; animation: bob 3.2s ease-in-out infinite; }
.lp-hero h1 { font-size: 2.6rem; font-weight: 800; margin: 6px 0 10px; }
.lp-hero p { font-size: 1.15rem; color: #d7e6fb; max-width: 620px; margin: 0 auto 26px; line-height: 1.9; }
.lp-hero .cta { display: flex; gap: 12px; justify-content: center; flex-wrap: wrap; }
.lp-orb { position: absolute; border-radius: 50%; filter: blur(70px); opacity: .45; animation: floatOrb 16s ease-in-out infinite; }
.lp-orb.a { width: 360px; height: 360px; background: #ff7043; top: -120px; right: -60px; }
.lp-orb.b { width: 300px; height: 300px; background: #26c6da; bottom: -120px; left: -40px; animation-delay: -6s; }

.lp-sec { max-width: 1040px; margin: 0 auto; padding: 56px 24px; }
.lp-sec h2 { text-align: center; font-size: 1.8rem; font-weight: 800; margin-bottom: 6px; }
.lp-sec .lead { text-align: center; color: #65718a; margin-bottom: 34px; }
.lp-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 18px; }
.lp-feat { background: #fff; border: 1px solid #e9edf5; border-radius: 16px; padding: 22px; transition: .15s; }
.lp-feat:hover { transform: translateY(-4px); box-shadow: 0 16px 36px rgba(20,40,80,.08); }
.lp-feat .ic { font-size: 1.9rem; }
.lp-feat h3 { font-size: 1.12rem; font-weight: 700; margin: 10px 0 6px; }
.lp-feat p { color: #65718a; font-size: .95rem; line-height: 1.8; }
.lp-steps { background: #f4f6fb; }
.lp-step { display: flex; gap: 14px; align-items: flex-start; margin: 14px 0; }
.lp-step .n { width: 38px; height: 38px; flex-shrink: 0; border-radius: 50%; background: linear-gradient(135deg,#1565c0,#0d47a1);
              color: #fff; display: grid; place-items: center; font-weight: 700; }
.lp-who { display: grid; grid-template-columns: repeat(3,1fr); gap: 18px; }
.lp-who .card-w { background: #fff; border: 1px solid #e9edf5; border-radius: 16px; padding: 24px; text-align: center; }
.lp-who .card-w .e { font-size: 2.4rem; }
.lp-cta-band { background: linear-gradient(135deg,#0d47a1,#1565c0); color: #fff; text-align: center; padding: 50px 24px; }
.lp-cta-band h2 { font-size: 1.7rem; font-weight: 800; margin-bottom: 16px; }
.lp-footer { text-align: center; padding: 26px; color: #8a93a6; font-size: .9rem; }
@media (max-width: 820px) { .lp-grid, .lp-who { grid-template-columns: 1fr; } .lp-hero h1 { font-size: 2rem; } }

/* ===== chat ===== */
.chat-grid { display: grid; grid-template-columns: 320px 1fr; gap: 14px; }
.chat-list-item { padding: 12px; border-radius: 12px; cursor: pointer; border: 1px solid #eef1f6; margin-bottom: 6px; }
.chat-list-item:hover { background: #f6f9ff; }
.chat-list-item.active { background: #e8f0fe; border-color: #1565c0; }
.chat-gov-chip { display:inline-block; padding:4px 12px; border-radius:999px; background:#eef3fb; color:#0d47a1; cursor:pointer; margin:0 0 6px 6px; font-size:.85rem; border:1px solid transparent; }
.chat-gov-chip.active { background:#1565c0; color:#fff; }
.chat-box { display:flex; flex-direction:column; height:62vh; background:#fff; border-radius:14px; border:1px solid #e6e9f0; }
.chat-msgs { flex:1; overflow-y:auto; padding:16px; display:flex; flex-direction:column; gap:8px; }
.bubble { max-width:75%; padding:9px 13px; border-radius:14px; font-size:.95rem; }
.bubble.them { align-self:flex-start; background:#eef1f6; border-bottom-right-radius:4px; }
.bubble.me { align-self:flex-end; background:linear-gradient(135deg,#1565c0,#0d47a1); color:#fff; border-bottom-left-radius:4px; }
.bubble .t { display:block; font-size:.68rem; opacity:.7; margin-top:3px; }
.chat-input { display:flex; gap:8px; padding:10px; border-top:1px solid #eef1f6; }
@media (max-width:760px){ .chat-grid{ grid-template-columns:1fr; } }

#blazor-error-ui {
    color-scheme: light only;
    background: lightyellow;
    bottom: 0; box-shadow: 0 -1px 2px rgba(0,0,0,.2);
    display: none; left: 0; padding: 0.6rem 1.25rem 0.7rem 1.25rem; position: fixed; width: 100%; z-index: 1000;
}
#blazor-error-ui .dismiss { cursor: pointer; position: absolute; left: 0.75rem; top: 0.5rem; }
