/* ============================================================
   TerritoryIQ — app-drawer.css
   Right-side overlay drawer + icon rail for Analyze page.
   Drawer overlays the map (no push). Map dims behind open panel.
   Rail is 44px, always visible post-analysis, anchored to map edge.
   ============================================================ */

/* ── Map wrapper ─────────────────────────────────────────── */
/* Taller map than the default 480px — gives the drawer more canvas */
.fi-map-container {
    position: relative;
    width: 100%;
    height: 600px;
    flex-shrink: 0;
    overflow: hidden;
}

/* ── Map dim overlay ─────────────────────────────────────── */
.tiq-map-dim {
    position: absolute;
    inset: 0;
    background: rgba(10, 22, 40, 0.30);
    z-index: 15;
    pointer-events: auto;
    cursor: pointer;
    opacity: 0;
    transition: opacity 0.25s ease;
}

.tiq-map-dim.tiq-map-dim--visible {
    opacity: 1;
}

/* ── Icon Rail ───────────────────────────────────────────── */
.tiq-drawer-rail {
    position: absolute;
    right: 0;
    top: 0;
    bottom: 0;
    width: 44px;
    background: #FFFFFF;
    border-left: 1px solid var(--tiq-border);
    display: flex;
    flex-direction: column;
    align-items: center;
    padding: 14px 0;
    gap: 4px;
    z-index: 20;
    box-shadow: -2px 0 8px rgba(0,0,0,0.06);
}

.tiq-rail-btn {
    position: relative;
    width: 32px;
    height: 32px;
    border-radius: 8px;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    border: none;
    background: transparent;
    color: var(--tiq-text-4);
    transition: background 0.15s, color 0.15s;
    flex-shrink: 0;
}

.tiq-rail-btn:hover {
    background: var(--tiq-surface-2);
    color: var(--tiq-text-2);
}

.tiq-rail-btn.tiq-rail-btn--active {
    background: var(--tiq-green-light);
    color: var(--tiq-green);
}

.tiq-rail-btn svg {
    width: 16px;
    height: 16px;
    flex-shrink: 0;
}

/* Tooltip — appears to the LEFT of the rail button */
.tiq-rail-tooltip {
    position: absolute;
    right: calc(100% + 8px);
    top: 50%;
    transform: translateY(-50%);
    background: var(--tiq-ink);
    color: #fff;
    font-size: 10px;
    font-weight: 600;
    white-space: nowrap;
    padding: 4px 8px;
    border-radius: 5px;
    pointer-events: none;
    opacity: 0;
    transition: opacity 0.15s;
    letter-spacing: 0.02em;
    z-index: 30;
}

.tiq-rail-tooltip::after {
    content: '';
    position: absolute;
    left: 100%;
    top: 50%;
    transform: translateY(-50%);
    border: 4px solid transparent;
    border-left-color: var(--tiq-ink);
}

.tiq-rail-btn:hover .tiq-rail-tooltip {
    opacity: 1;
}

/* ── Drawer panel ────────────────────────────────────────── */
.tiq-drawer {
    position: absolute;
    right: 44px;          /* sits flush against the rail */
    top: 0;
    bottom: 0;
    width: 360px;
    background: var(--tiq-surface);
    border-left: 1px solid var(--tiq-border);
    display: flex;
    flex-direction: column;
    z-index: 19;
    box-shadow: -6px 0 28px rgba(0,0,0,0.12);
    transform: translateX(100%);
    transition: transform 0.28s cubic-bezier(0.16, 1, 0.3, 1);
    overflow: hidden;
}

.tiq-drawer.tiq-drawer--open {
    transform: translateX(0);
}

/* ── Drawer header ───────────────────────────────────────── */
.tiq-drawer-header {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 12px 14px 11px;
    border-bottom: 1px solid var(--tiq-border);
    flex-shrink: 0;
    background: var(--tiq-surface);
}

