/* ═══════════════════════════════════════════════════════
   MotoSheba Admin Panel — Global Stylesheet
   ═══════════════════════════════════════════════════════ */

/* ── Reset & Base ── */
*, *::before, *::after {
    box-sizing: border-box;
}

body {
    margin: 0;
    font-family: 'Segoe UI', system-ui, -apple-system, sans-serif;
}

/* ══════════════════════════════════════════
   DASHBOARD LAYOUT
   ══════════════════════════════════════════ */

.dashboard-body {
    background: #f0f4f8;
    min-height: 100vh;
}

/* ── Wrapper flex container ── */
#wrapper {
    min-height: 100vh;
    transition: all 0.3s ease;
}

/* ── Sidebar ── */
.sidebar-nav {
    width: 260px;
    min-height: 100vh;
    background: linear-gradient(180deg, #0f172a 0%, #1e293b 100%);
    display: flex;
    flex-direction: column;
    padding: 0;
    position: sticky;
    top: 0;
    height: 100vh;
    flex-shrink: 0;
    transition: width 0.3s ease;
    overflow: hidden;
}

/* Collapsed sidebar */
#wrapper.sidebar-collapsed .sidebar-nav {
    width: 70px;
}

#wrapper.sidebar-collapsed .sidebar-brand span,
#wrapper.sidebar-collapsed .sidebar-nav .nav-link span,
#wrapper.sidebar-collapsed .sidebar-footer .btn-logout span {
    display: none;
}

.sidebar-brand {
    display: flex;
    align-items: center;
    padding: 1.5rem 1.25rem;
    color: #fff;
    font-size: 1.2rem;
    font-weight: 700;
    letter-spacing: -0.3px;
    white-space: nowrap;
    border-bottom: 1px solid rgba(255,255,255,0.08);
    position: relative;
}

.sidebar-brand i.bi-motorcycle {
    font-size: 1.5rem;
    color: #f97316;
    flex-shrink: 0;
}

.sidebar-close-btn {
    margin-left: auto;
    color: rgba(255, 255, 255, 0.75);
    border: 1px solid rgba(255, 255, 255, 0.15);
    border-radius: 8px;
    padding: 0.25rem 0.45rem;
    line-height: 1;
    background: transparent;
}

.sidebar-close-btn:hover {
    color: #fff;
    background: rgba(255, 255, 255, 0.08);
}

.sidebar-close-btn i {
    font-size: 1rem;
    color: inherit;
}

.sidebar-divider {
    border-color: rgba(255,255,255,0.08);
    margin: 0.5rem 0;
}

.sidebar-nav .nav {
    padding: 0.75rem 0.75rem;
    flex-grow: 1;
}

.sidebar-nav .nav-link {
    color: rgba(255,255,255,0.65);
    border-radius: 10px;
    padding: 0.65rem 0.9rem;
    font-size: 0.9rem;
    font-weight: 500;
    display: flex;
    align-items: center;
    gap: 0.6rem;
    transition: background 0.2s, color 0.2s;
    white-space: nowrap;
}

.sidebar-nav .nav-link i {
    font-size: 1.1rem;
    flex-shrink: 0;
}

.sidebar-nav .nav-link:hover,
.sidebar-nav .nav-link.active {
    background: rgba(249, 115, 22, 0.15);
    color: #f97316;
}

.sidebar-footer {
    padding: 1rem;
    border-top: 1px solid rgba(255,255,255,0.08);
    margin-top: auto;
}

.btn-logout {
    background: rgba(239, 68, 68, 0.12);
    border: 1px solid rgba(239, 68, 68, 0.25);
    color: #fca5a5;
    border-radius: 10px;
    padding: 0.6rem 1rem;
    font-size: 0.875rem;
    font-weight: 500;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    transition: background 0.2s, color 0.2s;
    white-space: nowrap;
}

.btn-logout:hover {
    background: rgba(239, 68, 68, 0.25);
    color: #fff;
}

/* ── Top Navbar ── */
.top-navbar {
    background: #fff;
    border-bottom: 1px solid #e5e9ef;
    padding: 0.65rem 1.25rem;
    box-shadow: 0 1px 6px rgba(0,0,0,0.06);
    position: sticky;
    top: 0;
    z-index: 100;
}

.top-navbar-inner {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 0.75rem;
    min-width: 0;
    width: 100%;
}

.top-navbar-start,
.top-navbar-end,
.top-navbar-user {
    display: flex;
    align-items: center;
    min-width: 0;
}

.top-navbar-start {
    gap: 0.75rem;
    flex: 1 1 auto;
}

.top-navbar-end {
    gap: 0.5rem;
    flex: 0 0 auto;
    justify-content: flex-end;
}

.top-navbar-user {
    gap: 0.4rem;
}

.top-navbar-title {
    margin: 0;
    font-size: clamp(1rem, 2.5vw, 1.35rem);
    font-weight: 600;
    color: #1e293b;
    line-height: 1.3;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    max-width: min(52vw, 28rem);
}

.btn-sidebar-toggle {
    background: none;
    border: 1px solid #e2e8f0;
    border-radius: 8px;
    color: #64748b;
    line-height: 1;
    padding: 0.4rem 0.55rem;
    flex-shrink: 0;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    transition: background 0.2s;
}

