:root {
    --ink: #12344d;
    --ink-deep: #0b263a;
    --ink-soft: #587084;
    --coral: #f2674a;
    --coral-dark: #d94d31;
    --coral-soft: #fff0ec;
    --blue-soft: #eaf3f8;
    --green: #2d8067;
    --green-soft: #e8f6f0;
    --surface: #ffffff;
    --canvas: #f7f9f8;
    --line: #dfe7e9;
    --shadow-sm: 0 8px 30px rgba(18, 52, 77, 0.08);
    --shadow-lg: 0 24px 70px rgba(18, 52, 77, 0.16);
    --radius-sm: 12px;
    --radius-md: 20px;
    --radius-lg: 30px;
    --transition: 180ms ease;
}

* { box-sizing: border-box; }

html { scroll-behavior: smooth; }

body {
    min-height: 100vh;
    margin: 0;
    display: flex;
    flex-direction: column;
    color: var(--ink);
    background: var(--canvas);
    font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
    -webkit-font-smoothing: antialiased;
}

body, input, select, textarea, button { font-size: 16px; }

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

h1, h2, h3, h4, h5 {
    color: var(--ink-deep);
    font-weight: 780;
    letter-spacing: -0.035em;
}

h1 { font-size: clamp(2.2rem, 5vw, 4.75rem); line-height: 1.02; }
h2 { font-size: clamp(1.75rem, 3vw, 2.7rem); line-height: 1.12; }
h3 { font-size: 1.35rem; line-height: 1.25; }

a { color: var(--ink); text-underline-offset: 3px; }
a:hover { color: var(--coral-dark); }

svg {
    width: 1.25em;
    height: 1.25em;
    fill: none;
    stroke: currentColor;
    stroke-width: 1.8;
    stroke-linecap: round;
    stroke-linejoin: round;
}

.skip-link {
    position: fixed;
    z-index: 2000;
    top: 10px;
    left: 10px;
    padding: .75rem 1rem;
    border-radius: 10px;
    color: #fff;
    background: var(--ink-deep);
    transform: translateY(-150%);
}
.skip-link:focus { transform: translateY(0); }

.app-main { flex: 1; }

.app-navbar {
    min-height: 76px;
    border-bottom: 1px solid rgba(18, 52, 77, .08);
    background: rgba(255, 255, 255, .94);
    box-shadow: 0 2px 18px rgba(18, 52, 77, .05);
    backdrop-filter: blur(14px);
}

.navbar-brand {
    display: inline-flex;
    align-items: center;
    gap: .65rem;
    color: var(--ink-deep);
    font-size: 1.4rem;
    font-weight: 850;
    letter-spacing: -.04em;
}
.navbar-brand:hover { color: var(--ink-deep); }
.brand-mark {
    width: 40px;
    height: 40px;
    display: grid;
    place-items: center;
    border-radius: 13px;
    color: #fff;
    background: var(--coral);
    box-shadow: 0 7px 18px rgba(242, 103, 74, .28);
}
.brand-mark svg { width: 25px; height: 25px; stroke-width: 1.7; }

.navbar .nav-link {
    padding: .7rem .85rem !important;
    color: var(--ink-soft);
    font-weight: 650;
}
.navbar .nav-link:hover { color: var(--ink); }
.navbar-actions { margin-top: .75rem; }
.logout-form { display: inline-flex; }
.avatar-mini {
    width: 28px;
    height: 28px;
    display: inline-grid;
    place-items: center;
    margin-right: .35rem;
    border-radius: 50%;
    color: var(--ink);
    background: var(--blue-soft);
    font-size: .8rem;
    font-weight: 800;
    text-transform: uppercase;
}