.tiq-drawer-accent {
    width: 3px;
    height: 18px;
    border-radius: 2px;
    background: var(--tiq-green);
    flex-shrink: 0;
}

.tiq-drawer-title {
    font-size: 0.8rem;
    font-weight: 700;
    color: var(--tiq-text);
    letter-spacing: 0.02em;
    text-transform: uppercase;
    flex: 1;
    min-width: 0;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.tiq-drawer-close {
    width: 24px;
    height: 24px;
    border-radius: 5px;
    background: var(--tiq-surface-2);
    border: 1px solid var(--tiq-border);
    cursor: pointer;
    font-size: 15px;
    color: var(--tiq-text-3);
    display: flex;
    align-items: center;
    justify-content: center;
    line-height: 1;
    transition: all 0.15s;
    flex-shrink: 0;
    font-family: inherit;
}

.tiq-drawer-close:hover {
    background: #FEF2F2;
    border-color: #FECACA;
    color: var(--tiq-red);
}

/* ── Drawer body ─────────────────────────────────────────── */
.tiq-drawer-body {
    flex: 1;
    overflow-y: auto;
    overflow-x: hidden;
    padding: 14px;
    display: flex;
    flex-direction: column;
    gap: 12px;
    scrollbar-width: thin;
    scrollbar-color: var(--tiq-border) transparent;
}

.tiq-drawer-body::-webkit-scrollbar { width: 4px; }
.tiq-drawer-body::-webkit-scrollbar-thumb { background: var(--tiq-border); border-radius: 2px; }

/* ── Drawer stat row (Agent panel header) ────────────────── */
.tiq-drawer-stats {
    display: flex;
    gap: 8px;
}

.tiq-drawer-stat {
    flex: 1;
    background: var(--tiq-surface-2);
    border: 1px solid var(--tiq-border);
    border-radius: 8px;
    padding: 8px 6px;
    text-align: center;
}

.tiq-drawer-stat-val {
    font-size: 1.3rem;
    font-weight: 800;
    color: var(--tiq-text);
    line-height: 1;
    letter-spacing: -0.03em;
    font-variant-numeric: tabular-nums;
}

.tiq-drawer-stat-val--green { color: var(--tiq-green); }
.tiq-drawer-stat-val--red   { color: var(--tiq-red); }
.tiq-drawer-stat-val--amber { color: var(--tiq-amber); }

.tiq-drawer-stat-lbl {
    font-size: 0.6rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.07em;
    color: var(--tiq-text-4);
    margin-top: 3px;
}

/* ── Insight cards inside drawer ─────────────────────────── */
.tiq-drawer-insight {
    border-left: 3px solid var(--tiq-green);
    background: #F0FDF9;
    border-radius: 0 8px 8px 0;
    padding: 9px 11px;
    font-size: 0.82rem;
    color: var(--tiq-text-2);
    line-height: 1.5;
    display: flex;
    align-items: flex-start;
    gap: 8px;
}

.tiq-drawer-insight--amber { border-left-color: var(--tiq-amber); background: #FFFBEB; }
.tiq-drawer-insight--red   { border-left-color: var(--tiq-red);   background: #FEF2F2; }
.tiq-drawer-insight--blue  { border-left-color: #0284C7;          background: #F0F9FF; }

.tiq-drawer-insight-icon {
    font-size: 0.95rem;
    line-height: 1.4;
    flex-shrink: 0;
}

.tiq-drawer-insight-body { display: flex; flex-direction: column; gap: 2px; min-width: 0; }

.tiq-drawer-insight-headline {
    font-size: 0.8rem;
    font-weight: 700;
    color: var(--tiq-text);
    line-height: 1.3;
}

.tiq-drawer-insight--green  .tiq-drawer-insight-headline { color: #15803D; }
.tiq-drawer-insight--amber  .tiq-drawer-insight-headline { color: #92400E; }
.tiq-drawer-insight--red    .tiq-drawer-insight-headline { color: #B91C1C; }
.tiq-drawer-insight--blue   .tiq-drawer-insight-headline { color: #0369A1; }

.tiq-drawer-insight-detail {
    font-size: 0.76rem;
    color: var(--tiq-text-3);
    line-height: 1.5;
}

/* ── Section divider inside drawer ──────────────────────── */
.tiq-drawer-section-label {
    font-size: 0.62rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.09em;
    color: var(--tiq-text-4);
    padding: 4px 0 2px;
    border-top: 1px solid var(--tiq-border);
    margin-top: 4px;
}

/* ── Narrative text in drawer ────────────────────────────── */
.tiq-drawer-narrative {
    font-size: 0.875rem;
    line-height: 1.75;
    color: var(--tiq-text-2);
}

.tiq-drawer-narrative p { margin: 0 0 0.75rem; }
.tiq-drawer-narrative p:last-child { margin-bottom: 0; }

.tiq-drawer-narrative-loading {
    display: flex;
    align-items: center;
    gap: 8px;
    color: var(--tiq-text-3);
    font-size: 0.84rem;
    padding: 4px 0;
}

/* ── Agent thread in drawer ──────────────────────────────── */
.tiq-drawer-agent-thread {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.tiq-drawer-msg {
    display: flex;
    flex-direction: column;
    max-width: 90%;
}

.tiq-drawer-msg--user { align-self: flex-end; align-items: flex-end; }
.tiq-drawer-msg--assistant { align-self: flex-start; align-items: flex-start; }

.tiq-drawer-msg--user::before {
    content: "You";
    font-size: 0.6rem;
    font-weight: 700;
    color: var(--tiq-green-dim);
    text-transform: uppercase;
    letter-spacing: 0.07em;
    margin-bottom: 3px;
}

.tiq-drawer-msg--assistant::before {
    content: "TerritoryIQ Agent";
    font-size: 0.6rem;
    font-weight: 700;
    color: var(--tiq-text-4);
    text-transform: uppercase;
    letter-spacing: 0.07em;
    margin-bottom: 3px;
}

.tiq-drawer-bubble {
    padding: 8px 11px;
    border-radius: 10px;
    font-size: 0.86rem;
    line-height: 1.65;
    width: 100%;
    box-sizing: border-box;
}

.tiq-drawer-msg--user .tiq-drawer-bubble {
    background: var(--tiq-green-light);
    border: 1.5px solid rgba(0,178,122,0.2);
    color: var(--tiq-text);
    border-bottom-right-radius: 3px;
}

.tiq-drawer-msg--assistant .tiq-drawer-bubble {
    background: var(--tiq-surface-2);
    border: 1.5px solid var(--tiq-border);
    color: var(--tiq-text-2);
    border-bottom-left-radius: 3px;
}

.tiq-drawer-bubble p { margin: 0 0 0.5rem; }
.tiq-drawer-bubble p:last-child { margin-bottom: 0; }

.tiq-drawer-bubble--streaming:not(:has(p)) {
    min-width: 60px;
    min-height: 38px;
    display: flex;
    align-items: center;
}

.tiq-drawer-bubble--streaming .fi-spinner {
    border-color: rgba(30,41,59,0.12);
    border-top-color: var(--tiq-text-3);
}

/* Agent limit message */
.tiq-drawer-agent-limit {
    font-size: 0.8rem;
    color: var(--tiq-text-3);
    background: var(--tiq-surface-2);
    border: 1.5px solid var(--tiq-border);
    border-radius: var(--tiq-radius);
    padding: 10px 12px;
    text-align: center;
    line-height: 1.5;
}

.tiq-drawer-agent-limit a {
    color: var(--tiq-green);
    font-weight: 600;
    text-decoration: none;
}

.tiq-drawer-agent-limit a:hover { text-decoration: underline; }

/* ── Chat input pinned to drawer bottom ──────────────────── */
.tiq-drawer-chat-footer {
    border-top: 1px solid var(--tiq-border);
    background: var(--tiq-surface);
    flex-shrink: 0;
    display: flex;
    flex-direction: column;
    gap: 0;
}

.tiq-drawer-chat-row {
    display: flex;
    gap: 6px;
    align-items: center;
    padding: 10px 14px;
}

.tiq-drawer-chat-input {
    flex: 1;
    background: var(--tiq-surface-2);
    border: 1.5px solid var(--tiq-border);
    border-radius: 8px;
    padding: 7px 10px;
    font-size: 0.84rem;
    color: var(--tiq-text);
    font-family: inherit;
    outline: none;
    transition: border-color 0.15s, box-shadow 0.15s;
    resize: none;
}

.tiq-drawer-chat-input::placeholder { color: var(--tiq-text-4); }

.tiq-drawer-chat-input:focus {
    border-color: var(--tiq-green);
    box-shadow: 0 0 0 3px var(--tiq-green-glow);
}

.tiq-drawer-chat-send {
    width: 34px;
    height: 34px;
    background: var(--tiq-green);
    color: #fff;
    border: none;
    border-radius: 8px;
    font-size: 14px;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
    transition: all 0.15s;
    box-shadow: 0 2px 6px rgba(0,178,122,0.3);
}

.tiq-drawer-chat-send:hover:not(:disabled) {
    background: var(--tiq-green-dim);
    transform: translateY(-1px);
}

.tiq-drawer-chat-send:disabled { opacity: 0.45; cursor: not-allowed; }

.tiq-drawer-usage-note {
    font-size: 0.7rem;
    color: var(--tiq-text-4);
    text-align: center;
    padding: 0 14px 10px;
    line-height: 1.4;
}

.tiq-drawer-usage-note a {
    color: var(--tiq-green);
    font-weight: 600;
    text-decoration: none;
}

.tiq-drawer-usage-note a:hover { text-decoration: underline; }

/* ── Demographics panel ──────────────────────────────────── */
.tiq-drawer-demo-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 8px;
}

.tiq-drawer-demo-card {
    background: var(--tiq-surface-2);
    border: 1px solid var(--tiq-border);
    border-radius: 8px;
    padding: 10px 8px;
    text-align: center;
    transition: all 0.15s;
}

.tiq-drawer-demo-card:hover {
    border-color: var(--tiq-border-green);
    background: var(--tiq-surface);
}

.tiq-drawer-demo-card--income {
    border-color: rgba(0,178,122,0.2);
    background: var(--tiq-green-light);
}

.tiq-drawer-demo-icon { font-size: 1rem; margin-bottom: 3px; line-height: 1; }

.tiq-drawer-demo-val {
    font-size: 1rem;
    font-weight: 800;
    color: var(--tiq-text);
    line-height: 1.1;
    letter-spacing: -0.02em;
    font-variant-numeric: tabular-nums;
}

.tiq-drawer-demo-lbl {
    font-size: 0.6rem;
    color: var(--tiq-text-4);
    text-transform: uppercase;
    letter-spacing: 0.07em;
    margin-top: 3px;
    font-weight: 700;
}

.tiq-drawer-demo-tier {
    display: inline-block;
    margin-top: 4px;
    font-size: 0.6rem;
    font-weight: 700;
    color: var(--tiq-green-dim);
    background: var(--tiq-green-light);
    border: 1px solid rgba(0,178,122,0.25);
    border-radius: 20px;
    padding: 1px 6px;
    text-transform: uppercase;
    letter-spacing: 0.05em;
}

.tiq-drawer-loading {
    display: flex;
    align-items: center;
    gap: 8px;
    color: var(--tiq-text-3);
    font-size: 0.84rem;
    padding: 8px 0;
}

/* ── Heatmap panel ───────────────────────────────────────── */
.tiq-drawer-heatmap-stats {
    display: flex;
    gap: 8px;
}

.tiq-drawer-heatmap-stat {
    flex: 1;
    text-align: center;
    border-radius: 8px;
    padding: 10px 6px;
    border: 1.5px solid;
}

.tiq-drawer-heatmap-stat--green { border-color: #86EFAC; background: #F0FDF4; }
.tiq-drawer-heatmap-stat--yellow { border-color: #FDE68A; background: #FFFBEB; }
.tiq-drawer-heatmap-stat--red { border-color: #FECACA; background: #FEF2F2; }

.tiq-drawer-heatmap-stat-val {
    font-size: 1.4rem;
    font-weight: 800;
    line-height: 1;
    letter-spacing: -0.03em;
}

.tiq-drawer-heatmap-stat--green  .tiq-drawer-heatmap-stat-val { color: #16A34A; }
.tiq-drawer-heatmap-stat--yellow .tiq-drawer-heatmap-stat-val { color: #D97706; }
.tiq-drawer-heatmap-stat--red    .tiq-drawer-heatmap-stat-val { color: #DC2626; }

.tiq-drawer-heatmap-stat-lbl {
    font-size: 0.6rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.07em;
    color: var(--tiq-text-4);
    margin-top: 3px;
}

/* Heatmap upload area */
.tiq-drawer-upload-zone {
    background: var(--tiq-surface-2);
    border: 1.5px dashed var(--tiq-border-2);
    border-radius: 10px;
    padding: 16px;
    display: flex;
    flex-direction: column;
    gap: 10px;
    align-items: flex-start;
}

.tiq-drawer-upload-desc {
    font-size: 0.82rem;
    color: var(--tiq-text-3);
    line-height: 1.55;
    margin: 0;
}

.tiq-drawer-threshold-row {
    display: flex;
    align-items: center;
    gap: 8px;
    flex-wrap: wrap;
    width: 100%;
    font-size: 0.8rem;
    color: var(--tiq-text-2);
}

.tiq-drawer-threshold-label {
    font-size: 0.62rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.08em;
    color: var(--tiq-text-4);
}

.tiq-drawer-threshold-field {
    display: flex;
    align-items: center;
    gap: 5px;
    font-size: 0.8rem;
    color: var(--tiq-text-2);
}

.tiq-drawer-threshold-input {
    width: 52px !important;
    padding: 4px 6px !important;
    font-size: 0.82rem !important;
    text-align: center;
    border: 1.5px solid var(--tiq-border);
    border-radius: 6px;
    background: var(--tiq-surface);
    color: var(--tiq-text);
    font-family: inherit;
    outline: none;
}

.tiq-drawer-threshold-input:focus {
    border-color: var(--tiq-green);
    box-shadow: 0 0 0 2px var(--tiq-green-glow);
}

.tiq-drawer-upload-row {
    display: flex;
    align-items: center;
    gap: 8px;
    flex-wrap: wrap;
    width: 100%;
}

.tiq-drawer-file-name {
    font-size: 0.8rem;
    color: var(--tiq-text-2);
    max-width: 160px;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

/* Progress bar */
.tiq-drawer-progress {
    display: flex;
    align-items: center;
    gap: 8px;
    flex-wrap: wrap;
    font-size: 0.82rem;
    color: var(--tiq-text-3);
}

.tiq-drawer-progress-bar {
    flex: 1;
    min-width: 80px;
    height: 4px;
    background: var(--tiq-border);
    border-radius: 2px;
    overflow: hidden;
}

.tiq-drawer-progress-fill {
    height: 100%;
    background: linear-gradient(90deg, var(--tiq-green), var(--tiq-green-bright));
    border-radius: 2px;
    transition: width 0.4s ease;
}

.tiq-drawer-heatmap-actions { display: flex; gap: 6px; flex-wrap: wrap; }

/* Learn more toggle */
.tiq-drawer-learn-toggle {
    background: none;
    border: none;
    padding: 0;
    font-size: 0.78rem;
    font-weight: 600;
    color: var(--tiq-green);
    cursor: pointer;
    font-family: inherit;
    transition: opacity 0.15s;
}

.tiq-drawer-learn-toggle:hover { text-decoration: underline; }

.tiq-drawer-explainer {
    background: var(--tiq-surface-2);
    border: 1.5px solid var(--tiq-border);
    border-radius: 8px;
    padding: 10px 12px;
    font-size: 0.8rem;
    color: var(--tiq-text-2);
    line-height: 1.65;
    display: flex;
    flex-direction: column;
    gap: 6px;
}

.tiq-drawer-explainer ul {
    margin: 0;
    padding-left: 0;
    list-style: none;
    display: flex;
    flex-direction: column;
    gap: 4px;
}

.tiq-drawer-explainer code {
    font-family: 'Cascadia Code', 'Consolas', monospace;
    background: var(--tiq-surface);
    border: 1px solid var(--tiq-border);
    border-radius: 3px;
    padding: 1px 4px;
    font-size: 0.75rem;
    color: var(--tiq-green-dim);
}

/* ── Competitors panel ───────────────────────────────────── */
.tiq-drawer-comp-table {
    width: 100%;
    border-collapse: collapse;
    font-size: 0.8rem;
}

.tiq-drawer-comp-table th {
    text-align: left;
    padding: 5px 6px;
    background: var(--tiq-surface-2);
    color: var(--tiq-text-4);
    font-size: 0.6rem;
    text-transform: uppercase;
    letter-spacing: 0.08em;
    font-weight: 700;
    border-bottom: 1.5px solid var(--tiq-border);
}

.tiq-drawer-comp-table td {
    padding: 7px 6px;
    border-bottom: 1px solid var(--tiq-border);
    color: var(--tiq-text-2);
    vertical-align: middle;
}

.tiq-drawer-comp-table tr:last-child td { border-bottom: none; }
.tiq-drawer-comp-table tr:hover td { background: var(--tiq-surface-2); }

.tiq-drawer-comp-name {
    display: flex;
    align-items: center;
    gap: 5px;
    font-weight: 600;
    color: var(--tiq-text);
}

/* Manual comp add form inside drawer */
.tiq-drawer-manual-add {
    background: var(--tiq-surface-2);
    border: 1.5px solid var(--tiq-border);
    border-radius: 8px;
    padding: 12px;
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.tiq-drawer-manual-add-title {
    font-size: 0.62rem;
    font-weight: 700;
    color: var(--tiq-text-4);
    text-transform: uppercase;
    letter-spacing: 0.08em;
    margin: 0;
}

.tiq-drawer-manual-fields {
    display: flex;
    flex-direction: column;
    gap: 6px;
}

.tiq-drawer-manual-field {
    display: flex;
    flex-direction: column;
    gap: 3px;
}

.tiq-drawer-manual-field label {
    font-size: 0.62rem;
    font-weight: 700;
    color: var(--tiq-text-4);
    text-transform: uppercase;
    letter-spacing: 0.07em;
}

.tiq-drawer-manual-actions { display: flex; gap: 6px; flex-wrap: wrap; align-items: center; }
.tiq-drawer-manual-hint { font-size: 0.74rem; color: #7C3AED; font-style: italic; }

/* Manual comp list */
.tiq-drawer-manual-list { display: flex; flex-direction: column; }

.tiq-drawer-manual-row {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 7px 0;
    border-bottom: 1px solid var(--tiq-border);
    font-size: 0.82rem;
}

.tiq-drawer-manual-row:last-child { border-bottom: none; }

.tiq-drawer-manual-dot {
    width: 9px;
    height: 9px;
    border-radius: 2px;
    background: #7C3AED;
    flex-shrink: 0;
    transform: rotate(45deg);
}

.tiq-drawer-manual-name {
    font-weight: 600;
    color: var(--tiq-text);
    flex: 1;
    min-width: 0;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.tiq-drawer-manual-addr {
    color: var(--tiq-text-4);
    font-size: 0.74rem;
    flex: 1;
    min-width: 0;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

/* ── Error inside drawer ─────────────────────────────────── */
.tiq-drawer-error {
    padding: 8px 11px;
    background: #FEF2F2;
    border: 1px solid #FECACA;
    border-radius: 6px;
    color: #B91C1C;
    font-size: 0.8rem;
    line-height: 1.5;
}

/* ── Customer address save opt-in ────────────────────── */
.tiq-drawer-save-opt {
    display: flex;
    align-items: center;
    gap: 8px;
    cursor: pointer;
    margin-top: 6px;
    font-size: 0.8rem;
    color: var(--tiq-text-3);
    user-select: none;
}

.tiq-drawer-save-opt input[type="checkbox"] {
    accent-color: var(--tiq-green);
    width: 14px;
    height: 14px;
    flex-shrink: 0;
    cursor: pointer;
}

.tiq-drawer-save-opt span { line-height: 1.4; }

.tiq-drawer-save-hint {
    margin-top: 6px;
    padding: 8px 10px;
    background: var(--tiq-green-light);
    border: 1px solid rgba(0,178,122,0.25);
    border-radius: 6px;
    font-size: 0.76rem;
    color: var(--tiq-text-3);
    line-height: 1.5;
}

/* ── Saved customers banner ─────────────────────────── */
.tiq-drawer-saved-customers {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 10px;
    padding: 12px 14px;
    background: var(--tiq-green-light);
    border: 1.5px solid rgba(0,178,122,0.3);
    border-radius: 10px;
}

.tiq-drawer-saved-customers-left {
    display: flex;
    align-items: center;
    gap: 10px;
    min-width: 0;
}

.tiq-drawer-saved-customers-icon {
    font-size: 1.2rem;
    flex-shrink: 0;
    line-height: 1;
}

.tiq-drawer-saved-customers-count {
    font-size: 0.84rem;
    font-weight: 700;
    color: var(--tiq-text);
    line-height: 1.3;
}

.tiq-drawer-saved-customers-sub {
    font-size: 0.74rem;
    color: var(--tiq-text-3);
    line-height: 1.3;
    margin-top: 1px;
}

/* ── Manual customer entry ─────────────────────── */
.tiq-drawer-manual-customers {
    margin-top: 4px;
}

.tiq-drawer-manual-cust-form {
    margin-top: 8px;
    padding: 12px 14px;
    background: var(--tiq-bg);
    border: 1px solid var(--tiq-border);
    border-radius: 8px;
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.tiq-drawer-manual-cust-desc {
    font-size: 0.78rem;
    color: var(--tiq-text-3);
    line-height: 1.5;
    margin: 0;
}

.tiq-drawer-manual-cust-count {
    font-size: 0.8rem;
    font-weight: 700;
    color: var(--tiq-green);
}

.tiq-drawer-manual-cust-row {
    display: flex;
    gap: 6px;
    align-items: center;
}

.tiq-drawer-manual-cust-input {
    flex: 1;
    font-size: 0.8rem !important;
    padding: 6px 8px !important;
    min-width: 0;
}

.tiq-drawer-manual-cust-success {
    font-size: 0.78rem;
    color: var(--tiq-green);
    line-height: 1.4;
    font-weight: 500;
}

/* ── Manual entry confirmation card ──────────────── */
.tiq-drawer-manual-cust-confirm {
    display: flex;
    flex-direction: column;
    gap: 8px;
    padding: 10px 12px;
    background: #FFFBEB;
    border: 1.5px solid #FCD34D;
    border-radius: 8px;
    margin-top: 2px;
}

.tiq-drawer-manual-cust-confirm-label {
    font-size: 0.76rem;
    font-weight: 600;
    color: #92400E;
}

.tiq-drawer-manual-cust-confirm-address {
    font-size: 0.8rem;
    color: var(--tiq-text);
    font-weight: 500;
    line-height: 1.4;
    word-break: break-word;
}

.tiq-drawer-manual-cust-confirm-actions {
    display: flex;
    gap: 6px;
    flex-wrap: wrap;
}