.btn-sidebar-toggle i {
    font-size: 1.35rem;
}

.btn-sidebar-toggle:hover {
    background: #f1f5f9;
}

.admin-badge {
    background: linear-gradient(135deg, #0f172a, #1e3a5f);
    color: #fff;
    padding: 0.4rem 0.85rem;
    border-radius: 20px;
    font-size: 0.825rem;
    font-weight: 500;
    display: inline-flex;
    align-items: center;
    gap: 0.35rem;
    max-width: 14rem;
}

.admin-badge i {
    flex-shrink: 0;
    font-size: 1rem;
}

.admin-badge-name {
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.verified-badge {
    background: #16a34a;
    color: #fff;
    font-size: 0.7rem;
    font-weight: 600;
    padding: 0.35rem 0.55rem;
    border-radius: 999px;
    display: inline-flex;
    align-items: center;
    gap: 0.25rem;
    flex-shrink: 0;
}

.btn-logout-top {
    background: #fff;
    border: 1px solid #fecaca;
    color: #dc2626;
    border-radius: 8px;
    padding: 0.4rem 0.85rem;
    font-size: 0.825rem;
    font-weight: 500;
    display: inline-flex;
    align-items: center;
    gap: 0.35rem;
    white-space: nowrap;
    transition: background 0.2s, color 0.2s, border-color 0.2s;
}

.btn-logout-top:hover {
    background: #fef2f2;
    border-color: #f87171;
    color: #b91c1c;
}

.top-navbar-logout {
    margin: 0;
    flex-shrink: 0;
}

.sidebar-backdrop {
    display: none;
}

body.sidebar-drawer-open {
    overflow: hidden;
}

/* ── Page main area ── */
.page-main {
    padding: 2rem 1.75rem;
}

/* ══════════════════════════════════════════
   STAT CARDS
   ══════════════════════════════════════════ */

.stat-card {
    background: #fff;
    border-radius: 16px;
    padding: 1.5rem;
    display: flex;
    align-items: center;
    gap: 1.25rem;
    box-shadow: 0 2px 10px rgba(0,0,0,0.06);
    transition: transform 0.2s, box-shadow 0.2s;
}

.stat-card:hover {
    transform: translateY(-3px);
    box-shadow: 0 8px 24px rgba(0,0,0,0.1);
}

.stat-icon {
    width: 56px;
    height: 56px;
    border-radius: 14px;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
    font-size: 1.5rem;
    color: #fff;
}

.stat-card-primary .stat-icon   { background: linear-gradient(135deg, #3b82f6, #1d4ed8); }
.stat-card-success .stat-icon   { background: linear-gradient(135deg, #22c55e, #15803d); }
.stat-card-warning .stat-icon   { background: linear-gradient(135deg, #f59e0b, #d97706); }
.stat-card-danger  .stat-icon   { background: linear-gradient(135deg, #ef4444, #b91c1c); }
.stat-card-indigo  .stat-icon   { background: linear-gradient(135deg, #6366f1, #4338ca); }
.stat-card-teal    .stat-icon   { background: linear-gradient(135deg, #14b8a6, #0f766e); }
.stat-card-rose    .stat-icon   { background: linear-gradient(135deg, #f43f5e, #be123c); }

.stat-label {
    font-size: 0.8rem;
    font-weight: 600;
    color: #94a3b8;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    margin-bottom: 0.25rem;
}

.stat-value {
    font-size: 1.8rem;
    font-weight: 700;
    color: #1e293b;
    margin-bottom: 0;
    line-height: 1.1;
}

/* ══════════════════════════════════════════
   WELCOME PANEL
   ══════════════════════════════════════════ */

.welcome-panel {
    background: linear-gradient(135deg, #0f172a 0%, #1e3a5f 100%);
    border-radius: 16px;
    padding: 1.75rem 2rem;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 1rem;
    box-shadow: 0 4px 20px rgba(15, 23, 42, 0.3);
}

.welcome-content {
    display: flex;
    align-items: center;
    gap: 1.25rem;
}

.welcome-icon {
    width: 52px;
    height: 52px;
    background: rgba(249, 115, 22, 0.2);
    border-radius: 14px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #f97316;
    font-size: 1.5rem;
    flex-shrink: 0;
}

.welcome-title {
    color: #fff;
    font-weight: 700;
    margin-bottom: 0.2rem;
    font-size: 1.1rem;
}

.welcome-sub {
    color: rgba(255,255,255,0.6);
    margin-bottom: 0;
    font-size: 0.875rem;
}

.welcome-sub strong {
    color: #f97316;
}

/* ══════════════════════════════════════════
   RESPONSIVE
   ══════════════════════════════════════════ */

/* Phones + tablets: off-canvas drawer sidebar */
@media (max-width: 991.98px) {
    .sidebar-nav {
        position: fixed;
        top: 0;
        left: 0;
        bottom: 0;
        width: min(260px, 85vw);
        height: 100vh;
        height: 100dvh;
        z-index: 1050;
        margin: 0;
        transform: translate3d(-105%, 0, 0);
        transition: transform 0.3s ease;
        box-shadow: 4px 0 24px rgba(0, 0, 0, 0.28);
        overflow-y: auto;
        overflow-x: hidden;
        -webkit-overflow-scrolling: touch;
    }

    #wrapper.sidebar-open .sidebar-nav {
        transform: translate3d(0, 0, 0);
    }

    /* Desktop collapse must not shrink the drawer on small screens */
    #wrapper.sidebar-collapsed .sidebar-nav {
        width: min(260px, 85vw);
    }

    #wrapper.sidebar-collapsed .sidebar-brand > span,
    #wrapper.sidebar-collapsed .sidebar-nav .nav-link span,
    #wrapper.sidebar-collapsed .sidebar-footer .btn-logout span {
        display: inline;
    }

    .sidebar-backdrop {
        display: none;
        position: fixed;
        inset: 0;
        background: rgba(15, 23, 42, 0.5);
        z-index: 1040;
        border: 0;
        padding: 0;
        cursor: pointer;
    }

    #wrapper.sidebar-open .sidebar-backdrop {
        display: block;
    }

    .top-navbar {
        padding: 0.55rem 1rem;
    }

    .admin-badge {
        max-width: 10rem;
    }

    .top-navbar-title {
        max-width: min(40vw, 18rem);
    }
}

@media (max-width: 768px) {
    .top-navbar {
        padding: 0.5rem 0.75rem;
    }

    .top-navbar-inner {
        gap: 0.5rem;
    }

    .top-navbar-start {
        gap: 0.5rem;
    }

    .top-navbar-end {
        gap: 0.35rem;
    }

    .top-navbar-title {
        max-width: min(38vw, 12rem);
        font-size: 1rem;
    }

    .admin-badge {
        padding: 0.35rem 0.55rem;
        max-width: none;
        border-radius: 999px;
    }

    .admin-badge-name,
    .verified-label,
    .logout-label {
        display: none;
    }

    .verified-badge {
        padding: 0.35rem 0.45rem;
    }

    .btn-logout-top {
        padding: 0.4rem 0.55rem;
    }

    .page-main {
        padding: 1.25rem 1rem;
    }

    .welcome-panel {
        flex-direction: column;
        align-items: flex-start;
    }

    .stat-card {
        padding: 1.25rem;
    }
}

@media (max-width: 480px) {
    .top-navbar-title {
        max-width: min(42vw, 9.5rem);
        font-size: 0.95rem;
    }

    .page-main {
        padding: 1rem 0.75rem;
    }
}

/* ══════════════════════════════════════════
   SHOWROOM BIKE LIST
   ══════════════════════════════════════════ */

.bike-page {
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

.bike-page-header {
    display: flex;
    align-items: flex-end;
    justify-content: space-between;
    gap: 1rem;
}

.bike-page-subtitle {
    margin: 0;
    font-size: 0.95rem;
    font-weight: 600;
    color: #334155;
}

.bike-page-count {
    margin: 0.2rem 0 0;
    font-size: 0.8rem;
    color: #94a3b8;
}

.bike-filter-bar {
    min-height: 64px;
    background: #fff;
    border: 1px solid #e2e8f0;
    border-radius: 14px;
    padding: 0.75rem 1rem;
    display: flex;
    align-items: center;
    gap: 0.75rem;
    flex-wrap: wrap;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.04);
}

.bike-search {
    position: relative;
    display: block;
    width: 100%;
    max-width: 520px;
    margin: 0;
}

.bike-search-icon {
    position: absolute;
    left: 0.9rem;
    top: 50%;
    transform: translateY(-50%);
    color: #94a3b8;
    font-size: 0.95rem;
    pointer-events: none;
}

.bike-search-input {
    width: 100%;
    height: 42px;
    border: 1px solid #e2e8f0;
    border-radius: 10px;
    padding: 0 2.5rem;
    font-size: 0.9rem;
    color: #334155;
    background: #f8fafc;
    outline: none;
}

.bike-search-input::placeholder {
    color: #94a3b8;
}

.bike-search-input:focus {
    border-color: #22c55e;
    background: #fff;
    box-shadow: 0 0 0 3px rgba(34, 197, 94, 0.12);
}

.bike-search-input::-webkit-search-cancel-button {
    display: none;
}

.bike-search-clear {
    position: absolute;
    right: 0.35rem;
    top: 50%;
    transform: translateY(-50%);
    width: 28px;
    height: 28px;
    border: 0;
    border-radius: 8px;
    background: transparent;
    color: #94a3b8;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 0;
}

.bike-search-clear[hidden] {
    display: none;
}

.bike-search-clear:hover {
    background: #e2e8f0;
    color: #475569;
}

.bike-filter-reset {
    height: 42px;
    padding: 0 1rem;
    border: 1px solid #16a34a;
    border-radius: 10px;
    background: #22c55e;
    color: #fff;
    font-size: 0.9rem;
    font-weight: 600;
    flex: 0 0 auto;
    cursor: pointer;
}

.bike-filter-reset:hover:not(:disabled) {
    background: #16a34a;
    border-color: #15803d;
    color: #fff;
}

.bike-filter-reset:disabled {
    opacity: 0.55;
    cursor: not-allowed;
}

.bike-brand-filter {
    position: relative;
    display: block;
    flex: 0 1 240px;
    min-width: 180px;
    margin: 0;
}

.bike-status-filter {
    flex-basis: 170px;
    min-width: 150px;
}

.bike-brand-icon,
.bike-brand-chevron {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    color: #94a3b8;
    pointer-events: none;
}

.bike-brand-icon {
    left: 0.85rem;
    font-size: 0.95rem;
}

.bike-brand-chevron {
    right: 0.8rem;
    font-size: 0.75rem;
}

.bike-brand-select {
    width: 100%;
    height: 42px;
    border: 1px solid #e2e8f0;
    border-radius: 10px;
    padding: 0 2rem 0 2.35rem;
    font-size: 0.9rem;
    color: #334155;
    background: #f8fafc;
    appearance: none;
    outline: none;
    cursor: pointer;
}

.bike-brand-select:focus {
    border-color: #22c55e;
    background: #fff;
    box-shadow: 0 0 0 3px rgba(34, 197, 94, 0.12);
}

.bike-list-item[hidden] {
    display: none;
}

.bike-list-head.bike-list-head-hidden {
    display: none !important;
}

.bike-pagination {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 0.75rem 1rem;
    padding: 0.85rem 1.25rem;
    border-top: 1px solid #e2e8f0;
    background: #fff;
    flex-wrap: wrap;
}

.bike-pagination[hidden] {
    display: none;
}

.bike-pagination-meta {
    display: flex;
    align-items: center;
    gap: 0.85rem;
    flex-wrap: wrap;
}

.bike-pagination-summary {
    margin: 0;
    font-size: 0.82rem;
    color: #64748b;
}

.bike-pagination-controls {
    display: flex;
    align-items: center;
    gap: 0.35rem;
    flex-wrap: wrap;
}

.bike-page-btn {
    min-width: 36px;
    height: 36px;
    padding: 0 0.7rem;
    border: 1px solid #e2e8f0;
    border-radius: 8px;
    background: #fff;
    color: #334155;
    font-size: 0.85rem;
    font-weight: 600;
    cursor: pointer;
}

.bike-page-btn:hover:not(:disabled):not(.is-active) {
    border-color: #bbf7d0;
    background: #f0fdf4;
    color: #166534;
}

.bike-page-btn.is-active {
    background: #22c55e;
    border-color: #16a34a;
    color: #fff;
}

.bike-page-btn:disabled {
    opacity: 0.45;
    cursor: not-allowed;
}

.bike-page-gap {
    min-width: 1.25rem;
    text-align: center;
    color: #94a3b8;
}

.bike-page-size-label {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    margin: 0;
    font-size: 0.82rem;
    font-weight: 600;
    color: #64748b;
}

.bike-page-size-select-wrap {
    position: relative;
    display: inline-flex;
}

.bike-page-size-select {
    height: 36px;
    min-width: 78px;
    border: 1px solid #e2e8f0;
    border-radius: 8px;
    padding: 0 1.7rem 0 0.7rem;
    background: #f8fafc;
    color: #334155;
    font-size: 0.85rem;
    font-weight: 600;
    appearance: none;
    outline: none;
    cursor: pointer;
}

.bike-page-size-select:focus {
    border-color: #22c55e;
    background: #fff;
    box-shadow: 0 0 0 3px rgba(34, 197, 94, 0.12);
}

.bike-page-size-chevron {
    position: absolute;
    right: 0.55rem;
    top: 50%;
    transform: translateY(-50%);
    font-size: 0.7rem;
    color: #94a3b8;
    pointer-events: none;
}

.bike-list-panel {
    background: #fff;
    border-radius: 16px;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.05);
    overflow: hidden;
}

.bike-list-empty {
    text-align: center;
    padding: 3.5rem 1.5rem;
    color: #94a3b8;
}

.bike-list-empty i {
    font-size: 2.5rem;
    color: #cbd5e1;
    display: block;
    margin-bottom: 0.75rem;
}

.bike-list-empty h3 {
    margin: 0 0 0.35rem;
    font-size: 1.1rem;
    color: #475569;
}

.bike-list-empty p {
    margin: 0;
    font-size: 0.9rem;
}

.bike-list-head {
    display: grid;
    grid-template-columns: minmax(180px, 2fr) 0.75fr 0.7fr 0.9fr 0.7fr 0.55fr 0.75fr 96px;
    gap: 0.75rem;
    padding: 0.75rem 1.25rem;
    background: #f8fafc;
    border-bottom: 1px solid #e2e8f0;
    font-size: 0.72rem;
    font-weight: 700;
    letter-spacing: 0.04em;
    text-transform: uppercase;
    color: #94a3b8;
}

.bike-list {
    list-style: none;
    margin: 0;
    padding: 0;
}

.bike-list-item {
    border-bottom: 1px solid #f1f5f9;
    transition: background 0.15s ease;
}

.bike-list-item:last-child {
    border-bottom: none;
}

.bike-list-item:hover {
    background: #f8fafc;
}

.bike-list-row {
    display: grid;
    grid-template-columns: minmax(180px, 2fr) 0.75fr 0.7fr 0.9fr 0.7fr 0.55fr 0.75fr 96px;
    gap: 0.75rem;
    align-items: center;
    padding: 0.95rem 1.25rem;
}

.bike-col-active {
    min-width: 0;
}

.bike-col-identity {
    display: flex;
    align-items: center;
    gap: 0.85rem;
    min-width: 0;
}

.bike-thumb {
    width: 52px;
    height: 52px;
    border-radius: 12px;
    overflow: hidden;
    background: #f1f5f9;
    flex-shrink: 0;
    display: flex;
    align-items: center;
    justify-content: center;
}

.bike-thumb img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.bike-thumb-empty {
    color: #94a3b8;
    font-size: 1.35rem;
}

.bike-identity-text {
    min-width: 0;
}

.bike-model-name {
    margin: 0;
    font-size: 0.95rem;
    font-weight: 700;
    color: #0f172a;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.bike-meta {
    margin: 0.2rem 0 0;
    display: flex;
    flex-wrap: wrap;
    gap: 0.35rem 0.55rem;
    font-size: 0.75rem;
    color: #64748b;
}

.bike-meta span:not(:last-child)::after {
    content: "·";
    margin-left: 0.55rem;
    color: #cbd5e1;
}

.bike-uid {
    font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
    color: #94a3b8;
}

.bike-col-value {
    display: block;
    font-size: 0.875rem;
    font-weight: 600;
    color: #334155;
}

.bike-col-sub {
    display: block;
    margin-top: 0.15rem;
    font-size: 0.72rem;
    color: #94a3b8;
}

.bike-offer {
    color: #ea580c;
    font-weight: 600;
}

.bike-col-muted {
    color: #cbd5e1;
    font-size: 0.875rem;
}

.bike-stock-badge {
    display: inline-flex;
    align-items: center;
    padding: 0.28rem 0.65rem;
    border-radius: 999px;
    font-size: 0.72rem;
    font-weight: 700;
    letter-spacing: 0.02em;
}

.bike-stock-in {
    background: #dcfce7;
    color: #15803d;
}

.bike-stock-out {
    background: #fee2e2;
    color: #b91c1c;
}

.bike-stock-unknown {
    background: #f1f5f9;
    color: #64748b;
}

.bike-color-dots {
    display: flex;
    align-items: center;
    gap: 0.35rem;
    flex-wrap: wrap;
}

.bike-color-dot {
    width: 16px;
    height: 16px;
    border-radius: 50%;
    border: 2px solid #fff;
    box-shadow: 0 0 0 1px #e2e8f0;
}

.bike-color-more {
    font-size: 0.72rem;
    font-weight: 700;
    color: #64748b;
}

.bike-col-actions {
    display: flex;
    justify-content: flex-end;
    align-items: center;
    gap: 0.4rem;
    flex-shrink: 0;
    white-space: nowrap;
    min-width: 0;
}

.bike-action-btn {
    width: 36px;
    height: 36px;
    border-radius: 10px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    text-decoration: none;
    border: 1px solid transparent;
    transition: background 0.15s, color 0.15s, border-color 0.15s;
}

.bike-action-edit {
    color: #2563eb;
    background: #eff6ff;
    border-color: #bfdbfe;
}

.bike-action-edit:hover {
    background: #dbeafe;
    color: #1d4ed8;
}

.bike-action-delete {
    color: #dc2626;
    background: #fef2f2;
    border-color: #fecaca;
}

.bike-action-delete:hover {
    background: #fee2e2;
    color: #b91c1c;
}

@media (max-width: 991.98px) {
    .bike-list-row {
        grid-template-columns: 1fr 1fr;
        gap: 0.85rem 1rem;
    }

    .bike-col-identity {
        grid-column: 1 / -1;
    }

    .bike-col-actions {
        grid-column: 1 / -1;
        justify-content: flex-start;
        padding-top: 0.25rem;
        border-top: 1px dashed #e2e8f0;
    }

    .bike-col[data-label]::before {
        content: attr(data-label);
        display: block;
        margin-bottom: 0.2rem;
        font-size: 0.68rem;
        font-weight: 700;
        letter-spacing: 0.04em;
        text-transform: uppercase;
        color: #94a3b8;
    }
}

@media (max-width: 575.98px) {
    .bike-list-row {
        grid-template-columns: 1fr 1fr;
        padding: 1rem;
        gap: 0.85rem 1.25rem;
    }

    .bike-col-identity {
        grid-column: 1 / -1;
    }

    .bike-col-actions {
        grid-column: 1 / -1;
        justify-content: flex-end;
    }

    .bike-filter-bar {
        min-height: 56px;
        padding: 0.75rem;
        align-items: stretch;
        flex-direction: column;
    }

    .bike-search,
    .bike-brand-filter {
        max-width: none;
        flex: 1 1 auto;
        width: 100%;
    }

    .bike-pagination {
        flex-direction: column;
        align-items: flex-start;
        padding: 0.85rem 1rem;
    }
}

/* ══════════════════════════════════════════
   EDIT BIKE FORM
   ══════════════════════════════════════════ */

.edit-bike-page {
    display: flex;
    flex-direction: column;
    gap: 1.25rem;
    padding-bottom: 5rem;
}

.edit-bike-top {
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
}

.edit-bike-back {
    display: inline-flex;
    align-items: center;
    gap: 0.4rem;
    width: fit-content;
    color: #64748b;
    text-decoration: none;
    font-size: 0.875rem;
    font-weight: 600;
}

.edit-bike-back:hover {
    color: #0f172a;
}

.edit-bike-heading h2 {
    margin: 0;
    font-size: 1.45rem;
    font-weight: 700;
    color: #0f172a;
}

.edit-bike-heading p {
    margin: 0.25rem 0 0;
    font-size: 0.875rem;
    color: #94a3b8;
}

.edit-bike-empty {
    background: #fff;
    border-radius: 16px;
    padding: 3rem 1.5rem;
    text-align: center;
    color: #94a3b8;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.05);
}

.edit-bike-empty i {
    font-size: 2rem;
    display: block;
    margin-bottom: 0.75rem;
    color: #cbd5e1;
}

.edit-bike-empty h3 {
    margin: 0 0 0.35rem;
    color: #475569;
    font-size: 1.1rem;
}

.edit-bike-form {
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

.edit-bike-alert {
    margin: 0;
    border-radius: 12px;
}

.edit-section {
    background: #fff;
    border-radius: 16px;
    padding: 1.25rem 1.35rem 1.4rem;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.05);
}

.edit-section-head {
    display: flex;
    align-items: center;
    gap: 0.55rem;
    margin-bottom: 1.1rem;
    padding-bottom: 0.75rem;
    border-bottom: 1px solid #f1f5f9;
}

.edit-section-head i {
    color: #f97316;
    font-size: 1.1rem;
}

.edit-section-head h3 {
    margin: 0;
    font-size: 1rem;
    font-weight: 700;
    color: #1e293b;
}

.edit-color-bulk {
    margin-left: auto;
    display: inline-flex;
    align-items: center;
    gap: 0.4rem;
}

.edit-color-bulk .btn-link {
    color: #ea580c;
    font-weight: 600;
    text-decoration: none;
}

.edit-color-bulk .btn-link:hover {
    color: #c2410c;
    text-decoration: underline;
}

.edit-color-bulk-sep {
    color: #cbd5e1;
}

.edit-grid {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 1rem 1.1rem;
}

.edit-field {
    display: flex;
    flex-direction: column;
    gap: 0.35rem;
    min-width: 0;
}

.edit-field-inline {
    flex-direction: row;
    align-items: center;
    gap: 0.75rem;
}

.edit-field-inline label {
    white-space: nowrap;
}

.edit-field-inline .form-control {
    flex: 1;
    min-width: 0;
}

.edit-field label {
    margin: 0;
    font-size: 0.75rem;
    font-weight: 700;
    letter-spacing: 0.02em;
    text-transform: uppercase;
    color: #64748b;
}

.edit-field .form-control,
.edit-field .form-select {
    border-radius: 10px;
    border-color: #e2e8f0;
    font-size: 0.9rem;
    padding: 0.55rem 0.75rem;
    color: #0f172a;
    background-color: #fff;
}

.edit-field .form-select {
    padding-right: 2.25rem;
    background-image: var(--bs-form-select-bg-img);
    background-repeat: no-repeat;
    background-position: right 0.75rem center;
    background-size: 16px 12px;
}

.edit-field .form-control:focus,
.edit-field .form-select:focus {
    border-color: #fb923c;
    box-shadow: 0 0 0 0.2rem rgba(249, 115, 22, 0.15);
}

.edit-muted {
    margin: 0;
    color: #94a3b8;
    font-size: 0.9rem;
}

.edit-color-list {
    display: flex;
    flex-wrap: wrap;
    gap: 0.6rem;
}

.edit-color-picker {
    display: flex;
    flex-wrap: wrap;
    gap: 0.65rem;
}

.edit-color-option {
    position: relative;
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    margin: 0;
    padding: 0.45rem 0.85rem 0.45rem 0.55rem;
    border-radius: 999px;
    background: #f8fafc;
    border: 1.5px solid #e2e8f0;
    font-size: 0.85rem;
    font-weight: 600;
    color: #475569;
    cursor: pointer;
    user-select: none;
    transition: border-color 0.15s, background 0.15s, color 0.15s, box-shadow 0.15s;
}

.edit-color-option input.edit-color-checkbox {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    margin: 0;
    opacity: 0;
    cursor: pointer;
    z-index: 1;
}

.edit-color-option:hover {
    border-color: #cbd5e1;
    background: #fff;
}

.edit-color-option.is-selected {
    background: #fff7ed;
    border-color: #fb923c;
    color: #9a3412;
    box-shadow: 0 0 0 3px rgba(249, 115, 22, 0.12);
}

.edit-color-name {
    line-height: 1.2;
    position: relative;
    z-index: 0;
}

.edit-color-check {
    display: none;
    font-size: 0.85rem;
    color: #ea580c;
    position: relative;
    z-index: 0;
}

.edit-color-option.is-selected .edit-color-check {
    display: inline-flex;
}

.edit-color-chip {
    display: inline-flex;
    align-items: center;
    gap: 0.45rem;
    padding: 0.4rem 0.7rem;
    border-radius: 999px;
    background: #f8fafc;
    border: 1px solid #e2e8f0;
    font-size: 0.8rem;
    color: #475569;
    font-weight: 600;
}

.edit-color-swatch {
    width: 16px;
    height: 16px;
    border-radius: 50%;
    border: 2px solid #fff;
    box-shadow: 0 0 0 1px #e2e8f0;
    flex-shrink: 0;
}

.edit-image-grid {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 0.85rem;
}

.edit-image-card {
    position: relative;
    aspect-ratio: 4 / 3;
    border-radius: 12px;
    overflow: hidden;
    background: #f1f5f9;
    border: 1px solid #e2e8f0;
}

.edit-image-card img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
}

.edit-image-remove {
    position: absolute;
    top: 0.4rem;
    right: 0.4rem;
    z-index: 2;
    width: 1.75rem;
    height: 1.75rem;
    border: none;
    border-radius: 999px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    background: rgba(15, 23, 42, 0.72);
    color: #fff;
    line-height: 1;
    padding: 0;
    cursor: pointer;
    transition: background 0.15s ease, transform 0.15s ease;
}

.edit-image-remove:hover {
    background: #dc2626;
    color: #fff;
    transform: scale(1.05);
}

.edit-image-remove i {
    font-size: 1rem;
}

.edit-image-upload-card {
    position: relative;
    aspect-ratio: 4 / 3;
    border-radius: 12px;
    border: 1.5px dashed #cbd5e1;
    background: #f8fafc;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: border-color 0.15s ease, background 0.15s ease;
}

.edit-image-upload-card:hover {
    border-color: #f97316;
    background: #fff7ed;
}

.edit-image-file-input {
    position: absolute;
    inset: 0;
    opacity: 0;
    cursor: pointer;
}

.edit-image-upload-inner {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 0.2rem;
    text-align: center;
    color: #64748b;
    padding: 0.75rem;
    pointer-events: none;
}

.edit-image-upload-inner i {
    font-size: 1.5rem;
    color: #f97316;
}

.edit-image-upload-inner strong {
    font-size: 0.85rem;
    color: #334155;
}

.edit-image-upload-inner small {
    font-size: 0.72rem;
    color: #94a3b8;
}

.edit-image-preview-wrap {
    margin-top: 1rem;
}

.edit-image-preview-label {
    margin: 0 0 0.65rem;
    font-size: 0.8rem;
    font-weight: 600;
    color: #64748b;
}

.edit-image-preview-badge {
    position: absolute;
    top: 0.4rem;
    left: 0.4rem;
    z-index: 2;
    background: #f97316;
    color: #fff;
    font-size: 0.65rem;
    font-weight: 700;
    letter-spacing: 0.02em;
    padding: 0.2rem 0.45rem;
    border-radius: 999px;
}

.edit-bike-actions {
    position: sticky;
    bottom: 0.75rem;
    z-index: 20;
    display: flex;
    justify-content: flex-end;
    gap: 0.65rem;
    padding: 0.85rem 1rem;
    background: rgba(255, 255, 255, 0.92);
    backdrop-filter: blur(8px);
    border: 1px solid #e2e8f0;
    border-radius: 14px;
    box-shadow: 0 8px 24px rgba(15, 23, 42, 0.08);
}

.btn-edit-cancel {
    border: 1px solid #e2e8f0;
    background: #fff;
    color: #475569;
    font-weight: 600;
    border-radius: 10px;
    padding: 0.55rem 1.1rem;
}

.btn-edit-cancel:hover {
    background: #f8fafc;
    color: #0f172a;
}

.btn-edit-update {
    display: inline-flex;
    align-items: center;
    gap: 0.4rem;
    border: none;
    background: linear-gradient(135deg, #f97316, #ea580c);
    color: #fff;
    font-weight: 700;
    border-radius: 10px;
    padding: 0.55rem 1.25rem;
}

.btn-edit-update:hover {
    background: linear-gradient(135deg, #ea580c, #c2410c);
    color: #fff;
}

@media (max-width: 991.98px) {
    .edit-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    .edit-image-grid {
        grid-template-columns: repeat(3, minmax(0, 1fr));
    }
}

@media (max-width: 575.98px) {
    .edit-section {
        padding: 1rem;
        border-radius: 14px;
    }

    .edit-grid {
        grid-template-columns: 1fr;
        gap: 0.85rem;
    }

    .edit-image-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    .edit-bike-actions {
        left: 0;
        right: 0;
        bottom: 0;
        border-radius: 14px 14px 0 0;
        justify-content: stretch;
    }

    .btn-edit-cancel,
    .btn-edit-update {
        flex: 1;
        justify-content: center;
    }

    .edit-bike-heading h2 {
        font-size: 1.25rem;
    }
}

/* ══════════════════════════════════════════
   BRANDS LIST
   ══════════════════════════════════════════ */

.brand-page {
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

.brand-page-header {
    display: flex;
    align-items: flex-end;
    justify-content: space-between;
    gap: 1rem;
    flex-wrap: wrap;
}

.brand-status-filter {
    position: relative;
    display: block;
    flex: 0 1 190px;
    min-width: 160px;
    margin: 0 0 0 auto;
}

.brand-status-icon,
.brand-status-chevron {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    color: #94a3b8;
    pointer-events: none;
}

.brand-status-icon {
    left: 0.85rem;
    font-size: 0.95rem;
}

.brand-status-chevron {
    right: 0.8rem;
    font-size: 0.75rem;
}

.brand-status-select {
    width: 100%;
    height: 42px;
    border: 1px solid #e2e8f0;
    border-radius: 10px;
    padding: 0 2rem 0 2.35rem;
    font-size: 0.9rem;
    color: #334155;
    background: #fff;
    appearance: none;
    outline: none;
    cursor: pointer;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.04);
}

.brand-status-select:focus {
    border-color: #22c55e;
    box-shadow: 0 0 0 3px rgba(34, 197, 94, 0.12);
}

.brand-list-item[hidden] {
    display: none;
}

.brand-list-head.brand-list-head-hidden {
    display: none !important;
}

.brand-page-subtitle {
    margin: 0;
    font-size: 0.95rem;
    font-weight: 600;
    color: #334155;
}

.brand-page-count {
    margin: 0.2rem 0 0;
    font-size: 0.8rem;
    color: #94a3b8;
}

.brand-list-panel {
    background: #fff;
    border-radius: 16px;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.05);
    overflow: hidden;
}

.brand-list-empty {
    text-align: center;
    padding: 3.5rem 1.5rem;
    color: #94a3b8;
}

.brand-list-empty i {
    font-size: 2.5rem;
    color: #cbd5e1;
    display: block;
    margin-bottom: 0.75rem;
}

.brand-list-empty h3 {
    margin: 0 0 0.35rem;
    font-size: 1.1rem;
    color: #475569;
}

.brand-list-empty p {
    margin: 0;
    font-size: 0.9rem;
}

.brand-list-head {
    display: grid;
    grid-template-columns: minmax(160px, 1.4fr) 1fr 1fr 140px;
    gap: 0.75rem;
    padding: 0.75rem 1.25rem;
    background: #f8fafc;
    border-bottom: 1px solid #e2e8f0;
    font-size: 0.72rem;
    font-weight: 700;
    letter-spacing: 0.04em;
    text-transform: uppercase;
    color: #94a3b8;
}

.brand-list {
    list-style: none;
    margin: 0;
    padding: 0;
}

.brand-list-item {
    border-bottom: 1px solid #f1f5f9;
}

.brand-list-item:last-child {
    border-bottom: 0;
}

.brand-list-item:hover {
    background: #f8fafc;
}

.brand-list-row {
    display: grid;
    grid-template-columns: minmax(160px, 1.4fr) 1fr 1fr 140px;
    gap: 0.75rem;
    align-items: center;
    padding: 0.95rem 1.25rem;
}

.brand-name {
    display: block;
    font-size: 0.95rem;
    font-weight: 700;
    color: #0f172a;
}

.brand-id-sub,
.brand-col-value {
    display: block;
    font-size: 0.8rem;
    color: #64748b;
}

.brand-id-sub {
    margin-top: 0.15rem;
}

.brand-col-active {
    display: flex;
    justify-content: flex-end;
}

.brand-switch {
    display: inline-flex;
    align-items: center;
    gap: 0.55rem;
    margin: 0;
    cursor: pointer;
    user-select: none;
}

.brand-switch-input {
    position: absolute;
    opacity: 0;
    width: 0;
    height: 0;
}

.brand-switch-slider {
    position: relative;
    width: 42px;
    height: 24px;
    border-radius: 999px;
    background: #cbd5e1;
    transition: background 0.15s ease;
    flex: 0 0 auto;
}

.brand-switch-slider::after {
    content: "";
    position: absolute;
    top: 3px;
    left: 3px;
    width: 18px;
    height: 18px;
    border-radius: 50%;
    background: #fff;
    box-shadow: 0 1px 3px rgba(15, 23, 42, 0.2);
    transition: transform 0.15s ease;
}

.brand-switch-input:checked + .brand-switch-slider {
    background: #22c55e;
}

.brand-switch-input:checked + .brand-switch-slider::after {
    transform: translateX(18px);
}

.brand-switch-input:disabled + .brand-switch-slider {
    opacity: 0.6;
}

.brand-switch-text {
    font-size: 0.8rem;
    font-weight: 600;
    color: #475569;
    min-width: 3.5rem;
}

@media (max-width: 767.98px) {
    .brand-list-row {
        grid-template-columns: 1fr 1fr;
        gap: 0.75rem 1rem;
    }

    .brand-col-name {
        grid-column: 1 / -1;
    }

    .brand-col-active {
        grid-column: 1 / -1;
        justify-content: flex-start;
        padding-top: 0.25rem;
        border-top: 1px dashed #e2e8f0;
    }

    .brand-col[data-label]::before {
        content: attr(data-label);
        display: block;
        margin-bottom: 0.2rem;
        font-size: 0.68rem;
        font-weight: 700;
        letter-spacing: 0.04em;
        text-transform: uppercase;
        color: #94a3b8;
    }
}
