﻿/* Zarcall Client Portal – styles v3.0 (2026-06 redesign) */
/* Design: Inter font, modern SaaS, OpenPhone/Stripe style */

@import url('https://fonts.googleapis.com/css2?family=Inter:wght@400;500;600;700&display=swap');

/* ─── Hide Astra page H1 ─── */
.page-id-1080 .entry-header { display: none; }

/* ─── Global wrapper ─── */
.zarcall-page { padding-top: 180px; }

.zarcall-portal {
    max-width: 1100px;
    margin: 0 auto 32px;
    font-family: Inter, -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
    color: #0a1628;
    border-radius: 12px;
    overflow: hidden;
    box-shadow: 0 4px 24px rgba(15,23,42,.09);
    background: #fff;
    transition: all .15s cubic-bezier(0.4,0,0.2,1);
}

/* ─── Admin Impersonation Bar ─── */
.zc-admin-impersonation-bar {
    height: 36px;
    background: #FEF3C7;
    color: #92400E;
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 0 24px;
    font-size: 13px;
    font-weight: 500;
    border-bottom: 1px solid #FDE68A;
    flex-shrink: 0;
}
.zc-admin-bar-return {
    color: #92400E;
    text-decoration: none;
    font-weight: 600;
    font-size: 12px;
    border: 1px solid #D97706;
    border-radius: 6px;
    padding: 3px 10px;
    transition: background .15s;
}
.zc-admin-bar-return:hover { background: #FDE68A; text-decoration: none; }

/* ─── Header ─── */
.zc-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 0 24px;
    height: 60px;
    background: #0a1628;
    color: #fff;
}
.zc-brand { line-height: 1.25; }
.zc-brand-name {
    font-size: 17px;
    font-weight: 700;
    color: #fff;
    display: block;
}
.zc-brand-sub {
    font-size: 11px;
    color: rgba(255,255,255,.4);
    font-weight: 400;
    display: block;
    margin-top: 1px;
}
.zc-phone { display: none; }

