:root {
    --header-height: 110px; /* 👈 فقط همین یک عدد را هر وقت خواستید عوض کنید */
}
html, body {
    overflow-x: hidden;
    max-width: 100%;
}
@font-face {
    font-family: 'Vazirmatn FD';
    src: url('/static/fonts/Vazirmatn-Regular.woff2') format('woff2');
    font-weight: 400;
}
@font-face {
    font-family: 'Vazirmatn FD';
    src: url('/static/fonts/Vazirmatn-Medium.woff2') format('woff2');
    font-weight: 500;
}
@font-face {
    font-family: 'Vazirmatn FD';
    src: url('/static/fonts/Vazirmatn-Bold.woff2') format('woff2');
    font-weight: 700;
}

* {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
    font-family: "Vazirmatn FD", Tahoma, "Segoe UI", sans-serif;
    -webkit-tap-highlight-color: transparent;
    transition: background-color 0.25s ease, border-color 0.25s ease, color 0.2s ease;
}

/* ================= تنظیمات حالت تیره (Dark) ================= */
:root[data-theme="dark"] {
    /* 🖼️ مسیر تصاویر استاتیک دارک */
    --site-bg-image: url('/static/images/bg-dark.webp');
    --header-bg-image: url('/static/images/header-dark.jpg');

    --bg-color: #0b0f19;
    --card-bg: rgba(18, 24, 43, 0.82);
    --border-color: rgba(255, 255, 255, 0.09);

    --primary: #6366f1;
    --primary-hover: #4f46e5;
    --accent: #10b981;
    --text-main: #f8fafc;
    --text-muted: #94a3b8;
    --input-bg: rgba(11, 15, 28, 0.9);

    --tab-active-bg: rgba(99, 102, 241, 0.35);
    --tab-active-color: #c7d2fe;
    --tab-hover-bg: rgba(255, 255, 255, 0.08);

    /* متغیرهای چت‌بات دارک */
    --chat-sidebar-bg: rgba(13, 17, 30, 0.95);
    --chat-main-bg: rgba(10, 14, 26, 0.75);
    --chat-bubble-assistant: rgba(26, 34, 58, 0.9);
    --chat-bubble-user: rgba(99, 102, 241, 0.28);
    --chat-input-bar-bg: rgba(13, 17, 30, 0.98);
}

/* ================= تنظیمات حالت روشن (Light) ================= */
:root[data-theme="light"] {
    /* 🖼️ مسیر تصاویر استاتیک لایت */
    --site-bg-image: url('/static/images/bg-light.webp');
    --header-bg-image: url('/static/images/header-light.jpg');

    --bg-color: #f1f5f9;
    --card-bg: rgba(255, 255, 255, 0.88);
    --border-color: rgba(0, 0, 0, 0.08);

    --primary: #4f46e5;
    --primary-hover: #4338ca;
    --accent: #059669;
    --text-main: #0f172a;
    --text-muted: #64748b;
    --input-bg: #ffffff;

    --tab-active-bg: #e0e7ff;
    --tab-active-color: #3730a3;
    --tab-hover-bg: rgba(0, 0, 0, 0.05);

    /* متغیرهای چت‌بات لایت */
    --chat-sidebar-bg: rgba(248, 250, 252, 0.96);
    --chat-main-bg: rgba(255, 255, 255, 0.85);
    --chat-bubble-assistant: #f1f5f9;
    --chat-bubble-user: #e0e7ff;
    --chat-input-bar-bg: rgba(255, 255, 255, 0.98);
}

/* ================= بک‌گراند کل وبسایت ================= */
body {
    background-color: var(--bg-color);
    background-image: var(--site-bg-image);
    background-size: cover;
    background-position: center center;
    background-repeat: no-repeat;
    background-attachment: fixed; /* پس‌زمینه ثابت می‌ماند و محتوا روی آن اسکرول می‌شود */
    color: var(--text-main);
    min-height: 100vh;
}

/* ================= هدر سایت با پس‌زمینه تصویری ================= */
.app-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 0 1.8rem;
    height: 110px;
    background-color: var(--card-bg);
    background-image: var(--header-bg-image);
    background-size: cover;
    background-position: center;
    background-repeat: no-repeat;
    border-bottom: 1px solid var(--border-color);
    box-shadow: 0 6px 25px rgba(0, 0, 0, 0.06);
    position: sticky;
    top: 0;
    z-index: 1000;
}

