/* «🤖 ИИ-собеседник группы» — шторка настроек персоны (js/persona.js).
   Всё namespaced .aya-pers-*; переменные темы — с фолбэками (как autoreply.css). */

.aya-pers-overlay {
    position: fixed;
    inset: 0;
    z-index: 1300;
    background: rgba(0, 0, 0, 0.42);
    display: flex;
    align-items: flex-end;
    justify-content: center;
    opacity: 0;
    transition: opacity 0.2s ease;
}
.aya-pers-overlay.aya-pers-show { opacity: 1; }

.aya-pers-sheet {
    width: 100%;
    max-width: 560px;
    background: var(--bg-primary, var(--bg, #fff));
    color: var(--text, inherit);
    border-radius: 18px 18px 0 0;
    padding: 8px 18px calc(18px + env(safe-area-inset-bottom, 0px));
    box-shadow: 0 -8px 32px rgba(0, 0, 0, 0.25);
    transform: translateY(24px);
    transition: transform 0.2s ease;
}
.aya-pers-overlay.aya-pers-show .aya-pers-sheet { transform: translateY(0); }

.aya-pers-grip {
    width: 38px;
    height: 4px;
    border-radius: 2px;
    background: var(--border, rgba(120, 120, 128, 0.35));
    margin: 4px auto 12px;
}

.aya-pers-title {
    font-size: 18px;
    font-weight: 700;
    text-align: center;
}
.aya-pers-desc {
    font-size: 13px;
    line-height: 1.4;
    color: var(--text-muted, #8a8a8e);
    text-align: center;
    margin: 6px 0 14px;
}

.aya-pers-card {
    border-radius: 14px;
    background: var(--input-bg, rgba(120, 120, 128, 0.10));
    overflow: hidden;
}
.aya-pers-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 10px;
    padding: 13px 14px;
    cursor: pointer;
    user-select: none;
}
.aya-pers-row-label { font-size: 15px; }

/* Тумблер (рисуем свой, чтобы не зависеть от contact-info.css). */
.aya-pers-toggle {
    flex: 0 0 auto;
    width: 46px;
    height: 28px;
    border-radius: 14px;
    background: var(--border, rgba(120, 120, 128, 0.32));
    position: relative;
    transition: background 0.18s ease;
}
.aya-pers-toggle::after {
    content: '';
    position: absolute;
    top: 2px;
    left: 2px;
    width: 24px;
    height: 24px;
    border-radius: 50%;
    background: #fff;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.3);
    transition: left 0.18s ease;
}
.aya-pers-toggle.aya-pers-on { background: var(--brand, #2f6fed); }
.aya-pers-toggle.aya-pers-on::after { left: 20px; }

.aya-pers-extra { margin-top: 14px; }
.aya-pers-extra--off { display: none; }

.aya-pers-label {
    font-size: 12px;
    text-transform: uppercase;
    letter-spacing: 0.4px;
    color: var(--text-muted, #8a8a8e);
    margin: 10px 2px 6px;
}
.aya-pers-name {
    width: 100%;
    box-sizing: border-box;
    padding: 11px 12px;
    border-radius: 12px;
    border: 1px solid var(--border, rgba(120, 120, 128, 0.28));
    background: var(--input-bg, rgba(120, 120, 128, 0.10));
    color: var(--text, inherit);
    font-size: 15px;
    outline: none;
}
.aya-pers-name:focus { border-color: var(--brand, #2f6fed); }

.aya-pers-chips {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
}
.aya-pers-chip {
    border: 1px solid var(--border, rgba(120, 120, 128, 0.28));
    background: var(--input-bg, rgba(120, 120, 128, 0.10));
    color: var(--text, inherit);
    font-size: 14px;
    padding: 8px 14px;
    border-radius: 18px;
    cursor: pointer;
}
.aya-pers-chip--on {
    background: var(--brand, #2f6fed);
    border-color: var(--brand, #2f6fed);
    color: #fff;
}

.aya-pers-save {
    display: block;
    width: 100%;
    margin-top: 16px;
    padding: 13px;
    border: none;
    border-radius: 12px;
    background: var(--brand, #2f6fed);
    color: #fff;
    font-size: 16px;
    font-weight: 600;
    cursor: pointer;
}
.aya-pers-save:disabled { opacity: 0.55; cursor: default; }
