/* ============================================================
   InfoStack — Main Stylesheet
   ============================================================ */

:root {
    --bg-dark:       #0f1117;
    --bg-sidebar:    #161b25;
    --bg-card:       #1c2333;
    --bg-input:      #242b3d;
    --accent:        #c0392b;
    --accent-light:  #e74c3c;
    --accent-glow:   rgba(192,57,43,0.15);
    --text-white:    #f0f4ff;
    --text-light:    #a8b2d8;
    --text-muted:    #5a6480;
    --border:        rgba(255,255,255,0.07);
    --border-light:  rgba(255,255,255,0.12);
    --green:  #27ae60;
    --yellow: #f39c12;
    --blue:   #2980b9;
    --font-head: 'Syne', sans-serif;
    --font-body: 'DM Sans', sans-serif;
    --radius:    10px;
    --radius-lg: 16px;
    --sidebar-w: 240px;
    --transition: all 0.25s ease;
}

* { margin:0; padding:0; box-sizing:border-box; }

body {
    font-family: var(--font-body);
    background: var(--bg-dark);
    color: var(--text-white);
    font-size: 14px;
    line-height: 1.6;
    min-height: 100vh;
}

a { text-decoration:none; color:inherit; }
ul { list-style:none; }

/* Layout */
.app-wrapper { display:flex; min-height:100vh; }

/* Global Mobile Overflow Fix */
* {
    box-sizing: border-box;
}

body, html {
    overflow-x: hidden;           /* Important */
    max-width: 100%;
}

.app-wrapper {
    max-width: 100%;
    overflow-x: hidden;
}

.main-content {
    width: 100%;
    max-width: 100%;
    padding: 16px 14px;
    overflow-x: hidden;
}

/* ============================================================
   Sidebar
   ============================================================ */
.sidebar {
    width: var(--sidebar-w);
    background: var(--bg-sidebar);
    border-right: 1px solid var(--border);
    display: flex;
    flex-direction: column;
    position: fixed;
    top:0; left:0;
    height: 100vh;
    overflow-y: auto;
    z-index: 200;
    transition: transform 0.3s ease;
}

.sidebar-close {
    display: none;
    position: absolute;
    top:14px; right:14px;
    background: none; border: none;
    color: var(--text-light);
    font-size: 20px; cursor: pointer;
}

.sidebar-logo {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 22px 20px;
    border-bottom: 1px solid var(--border);
    flex-shrink: 0;
}

.logo-icon {
    width:36px; height:36px;
    background: var(--accent);
    border-radius: 8px;
    display:flex; align-items:center; justify-content:center;
    font-family: var(--font-head);
    font-weight:800; font-size:13px; color:#fff;
    flex-shrink:0;
}

.logo-text { font-family:var(--font-head); font-size:17px; }
.logo-text strong { color:var(--accent-light); }

.sidebar-nav { padding:14px 12px; flex:1; }

.nav-label {
    font-size:10px; font-weight:700;
    letter-spacing:1.5px; text-transform:uppercase;
    color:var(--text-muted);
    padding:14px 10px 6px;
}

.nav-item {
    display:flex; align-items:center; gap:10px;
    padding:10px 12px;
    border-radius:var(--radius);
    color:var(--text-light);
    font-size:13.5px; font-weight:500;
    transition:var(--transition);
    margin-bottom:2px;
}

.nav-item:hover { background:var(--bg-card); color:var(--text-white); }
.nav-item.active { background:var(--accent-glow); color:var(--accent-light); border:1px solid rgba(192,57,43,0.25); }
.nav-item i { font-size:17px; flex-shrink:0; }