.zc-user {
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 13px;
    color: rgba(255,255,255,.75);
}
.zc-user a { color: #1D9E75; text-decoration: none; font-size: 13px; }
.zc-user a:hover { text-decoration: underline; }

/* ─── Role Badge ─── */
.zc-role-badge {
    display: inline-flex;
    align-items: center;
    font-size: 11px;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: .04em;
    padding: 2px 8px;
    border-radius: 999px;
}
.zc-role-badge.zc-role-owner { background: #E1FCEF; color: #10B981; }
.zc-role-badge.zc-role-agent { background: rgba(255,255,255,.12); color: rgba(255,255,255,.7); }

/* ─── Pill Navigation ─── */
.zc-tabs {
    display: flex;
    background: #fff;
    padding: 10px 20px;
    border-bottom: 1px solid #E2E8F0;
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
}
.zc-tabs::-webkit-scrollbar { display: none; }
.zc-tabs-inner {
    display: flex;
    background: #F1F5F9;
    border-radius: 8px;
    padding: 4px;
    gap: 2px;
    flex-shrink: 0;
}
.zc-tabs a {
    display: inline-flex;
    align-items: center;
    padding: 6px 14px;
    text-decoration: none;
    color: #64748B;
    font-weight: 500;
    font-size: 13px;
    border-radius: 6px;
    white-space: nowrap;
    border-bottom: none;
    transition: all .15s cubic-bezier(0.4,0,0.2,1);
}
.zc-tabs a:hover { background: rgba(255,255,255,.6); color: #0a1628; }
.zc-tabs a.active {
    background: #FFFFFF;
    color: #0a1628;
    font-weight: 600;
    box-shadow: 0 1px 3px rgba(0,0,0,.08);
}

/* ─── Content ─── */
.zc-content {
    background: #fff;
    padding: 24px;
    min-height: 400px;
}
.zc-content.zc-sms-content { padding: 0; overflow: hidden; }

/* ─── Summary Cards (Calls tab) ─── */
.zc-summary-cards {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 12px;
    margin-bottom: 20px;
}
.zc-summary-card {
    background: #fff;
    border: 1px solid #E2E8F0;
    border-radius: 12px;
    padding: 16px;
    transition: box-shadow .15s cubic-bezier(0.4,0,0.2,1);
}
.zc-summary-card:hover { box-shadow: 0 4px 12px rgba(15,23,42,.08); }
.zc-card-metric { font-size: 24px; font-weight: 700; color: #0a1628; line-height: 1.2; margin-bottom: 4px; }
.zc-card-label  { font-size: 12px; color: #64748B; font-weight: 500; }

/* ─── Table ─── */
.zc-table {
    width: 100%;
    border-collapse: collapse;
}
.zc-table th {
    background: #F8FAFC;
    font-size: 11px;
    font-weight: 600;
    color: #64748B;
    text-transform: uppercase;
    letter-spacing: .05em;
    padding: 10px 14px;
    text-align: left;
    border-bottom: 1px solid #E2E8F0;
}
.zc-table td {
    padding: 14px;
    font-size: 14px;
    color: #0a1628;
    border-bottom: 1px solid #F1F5F9;
    vertical-align: middle;
}
.zc-table tbody tr { transition: background .1s; }
.zc-table tbody tr:hover td { background: #F8FAFC; }
.zc-table tbody tr:last-child td { border-bottom: 0; }
.zc-table a { color: #1D9E75; }

/* ─── Status Badges ─── */
.zc-badge {
    display: inline-flex;
    align-items: center;
    border-radius: 999px;
    padding: 3px 10px;
    font-size: 12px;
    font-weight: 600;
    white-space: nowrap;
}
.zc-badge-answered  { background: #E1FCEF; color: #0F766E; }
.zc-badge-cancelled { background: #F1F5F9; color: #475569; }
.zc-badge-missed    { background: #FEE2E2; color: #B91C1C; }
.zc-badge-busy      { background: #FEF3C7; color: #B45309; }
.zc-badge-other     { background: #F1F5F9; color: #64748B; }

/* ─── Call Direction Column ─── */
.zc-dir-cell { display: flex; align-items: center; gap: 8px; }
.zc-dir-arrow-in  { color: #1D9E75; font-size: 13px; flex-shrink: 0; }
.zc-dir-arrow-out { color: #94A3B8; font-size: 13px; flex-shrink: 0; }
.zc-dir-arrow-loc { color: #94A3B8; font-size: 13px; flex-shrink: 0; }
.zc-contact-label { font-size: 14px; font-weight: 500; color: #0a1628; }

/* ─── Action Buttons ─── */
.zc-rec-btns {
    display: flex;
    align-items: center;
    gap: 4px;
}

.zc-rec-play, .zc-vm-play {
    width: 32px;
    height: 32px;
    border-radius: 6px;
    border: none;
    cursor: pointer;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
    padding: 0;
    background: #E1FCEF;
    color: #10B981;
    transition: all .15s cubic-bezier(0.4,0,0.2,1);
}
.zc-rec-play:hover, .zc-vm-play:hover { background: #D1FAE5; color: #059669; }
.zc-rec-play.zc-audio-playing, .zc-vm-play.zc-audio-playing { background: #10B981; color: #fff; }

.zc-rec-dl {
    width: 32px;
    height: 32px;
    border-radius: 6px;
    border: none;
    cursor: pointer;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
    text-decoration: none;
    background: transparent;
    color: #64748B;
    transition: all .15s cubic-bezier(0.4,0,0.2,1);
}
.zc-rec-dl:hover { background: #F1F5F9; color: #0a1628; }

.zc-call-del {
    width: 32px;
    height: 32px;
    border-radius: 6px;
    border: none;
    cursor: pointer;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
    background: transparent;
    color: #CBD5E1;
    font-size: 16px;
    line-height: 1;
    transition: all .15s cubic-bezier(0.4,0,0.2,1);
    padding: 0;
}
.zc-call-del:hover { background: #FEE2E2; color: #EF4444; }

.zc-rbtn-icon { display: flex; align-items: center; justify-content: center; pointer-events: none; }

/* ─── Inline Audio Player (lightweight) ─── */
.zc-audio-row td {
    padding: 2px 14px 8px !important;
    background: #fff !important;
    border-bottom: 1px solid #F1F5F9 !important;
}
.zc-player {
    background: #F8FAFC;
    border: 1px solid #E2E8F0;
    border-radius: 6px;
    padding: 6px 12px;
    display: flex;
    align-items: center;
    gap: 10px;
    max-width: 480px;
}
.zc-player-label {
    font-size: 10px;
    color: #94A3B8;
    font-weight: 500;
    text-transform: uppercase;
    letter-spacing: .04em;
    margin-right: 2px;
    flex-shrink: 0;
}
.zc-player-pp {
    width: 24px;
    height: 24px;
    border-radius: 50%;
    border: none;
    background: #1D9E75;
    color: #fff;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    flex-shrink: 0;
    padding: 0;
    transition: background .15s;
}
.zc-player-pp:hover { background: #168a62; }
.zc-player-cur, .zc-player-dur {
    font-size: 11px;
    color: #64748B;
    font-variant-numeric: tabular-nums;
    white-space: nowrap;
    flex-shrink: 0;
    min-width: 30px;
}
.zc-player-dur { color: #94A3B8; }
.zc-player-seek {
    flex: 1;
    -webkit-appearance: none;
    appearance: none;
    height: 4px;
    background: #E2E8F0;
    border-radius: 999px;
    cursor: pointer;
    min-width: 80px;
    accent-color: #1D9E75;
}
.zc-player-seek::-webkit-slider-thumb {
    -webkit-appearance: none;
    width: 11px;
    height: 11px;
    border-radius: 50%;
    background: #1D9E75;
    cursor: pointer;
}
.zc-player-seek::-moz-range-thumb {
    width: 11px;
    height: 11px;
    border-radius: 50%;
    background: #1D9E75;
    border: none;
    cursor: pointer;
}
.zc-player audio { display: none; }

/* ─── Overflow action menu (⋮) ─── */
.zc-action-menu {
    position: relative;
    flex-shrink: 0;
}
.zc-menu-trigger {
    width: 28px;
    height: 28px;
    border-radius: 6px;
    border: none;
    background: transparent;
    color: #94A3B8;
    font-size: 17px;
    line-height: 1;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 0;
    transition: all .15s;
    letter-spacing: -.5px;
}
.zc-menu-trigger:hover { background: #F1F5F9; color: #0a1628; }
.zc-menu-dropdown {
    display: none;
    position: absolute;
    right: 0;
    top: calc(100% + 4px);
    background: #fff;
    border: 1px solid #E2E8F0;
    border-radius: 8px;
    box-shadow: 0 8px 24px rgba(0,0,0,.12);
    z-index: 200;
    min-width: 140px;
    overflow: hidden;
}
.zc-menu-dropdown.open { display: block; }
.zc-menu-item {
    display: flex;
    align-items: center;
    gap: 8px;
    width: 100%;
    padding: 9px 14px;
    font-size: 13px;
    font-family: inherit;
    color: #0a1628;
    background: none;
    border: none;
    cursor: pointer;
    text-decoration: none;
    text-align: left;
    transition: background .1s;
    box-sizing: border-box;
    white-space: nowrap;
}
.zc-menu-item:hover { background: #F8FAFC; }
.zc-menu-item.danger { color: #EF4444; }
.zc-menu-item.danger:hover { background: #FEF2F2; }
.zc-menu-sep { height: 1px; background: #F1F5F9; margin: 2px 0; }

/* Disabled play button (no recording) */
.zc-rec-play:disabled, .zc-vm-play:disabled {
    background: #F1F5F9;
    color: #CBD5E1;
    cursor: not-allowed;
    opacity: 1;
}
.zc-rec-play:disabled:hover, .zc-vm-play:disabled:hover {
    background: #F1F5F9;
    color: #CBD5E1;
}

/* ─── Empty State ─── */
.zc-empty {
    text-align: center;
    padding: 48px 20px;
    color: #64748B;
    font-size: 14px;
}
.zc-empty-icon  { font-size: 32px; margin-bottom: 12px; display: block; }
.zc-empty-title { font-size: 16px; font-weight: 600; color: #0a1628; margin-bottom: 6px; display: block; }
.zc-hint { font-size: 12px; color: #64748B; margin: 4px 0 0; }

/* ─── Primary Button ─── */
.zc-btn-primary {
    background: #1D9E75;
    color: #fff;
    border: 0;
    padding: 10px 20px;
    border-radius: 8px;
    cursor: pointer;
    font-weight: 600;
    font-family: inherit;
    font-size: 14px;
    transition: background .15s;
}
.zc-btn-primary:hover { background: #0d9e8e; }
.zc-btn-primary:disabled { opacity: .5; cursor: not-allowed; }

#zc-reply-status { font-size: 13px; }
#zc-fax-status   { margin-left: 12px; font-size: 13px; }
.zc-status-ok  { color: #10B981; }
.zc-status-err { color: #EF4444; }

/* ─── DID (From) Selector Bar ─── */
.zc-did-bar {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 6px 0 8px;
}
.zc-did-bar-label {
    font-size: 11px;
    font-weight: 600;
    color: #64748B;
    text-transform: uppercase;
    letter-spacing: .04em;
    flex-shrink: 0;
}
.zc-did-select {
    -webkit-appearance: none;
    appearance: none;
    font-size: 13px;
    font-weight: 500;
    font-family: inherit;
    color: #0a1628;
    background: transparent;
    border: none;
    padding: 0 18px 0 0;
    cursor: pointer;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 24 24' fill='none' stroke='%2364748B' stroke-width='2.5'%3E%3Cpolyline points='6 9 12 15 18 9'/%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: right 2px center;
}
.zc-did-select:focus { outline: none; }


/* --- Fax Address Card (From+To) --- */
.zf-addr-card{border:1px solid #e6e9ee;border-radius:8px;overflow:hidden;margin-bottom:16px;background:#fff;}
.zf-addr-row{display:flex;align-items:center;padding:9px 12px;gap:10px;}
.zf-addr-row+.zf-addr-row{border-top:1px solid #f1f5f9;}
.zf-addr-label{font-size:11px;font-weight:600;color:#64748B;width:44px;flex-shrink:0;text-transform:uppercase;letter-spacing:.05em;white-space:nowrap;}
.zf-addr-did{-webkit-appearance:none;appearance:none;font-size:13px;font-weight:500;font-family:inherit;color:#0a1628;background:transparent;border:none;padding:0 18px 0 0;cursor:pointer;background-image:url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 24 24' fill='none' stroke='%2364748B' stroke-width='2.5'%3E%3Cpolyline points='6 9 12 15 18 9'/%3E%3C/svg%3E");background-repeat:no-repeat;background-position:right 2px center;outline:none;}
.zf-addr-input{flex:1;border:none;outline:none;font-size:13px;font-family:inherit;color:#0a1628;background:transparent;padding:0;min-width:0;}
.zf-addr-input::placeholder{color:#9ca3af;}
/* ─── SMS Two-column Layout ─── */
.zc-sms-wrap { display: flex; height: 600px; }

.zc-threads-col {
    width: 300px;
    min-width: 300px;
    border-right: 1px solid #E2E8F0;
    overflow-y: auto;
    background: #FAFBFC;
    display: flex;
    flex-direction: column;
}

.zc-new-msg-bar {
    padding: 10px 12px;
    border-bottom: 1px solid #E2E8F0;
    background: #fff;
    flex-shrink: 0;
}
.zc-btn-compose {
    width: 100%;
    background: #1D9E75;
    color: #fff;
    border: 0;
    border-radius: 8px;
    padding: 8px 12px;
    font-size: 13px;
    font-weight: 600;
    cursor: pointer;
    font-family: inherit;
    transition: background .15s;
}
.zc-btn-compose:hover { background: #0d9e8e; }

.zc-compose-form {
    padding: 10px 12px;
    border-bottom: 1px solid #E2E8F0;
    background: #F9FAFB;
    flex-shrink: 0;
}
.zc-compose-form input[type=text],
.zc-compose-form textarea {
    width: 100%;
    padding: 8px 10px;
    border: 1px solid #E2E8F0;
    border-radius: 6px;
    font-size: 13px;
    box-sizing: border-box;
    margin-bottom: 8px;
    font-family: inherit;
    color: #0a1628;
}
.zc-compose-form textarea { resize: none; }
.zc-compose-form input:focus, .zc-compose-form textarea:focus { outline: none; border-color: #1D9E75; }
.zc-compose-actions { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; }

.zc-btn-cancel {
    background: none;
    border: 1px solid #E2E8F0;
    border-radius: 6px;
    padding: 6px 12px;
    font-size: 13px;
    cursor: pointer;
    color: #64748B;
    font-family: inherit;
    transition: background .15s;
}
.zc-btn-cancel:hover { background: #F1F5F9; }
#zc-compose-status { font-size: 12px; flex-basis: 100%; margin-top: 2px; }

.zc-threads-list { flex: 1; }
.zc-thr-empty { text-align: center; color: #94A3B8; padding: 32px 16px; font-size: 14px; }

.zc-thread-item {
    padding: 14px 16px;
    border-bottom: 1px solid #F1F5F9;
    cursor: pointer;
    transition: background .1s;
    position: relative;
}
.zc-thread-del {
    position: absolute;
    top: 8px;
    right: 8px;
    width: 18px;
    height: 18px;
    background: #EF4444;
    color: #fff;
    border: none;
    border-radius: 50%;
    font-size: 11px;
    line-height: 18px;
    text-align: center;
    cursor: pointer;
    padding: 0;
    display: none;
    z-index: 5;
}
.zc-thread-item:hover .zc-thread-del { display: block; }
.zc-thread-del:hover { background: #DC2626; }
.zc-thread-item:hover { background: #F8FAFC; }
.zc-thread-item.active {
    background: #F0FDFA;
    border-left: 3px solid #1D9E75;
    padding-left: 13px;
}

.zc-thr-top { display: flex; justify-content: space-between; align-items: center; margin-bottom: 4px; }
.zc-thr-peer { font-size: 14px; font-weight: 600; color: #0a1628; }
.zc-thr-time { font-size: 11px; color: #94A3B8; white-space: nowrap; margin-left: 8px; }
.zc-thr-bottom { display: flex; justify-content: space-between; align-items: center; }
.zc-thr-preview { font-size: 13px; color: #64748B; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; max-width: 200px; }

.zc-unread-badge {
    background: #2563eb;
    color: #fff;
    font-size: 10px;
    font-weight: 700;
    border-radius: 10px;
    min-width: 18px;
    height: 18px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 0 5px;
    margin-left: 6px;
    flex-shrink: 0;
    vertical-align: middle;
}

.zc-conv-col { flex: 1; display: flex; flex-direction: column; overflow: hidden; }
.zc-conv-header {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 12px 16px;
    border-bottom: 1px solid #E2E8F0;
    background: #F9FAFB;
    flex-shrink: 0;
}
.zc-back-btn {
    display: none;
    background: none;
    border: 1px solid #E2E8F0;
    border-radius: 6px;
    padding: 4px 10px;
    font-size: 13px;
    cursor: pointer;
    color: #0a1628;
    font-family: inherit;
}
.zc-back-btn:hover { background: #F1F5F9; }
.zc-conv-peer { font-size: 15px; font-weight: 600; color: #0a1628; }
.zc-conv-messages { flex: 1; overflow-y: auto; padding: 16px; display: flex; flex-direction: column; gap: 8px; }
.zc-conv-empty { color: #94A3B8; text-align: center; margin-top: 40px; font-size: 14px; }

/* Bubbles */
.zc-bubble { max-width: 72%; display: flex; flex-direction: column; position: relative; }
.zc-bubble.in  { align-self: flex-start; }
.zc-bubble.out { align-self: flex-end; }
.zc-bubble-text {
    padding: 10px 14px;
    border-radius: 18px;
    font-size: 14px;
    line-height: 1.5;
    white-space: pre-wrap;
    word-break: break-word;
}
.zc-bubble.in  .zc-bubble-text { background: #F1F5F9; color: #0a1628; border-bottom-left-radius: 4px; }
.zc-bubble.out .zc-bubble-text { background: #1D9E75; color: #fff; border-bottom-right-radius: 4px; }
.zc-bubble-time { font-size: 11px; color: #94A3B8; margin-top: 3px; padding: 0 4px; }
.zc-bubble.out .zc-bubble-time { text-align: right; }
.zc-sending { color: #94A3B8; font-style: italic; }
.zc-bubble-sender { font-size: 10px; opacity: .7; margin-left: 6px; }

.zc-conv-reply {
    padding: 12px 16px;
    border-top: 1px solid #E2E8F0;
    background: #fff;
    flex-shrink: 0;
}
.zc-conv-reply textarea {
    width: 100%;
    padding: 10px 12px;
    border: 1px solid #E2E8F0;
    border-radius: 8px;
    font-size: 14px;
    resize: none;
    box-sizing: border-box;
    font-family: inherit;
    margin-bottom: 8px;
    color: #0a1628;
}
.zc-conv-reply textarea:focus { outline: none; border-color: #1D9E75; box-shadow: 0 0 0 3px rgba(20,184,166,.12); }
.zc-reply-actions { display: flex; align-items: center; gap: 10px; }

/* SMS delete */
.zc-sms-delete {
    position: absolute;
    top: -7px;
    right: -7px;
    width: 18px;
    height: 18px;
    background: #EF4444;
    color: #fff;
    border: none;
    border-radius: 50%;
    font-size: 13px;
    line-height: 18px;
    text-align: center;
    cursor: pointer;
    padding: 0;
    display: none;
    z-index: 10;
}
.zc-bubble.in .zc-sms-delete { left: -7px; right: auto; }
.zc-bubble:hover .zc-sms-delete { display: block; }
.zc-sms-delete:hover { background: #DC2626; }

/* MMS media */
.zc-bubble-media { margin-bottom: 4px; }
.zc-mms-img { max-width: 200px; max-height: 200px; border-radius: 8px; cursor: pointer; display: block; }
.zc-mms-pdf {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    font-size: 13px;
    color: #1D9E75;
    text-decoration: none;
    padding: 4px 8px;
    background: rgba(20,184,166,.08);
    border-radius: 6px;
}
.zc-mms-pdf:hover { text-decoration: underline; }
.zc-mms-uploading { font-size: 12px; color: #94A3B8; font-style: italic; }

/* Attach button */
.zc-btn-attach {
    background: none;
    border: 1px solid #E2E8F0;
    border-radius: 6px;
    padding: 5px 9px;
    font-size: 16px;
    cursor: pointer;
    line-height: 1;
    color: #64748B;
    flex-shrink: 0;
    font-family: inherit;
    transition: all .15s;
}
.zc-btn-attach:hover { border-color: #1D9E75; color: #1D9E75; }
.zc-attach-name { font-size: 12px; color: #64748B; max-width: 120px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; flex-shrink: 1; }

/* ─── Login ─── */
.zarcall-login-wrap {
    max-width: 400px;
    margin: 0 auto;
    padding: 36px 32px 44px;
    border: 1px solid #E2E8F0;
    border-radius: 12px;
    background: #fff;
    box-shadow: 0 4px 24px rgba(15,23,42,.08);
    box-sizing: border-box;
}
.zarcall-login-wrap h2 { margin: 0 0 22px; font-size: 22px; font-weight: 700; color: #0a1628; }
.zc-login-label { display: block; font-size: 13px; font-weight: 600; color: #0a1628; margin-bottom: 5px; }
.zc-login-btn { width: 100%; padding: 11px; font-size: 15px; justify-content: center; }
.zc-login-error  { background: #FEF2F2; border: 1px solid #FECACA; color: #B91C1C; padding: 10px 14px; border-radius: 8px; margin-bottom: 18px; font-size: 14px; }
.zc-login-success { background: #F0FDF4; border: 1px solid #BBF7D0; color: #15803D; padding: 10px 14px; border-radius: 8px; margin-bottom: 18px; font-size: 14px; }
.zc-login-footer { margin-top: 18px; text-align: center; font-size: 13px; }
.zc-login-footer a { color: #1D9E75; text-decoration: none; }
.zc-login-footer a:hover { text-decoration: underline; }
.zarcall-notice { max-width: 600px; margin: 0 auto; padding: 20px; background: #FEF3C7; border: 1px solid #FDE68A; border-radius: 8px; }

/* ─── Autocomplete ─── */
.zc-ac-wrap { position: relative; margin-bottom: 8px; }
.zc-ac-wrap input { margin-bottom: 0; width: 100%; }
.zc-ac-dropdown {
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    background: #fff;
    border: 1px solid #E2E8F0;
    border-radius: 0 0 8px 8px;
    box-shadow: 0 8px 24px rgba(0,0,0,.10);
    z-index: 100;
    max-height: 200px;
    overflow-y: auto;
}
.zc-ac-item {
    padding: 9px 12px;
    font-size: 13px;
    cursor: pointer;
    display: flex;
    justify-content: space-between;
    align-items: center;
    border-bottom: 1px solid #F1F5F9;
    color: #0a1628;
    transition: background .1s;
}
.zc-ac-item:last-child { border-bottom: 0; }
.zc-ac-item:hover { background: #F8FAFC; }
.zc-ac-phone { font-size: 11px; color: #94A3B8; }

/* Contact button in conv header */
.zc-conv-header-info { flex: 1; display: flex; flex-direction: column; min-width: 0; }
.zc-conv-peer-phone { font-size: 12px; color: #94A3B8; margin-top: 1px; }
.zc-contact-btn {
    background: none;
    border: 1px solid #1D9E75;
    color: #1D9E75;
    border-radius: 6px;
    padding: 4px 10px;
    font-size: 12px;
    cursor: pointer;
    white-space: nowrap;
    flex-shrink: 0;
    font-family: inherit;
    transition: all .15s;
}
.zc-contact-btn:hover { background: #1D9E75; color: #fff; }

/* ─── Modals ─── */
.zc-modal-overlay {
    position: fixed;
    inset: 0;
    background: rgba(0,0,0,.45);
    z-index: 9999;
    display: flex;
    align-items: center;
    justify-content: center;
}
.zc-modal {
    background: #fff;
    border-radius: 12px;
    width: 100%;
    max-width: 420px;
    box-shadow: 0 20px 60px rgba(0,0,0,.20);
    overflow: hidden;
}
.zc-modal-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 16px 20px;
    background: #0a1628;
    color: #fff;
}
.zc-modal-header h3 { margin: 0; font-size: 16px; font-weight: 600; }
.zc-modal-close { background: none; border: 0; color: #fff; font-size: 22px; cursor: pointer; line-height: 1; opacity: .7; padding: 0; }
.zc-modal-close:hover { opacity: 1; }
.zc-modal-body { padding: 20px; }
.zc-modal-field { margin-bottom: 14px; }
.zc-modal-field label { display: block; font-size: 13px; font-weight: 500; margin-bottom: 5px; color: #0a1628; }
.zc-modal-field .zc-input { width: 100%; box-sizing: border-box; }
.zc-modal-status { font-size: 13px; min-height: 18px; }
.zc-modal-footer {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 14px 20px;
    border-top: 1px solid #E2E8F0;
    background: #F9FAFB;
}

/* Confirm delete modal */
.zc-confirm-body { padding: 28px 24px; text-align: center; }
.zc-confirm-icon  { font-size: 36px; margin-bottom: 14px; display: block; }
.zc-confirm-title { font-size: 17px; font-weight: 700; color: #0a1628; margin: 0 0 8px; }
.zc-confirm-desc  { font-size: 14px; color: #64748B; margin: 0 0 24px; line-height: 1.5; }
.zc-confirm-actions { display: flex; gap: 10px; justify-content: center; }
.zc-btn-danger-confirm {
    background: #EF4444;
    color: #fff;
    border: none;
    border-radius: 8px;
    padding: 10px 20px;
    font-size: 14px;
    font-weight: 600;
    cursor: pointer;
    font-family: inherit;
    transition: background .15s;
}
.zc-btn-danger-confirm:hover { background: #DC2626; }

/* ─── Fax Tab ─── */
.zc-pane h3 { margin-top: 0; color: #0a1628; }
.zc-compose {
    background: #F8FAFC;
    padding: 16px;
    border-radius: 8px;
    margin-bottom: 24px;
    border: 1px solid #E2E8F0;
}
.zc-compose input[type=text], .zc-compose textarea {
    width: 100%;
    padding: 10px 12px;
    border: 1px solid #E2E8F0;
    border-radius: 6px;
    margin-bottom: 10px;
    font-size: 14px;
    box-sizing: border-box;
    font-family: inherit;
    color: #0a1628;
}
.zc-compose input[type=file] { margin-bottom: 10px; }

.zc-dir-in  { color: #10B981; font-size: 16px; font-weight: 700; line-height: 1; }
.zc-dir-out { color: #3B82F6; font-size: 16px; font-weight: 700; line-height: 1; }

.zc-cover-note { font-size: 15px; color: #94A3B8; cursor: pointer; display: inline-block; vertical-align: middle; margin-left: 4px; transition: color .12s; user-select: none; }
.zc-cover-note:hover { color: #1D9E75; }
.zc-cover-popover {
    position: absolute;
    background: #0a1628;
    color: #fff;
    padding: 10px 14px;
    border-radius: 8px;
    max-width: 280px;
    font-size: 13px;
    line-height: 1.5;
    box-shadow: 0 8px 24px rgba(0,0,0,.20);
    white-space: pre-wrap;
    word-break: break-word;
    z-index: 1000;
}
.zc-cover-popover::before {
    content: '';
    position: absolute;
    top: -6px;
    left: 12px;
    width: 0;
    height: 0;
    border-left: 6px solid transparent;
    border-right: 6px solid transparent;
    border-bottom: 6px solid #0a1628;
}
.zc-cover-popover-right::before { left: auto; right: 12px; }

.zc-fax-delete { color: #94A3B8; text-decoration: none; font-size: 18px; line-height: 1; padding: 2px 6px; transition: color .15s; display: inline-block; vertical-align: middle; }
.zc-fax-delete:hover { color: #EF4444; text-decoration: none; }
.zc-fax-actions { text-align: right; width: 32px; padding-right: 6px !important; }
.zc-fax-table tbody tr:hover td { background: #F8FAFC; }

.zc-fax-ok   { color: #10B981; font-weight: 600; }
.zc-fax-fail { color: #EF4444; }
.zc-fax-refresh-indicator { font-size: 10px; color: #1D9E75; margin-left: 6px; }

.zc-fax-from-line { font-size: 13px; color: #94A3B8; margin: 0 0 10px; }
.zc-fax-no-number { background: #FEF3C7; border: 1px solid #FDE68A; border-radius: 8px; padding: 14px 16px; font-size: 14px; }
.zc-fax-no-number p { margin: 0 0 6px; }
.zc-fax-no-number p:last-child { margin: 0; }
.zc-cover-icon { cursor: help; font-size: 14px; margin-left: 4px; vertical-align: middle; }

/* Fax icon buttons */
.zc-fax-btngroup { display: inline-flex; align-items: center; gap: 8px; }
.zc-fax-ibtn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 32px;
    height: 32px;
    border-radius: 6px;
    text-decoration: none;
    transition: all .15s;
    flex-shrink: 0;
    font-size: 15px;
    line-height: 1;
}
.zc-fax-ibtn:hover { opacity: .82; transform: translateY(-1px); }
.zc-fax-ibtn-preview { background: #1D9E75; color: #fff; }
.zc-fax-ibtn-dl { background: transparent; color: #64748B; border: 1px solid #E2E8F0; }
.zc-fax-ibtn-dl:hover { background: #F1F5F9; color: #0a1628; }
.zc-pdf-expired { color: #94A3B8; font-size: 12px; font-style: italic; }
.zc-pdf-dl:hover { text-decoration: underline; }

/* ─── Thread contact name ─── */
.zc-thr-phone { font-size: 11px; color: #94A3B8; display: block; margin-top: 1px; }

/* ─── Contacts tab ─── */
.zc-contacts-wrap h2 { margin: 0 0 16px; color: #0a1628; font-size: 20px; }
.zc-contacts-search-bar { display: flex; gap: 10px; align-items: center; margin-bottom: 16px; flex-wrap: wrap; }
.zc-contacts-table-wrap { overflow-x: auto; }
.zc-contacts-table .zc-contact-actions { display: flex; gap: 6px; }

/* ─── Team Tab ─── */
.zc-team-list { display: flex; flex-direction: column; gap: 0; margin-top: 4px; }
.zc-team-member {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 14px 0;
    border-bottom: 1px solid #F1F5F9;
    gap: 12px;
    transition: all .15s;
}
.zc-team-member:last-child { border-bottom: 0; }
.zc-team-info { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; }
.zc-team-role-badge {
    display: inline-block;
    font-size: 11px;
    font-weight: 600;
    padding: 2px 8px;
    border-radius: 999px;
    text-transform: capitalize;
}
.zc-team-role-badge.zc-role-owner { background: #E1FCEF; color: #10B981; border: 1px solid #A7F3D0; }
.zc-team-role-badge.zc-role-agent { background: #F1F5F9; color: #64748B; border: 1px solid #E2E8F0; }
.zc-team-name  { font-weight: 600; font-size: 14px; color: #0a1628; }
.zc-team-email { font-size: 13px; color: #64748B; }
.zc-team-you   { font-size: 11px; background: #0a1628; color: #fff; padding: 1px 7px; border-radius: 999px; }
.zc-team-hint  { font-size: 13px; color: #94A3B8; margin-top: 16px; }

/* Extension status dots */
.zc-ext-dot     { font-size: 9px; margin-right: 3px; vertical-align: middle; line-height: 1; }
.zc-ext-online  { color: #10B981; }
.zc-ext-offline { color: #CBD5E1; }

/* ─── Calls / Recordings / Voicemail sections ─── */
.zc-calls-section, .zc-voicemail-section, .zc-recordings-section { padding: 4px 0; }
.zc-dir-local  { color: #94A3B8; font-size: 15px; }
.zc-call-ok    { color: #10B981; font-weight: 600; font-size: 12px; }
.zc-call-missed { color: #EF4444; font-weight: 600; font-size: 12px; }
.zc-call-other { color: #94A3B8; font-size: 12px; }
.zc-call-rec   { color: #1D9E75; font-size: 10px; }

.zc-vm-row-new { font-weight: 600; }
.zc-vm-new { color: #1D9E75; font-size: 8px; vertical-align: middle; }
.zc-recordings-table td:last-child, .zc-vm-table td:last-child { width: 80px; }

/* ─── Admin Portal ─── */
.zarcall-admin-portal .zc-content { min-height: 500px; }
.zc-admin-head { display: flex; align-items: center; justify-content: space-between; margin-bottom: 20px; gap: 12px; }
.zc-admin-head h2 { margin: 0; color: #0a1628; font-size: 20px; font-weight: 700; }
.zc-admin-notice { padding: 12px 16px; border-radius: 8px; margin-bottom: 16px; font-size: 14px; }
.zc-admin-notice p { margin: 0; }
.zc-admin-notice-ok  { background: #DCFCE7; color: #15803D; border: 1px solid #BBF7D0; }
.zc-admin-notice-err { background: #FEF2F2; color: #B91C1C; border: 1px solid #FECACA; }

.zc-admin-table-wrap { overflow-x: auto; }
.zc-admin-table th, .zc-admin-table td { white-space: nowrap; }
.zc-admin-actions { display: flex; gap: 5px; align-items: center; flex-wrap: wrap; }

.zc-btn-sm {
    display: inline-block;
    padding: 5px 10px;
    font-size: 12px;
    border: 1px solid #E2E8F0;
    border-radius: 6px;
    text-decoration: none;
    color: #0a1628;
    background: #fff;
    cursor: pointer;
    white-space: nowrap;
    line-height: 1.4;
    font-family: inherit;
    transition: all .15s;
}
.zc-btn-sm:hover { background: #F1F5F9; border-color: #1D9E75; color: #1D9E75; text-decoration: none; }
.zc-btn-danger { color: #B91C1C; border-color: #FECACA; }
.zc-btn-danger:hover { background: #FEF2F2; border-color: #EF4444; color: #EF4444; }

.zc-btn-back { font-size: 14px; color: #1D9E75; text-decoration: none; white-space: nowrap; }
.zc-btn-back:hover { text-decoration: underline; }

.zc-admin-form { max-width: 700px; }
.zc-form-section {
    font-weight: 600;
    font-size: 12px;
    text-transform: uppercase;
    letter-spacing: .05em;
    color: #64748B;
    border-bottom: 1px solid #E2E8F0;
    padding-bottom: 4px;
    margin: 24px 0 12px;
    display: block;
}
.zc-admin-form .zc-form-section:first-of-type { margin-top: 0; }
.zc-form-optional { font-weight: 400; font-size: 11px; text-transform: none; color: #94A3B8; }
.zc-form-grid { display: grid; gap: 12px; }
.zc-form-row { display: grid; grid-template-columns: 190px 1fr; gap: 8px 12px; align-items: start; }
.zc-form-label { font-size: 14px; font-weight: 500; color: #0a1628; padding-top: 8px; line-height: 1.4; }
.zc-required { color: #EF4444; }
.zc-form-hint { font-size: 12px; color: #64748B; display: block; margin-top: 4px; }
.zc-form-static { font-size: 14px; color: #334155; padding-top: 8px; display: block; }

.zc-input, .zc-select {
    width: 100%;
    padding: 8px 12px;
    border: 1px solid #E2E8F0;
    border-radius: 6px;
    font-size: 14px;
    font-family: inherit;
    box-sizing: border-box;
    color: #0a1628;
    background: #fff;
    transition: border-color .15s, box-shadow .15s;
}
.zc-input:focus, .zc-select:focus { outline: none; border-color: #1D9E75; box-shadow: 0 0 0 3px rgba(20,184,166,.12); }

.zc-checkbox-group { display: flex; flex-wrap: wrap; gap: 16px; padding-top: 8px; font-size: 14px; }
.zc-radio-group { display: flex; flex-direction: column; gap: 6px; padding-top: 6px; font-size: 14px; }
.zc-form-actions { margin-top: 28px; display: flex; align-items: center; gap: 16px; padding-bottom: 12px; }
.zc-btn-cancel-link { font-size: 14px; color: #64748B; text-decoration: none; }
.zc-btn-cancel-link:hover { color: #0a1628; text-decoration: underline; }

/* Section headings in calls/fax/recordings/voicemail */
.zc-section-head {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 16px;
}
.zc-section-title {
    font-size: 17px;
    font-weight: 700;
    color: #0a1628;
    margin: 0;
}

/* ─── Responsive ─── */
@media (max-width: 767px) {
    .zc-summary-cards { grid-template-columns: 1fr 1fr; }
    .zc-sms-wrap { flex-direction: column; height: auto; }
    .zc-threads-col { width: 100%; min-width: 0; border-right: none; border-bottom: 1px solid #E2E8F0; height: auto; max-height: 50vh; overflow-y: auto; }
    .zc-conv-col { height: 100vh; max-height: 70vh; }
    .zc-back-btn { display: inline-block; }
    .zc-conv-messages { max-height: calc(70vh - 110px); }
    .zc-bubble { max-width: 90%; }
    .zc-form-row { grid-template-columns: 1fr; gap: 4px; }
    .zc-admin-table td, .zc-admin-table th { font-size: 12px; padding: 8px 6px; }
    .zc-admin-actions { flex-wrap: wrap; }
    .zc-admin-head { flex-wrap: wrap; }
}
@media (max-width: 600px) {
    .zc-summary-cards { grid-template-columns: 1fr 1fr; }
    .zc-fax-table th:nth-child(4), .zc-fax-table td:nth-child(4),
    .zc-fax-table th:nth-child(6), .zc-fax-table td:nth-child(6) { display: none; }
    .zc-fax-table th, .zc-fax-table td { padding: 8px 5px; font-size: 12px; }
    .zc-fax-table td:nth-child(1) { white-space: nowrap; font-size: 11px; }
    .zc-fax-table td:nth-child(3) { max-width: 90px; word-break: break-all; font-size: 11px; }
    .zc-fax-btngroup { gap: 5px; }
    .zc-fax-ibtn { width: 28px; height: 28px; font-size: 13px; }
    .zc-fax-actions { padding-right: 4px !important; }
    .zc-calls-table th:nth-child(4), .zc-calls-table td:nth-child(4) { display: none; }
    .zc-calls-table th, .zc-calls-table td { padding: 8px 8px; font-size: 12px; }
    .zc-recordings-table th:nth-child(3), .zc-recordings-table td:nth-child(3),
    .zc-recordings-table th:nth-child(4), .zc-recordings-table td:nth-child(4) { display: none; }
    .zc-vm-table th:nth-child(3), .zc-vm-table td:nth-child(3) { display: none; }
    .zc-player { gap: 8px; padding: 8px 12px; }
}


/* === Calls v4.0 Redesign === */

.zc-calls-section .zc-summary-card {
    display: flex;
    align-items: center;
    gap: 14px;
    padding: 16px;
}
.zc-card-icon {
    width: 52px; min-width: 52px; height: 52px;
    border-radius: 50%;
    background: #10B981;
    display: flex; align-items: center; justify-content: center;
}
.zc-card-body { flex: 1; min-width: 0; }
.zc-calls-section .zc-card-metric { font-size: 28px; font-weight: 700; color: #0a1628; line-height: 1.1; margin-bottom: 0; }
.zc-calls-section .zc-card-label  { font-size: 13px; color: #64748B; font-weight: 500; margin-top: 3px; }

.zc-calls-filter-bar {
    display: flex; align-items: center; gap: 10px; margin-bottom: 18px; flex-wrap: wrap;
}
.zc-filter-search { position: relative; flex: 1; min-width: 180px; max-width: 300px; }
.zc-filter-search input {
    width: 100%; box-sizing: border-box;
    padding: 8px 12px 8px 34px;
    border: 1px solid #E2E8F0; border-radius: 8px;
    font-size: 13px; font-family: inherit; color: #0a1628; background: #fff;
    transition: border-color .15s;
}
.zc-filter-search input:focus { outline: none; border-color: #1D9E75; }
.zc-filter-search-icon {
    position: absolute; left: 10px; top: 50%; transform: translateY(-50%);
    color: #94A3B8; pointer-events: none; display: flex;
}
.zc-filter-right {
    display: flex; align-items: center; gap: 8px; flex-wrap: wrap; margin-left: auto;
}
.zc-filter-date {
    padding: 7px 10px; border: 1px solid #E2E8F0; border-radius: 8px;
    font-size: 13px; font-family: inherit; color: #0a1628; background: #fff;
}
.zc-filter-date:focus { outline: none; border-color: #1D9E75; }
.zc-filter-select {
    padding: 7px 28px 7px 10px; border: 1px solid #E2E8F0; border-radius: 8px;
    font-size: 13px; font-family: inherit; color: #0a1628; background: #fff;
    appearance: none; -webkit-appearance: none; cursor: pointer;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 24 24' fill='none' stroke='%2364748B' stroke-width='2.5'%3E%3Cpolyline points='6 9 12 15 18 9'/%3E%3C/svg%3E");
    background-repeat: no-repeat; background-position: right 8px center;
}
.zc-filter-select:focus { outline: none; border-color: #1D9E75; }
.zc-filter-export {
    padding: 7px 14px; border: 1px solid #E2E8F0; border-radius: 8px;
    font-size: 13px; font-family: inherit; color: #0a1628; background: #fff;
    cursor: pointer; display: inline-flex; align-items: center; gap: 6px;
    transition: all .15s; white-space: nowrap;
}
.zc-filter-export:hover { background: #F8FAFC; border-color: #94A3B8; }

.zc-rec-dl-btn {
    width: 32px; height: 32px; border-radius: 6px; border: 1px solid #E2E8F0;
    cursor: pointer; display: inline-flex; align-items: center; justify-content: center;
    flex-shrink: 0; background: transparent; color: #64748B;
    transition: all .15s; text-decoration: none; padding: 0;
}
.zc-rec-dl-btn:hover { background: #F1F5F9; color: #0a1628; }
.zc-rec-del-btn {
    width: 32px; height: 32px; border-radius: 6px; border: 1px solid #FECACA;
    cursor: pointer; display: inline-flex; align-items: center; justify-content: center;
    flex-shrink: 0; background: transparent; color: #EF4444;
    transition: all .15s; padding: 0;
}
.zc-rec-del-btn:hover { background: #FEE2E2; border-color: #EF4444; }
.zc-rec-del-btn:disabled { opacity: .3; cursor: not-allowed; }

.zc-exp-row > td {
    padding: 0 !important; border-bottom: 2px solid #E2E8F0 !important; background: #fff !important;
}
.zc-exp-inner {
    display: flex; align-items: center; gap: 20px;
    padding: 14px 20px; background: #F8FFFB; border-left: 3px solid #1D9E75;
}
.zc-exp-info { flex-shrink: 0; min-width: 150px; max-width: 220px; }
.zc-exp-label { font-size: 11px; font-weight: 700; color: #1D9E75; text-transform: uppercase; letter-spacing: .05em; margin-bottom: 4px; }
.zc-exp-peer  { font-size: 15px; font-weight: 600; color: #0a1628; margin-bottom: 3px; }
.zc-exp-meta  { font-size: 11px; color: #94A3B8; line-height: 1.5; }
.zc-wf-player { flex: 1; display: flex; align-items: center; gap: 12px; min-width: 0; }
.zc-wf-playbtn {
    width: 38px; height: 38px; border-radius: 50%; border: none;
    background: #10B981; color: #fff;
    display: flex; align-items: center; justify-content: center;
    cursor: pointer; flex-shrink: 0; padding: 0; transition: background .15s;
}
.zc-wf-playbtn:hover { background: #059669; }
.zc-wf-canvas { flex: 1; height: 48px; cursor: pointer; min-width: 80px; display: block; }
.zc-wf-time {
    font-size: 12px; color: #64748B; font-variant-numeric: tabular-nums;
    white-space: nowrap; flex-shrink: 0; min-width: 78px; text-align: center;
}
.zc-wf-dl {
    width: 32px; height: 32px; border-radius: 6px; border: 1px solid #E2E8F0;
    display: inline-flex; align-items: center; justify-content: center;
    text-decoration: none; color: #64748B; flex-shrink: 0; transition: all .15s;
}
.zc-wf-dl:hover { background: #F1F5F9; color: #0a1628; text-decoration: none; }

.zc-pagination {
    display: flex; align-items: center; justify-content: space-between;
    padding: 16px 0 4px; font-size: 13px; color: #64748B; flex-wrap: wrap; gap: 10px;
}
.zc-pagination-pages { display: flex; align-items: center; gap: 3px; }
.zc-page-btn {
    min-width: 32px; height: 32px; padding: 0 6px;
    border: 1px solid #E2E8F0; border-radius: 6px;
    background: #fff; color: #0a1628;
    font-size: 13px; font-family: inherit; cursor: pointer;
    display: inline-flex; align-items: center; justify-content: center;
    transition: all .15s;
}
.zc-page-btn:hover:not(:disabled):not(.active) { background: #F1F5F9; }
.zc-page-btn.active { background: #10B981; color: #fff; border-color: #10B981; }
.zc-page-btn:disabled { opacity: .4; cursor: not-allowed; pointer-events: none; }
.zc-page-ellipsis { padding: 0 4px; color: #94A3B8; font-size: 13px; line-height: 32px; }
.zc-per-page {
    padding: 6px 24px 6px 8px; border: 1px solid #E2E8F0; border-radius: 6px;
    font-size: 13px; font-family: inherit; color: #0a1628; background: #fff; cursor: pointer;
    appearance: none; -webkit-appearance: none;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 24 24' fill='none' stroke='%2364748B' stroke-width='2.5'%3E%3Cpolyline points='6 9 12 15 18 9'/%3E%3C/svg%3E");
    background-repeat: no-repeat; background-position: right 6px center;
}
.zc-per-page:focus { outline: none; }
.zc-pagination-right { display: flex; align-items: center; gap: 8px; }

@media (max-width: 767px) {
    .zc-calls-filter-bar { flex-direction: column; align-items: stretch; }
    .zc-filter-search { max-width: none; }
    .zc-filter-right { margin-left: 0; }
    .zc-exp-inner { flex-direction: column; align-items: flex-start; gap: 12px; }
    .zc-exp-info { min-width: 0; }
    .zc-wf-player { width: 100%; }
}
@media (max-width: 600px) {
    .zc-pagination { flex-direction: column; align-items: flex-start; }
}


/* === Filter bar fix v2 — single row === */
.zc-calls-filter-bar {
    flex-wrap: nowrap !important;
    border: 1px solid #E2E8F0;
    border-radius: 10px;
    padding: 4px 12px 4px 0;
    background: #fff;
    margin-bottom: 20px;
    gap: 0 !important;
    align-items: stretch;
}
.zc-filter-search {
    flex: 1;
    max-width: none !important;
    min-width: 120px;
    display: flex;
    align-items: center;
    padding-right: 0;
}
.zc-filter-search input {
    border: none !important;
    border-radius: 0 !important;
    padding: 8px 8px 8px 34px !important;
    background: transparent !important;
    box-shadow: none !important;
}
.zc-filter-search input:focus {
    border: none !important;
    box-shadow: none !important;
}
.zc-filter-divider {
    width: 1px;
    background: #E2E8F0;
    flex-shrink: 0;
    margin: 8px 10px;
}
.zc-filter-right {
    flex-wrap: nowrap !important;
    gap: 6px !important;
    margin-left: 0 !important;
    align-items: center;
}
.zc-filter-date {
    max-width: 118px !important;
    min-width: 80px !important;
    font-size: 12px !important;
    padding: 5px 4px !important;
    color-scheme: light;
}
.zc-filter-select {
    min-width: 108px !important;
    font-size: 12px !important;
    padding: 5px 22px 5px 8px !important;
}
.zc-filter-export {
    padding: 5px 10px !important;
    font-size: 12px !important;
    white-space: nowrap;
}
@media (max-width: 767px) {
    .zc-calls-filter-bar { flex-wrap: wrap !important; padding: 8px !important; }
    .zc-filter-search { min-width: 100%; }
    .zc-filter-divider { display: none; }
    .zc-filter-right { flex-wrap: wrap !important; gap: 6px !important; }
}


/* === Play button: solid green like mockup === */
.zc-rec-play {
    background: #1D9E75 !important;
    color: #fff !important;
}
.zc-rec-play:hover:not(:disabled) {
    background: #168a62 !important;
    color: #fff !important;
}
.zc-rec-play.zc-audio-playing {
    background: #0d7a56 !important;
    color: #fff !important;
}
.zc-rec-play:disabled {
    background: #E2E8F0 !important;
    color: #94A3B8 !important;
    cursor: not-allowed !important;
}
/* Download button: border style */
.zc-rec-dl-btn {
    border: 1px solid #D1D5DB !important;
    color: #6B7280 !important;
    background: #fff !important;
}
.zc-rec-dl-btn:hover {
    background: #F9FAFB !important;
    border-color: #9CA3AF !important;
    color: #374151 !important;
}
/* Delete button: red border */
.zc-rec-del-btn {
    border: 1px solid #FECACA !important;
    color: #EF4444 !important;
    background: #fff !important;
}
.zc-rec-del-btn:hover {
    background: #FEF2F2 !important;
    border-color: #F87171 !important;
}
/* Filter bar — full single-row fix */
#zc-calls-filter-bar {
    display: flex !important;
    flex-wrap: nowrap !important;
    align-items: center !important;
    border: 1px solid #E2E8F0 !important;
    border-radius: 10px !important;
    background: #fff !important;
    padding: 3px 12px 3px 0 !important;
    gap: 0 !important;
    margin-bottom: 20px !important;
    overflow: hidden !important;
}
#zc-calls-filter-bar .zc-filter-search {
    flex: 1 !important;
    max-width: none !important;
    min-width: 100px !important;
    display: flex !important;
    align-items: center !important;
}
#zc-calls-filter-bar .zc-filter-search input {
    border: none !important;
    border-radius: 0 !important;
    padding: 9px 8px 9px 34px !important;
    box-shadow: none !important;
    background: transparent !important;
    width: 100% !important;
}
#zc-calls-filter-bar .zc-filter-search input:focus {
    border: none !important;
    box-shadow: none !important;
    outline: none !important;
}
#zc-calls-filter-bar .zc-filter-divider {
    width: 1px !important;
    background: #E2E8F0 !important;
    align-self: stretch !important;
    margin: 0 10px !important;
    flex-shrink: 0 !important;
}
#zc-calls-filter-bar .zc-filter-right {
    display: flex !important;
    flex-wrap: nowrap !important;
    align-items: center !important;
    gap: 6px !important;
    margin-left: 0 !important;
    flex-shrink: 0 !important;
}
#zc-calls-filter-bar .zc-filter-date {
    width: 110px !important;
    min-width: 0 !important;
    font-size: 12px !important;
    padding: 5px 4px !important;
}
#zc-calls-filter-bar .zc-filter-select {
    min-width: 105px !important;
    max-width: 140px !important;
    font-size: 12px !important;
    padding: 6px 20px 6px 8px !important;
}
#zc-calls-filter-bar .zc-filter-export {
    padding: 6px 10px !important;
    font-size: 12px !important;
    white-space: nowrap !important;
    flex-shrink: 0 !important;
}

/* ============================================================
   Fax v3 — scoped to .zc-fax-v2
   ============================================================ */
.zc-fax-v2 { padding: 4px 0; }
.zc-fax-v2 .zf-page-title { font-size: 22px !important; font-weight: 700 !important; color: #0a1628 !important; margin: 0 0 2px !important; }
.zc-fax-v2 .zf-page-sub   { font-size: 13px !important; color: #6b7280 !important; margin: 0 !important; }

/* Stats */
.zc-fax-v2 .zf-stats { display: grid !important; grid-template-columns: repeat(4,1fr); gap: 16px; margin: 22px 0; }
.zc-fax-v2 .stat { background: #fff !important; border: 1px solid #e6e9ee !important; border-radius: 12px !important; padding: 18px !important; display: flex !important; align-items: center !important; gap: 14px !important; box-shadow: none !important; }
.zc-fax-v2 .stat .ic { width: 42px !important; height: 42px !important; border-radius: 50% !important; background: #e8f5ef !important; color: #1D9E75 !important; display: flex !important; align-items: center !important; justify-content: center !important; flex-shrink: 0 !important; }
.zc-fax-v2 .stat .num { font-size: 22px !important; font-weight: 700 !important; line-height: 1.1 !important; color: #0a1628 !important; margin: 0 !important; }
.zc-fax-v2 .stat .lbl { font-size: 12px !important; color: #6b7280 !important; margin: 2px 0 0 !important; }

/* Grid & panels */
.zc-fax-v2 .zf-grid  { display: flex !important; flex-direction: column !important; gap: 20px !important; }
.zc-fax-v2 .zf-panel { background: #fff !important; border: 1px solid #e6e9ee !important; border-radius: 12px !important; padding: 20px !important; }
.zc-fax-v2 .zf-panel-h2 { font-size: 16px !important; font-weight: 600 !important; margin: 0 0 16px !important; color: #0a1628 !important; line-height: 1.3 !important; }

/* Form */
.zc-fax-v2 .zf-field { margin-bottom: 16px !important; }
.zc-fax-v2 .zf-label { display: block !important; font-size: 12px !important; color: #6b7280 !important; margin-bottom: 6px !important; font-weight: 500 !important; }
.zc-fax-v2 .zf-input { width: 100% !important; border: 1px solid #e6e9ee !important; border-radius: 8px !important; padding: 10px 12px !important; font-family: inherit !important; font-size: 14px !important; outline: none !important; box-sizing: border-box !important; color: #1f2937 !important; background: #fff !important; }
.zc-fax-v2 .zf-input:focus { border-color: #1D9E75 !important; }
.zc-fax-v2 .zf-input::placeholder { color: #b3b9c2 !important; }
.zc-fax-v2 .zf-textarea { display: block !important; width: 100% !important; border: 1px solid #e6e9ee !important; border-radius: 8px !important; padding: 10px 12px !important; font-family: inherit !important; font-size: 14px !important; outline: none !important; box-sizing: border-box !important; color: #1f2937 !important; resize: vertical !important; min-height: 90px !important; background: #fff !important; }
.zc-fax-v2 .zf-textarea:focus { border-color: #1D9E75 !important; }
.zc-fax-v2 .zf-textarea::placeholder { color: #b3b9c2 !important; }
.zc-fax-v2 .zf-counter { text-align: right !important; font-size: 11px !important; color: #6b7280 !important; margin: 4px 0 0 !important; }
.zc-fax-v2 .zf-file-selected { font-size: 12px !important; color: #1D9E75 !important; font-weight: 500 !important; margin-top: 6px !important; padding: 4px 8px !important; background: #f0fdf4 !important; border-radius: 4px !important; }
.zc-fax-v2 .zf-upload:hover, .zc-fax-v2 .zf-upload.dragging { border-color: #1D9E75 !important; background: #f0fdf4 !important; }
.zc-fax-v2 .zf-upload-btn:hover { border-color: #1D9E75 !important; color: #1D9E75 !important; }
.zc-fax-v2 .zf-ico-btn:hover { border-color: #1D9E75 !important; color: #1D9E75 !important; }
.zc-fax-v2 .zf-send:hover { background: #178862 !important; }
.zc-fax-v2 .zf-send:disabled { opacity: .6 !important; cursor: not-allowed !important; }

/* History toolbar */
.zc-fax-v2 .zf-refresh.spinning svg { animation: zcSpin .7s linear infinite !important; }

/* Fax list items */
.zc-fax-v2 .fax-item { display: flex !important; align-items: center !important; gap: 14px !important; padding: 13px 4px !important; border-bottom: 1px solid #f0f2f5 !important; border-top: none !important; border-left: none !important; border-right: none !important; }
.zc-fax-v2 .fax-item:last-child { border-bottom: none !important; }
.zc-fax-v2 .dir { width: 34px !important; height: 34px !important; border-radius: 50% !important; background: #e8f5ef !important; display: flex !important; align-items: center !important; justify-content: center !important; flex-shrink: 0 !important; }
.zc-fax-v2 .dir.in  { color: #1D9E75 !important; }
.zc-fax-v2 .dir.out { color: #2563eb !important; background: #e8eefc !important; }
.zc-fax-v2 .meta { flex: 0 0 110px !important; min-width: 0 !important; }
.zc-fax-v2 .meta .when { font-size: 12px !important; color: #6b7280 !important; margin: 0 !important; }
.zc-fax-v2 .meta .type { font-size: 11px !important; font-weight: 600 !important; margin: 0 !important; }
.zc-fax-v2 .type.received { color: #1D9E75 !important; }
.zc-fax-v2 .type.sent { color: #2563eb !important; }
.zc-fax-v2 .num { font-size: 13px !important; font-weight: 600 !important; flex: 1 !important; min-width: 0 !important; color: #0a1628 !important; overflow: hidden !important; text-overflow: ellipsis !important; margin: 0 !important; }
.zc-fax-v2 .num .pages { font-size: 11px !important; color: #6b7280 !important; font-weight: 400 !important; margin: 1px 0 0 !important; }
.zc-fax-v2 .badge { font-size: 11px !important; font-weight: 600 !important; padding: 4px 10px !important; border-radius: 20px !important; white-space: nowrap !important; flex-shrink: 0 !important; }
.zc-fax-v2 .badge.received  { background: #e8f5ef !important; color: #1D9E75 !important; }
.zc-fax-v2 .badge.delivered { background: #e8eefc !important; color: #2563eb !important; }
.zc-fax-v2 .badge.sent      { background: #e8eefc !important; color: #2563eb !important; }
.zc-fax-v2 .badge.failed    { background: #fee2e2 !important; color: #ef4444 !important; }
.zc-fax-v2 .actions { display: flex !important; gap: 6px !important; flex-shrink: 0 !important; }
.zc-fax-v2 .act { border: 1px solid #e6e9ee !important; border-radius: 7px !important; padding: 6px 9px !important; display: inline-flex !important; align-items: center !important; gap: 5px !important; color: #6b7280 !important; background: #fff !important; cursor: pointer !important; font-size: 12px !important; font-family: inherit !important; text-decoration: none !important; transition: border-color .15s, color .15s !important; }
.zc-fax-v2 .act.view { font-weight: 500 !important; }
.zc-fax-v2 .act:hover { border-color: #9ca3af !important; color: #0a1628 !important; }
.zc-fax-v2 .act.del { color: #ef4444 !important; border-color: #fde0e0 !important; }
.zc-fax-v2 .act.del:hover { background: #fee2e2 !important; }
.zc-fax-v2 .act svg { width: 14px !important; height: 14px !important; }

/* Pagination */
.zc-fax-v2 .zf-pager { display: flex !important; justify-content: space-between !important; align-items: center !important; margin-top: 18px !important; flex-wrap: wrap !important; gap: 12px !important; }
.zc-fax-v2 .zf-pager-info  { font-size: 12px !important; color: #6b7280 !important; }
.zc-fax-v2 .zf-pager-pages { display: flex !important; gap: 6px !important; align-items: center !important; }

/* Mobile */
@media (max-width: 980px) {
    .zc-fax-v2 .zf-stats { grid-template-columns: repeat(2,1fr) !important; }
}
@media (max-width: 560px) {
    .zc-fax-v2 .zf-stats { grid-template-columns: 1fr 1fr !important; }
    .zc-fax-v2 .act.view span { display: none !important; }
    .zc-fax-v2 .meta { flex: 0 0 85px !important; }
    .zc-fax-v2 .badge { display: none !important; }
}
@media (max-width: 400px) {
    .zc-fax-v2 .zf-stats { grid-template-columns: 1fr !important; }
}
/* ============================================================
   Mobile fixes — 2026-06-04
   ============================================================ */

/* Impersonation bar: auto height + wrap on mobile */
@media (max-width: 600px) {
    .zc-admin-impersonation-bar {
        height: auto !important;
        min-height: 36px !important;
        padding: 8px 12px !important;
        flex-wrap: wrap !important;
        gap: 4px 8px !important;
    }
    .zc-admin-bar-return { flex-shrink: 0; }
}

/* Header: wrap on small screens */
@media (max-width: 600px) {
    .zc-header {
        height: auto !important;
        min-height: 56px !important;
        padding: 10px 14px !important;
        flex-wrap: wrap !important;
        gap: 6px !important;
    }
    .zc-user { font-size: 12px; gap: 6px; }
    .zc-role-badge { font-size: 10px; padding: 2px 6px; }
}

/* Content: smaller padding on mobile */
@media (max-width: 600px) {
    .zc-content { padding: 16px 12px !important; }
    .zc-tabs { padding: 8px 12px !important; }
}

/* Calls filter bar: allow wrap on mobile (override ID selector) */
@media (max-width: 767px) {
    #zc-calls-filter-bar {
        flex-wrap: wrap !important;
        padding: 8px !important;
        gap: 8px !important;
    }
    #zc-calls-filter-bar .zc-filter-search { min-width: 100% !important; }
    #zc-calls-filter-bar .zc-filter-divider { display: none !important; }
    #zc-calls-filter-bar .zc-filter-right {
        flex-wrap: wrap !important;
        gap: 6px !important;
        width: 100% !important;
    }
    #zc-calls-filter-bar .zc-filter-date { min-width: 120px !important; flex: 1 !important; }
    #zc-calls-filter-bar .zc-filter-select { min-width: 120px !important; flex: 1 !important; }
    #zc-calls-filter-bar .zc-filter-export { width: 100% !important; justify-content: center !important; }
}

/* Fax action buttons: compact on mobile (don't use width:100% — it squeezes .num) */
@media (max-width: 480px) {
    .zc-fax-v2 .actions { gap: 4px !important; }
    .zc-fax-v2 .act { padding: 5px 6px !important; font-size: 11px !important; }
    .zc-fax-v2 .act svg { width: 13px !important; height: 13px !important; }
}

/* FROM/TO address row: prevent Astra theme inflating select height */
.zf-addr-row select.zf-addr-did,
.zf-addr-did {
    height: auto !important;
    line-height: normal !important;
    min-height: 0 !important;
    font-size: 13px !important;
    padding: 0 18px 0 0 !important;
}

/* Fax item: prevent num from wrapping to many lines */
.zc-fax-v2 .num {
    white-space: nowrap !important;
}
.zc-fax-v2 .num .pages {
    white-space: normal !important;
    font-size: 11px !important;
}

/* meta date: no wrap */
.zc-fax-v2 .meta .when {
    white-space: nowrap !important;
    overflow: hidden !important;
    text-overflow: ellipsis !important;
}
/* ============================================================
   Mobile App Architecture — bottom tab bar (≤600px)
   Like iOS app: compact header + scrollable content + fixed bottom tabs
   ============================================================ */
@media (max-width: 600px) {

    /* Reduce huge top padding on mobile */
    .zarcall-page { padding-top: 110px !important; }

    /* Portal: full-width, no card border-radius on mobile */
    .zarcall-portal {
        border-radius: 0 !important;
        box-shadow: none !important;
        margin: 0 0 0 0 !important;
    }

    /* ── App Bar (compact header) ── */
    .zc-header {
        height: 52px !important;
        min-height: 52px !important;
        padding: 0 14px !important;
        flex-wrap: nowrap !important;
        gap: 8px !important;
    }
    .zc-brand-sub { display: none !important; }
    .zc-brand-name { font-size: 15px !important; }
    .zc-user { font-size: 12px !important; gap: 6px !important; }
    .zc-role-badge { display: none !important; }

    /* ── Impersonation bar: compact on mobile ── */
    .zc-admin-impersonation-bar {
        font-size: 11px !important;
        padding: 6px 12px !important;
        height: auto !important;
        min-height: 0 !important;
        flex-wrap: wrap !important;
        gap: 4px !important;
    }
    .zc-admin-bar-return { font-size: 11px !important; padding: 2px 8px !important; }

    /* ── BOTTOM TAB BAR ── */
    .zc-tabs {
        position: fixed !important;
        bottom: 0 !important;
        left: 0 !important;
        right: 0 !important;
        z-index: 1000 !important;
        padding: 0 0 env(safe-area-inset-bottom, 0px) 0 !important;
        border-top: 1px solid #E2E8F0 !important;
        border-bottom: none !important;
        background: #fff !important;
        box-shadow: 0 -2px 16px rgba(0,0,0,.08) !important;
        overflow-x: visible !important;
    }
    .zc-tabs-inner {
        background: transparent !important;
        border-radius: 0 !important;
        padding: 0 !important;
        gap: 0 !important;
        width: 100% !important;
        justify-content: space-around !important;
        flex-shrink: 0 !important;
        flex-wrap: nowrap !important;
    }
    .zc-tabs a {
        flex-direction: column !important;
        align-items: center !important;
        justify-content: center !important;
        gap: 2px !important;
        padding: 7px 4px 9px !important;
        font-size: 10px !important;
        font-weight: 500 !important;
        border-radius: 0 !important;
        flex: 1 !important;
        white-space: nowrap !important;
        min-width: 0 !important;
        background: transparent !important;
        box-shadow: none !important;
        color: #94A3B8 !important;
        overflow: hidden !important;
    }
    .zc-tabs a svg {
        width: 21px !important;
        height: 21px !important;
        margin: 0 !important;
        display: block !important;
        flex-shrink: 0 !important;
        vertical-align: middle !important;
    }
    .zc-tabs a.active {
        background: transparent !important;
        box-shadow: none !important;
        color: #1D9E75 !important;
        font-weight: 600 !important;
    }
    .zc-tabs a:hover {
        background: transparent !important;
        color: #1D9E75 !important;
    }

    /* ── Content: pad bottom for tab bar height (~64px) ── */
    .zc-content {
        padding: 16px 12px 80px !important;
        min-height: calc(100vh - 200px) !important;
    }
    .zc-content.zc-sms-content {
        padding-bottom: 64px !important;
    }


}
/* ============================================================
   Calls tab — mobile fixes (2026-06-04)
   ============================================================ */

/* 1. Summary cards: JS sets inline style repeat(4,1fr) — override with !important */
@media (max-width: 600px) {
    #zc-calls-summary {
        grid-template-columns: 1fr 1fr !important;
        gap: 10px !important;
    }
    /* Compact card size on mobile */
    .zc-calls-section .zc-summary-card {
        padding: 12px !important;
        gap: 10px !important;
    }
    .zc-card-icon {
        width: 40px !important;
        min-width: 40px !important;
        height: 40px !important;
    }
    .zc-calls-section .zc-card-metric { font-size: 22px !important; }
    .zc-calls-section .zc-card-label  { font-size: 11px !important; }
}

/* 2. Calls table: hide Date column on mobile (shown in expanded row)
      Result: Contact | Status | Actions — fits in 376px */
@media (max-width: 600px) {
    .zc-calls-table th:nth-child(1),
    .zc-calls-table tr:not(.zc-exp-row) td:nth-child(1) { display: none !important; }

    /* Actions column: always visible, compact buttons */
    .zc-calls-table th:last-child,
    .zc-calls-table td:last-child {
        white-space: nowrap !important;
        width: 1% !important;
        padding-right: 4px !important;
    }
    .zc-rec-play, .zc-rec-dl-btn, .zc-rec-del-btn {
        width: 28px !important;
        height: 28px !important;
    }

    /* Contact column: allow wrap on phone number */
    .zc-calls-table td:nth-child(2) {
        max-width: 140px !important;
        word-break: break-all !important;
    }
}

/* 3. Filter bar: compact on mobile — hide Export, tighter layout */
@media (max-width: 600px) {
    #zc-calls-filter-bar .zc-filter-export { display: none !important; }

    /* Date inputs: smaller */
    #zc-calls-filter-bar .zc-filter-date {
        font-size: 11px !important;
        padding: 5px 4px !important;
    }
    /* Direction + Status: half width each */
    #zc-calls-filter-bar .zc-filter-select {
        font-size: 11px !important;
        padding: 5px 18px 5px 6px !important;
        min-width: 0 !important;
        flex: 1 !important;
    }
}

/* 4. Expanded waveform row: full width, compact on mobile */
@media (max-width: 600px) {
    .zc-exp-row td {
        padding: 10px 8px !important;
    }
    .zc-exp-inner {
        flex-direction: column !important;
        align-items: flex-start !important;
        gap: 10px !important;
    }
    .zc-wf-player { width: 100% !important; }
    .zc-exp-info { min-width: 0 !important; max-width: 100% !important; }
}
/* ============================================================
   Calls filter bar — uniform height, single row (2026-06-04)
   ============================================================ */
@media (max-width: 600px) {

    /* Filter-right: ONE row, no wrap, vertically centered */
    #zc-calls-filter-bar .zc-filter-right {
        flex-wrap: nowrap !important;
        align-items: center !important;
        gap: 5px !important;
        width: 100% !important;
    }

    /* ALL inputs & selects: exact same height */
    #zc-calls-filter-bar .zc-filter-date,
    #zc-calls-filter-bar .zc-filter-select {
        height: 32px !important;
        box-sizing: border-box !important;
        padding: 0 6px !important;
        font-size: 11px !important;
        border: 1px solid #E2E8F0 !important;
        border-radius: 6px !important;
        background-color: #fff !important;
        line-height: 32px !important;
    }

    /* Date inputs: share remaining space equally */
    #zc-calls-filter-bar .zc-filter-date {
        flex: 1 1 0 !important;
        min-width: 0 !important;
        max-width: none !important;
    }

    /* Dash between dates */
    #zc-calls-filter-bar .zc-filter-right > span {
        flex-shrink: 0 !important;
        font-size: 11px !important;
        color: #94A3B8 !important;
    }

    /* Selects: fixed width — enough to show text without cut */
    #zc-calls-filter-bar .zc-filter-select {
        flex: 0 0 80px !important;
        min-width: 0 !important;
        max-width: 80px !important;
        padding-right: 18px !important;
        appearance: none !important;
        -webkit-appearance: none !important;
        overflow: hidden !important;
        text-overflow: ellipsis !important;
        background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='10' height='10' viewBox='0 0 24 24' fill='none' stroke='%2364748B' stroke-width='2.5'%3E%3Cpolyline points='6 9 12 15 18 9'/%3E%3C/svg%3E") !important;
        background-repeat: no-repeat !important;
        background-position: right 4px center !important;
    }

    /* Search bar stays full-width on its own row */
    #zc-calls-filter-bar .zc-filter-search {
        min-width: 100% !important;
        margin-bottom: 0 !important;
    }
    #zc-calls-filter-bar .zc-filter-search input {
        height: 32px !important;
        box-sizing: border-box !important;
        padding: 0 8px 0 34px !important;
        font-size: 12px !important;
    }

    /* Outer filter card: tighter */
    #zc-calls-filter-bar {
        padding: 8px !important;
        gap: 6px !important;
        border-radius: 10px !important;
    }
}
/* Calls: move summary cards to bottom on mobile (like Fax tab) */
@media (max-width: 600px) {
    .zc-calls-section {
        display: flex !important;
        flex-direction: column !important;
    }
    #zc-calls-filter-bar  { order: 1 !important; }
    #zc-calls-wrap        { order: 2 !important; }
    #zc-calls-pagination  { order: 3 !important; }
    #zc-calls-summary     { order: 4 !important; margin-top: 16px !important; }
}
/* Portal page: full-width on mobile — remove Astra container padding */
@media (max-width: 600px) {
    .page-id-1080 .ast-container,
    .page-id-1080 .ast-row,
    .page-id-1080 #content,
    .page-id-1080 .site-content,
    .page-id-1080 .entry-content,
    .page-id-1080 .ast-article-single {
        padding-left: 0 !important;
        padding-right: 0 !important;
        max-width: 100% !important;
        width: 100% !important;
    }
    .zarcall-page {
        padding-left: 0 !important;
        padding-right: 0 !important;
    }
    .zarcall-portal {
        width: 100% !important;
        max-width: 100% !important;
        margin: 0 !important;
    }
}
/* Impersonation: integrated into header */
.zc-viewing-as {
    font-size: 11px;
    color: rgba(255,255,255,.5);
    font-weight: 400;
}
.zc-viewing-as strong {
    color: rgba(255,255,255,.85);
    font-weight: 600;
}
.zc-return-btn {
    font-size: 11px;
    color: #1D9E75;
    text-decoration: none;
    border: 1px solid rgba(29,158,117,.5);
    border-radius: 5px;
    padding: 3px 9px;
    font-weight: 500;
    white-space: nowrap;
    transition: all .15s;
}
.zc-return-btn:hover {
    background: rgba(29,158,117,.15);
    border-color: #1D9E75;
    color: #1D9E75;
    text-decoration: none;
}
/* Hide old impersonation bar if still rendered */
.zc-admin-impersonation-bar { display: none !important; }


/* Fax FROM/TO: equal full-width rows */
.zf-addr-did {
    flex: 1 !important;
    width: 100% !important;
    min-width: 0 !important;
}
.zf-addr-input {
    width: 100% !important;
    box-sizing: border-box !important;
}
/* Contact picker: hover highlight */
#zc-fax-pick-contact:hover { color: #1D9E75 !important; }
/* ============================================================
   Fax History item — mobile redesign (2026-06-04)
   Hierarchy: Number (large) → Date · Type → Pages | Actions (big)
   ============================================================ */
@media (max-width: 600px) {

    /* Grid layout: [icon] [content] [actions] */
    .zc-fax-v2 .fax-item {
        display: grid !important;
        grid-template-areas:
            "dir num    actions"
            "dir meta   actions" !important;
        grid-template-columns: 44px 1fr auto !important;
        grid-template-rows: auto auto !important;
        gap: 3px 10px !important;
        padding: 14px 6px !important;
        align-items: start !important;
    }

    /* Direction icon: top-left */
    .zc-fax-v2 .fax-item .dir {
        grid-area: dir !important;
        align-self: start !important;
        margin-top: 2px !important;
    }

    /* Phone number: PRIMARY — large bold, first row */
    .zc-fax-v2 .fax-item .num {
        grid-area: num !important;
        font-size: 16px !important;
        font-weight: 700 !important;
        color: #0a1628 !important;
        white-space: normal !important;
        overflow: visible !important;
        text-overflow: unset !important;
        line-height: 1.3 !important;
        flex: none !important;
        min-width: 0 !important;
    }

    /* Pages: small gray line below number */
    .zc-fax-v2 .fax-item .num .pages {
        display: block !important;
        font-size: 11px !important;
        font-weight: 400 !important;
        color: #9ca3af !important;
        margin-top: 2px !important;
    }

    /* Meta (date + sent/received): second row, smaller */
    .zc-fax-v2 .fax-item .meta {
        grid-area: meta !important;
        flex: none !important;
        min-width: 0 !important;
        display: flex !important;
        align-items: center !important;
        gap: 4px !important;
        flex-wrap: nowrap !important;
    }
    .zc-fax-v2 .fax-item .meta .when {
        font-size: 11px !important;
        color: #9ca3af !important;
        white-space: nowrap !important;
        margin: 0 !important;
    }
    .zc-fax-v2 .fax-item .meta .type {
        font-size: 11px !important;
        font-weight: 600 !important;
        white-space: nowrap !important;
        margin: 0 !important;
    }
    .zc-fax-v2 .fax-item .meta .when::after {
        content: ' ·' !important;
        color: #d1d5db !important;
    }

    /* Badge: hidden (info already in .type) */
    .zc-fax-v2 .fax-item .badge { display: none !important; }

    /* Actions: right column, stacked, finger-friendly (min 40px) */
    .zc-fax-v2 .fax-item .actions {
        grid-area: actions !important;
        flex-direction: column !important;
        gap: 5px !important;
        align-self: center !important;
        flex-shrink: 0 !important;
    }
    .zc-fax-v2 .fax-item .act {
        min-width: 40px !important;
        min-height: 40px !important;
        width: 40px !important;
        padding: 0 !important;
        justify-content: center !important;
        border-radius: 8px !important;
        font-size: 13px !important;
    }
    .zc-fax-v2 .fax-item .act svg {
        width: 16px !important;
        height: 16px !important;
    }
    /* Hide text labels on action buttons — icon only */
    .zc-fax-v2 .fax-item .act span { display: none !important; }
}
/* Fax FROM/TO: identical bordered boxes, same font size */
.zf-from-select,
.zf-from-static {
    width: 100% !important;
    box-sizing: border-box !important;
    border: 1px solid #e6e9ee !important;
    border-radius: 8px !important;
    padding: 10px 36px 10px 12px !important;
    font-size: 14px !important;
    font-weight: 500 !important;
    font-family: inherit !important;
    color: #1f2937 !important;
    background: #fff !important;
    height: 44px !important;
    line-height: 1.4 !important;
    display: flex !important;
    align-items: center !important;
}
/* Select: chevron arrow */
.zf-from-select {
    appearance: none !important;
    -webkit-appearance: none !important;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 24 24' fill='none' stroke='%2364748B' stroke-width='2.5'%3E%3Cpolyline points='6 9 12 15 18 9'/%3E%3C/svg%3E") !important;
    background-repeat: no-repeat !important;
    background-position: right 12px center !important;
    cursor: pointer !important;
    display: block !important;
}
/* Ensure TO input matches */
.zc-fax-v2 #zc-fax-to.zf-input {
    height: 44px !important;
    font-size: 14px !important;
    font-weight: 500 !important;
    padding: 10px 12px !important;
    color: #1f2937 !important;
}
/* Fax FROM / TO — inline label, separate bordered boxes */
.zf-inline-field {
    display: flex !important;
    align-items: center !important;
    border: 1px solid #e6e9ee !important;
    border-radius: 8px !important;
    padding: 11px 14px !important;
    background: #fff !important;
    margin-bottom: 10px !important;
    gap: 10px !important;
    box-sizing: border-box !important;
}
.zf-inline-label {
    font-size: 11px !important;
    font-weight: 700 !important;
    color: #64748B !important;
    text-transform: uppercase !important;
    letter-spacing: .05em !important;
    white-space: nowrap !important;
    flex-shrink: 0 !important;
    width: 36px !important;
}
/* Select (FROM) */
.zf-inline-select {
    flex: 1 !important;
    border: none !important;
    outline: none !important;
    font-size: 14px !important;
    font-weight: 500 !important;
    color: #1f2937 !important;
    background: transparent !important;
    font-family: inherit !important;
    padding: 0 20px 0 0 !important;
    min-width: 0 !important;
    cursor: pointer !important;
    appearance: none !important;
    -webkit-appearance: none !important;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 24 24' fill='none' stroke='%2364748B' stroke-width='2.5'%3E%3Cpolyline points='6 9 12 15 18 9'/%3E%3C/svg%3E") !important;
    background-repeat: no-repeat !important;
    background-position: right 0 center !important;
}
/* Input (TO) */
.zf-inline-input {
    width: 100% !important;
    border: none !important;
    outline: none !important;
    font-size: 14px !important;
    font-weight: 500 !important;
    color: #1f2937 !important;
    background: transparent !important;
    font-family: inherit !important;
    padding: 0 !important;
    min-width: 0 !important;
}
.zf-inline-input::placeholder { color: #b3b9c2 !important; font-weight: 400 !important; }
/* Static span (single DID, no select) */
.zf-inline-static {
    flex: 1 !important;
    font-size: 14px !important;
    font-weight: 500 !important;
    color: #1f2937 !important;
}
/* Fax items: compact padding + smaller action buttons on mobile */
@media (max-width: 600px) {
    .zc-fax-v2 .fax-item {
        padding: 10px 6px !important;
        gap: 2px 8px !important;
    }
    .zc-fax-v2 .fax-item .act {
        width: 30px !important;
        height: 30px !important;
        min-width: 30px !important;
        min-height: 30px !important;
        border-radius: 6px !important;
        padding: 0 !important;
    }
    .zc-fax-v2 .fax-item .act svg {
        width: 14px !important;
        height: 14px !important;
    }
    .zc-fax-v2 .fax-item .actions {
        gap: 4px !important;
    }
    /* Dir icon: smaller */
    .zc-fax-v2 .fax-item .dir {
        width: 30px !important;
        height: 30px !important;
    }
}
/* Fax items: remove direction icon on mobile, adjust grid */
@media (max-width: 600px) {
    .zc-fax-v2 .fax-item .dir { display: none !important; }
    .zc-fax-v2 .fax-item {
        grid-template-areas:
            "num  actions"
            "meta actions" !important;
        grid-template-columns: 1fr auto !important;
    }
}


/* SMS Back button: clean style, no grey box */
.zc-back-btn {
    background: transparent !important;
    border: none !important;
    color: #1D9E75 !important;
    font-size: 13px !important;
    font-weight: 600 !important;
    padding: 4px 0 !important;
    cursor: pointer !important;
    box-shadow: none !important;
    outline: none !important;
}
.zc-back-btn:hover { color: #168a62 !important; }

/* ============================================================
   SMS MOBILE — position:fixed overlay (no height calculations)
   Conv-col covers full screen except bottom tab bar
   ============================================================ */
@media (max-width: 767px) {

    .zc-content.zc-sms-content {
        padding: 0 !important;
        min-height: 0 !important;
        overflow: visible !important;
    }

    /* Conv col: hidden by default; JS sets position:fixed when opened */
    #zc-conv-col {
        display: none;
        max-height: none !important;
        flex-direction: column !important;
        overflow: hidden !important;
    }

    /* Messages: fill remaining space */
    #zc-conv-col .zc-conv-messages {
        flex: 1 1 auto !important;
        min-height: 0 !important;
        max-height: none !important;
        overflow-y: auto !important;
    }

    /* Reply bar: always visible */
    #zc-conv-col .zc-conv-reply {
        flex-shrink: 0 !important;
    }
}
/* DID badge in thread list (Phase 5.40 — multi-DID threads) */
.zc-thr-did {
    display: inline-block;
    font-size: 10px;
    color: #64748B;
    background: #F1F5F9;
    border-radius: 4px;
    padding: 1px 5px;
    margin-right: 4px;
    vertical-align: middle;
    flex-shrink: 0;
}

/* Unread badges (Phase 5.42) */
.zc-sms-nav-badge {
    display: inline;
    background: none;
    color: inherit;
    font-size: inherit;
    font-weight: 400;
    margin-left: 6px;
    letter-spacing: 0;
}
.zc-did-other-badge {
    display: inline-block;
    background: #e53e3e;
    color: #fff;
    border-radius: 10px;
    font-size: 11px;
    font-weight: 700;
    padding: 1px 6px;
    min-width: 18px;
    text-align: center;
    margin-left: 6px;
    vertical-align: middle;
    cursor: default;
}
/* ── Phase 5.43: unread thread styling ────────────────────── */

/* Thread item — unread state */
.zc-thread-item.unread {
    background: #eef6ff;
    border-left: 4px solid #2563eb;
}
.zc-thread-item.unread .zc-thr-peer {
    font-weight: 700;
    color: #0f172a;
}
.zc-thread-item.unread .zc-thr-preview {
    font-weight: 600;
    color: #1e293b;
}
.zc-thread-item.unread .zc-thr-time {
    color: #1e293b;
    font-weight: 600;
}

/* zc-unread-badge defined at line 616 — blue pill */

/* Hide the FROM-selector "other DID" badge (duplicates info now shown per-thread) */
.zc-did-other-badge { display: none !important; }