.btn {
    min-height: 44px;
    padding: .68rem 1.05rem;
    border-radius: 12px;
    font-weight: 750;
    transition: transform var(--transition), box-shadow var(--transition), background-color var(--transition), border-color var(--transition);
}
.btn:hover { transform: translateY(-1px); }
.btn-primary {
    --bs-btn-bg: var(--coral);
    --bs-btn-border-color: var(--coral);
    --bs-btn-hover-bg: var(--coral-dark);
    --bs-btn-hover-border-color: var(--coral-dark);
    --bs-btn-active-bg: var(--coral-dark);
    --bs-btn-active-border-color: var(--coral-dark);
    --bs-btn-disabled-bg: #d9a095;
    --bs-btn-disabled-border-color: #d9a095;
    color: #fff;
    box-shadow: 0 8px 20px rgba(242, 103, 74, .2);
}
.btn-primary:hover { box-shadow: 0 12px 28px rgba(242, 103, 74, .3); }
.btn-outline-primary {
    --bs-btn-color: var(--ink);
    --bs-btn-border-color: #b7c7cf;
    --bs-btn-hover-color: var(--ink);
    --bs-btn-hover-bg: var(--blue-soft);
    --bs-btn-hover-border-color: var(--ink);
    --bs-btn-active-bg: var(--blue-soft);
    --bs-btn-active-border-color: var(--ink);
}
.btn-light { color: var(--ink-deep); background: #fff; border-color: #fff; box-shadow: var(--shadow-sm); }
.btn-ghost { color: var(--ink); background: transparent; border-color: transparent; box-shadow: none; }
.btn-ghost:hover { color: var(--coral-dark); background: var(--coral-soft); }
.btn-soft { min-height: 38px; padding: .45rem .9rem; color: var(--ink); background: var(--blue-soft); border-color: transparent; }
.btn-soft:hover { color: var(--ink); background: #dceaf1; }
.btn-icon {
    width: 44px;
    padding: 0;
    display: inline-grid;
    place-items: center;
    color: var(--ink-soft);
    background: transparent;
    border-color: transparent;
}
.btn-icon:hover { color: var(--coral-dark); background: var(--coral-soft); }
.btn-lg { min-height: 52px; padding: .85rem 1.35rem; font-size: 1rem; }

.form-control, .form-select {
    min-height: 51px;
    border: 1px solid #cbd8dd;
    border-radius: 12px;
    color: var(--ink-deep);
    background-color: #fff;
    box-shadow: none;
}
.form-control::placeholder { color: #91a1ab; }
.form-control:focus, .form-select:focus {
    border-color: var(--coral);
    box-shadow: 0 0 0 .22rem rgba(242, 103, 74, .14);
}
textarea.form-control { min-height: 115px; padding: .85rem 1rem; }
.form-label { margin-bottom: .5rem; color: var(--ink); font-size: .9rem; font-weight: 750; }
.form-hint { margin-top: .4rem; color: var(--ink-soft); font-size: .8rem; }
.optional-label { margin-left: .25rem; color: var(--ink-soft); font-size: .78rem; font-weight: 550; }

.flash-zone { position: relative; z-index: 20; }
.flash-zone:empty { display: none; }
.flash-message {
    max-width: 850px;
    margin: 1rem auto 0;
    display: flex;
    align-items: center;
    gap: .75rem;
    border: 0;
    border-radius: 14px;
    box-shadow: var(--shadow-sm);
    transition: opacity .5s ease;
}
.alert-symbol { width: 28px; height: 28px; display: grid; place-items: center; flex: 0 0 auto; border-radius: 50%; font-weight: 850; }
.alert-danger { color: #812d2d; background: #fff0f0; }
.alert-danger .alert-symbol { color: #fff; background: #c44646; }
.alert-success { color: #245f4d; background: var(--green-soft); }
.alert-success .alert-symbol { color: #fff; background: var(--green); }

.eyebrow {
    display: inline-block;
    margin-bottom: .7rem;
    color: var(--coral-dark);
    font-size: .75rem;
    font-weight: 850;
    letter-spacing: .13em;
    text-transform: uppercase;
}
.eyebrow-light { color: #ffd6cc; }

.hero-section { padding: 1.5rem 0 0; }
.hero-card {
    min-height: 620px;
    position: relative;
    display: flex;
    align-items: flex-end;
    overflow: hidden;
    border-radius: var(--radius-lg);
    background: var(--ink-deep);
    box-shadow: var(--shadow-lg);
}
.hero-photo, .auth-visual img {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
}
.hero-photo { object-position: center 42%; }
.hero-overlay {
    position: absolute;
    inset: 0;
    background: linear-gradient(90deg, rgba(6, 27, 42, .92) 0%, rgba(6, 27, 42, .72) 42%, rgba(6, 27, 42, .08) 80%), linear-gradient(0deg, rgba(6, 27, 42, .45), transparent 50%);
}
.hero-content {
    width: 100%;
    max-width: 1120px;
    position: relative;
    z-index: 1;
    padding: clamp(2rem, 6vw, 5rem);
    color: #fff;
}
.hero-content h1 { max-width: 760px; margin-bottom: 1.3rem; color: #fff; }
.hero-content > p { max-width: 600px; margin-bottom: 2rem; color: rgba(255, 255, 255, .8); font-size: 1.15rem; line-height: 1.65; }

.hero-search, .search-panel {
    display: grid;
    grid-template-columns: 1fr 1fr .72fr auto;
    gap: .35rem;
    padding: .55rem;
    border-radius: 17px;
    color: var(--ink);
    background: #fff;
    box-shadow: 0 20px 50px rgba(0, 0, 0, .2);
}
.search-field { min-width: 0; padding: .35rem .75rem; border-right: 1px solid var(--line); }
.search-field label { display: block; margin: 0 0 .1rem 2rem; color: var(--ink); font-size: .7rem; font-weight: 800; letter-spacing: .04em; text-transform: uppercase; }
.search-field input {
    width: 100%;
    min-height: 35px;
    padding: .25rem .25rem;
    border: 0;
    outline: 0;
    color: var(--ink-deep);
    background: transparent;
    font-weight: 650;
}
.search-field-date label { margin-left: .25rem; }
.input-with-icon { display: flex; align-items: center; gap: .55rem; }
.input-with-icon > svg { flex: 0 0 auto; color: var(--coral); }
.btn-search { min-width: 148px; display: inline-flex; align-items: center; justify-content: center; gap: .45rem; }

.trust-strip { padding: 3.5rem 0; }
.trust-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 2rem; }
.trust-item { display: flex; align-items: center; gap: 1rem; }
.trust-item > div { display: grid; gap: .25rem; }
.trust-item strong { color: var(--ink-deep); font-size: .98rem; }
.trust-item span:not(.feature-icon) { color: var(--ink-soft); font-size: .85rem; }
.feature-icon { width: 48px; height: 48px; display: grid; place-items: center; flex: 0 0 auto; border-radius: 15px; font-size: 1.1rem; font-weight: 850; }
.feature-icon-green { color: var(--green); background: var(--green-soft); }
.feature-icon-blue { color: #37759a; background: var(--blue-soft); }
.feature-icon-coral { color: var(--coral-dark); background: var(--coral-soft); }

.content-section { padding: 4rem 0; background: #fff; }
.results-section { min-height: 430px; background: var(--canvas); }
.section-heading, .dashboard-header {
    margin-bottom: 2.2rem;
    display: flex;
    align-items: flex-end;
    justify-content: space-between;
    gap: 2rem;
}
.section-heading h2, .dashboard-header h1 { margin-bottom: .5rem; }
.section-heading p, .dashboard-header p { margin-bottom: 0; color: var(--ink-soft); }
.compact-heading { align-items: center; }
.compact-heading h2 { font-size: 2rem; }
.link-arrow { display: inline-flex; align-items: center; gap: .5rem; color: var(--ink); font-weight: 800; text-decoration: none; }
.link-arrow span { color: var(--coral); transition: transform var(--transition); }
.link-arrow:hover span { transform: translateX(4px); }

.trip-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 1.25rem; }
.trip-card, .detail-card, .form-section-card {
    border: 1px solid var(--line);
    border-radius: var(--radius-md);
    background: #fff;
    box-shadow: 0 5px 20px rgba(18, 52, 77, .045);
}
.trip-card { padding: 1.35rem; transition: transform var(--transition), box-shadow var(--transition), border-color var(--transition); }
.trip-card:hover { transform: translateY(-4px); border-color: #c1d0d5; box-shadow: var(--shadow-sm); }
.trip-card-top, .trip-card-footer { display: flex; align-items: center; justify-content: space-between; gap: 1rem; }
.date-badge { display: inline-flex; align-items: center; gap: .4rem; color: var(--ink-soft); font-size: .78rem; font-weight: 700; }
.date-badge svg { color: var(--coral); }
.trip-price { color: var(--ink-deep); font-size: 1.15rem; }
.route-line { margin: 1.7rem 0; display: grid; grid-template-columns: auto minmax(0, 1fr); gap: .15rem .7rem; align-items: center; }
.route-line > .route-dot-start { grid-column: 1; grid-row: 1; }
.route-line > div:first-of-type { grid-column: 2; grid-row: 1; }
.route-line > .route-track { grid-column: 1; grid-row: 2; }
.route-line > .route-dot-end { grid-column: 1; grid-row: 3; }
.route-line > div:last-of-type { grid-column: 2; grid-row: 3; }
.route-line > div { display: flex; align-items: baseline; justify-content: space-between; gap: 1rem; }
.route-line strong { min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; color: var(--ink-deep); }
.route-line > div > span { color: var(--ink-soft); font-size: .72rem; }
.route-dot { width: 10px; height: 10px; display: block; border: 2px solid var(--coral); border-radius: 50%; background: #fff; }
.route-dot-end { border-color: var(--ink); background: var(--ink); }
.route-track { width: 2px; height: 21px; margin-left: 4px; background: repeating-linear-gradient(to bottom, #b7c6cc 0 4px, transparent 4px 8px); }
.trip-card-footer { padding-top: 1rem; border-top: 1px solid var(--line); }
.driver-mini { min-width: 0; display: flex; align-items: center; gap: .65rem; }
.driver-mini > div { min-width: 0; display: grid; }
.driver-mini strong { overflow: hidden; text-overflow: ellipsis; color: var(--ink-deep); font-size: .86rem; }
.driver-mini span:not(.avatar) { color: var(--ink-soft); font-size: .72rem; }
.avatar {
    width: 39px;
    height: 39px;
    display: inline-grid;
    place-items: center;
    flex: 0 0 auto;
    border: 3px solid #fff;
    border-radius: 50%;
    color: var(--ink);
    background: var(--blue-soft);
    box-shadow: 0 0 0 1px #d5e1e5;
    font-weight: 850;
    text-transform: uppercase;
}

.cta-section { padding: 4rem 0; }
.cta-card {
    min-height: 250px;
    padding: clamp(2rem, 5vw, 4rem);
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 3rem;
    overflow: hidden;
    position: relative;
    border-radius: var(--radius-lg);
    color: #fff;
    background: var(--ink-deep);
}
.cta-card::after { content: ""; width: 330px; height: 330px; position: absolute; right: -100px; top: -180px; border: 55px solid rgba(255, 255, 255, .06); border-radius: 50%; }
.cta-card > * { position: relative; z-index: 1; }
.cta-card h2 { max-width: 680px; margin-bottom: .8rem; color: #fff; }
.cta-card p { max-width: 650px; margin-bottom: 0; color: rgba(255, 255, 255, .72); }

.page-hero { color: #fff; background: var(--ink-deep); }
.page-hero-search { padding: 4.8rem 0 0; margin-bottom: 3.8rem; }
.page-hero h1 { margin-bottom: .7rem; color: #fff; font-size: clamp(2.4rem, 5vw, 4rem); }
.page-hero p { margin-bottom: 2.3rem; color: rgba(255, 255, 255, .72); font-size: 1.05rem; }
.search-panel { position: relative; bottom: -2rem; box-shadow: var(--shadow-lg); }

.results-list { display: grid; gap: 1rem; }
.result-card {
    padding: 1.3rem 1.4rem;
    display: grid;
    grid-template-columns: 145px minmax(240px, 1.6fr) minmax(180px, 1fr) auto;
    align-items: center;
    gap: 1.5rem;
    border: 1px solid var(--line);
    border-radius: 18px;
    background: #fff;
    transition: border-color var(--transition), box-shadow var(--transition), transform var(--transition);
}
.result-card:hover { transform: translateY(-2px); border-color: #bdcdd3; box-shadow: var(--shadow-sm); }
.result-date { display: grid; gap: .1rem; }
.result-day { color: var(--ink-soft); font-size: .76rem; }
.result-date strong { color: var(--ink-deep); font-size: 1.45rem; }
.result-route { display: grid; grid-template-columns: auto 1fr; gap: 0 .7rem; align-items: center; }
.result-route div { display: grid; }
.result-route div span, .result-driver div span { color: var(--ink-soft); font-size: .68rem; text-transform: uppercase; letter-spacing: .06em; }
.result-route div strong, .result-driver strong { color: var(--ink-deep); }
.result-route-line { width: 2px; height: 18px; margin-left: 4px; background: #c3d0d5; }
.result-driver { min-width: 0; display: flex; align-items: center; gap: .7rem; }
.result-driver div { min-width: 0; display: grid; }
.result-driver strong { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; font-size: .85rem; }
.result-meta { display: flex; align-items: center; justify-content: flex-end; gap: 1rem; }
.seat-pill { padding: .4rem .65rem; border-radius: 999px; color: var(--green); background: var(--green-soft); font-size: .75rem; font-weight: 750; white-space: nowrap; }
.result-price { display: grid; color: var(--ink-deep); font-size: 1.25rem; white-space: nowrap; }
.result-price small { color: var(--ink-soft); font-size: .65rem; font-weight: 600; }

.empty-state { padding: 4rem 1.5rem; display: flex; flex-direction: column; align-items: center; text-align: center; border: 1px dashed #b9c8ce; border-radius: var(--radius-md); background: #fff; }
.empty-state h2, .empty-state h3 { margin-bottom: .7rem; }
.empty-state p { max-width: 520px; margin-bottom: 1.3rem; color: var(--ink-soft); }
.empty-icon { width: 58px; height: 58px; margin-bottom: 1.2rem; display: grid; place-items: center; border-radius: 18px; color: var(--coral-dark); background: var(--coral-soft); font-size: 1.4rem; font-weight: 850; }
.empty-icon svg { width: 28px; height: 28px; }

.page-shell { padding: 3rem 0 5rem; }
.breadcrumb-simple { margin-bottom: 2.2rem; display: flex; gap: .6rem; color: var(--ink-soft); font-size: .82rem; }
.breadcrumb-simple a { color: var(--ink-soft); text-decoration: none; }
.breadcrumb-simple a:hover { color: var(--coral-dark); }
.detail-layout { display: grid; grid-template-columns: minmax(0, 1fr) 350px; gap: 2.4rem; align-items: start; }
.detail-main { min-width: 0; }
.detail-header { margin-bottom: 2rem; }
.detail-header h1 { margin-bottom: 1.3rem; font-size: clamp(2.2rem, 4vw, 3.6rem); }
.detail-tags { display: flex; flex-wrap: wrap; gap: .7rem; }
.detail-tags > span { padding: .55rem .75rem; display: inline-flex; align-items: center; gap: .45rem; border-radius: 999px; color: var(--ink-soft); background: #fff; font-size: .8rem; font-weight: 700; box-shadow: 0 3px 12px rgba(18, 52, 77, .06); }
.detail-tags svg { color: var(--coral); }
.detail-card { padding: 1.7rem; margin-bottom: 1rem; }
.detail-card h2 { margin-bottom: 1.4rem; font-size: 1.25rem; letter-spacing: -.02em; }
.detail-route { display: grid; grid-template-columns: 60px 18px 1fr; gap: .7rem; }
.detail-route-time { padding-top: .1rem; color: var(--ink-deep); font-weight: 800; }
.route-axis { display: flex; flex-direction: column; align-items: center; }
.route-axis > span:nth-child(2) { width: 2px; min-height: 52px; flex: 1; background: #bdcbd0; }
.route-stops { display: flex; min-height: 85px; flex-direction: column; justify-content: space-between; }
.route-stops > div { display: grid; }
.route-stops small { color: var(--ink-soft); font-size: .72rem; }
.route-stops strong { color: var(--ink-deep); font-size: 1.05rem; }
.driver-profile { display: flex; align-items: center; gap: 1rem; }
.avatar-large { width: 58px; height: 58px; font-size: 1.25rem; }
.driver-profile > div { display: grid; }
.driver-profile > div strong { color: var(--ink-deep); font-size: 1.05rem; }
.driver-profile > div span { color: var(--ink-soft); font-size: .8rem; }
.driver-profile > div a { margin-top: .2rem; color: var(--coral-dark); font-size: .82rem; font-weight: 750; }
.verified-pill { margin-left: auto; padding: .35rem .6rem; border-radius: 999px; color: var(--green); background: var(--green-soft); font-size: .72rem; font-weight: 750; }
.detail-description { margin-bottom: 0; color: var(--ink-soft); line-height: 1.75; white-space: pre-line; }
.passenger-list { display: grid; gap: .85rem; }
.passenger-row { padding-bottom: .85rem; display: flex; align-items: center; gap: .75rem; border-bottom: 1px solid var(--line); }
.passenger-row:last-child { padding-bottom: 0; border-bottom: 0; }
.passenger-row > div { display: grid; }
.passenger-row > div strong { font-size: .88rem; }
.passenger-row > div span { color: var(--ink-soft); font-size: .75rem; }
.status-badge { padding: .4rem .65rem; display: inline-flex; align-items: center; gap: .3rem; border-radius: 999px; font-size: .72rem; font-weight: 800; text-transform: capitalize; white-space: nowrap; }
.status-confirmed { margin-left: auto; color: var(--green); background: var(--green-soft); }
.detail-actions { margin-top: 1.5rem; display: flex; align-items: center; justify-content: space-between; gap: 1rem; }

.booking-card {
    position: sticky;
    top: 100px;
    padding: 1.7rem;
    border: 1px solid var(--line);
    border-radius: var(--radius-md);
    background: #fff;
    box-shadow: var(--shadow-sm);
}
.booking-price, .booking-summary { display: flex; align-items: center; justify-content: space-between; gap: 1rem; }
.booking-price span, .booking-summary span { color: var(--ink-soft); font-size: .82rem; }
.booking-price strong { color: var(--ink-deep); font-size: 1.8rem; }
.booking-summary strong { color: var(--ink-deep); }
.booking-divider { height: 1px; margin: 1.2rem 0; background: var(--line); }
.booking-card form { margin-top: 1.4rem; }
.booking-card .form-select { margin-bottom: 1rem; }
.booking-reassurance { margin: .8rem 0 0; color: var(--green); font-size: .75rem; text-align: center; }
.booking-message { color: var(--ink-soft); line-height: 1.55; }
.inline-state { margin-top: 1.5rem; padding: 1rem; display: grid; gap: .2rem; border-radius: 14px; }
.inline-state strong { font-size: .9rem; }
.inline-state span { font-size: .78rem; }
.inline-state-info { color: #2f6688; background: var(--blue-soft); }
.inline-state-success { color: var(--green); background: var(--green-soft); }
.inline-state-warning { color: #815b1c; background: #fff5dc; }

.form-page { background: linear-gradient(180deg, #eef4f5 0, var(--canvas) 400px); }
.form-container { max-width: 980px; }
.form-page-header { max-width: 720px; margin-bottom: 2rem; }
.form-page-header h1 { margin-bottom: .7rem; font-size: clamp(2.2rem, 4vw, 3.4rem); }
.form-page-header p { color: var(--ink-soft); font-size: 1.05rem; }
.notice-card { margin-bottom: 1.2rem; padding: 1rem 1.2rem; display: flex; align-items: center; gap: .8rem; border: 1px solid #c9dce6; border-radius: 15px; color: #315f78; background: var(--blue-soft); }
.notice-card > div { display: grid; }
.notice-card span:not(.notice-icon) { font-size: .82rem; }
.notice-icon { width: 29px; height: 29px; display: grid; place-items: center; flex: 0 0 auto; border-radius: 50%; color: #fff; background: #4a839f; font-family: Georgia, serif; font-weight: 850; }
.journey-form { display: grid; gap: 1rem; }
.form-section-card { padding: clamp(1.4rem, 3vw, 2rem); }
.form-section-title { margin-bottom: 1.6rem; display: flex; gap: .9rem; }
.form-section-title h2 { margin-bottom: .3rem; font-size: 1.25rem; }
.form-section-title p { margin-bottom: 0; color: var(--ink-soft); font-size: .85rem; }
.step-number { width: 34px; height: 34px; display: grid; place-items: center; flex: 0 0 auto; border-radius: 11px; color: #fff; background: var(--ink); font-size: .85rem; font-weight: 850; }
.form-input-icon { position: relative; }
.form-input-icon > svg { position: absolute; left: .9rem; z-index: 1; color: var(--coral); }
.form-input-icon .form-control { padding-left: 2.8rem; }
.input-suffix { position: relative; }
.input-suffix .form-control { padding-right: 3rem; }
.input-suffix span { position: absolute; right: 1rem; top: 50%; color: var(--ink-soft); font-weight: 800; transform: translateY(-50%); }
.form-submit-bar { padding: 1rem 0; display: flex; align-items: center; justify-content: flex-end; gap: .7rem; }

.auth-page { padding: 3rem 0 5rem; background: linear-gradient(135deg, #eef4f5, #fff5f1); }
.auth-card { max-width: 1050px; min-height: 650px; margin: 0 auto; display: grid; grid-template-columns: 1.05fr .95fr; overflow: hidden; border: 1px solid rgba(18, 52, 77, .08); border-radius: var(--radius-lg); background: #fff; box-shadow: var(--shadow-lg); }
.auth-card-register { min-height: 780px; }
.auth-card-compact { min-height: 590px; }
.auth-visual { min-height: 520px; position: relative; overflow: hidden; background: var(--ink-deep); }
.auth-visual img { object-position: 60% center; }
.auth-visual-overlay { position: absolute; inset: 0; background: linear-gradient(0deg, rgba(7, 28, 43, .84), rgba(7, 28, 43, .06) 70%); }
.auth-visual blockquote, .auth-benefits { position: absolute; z-index: 1; right: 2.5rem; bottom: 2.5rem; left: 2.5rem; color: #fff; }
.auth-visual blockquote { max-width: 420px; margin: 0; font-size: 1.65rem; font-weight: 750; letter-spacing: -.03em; line-height: 1.25; }
.auth-benefits h2 { color: #fff; font-size: 2rem; }
.auth-benefits ul { padding: 0; margin: 1.2rem 0 0; display: grid; gap: .55rem; list-style: none; }
.auth-benefits li::before { content: "✓"; margin-right: .55rem; color: #9ce0ca; font-weight: 850; }
.auth-form-panel { padding: clamp(2rem, 5vw, 4rem); display: flex; flex-direction: column; justify-content: center; }
.auth-form-panel h1 { margin-bottom: .65rem; font-size: clamp(2rem, 4vw, 3rem); }
.auth-intro { margin-bottom: 2rem; color: var(--ink-soft); }
.auth-switch { margin: 1.5rem 0 0; color: var(--ink-soft); text-align: center; }
.auth-switch a { color: var(--coral-dark); font-weight: 800; }
.auth-form-meta { margin-top: .55rem; text-align: right; }
.auth-form-meta a { color: var(--coral-dark); font-size: .8rem; font-weight: 750; text-decoration: none; }
.auth-form-meta a:hover { text-decoration: underline; }
.auth-secondary-form { margin-top: .8rem; }
.otp-input { min-height: 64px; font-size: 1.8rem; font-weight: 850; letter-spacing: .45em; text-align: center; }
.security-note { margin-top: 1.3rem; padding: .9rem; display: flex; align-items: flex-start; gap: .65rem; border-radius: 13px; color: var(--green); background: var(--green-soft); }
.security-note > span { width: 22px; height: 22px; display: grid; place-items: center; flex: 0 0 auto; border-radius: 50%; color: #fff; background: var(--green); font-size: .7rem; font-weight: 850; }
.security-note p { margin: 0; font-size: .76rem; line-height: 1.5; }
.password-field { position: relative; }
.password-field .form-control { padding-right: 5.6rem; }
.password-toggle { position: absolute; top: 50%; right: .75rem; padding: .35rem; border: 0; color: var(--ink-soft); background: transparent; font-size: .76rem; font-weight: 750; transform: translateY(-50%); }
.password-toggle:hover { color: var(--coral-dark); }

.narrow-content { max-width: 1100px; }
.dashboard-header { margin-bottom: 2.5rem; align-items: center; }
.dashboard-header h1 { font-size: clamp(2.2rem, 4vw, 3.4rem); }
.booking-list { display: grid; gap: 1rem; }
.my-booking-card { padding: 1.35rem; display: grid; grid-template-columns: 130px 1fr auto auto; align-items: center; gap: 1.5rem; border: 1px solid var(--line); border-radius: 18px; background: #fff; box-shadow: 0 4px 18px rgba(18, 52, 77, .04); }
.booking-date-box { display: grid; justify-items: start; gap: .1rem; }
.booking-date-box svg { margin-bottom: .3rem; color: var(--coral); }
.booking-date-box strong { color: var(--ink-deep); font-size: .85rem; }
.booking-date-box span { color: var(--ink-soft); font-size: .78rem; }
.booking-route span { color: var(--ink-soft); font-size: .7rem; text-transform: uppercase; letter-spacing: .07em; }
.booking-route h2 { margin: .2rem 0 .3rem; font-size: 1.2rem; }
.booking-route h2 span { color: var(--coral); font-size: inherit; }
.booking-route p { margin: 0; color: var(--ink-soft); font-size: .8rem; }
.booking-facts { display: flex; gap: 1.3rem; }
.booking-facts > div { display: grid; }
.booking-facts span { color: var(--ink-soft); font-size: .7rem; }
.booking-facts strong { color: var(--ink-deep); }
.empty-state-large { min-height: 400px; justify-content: center; }

.profile-container { max-width: 1050px; }
.profile-layout { display: grid; grid-template-columns: 290px minmax(0, 1fr); gap: 1.5rem; align-items: start; }
.profile-summary { padding: 2rem; border-radius: var(--radius-md); color: #fff; background: var(--ink-deep); box-shadow: var(--shadow-sm); }
.avatar-profile { width: 76px; height: 76px; margin-bottom: 1.2rem; color: var(--ink); background: #fff; font-size: 1.8rem; }
.profile-summary h2 { margin-bottom: .35rem; color: #fff; font-size: 1.45rem; }
.profile-type { display: inline-block; padding: .3rem .55rem; border-radius: 999px; color: #c5e5f3; background: rgba(255, 255, 255, .1); font-size: .7rem; font-weight: 750; text-transform: capitalize; }
.profile-trust { margin-top: 2rem; padding-top: 1.4rem; display: flex; gap: .75rem; border-top: 1px solid rgba(255, 255, 255, .12); }
.profile-trust > span { width: 27px; height: 27px; display: grid; place-items: center; flex: 0 0 auto; border-radius: 50%; color: var(--green); background: #d6f0e5; font-weight: 850; }
.profile-trust strong { font-size: .85rem; }
.profile-trust p { margin: .2rem 0 0; color: rgba(255, 255, 255, .62); font-size: .75rem; line-height: 1.5; }
.profile-form { margin: 0; }
.profile-submit { padding-bottom: 0; }

.app-footer { padding: 2.2rem 0; color: #b8c6cf; background: var(--ink-deep); }
.footer-inner { display: grid; grid-template-columns: auto 1fr auto; align-items: center; gap: 1.5rem; }
.footer-brand { color: #fff; font-size: 1.25rem; font-weight: 850; text-decoration: none; }
.footer-inner p { margin: 0; font-size: .82rem; }
.footer-links { display: flex; align-items: center; gap: 1rem; font-size: .75rem; }
.footer-links a { color: #d2dce2; text-decoration: none; }
.footer-links a:hover { color: #fff; }

/* Rex, assistant de support */
.rex-widget { position: fixed; z-index: 1200; right: 1.25rem; bottom: 1.25rem; }
.rex-launcher { min-height: 58px; display: flex; align-items: center; gap: .7rem; padding: .55rem 1rem .55rem .6rem; border: 0; border-radius: 18px; color: #fff; background: var(--ink-deep); box-shadow: var(--shadow-lg); }
.rex-launcher:hover { background: #123d59; transform: translateY(-2px); }
.rex-avatar { width: 40px; height: 40px; display: grid; place-items: center; flex: 0 0 auto; border-radius: 14px; color: #fff; background: linear-gradient(145deg, var(--coral), #f8915d); font-size: 1.05rem; font-weight: 900; box-shadow: 0 7px 18px rgba(242, 103, 74, .28); }
.rex-launcher-copy { display: grid; text-align: left; line-height: 1.15; }
.rex-launcher-copy strong { font-size: .86rem; }
.rex-launcher-copy small { margin-top: .16rem; color: #bcd0dc; font-size: .7rem; }
.rex-panel { position: absolute; right: 0; bottom: 0; width: min(390px, calc(100vw - 2rem)); height: min(650px, calc(100vh - 2rem)); display: grid; grid-template-rows: auto auto 1fr auto auto auto; overflow: hidden; border: 1px solid rgba(18, 52, 77, .12); border-radius: 24px; background: #fff; box-shadow: 0 30px 90px rgba(6, 27, 42, .3); }
.rex-panel[hidden] { display: none; }
.rex-header { display: flex; align-items: center; gap: .75rem; padding: 1rem; color: #fff; background: var(--ink-deep); }
.rex-header .rex-avatar { width: 42px; height: 42px; }
.rex-header > div { display: grid; flex: 1; }
.rex-header strong { font-size: 1rem; }
.rex-header span { color: #bfd0da; font-size: .72rem; }
.rex-close { width: 38px; height: 38px; border: 0; border-radius: 12px; color: #fff; background: rgba(255, 255, 255, .1); font-size: 1.6rem; line-height: 1; }
.rex-close:hover { background: rgba(255, 255, 255, .18); }
.rex-privacy { margin: 0; padding: .72rem 1rem; color: #657b89; background: #f2f7f9; font-size: .67rem; line-height: 1.45; }
.rex-messages { min-height: 0; padding: 1rem; display: flex; flex-direction: column; gap: .8rem; overflow-y: auto; background: #fbfcfc; }
.rex-message { max-width: 88%; }
.rex-message p { margin: 0; padding: .75rem .9rem; border-radius: 16px; font-size: .84rem; line-height: 1.5; white-space: pre-wrap; }
.rex-message-assistant { align-self: flex-start; }
.rex-message-assistant p { color: var(--ink); background: var(--blue-soft); border-bottom-left-radius: 5px; }
.rex-message-user { align-self: flex-end; }
.rex-message-user p { color: #fff; background: var(--coral); border-bottom-right-radius: 5px; }
.rex-status { align-self: flex-start; margin: 0; color: var(--ink-soft); font-size: .74rem; font-style: italic; }
.rex-feedback { margin-top: .3rem; display: flex; align-items: center; gap: .25rem; color: var(--ink-soft); font-size: .65rem; }
.rex-feedback button { padding: .15rem .4rem; border: 1px solid var(--line); border-radius: 7px; color: var(--ink); background: #fff; font-size: .64rem; }
.rex-suggestions { padding: .65rem 1rem 0; display: flex; gap: .4rem; overflow-x: auto; background: #fff; }
.rex-suggestions[hidden] { display: none; }
.rex-suggestions button { flex: 0 0 auto; padding: .38rem .65rem; border: 1px solid #cbd9df; border-radius: 999px; color: var(--ink); background: #fff; font-size: .68rem; }
.rex-suggestions button:hover { border-color: var(--coral); color: var(--coral-dark); }
.rex-form { margin: 0; padding: .75rem 1rem; display: grid; grid-template-columns: 1fr 42px; gap: .55rem; background: #fff; }
.rex-form textarea { max-height: 110px; resize: none; padding: .68rem .8rem; border: 1px solid #cbd9df; border-radius: 13px; outline: none; font-size: .82rem; line-height: 1.35; }
.rex-form textarea:focus { border-color: var(--coral); box-shadow: 0 0 0 3px var(--coral-soft); }
.rex-form button { width: 42px; height: 42px; align-self: end; display: grid; place-items: center; border: 0; border-radius: 13px; color: #fff; background: var(--coral); }
.rex-form button:disabled { opacity: .55; }
.rex-footer { padding: 0 1rem .7rem; display: flex; justify-content: space-between; color: var(--ink-soft); background: #fff; font-size: .62rem; }
.rex-footer button { padding: 0; border: 0; color: var(--ink-soft); background: transparent; font-size: inherit; text-decoration: underline; }

@media (max-width: 1199.98px) {
    .result-card { grid-template-columns: 120px minmax(210px, 1.5fr) minmax(150px, 1fr); }
    .result-meta { grid-column: 2 / -1; justify-content: flex-start; padding-top: .7rem; border-top: 1px solid var(--line); }
}

@media (max-width: 991.98px) {
    .app-navbar { min-height: 68px; }
    .navbar-collapse { padding: .8rem 0 1rem; }
    .navbar-actions { display: grid; grid-template-columns: 1fr 1fr; }
    .navbar-actions .btn { width: 100%; }
    .logout-form { position: absolute; right: .75rem; bottom: 1rem; }
    .hero-card { min-height: 680px; }
    .hero-overlay { background: linear-gradient(90deg, rgba(6, 27, 42, .92), rgba(6, 27, 42, .52)), linear-gradient(0deg, rgba(6, 27, 42, .45), transparent); }
    .hero-search, .search-panel { grid-template-columns: 1fr 1fr; }
    .search-field { border-right: 0; border-bottom: 1px solid var(--line); }
    .search-field-date { border-bottom: 0; }
    .btn-search { min-width: 0; }
    .trip-grid { grid-template-columns: repeat(2, 1fr); }
    .detail-layout { grid-template-columns: 1fr; }
    .booking-card { position: static; grid-row: 1; }
    .auth-card { grid-template-columns: .8fr 1.2fr; }
    .auth-visual blockquote, .auth-benefits { right: 1.5rem; bottom: 1.5rem; left: 1.5rem; }
    .auth-visual blockquote { font-size: 1.3rem; }
    .my-booking-card { grid-template-columns: 110px 1fr auto; }
    .my-booking-card > .status-badge { grid-column: 3; grid-row: 1; }
    .booking-facts { grid-column: 2 / -1; }
}

@media (max-width: 767.98px) {
    h1 { font-size: 2.5rem; }
    .page-hero h1 { font-size: 2.05rem; }
    .hero-section { padding-top: .7rem; }
    .hero-card { min-height: 720px; border-radius: 22px; }
    .hero-photo { object-position: 60% center; }
    .hero-content { padding: 2rem 1.2rem; }
    .hero-content > p { font-size: 1rem; }
    .hero-search, .search-panel { grid-template-columns: 1fr; padding: .65rem; }
    .search-field, .search-field-date { border-bottom: 1px solid var(--line); }
    .btn-search { min-height: 50px; }
    .trust-strip { padding: 2.5rem 0; }
    .trust-grid { grid-template-columns: 1fr; gap: 1.3rem; }
    .content-section { padding: 3rem 0; }
    .section-heading, .dashboard-header { align-items: flex-start; flex-direction: column; gap: 1rem; }
    .trip-grid { grid-template-columns: 1fr; }
    .cta-section { padding: 2.5rem 0; }
    .cta-card { padding: 2rem; align-items: flex-start; flex-direction: column; border-radius: 22px; }
    .page-hero-search { padding-top: 3rem; margin-bottom: 3rem; }
    .search-panel { bottom: -1.5rem; }
    .result-card { grid-template-columns: 85px 1fr; gap: 1rem; }
    .result-route { grid-column: 2; }
    .result-driver { grid-column: 2; padding-top: .8rem; border-top: 1px solid var(--line); }
    .result-meta { grid-column: 1 / -1; flex-wrap: wrap; }
    .result-meta .btn { margin-left: auto; }
    .page-shell { padding: 2rem 0 3.5rem; }
    .detail-card { padding: 1.3rem; }
    .detail-actions { align-items: flex-start; flex-direction: column-reverse; }
    .driver-profile { align-items: flex-start; }
    .verified-pill { display: none; }
    .form-section-card { padding: 1.3rem; }
    .form-submit-bar { align-items: stretch; flex-direction: column-reverse; }
    .form-submit-bar .btn { width: 100%; }
    .auth-page { padding: 1rem 0 3rem; }
    .auth-card { grid-template-columns: 1fr; border-radius: 22px; }
    .auth-visual { min-height: 260px; }
    .auth-visual blockquote { font-size: 1.2rem; }
    .auth-benefits h2 { font-size: 1.5rem; }
    .auth-benefits ul { display: none; }
    .auth-form-panel { padding: 2rem 1.3rem; }
    .my-booking-card { grid-template-columns: 1fr auto; gap: 1rem; }
    .booking-date-box { grid-column: 1; }
    .my-booking-card > .status-badge { grid-column: 2; grid-row: 1; }
    .booking-route, .booking-facts { grid-column: 1 / -1; }
    .profile-layout { grid-template-columns: 1fr; }
    .profile-summary { display: grid; grid-template-columns: auto 1fr; gap: .2rem 1rem; }
    .avatar-profile { grid-row: 1 / 3; margin: 0; }
    .profile-type { align-self: start; justify-self: start; }
    .profile-trust { grid-column: 1 / -1; }
    .footer-inner { grid-template-columns: 1fr; text-align: center; }
    .footer-links { justify-content: center; flex-wrap: wrap; }
}

@media (max-width: 479.98px) {
    .container { --bs-gutter-x: 1.3rem; }
    .hero-card { min-height: 760px; }
    .hero-content h1 br { display: none; }
    .navbar-actions { grid-template-columns: 1fr; }
    .logout-form { position: static; }
    .result-card { grid-template-columns: 1fr; }
    .result-date, .result-route, .result-driver, .result-meta { grid-column: 1; }
    .result-date { grid-template-columns: auto auto; justify-content: space-between; align-items: center; }
    .result-meta .btn { width: 100%; margin-left: 0; }
    .detail-tags { gap: .4rem; }
    .detail-tags > span { padding: .45rem .6rem; }
    .booking-card { padding: 1.3rem; }
    .rex-widget { right: .65rem; bottom: .65rem; }
    .rex-panel { position: fixed; inset: .65rem; width: auto; height: auto; }
    .rex-launcher-copy { display: none; }
    .rex-launcher { width: 58px; padding: .55rem; border-radius: 50%; }
    .rex-launcher .rex-avatar { border-radius: 50%; }
}

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