/* لوگو استاتیک */
.brand-link {
    display: flex;
    align-items: center;
    gap: 12px;
    text-decoration: none;
    color: inherit;
}
.brand {
    display: flex;
    align-items: center;
    gap: 12px;
    z-index: 2;

    /* 👈 این خط لوگو را به سمت چپ (مرکز) هل می‌دهد: */
    margin-right: 120px; /* هر چقدر عدد را بیشتر کنید (مثلا 80px یا 100px) به وسط نزدیک‌تر می‌شود */
}
/* اندازه عکس لوگو */
.brand-logo-img {
    height: 95px; /* 👈 عدد قبلی 44px بود. هر چه بزرگتر بخواهید این عدد را بیشتر کنید (مثلا 75px یا 80px) */
    width: auto;
    max-height: 90%; /* جلوگیری از بیرون زدن از کادر هدر */
    object-fit: contain;
}
[data-theme="dark"] .logo-light { display: none; }
[data-theme="dark"] .logo-dark { display: block; }
[data-theme="light"] .logo-light { display: block; }
[data-theme="light"] .logo-dark { display: none; }

.brand-text { display: flex; flex-direction: column; }
.brand-title { font-size: 1.35rem; font-weight: 800; color: var(--text-main); }
.brand-sub { font-size: 0.7rem; color: var(--text-muted); font-weight: 600; }
.brand-divider { width: 1px; height: 32px; background: var(--border-color); margin: 0 16px; }

/* منوی وسط‌چین شده */
.nav-tabs {
    display: flex;
    gap: 8px;
    align-items: center;

    /* 👈 این سه خط منو را دقیقا در مرکز صفحه قرار می‌دهد: */
    position: absolute;
    left: 50%;
    transform: translateX(-50%);
}

.tab-btn {
    background: transparent;
    border: 1px solid transparent;
    color: var(--text-muted);
    padding: 8px 16px;
    border-radius: 9999px;
    cursor: pointer;
    font-size: 0.9rem;
    font-weight: 600;
    white-space: nowrap;
}
.tab-btn:hover { color: var(--text-main); background: var(--tab-hover-bg); }
.tab-btn.active {
    background: var(--tab-active-bg);
    color: var(--tab-active-color);
    border-color: rgba(99, 102, 241, 0.3);
}

/* دکمه‌های اکشن هدر */
.header-actions { display: flex; align-items: center; gap: 10px; }
.action-circle-btn {
    width: 42px;
    height: 42px;
    border-radius: 50%;
    background: var(--tab-hover-bg);
    border: 1px solid var(--border-color);
    color: var(--text-main);
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    font-size: 1.1rem;
    margin-left: 160px;
}

[data-theme="dark"] .theme-icon-dark { display: none; }
[data-theme="dark"] .theme-icon-light { display: inline; }
[data-theme="light"] .theme-icon-dark { display: inline; }
[data-theme="light"] .theme-icon-light { display: none; }

/* کارت‌ها و المان‌های عمومی محتوا */
.content-container { max-width: 1200px; margin: 1.8rem auto; padding: 0 1.2rem; }
.content-container.chat-mode-wide { max-width: 96% !important; width: 96% !important; margin: 0.8rem auto !important; padding: 0 !important; }
.tab-page { display: none; }
.tab-page.active { display: block; animation: fadeIn 0.25s ease; }
@keyframes fadeIn { from { opacity: 0; transform: translateY(6px); } to { opacity: 1; transform: translateY(0); } }

.hero-section { text-align: center; margin-bottom: 2.2rem; }
.hero-section h2 { font-size: 2rem; margin-bottom: 8px; }
.gradient-text { background: linear-gradient(90deg, #6366f1, #06b6d4); -webkit-background-clip: text; -webkit-text-fill-color: transparent; }
.hero-section p { color: var(--text-muted); font-size: 1rem; }

.cards-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(240px, 1fr)); gap: 1.25rem; }
.feature-card { background: var(--card-bg); border: 1px solid var(--border-color); padding: 1.6rem; border-radius: 16px; cursor: pointer; backdrop-filter: blur(12px); }
.feature-card:hover { transform: translateY(-4px); border-color: var(--primary); }
.card-icon { font-size: 2rem; margin-bottom: 10px; }
.feature-card h3 { margin-bottom: 6px; font-size: 1.1rem; }
.feature-card p { color: var(--text-muted); font-size: 0.85rem; line-height: 1.6; }