.badge { margin-left:auto; background:var(--accent); color:#fff; font-size:10px; font-weight:700; padding:2px 7px; border-radius:20px; }

.sidebar-user { padding:14px 16px; border-top:1px solid var(--border); flex-shrink:0; }
.plan-badge { display:inline-block; font-size:10px; color:var(--accent-light); font-weight:600; margin-bottom:10px; }
.user-row { display:flex; align-items:center; gap:10px; }
.user-avatar { width:34px; height:34px; background:var(--accent); border-radius:50%; display:flex; align-items:center; justify-content:center; font-size:12px; font-weight:700; color:#fff; flex-shrink:0; }
.user-info { display:flex; flex-direction:column; flex:1; min-width:0; }
.user-name { font-size:13px; font-weight:600; white-space:nowrap; overflow:hidden; text-overflow:ellipsis; }
.user-role { font-size:11px; color:var(--text-muted); }
.logout-icon { font-size:16px; color:var(--text-muted); cursor:pointer; transition:var(--transition); }
.logout-icon:hover { color:var(--accent-light); }

/* Mobile topbar */
.mobile-topbar { display:none; align-items:center; justify-content:space-between; padding:14px 16px; background:var(--bg-sidebar); border-bottom:1px solid var(--border); position:sticky; top:0; z-index:100; }
.hamburger { background:none; border:none; color:var(--text-white); font-size:22px; cursor:pointer; }
.sidebar-overlay { display:none; position:fixed; inset:0; background:rgba(0,0,0,0.6); z-index:150; }
.sidebar-overlay.open { display:block; }

/* Main content */
.main-content { margin-left:var(--sidebar-w); flex:1; padding:28px 30px; min-height:100vh; }

/* Top bar */
.top-bar { display:flex; justify-content:space-between; align-items:center; margin-bottom:20px; flex-wrap:wrap; gap:14px; }
.top-bar-left h1 { font-family:var(--font-head); font-size:22px; font-weight:700; }
.top-bar-left p { font-size:13px; color:var(--text-muted); }
.top-bar-right { display:flex; align-items:center; gap:10px; }

.search-bar { display:flex; align-items:center; gap:8px; background:var(--bg-card); border:1px solid var(--border); border-radius:var(--radius); padding:8px 14px; width:200px; }
.search-bar input { background:none; border:none; outline:none; color:var(--text-white); font-size:13px; font-family:var(--font-body); width:100%; }
.search-bar input::placeholder { color:var(--text-muted); }
.search-bar i { color:var(--text-muted); font-size:15px; }

/* Buttons */
.btn { display:inline-flex; align-items:center; gap:6px; padding:9px 18px; border-radius:var(--radius); font-size:13px; font-weight:600; cursor:pointer; border:none; font-family:var(--font-body); transition:var(--transition); text-decoration:none; }
.btn-primary { background:var(--accent); color:#fff; }
.btn-primary:hover { background:var(--accent-light); }
.btn-outline { background:transparent; color:var(--text-light); border:1px solid var(--border-light); }
.btn-outline:hover { background:var(--bg-card); color:var(--text-white); }
.btn-sm { padding:6px 12px; font-size:12px; }
.btn-full { width:100%; justify-content:center; background:var(--accent); color:#fff; border:none; border-radius:var(--radius); padding:13px; font-size:15px; font-weight:600; font-family:var(--font-body); cursor:pointer; margin-top:6px; transition:background 0.2s; }
.btn-full:hover { background:var(--accent-light); }

/* Cards */
.card { background:var(--bg-card); border:1px solid var(--border); border-radius:var(--radius-lg); padding:22px; }
.card-header { display:flex; justify-content:space-between; align-items:flex-start; margin-bottom:18px; flex-wrap:wrap; gap:10px; }
.card-header h3 { font-family:var(--font-head); font-size:15px; font-weight:700; }
.card-header p { font-size:12px; color:var(--text-muted); margin-top:2px; }

/* Stat cards */
.stats-grid { display:grid; grid-template-columns:repeat(4,1fr); gap:16px; margin-bottom:24px;margin-top:24px; }
.stat-card { background:var(--bg-card); border:1px solid var(--border); border-radius:var(--radius-lg); padding:20px; transition:var(--transition);box-shadow:0 1px 12px hsl(249, 56%, 84%); }
.stat-card:hover { border-color:var(--border-light); }
.stat-top { display:flex; justify-content:space-between; align-items:center; margin-bottom:12px; }
.stat-label { font-size:11px; font-weight:700; letter-spacing:1px; text-transform:uppercase; color:var(--text-muted); }
.stat-icon { width:36px; height:36px; border-radius:8px; display:flex; align-items:center; justify-content:center; font-size:17px; }
.stat-icon.red    { background:rgba(192,57,43,0.15); color:var(--accent-light); }
.stat-icon.yellow { background:rgba(243,156,18,0.15); color:var(--yellow); }
.stat-icon.green  { background:rgba(39,174,96,0.15);  color:var(--green); }
.stat-icon.blue   { background:rgba(41,128,185,0.15); color:var(--blue); }
.stat-value { font-family:var(--font-head); font-size:26px; font-weight:700; margin-bottom:5px; }
.stat-sub { font-size:12px; color:var(--text-muted); }
.stat-sub .down { color:var(--accent-light); font-weight:600; }

/* Dashboard grids */
.dashboard-grid { display:grid; grid-template-columns:2fr 1fr; gap:20px; margin-bottom:20px; }
.bottom-grid    { display:grid; grid-template-columns:1.4fr 1fr 1fr; gap:20px; }

/* Mini table */
.mini-table { width:100%; border-collapse:collapse; }
.mini-table thead th { font-size:10px; font-weight:700; letter-spacing:1px; text-transform:uppercase; color:var(--text-muted); padding:0 0 10px; text-align:left; border-bottom:1px solid var(--border); }
.mini-table tbody td { padding:10px 0; font-size:13px; color:var(--text-light); border-bottom:1px solid var(--border); vertical-align:middle; }
.mini-table tbody tr:last-child td { border-bottom:none; }
.proj-name   { font-weight:600; color:var(--text-white); font-size:13px; }
.client-name { font-size:11px; color:var(--text-muted); }
.empty-cell  { text-align:center; color:var(--text-muted); padding:20px 0; font-size:13px; }
.empty-cell a { color:var(--accent-light); }

/* Status badges */
.status-badge { display:inline-block; padding:3px 10px; border-radius:20px; font-size:11px; font-weight:600; }
.status-badge.active  { background:rgba(41,128,185,0.15);  color:#5dade2; }
.status-badge.done    { background:rgba(39,174,96,0.15);   color:var(--green); }
.status-badge.review  { background:rgba(243,156,18,0.15);  color:var(--yellow); }
.status-badge.overdue { background:rgba(192,57,43,0.15);   color:var(--accent-light); }
.status-badge.pending { background:rgba(243,156,18,0.15);  color:var(--yellow); }
.status-badge.paid    { background:rgba(39,174,96,0.15);   color:var(--green); }
.status-badge.hold    { background:rgba(90,100,128,0.2);   color:var(--text-muted); }

/* Tasks */
.task-item { display:flex; align-items:flex-start; gap:10px; padding:10px 0; border-bottom:1px solid var(--border); }
.task-item:last-child { border-bottom:none; }
.task-check { width:18px; height:18px; border-radius:4px; border:2px solid var(--border-light); flex-shrink:0; margin-top:2px; display:flex; align-items:center; justify-content:center; }
.task-check.checked { background:var(--green); border-color:var(--green); }
.task-check.checked::after { content:'✓'; color:#fff; font-size:11px; font-weight:700; }
.task-text { flex:1; min-width:0; }
.task-title { font-size:13px; font-weight:500; white-space:nowrap; overflow:hidden; text-overflow:ellipsis; }
.task-title.done-text { text-decoration:line-through; color:var(--text-muted); }
.task-meta { font-size:11px; color:var(--text-muted); }
.priority-dot { width:8px; height:8px; border-radius:50%; flex-shrink:0; margin-top:6px; }
.priority-dot.high   { background:var(--accent-light); }
.priority-dot.medium { background:var(--yellow); }
.priority-dot.low    { background:var(--green); }

/* Activity */
.activity-item { display:flex; gap:12px; padding:10px 0; border-bottom:1px solid var(--border); }
.activity-item:last-child { border-bottom:none; }
.activity-icon { width:30px; height:30px; border-radius:50%; display:flex; align-items:center; justify-content:center; font-size:13px; flex-shrink:0; }
.activity-icon.green  { background:rgba(39,174,96,0.15);  color:var(--green); }
.activity-icon.yellow { background:rgba(243,156,18,0.15); color:var(--yellow); }
.activity-icon.red    { background:rgba(192,57,43,0.15);  color:var(--accent-light); }
.activity-title { font-size:12.5px; color:var(--text-light); }
.activity-title strong { color:var(--text-white); }
.activity-time { font-size:11px; color:var(--text-muted); }

/* Donut */
.donut-wrapper { display:flex; flex-direction:column; align-items:center; gap:16px; }
.donut-legend { width:100%; }
.legend-item { display:flex; align-items:center; gap:8px; font-size:12px; color:var(--text-light); margin-bottom:8px; }
.legend-dot { width:10px; height:10px; border-radius:50%; flex-shrink:0; }
.legend-item span:last-child { margin-left:auto; font-weight:600; }

/* Alerts */
.alert { padding:11px 16px; border-radius:var(--radius); font-size:13px; display:flex; align-items:center; gap:8px; }
.alert-error   { background:rgba(192,57,43,0.12); border:1px solid rgba(192,57,43,0.3); color:var(--accent-light); }
.alert-success { background:rgba(39,174,96,0.12);  border:1px solid rgba(39,174,96,0.3);  color:var(--green); }

/* Forms */
.field { margin-bottom:16px; }
.field label { display:block; font-size:11px; font-weight:700; letter-spacing:0.8px; text-transform:uppercase; color:var(--text-light); margin-bottom:7px; }
.field-wrap { position:relative; }
.field-wrap i { position:absolute; left:13px; top:50%; transform:translateY(-50%); color:var(--text-muted); font-size:16px; pointer-events:none; }
.field-wrap input,
.field-wrap select,
.field-wrap textarea { width:100%; background:var(--bg-input); border:1px solid var(--border-light); border-radius:var(--radius); padding:11px 14px 11px 40px; color:var(--text-white); font-size:14px; font-family:var(--font-body); outline:none; transition:border 0.2s; -webkit-appearance:none; appearance:none; }
.field-wrap input:focus,
.field-wrap select:focus { border-color:var(--accent); }
.field-wrap select option { background:var(--bg-card); }
.field-row   { display:grid; grid-template-columns:1fr 1fr;     gap:16px; }
.field-row-3 { display:grid; grid-template-columns:1fr 1fr 1fr; gap:16px; }
.form-section-label { font-size:11px; font-weight:700; letter-spacing:1px; text-transform:uppercase; color:var(--accent-light); margin-bottom:14px; padding-bottom:8px; border-bottom:1px solid var(--border); }

/* Data table */
.data-table { width:100%; border-collapse:collapse; }
.data-table thead th { font-size:10px; font-weight:700; letter-spacing:1px; text-transform:uppercase; color:var(--text-muted); padding:0 12px 12px 0; text-align:left; border-bottom:1px solid var(--border); white-space:nowrap; }
.data-table tbody td { padding:12px 12px 12px 0; font-size:13px; color:var(--text-light); border-bottom:1px solid var(--border); vertical-align:middle; }
.data-table tbody tr:last-child td { border-bottom:none; }
.data-table tbody tr:hover td { background:rgba(255,255,255,0.02); }

/* Auth pages */
.auth-body { display:flex; align-items:center; justify-content:center; min-height:100vh; padding:30px 16px; }
.auth-box { background:var(--bg-card); border:1px solid var(--border); border-radius:18px; padding:40px; width:100%; max-width:420px; }
.auth-logo { display:flex; align-items:center; gap:10px; margin-bottom:28px; }
.auth-logo .logo-text { font-family:var(--font-head); font-size:20px; }
.auth-box h2 { font-family:var(--font-head); font-size:22px; font-weight:700; margin-bottom:4px; }
.auth-sub { color:var(--text-muted); font-size:13px; margin-bottom:24px; }
.auth-link { text-align:center; margin-top:18px; font-size:13px; color:var(--text-muted); }
.auth-link a { color:var(--accent-light); font-weight:600; }

/* Scrollbar */
::-webkit-scrollbar { width:5px; }
::-webkit-scrollbar-track { background:var(--bg-dark); }
::-webkit-scrollbar-thumb { background:var(--bg-card); border-radius:10px; }

/* ============================================================
   RESPONSIVE — MOBILE FIXED
   ============================================================ */

/* ── Tablet & Mobile (≤768px) ─────────────────────────────── */
@media (max-width: 768px) {

    /* Sidebar: slide off screen, opens on hamburger click */
    .sidebar {
        width: 280px;
        transform: translateX(-100%);
        transition: transform 0.28s ease;
        box-shadow: 4px 0 20px rgba(0,0,0,0.5);
        z-index: 200;
    }
    .sidebar.open { transform: translateX(0); }
    .sidebar-close { display: block; }

    /* Show sticky mobile top bar */
    .mobile-topbar { display: flex; }

    /* Main content: full width, no left margin */
    .main-content {
        margin-left: 0 !important;
        padding: 14px 12px 24px;
        width: 100%;
        overflow-x: hidden;
    }

    /* ── Top Bar: show but stack vertically ── */
    .top-bar {
        display: flex;
        flex-direction: column;
        align-items: flex-start;
        gap: 10px;
        margin-bottom: 16px;
    }
    .top-bar-left { width: 100%; }
    .top-bar-left h1 { font-size: 18px; }
    .top-bar-right {
        width: 100%;
        flex-wrap: wrap;
        gap: 8px;
    }

    /* Search bar: full width */
    .search-bar {
        width: 100% !important;
        flex: 1;
        min-width: 0;
    }

    /* Action buttons: stretch on mobile */
    .top-bar-right .btn {
        flex: 1;
        justify-content: center;
        font-size: 12px;
        padding: 8px 10px;
    }

    /* ── Stat Cards: 2 per row ── */
    .stats-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 10px;
    }
    .stat-card { padding: 14px 12px; }
    .stat-value { font-size: 20px; }

    /* ── Charts: 1 column ── */
    .dashboard-grid {
        grid-template-columns: 1fr;
        gap: 14px;
    }

    /* ── Bottom widgets: 1 column ── */
    .bottom-grid {
        grid-template-columns: 1fr;
        gap: 14px;
    }

    /* ── Cards ── */
    .card { padding: 16px 14px; }

    /* ── Card header: stack title + button ── */
    .card-header {
        flex-wrap: wrap;
        gap: 10px;
    }
    .card-header .btn { font-size: 11px; padding: 6px 10px; }

    /* ── Form fields: always 1 column ── */
    .field-row,
    .field-row-3 {
        grid-template-columns: 1fr !important;
        gap: 12px;
    }
    .field { min-width: 0; }

    /* ── Lead step wizard on mobile ── */
    .pipeline-stepper { padding: 14px 10px 0; gap: 0; }
    .ps-label { font-size: 9px; }
    .ps-sub   { display: none; }
    .ps-circle { width: 30px; height: 30px; font-size: 12px; }
    .step-hd  { padding: 12px 14px; gap: 10px; }
    .step-body { padding: 14px; }

    /* ── Stat icon: smaller ── */
    .stat-icon { width: 34px; height: 34px; font-size: 16px; }

    /* ── Tables: horizontal scroll wrapper ── */
    .data-table-wrapper,
    .mini-table-wrapper,
    .card > table {
        overflow-x: auto;
        -webkit-overflow-scrolling: touch;
        /*display: block;*/
        width: 100%;
    }
    .data-table { min-width: 580px; }
    .mini-table { min-width: 400px; }

    /* ── Biz switcher: full width ── */
    .biz-switcher-btn { width: 100%; }
    .biz-dropdown { width: 100%; left: 0; right: 0; }

    /* ── Invoice & quotation view: scale down ── */
    .inv-page, .page {
        margin: 8px auto;
        padding: 12px;
        width: 100%;
        overflow-x: auto;
    }
    .inv-wrap { font-size: 10px; }
    .inv-header { padding: 10px 12px; }
    .hdr-biz .name { font-size: 15px; }
    .meta-grid,
    .totals-section,
    .bank-section,
    .terms-section,
    .bottom-grid,
    .inv-meta { grid-template-columns: 1fr; }

    /* ── Quotation view on mobile ── */
    .warranty-grid { grid-template-columns: 1fr 1fr 1fr; gap: 6px; }
    .warranty-box .yr { font-size: 18px; }

    /* ── Overflow prevention ── */
    .activity-title,
    .proj-name,
    .client-name {
        white-space: normal;
        word-break: break-word;
    }
}

/* ── Small phones (≤480px) ─────────────────────────────────── */
@media (max-width: 480px) {

    .main-content { padding: 10px 10px 20px; }
    .card { padding: 14px 12px; }

    /* Stat cards: still 2 per row but tighter */
    .stats-grid { grid-template-columns: repeat(2, 1fr); gap: 8px; }
    .stat-value { font-size: 18px; }
    .stat-label { font-size: 11px; }

    /* Stepper: very compact */
    .ps-circle { width: 26px; height: 26px; font-size: 11px; }
    .ps-label   { font-size: 8px; }
    .step-badge { display: none; }

    /* Buttons: full width on very small screens */
    .top-bar-right { flex-direction: column; }
    .top-bar-right .btn { width: 100%; }

    /* Table: scroll */
    .data-table { min-width: 520px; }
    .mini-table { min-width: 360px; }
}
/* ============================================================
   MOBILE TABLE CARD STYLE (Desktop Safe)
   ============================================================ */

@media (max-width: 768px) {
    /* Hide normal table header */
    .data-table thead,
    .mini-table thead {
        display: none;
    }

    /* Make each row look like a card */
    .data-table tbody tr,
    .mini-table tbody tr {
        display: block;
        background: var(--bg-card);
        border: 1px solid rgba(255, 255, 255, 0.25);
        border-radius: 12px;
        margin-bottom: 16px;
        padding: 14px 16px;
        box-shadow: 0 4px 12px hsl(249, 56%, 84%);
    }

    /* Make cells block elements */
    .data-table tbody td,
    .mini-table tbody td {
        display: block;
        padding: 9px 0;
        border-bottom: 1px dashed var(--border-light);
        font-size: 13.5px;
        text-align: left;
    }

    .data-table tbody td:last-child,
    .mini-table tbody td:last-child {
        border-bottom: none;
    }

    /* Show column name automatically */
    .data-table tbody td:nth-child(1):before,
    .mini-table tbody td:nth-child(1):before { content: "Business / Name"; font-weight:700; color:var(--accent-light); font-size:12px; display:block; margin-bottom:3px; }
    
    .data-table tbody td:nth-child(2):before,
    .mini-table tbody td:nth-child(2):before { content: "Admin"; font-weight:700; color:var(--accent-light); font-size:12px; display:block; margin-bottom:3px; }
    
    .data-table tbody td:nth-child(3):before { content: "Email"; font-weight:700; color:var(--accent-light); font-size:12px; display:block; margin-bottom:3px; }
    
    .data-table tbody td:nth-child(4):before { content: "Contact"; font-weight:700; color:var(--accent-light); font-size:12px; display:block; margin-bottom:3px; }
    
    .data-table tbody td:nth-child(5):before { content: "GST / PAN"; font-weight:700; color:var(--accent-light); font-size:12px; display:block; margin-bottom:3px; }
    
    .data-table tbody td:nth-child(6):before { content: "Clients"; font-weight:700; color:var(--accent-light); font-size:12px; display:block; margin-bottom:3px; }
    
    .data-table tbody td:nth-child(7):before { content: "Projects"; font-weight:700; color:var(--accent-light); font-size:12px; display:block; margin-bottom:3px; }
    
    .data-table tbody td:nth-child(8):before { content: "Invoices"; font-weight:700; color:var(--accent-light); font-size:12px; display:block; margin-bottom:3px; }
    
    .data-table tbody td:nth-child(9):before { content: "Revenue"; font-weight:700; color:var(--accent-light); font-size:12px; display:block; margin-bottom:3px; }
    
    .data-table tbody td:nth-child(10):before { content: "Joined"; font-weight:700; color:var(--accent-light); font-size:12px; display:block; margin-bottom:3px; }
    
    .data-table tbody td:nth-child(11):before { content: "Status"; font-weight:700; color:var(--accent-light); font-size:12px; display:block; margin-bottom:3px; }
    
    .data-table tbody td:nth-child(12):before { content: "Action"; font-weight:700; color:var(--accent-light); font-size:12px; display:block; margin-bottom:3px; }

    /* Mini Table Specific */
    .mini-table tbody td:nth-child(1):before { content: "Project"; }
    .mini-table tbody td:nth-child(2):before { content: "Client"; }
    .mini-table tbody td:nth-child(3):before { content: "Status"; }

    /* Remove horizontal scroll */
    .data-table,
    .mini-table {
        min-width: auto;
        width: 100%;
    }
}

/* Extra Small Screens */
@media (max-width: 480px) {
    .data-table tbody tr,
    .mini-table tbody tr {
        padding: 12px 14px;
        margin-bottom: 14px;
    }
}








/* ── Step Tabs ── */
.step-tabs {
    display: flex;
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: var(--radius-lg);
    padding: 6px;
    margin-bottom: 24px;
    gap: 4px;
}
.step-tab {
    flex: 1;
    padding: 10px 14px;
    border-radius: var(--radius);
    border: none;
    background: transparent;
    color: var(--text-muted);
    font-size: 13.5px;
    font-weight: 500;
    font-family: var(--font-body);
    cursor: default;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    transition: var(--transition);
}
.step-tab.active {
    background: var(--accent);
    color: #fff;
    font-weight: 600;
}
.step-tab.done { color: var(--accent); }
.step-num {
    width: 22px; height: 22px;
    border-radius: 50%;
    border: 1.5px solid currentColor;
    font-size: 11px; font-weight: 700;
    display: flex; align-items: center; justify-content: center;
    flex-shrink: 0;
}
.step-tab.active .step-num { background: rgba(255,255,255,0.2); border-color: transparent; }
.step-tab.done  .step-num  { background: var(--accent); border-color: var(--accent); color: #fff; content: '✓'; }

/* ── Step panels ── */
.step-panel { display: none; }
.step-panel.active { display: block; }

/* ── Inline add row ── */
.inline-add-row {
    display: flex; gap: 8px; margin-top: 8px; align-items: center;
}
.inline-add-row input {
    flex: 1; padding: 8px 12px;
    background: var(--bg-input);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    color: var(--text-white);
    font-size: 13px; font-family: var(--font-body);
    transition: var(--transition);
}
.inline-add-row input::placeholder { color: var(--text-muted); }
.inline-add-row input:focus { outline: none; border-color: var(--accent); }
.btn-inline {
    padding: 8px 14px;
    background: var(--accent-glow);
    border: 1px solid var(--accent);
    border-radius: var(--radius);
    color: var(--accent);
    font-size: 13px; font-weight: 600;
    cursor: pointer; font-family: var(--font-body);
    white-space: nowrap;
    transition: var(--transition);
    display: inline-flex; align-items: center; gap: 4px;
}
.btn-inline:hover { background: var(--accent); color: #fff; }

/* ── Review table ── */
.review-table { width: 100%; border-collapse: collapse; margin-top: 4px; }
.review-table td {
    padding: 12px 0;
    border-bottom: 1px solid var(--border);
    font-size: 14px; color: var(--text-white);
}
.review-table td:first-child {
    color: var(--text-muted); width: 38%;
    font-weight: 500; font-size: 12px;
    text-transform: uppercase; letter-spacing: .06em;
}
.review-table tr:last-child td { border-bottom: none; }

/* ── Step nav ── */
.step-nav {
    display: flex; justify-content: space-between; align-items: center;
    margin-top: 28px; padding-top: 20px;
    border-top: 1px solid var(--border);
}
.step-nav-right { display: flex; gap: 10px; }

/* ── Live preview box ── */
.preview-box {
    background: var(--accent-glow);
    border: 1px solid rgba(192,57,43,0.3);
    border-radius: var(--radius);
    padding: 16px 20px;
    margin-top: 20px;
    display: flex; gap: 36px; flex-wrap: wrap;
}
.preview-box .pv-label {
    font-size: 10px; font-weight: 700;
    text-transform: uppercase; letter-spacing: .08em;
    color: var(--text-muted); margin-bottom: 4px;
}
.preview-val  { font-size: 22px; font-weight: 700; color: var(--accent); font-family: var(--font-head); }
.stock-ok     { color: var(--green); font-size: 14px; font-weight: 600; }
.stock-low    { color: var(--yellow); font-size: 14px; font-weight: 600; }
.stock-out    { color: var(--accent-light); font-size: 14px; font-weight: 600; }