.panel { background: var(--card-bg); border: 1px solid var(--border-color); padding: 1.8rem; border-radius: 16px; backdrop-filter: blur(12px); }
.form-group { margin-bottom: 1.2rem; display: flex; flex-direction: column; gap: 6px; }
.form-group label { font-size: 0.88rem; color: var(--text-muted); }
.input-text, .input-line, .file-input, .code-area, select.input-line { background: var(--input-bg); border: 1px solid var(--border-color); color: var(--text-main); padding: 10px 14px; border-radius: 10px; font-size: 0.95rem; outline: none; width: 100%; }
.input-text { height: 100px; resize: vertical; }
.code-area { height: 140px; font-family: monospace; font-size: 0.85rem; direction: ltr; }
.grid-2-cols { display: grid; grid-template-columns: 1fr 1fr; gap: 1.2rem; }
.btn { padding: 10px 18px; border-radius: 10px; border: none; font-size: 0.92rem; font-weight: 600; cursor: pointer; display: inline-flex; justify-content: center; align-items: center; gap: 8px; }
.primary-btn { background: var(--primary); color: #fff; }
.primary-btn:hover { background: var(--primary-hover); }
.secondary-btn { background: var(--accent); color: #fff; }

.editor-layout { display: flex; gap: 20px; align-items: flex-start; }
.editor-sidebar { flex: 1 1 320px; }
.editor-main { flex: 2 1 600px; }
.checkbox-box { display: flex; flex-direction: column; gap: 10px; background: rgba(0, 0, 0, 0.05); padding: 12px; border-radius: 10px; border: 1px solid var(--border-color); margin-top: 15px; }
.drop-zone { border: 2px dashed var(--primary); background: rgba(99, 102, 241, 0.05); border-radius: 14px; padding: 30px 15px; text-align: center; cursor: pointer; }
.hidden { display: none !important; }
.mobile-nav-toggle { display: none; }

@media (max-width: 900px) {
    .app-header {
        height: 70px;
        padding: 0 1rem;
    }
    .brand {
        margin-right: 0;
    }
    .brand-logo-img {
        height: 52px;
    }
    .brand-divider { display: none; }
    .action-circle-btn {
        margin-left: 0;
        width: 38px;
        height: 38px;
    }
    .mobile-nav-toggle {
        display: flex;
        align-items: center;
        justify-content: center;
        width: 38px;
        height: 38px;
        border-radius: 10px;
        border: 1px solid var(--border-color);
        background: var(--tab-hover-bg);
        color: var(--text-main);
        cursor: pointer;
        font-size: 1.2rem;
    }
    .nav-tabs {
        display: none;
        position: absolute;
        top: 70px;
        left: 0;
        right: 0;
        transform: none;
        z-index: 1002;
        background: var(--chat-sidebar-bg);
        backdrop-filter: blur(16px);
        border-bottom: 1px solid var(--border-color);
        flex-direction: column;
        padding: 14px;
        gap: 8px;
        box-shadow: 0 15px 30px rgba(0,0,0,0.35);
    }
    .nav-tabs.menu-open { display: flex; }
    .tab-btn { width: 100%; text-align: right; }
    .editor-layout, .grid-2-cols { flex-direction: column; grid-template-columns: 1fr; }
    .content-container { padding: 0 0.75rem; margin: 1rem auto; }
    .panel { padding: 1rem; }
}

/* ================= استایل شیک کادرهای انتخاب فایل صوت ================= */
.file-input {
    cursor: pointer;
    background: var(--input-bg) !important;
    border: 1.5px dashed var(--border-color) !important;
    padding: 10px 14px !important;
    border-radius: 12px !important;
    color: var(--text-muted) !important;
    transition: all 0.25s ease !important;
    display: flex;
    align-items: center;
}

/* هاور شدن روی کل کادر ورودی */
.file-input:hover {
    border-color: var(--primary) !important;
    background: var(--tab-hover-bg) !important;
}

/* 🎨 تغییر ظاهر آن دکمه سفید زشت به دکمه شیک متناسب با تم */
.file-input::file-selector-button,
.file-input::-webkit-file-upload-button {
    background: var(--primary);
    color: #ffffff;
    border: none;
    padding: 8px 18px;
    border-radius: 8px;
    margin-left: 14px; /* فاصله از متن در حالت فارسی */
    font-size: 0.88rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.2s ease;
    box-shadow: 0 4px 12px rgba(99, 102, 241, 0.3);
    content: "📁 انتخاب فایل";
}

/* افکت موس روی دکمه */
.file-input::file-selector-button:hover,
.file-input::-webkit-file-upload-button:hover {
    background: var(--primary-hover);
    transform: translateY(-1px);
    box-shadow: 0 6px 18px rgba(99, 102, 241, 0.45);
}

/* ================= استایل هوشمند پلیر صوت (تفکیک کامل در لایت‌مد) ================= */
audio {
    width: 100%;
    height: 50px;
    border-radius: 9999px;
    outline: none;
    transition: all 0.25s ease;
}

/* ☀️ حالت روشن (Light): تیره شدن بدنه پلیر، کادر دودی و سایه برجسته */
[data-theme="light"] audio {
    background-color: #e2e8f0 !important;
    border: 2px solid #94a3b8 !important; /* 👈 کادر کاملاً مشخص دور پلیر */
    box-shadow: 0 6px 20px rgba(15, 23, 42, 0.14) !important;
}

/* رنگ پس‌زمینه کنترلرهای داخلی پلیر در مرورگرهای کروم، اج و فایرفاکس */
[data-theme="light"] audio::-webkit-media-controls-panel {
    background-color: #e2e8f0 !important; /* رنگ طوسی/دودی شیک برای پس‌زمینه داخلی */
}

/* 🌙 حالت تیره (Dark): تنظیم مورد تایید قبلی */
[data-theme="dark"] audio {
    background-color: rgba(15, 23, 42, 0.9);
    border: 1.5px solid rgba(255, 255, 255, 0.2);
    filter: invert(0.88) hue-rotate(180deg) drop-shadow(0 4px 12px rgba(0, 0, 0, 0.4));
}


/* ================= ردیف افقی گویندگان داینامیک ================= */
/* ==============================================================
   استایل کامل و بدون تداخل گرید گویندگان (دو ردیف ۵ تایی)
   ============================================================== */
/* ================= گرید ۵ ستونه با تصویر بزرگتر در کنار متن ================= */
.preset-voices-grid {
    display: grid;
    grid-template-columns: repeat(5, minmax(0, 1fr));
    gap: 12px;
    width: 100%;
    margin-top: 12px;
    box-sizing: border-box;
}

.voice-card {
    width: 100%;
    min-width: 0;
    overflow: hidden;
    background: var(--input-bg);
    border: 1.5px solid var(--border-color);
    border-radius: 16px;
    padding: 14px 10px;
    display: flex !important;
    flex-direction: column !important;
    align-items: center !important;
    justify-content: center !important;
    gap: 8px;
    cursor: pointer;
    position: relative;
    box-sizing: border-box;
    transition: all 0.22s ease;
    user-select: none;
    text-align: center;
}

.voice-card:hover {
    transform: translateY(-2px);
    border-color: var(--primary);
    box-shadow: 0 8px 22px rgba(99, 102, 241, 0.18);
}

.voice-card.active {
    background: var(--tab-active-bg);
    border-color: var(--primary);
    box-shadow: 0 0 0 2px var(--primary);
}

.voice-avatar {
    width: 60px;
    height: 60px;
    max-width: 100%;
    border-radius: 50% !important;
    object-fit: cover !important;
    object-position: center 20% !important;
    aspect-ratio: 1 / 1 !important;
    border: 2px solid var(--border-color);
    background: var(--card-bg);
    margin: 0 auto !important;
    display: block !important;
    flex-shrink: 0;
}

.voice-card.active .voice-avatar {
    border-color: var(--primary);
}

.voice-name {
    width: 100%;
    min-width: 0;
    display: block;
    font-size: 0.84rem;
    font-weight: 700;
    color: var(--text-main);
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    margin: 0;
    text-align: center;
}

.voice-preview-btn {
    background: var(--tab-hover-bg);
    border: 1px solid var(--border-color);
    color: var(--primary);
    width: 28px;
    height: 28px;
    border-radius: 50%;
    font-size: 11px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    padding: 0;
    margin: 0 auto;
    transition: all 0.2s ease;
}

.voice-preview-btn:hover {
    background: var(--primary);
    color: #fff;
    transform: scale(1.12);
}

.voice-card.active::after {
    content: "✓";
    position: absolute;
    top: 8px;
    left: 8px;
    background: var(--primary);
    color: #fff;
    width: 18px;
    height: 18px;
    border-radius: 50%;
    font-size: 11px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: bold;
}

/* 📱 تنظیم خودکار در موبایل عمودی، موبایل افقی (چرخاندن صفحه) و تبلت */
@media (max-width: 1024px) {
    .preset-voices-grid {
        grid-template-columns: repeat(auto-fit, minmax(115px, 1fr));
        gap: 10px;
    }
}

@media (max-width: 480px) {
    .preset-voices-grid {
        grid-template-columns: repeat(auto-fit, minmax(105px, 1fr));
        gap: 8px;
    }
    .voice-card {
        padding: 12px 6px;
        gap: 6px;
    }
    .voice-avatar {
        width: 50px;
        height: 50px;
    }
    .voice-name {
        font-size: 0.78rem;
    }
}



/* ================= نوار ابزار حرکات، دکمه‌های نمونه و ۳ اسلایدر ================= */
.diacritic-toolbar {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 7px;
    margin: 6px 0 10px 0;
}

.diacritic-toolbar .diacritic-label {
    font-size: 12.5px;
    color: var(--text-muted);
    margin-left: 4px;
}

.diacritic-toolbar .diacritic-btn {
    width: auto !important;
    min-width: unset;
    padding: 5px 11px;
    font-size: 12.5px;
    font-family: inherit;
    line-height: 1.5;
    color: #e2e8f0;
    background: #1e293b;
    border: 1px solid rgba(148, 163, 184, 0.25);
    border-radius: 8px;
    cursor: pointer;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.25);
    transition: all 0.15s ease;
}

[data-theme="light"] .diacritic-toolbar .diacritic-btn {
    color: var(--text-main);
    background: #e2e8f0;
    border-color: rgba(15, 23, 42, 0.15);
    box-shadow: 0 1px 2px rgba(0, 0, 0, 0.06);
}

.diacritic-toolbar .diacritic-btn:hover {
    background: rgba(56, 189, 248, 0.16);
    border-color: #38bdf8;
    color: #ffffff;
    transform: translateY(-1px);
}

[data-theme="light"] .diacritic-toolbar .diacritic-btn:hover {
    color: var(--primary);
    border-color: var(--primary);
}

.diacritic-toolbar .diacritic-btn:active {
    transform: translateY(0);
}

.diacritic-toolbar .diacritic-clear {
    color: #fca5a5;
    background: rgba(239, 68, 68, 0.1);
    border-color: rgba(248, 113, 113, 0.28);
}

[data-theme="light"] .diacritic-toolbar .diacritic-clear {
    color: #dc2626;
    background: rgba(239, 68, 68, 0.1);
    border-color: rgba(239, 68, 68, 0.3);
}

.diacritic-toolbar .diacritic-clear:hover {
    background: rgba(239, 68, 68, 0.22);
    border-color: #ef4444;
    color: #fecaca;
}

[data-theme="light"] .diacritic-toolbar .diacritic-clear:hover {
    color: #b91c1c;
}

.grid-3-cols {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 16px;
    align-items: end;
}

.grid-3-cols .form-group {
    margin-bottom: 0;
}

@media (max-width: 768px) {
    .grid-3-cols {
        grid-template-columns: 1fr;
    }
}

.time-badge-box {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    margin: 8px 0;
    padding: 5px 12px;
    font-size: 12.5px;
    color: #38bdf8;
    background: rgba(56, 189, 248, 0.1);
    border: 1px solid rgba(56, 189, 248, 0.28);
    border-radius: 8px;
}

.tts-label-row {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 12px;
    margin-bottom: 8px;
}

.sample-chip-btn {
    width: auto !important;
    background: rgba(59, 130, 246, 0.15);
    border: 1px dashed var(--primary, #3b82f6);
    color: var(--primary, #60a5fa);
    border-radius: 6px;
    padding: 5px 12px;
    font-size: 0.82rem;
    font-weight: 500;
    font-family: inherit;
    cursor: pointer;
    transition: all 0.2s;
}

.sample-chip-btn:hover {
    background: rgba(59, 130, 246, 0.25);
    transform: translateY(-1px);
}

/* ==================== 🎙️ باکس ضبط میکروفن ==================== */
.mic-box {
    margin-top: 10px;
    padding: 10px 12px;
    background: var(--input-bg);
    border: 1px dashed var(--border-color);
    border-radius: 10px;
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.mic-controls-row {
    display: flex;
    align-items: center;
    gap: 10px;
    flex-wrap: wrap;
}

.mic-record-btn {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 7px 14px;
    border-radius: 8px;
    border: 1px solid var(--border-color);
    background: var(--card-bg);
    color: inherit;
    cursor: pointer;
    font-size: 0.88rem;
    font-family: inherit;
    transition: all 0.2s ease;
}

.mic-record-btn:hover {
    border-color: #38bdf8;
}

.mic-record-btn.recording {
    background: rgba(239, 68, 68, 0.18);
    border-color: #ef4444;
    color: #f87171;
    animation: micPulse 1.2s infinite;
}

@keyframes micPulse {
    0%, 100% { box-shadow: 0 0 0 0 rgba(239, 68, 68, 0.45); }
    50% { box-shadow: 0 0 0 6px rgba(239, 68, 68, 0); }
}

.mic-timer {
    font-family: monospace;
    font-size: 0.88rem;
    color: #facc15;
    min-width: 48px;
}

.mic-level-track {
    flex: 1;
    min-width: 80px;
    height: 8px;
    background: rgba(148, 163, 184, 0.2);
    border-radius: 99px;
    overflow: hidden;
}

.mic-level-fill {
    width: 0%;
    height: 100%;
    background: linear-gradient(90deg, #10b981, #facc15, #ef4444);
    transition: width 0.08s linear;
}

.mic-hint {
    font-size: 0.78rem;
    color: var(--text-muted);
}

.mic-preview-row {
    display: flex;
    align-items: center;
    gap: 8px;
    flex-wrap: wrap;
}

.mic-preview-row audio {
    flex: 1;
    min-width: 180px;
    height: 36px;
}

.mic-mini-btn {
    padding: 6px 12px;
    border-radius: 8px;
    border: 1px solid var(--border-color);
    background: var(--card-bg);
    color: inherit;
    cursor: pointer;
    font-size: 0.82rem;
    font-family: inherit;
}

.mic-mini-btn.send-now {
    background: #0284c7;
    border-color: #0284c7;
    color: #fff;
}

.mic-mini-btn.danger:hover {
    border-color: #ef4444;
    color: #f87171;
}


/* ==================== 🎙️ تب چت صوتی ==================== */
.vchat-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 12px;
    flex-wrap: wrap;
    margin-bottom: 16px;
}

.vchat-status-pill {
    padding: 6px 14px;
    border-radius: 99px;
    font-size: 0.85rem;
    background: var(--input-bg);
    border: 1px solid var(--border-color);
}

.vchat-status-pill[data-state="listening"] { border-color: #ef4444; color: #f87171; }
.vchat-status-pill[data-state="processing"] { border-color: #facc15; color: #facc15; }
.vchat-status-pill[data-state="speaking"] { border-color: #10b981; color: #34d399; }

.vchat-settings-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 12px;
    margin-bottom: 10px;
}

.vchat-options-row {
    display: flex;
    gap: 18px;
    flex-wrap: wrap;
    align-items: center;
    font-size: 0.88rem;
    margin-bottom: 14px;
}

.vchat-mic-stage {
    display: flex;
    gap: 10px;
    flex-wrap: wrap;
    align-items: center;
}

.vchat-main-btn.recording {
    background: #dc2626 !important;
    border-color: #ef4444 !important;
}

.vchat-meter-wrap {
    display: flex;
    align-items: center;
    gap: 12px;
    margin: 10px 0 14px;
}

.vchat-countdown {
    font-size: 0.82rem;
    color: #facc15;
    min-width: 150px;
}

.vchat-transcript-box {
    background: var(--input-bg);
    border: 1px solid var(--border-color);
    border-radius: 12px;
    padding: 14px;
    min-height: 220px;
    max-height: 360px;
    overflow-y: auto;
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.vchat-empty {
    text-align: center;
    color: var(--text-muted);
    margin: auto;
    font-size: 0.9rem;
}

.vchat-msg {
    padding: 9px 13px;
    border-radius: 10px;
    line-height: 1.7;
    font-size: 0.95rem;
}

.vchat-msg.user {
    background: rgba(56, 189, 248, 0.12);
    border-right: 3px solid #38bdf8;
}

.vchat-msg.assistant {
    background: rgba(16, 185, 129, 0.12);
    border-right: 3px solid #10b981;
}

.vchat-role {
    font-weight: bold;
    margin-left: 6px;
}