/* =========================================
   1. ПЕРЕМЕННЫЕ И БАЗОВЫЕ НАСТРОЙКИ
========================================= */
:root {
    --bg-main: #0B0C10;
    --bg-surface: #121318;
    --bg-card-light: #F4EAD6;
    --bg-input: #1C1E26;

    --gold-main: #C49A45;
    --gold-hover: #d6af5b;
    --success-green: #6DA37A;
    --error-red: #ff4d4f;

    --text-white: #FFFFFF;
    --text-muted: #888B94;
    --text-dark: #1A1A1A;

    --border-color: #2A2C35;
    --border-focus: #C49A45;

    --transition-base: 0.3s ease;
    
    --radius-sm: 8px;
    --radius-md: 12px;
    --radius-lg: 16px;
    --radius-xl: 20px;
}

* {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
}

body {
    background-color: var(--bg-main);
    color: var(--text-white);
    display: flex;
    justify-content: center;
    min-height: 100vh;
}

/* =========================================
   2. УТИЛИТЫ И ТИПОГРАФИКА
========================================= */
.hidden {
    display: none !important;
}

.mt-20 {
    margin-top: 20px;
}

.text-muted {
    color: var(--text-muted);
    font-size: 14px;
    margin-bottom: 30px;
}

.text-muted-dark {
    color: #666;
    font-size: 12px;
    margin-bottom: 4px;
}

.error-text {
    color: var(--error-red);
    font-size: 14px;
    margin: -15px 0 15px 0;
    transition: opacity var(--transition-base);
}

h3 {
    font-size: 18px;
    margin: 24px 0 16px 0;
}

/* =========================================
   3. ЛАЙАУТ И ЭКРАНЫ
========================================= */
.screen {
    display: none;
    width: 100%;
    max-width: 480px; 
    min-height: 100vh; 
    background-color: var(--bg-surface);
    padding: 24px;
    flex-direction: column;
    box-shadow: 0 0 20px rgba(0,0,0,0.5);
    position: relative;
}

.screen.active {
    display: flex;
}

.main-screen {
    padding-bottom: 90px;
    justify-content: flex-start;
}

.top-bar, 
.top-bar-simple {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 20px;
}

.top-bar-left {
    display: flex;
    align-items: center;
    gap: 10px;
}

.top-bar-actions {
    display: flex;
    gap: 10px;
}

/* =========================================
   4. НИЖНЯЯ НАВИГАЦИЯ
========================================= */
.bottom-nav {
    position: fixed; 
    bottom: 0; 
    left: 0; 
    right: 0; 
    max-width: 480px; 
    margin: 0 auto;
    height: 80px; 
    background-color: var(--bg-surface); 
    border-top: 1px solid var(--border-color);
    display: flex; 
    justify-content: space-around; 
    align-items: center; 
    z-index: 1000;
}

.nav-item {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 4px;
    cursor: pointer;
    color: var(--text-muted);
    transition: var(--transition-base);
    background: none;
    border: none;
}

.nav-icon {
    font-size: 20px;
}

.nav-text {
    font-size: 10px;
}

.nav-item.active {
    color: var(--gold-main);
}

.nav-item.active .nav-icon {
    background: var(--gold-main);
    color: var(--text-dark);
    padding: 4px 16px;
    border-radius: var(--radius-lg);
}

/* =========================================
   5. КНОПКИ И БЕЙДЖИ
========================================= */
.btn {
    width: 100%; 
    padding: 16px; 
    border-radius: var(--radius-md);
    font-size: 16px; 
    font-weight: 600; 
    cursor: pointer;
    margin-bottom: 12px; 
    border: none; 
    transition: background-color 0.2s, border-color 0.2s;
}

.btn-primary {
    background-color: var(--gold-main);
    color: #000;
}

.btn-primary:hover {
    background-color: var(--gold-hover);
}

.btn-secondary {
    background-color: transparent;
    border: 1px solid var(--text-muted);
    color: var(--text-white);
}

.btn-secondary:hover {
    border-color: var(--text-white);
}

.btn-draft {
    background: var(--bg-input);
    color: var(--text-white);
    border: none;
    padding: 8px 16px;
    border-radius: var(--radius-xl);
    font-size: 12px;
    cursor: pointer;
}

.icon-btn {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    border: 1px solid var(--border-color);
    display: flex;
    justify-content: center;
    align-items: center;
    color: var(--gold-main);
    font-size: 18px;
    background: var(--bg-surface);
    cursor: pointer;
    position: relative;
}

.badge {
    background: var(--bg-card-light);
    color: var(--text-dark);
    padding: 4px 10px;
    border-radius: var(--radius-md);
    font-size: 12px;
    font-weight: bold;
}

.notification-badge {
    position: absolute;
    top: -5px;
    right: -5px;
    background-color: var(--error-red);
    color: var(--text-white);
    font-size: 10px;
    font-weight: bold;
    padding: 2px 6px;
    border-radius: 10px;
    box-shadow: 0 0 5px rgba(231, 76, 60, 0.5);
    z-index: 10;
}

/* =========================================
   6. ФОРМЫ И ИНПУТЫ
========================================= */
.input-group {
    margin-bottom: 20px;
}

.input-group label {
    display: block;
    font-size: 12px;
    color: var(--text-muted);
    margin-bottom: 8px;
}

.input-group input, 
.search-bar input, 
textarea, 
.chat-input input {
    width: 100%;
    background-color: var(--bg-input);
    border: 1px solid var(--border-color);
    color: var(--text-white);
    outline: none;
    transition: border var(--transition-base);
}

.input-group input {
    padding: 16px;
    border-radius: var(--radius-md);
    font-size: 16px;
    background-color: transparent;
}

.search-bar input {
    padding: 14px 16px;
    border-radius: var(--radius-md);
    font-size: 14px;
    margin-bottom: 16px;
}

textarea {
    padding: 16px;
    border-radius: var(--radius-md);
    font-size: 14px;
    resize: none;
}

.chat-input input {
    flex: 1;
    border-radius: var(--radius-xl);
    padding: 12px 16px;
}

.input-group input:focus, 
.search-bar input:focus, 
textarea:focus, 
.chat-input input:focus {
    border-color: var(--border-focus);
}

.form-row {
    display: flex;
    gap: 12px;
}

.half, .third {
    flex: 1;
}

.code-inputs {
    display: flex;
    justify-content: space-between;
    gap: 8px;
    margin: 30px 0;
}

.code-box {
    width: 48px;
    height: 56px;
    background-color: transparent;
    border: 1px solid var(--border-color);
    border-radius: var(--radius-md);
    text-align: center;
    font-size: 24px;
    color: var(--text-white);
    outline: none;
    transition: border var(--transition-base);
}

.code-box:focus {
    border-color: var(--border-focus);
}

.code-box.error-border {
    border-color: var(--error-red);
    color: var(--error-red);
    animation: shake 0.3s ease-in-out;
}

/* =========================================
   7. АВАТАРЫ И КАРТОЧКИ
========================================= */
.avatar, 
.avatar-small, 
.avatar-large, 
.avatar-circle {
    display: flex;
    justify-content: center;
    align-items: center;
    border-radius: 50%;
    font-weight: bold;
}

.avatar {
    width: 50px;
    height: 50px;
    background: #E8D8BA;
    font-size: 20px;
    color: var(--text-dark);
}

.avatar-small {
    width: 40px;
    height: 40px;
    background: #E8D8BA;
    color: var(--text-dark);
}

.avatar-large {
    width: 70px;
    height: 70px;
    background: #E8D8BA;
    font-size: 28px;
    color: var(--text-dark);
}

.avatar-circle {
    width: 56px;
    height: 56px;
    color: var(--text-dark);
    font-size: 20px;
}

.light-card {
    background: var(--bg-card-light);
    border-radius: var(--radius-xl);
    padding: 20px;
    color: var(--text-dark);
    margin-bottom: 16px;
}

.dark-card {
    background: var(--bg-input);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-lg);
    padding: 16px;
    margin-bottom: 16px;
}

/* =========================================
   8. ЭКРАНЫ АВТОРИЗАЦИИ
========================================= */
#screen-splash {
    background-color: var(--bg-main);
    padding: 0;
}

.splash-container {
    flex: 1;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
}

.logo-large {
    width: 220px;
    max-width: 60%;
    height: auto;
    margin-bottom: 20px;
}

.loader {
    margin-top: 30px;
    width: 24px;
    height: 24px;
    border: 3px solid rgba(196, 154, 69, 0.3);
    border-top: 3px solid var(--gold-main);
    border-radius: 50%;
    animation: spin 1s linear infinite;
}

.auth-header, 
.verify-header {
    display: flex;
    align-items: center;
    gap: 12px;
    margin: 20px 0 40px 0;
}

.brand-title {
    font-size: 18px;
    text-transform: uppercase;
    letter-spacing: 1px;
}

.brand-title-small {
    font-size: 14px;
    text-transform: uppercase;
    letter-spacing: 1px;
    font-weight: bold;
}

.brand-subtitle {
    font-size: 12px;
    color: var(--text-muted);
}

.brand-subtitle-micro {
    font-size: 10px;
    color: var(--text-muted);
}

.logo-micro { width: 32px; }
.logo-shield { width: 64px; margin-bottom: 20px; }

.auth-body h2 { font-size: 24px; margin-bottom: 8px; }
.verify-body { text-align: center; }

.forgot-password { text-align: right; margin-bottom: 24px; }
.forgot-password a { color: var(--gold-main); font-size: 12px; text-decoration: none; }
.terms-text { text-align: center; font-size: 11px; color: var(--text-muted); margin-top: 30px; line-height: 1.5; }
.timer-text { font-size: 12px; color: var(--text-muted); margin-bottom: 30px; }
.back-btn { background: none; border: none; color: var(--text-white); font-size: 16px; cursor: pointer; }

/* ВЫБОР РОЛИ */
.role-body { text-align: center; margin-top: 20px; }
.role-body h2 { font-size: 24px; margin-bottom: 8px; }
.role-cards { display: flex; flex-direction: column; gap: 16px; margin-top: 30px; }

.role-card {
    background: var(--bg-input);
    border: 2px solid var(--border-color);
    border-radius: var(--radius-xl);
    padding: 24px;
    text-align: left;
    cursor: pointer;
    transition: var(--transition-base);
    color: var(--text-white);
    display: block;
    width: 100%;
}

.role-card:hover, .role-card:active {
    border-color: var(--gold-main);
    background: rgba(196, 154, 69, 0.05);
}

.role-icon { font-size: 32px; display: block; margin-bottom: 12px; }
.role-card h3 { margin: 0 0 8px 0; font-size: 18px; color: var(--gold-main); }
.role-card p { margin: 0; font-size: 13px; color: var(--text-muted); line-height: 1.4; }

/* =========================================
   9. КАТАЛОГ И КАРТОЧКИ МАСТЕРОВ
========================================= */
.filter-row {
    display: flex;
    justify-content: space-between;
    margin-bottom: 24px;
}

.location-chip {
    padding: 10px 16px;
    border-radius: var(--radius-xl);
    border: 1px solid var(--border-color);
    font-size: 14px;
    background: var(--bg-input);
}

.section-title {
    display: flex;
    align-items: center;
    gap: 10px;
}

.master-card-header {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    margin-bottom: 12px;
}

.master-info {
    flex: 1;
    margin-left: 12px;
}

.master-info h4 { font-size: 16px; margin-bottom: 4px; }
.verified { color: var(--gold-main); font-size: 12px; }
.rating-city { font-size: 12px; color: #666; }
.heart-icon { color: var(--gold-main); font-size: 24px; background: none; border: none; cursor: pointer; }
.master-desc { font-size: 14px; line-height: 1.4; margin-bottom: 16px; }

.master-card-footer {
    display: flex;
    justify-content: space-between;
    font-size: 12px;
    font-weight: bold;
}

.status-green { color: var(--success-green); }
.profile-link { color: var(--text-dark); text-decoration: none; }

/* =========================================
   10. ПРОФИЛЬ, РЕЖИМЫ И СТАТИСТИКА
========================================= */
.profile-header-info {
    display: flex;
    align-items: center;
    gap: 16px;
    margin-bottom: 20px;
}

.verified-badge {
    background: rgba(196, 154, 69, 0.2);
    color: #A57D33;
    padding: 4px 8px;
    border-radius: var(--radius-md);
    font-size: 11px;
    font-weight: bold;
}

.profile-stats {
    display: flex;
    justify-content: space-between;
    gap: 10px;
    margin-bottom: 8px;
}

.stat-box {
    flex: 1;
    background: rgba(0,0,0,0.05);
    border-radius: var(--radius-md);
    padding: 14px 8px;
    text-align: center;
}

.stat-value {
    font-size: 18px;
    font-weight: bold;
    margin-bottom: 4px;
    color: var(--text-dark);
}

.stat-label {
    font-size: 11px;
    color: #666;
}

.account-mode {
    margin-top: 25px;
    margin-bottom: 20px;
}

.mode-toggle {
    display: flex;
    background: #1e1e1e;
    border-radius: 8px;
    overflow: hidden;
    margin-top: 10px;
    border: 1px solid rgba(255, 255, 255, 0.05);
}

.mode-toggle .mode {
    flex: 1;
    padding: 12px;
    text-align: center;
    background: none;
    border: none;
    color: #888;
    cursor: pointer;
    transition: all 0.3s ease;
    font-size: 14px;
    font-weight: bold;
}

.mode-toggle .mode.active {
    background: var(--gold-main);
    color: var(--text-dark);
}

/* =========================================
   11. ПОРТФОЛИО (ДО И ПОСЛЕ)
========================================= */
#portfolio-upload-form {
    border: 1px dashed var(--gold-main);
    background: rgba(196, 154, 69, 0.05);
}

#portfolio-upload-form input[type="file"] {
    background: #1e1e1e;
    border-radius: 4px;
    padding: 5px;
    border: 1px solid rgba(255, 255, 255, 0.1);
}

.portfolio-grid {
    display: flex;
    flex-direction: column;
    gap: 15px;
    margin-bottom: 24px;
}

.portfolio-item-wrapper {
    border-radius: 8px;
    overflow: hidden;
    background: #2a2a2a;
    border: 1px solid rgba(255, 255, 255, 0.1);
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.2);
}

.portfolio-item-wrapper > div:first-child {
    padding: 12px;
    font-weight: bold;
    font-size: 14px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.05);
    background: #1e1e1e;
}

/* =========================================
   12. КАЛЕНДАРЬ
========================================= */
.calendar-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 16px;
}

.cal-nav-btn {
    background: none;
    border: none;
    font-size: 16px;
    cursor: pointer;
    color: var(--text-dark);
    padding: 4px 8px;
}

.calendar-title {
    font-size: 16px;
    font-weight: bold;
    margin: 0;
}

.calendar-grid {
    display: grid;
    grid-template-columns: repeat(7, 1fr);
    gap: 6px;
    text-align: center;
}

.weekday {
    font-size: 12px;
    color: #666;
    font-weight: bold;
    margin-bottom: 8px;
}

.day {
    position: relative;
    font-size: 14px;
    height: 36px;
    display: flex;
    justify-content: center;
    align-items: center;
    border-radius: var(--radius-sm);
}

.prev-month {
    color: #AFAFAF;
}

.has-dot {
    font-weight: bold;
}

.dot {
    position: absolute;
    bottom: 4px;
    width: 4px;
    height: 4px;
    background-color: var(--gold-main);
    border-radius: 50%;
}

.day.clickable-day {
    cursor: pointer;
    position: relative;
    text-align: center;
    padding: 6px 0;
    border-radius: 4px;
    transition: background 0.2s;
}

.day.day-working {
    border: 1px solid var(--gold-main);
    background: rgba(196, 154, 69, 0.2);
    color: var(--text-dark);
    font-weight: bold;
}

.day.day-weekend-striped {
    background: repeating-linear-gradient(
        45deg,
        rgba(196, 154, 69, 0.1),
        rgba(196, 154, 69, 0.1) 4px,
        transparent 4px,
        transparent 8px
    );
    border: 1px dashed var(--gold-main);
    color: var(--text-dark);
}

/* =========================================
   13. МОДАЛЬНЫЕ ОКНА (ПРИНУДИТЕЛЬНЫЙ ПОКАЗ)
========================================= */
#modal-notifications {
    position: fixed !important;
    top: 0 !important;
    left: 0 !important;
    width: 100vw !important;
    height: 100vh !important;
    background: rgba(0, 0, 0, 0.85) !important;
    z-index: 99999 !important;
    display: flex !important;
    justify-content: center !important;
    align-items: center !important;
    padding: 20px !important;
    box-sizing: border-box !important;
}

#modal-notifications.hidden {
    display: none !important;
}

/* =========================================
   14. ЧАТ И СООБЩЕНИЯ
========================================= */
.chat-avatars-scroll {
    display: flex;
    gap: 16px;
    overflow-x: auto;
    margin-bottom: 20px;
    padding-bottom: 10px;
}

.chat-avatar-item {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 8px;
    font-size: 12px;
    cursor: pointer;
}

.chat-avatar-item.active .avatar-circle {
    background: var(--gold-main);
}

.chat-window {
    padding: 0;
    display: flex;
    flex-direction: column;
    overflow: hidden;
}

.chat-header {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 16px;
    border-bottom: 1px solid rgba(0,0,0,0.05);
}

.chat-messages {
    padding: 16px;
    display: flex;
    flex-direction: column;
    gap: 12px;
    flex: 1;
    background: var(--bg-main);
    color: var(--text-white);
    height: 300px;
    overflow-y: auto;
}

.msg {
    padding: 12px 16px;
    border-radius: var(--radius-lg);
    font-size: 14px;
    max-width: 85%;
}

.msg-left {
    background: var(--bg-card-light);
    color: var(--text-dark);
    align-self: flex-start;
    border-bottom-left-radius: 4px;
}

.msg-right {
    background: var(--gold-hover);
    color: var(--text-dark);
    align-self: flex-end;
    border-bottom-right-radius: 4px;
}

.chat-input {
    display: flex;
    padding: 16px;
    background: var(--bg-main);
    gap: 12px;
    align-items: center;
}

.btn-send {
    width: 44px;
    height: 44px;
    background: var(--gold-main);
    border: none;
    border-radius: 50%;
    cursor: pointer;
}

.file-input-hidden {
    display: none;
}

.btn-attach {
    background: none;
    border: none;
    font-size: 20px;
    cursor: pointer;
    color: var(--text-muted);
}

.chat-avatars-scroll::-webkit-scrollbar,
.chat-messages::-webkit-scrollbar {
    width: 6px;
    height: 6px;
}

.chat-avatars-scroll::-webkit-scrollbar-thumb,
.chat-messages::-webkit-scrollbar-thumb {
    background: #444;
    border-radius: 4px;
}

/* =========================================
   15. АНИМАЦИИ И ПРОЧЕЕ
========================================= */
@keyframes spin { 
    100% { transform: rotate(360deg); } 
}

@keyframes shake { 
    0%, 100% { transform: translateX(0); } 
    25% { transform: translateX(-5px); } 
    50% { transform: translateX(5px); } 
    75% { transform: translateX(-5px); } 
}

/* =========================================
   16. ОСНОВНАЯ РОЛЬ — ПЕРВЫЙ ШАГ РЕГИСТРАЦИИ
========================================= */
.screen-toolbar {
    display: flex;
    align-items: center;
    gap: 10px;
    margin-bottom: 20px;
}

.screen-toolbar h1 {
    margin: 0;
    font-family: "Arial Narrow", "Roboto Condensed", -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
    font-size: 16px;
    font-weight: 800;
    letter-spacing: -0.2px;
}

.toolbar-back-btn {
    width: 44px;
    height: 44px;
    flex: 0 0 44px;
    display: grid;
    place-items: center;
    border: 0;
    border-radius: 12px;
    background: #17191f;
    color: var(--gold-main);
    font-size: 26px;
    line-height: 1;
    cursor: pointer;
}

.toolbar-back-btn:active {
    transform: translateY(1px);
}

.role-screen {
    background: #0d0f12;
    padding: 16px;
}

.role-screen .role-body {
    margin-top: 0;
    text-align: left;
}

.role-screen .role-body h2 {
    margin: 14px 0 14px;
    font-family: "Arial Narrow", "Roboto Condensed", -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
    font-size: 19px;
    line-height: 1.2;
    font-weight: 800;
}

.role-lead {
    margin: 0 0 18px;
    color: #8e8b88;
    font-size: 14px;
    line-height: 1.45;
}

.role-segmented {
    display: flex;
    width: 180px;
    margin: 0 auto 16px;
    padding: 3px;
    border: 1px solid #363941;
    border-radius: 999px;
    background: #16191e;
}

.role-segment {
    flex: 1;
    min-height: 36px;
    border: 0;
    border-radius: 999px;
    background: transparent;
    color: #928f8c;
    font-size: 13px;
    cursor: pointer;
}

.role-segment.active {
    background: #d2a53a;
    color: #121212;
    box-shadow: 0 0 0 1px rgba(232, 205, 137, 0.45);
}

.role-screen .role-cards {
    display: flex;
    flex-direction: column;
    gap: 14px;
    margin: 0;
}

.role-screen .role-card {
    width: 100%;
    min-height: 118px;
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    gap: 6px;
    padding: 16px;
    border: 1px solid #363b43;
    border-radius: 16px;
    background: #171a1f;
    color: #f7f7f7;
    text-align: left;
    cursor: pointer;
    transition: border-color 0.2s ease, background-color 0.2s ease, transform 0.15s ease;
}

.role-screen .role-card:hover {
    border-color: #665735;
}

.role-screen .role-card:active {
    transform: scale(0.995);
}

.role-screen .role-card.selected {
    border-color: #d2a53a;
    background: #f4efe5;
    color: #262626;
    box-shadow: inset 0 0 0 1px rgba(210, 165, 58, 0.18);
}

.role-card-title {
    display: block;
    font-size: 15px;
    line-height: 1.2;
    font-weight: 800;
}

.role-card-kicker {
    display: block;
    color: #d2a53a;
    font-size: 11px;
    line-height: 1.2;
    letter-spacing: 0.1px;
}

.role-card-text {
    display: block;
    color: #8e8b88;
    font-size: 14px;
    line-height: 1.45;
}

.role-card.selected .role-card-text {
    color: #87827c;
}

.role-screen #role-error {
    margin: 10px 0 0;
}

.role-continue-btn {
    margin-top: 16px;
    min-height: 49px;
    border-radius: 12px;
    background: #d2a53a;
    font-size: 13px;
    font-weight: 800;
}

/* =========================================
   17. НАСТРОЙКИ ПРОФИЛЯ
========================================= */
.settings-screen {
    background: #0d0f12;
    padding: 16px 16px 96px;
}

.settings-toolbar {
    margin-bottom: 7px;
}

.settings-subtitle {
    margin: 0 0 10px;
    color: #8a8783;
    font-size: 12px;
    line-height: 1.45;
}

.settings-photo-card {
    margin-bottom: 10px;
    padding: 10px;
    border: 1px solid #343941;
    border-radius: 15px;
    background: #171a1f;
}

.settings-photo-top {
    display: flex;
    align-items: center;
    gap: 14px;
    margin-bottom: 12px;
}

.settings-avatar-preview {
    width: 76px;
    height: 76px;
    flex: 0 0 76px;
    display: grid;
    place-items: center;
    overflow: hidden;
    border: 1px solid #d2a53a;
    border-radius: 50%;
    background: #f4efe5 center / cover no-repeat;
    color: #1c1c1c;
    font-size: 18px;
    font-weight: 800;
}

.settings-avatar-preview.has-photo,
.avatar-large.has-photo {
    background-position: center;
    background-size: cover;
    background-repeat: no-repeat;
}

.settings-photo-copy h2 {
    margin: 0 0 5px;
    font-size: 15px;
    font-weight: 800;
}

.settings-photo-copy p {
    margin: 0;
    color: #8a8783;
    font-size: 12px;
}

.settings-upload-btn {
    width: 100%;
    min-height: 48px;
    display: grid;
    place-items: center;
    border: 1px solid #e5cf98;
    border-radius: 12px;
    background: transparent;
    color: #efefef;
    font-size: 13px;
    font-weight: 700;
    cursor: pointer;
}

.settings-upload-btn:active {
    background: rgba(210, 165, 58, 0.08);
}

.settings-section-title {
    margin: 8px 0 8px;
    font-size: 16px;
    line-height: 1.2;
    font-weight: 800;
}

.settings-section-title.access-title {
    margin-top: 14px;
}

.settings-field {
    margin-bottom: 10px;
}

.settings-field label {
    display: block;
    margin-bottom: 7px;
    color: #777572;
    font-size: 10px;
}

.settings-input {
    width: 100%;
    min-height: 48px;
    padding: 0 14px !important;
    border: 1px solid #343941 !important;
    border-radius: 12px !important;
    outline: none;
    background: #171a1f !important;
    color: #f5f5f5 !important;
    font-size: 13px !important;
}

.settings-input::placeholder {
    color: #817e7a;
}

.settings-input:focus {
    border-color: var(--gold-main) !important;
}

.settings-role-row {
    min-height: 48px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    margin: 2px 0 8px;
    padding: 0 12px;
    border: 1px solid #343941;
    border-radius: 12px;
    background: #171a1f;
    font-size: 13px;
}

.settings-role-change {
    border: 0;
    background: transparent;
    color: #d2a53a;
    font-size: 12px;
    cursor: pointer;
}

.settings-role-picker {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 8px;
    margin: -2px 0 10px;
}

.settings-role-option {
    min-height: 40px;
    border: 1px solid #343941;
    border-radius: 10px;
    background: #171a1f;
    color: #aaa7a3;
    cursor: pointer;
}

.settings-role-option.active {
    border-color: var(--gold-main);
    background: rgba(210, 165, 58, 0.12);
    color: var(--gold-main);
}

.settings-inline-error {
    margin: 6px 0 10px;
    color: var(--error-red);
    font-size: 12px;
    line-height: 1.35;
}

.settings-inline-error.success {
    color: var(--success-green);
}

.settings-save-btn {
    min-height: 48px;
    margin: 0 0 8px;
    border-radius: 12px;
    background: #d2a53a;
    font-size: 13px;
    font-weight: 800;
}

.settings-logout-btn {
    min-height: 48px;
    margin: 0;
    border: 1px solid #e6604e;
    border-radius: 12px;
    background: transparent;
    color: #e6604e;
    font-size: 13px;
    font-weight: 700;
}

.settings-logout-btn:hover {
    background: rgba(230, 96, 78, 0.06);
}

.avatar-large {
    background-position: center;
    background-size: cover;
    background-repeat: no-repeat;
}

/* Кнопка "Создать" в нижней навигации теперь действительно работает. */
.nav-add {
    cursor: pointer;
}

.nav-icon-box {
    min-width: 22px;
    height: 22px;
    display: grid;
    place-items: center;
    border: 1px solid var(--gold-main);
    border-radius: 6px;
    color: var(--gold-main);
    font-size: 12px;
    line-height: 1;
}

/* На широком экране приложение выглядит как мобильный макет из референса. */
@media (min-width: 560px) {
    body {
        padding: 12px 0;
        background: #f6f6f6;
    }

    .screen {
        max-width: 360px;
        min-height: calc(100vh - 24px);
        border-radius: 24px;
        overflow-x: hidden;
    }

    .bottom-nav {
        max-width: 360px;
        bottom: 12px;
        border-radius: 0 0 24px 24px;
    }
}

@media (max-width: 380px) {
    .role-screen,
    .settings-screen {
        padding-left: 14px;
        padding-right: 14px;
    }

    .role-card-text {
        font-size: 13px;
    }
}

/* =========================================
   18. ТЗ: ЗАПУСК + ПОШАГОВОЕ СОЗДАНИЕ ПРОФИЛЯ
========================================= */
.splash-start-container {
    padding: 28px;
    text-align: center;
}

.splash-tagline {
    max-width: 260px;
    margin: 0 auto 26px;
    color: var(--text-muted);
    font-size: 15px;
    line-height: 1.5;
}

.splash-start-btn {
    max-width: 300px;
    margin-top: 18px;
}

.auth-note {
    margin-top: 12px;
    color: var(--text-muted);
    font-size: 12px;
    line-height: 1.45;
    text-align: center;
}

.onboarding-screen {
    background: #0d0f12;
    padding: 16px 16px 32px;
}

.onboarding-toolbar {
    display: flex;
    align-items: center;
    gap: 12px;
    margin-bottom: 12px;
}

.onboarding-toolbar-copy {
    min-width: 0;
}

.onboarding-toolbar-copy span {
    display: block;
    margin-bottom: 2px;
    color: #777b83;
    font-size: 10px;
    text-transform: uppercase;
    letter-spacing: .5px;
}

.onboarding-toolbar-copy h1 {
    margin: 0;
    font-size: 16px;
    line-height: 1.2;
}

.onboarding-progress {
    height: 4px;
    margin: 0 0 24px;
    overflow: hidden;
    border-radius: 999px;
    background: #23262d;
}

.onboarding-progress span {
    display: block;
    width: 11.111%;
    height: 100%;
    border-radius: inherit;
    background: var(--gold-main);
    transition: width .25s ease;
}

.onboarding-step {
    display: none;
    animation: onboardingFade .2s ease;
}

.onboarding-step.active {
    display: block;
}

@keyframes onboardingFade {
    from { opacity: 0; transform: translateY(4px); }
    to { opacity: 1; transform: translateY(0); }
}

.onboarding-step > h2,
.onboarding-role-body h2 {
    margin: 0 0 10px;
    font-size: 21px;
    line-height: 1.25;
}

.onboarding-lead {
    margin: 0 0 22px;
    color: #8e8b88;
    font-size: 14px;
    line-height: 1.5;
}

.onboarding-role-body {
    margin-top: 0;
    text-align: left;
}

.onboarding-role-body .role-cards {
    display: flex;
    flex-direction: column;
    gap: 14px;
    margin: 0;
}

.onboarding-role-body .role-card {
    width: 100%;
    min-height: 118px;
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    gap: 6px;
    padding: 16px;
    border: 1px solid #363b43;
    border-radius: 16px;
    background: #171a1f;
    color: #f7f7f7;
    text-align: left;
    cursor: pointer;
    transition: border-color .2s ease, background-color .2s ease, transform .15s ease;
}

.onboarding-role-body .role-card.selected {
    border-color: #d2a53a;
    background: #f4efe5;
    color: #262626;
    box-shadow: inset 0 0 0 1px rgba(210, 165, 58, .18);
}

.onboarding-photo-card {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 14px;
    padding: 22px 16px;
    border: 1px solid #343941;
    border-radius: 16px;
    background: #171a1f;
}

.onboarding-avatar-preview {
    width: 112px;
    height: 112px;
    display: grid;
    place-items: center;
    overflow: hidden;
    border: 1px solid var(--gold-main);
    border-radius: 50%;
    background: #f4efe5 center / cover no-repeat;
    color: #1c1c1c;
    font-size: 30px;
    font-weight: 800;
}

.onboarding-avatar-preview.has-photo {
    background-position: center;
    background-size: cover;
    background-repeat: no-repeat;
}

.onboarding-photo-card .settings-upload-btn {
    max-width: 260px;
}

.small-muted {
    margin: 0;
    color: #7f8188;
    font-size: 12px;
    line-height: 1.45;
    text-align: center;
}

.field-label {
    display: block;
    margin: 18px 0 10px;
    color: var(--text-muted);
    font-size: 12px;
}

.choice-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 10px;
}

.choice-grid.compact {
    grid-template-columns: repeat(2, minmax(0, 1fr));
}

.choice-chip {
    min-height: 48px;
    padding: 10px 12px;
    border: 1px solid #343941;
    border-radius: 12px;
    background: #171a1f;
    color: #aaa7a3;
    font-size: 13px;
    line-height: 1.25;
    cursor: pointer;
    transition: border-color .2s ease, background-color .2s ease, color .2s ease;
}

.choice-chip.selected {
    border-color: var(--gold-main);
    background: rgba(196, 154, 69, .14);
    color: #f0c968;
}

.tags-grid .choice-chip {
    min-height: 42px;
    font-size: 12px;
}

.schedule-time-label {
    margin-top: 24px;
}

.onboarding-geo-btn {
    margin-bottom: 10px;
}

#onboarding-geo-status {
    min-height: 34px;
    margin-bottom: 14px;
}

.textarea-counter {
    margin-top: 6px;
    color: #777b83;
    font-size: 11px;
    text-align: right;
}

.consent-card {
    display: flex;
    flex-direction: column;
    gap: 12px;
    margin: 10px 0 4px;
    padding: 14px;
    border: 1px solid #343941;
    border-radius: 14px;
    background: #171a1f;
}

.consent-row {
    display: flex;
    align-items: flex-start;
    gap: 10px;
    color: #b4b1ad;
    font-size: 12px;
    line-height: 1.45;
    cursor: pointer;
}

.consent-row input {
    width: 18px;
    height: 18px;
    margin-top: 1px;
    accent-color: var(--gold-main);
}

.consent-row a {
    color: var(--gold-main);
}

.onboarding-nav {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 10px;
    margin-top: 24px;
}

.onboarding-nav .btn:only-child,
.onboarding-nav .btn.hidden + .btn {
    grid-column: 1 / -1;
}

.onboarding-complete {
    flex: 1;
    min-height: 480px;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    text-align: center;
}

.complete-icon {
    width: 76px;
    height: 76px;
    display: grid;
    place-items: center;
    margin-bottom: 18px;
    border-radius: 50%;
    background: rgba(109, 163, 122, .15);
    color: var(--success-green);
    font-size: 38px;
}

.onboarding-complete h2 {
    margin: 0 0 10px;
    font-size: 24px;
}

/* =========================================
   19. ТЗ: ПРОФИЛЬ И НАСТРОЙКИ
========================================= */
.profile-edit-btn {
    margin: 0 0 8px;
}

.settings-textarea {
    min-height: 108px !important;
    padding: 12px 14px !important;
    resize: vertical;
}

.settings-select {
    appearance: none;
    cursor: pointer;
}

.settings-toggle-row {
    min-height: 62px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
    margin-bottom: 12px;
    padding: 10px 12px;
    border: 1px solid #343941;
    border-radius: 12px;
    background: #171a1f;
}

.settings-toggle-row span {
    display: flex;
    flex-direction: column;
    gap: 4px;
}

.settings-toggle-row strong {
    color: #f3f3f3;
    font-size: 13px;
}

.settings-toggle-row small {
    color: #777b83;
    font-size: 10px;
    line-height: 1.35;
}

.settings-toggle-row input {
    width: 20px;
    height: 20px;
    accent-color: var(--gold-main);
}

.settings-links-card {
    margin: 8px 0 14px;
    overflow: hidden;
    border: 1px solid #343941;
    border-radius: 12px;
    background: #171a1f;
}

.settings-link-row {
    width: 100%;
    min-height: 48px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 0 14px;
    border: 0;
    border-bottom: 1px solid #2a2e35;
    background: transparent;
    color: #e8e8e8;
    font-size: 13px;
    text-align: left;
    cursor: pointer;
}

.settings-link-row:last-child {
    border-bottom: 0;
}

.settings-link-row span {
    color: var(--gold-main);
    font-size: 22px;
}

.settings-delete-btn {
    min-height: 48px;
    margin-top: 8px;
    border: 1px solid #8b3a31;
    border-radius: 12px;
    background: transparent;
    color: #d78b80;
    font-size: 13px;
    font-weight: 700;
}

/* =========================================
   20. ТЗ: ЗАЯВКИ И ПУСТЫЕ СОСТОЯНИЯ
========================================= */
.empty-state {
    margin-top: 40px;
    padding: 24px 16px;
    color: var(--text-muted);
    text-align: center;
}

.empty-state-icon {
    margin-bottom: 10px;
    font-size: 34px;
}

.orders-loading {
    margin-top: 28px;
    text-align: center;
}

.order-card-accent {
    margin: 10px 0;
}

.order-card-header {
    display: flex;
    justify-content: space-between;
    gap: 12px;
}

.order-price {
    color: var(--gold-main);
    font-weight: 700;
    white-space: nowrap;
}

.order-meta,
.order-public-location {
    margin: 8px 0;
    font-size: 13px;
    line-height: 1.45;
}

.order-public-location {
    color: var(--text-muted);
    font-size: 12px;
}

.order-private-address {
    margin: 8px 0;
    padding: 9px;
    border-radius: 8px;
    background: rgba(196, 154, 69, .08);
    font-size: 12px;
    line-height: 1.45;
}

.order-status {
    font-size: 12px;
    font-weight: 700;
}

.completion-prompt {
    margin-top: 12px;
    padding-top: 10px;
    border-top: 1px solid rgba(255,255,255,.1);
}

.completion-prompt p {
    margin-bottom: 8px;
    font-size: 13px;
}

.completion-actions {
    display: flex;
    gap: 8px;
}

.btn-complete-order {
    padding: 7px 12px;
    border: 0;
    border-radius: 7px;
    background: #287c4b;
    color: #fff;
    cursor: pointer;
}

.btn-complete-order.negative {
    background: #8b3a31;
}

.create-order-toolbar {
    gap: 10px;
}

.create-order-toolbar h2 {
    flex: 1;
    margin: 0;
    font-size: 20px;
}

@media (max-width: 380px) {
    .choice-grid {
        grid-template-columns: 1fr;
    }

    .choice-grid.compact {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }
}

/* =========================================
   21. ТЗ: ПОЛНЫЙ СЦЕНАРИЙ ЗАЯВОК / ОТКЛИКОВ
========================================= */
.eyebrow {
    margin: 0 0 4px;
    color: var(--gold-main);
    font-size: 10px;
    font-weight: 800;
    letter-spacing: .12em;
}

.orders-toolbar {
    align-items: flex-start;
}

.orders-toolbar h2 {
    margin: 0;
}

.order-tabs {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 6px;
    margin-bottom: 16px;
    padding: 4px;
    background: var(--bg-input);
    border: 1px solid var(--border-color);
    border-radius: 14px;
}

.order-tab {
    min-width: 0;
    padding: 10px 5px;
    border: 0;
    border-radius: 10px;
    background: transparent;
    color: var(--text-muted);
    font-size: 11px;
    font-weight: 700;
    cursor: pointer;
}

.order-tab span {
    display: inline-flex;
    min-width: 18px;
    height: 18px;
    margin-left: 2px;
    padding: 0 5px;
    align-items: center;
    justify-content: center;
    border-radius: 999px;
    background: rgba(255,255,255,.07);
    font-size: 10px;
}

.order-tab.active {
    background: var(--gold-main);
    color: var(--text-dark);
}

.order-tab.active span {
    background: rgba(0,0,0,.12);
}

.orders-master-toolbar {
    margin-bottom: 14px;
}

.orders-search-bar input {
    margin-bottom: 10px;
}

.order-filter-row {
    display: flex;
    gap: 10px;
    align-items: center;
}

.order-filter-select,
.form-select {
    width: 100%;
    min-height: 48px;
    padding: 0 14px;
    border: 1px solid var(--border-color);
    border-radius: var(--radius-md);
    outline: none;
    background: var(--bg-input);
    color: var(--text-white);
    font: inherit;
}

.order-filter-select:focus,
.form-select:focus {
    border-color: var(--border-focus);
}

.order-filter-row .order-filter-select {
    flex: 1;
}

.orders-context-note,
.create-order-lead,
.privacy-note {
    margin: 0 0 16px;
    color: var(--text-muted);
    font-size: 12px;
    line-height: 1.5;
}

.privacy-note {
    margin-top: -8px;
    padding: 10px 12px;
    border: 1px solid rgba(196,154,69,.18);
    border-radius: 10px;
    background: rgba(196,154,69,.06);
}

.order-feed-card {
    margin-bottom: 14px;
    padding: 16px;
    border: 1px solid var(--border-color);
    border-radius: 16px;
    background: var(--bg-input);
}

.order-feed-topline,
.response-master-row,
.modal-header-row,
.field-label-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 10px;
}

.order-feed-card h3 {
    margin: 12px 0 6px;
    font-size: 17px;
    line-height: 1.25;
}

.order-category-badge {
    display: inline-flex;
    padding: 5px 8px;
    border-radius: 999px;
    background: rgba(196,154,69,.12);
    color: var(--gold-main);
    font-size: 11px;
    font-weight: 700;
}

.order-budget {
    color: var(--text-white);
    font-size: 13px;
    font-weight: 800;
    text-align: right;
}

.order-feed-meta,
.order-client-line,
.order-feed-description {
    margin: 6px 0;
    font-size: 13px;
    line-height: 1.45;
}

.order-feed-meta,
.order-client-line {
    color: var(--text-muted);
    font-size: 12px;
}

.order-client-line strong {
    color: var(--text-white);
}

.order-feed-description {
    margin-top: 11px;
}

.order-privacy-line {
    margin: 12px 0;
    padding-top: 10px;
    border-top: 1px solid rgba(255,255,255,.07);
    color: var(--text-muted);
    font-size: 11px;
}

.order-primary-action {
    width: 100%;
    min-height: 44px;
    margin-top: 10px;
    padding: 10px 14px;
    border: 0;
    border-radius: 11px;
    background: var(--gold-main);
    color: var(--text-dark);
    font-weight: 800;
    cursor: pointer;
}

.order-primary-action.muted,
.order-primary-action:disabled {
    background: #2a2d34;
    color: var(--text-muted);
    cursor: default;
}

.order-status-chip {
    padding: 5px 8px;
    border-radius: 999px;
    font-size: 10px;
    font-weight: 800;
}

.order-status-chip.active {
    background: rgba(109,163,122,.14);
    color: var(--success-green);
}

.order-status-chip.progress {
    background: rgba(196,154,69,.15);
    color: var(--gold-main);
}

.order-status-chip.completed {
    background: rgba(136,139,148,.13);
    color: var(--text-muted);
}

.order-secondary-actions {
    display: flex;
    justify-content: center;
    gap: 18px;
    margin-top: 8px;
}

.order-text-action {
    padding: 7px 0;
    border: 0;
    background: none;
    color: var(--text-muted);
    font-size: 12px;
    cursor: pointer;
}

.order-text-action.danger {
    color: #e06a5f;
}

.responses-count-pill {
    display: inline-flex;
    min-width: 20px;
    height: 20px;
    margin-left: 5px;
    padding: 0 6px;
    align-items: center;
    justify-content: center;
    border-radius: 999px;
    background: rgba(0,0,0,.14);
    font-size: 10px;
}

.form-section-title {
    margin: 18px 0 12px;
    font-size: 15px;
}

.field-label-row label {
    margin-bottom: 8px;
}

.field-label-row span {
    margin-bottom: 8px;
    color: var(--text-muted);
    font-size: 11px;
}

.check-row {
    display: flex;
    gap: 10px;
    align-items: center;
    color: var(--text-white);
    font-size: 13px;
    cursor: pointer;
}

.check-row input {
    width: 18px;
    height: 18px;
    accent-color: var(--gold-main);
}

.budget-negotiable-row {
    margin-top: -8px;
    margin-bottom: 14px;
}

.app-modal {
    position: fixed;
    inset: 0;
    z-index: 3000;
    display: flex;
    align-items: flex-end;
    justify-content: center;
    padding: 18px;
    background: rgba(0,0,0,.72);
    backdrop-filter: blur(4px);
}

.app-modal.hidden {
    display: none !important;
}

.app-modal-card {
    width: min(100%, 440px);
    max-height: 86vh;
    overflow-y: auto;
    padding: 20px;
    border: 1px solid var(--border-color);
    border-radius: 22px;
    background: var(--bg-surface);
    box-shadow: 0 20px 60px rgba(0,0,0,.45);
}

.modal-header-row {
    align-items: flex-start;
    margin-bottom: 12px;
}

.modal-header-row h2 {
    margin: 0;
    font-size: 20px;
}

.modal-close-btn {
    width: 38px;
    height: 38px;
    flex: 0 0 38px;
    border: 1px solid var(--border-color);
    border-radius: 50%;
    background: var(--bg-input);
    color: var(--text-white);
    font-size: 22px;
    cursor: pointer;
}

.response-order-summary {
    margin: 0 0 18px;
    color: var(--text-muted);
    font-size: 12px;
    line-height: 1.45;
}

.responses-list {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.response-card {
    padding: 14px;
    border: 1px solid var(--border-color);
    border-radius: 14px;
    background: var(--bg-input);
}

.response-master-row {
    align-items: center;
}

.response-master-row > div:nth-child(2) {
    min-width: 0;
    flex: 1;
}

.response-master-row h3 {
    margin: 0 0 3px;
    font-size: 14px;
}

.response-master-row p {
    margin: 0;
    color: var(--gold-main);
    font-size: 11px;
}

.response-master-row strong {
    max-width: 35%;
    color: var(--gold-main);
    font-size: 12px;
    text-align: right;
}

.response-avatar {
    width: 42px;
    height: 42px;
    display: flex;
    align-items: center;
    justify-content: center;
    flex: 0 0 42px;
    border-radius: 50%;
    background: var(--bg-card-light);
    color: var(--text-dark);
    font-weight: 800;
}

.response-message {
    margin: 12px 0;
    color: var(--text-white);
    font-size: 13px;
    line-height: 1.5;
}

.response-actions {
    display: grid;
    grid-template-columns: 1fr 1.4fr;
    gap: 8px;
}

.btn-response-reject,
.btn-response-accept {
    min-height: 42px;
    border-radius: 10px;
    font-weight: 800;
    cursor: pointer;
}

.btn-response-reject {
    border: 1px solid #6f3c38;
    background: transparent;
    color: #e06a5f;
}

.btn-response-accept {
    border: 0;
    background: var(--gold-main);
    color: var(--text-dark);
}

.response-resolved {
    padding: 8px 10px;
    border-radius: 9px;
    text-align: center;
    font-size: 12px;
    font-weight: 700;
}

.response-resolved.accepted {
    background: rgba(109,163,122,.13);
    color: var(--success-green);
}

.response-resolved.rejected,
.response-resolved.declined {
    background: rgba(255,77,79,.08);
    color: #e06a5f;
}

.match-card {
    text-align: center;
}

.match-icon {
    margin: 4px 0 10px;
    font-size: 48px;
}

.match-card h2 {
    margin-bottom: 8px;
}

.match-card p {
    margin: 0 0 22px;
    color: var(--text-muted);
    line-height: 1.5;
}

.empty-state.compact {
    margin-top: 0;
    padding: 18px 8px;
}

.orders-skeleton {
    display: grid;
    gap: 12px;
}

.orders-skeleton span {
    height: 126px;
    border-radius: 16px;
    background: linear-gradient(90deg, var(--bg-input), #252832, var(--bg-input));
    background-size: 220% 100%;
    animation: ordersPulse 1.4s infinite linear;
}

.completion-actions.three {
    display: grid;
    grid-template-columns: 1fr 1.25fr .8fr;
}

.btn-complete-order.postpone {
    background: #8f6c24;
}

@keyframes ordersPulse {
    from { background-position: 120% 0; }
    to { background-position: -100% 0; }
}

@media (min-width: 600px) {
    .app-modal {
        align-items: center;
    }
}

@media (max-width: 380px) {
    .order-tabs {
        grid-template-columns: 1fr;
    }
    .completion-actions.three {
        grid-template-columns: 1fr;
    }
}

/* =========================================
   ЧАТ — список сделок и вложения (MVP ТЗ)
========================================= */
.chat-header-hint {
    color: var(--text-muted);
    font-size: 12px;
    text-transform: uppercase;
    letter-spacing: .08em;
}

.chat-list {
    display: flex;
    flex-direction: column;
    gap: 8px;
    margin-bottom: 16px;
}

.chat-list-item {
    width: 100%;
    display: grid;
    grid-template-columns: 48px minmax(0, 1fr) auto;
    gap: 12px;
    align-items: center;
    padding: 12px;
    border: 1px solid var(--border-color);
    border-radius: var(--radius-md);
    background: var(--bg-input);
    color: var(--text-white);
    text-align: left;
    cursor: pointer;
}

.chat-list-item.active {
    border-color: var(--gold-main);
    box-shadow: inset 0 0 0 1px rgba(196, 154, 69, .18);
}

.chat-list-avatar {
    width: 48px;
    height: 48px;
    background-size: cover;
    background-position: center;
    flex-shrink: 0;
}

.chat-list-copy {
    min-width: 0;
    display: flex;
    flex-direction: column;
    gap: 4px;
}

.chat-list-copy strong,
.chat-list-copy small {
    overflow: hidden;
    white-space: nowrap;
    text-overflow: ellipsis;
}

.chat-list-copy small {
    color: var(--text-muted);
    font-size: 12px;
}

.chat-unread-badge {
    min-width: 22px;
    height: 22px;
    padding: 0 6px;
    border-radius: 999px;
    background: var(--gold-main);
    color: var(--text-dark);
    display: inline-flex;
    align-items: center;
    justify-content: center;
    font-size: 11px;
    font-weight: 700;
}

.chat-history-empty {
    margin: auto;
    padding: 24px 12px;
    text-align: center;
    color: var(--text-muted);
    font-size: 13px;
}

.chat-history-empty.error {
    color: var(--error-red);
}

.chat-message-image {
    display: block;
    max-width: min(240px, 100%);
    max-height: 300px;
    object-fit: cover;
    border-radius: 10px;
    margin-bottom: 7px;
}

.chat-message-time {
    display: block;
    margin-top: 5px;
    font-size: 10px;
    opacity: .65;
    text-align: right;
}

.chat-upload-status {
    min-height: 18px;
    margin: -8px 16px 8px;
    color: var(--text-muted);
    font-size: 11px;
}

.btn-send {
    color: var(--text-dark);
    font-size: 18px;
    font-weight: 700;
}

/* =========================================
   ЗАВЕРШЕНИЕ СДЕЛКИ — ДВУСТОРОННЕЕ ПОДТВЕРЖДЕНИЕ
========================================= */
.master-order-tabs {
    margin-bottom: 14px;
}

.completion-prompt.waiting {
    border-color: rgba(196, 154, 69, .45);
    background: rgba(196, 154, 69, .08);
}

.completion-prompt.attention {
    border-color: rgba(109, 163, 122, .45);
    background: rgba(109, 163, 122, .08);
}

.completion-prompt.warning {
    border-color: rgba(255, 77, 79, .45);
    background: rgba(255, 77, 79, .07);
}

.btn-complete-order.selected {
    outline: 2px solid var(--text-white);
    outline-offset: 2px;
}

.completion-result {
    margin-top: 16px;
    padding: 13px 14px;
    border-radius: var(--radius-md);
    font-size: 12px;
    font-weight: 700;
    line-height: 1.45;
}

.completion-result.success {
    background: rgba(109, 163, 122, .12);
    color: var(--success-green);
    border: 1px solid rgba(109, 163, 122, .28);
}

.completion-result.danger {
    background: rgba(255, 77, 79, .08);
    color: #e06a5f;
    border: 1px solid rgba(255, 77, 79, .25);
}

.master-assigned-card .order-private-address {
    margin-top: 12px;
}

/* =========================================
   БЕЗОПАСНОСТЬ: БЛОКИРОВКИ И ЖАЛОБЫ
========================================= */
.chat-header-copy {
    flex: 1;
    min-width: 0;
}

.chat-safety-btn {
    width: 36px;
    height: 36px;
    flex: 0 0 36px;
    border: 1px solid rgba(0,0,0,.12);
    border-radius: 50%;
    background: transparent;
    color: var(--text-dark);
    font-size: 22px;
    line-height: 1;
    cursor: pointer;
}

.chat-list-item.blocked {
    opacity: .72;
    border-style: dashed;
}

.chat-blocked-banner {
    margin: 0 14px 10px;
    padding: 10px 12px;
    border-radius: 10px;
    border: 1px solid rgba(255, 77, 79, .25);
    background: rgba(255, 77, 79, .08);
    color: #b84f49;
    font-size: 11px;
    line-height: 1.45;
}

#chat-input-form input:disabled,
#chat-input-form button:disabled {
    opacity: .45;
    cursor: not-allowed;
}

.safety-modal-card h3 {
    margin: 0 0 14px;
    font-size: 16px;
}

.safety-divider {
    height: 1px;
    margin: 8px 0 18px;
    background: var(--border-color);
}

.safety-block-btn {
    border-color: #b95d54;
    color: #ef7d72;
}

.safety-complaint-btn {
    background: transparent;
    border: 1px solid #b95d54;
    color: #ef7d72;
}

.safety-complaint-btn:hover {
    border-color: #ef7d72;
}

/* =====================================================================
   SIGNUM DESIGN V5 — строго по переданным sketches + assets
   Источник визуала: sketches(1).zip
   Источник иконок: assets(1).zip
   Этот слой переопределяет старые технические стили, не ломая JS/API.
===================================================================== */

:root {
    --signum-bg: #0b0d10;
    --signum-surface: #15181d;
    --signum-surface-2: #1a1d22;
    --signum-card: #f4ead6;
    --signum-card-2: #eee4d3;
    --signum-gold: #c79a3b;
    --signum-gold-soft: #e9d89f;
    --signum-text: #f5f1e9;
    --signum-muted: #8f8b88;
    --signum-muted-2: #aaa49a;
    --signum-dark: #1a1815;
    --signum-border: #343840;
    --signum-green: #4c907d;
    --signum-red: #df6657;
    --signum-app-width: 360px;
    --signum-nav-height: 61px;
    --signum-radius: 15px;
    --signum-card-radius: 18px;

    /* keep legacy variables aligned */
    --bg-main: var(--signum-bg);
    --bg-surface: var(--signum-bg);
    --bg-card-light: var(--signum-card);
    --bg-input: var(--signum-surface);
    --gold-main: var(--signum-gold);
    --gold-hover: #d7aa48;
    --success-green: var(--signum-green);
    --error-red: var(--signum-red);
    --text-white: var(--signum-text);
    --text-muted: var(--signum-muted);
    --text-dark: var(--signum-dark);
    --border-color: var(--signum-border);
    --border-focus: var(--signum-gold);
}

html {
    min-height: 100%;
    background: #f7f7f7;
}

body {
    min-height: 100vh;
    min-height: 100dvh;
    margin: 0;
    display: flex;
    justify-content: center;
    background: #f7f7f7;
    color: var(--signum-text);
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Arial, sans-serif;
    -webkit-font-smoothing: antialiased;
    text-rendering: optimizeLegibility;
}

button,
input,
textarea,
select {
    font: inherit;
}

button {
    -webkit-tap-highlight-color: transparent;
}

img {
    max-width: 100%;
}

.hidden {
    display: none !important;
}

.screen {
    display: none;
    width: 100%;
    max-width: var(--signum-app-width);
    min-height: 100dvh;
    margin: 0 auto;
    padding: 16px 16px calc(var(--signum-nav-height) + 16px);
    flex-direction: column;
    background: var(--signum-bg);
    color: var(--signum-text);
    position: relative;
    overflow-x: hidden;
    box-shadow: 0 10px 28px rgba(0, 0, 0, .16);
}

.screen.active {
    display: flex;
}

.main-screen {
    padding-bottom: calc(var(--signum-nav-height) + 16px);
}

@media (min-width: 481px) {
    body {
        padding: 12px 0;
        align-items: flex-start;
    }

    .screen {
        min-height: 800px;
        max-height: calc(100dvh - 24px);
        border-radius: 24px;
        overflow-y: auto;
        scrollbar-width: thin;
        scrollbar-color: #31343a transparent;
    }

    #screen-splash {
        overflow: hidden;
    }
}

@media (max-width: 480px) {
    body {
        background: var(--signum-bg);
    }

    .screen {
        box-shadow: none;
    }
}

/* ---------- typography ---------- */
h1,
h2,
h3,
h4,
.brand-title,
.brand-title-small,
.verify-toolbar-title,
.screen-toolbar h1,
.onboarding-toolbar h1,
.top-bar-simple > h2,
.section-title h3 {
    font-family: "Arial Narrow", "Roboto Condensed", "Segoe UI Semibold", "Segoe UI", sans-serif;
    font-stretch: condensed;
}

h2 {
    font-size: 20px;
    line-height: 1.16;
    font-weight: 800;
}

h3 {
    margin: 15px 0 10px;
    font-size: 16px;
    line-height: 1.2;
}

.text-muted,
.small-muted,
.auth-note,
.onboarding-lead,
.role-lead,
.settings-subtitle {
    color: var(--signum-muted);
    line-height: 1.45;
}

.text-muted {
    margin-bottom: 22px;
    font-size: 12px;
}

.text-muted-dark {
    color: #8d887f;
    font-size: 10px;
}

.ui-icon {
    width: 20px;
    height: 20px;
    display: block;
    object-fit: contain;
}

/* ---------- buttons ---------- */
.btn {
    width: 100%;
    min-height: 48px;
    margin: 0 0 10px;
    padding: 12px 16px;
    border: 1px solid transparent;
    border-radius: 11px;
    cursor: pointer;
    font-size: 12px;
    font-weight: 700;
    transition: transform .12s ease, opacity .12s ease, background-color .12s ease, border-color .12s ease;
}

.btn:active:not(:disabled) {
    transform: scale(.99);
}

.btn:disabled {
    opacity: .5;
    cursor: default;
}

.btn-primary {
    background: var(--signum-gold);
    color: var(--signum-dark);
}

.btn-primary:hover {
    background: #d3a445;
}

.btn-secondary {
    background: transparent;
    color: var(--signum-text);
    border-color: #d9c58d;
}

.btn-draft {
    width: auto;
    min-height: 34px;
    padding: 8px 12px;
    margin: 0;
    border: 1px solid #292d34;
    border-radius: 999px;
    background: #121419;
    color: #79777a;
    font-size: 9px;
    font-weight: 500;
}

.icon-btn {
    width: 44px;
    height: 44px;
    flex: 0 0 44px;
    padding: 0;
    margin: 0;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border: 1px solid #2d3138;
    border-radius: 12px;
    background: #14171b;
    color: var(--signum-gold);
    box-shadow: none;
    cursor: pointer;
}

.icon-btn .ui-icon {
    width: 20px;
    height: 20px;
}

.toolbar-back-btn,
.back-btn {
    width: 44px;
    height: 44px;
    min-width: 44px;
    padding: 0;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border: 0;
    border-radius: 12px;
    background: #15181d;
    color: var(--signum-gold);
    cursor: pointer;
}

.toolbar-back-btn .back-icon,
.back-btn .back-icon {
    width: 18px;
    height: 18px;
}

/* ---------- fields ---------- */
.input-group {
    margin-bottom: 15px;
}

.input-group label,
.settings-field label,
.field-label,
.field-label-row label {
    display: block;
    margin-bottom: 7px;
    color: #747175;
    font-size: 10px;
    font-weight: 400;
}

.input-group input,
.search-bar input,
textarea,
.chat-input input,
.form-select,
.settings-input,
.order-filter-select,
.settings-select {
    width: 100%;
    min-height: 47px;
    padding: 12px 14px;
    border: 1px solid #363b43;
    border-radius: 11px;
    outline: none;
    background: #15181d;
    color: var(--signum-text);
    font-size: 12px;
    box-shadow: none;
}

textarea,
.settings-textarea {
    min-height: 94px;
    resize: vertical;
    line-height: 1.45;
}

input::placeholder,
textarea::placeholder {
    color: #737174;
    opacity: 1;
}

.input-group input:focus,
.search-bar input:focus,
textarea:focus,
.chat-input input:focus,
.form-select:focus,
.settings-input:focus,
.order-filter-select:focus {
    border-color: #8c7440;
    box-shadow: 0 0 0 1px rgba(199, 154, 59, .08);
}

.form-row {
    display: flex;
    gap: 8px;
}

.half,
.third {
    min-width: 0;
    flex: 1;
}

/* ---------- splash / Loading.png concept ---------- */
#screen-splash {
    padding: 0;
    background: #000;
}

#screen-splash .splash-start-container {
    width: 100%;
    min-height: inherit;
    display: flex;
    align-items: center;
    justify-content: center;
    background: #000;
    position: relative;
}

.splash-reference-image {
    width: 235px;
    height: auto;
    max-height: 55%;
    object-fit: contain;
    display: block;
}

#screen-splash .loader,
#screen-splash .splash-start-btn {
    position: absolute;
    bottom: 55px;
}

#screen-splash .splash-start-btn.hidden,
#screen-splash .loader.hidden {
    display: none !important;
}

/* ---------- Authorization / Registration.jpg ---------- */
#screen-auth {
    padding-top: 25px;
}

#screen-auth .auth-header {
    display: flex;
    align-items: center;
    gap: 9px;
    margin: 0;
}

#screen-auth .logo-small {
    width: 35px;
    height: 35px;
    flex: 0 0 35px;
}

#screen-auth .brand-title {
    margin: 0;
    color: var(--signum-text);
    font-size: 17px;
    line-height: 1;
    letter-spacing: .01em;
    font-weight: 900;
}

#screen-auth .brand-subtitle {
    margin: 3px 0 0;
    color: #8b8786;
    font-size: 8px;
    line-height: 1;
}

#screen-auth .auth-body {
    margin-top: 83px;
}

#screen-auth .auth-body h2 {
    margin: 0 0 7px;
    font-size: 22px;
}

#screen-auth .auth-body > .text-muted {
    max-width: 290px;
    margin: 0 0 31px;
    font-size: 11px;
}

#screen-auth .input-group {
    margin-bottom: 17px;
}

#screen-auth #auth-email {
    border-color: #b49a5f;
}

#screen-auth #btn-send-auth-code {
    margin-top: 0;
}

#screen-auth .auth-password-group {
    margin-top: 0;
    margin-bottom: 10px;
}

#screen-auth #auth-password {
    border-color: var(--border-color);
}

#screen-auth #auth-password:focus {
    border-color: #b49a5f;
}

#screen-auth .auth-forgot-password {
    margin: -1px 0 26px;
    text-align: right;
}

#screen-auth .auth-forgot-link {
    appearance: none;
    border: 0;
    padding: 0;
    background: transparent;
    color: var(--gold-main);
    font: inherit;
    font-size: 11px;
    line-height: 1.2;
    cursor: pointer;
}

#screen-auth .auth-forgot-link:hover,
#screen-auth .auth-forgot-link:focus-visible {
    color: var(--gold-hover);
    outline: none;
}

#screen-auth .auth-forgot-link:disabled {
    opacity: .65;
    cursor: default;
}

#screen-auth .auth-create-account-btn {
    border-color: #d9c58d;
    color: #f1eee8;
}

#screen-auth .auth-note {
    max-width: 280px;
    margin: 18px auto 0;
    text-align: center;
    font-size: 9px;
}

/* ---------- Authorization.png / verification ---------- */
#screen-verify {
    padding-top: 16px;
}

#screen-verify .verify-header {
    min-height: 44px;
    display: flex;
    align-items: center;
    gap: 10px;
    margin: 0;
}

.verify-toolbar-title {
    margin: 0;
    font-size: 16px;
    font-weight: 800;
}

#screen-verify .verify-body {
    margin-top: 76px;
    text-align: center;
}

#screen-verify .logo-shield {
    width: 72px;
    height: 72px;
    margin: 0 auto 24px;
}

#screen-verify .verify-body h2 {
    margin: 0 0 8px;
    font-size: 20px;
}

#screen-verify .verify-body .text-muted {
    margin: 0 auto 27px;
    color: #858183;
    font-size: 10px;
}

#screen-verify .code-inputs {
    display: flex;
    justify-content: center;
    gap: 8px;
    margin: 0 0 14px;
}

#screen-verify .code-box {
    width: 44px;
    height: 52px;
    padding: 0;
    border: 1px solid #343941;
    border-radius: 9px;
    background: #15181d;
    color: var(--signum-text);
    text-align: center;
    font-size: 18px;
}

#screen-verify .code-box:focus {
    border-color: #e1c47b;
    box-shadow: inset 0 0 0 1px #e1c47b;
}

#screen-verify .timer-text {
    margin: 0 0 58px;
    color: #8b8788;
    font-size: 9px;
}

#screen-verify #btn-confirm {
    margin-bottom: 10px;
}

/* ---------- onboarding general ---------- */
#screen-onboarding {
    padding-top: 16px;
}

.onboarding-toolbar {
    min-height: 44px;
    display: flex;
    align-items: center;
    gap: 10px;
    margin: 0 0 14px;
}

.onboarding-toolbar-copy {
    min-width: 0;
    display: flex;
    flex-direction: column;
    gap: 1px;
}

#onboarding-step-caption {
    color: #747176;
    font-size: 8px;
}

#onboarding-toolbar-title {
    margin: 0;
    font-size: 16px;
    line-height: 1.1;
    font-weight: 800;
    white-space: nowrap;
}

.onboarding-progress {
    height: 3px;
    margin: 0 0 24px;
    overflow: hidden;
    border-radius: 999px;
    background: #171a1f;
}

.onboarding-progress > span {
    display: block;
    height: 100%;
    border-radius: inherit;
    background: var(--signum-gold);
}

.onboarding-step {
    width: 100%;
}

.onboarding-step h2 {
    margin: 0 0 8px;
    font-size: 20px;
}

.onboarding-lead,
.role-lead {
    margin: 0 0 20px;
    font-size: 11px;
}

.onboarding-nav {
    margin-top: 16px;
    display: flex;
    gap: 8px;
}

.onboarding-nav .btn {
    flex: 1 1 0;
    width: auto;
}

.onboarding-photo-card,
.settings-photo-card {
    padding: 12px;
    border: 1px solid #373b42;
    border-radius: 14px;
    background: #15181d;
}

.onboarding-avatar-preview,
.settings-avatar-preview,
.avatar,
.avatar-small,
.avatar-large,
.avatar-circle,
.chat-list-avatar {
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    background: #f2e5bd;
    border: 1px solid #e5ce90;
    color: var(--signum-dark);
    background-size: cover;
    background-position: center;
    font-weight: 700;
}

.choice-grid {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
}

.choice-chip {
    min-height: 41px;
    padding: 9px 12px;
    border: 1px solid #353a42;
    border-radius: 10px;
    background: #15181d;
    color: #aaa6a4;
    font-size: 11px;
    cursor: pointer;
}

.choice-chip.selected {
    border-color: var(--signum-gold);
    background: rgba(199, 154, 59, .12);
    color: #e1bd65;
}

/* ---------- 2ekran.jpg / role ---------- */
#screen-onboarding[data-current-step="2"] .onboarding-progress,
#screen-onboarding[data-current-step="2"] #onboarding-step-caption {
    display: none;
}

#screen-onboarding[data-current-step="2"] .onboarding-toolbar {
    margin-bottom: 19px;
}

#screen-onboarding[data-current-step="2"] #onboarding-toolbar-title {
    font-size: 16px;
}

#screen-onboarding[data-current-step="2"] .role-body {
    margin: 0;
    text-align: left;
}

#screen-onboarding[data-current-step="2"] .role-body h2 {
    margin: 0 0 15px;
    font-size: 20px;
}

#screen-onboarding[data-current-step="2"] .role-lead {
    margin-bottom: 17px;
    font-size: 11px;
}

.role-segmented {
    width: 180px;
    height: 44px;
    margin: 0 auto 16px;
    padding: 3px;
    display: flex;
    border: 1px solid #3b4048;
    border-radius: 999px;
    background: #15181d;
}

.role-segment {
    min-width: 0;
    flex: 1 1 50%;
    padding: 0 9px;
    border: 0;
    border-radius: 999px;
    background: transparent;
    color: #8d8887;
    font-size: 11px;
    cursor: pointer;
}

.role-segment.active {
    background: var(--signum-gold);
    color: var(--signum-dark);
}

.role-cards {
    display: flex;
    flex-direction: column;
    gap: 14px;
    margin: 0;
}

.role-card {
    width: 100%;
    min-height: 118px;
    padding: 16px;
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    border: 1px solid #383d45;
    border-radius: 15px;
    background: #15181d;
    color: var(--signum-text);
    cursor: pointer;
}

.role-card-title {
    margin-bottom: 7px;
    font-size: 15px;
    font-weight: 800;
}

.role-card-kicker {
    margin-bottom: 8px;
    color: var(--signum-gold);
    font-size: 9px;
    letter-spacing: .02em;
}

.role-card-text {
    max-width: 285px;
    color: #9a9692;
    font-size: 12px;
    line-height: 1.4;
}

.role-card.selected {
    border-color: #dab863;
    background: #f4ead6;
    color: #2a2825;
}

.role-card.selected .role-card-text {
    color: #827d74;
}

#screen-onboarding[data-current-step="2"] #btn-onboarding-prev {
    display: none !important;
}

#screen-onboarding[data-current-step="2"] #onboarding-nav {
    margin-top: 16px;
}

#screen-onboarding[data-current-step="2"] #btn-onboarding-next {
    width: 100%;
    flex-basis: 100%;
}

.onboarding-complete {
    margin: auto 0;
    text-align: center;
}

.complete-icon {
    width: 64px;
    height: 64px;
    margin: 0 auto 20px;
    display: flex;
    align-items: center;
    justify-content: center;
    border: 1px solid var(--signum-gold);
    border-radius: 50%;
    color: var(--signum-gold);
    font-size: 28px;
}

/* ---------- top bars ---------- */
.top-bar,
.top-bar-simple,
.screen-toolbar {
    min-height: 44px;
    margin: 0 0 11px;
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.top-bar-left {
    min-width: 0;
    display: flex;
    align-items: center;
    gap: 8px;
}

.logo-micro {
    width: 31px;
    height: 31px;
}

.brand-title-small {
    margin: 0;
    font-size: 16px;
    line-height: 1;
    font-weight: 900;
}

.brand-subtitle-micro {
    margin-top: 3px;
    color: #8c8886;
    font-size: 8px;
}

.top-bar-actions {
    display: flex;
    gap: 7px;
}

/* ---------- search input: supplied lypa icon ---------- */
.search-bar {
    position: relative;
}

.search-bar input {
    height: 44px;
    min-height: 44px;
    margin-bottom: 12px;
    padding: 11px 13px 11px 39px;
    border-radius: 12px;
    background-color: #15181d;
    background-image: none;
    font-size: 11px;
}

/* ---------- AdDraft1.jpg / catalog ---------- */
#screen-catalog {
    padding-top: 16px;
}

#screen-catalog .top-bar {
    margin-bottom: 12px;
}

#screen-catalog .filter-row {
    margin: 0 0 13px;
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.location-chip {
    min-width: 89px;
    height: 44px;
    padding: 0 14px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border: 1px solid #343941;
    border-radius: 12px;
    background: #15181d;
    color: #eeeae4;
    font-size: 10px;
}

.section-title {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin: 0 0 12px;
}

.section-title h3 {
    margin: 0;
    font-size: 17px;
}

.badge {
    min-width: 26px;
    height: 24px;
    padding: 0 7px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border-radius: 999px;
    background: var(--signum-card);
    color: var(--signum-dark);
    font-size: 9px;
    font-weight: 700;
}

#masters-container {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.master-card.light-card {
    min-height: 171px;
    margin: 0;
    padding: 15px 16px 12px;
    border: 0;
    border-radius: 18px;
    background: var(--signum-card);
    color: #292722;
    box-shadow: none;
}

.master-card-header {
    min-height: 56px;
    display: flex;
    align-items: center;
    margin: 0 0 12px;
}

.master-card .avatar {
    width: 56px;
    height: 56px;
    flex: 0 0 56px;
    font-size: 18px;
}

.master-info {
    min-width: 0;
    flex: 1;
    margin-left: 11px;
}

.master-info h4 {
    margin: 0 0 4px;
    color: #24221f;
    font-size: 14px;
    line-height: 1.1;
}

.master-info .verified {
    display: inline-flex;
    width: 14px;
    height: 14px;
    margin-left: 2px;
    vertical-align: -2px;
}

.master-info .verified img {
    width: 14px;
    height: 14px;
}

.rating-city {
    margin: 0;
    color: #8d887f;
    font-size: 10px;
}

.rating-city strong {
    color: #292722;
}

.heart-icon {
    width: 31px;
    height: 31px;
    padding: 4px;
    flex: 0 0 31px;
    border: 0;
    background: transparent;
    cursor: pointer;
}

.heart-icon img {
    width: 22px;
    height: 20px;
    display: block;
}

.master-desc {
    min-height: 48px;
    margin: 0;
    padding: 0 0 12px;
    border-bottom: 1px solid #e7ddca;
    color: #5c5851;
    font-size: 11px;
    line-height: 1.45;
}

.master-card-footer {
    padding-top: 10px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    font-size: 9px;
    font-weight: 500;
}

.master-card-footer .status-green {
    color: var(--signum-green);
}

.master-card-footer .text-muted {
    margin: 0;
    color: #98928a;
    font-size: 9px;
}

.profile-link {
    color: #37332d;
    text-decoration: none;
}

.profile-link::after {
    content: " +";
}

/* ---------- orders ---------- */
#screen-orders {
    padding-top: 16px;
}

.orders-toolbar {
    align-items: center;
}

.eyebrow {
    margin: 0 0 2px;
    color: #747176;
    font-size: 8px;
    letter-spacing: .08em;
}

#orders-screen-title {
    margin: 0;
    font-size: 21px;
}

#btn-orders-create {
    border-color: #343941;
    color: #c3a44f;
}

.order-tabs {
    margin: 7px 0 13px;
    padding: 0;
    display: flex;
    gap: 7px;
    overflow-x: auto;
    scrollbar-width: none;
    background: transparent;
}

.order-tabs::-webkit-scrollbar {
    display: none;
}

.order-tab {
    min-height: 38px;
    padding: 0 12px;
    flex: 0 0 auto;
    border: 1px solid #343941;
    border-radius: 10px;
    background: #15181d;
    color: #989599;
    font-size: 10px;
}

.order-tab.active {
    border-color: var(--signum-gold);
    background: var(--signum-gold);
    color: var(--signum-dark);
}

.orders-context-note {
    margin: 2px 0 12px;
    color: #7d797c;
    font-size: 9px;
    line-height: 1.4;
}

.orders-master-toolbar {
    margin-top: 3px;
}

.orders-search-bar input {
    margin-bottom: 8px;
}

.order-filter-row {
    display: flex;
    gap: 8px;
    margin-bottom: 11px;
}

.order-filter-select {
    height: 42px;
    min-height: 42px;
    font-size: 10px;
}

#btn-orders-refresh {
    width: auto;
    min-width: 70px;
    padding: 0 10px;
    font-size: 10px;
}

.order-feed-card,
.client-order-card,
.master-assigned-card {
    margin: 0 0 11px;
    padding: 14px;
    border: 1px solid #343941;
    border-radius: 14px;
    background: #15181d;
    color: var(--signum-text);
    box-shadow: none;
}

.order-feed-topline,
.order-card-topline {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 8px;
}

.order-category-badge,
.order-status-badge {
    color: var(--signum-gold);
    font-size: 9px;
    letter-spacing: .02em;
}

.order-budget {
    color: #d7d1c8;
    font-size: 10px;
}

.order-feed-card h3,
.client-order-card h3,
.master-assigned-card h3 {
    margin: 9px 0 6px;
    font-size: 15px;
}

.order-feed-meta,
.order-client-line,
.order-feed-description,
.order-card-meta,
.order-public-location,
.order-private-address {
    margin: 0 0 7px;
    color: #989397;
    font-size: 10px;
    line-height: 1.45;
}

.order-feed-description {
    color: #b2ada9;
}

.order-privacy-line,
.privacy-note {
    color: #6e8f84;
    font-size: 9px;
    line-height: 1.35;
}

.order-primary-action,
.btn-response-accept,
.btn-complete-order {
    min-height: 42px;
    padding: 10px 12px;
    border: 1px solid var(--signum-gold);
    border-radius: 10px;
    background: var(--signum-gold);
    color: var(--signum-dark);
    font-size: 10px;
    font-weight: 700;
}

.order-primary-action.muted {
    border-color: #353a42;
    background: #202329;
    color: #8f8c90;
}

.order-card-actions,
.order-secondary-actions,
.response-actions,
.completion-actions {
    display: flex;
    gap: 7px;
    flex-wrap: wrap;
}

.btn-edit-order,
.btn-delete-order,
.btn-view-responses,
.btn-response-reject,
.order-text-action {
    min-height: 36px;
    padding: 8px 10px;
    border: 1px solid #3b4048;
    border-radius: 9px;
    background: transparent;
    color: #b9b5b0;
    font-size: 9px;
}

.completion-prompt,
.completion-result {
    margin-top: 10px;
    padding: 10px;
    border: 1px solid #343941;
    border-radius: 10px;
    background: #111318;
    color: #aaa6a2;
    font-size: 9px;
}

.completion-actions.three .btn-complete-order {
    flex: 1;
}

.btn-complete-order.postpone {
    border-color: #6c5d37;
    background: transparent;
    color: #c6a452;
}

.btn-complete-order.negative {
    border-color: #6b3631;
    background: transparent;
    color: #d86d60;
}

/* ---------- CreatingAnAd.png concept ---------- */
#screen-create {
    padding-top: 16px;
}

.create-order-toolbar {
    display: grid;
    grid-template-columns: 1fr auto;
    gap: 10px;
    align-items: center;
}

#btn-create-back {
    display: none !important;
}

#create-order-title {
    margin: 0;
    font-size: 21px;
}

.create-order-lead {
    display: none;
}

#create-order-form {
    width: 100%;
}

#create-order-form .form-section-title {
    margin: 16px 0 10px;
    color: #f0ece6;
    font-size: 14px;
}

#screen-create .input-group {
    margin-bottom: 13px;
}

#screen-create input,
#screen-create textarea,
#screen-create select {
    background: #15181d;
}

#order-description {
    min-height: 89px;
}

.field-label-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.field-label-row > span,
.textarea-counter {
    color: #6f6c70;
    font-size: 8px;
}

#screen-create .privacy-note {
    margin: -1px 0 14px;
}

.budget-negotiable-row,
.check-row {
    display: flex;
    align-items: center;
    gap: 8px;
    color: #8e8a8d;
    font-size: 10px;
}

#btn-publish-order {
    min-height: 49px;
    margin-top: 9px;
}

/* ---------- Messages.jpg / chats ---------- */
#screen-chats {
    padding-top: 16px;
}

#screen-chats > .top-bar-simple {
    margin-bottom: 10px;
}

#screen-chats > .top-bar-simple h2 {
    margin: 0;
    font-size: 21px;
}

.chat-header-hint {
    width: 43px;
    height: 43px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border: 1px solid #2e3239;
    border-radius: 11px;
    background: #14171b;
}

.chat-header-hint .ui-icon {
    width: 19px;
    height: 20px;
}

.chat-list {
    display: flex;
    flex-direction: row;
    gap: 7px;
    margin: 0 0 11px;
    padding: 0 0 2px;
    overflow-x: auto;
    scrollbar-width: none;
}

.chat-list::-webkit-scrollbar {
    display: none;
}

.chat-list-item {
    position: relative;
    width: 64px;
    min-width: 64px;
    min-height: 64px;
    padding: 6px 4px;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 3px;
    border: 1px solid transparent;
    border-radius: 10px;
    background: #15181d;
    color: #d9d4cd;
}

.chat-list-item.active {
    border-color: #efe1b8;
    background: #f1e3bd;
    color: #2b2720;
}

.chat-list-avatar {
    width: 34px;
    height: 34px;
    flex: 0 0 34px;
    font-size: 10px;
}

.chat-list-copy {
    width: 100%;
}

.chat-list-copy strong {
    display: block;
    overflow: hidden;
    color: inherit;
    font-size: 8px;
    font-weight: 500;
    white-space: nowrap;
    text-overflow: ellipsis;
}

.chat-list-copy small {
    display: none;
}

.chat-unread-badge {
    position: absolute;
    top: 2px;
    right: 2px;
    z-index: 2;
    min-width: 16px;
    height: 16px;
    padding: 0 4px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border: 1px solid #101216;
    border-radius: 999px;
    background: var(--signum-gold);
    color: #1c1710;
    font-size: 8px;
    font-weight: 800;
    line-height: 1;
    box-sizing: border-box;
}

.chat-list-item.has-unread .chat-list-copy strong {
    font-weight: 700;
}

#chat-empty-state {
    margin-top: 47px;
    color: #777579;
    text-align: center;
    font-size: 10px;
    line-height: 1.45;
}

.empty-state-asset {
    width: 28px;
    height: 28px;
    display: block;
    margin: 0 auto 9px;
}

.chat-window.light-card {
    height: 475px;
    min-height: 400px;
    max-height: calc(100dvh - 248px);
    margin: 0;
    padding: 0;
    display: none;
    flex-direction: column;
    overflow: hidden;
    border: 1px solid #343941;
    border-radius: 13px;
    background: #15181d;
    color: var(--signum-text);
}

.chat-header {
    min-height: 49px;
    padding: 8px 12px;
    display: flex;
    align-items: center;
    gap: 8px;
    background: var(--signum-card);
    color: #29251f;
}

.chat-header .avatar-small {
    width: 32px;
    height: 32px;
    flex: 0 0 32px;
    font-size: 10px;
}

.chat-header-copy {
    min-width: 0;
    flex: 1;
}

.chat-header h4 {
    margin: 0 0 2px;
    font-size: 12px;
}

.chat-header .status-green {
    color: var(--signum-green);
    font-size: 8px;
}

.chat-safety-btn {
    width: 30px;
    height: 30px;
    padding: 0;
    border: 0;
    background: transparent;
    color: #615a4c;
    font-size: 14px;
    letter-spacing: 1px;
}

.chat-blocked-banner {
    padding: 7px 10px;
    background: #33211f;
    color: #d2877d;
    font-size: 8px;
    line-height: 1.35;
}

.chat-messages {
    min-height: 0;
    flex: 1;
    padding: 14px 11px;
    display: flex;
    flex-direction: column;
    gap: 12px;
    overflow-y: auto;
    background: #15181d;
}

.msg {
    max-width: 82%;
    padding: 9px 11px;
    border-radius: 11px;
    font-size: 10px;
    line-height: 1.35;
    box-shadow: none;
}

.msg-left {
    align-self: flex-start;
    background: var(--signum-card);
    color: #5d5851;
}

.msg-right {
    align-self: flex-end;
    background: #efe0b7;
    color: #5a554e;
}

.chat-message-image {
    width: 100%;
    max-height: 190px;
    margin-bottom: 6px;
    border-radius: 8px;
    object-fit: cover;
}

.chat-message-time {
    display: block;
    margin-top: 3px;
    color: #8a847b;
    font-size: 7px;
    text-align: right;
}

#chat-input-form.chat-input {
    min-height: 47px;
    margin: 9px 10px 10px;
    padding: 0 4px 0 8px;
    display: flex;
    align-items: center;
    gap: 4px;
    border: 1px solid #343941;
    border-radius: 11px;
    background: #101216;
}

#chat-input-form .btn-attach {
    width: 29px;
    height: 40px;
    padding: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    border: 0;
    background: transparent;
}

#chat-input-form .btn-attach .ui-icon {
    width: 18px;
    height: 20px;
}

#chat-message-input {
    min-width: 0;
    flex: 1;
    min-height: 41px;
    padding: 9px 5px;
    border: 0;
    background: transparent;
    font-size: 10px;
}

#chat-input-form .btn-send {
    width: 36px;
    height: 36px;
    flex: 0 0 36px;
    padding: 0;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border: 0;
    border-radius: 50%;
    background: var(--signum-gold);
}

#chat-input-form .chat-send-icon {
    width: 16px;
    height: 16px;
    display: block;
    transform: rotate(180deg);
    filter: brightness(0) saturate(100%);
    opacity: .72;
    pointer-events: none;
}

#chat-input-form .btn-send:disabled .chat-send-icon {
    opacity: .35;
}

.chat-upload-status {
    margin: -7px 11px 8px;
    color: #8e8a8d;
    font-size: 8px;
}

/* ---------- ProfileSketch ---------- */
#screen-profile {
    padding-top: 16px;
}

#screen-profile > .top-bar-simple {
    margin-bottom: 10px;
}

#screen-profile > .top-bar-simple h2 {
    margin: 0;
    font-size: 21px;
}

.profile-main-card.light-card {
    margin: 0 0 11px;
    padding: 15px;
    border: 0;
    border-radius: 17px;
    background: var(--signum-card);
    color: #27241e;
    box-shadow: none;
}

.profile-header-info {
    margin-bottom: 12px;
    display: flex;
    align-items: center;
    gap: 12px;
}

.profile-main-card .avatar-large {
    width: 70px;
    height: 70px;
    flex: 0 0 70px;
    font-size: 20px;
}

.profile-main-card .info {
    min-width: 0;
}

.profile-main-card .info h3 {
    margin: 0 0 3px;
    color: #27241e;
    font-size: 14px;
}

.profile-main-card .text-muted-dark {
    margin: 0 0 5px;
    color: #8c877e;
    font-size: 9px;
}

.verified-badge {
    min-height: 22px;
    padding: 3px 8px;
    display: inline-flex;
    align-items: center;
    gap: 5px;
    border-radius: 999px;
    background: #eee1bd;
    color: #5f584b;
    font-size: 8px;
    font-weight: 600;
}

.verified-icon {
    width: 12px;
    height: 12px;
}

.profile-stats {
    display: flex;
    gap: 8px;
}

.stat-box {
    min-height: 54px;
    flex: 1;
    padding: 9px 5px;
    border-radius: 11px;
    background: #eee4d3;
    text-align: center;
}

.stat-value {
    margin: 0 0 2px;
    color: #25221d;
    font-size: 14px;
    font-weight: 700;
}

.stat-label {
    color: #918b82;
    font-size: 8px;
}

#btn-edit-profile {
    display: none;
}

.account-mode {
    margin: 0 0 10px;
}

.account-mode > .text-muted {
    margin: 0 0 5px;
    color: #777478;
    font-size: 9px;
}

.mode-toggle {
    width: 184px;
    min-height: 42px;
    padding: 3px;
    display: flex;
    border: 1px solid #343941;
    border-radius: 999px;
    background: #15181d;
}

.mode-toggle .mode {
    flex: 1;
    min-height: 34px;
    padding: 0 14px;
    border: 0;
    border-radius: 999px;
    background: transparent;
    color: #8d888b;
    font-size: 10px;
    font-weight: 600;
}

.mode-toggle .mode.active {
    background: var(--signum-gold);
    color: var(--signum-dark);
}

#master-specific-content > div:first-child {
    margin-top: 0 !important;
}

#master-specific-content h3 {
    margin: 11px 0 10px !important;
    color: #f0ece6;
    font-size: 14px;
}

#btn-add-portfolio {
    min-height: 31px;
    padding: 7px 10px;
    border-color: #343941;
    color: #b9943d;
    font-size: 8px !important;
}

#portfolio-upload-form {
    margin: 0 0 10px;
    padding: 11px;
    border: 1px dashed #8b7139;
    border-radius: 12px;
    background: #15181d;
}

#portfolio-upload-form > input[type="text"] {
    width: 100%;
    min-height: 42px;
    margin-bottom: 9px;
    padding: 10px 11px;
    border: 1px solid #343941;
    border-radius: 9px;
    background: #111318;
    color: var(--signum-text);
}

#portfolio-upload-form > div {
    display: flex;
    gap: 8px;
    margin-bottom: 10px;
}

#portfolio-upload-form > div > div {
    min-width: 0;
    flex: 1;
}

#portfolio-upload-form label {
    display: block;
    margin-bottom: 5px;
    color: #8d888b;
    font-size: 8px;
}

#portfolio-upload-form input[type="file"] {
    width: 100%;
    color: #989397;
    font-size: 8px;
}

#portfolio-upload-form .btn {
    min-height: 40px;
    margin: 0;
}

.portfolio-grid {
    display: grid !important;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 10px !important;
    margin-bottom: 11px;
}

.portfolio-item-wrapper {
    min-width: 0;
    overflow: hidden;
    border-radius: 13px;
    background: #171a1f;
}

.portfolio-item-head {
    min-height: 28px;
    padding: 6px 7px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 5px;
    color: #d8d3cc;
    font-size: 8px;
}

.btn-delete-portfolio {
    padding: 0;
    border: 0;
    background: transparent;
    color: #b86a5f;
    font-size: 7px;
    cursor: pointer;
}

.portfolio-before-after {
    height: 112px;
    display: flex;
}

.portfolio-half {
    min-width: 0;
    flex: 1;
    display: flex;
    align-items: center;
    justify-content: center;
    background-position: center;
    background-size: cover;
    position: relative;
}

.portfolio-half::after {
    content: "";
    position: absolute;
    inset: 0;
    background: rgba(0, 0, 0, .12);
}

.portfolio-half span {
    position: relative;
    z-index: 1;
    color: #fff;
    font-size: 10px;
    font-weight: 700;
}

.portfolio-after {
    border-left: 1px solid rgba(255,255,255,.25);
}

.calendar-card.light-card {
    margin: 0;
    padding: 10px 10px 11px;
    border-radius: 12px;
    background: #fffdf9;
    color: #171717;
}

.calendar-header {
    margin-bottom: 8px;
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.calendar-title {
    margin: 0;
    font-size: 14px;
    font-weight: 600;
}

.cal-nav-btn {
    width: 29px;
    height: 29px;
    padding: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    border: 1px solid #ead394;
    border-radius: 5px;
    background: #fff4d5;
}

.calendar-arrow {
    width: 14px;
    height: 14px;
}

.calendar-arrow.next {
    transform: rotate(180deg);
}

.calendar-grid {
    display: grid;
    grid-template-columns: repeat(7, 1fr);
    gap: 2px;
    text-align: center;
}

.weekday {
    color: #24211e;
    font-size: 9px;
    font-weight: 600;
}

.day {
    height: 24px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 3px;
    color: #171717;
    font-size: 9px;
}

.day-working {
    outline: 1px solid var(--signum-gold);
}

.day-weekend-striped {
    background: repeating-linear-gradient(135deg, #fff 0 4px, #f2e9d4 4px 8px);
}

/* ---------- NastroikyProfily.jpg ---------- */
#screen-settings {
    padding-top: 16px;
}

.settings-toolbar {
    justify-content: flex-start;
    gap: 10px;
    margin-bottom: 7px;
}

.settings-toolbar h1 {
    margin: 0;
    font-size: 16px;
    font-weight: 800;
}

.settings-subtitle {
    margin: 0 0 10px;
    font-size: 9px;
}

.settings-photo-card {
    margin: 0 0 10px;
    padding: 11px;
}

.settings-photo-top {
    display: flex;
    align-items: center;
    gap: 11px;
}

.settings-avatar-preview {
    width: 76px;
    height: 76px;
    flex: 0 0 76px;
    font-size: 17px;
}

.settings-photo-copy h2 {
    margin: 0 0 5px;
    font-size: 14px;
}

.settings-photo-copy p {
    margin: 0;
    color: #858185;
    font-size: 9px;
}

.file-input-hidden {
    position: absolute !important;
    width: 1px !important;
    height: 1px !important;
    opacity: 0 !important;
    pointer-events: none !important;
}

.settings-upload-btn {
    min-height: 43px;
    margin-top: 10px;
    display: flex;
    align-items: center;
    justify-content: center;
    border: 1px solid #d8bd73;
    border-radius: 10px;
    color: #f0ece5;
    font-size: 10px;
    font-weight: 600;
    cursor: pointer;
}

.settings-section-title {
    margin: 8px 0 8px;
    font-size: 14px;
}

.settings-field {
    margin-bottom: 10px;
}

.settings-input {
    height: 47px;
    min-height: 47px;
    font-size: 11px;
}

.settings-role-row {
    min-height: 48px;
    margin: 0 0 8px;
    padding: 0 12px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    border: 1px solid #363b43;
    border-radius: 10px;
    background: #15181d;
    color: #d9d5cf;
    font-size: 11px;
}

.settings-role-change {
    padding: 0;
    border: 0;
    background: transparent;
    color: var(--signum-gold);
    font-size: 10px;
    cursor: pointer;
}

.settings-role-picker {
    margin-bottom: 9px;
    padding: 3px;
    display: flex;
    border: 1px solid #363b43;
    border-radius: 999px;
    background: #15181d;
}

.settings-role-option {
    min-height: 34px;
    flex: 1;
    border: 0;
    border-radius: 999px;
    background: transparent;
    color: #989397;
    font-size: 10px;
}

.settings-role-option.active {
    background: var(--signum-gold);
    color: var(--signum-dark);
}

.settings-save-btn {
    min-height: 48px;
    margin-top: 1px;
}

.settings-logout-btn {
    min-height: 48px;
    border: 1px solid #df614f;
    background: transparent;
    color: #df614f;
}

.settings-advanced-panel {
    margin-top: 9px;
    border-top: 1px solid #22262c;
    color: #8a878a;
}

.settings-advanced-panel summary {
    padding: 12px 1px;
    list-style: none;
    color: #969296;
    font-size: 9px;
    cursor: pointer;
}

.settings-advanced-panel summary::-webkit-details-marker {
    display: none;
}

.settings-advanced-panel summary::after {
    content: "+";
    float: right;
    color: var(--signum-gold);
}

.settings-advanced-panel[open] summary::after {
    content: "−";
}

.settings-advanced-content {
    padding-bottom: 5px;
}

.settings-toggle-row {
    min-height: 52px;
    margin-bottom: 10px;
    padding: 9px 11px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 10px;
    border: 1px solid #343941;
    border-radius: 10px;
    background: #15181d;
}

.settings-toggle-row strong,
.settings-toggle-row small {
    display: block;
}

.settings-toggle-row strong {
    color: #ded9d3;
    font-size: 10px;
}

.settings-toggle-row small {
    margin-top: 2px;
    color: #807d81;
    font-size: 8px;
}

.settings-links-card {
    margin-bottom: 10px;
    overflow: hidden;
    border: 1px solid #343941;
    border-radius: 10px;
}

.settings-link-row {
    width: 100%;
    min-height: 44px;
    padding: 0 11px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    border: 0;
    border-bottom: 1px solid #2b2f36;
    background: #15181d;
    color: #d2cec8;
    font-size: 10px;
}

.settings-link-row:last-child {
    border-bottom: 0;
}

.settings-delete-btn {
    min-height: 44px;
    border: 1px solid #6e3530;
    background: transparent;
    color: #c9675b;
}

/* ---------- bottom nav from supplied SVG assets ---------- */
.bottom-nav {
    position: fixed;
    left: 50%;
    right: auto;
    bottom: 0;
    transform: translateX(-50%);
    width: 100%;
    max-width: var(--signum-app-width);
    height: var(--signum-nav-height);
    margin: 0;
    padding: 5px 5px 6px;
    display: grid;
    grid-template-columns: repeat(5, minmax(0, 1fr));
    gap: 1px;
    align-items: stretch;
    border-top: 1px solid #6e6658;
    background: #17191d;
    z-index: 1000;
}

@media (min-width: 481px) {
    .bottom-nav {
        bottom: 12px;
        border-radius: 0 0 24px 24px;
        overflow: hidden;
    }
}

.nav-item {
    min-width: 0;
    height: 50px;
    padding: 4px 1px;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 3px;
    border: 0;
    border-radius: 10px;
    background: transparent;
    color: #9d8240;
    cursor: pointer;
}

.nav-icon {
    width: 21px;
    height: 21px;
    padding: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    background: transparent;
}

.nav-icon > img {
    width: 20px;
    height: 20px;
    object-fit: contain;
}

.catalog-grid-icon {
    width: 18px;
    height: 18px;
    display: grid;
    grid-template-columns: repeat(2, 8px);
    grid-template-rows: repeat(2, 8px);
    gap: 2px;
}

.catalog-grid-icon img {
    width: 8px;
    height: 8px;
}

.nav-text {
    color: #a58c52;
    font-size: 7px;
    line-height: 1;
}

.nav-item.active {
    background: #f1e3bd;
    color: #bd902b;
}

.nav-item.active .nav-text {
    color: #3e382d;
}

/* ---------- modal surfaces ---------- */
.app-modal,
#modal-notifications {
    position: fixed;
    inset: 0;
    z-index: 1200;
    padding: 16px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: rgba(0, 0, 0, .76) !important;
    backdrop-filter: blur(4px);
}

.app-modal.hidden,
#modal-notifications.hidden {
    display: none !important;
}

.app-modal-card,
#modal-notifications > .light-card {
    width: min(328px, 100%);
    max-height: min(680px, calc(100dvh - 32px));
    overflow-y: auto;
    padding: 15px;
    border: 1px solid #363b43;
    border-radius: 14px !important;
    background: #15181d !important;
    color: var(--signum-text);
    box-shadow: 0 18px 52px rgba(0, 0, 0, .42);
}

.modal-header-row {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 10px;
    margin-bottom: 10px;
}

.modal-header-row h2 {
    margin: 0;
    font-size: 17px;
}

.modal-close-btn {
    width: 32px;
    height: 32px;
    padding: 0;
    border: 0;
    border-radius: 9px;
    background: #22262c;
    color: #aaa6a8;
    font-size: 18px;
}

.response-order-summary {
    color: #8e8a8d;
    font-size: 10px;
    line-height: 1.4;
}

.response-card {
    margin-bottom: 9px;
    padding: 11px;
    border: 1px solid #343941;
    border-radius: 11px;
    background: #111318;
}

.response-master-row {
    display: flex;
    align-items: center;
    gap: 9px;
}

.response-avatar {
    width: 38px;
    height: 38px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    background: #f2e5bd;
    color: #25211b;
}

.match-card {
    text-align: center;
}

.match-icon {
    width: 58px;
    height: 58px;
    margin: 0 auto 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    border: 1px solid #8b7139;
    border-radius: 50%;
}

.match-asset-icon {
    width: 26px;
    height: 26px;
}

.safety-divider {
    height: 1px;
    margin: 12px 0;
    background: #2c3037;
}

.safety-block-btn {
    border-color: #6f3a34;
    color: #d77568;
}

.safety-complaint-btn {
    background: transparent;
    border: 1px solid #a94e45;
    color: #df6d60;
}

/* ---------- notification center ---------- */
#modal-notifications > .light-card > div:first-child {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 12px;
}

#modal-notifications h3 {
    margin: 0;
    color: var(--signum-text);
    font-size: 17px;
}

#notifications-list-container {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.notifications-empty {
    padding: 22px 0;
    color: #858185;
    text-align: center;
    font-size: 10px;
}

.notification-item {
    padding: 11px 12px;
    border: 1px solid #343941;
    border-radius: 11px;
    background: #111318;
}

.notification-item.is-unread {
    border-color: #715f35;
    box-shadow: inset 3px 0 0 var(--signum-gold);
}

.notification-item h4 {
    margin: 0 0 4px;
    color: #f0ece6;
    font-size: 11px;
}

.notification-item p {
    margin: 0;
    color: #959095;
    font-size: 9px;
    line-height: 1.4;
}

.notification-badge {
    position: absolute;
    top: -4px !important;
    right: -4px !important;
    min-width: 15px;
    height: 15px;
    padding: 0 4px !important;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border: 1px solid #17191d;
    border-radius: 999px;
    background: #d95e4e !important;
    color: #fff;
    font-size: 7px !important;
}

/* ---------- empty / error states ---------- */
.empty-state {
    padding: 34px 14px;
    color: #7f7b7f;
    text-align: center;
    font-size: 10px;
}

.empty-state.compact {
    padding: 18px 10px;
}

.error-text,
.settings-inline-error {
    margin: 0 0 9px;
    color: var(--signum-red);
    font-size: 9px;
    line-height: 1.35;
}

.orders-skeleton {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.orders-skeleton span {
    height: 120px;
    display: block;
    border-radius: 14px;
    background: linear-gradient(90deg, #15181d, #1c2026, #15181d);
    background-size: 180% 100%;
    animation: signumShimmer 1.4s linear infinite;
}

@keyframes signumShimmer {
    to { background-position: -180% 0; }
}

/* ---------- small screens ---------- */
@media (max-width: 359px) {
    .screen {
        padding-left: 12px;
        padding-right: 12px;
    }

    #screen-verify .code-inputs {
        gap: 5px;
    }

    #screen-verify .code-box {
        width: 40px;
    }

    .portfolio-grid {
        gap: 7px !important;
    }
}

/* Desktop preview geometry mirrors the 408×848 design boards: 360×800 phone surface. */
@media (min-width: 481px) {
    .screen {
        height: min(800px, calc(100dvh - 24px));
        min-height: 0;
    }

    .bottom-nav {
        bottom: max(12px, calc(100dvh - 812px));
    }
}

/* Respect initial unread state without exposing a red "0" before API data arrives. */
.notification-badge[style*="display: none"] {
    display: none !important;
}
.complete-asset-icon {
    width: 28px;
    height: 28px;
}

/* =========================================================
   SIGNUM MVP COMPLETE — экраны из утверждённых sketches/assets
   ========================================================= */

.catalog-actions {
    gap: 8px;
}

#btn-open-favorites {
    position: relative;
}

.favorites-header-icon {
    width: 24px;
    height: 24px;
}

.favorite-count-badge {
    position: absolute;
    top: 5px;
    right: 4px;
    min-width: 15px;
    height: 15px;
    padding: 0 3px;
    border-radius: 10px;
    background: var(--bg-card-light);
    color: var(--text-dark);
    font-size: 8px;
    line-height: 15px;
    text-align: center;
    font-weight: 700;
}

.favorite-count-badge.hidden {
    display: none;
}

/* ---------- Избранное / AdDraft.png ---------- */
#screen-favorites {
    padding-top: 28px;
}

.favorites-toolbar {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 18px;
}

.favorites-toolbar h2 {
    margin: 0;
    font-size: 23px;
    line-height: 1;
}

.favorites-heart-counter {
    display: inline-flex;
    align-items: center;
    gap: 3px;
    min-width: 58px;
    height: 42px;
    padding: 0 12px;
    border-radius: 16px;
    background: var(--bg-input);
    color: var(--text-muted);
    font-size: 11px;
}

.favorites-heart-counter img {
    width: 27px;
    height: 27px;
}

.search-bar input,
.favorites-search-bar input {
    padding-left: 40px !important;
    background-image: none !important;
}

.favorites-tabs {
    display: flex;
    gap: 9px;
    margin: 12px 0 16px;
}

.favorites-tab {
    min-width: 108px;
    padding: 13px 20px;
    border: 1px solid var(--border-color);
    border-radius: 12px;
    background: var(--bg-input);
    color: var(--text-white);
    font: inherit;
    font-size: 13px;
    cursor: pointer;
}

.favorites-tab.active {
    border-color: var(--gold-main);
    background: var(--gold-main);
    color: var(--text-dark);
}

.favorites-list {
    display: flex;
    flex-direction: column;
    gap: 13px;
}

.favorite-master-card {
    margin: 0;
    padding: 17px 16px 14px;
    border: 1px solid rgba(196, 154, 69, 0.35);
}

.favorite-master-card .master-card-header {
    margin-bottom: 12px;
}

.favorite-master-card .heart-icon.is-favorite,
.master-card .heart-icon.is-favorite {
    opacity: 1;
}

.master-card .heart-icon:not(.is-favorite) img {
    opacity: .72;
}

.favorite-master-card .favorite-card-footer {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding-top: 11px;
    border-top: 1px solid rgba(26, 26, 26, .08);
    font-size: 12px;
}

.favorite-master-card .profile-link,
.favorite-order-card .favorite-order-open {
    border: 0;
    background: transparent;
    color: var(--text-dark);
    font: inherit;
    font-weight: 600;
    cursor: pointer;
}

.favorite-order-card {
    margin: 0;
}

/* ---------- Публичный профиль мастера ---------- */
.master-public-screen {
    padding-top: 22px;
}

.public-profile-toolbar {
    grid-template-columns: 42px 1fr 42px;
}

.public-profile-toolbar h1 {
    text-align: left;
}

.public-master-favorite {
    width: 42px;
    height: 42px;
}

.public-master-card {
    margin-top: 18px;
}

.public-master-about {
    margin: 20px 0 8px;
}

.public-master-about h3 {
    margin-bottom: 8px;
}

.public-master-about p {
    color: var(--text-muted);
    font-size: 13px;
    line-height: 1.55;
}

.public-portfolio-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 10px;
}

.public-portfolio-project {
    overflow: hidden;
    border-radius: 14px;
    background: var(--bg-input);
    border: 1px solid var(--border-color);
}

.public-portfolio-project-title {
    padding: 9px 10px;
    color: var(--text-white);
    font-size: 12px;
}

.public-portfolio-images {
    display: grid;
    grid-template-columns: 1fr 1fr;
    min-height: 98px;
}

.public-portfolio-image {
    position: relative;
    background: rgba(196, 154, 69, .12);
    background-size: cover;
    background-position: center;
}

.public-portfolio-image::after {
    content: attr(data-label);
    position: absolute;
    inset: auto 0 0;
    padding: 7px 5px;
    background: rgba(11, 12, 16, .62);
    color: var(--text-white);
    text-align: center;
    font-size: 10px;
    font-weight: 700;
}

/* ---------- Отзывы в профиле ---------- */
.profile-reviews-list {
    display: flex;
    flex-direction: column;
    gap: 10px;
    margin-bottom: 20px;
}

.profile-review-card {
    padding: 14px;
    border: 1px solid var(--border-color);
    border-radius: 13px;
    background: var(--bg-input);
}

.profile-review-rating {
    display: flex;
    align-items: center;
    gap: 4px;
    margin-bottom: 9px;
    color: var(--gold-main);
    font-weight: 700;
    font-size: 12px;
}

.profile-review-rating img {
    width: 12px;
    height: 12px;
}

.profile-review-card p {
    color: #d5d5d5;
    font-size: 13px;
    line-height: 1.45;
}

.profile-review-meta,
.profile-reviews-empty {
    margin-top: 7px;
    color: var(--text-muted);
    font-size: 11px;
}

/* ---------- Принятый заказ / SketchofFavorites.png ---------- */
#screen-accepted-order {
    padding-top: 22px;
}

.accepted-order-toolbar {
    grid-template-columns: 42px 1fr;
    margin-bottom: 10px;
}

.accepted-order-toolbar h1 {
    text-align: left;
}

.accepted-status-strip {
    display: flex;
    align-items: center;
    gap: 7px;
    padding: 10px 12px;
    margin: 8px 0 10px;
    border-radius: 11px;
    background: var(--bg-input);
    color: var(--success-green);
    font-size: 11px;
}

.accepted-status-strip img {
    width: 20px;
    height: 20px;
}

.accepted-client-card {
    display: flex;
    align-items: center;
    gap: 11px;
    padding: 12px 11px;
    border: 1px solid var(--border-color);
    border-radius: 13px;
    background: var(--bg-input);
}

.accepted-client-avatar {
    width: 49px;
    height: 49px;
    flex: 0 0 49px;
    font-size: 18px;
}

.accepted-client-copy {
    min-width: 0;
    flex: 1;
    display: flex;
    flex-direction: column;
    gap: 4px;
}

.accepted-client-copy strong {
    font-size: 14px;
}

.accepted-client-copy span {
    color: var(--text-muted);
    font-size: 11px;
}

.accepted-chat-btn {
    width: 44px;
    height: 44px;
    border: 0;
    border-radius: 12px;
    background: var(--bg-card-light);
    cursor: pointer;
}

.accepted-chat-btn img {
    width: 22px;
    height: 22px;
}

.accepted-order-summary {
    margin-top: 10px;
    padding: 14px;
}

.accepted-order-summary h2 {
    margin: 0 0 8px;
    font-size: 16px;
}

.accepted-order-summary > p {
    margin: 0;
    color: #747474;
    font-size: 13px;
    line-height: 1.45;
}

.accepted-proposed-price {
    margin-top: 4px !important;
}

.accepted-proposed-price strong {
    margin-left: 7px;
    color: var(--text-dark);
}

.accepted-field {
    margin-top: 12px;
}

.accepted-field label {
    display: block;
    margin-bottom: 7px;
    color: var(--text-muted);
    font-size: 11px;
}

.accepted-field input {
    width: 100%;
    min-height: 49px;
    padding: 0 14px;
    border: 1px solid var(--border-color);
    border-radius: 11px;
    outline: none;
    background: var(--bg-input);
    color: var(--text-white);
    font: inherit;
    font-size: 13px;
}

.accepted-field input:focus {
    border-color: var(--gold-main);
}

.accepted-date-row {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 9px;
    margin-top: 12px;
}

.accepted-date-tile {
    display: flex;
    align-items: center;
    gap: 9px;
    min-height: 60px;
    padding: 10px 12px;
    border: 1px solid var(--border-color);
    border-radius: 11px;
    background: var(--bg-input);
}

.accepted-date-tile img {
    width: 23px;
    height: 23px;
}

.accepted-date-tile span {
    display: flex;
    flex-direction: column;
    gap: 2px;
}

.accepted-date-tile small {
    color: var(--text-muted);
    font-size: 10px;
}

.accepted-date-tile strong {
    font-size: 13px;
}

.accepted-confirm-btn {
    margin-top: 12px;
}

.accepted-confirm-btn.is-confirmed {
    opacity: .72;
}

.accepted-contact-btn {
    border-color: var(--bg-card-light);
}

.order-open-accepted {
    width: 100%;
    margin-top: 12px;
    padding: 12px;
    border: 1px solid var(--gold-main);
    border-radius: 11px;
    background: transparent;
    color: var(--gold-main);
    font: inherit;
    font-weight: 600;
    cursor: pointer;
}

/* ---------- Отзыв / Review.png ---------- */
#screen-review {
    padding-top: 22px;
}

.review-toolbar {
    grid-template-columns: 42px 1fr;
    margin-bottom: 36px;
}

.review-toolbar h1 {
    text-align: left;
}

.review-master-card {
    display: flex;
    align-items: center;
    gap: 12px;
    margin-bottom: 24px;
    padding: 16px 14px;
}

.review-master-card > div:last-child {
    display: flex;
    flex-direction: column;
    gap: 5px;
}

.review-master-card strong {
    font-size: 15px;
}

.review-master-card span {
    color: #858585;
    font-size: 11px;
}

.review-copy h2 {
    margin: 0 0 5px;
    font-size: 21px;
}

.review-copy p {
    color: var(--text-muted);
    font-size: 12px;
}

.review-field {
    margin-top: 28px;
}

.review-field label {
    display: block;
    margin-bottom: 8px;
    color: var(--text-muted);
    font-size: 11px;
}

.review-field textarea {
    min-height: 138px;
}

.review-rating-block {
    margin-top: 20px;
}

.review-rating-block > strong {
    display: block;
    margin-bottom: 9px;
    font-size: 12px;
}

.review-rating {
    display: flex;
    gap: 9px;
}

.rating-star {
    width: 48px;
    height: 48px;
    border: 1px solid #d8c18d;
    border-radius: 12px;
    background: var(--bg-input);
    cursor: pointer;
    transition: background-color .15s, border-color .15s, transform .15s;
}

.rating-star img {
    width: 15px;
    height: 15px;
}

.rating-star.selected,
.rating-star:hover {
    background: rgba(196, 154, 69, .16);
    border-color: var(--gold-main);
}

.rating-star:active {
    transform: scale(.96);
}

.review-submit-btn {
    margin-top: 34px;
}

.review-action-button {
    width: 100%;
    margin-top: 11px;
    padding: 12px;
    border: 0;
    border-radius: 11px;
    background: var(--gold-main);
    color: var(--text-dark);
    font: inherit;
    font-weight: 700;
    cursor: pointer;
}

.review-action-button.is-done {
    background: var(--bg-input);
    color: var(--text-muted);
    cursor: default;
}

/* ---------- Notification deep links ---------- */
.notifications-header-actions {
    display: flex;
    align-items: center;
    gap: 8px;
}

.notification-read-all {
    border: 0;
    background: transparent;
    color: var(--gold-main);
    font: inherit;
    font-size: 11px;
    cursor: pointer;
}

.notification-item {
    cursor: pointer;
}

.notification-item:hover {
    border-color: rgba(196, 154, 69, .5);
}

.notification-item-meta {
    display: flex;
    justify-content: space-between;
    gap: 8px;
    margin-top: 8px;
    color: var(--text-muted);
    font-size: 10px;
}

.notification-item-action {
    color: var(--gold-main);
}

@media (max-width: 390px) {
    .review-rating {
        gap: 7px;
    }
    .rating-star {
        width: 43px;
        height: 43px;
    }
}

/* Сохранённые заявки: нейтральное текстовое действие в существующей системе. */
.order-feed-actions-row {
    display: grid;
    grid-template-columns: minmax(0, 1fr) auto;
    align-items: center;
    gap: 12px;
}
.order-feed-actions-row .order-primary-action { margin: 0; }
.order-mark-action {
    min-height: 44px;
    padding: 0 4px;
    border: 0;
    background: transparent;
    color: var(--gold-main);
    font: inherit;
    font-size: 12px;
    font-weight: 600;
    cursor: pointer;
}
.order-mark-action.is-favorite { color: var(--text-muted); }
.settings-link-arrow {
    width: 14px;
    height: 14px;
    object-fit: contain;
}
.response-rating {
    display: inline-flex;
    align-items: center;
    gap: 5px;
}
.response-rating img {
    width: 14px;
    height: 14px;
}
.profile-service-ads {
    display: grid;
    gap: 10px;
    margin-bottom: 18px;
}
.profile-service-ad {
    min-height: 72px;
    padding: 14px;
    border: 1px solid var(--border-color);
    border-radius: var(--radius-md);
    background: var(--bg-input);
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
}
.profile-service-ad div { min-width: 0; display: grid; gap: 7px; }
.profile-service-ad strong { font-size: 14px; color: var(--text-white); }
.profile-service-ad span { font-size: 11px; color: var(--success-green); }
.profile-service-ad img { width: 14px; height: 14px; transform: rotate(180deg); flex: 0 0 auto; }

/* Локальный режим разработки: код подтверждения показывается только когда
   backend запущен в DEBUG без настроенного SMTP. В production блок скрыт. */
.dev-code-hint {
    margin: -12px 0 18px;
    padding: 10px 12px;
    border: 1px solid rgba(196, 154, 69, 0.45);
    border-radius: 10px;
    background: rgba(196, 154, 69, 0.08);
    color: var(--gold-main, #C49A45);
    font-size: 12px;
    line-height: 1.4;
    text-align: center;
}


/* ===== V6: active navigation keeps the supplied SVG icon unchanged ===== */
.bottom-nav .nav-item.active .nav-icon {
    width: 21px;
    height: 21px;
    padding: 0;
    border-radius: 0;
    background: transparent;
    color: inherit;
}

.bottom-nav .nav-item.active .nav-icon > img,
.bottom-nav .nav-item.active .catalog-grid-icon img {
    opacity: 1;
    filter: none;
    transform: none;
}

/* ===== V6: catalog filters ===== */
.catalog-filter-panel {
    margin: -2px 0 14px;
    padding: 14px;
    border: 1px solid #343941;
    border-radius: 14px;
    background: #15181d;
    box-shadow: 0 10px 28px rgba(0, 0, 0, .24);
}

.catalog-filter-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    margin-bottom: 13px;
}

.catalog-filter-header h3 {
    margin: 0;
    color: #f2eee7;
    font-size: 15px;
}

.catalog-filter-close {
    padding: 0;
    border: 0;
    background: transparent;
    color: #c79a3b;
    font-size: 10px;
    cursor: pointer;
}

.catalog-filter-field {
    margin: 0 0 13px;
}

.catalog-filter-field > label,
.catalog-filter-field legend {
    display: block;
    margin: 0 0 7px;
    padding: 0;
    color: #aaa49a;
    font-size: 9px;
}

.catalog-filter-fieldset {
    min-width: 0;
    padding: 0;
    border: 0;
}

.catalog-filter-field input[type="text"],
.catalog-filter-field input[type="number"],
.catalog-filter-field select {
    width: 100%;
    height: 40px;
    padding: 0 12px;
    border: 1px solid #343941;
    border-radius: 10px;
    outline: 0;
    background: #111419;
    color: #f2eee7;
    font: inherit;
    font-size: 10px;
}

.catalog-filter-field input:focus,
.catalog-filter-field select:focus {
    border-color: #c79a3b;
}

.catalog-price-row {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 8px;
}

.catalog-filter-chips {
    display: flex;
    flex-wrap: wrap;
    gap: 7px;
}

.catalog-filter-chips label {
    position: relative;
    cursor: pointer;
}

.catalog-filter-chips input {
    position: absolute;
    opacity: 0;
    pointer-events: none;
}

.catalog-filter-chips span {
    min-height: 30px;
    padding: 0 10px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border: 1px solid #343941;
    border-radius: 999px;
    background: #111419;
    color: #aaa49a;
    font-size: 9px;
    transition: .18s ease;
}

.catalog-filter-chips input:checked + span {
    border-color: #c79a3b;
    background: #c79a3b;
    color: #101216;
}

.catalog-filter-actions {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 8px;
    margin-top: 4px;
}

.catalog-filter-actions .btn {
    min-height: 40px;
    margin: 0;
    padding: 10px 8px;
    font-size: 10px;
}

#btn-filter[aria-expanded="true"] {
    border-color: #c79a3b;
    background: rgba(199, 154, 59, .08);
}


/* =========================================
   PASSWORD VISIBILITY CONTROL
   CSS-only icon: no foreign SVG/emoji is introduced.
========================================= */
.password-field-shell {
    position: relative;
    width: 100%;
}

.password-field-shell > input {
    padding-right: 48px !important;
}

.password-visibility-btn {
    position: absolute;
    top: 50%;
    right: 9px;
    width: 34px;
    height: 34px;
    padding: 0;
    border: 0;
    border-radius: 9px;
    background: transparent;
    color: var(--gold-main);
    display: inline-flex;
    align-items: center;
    justify-content: center;
    transform: translateY(-50%);
    cursor: pointer;
    z-index: 2;
}

.password-visibility-btn:hover {
    background: rgba(196, 154, 69, 0.08);
}

.password-visibility-btn:focus-visible {
    outline: 1px solid var(--gold-main);
    outline-offset: 1px;
}

.password-eye {
    position: relative;
    width: 18px;
    height: 12px;
    border: 1.5px solid currentColor;
    border-radius: 50% / 60%;
    display: block;
}

.password-eye::after {
    content: '';
    position: absolute;
    left: 50%;
    top: 50%;
    width: 4px;
    height: 4px;
    border-radius: 50%;
    background: currentColor;
    transform: translate(-50%, -50%);
}

.password-visibility-btn.is-visible .password-eye::before {
    content: '';
    position: absolute;
    left: -2px;
    top: 5px;
    width: 22px;
    height: 1.5px;
    border-radius: 2px;
    background: currentColor;
    transform: rotate(-35deg);
    transform-origin: center;
}

#screen-auth .password-visibility-btn {
    color: var(--gold-main);
}

#screen-settings .password-visibility-btn {
    color: #b58d39;
}

/* =========================================
   СОСТАВНЫЕ SVG-ИКОНКИ
   Один визуальный элемент может состоять из двух SVG.
   Пути к файлам задаются в HTML и не изменяются.
========================================= */
.svg-stack {
    position: relative;
    display: inline-block;
    flex: 0 0 auto;
    line-height: 0;
    vertical-align: middle;
}

.svg-stack > img {
    position: absolute;
    inset: 0;
    display: block;
    width: 100%;
    height: 100%;
    object-fit: contain;
    pointer-events: none;
    user-select: none;
}

/* Иконки в кнопках шапки: колокол, настройки */
.svg-stack--ui {
    width: 20px;
    height: 20px;
}

/* Маленькая составная галочка «Профиль проверен» */
.svg-stack--verified {
    width: 12px;
    height: 12px;
    margin-right: 4px;
}

/* Финальный экран регистрации */
.svg-stack--complete {
    width: 28px;
    height: 28px;
}

/* Успешный мэтч */
.svg-stack--match {
    width: 26px;
    height: 26px;
}

/* Статус принятого заказа */
.svg-stack--status {
    width: 20px;
    height: 20px;
}

/* Календарь и часы в принятом заказе */
.svg-stack--date {
    width: 23px;
    height: 23px;
}

/* Не даём старым правилам для обычных img ломать размеры составных иконок */
.complete-icon > .svg-stack,
.match-icon > .svg-stack,
.accepted-status-strip > .svg-stack,
.accepted-date-tile > .svg-stack,
.icon-btn > .svg-stack {
    flex-shrink: 0;
}

.verified-badge > .svg-stack {
    flex-shrink: 0;
}

/* =========================================================
   СОСТАВНЫЕ SVG-ИКОНКИ — ИСПРАВЛЕННАЯ СБОРКА
   Каждый SVG остаётся отдельным файлом и занимает своё место.
   ========================================================= */

/* Общая база для составных иконок */
.svg-composite {
    position: relative;
    display: inline-block;
    flex: 0 0 auto;
    vertical-align: middle;
}

.svg-composite > .svg-part {
    position: absolute;
    display: block;
    max-width: none;
    pointer-events: none;
    user-select: none;
}

/* Галочка внутри кружка */
.svg-check-circle {
    width: 20px;
    height: 20px;
}

.svg-check-circle > .svg-circle {
    inset: 0;
    width: 100%;
    height: 100%;
}

.svg-check-circle > .svg-check {
    left: 22.5%;
    top: 30%;
    width: 55%;
    height: 40%;
}

.complete-icon .complete-asset-icon {
    width: 28px;
    height: 28px;
}

.match-icon .match-asset-icon {
    width: 26px;
    height: 26px;
}

.verified-badge .verified-icon {
    width: 12px;
    height: 12px;
}

.accepted-status-strip .accepted-status-icon {
    width: 20px;
    height: 20px;
}

/* Колокол: основная форма + нижняя перемычка */
.svg-bell {
    width: 20px !important;
    height: 20px !important;
}

.svg-bell > .svg-bell-body {
    left: 0.5px;
    top: 0;
    width: 19px;
    height: 16px;
}

.svg-bell > .svg-bell-clapper {
    left: 7px;
    top: 17px;
    width: 6px;
    height: 2px;
}

/* Шестерёнка: наружная грань + центральный круг */
#btn-open-settings {
    display: grid;
    place-items: center;
}

.svg-gear {
    position: relative;
    display: block;
    width: 21px !important;
    height: 21px !important;
}

.svg-gear > .svg-gear-body {
    position: absolute;
    left: 0;
    top: 0;
    width: 21px;
    height: 21px;
    display: block;
}

.svg-gear > .svg-gear-center {
    position: absolute;
    left: 50%;
    top: 50%;
    transform: translate(-50%, -50%);
    width: 8px;
    height: 8px;
    display: block;
}

/* Календарь: рамка + верхние засечки/разделитель */
.svg-calendar {
    width: 23px;
    height: 23px;
}

.svg-calendar > .svg-calendar-frame {
    left: 0;
    top: 2px;
    width: 23px;
    height: 21px;
}

.svg-calendar > .svg-calendar-grid {
    left: 0;
    top: 2px;
    width: 23px;
    height: 10px;
}

/* Часы: круг + стрелки */
.svg-clock {
    width: 23px;
    height: 23px;
}

.svg-clock > .svg-clock-circle {
    inset: 0;
    width: 23px;
    height: 23px;
}

.svg-clock > .svg-clock-hand {
    left: 10.3px;
    top: 4.6px;
    width: 5.8px;
    height: 10.4px;
}

/* Старые правила для img внутри принятых условий
   не должны растягивать отдельные части составной иконки. */
.accepted-status-strip > .svg-composite,
.accepted-date-tile > .svg-composite {
    flex: 0 0 auto;
}

.accepted-status-strip .svg-composite img,
.accepted-date-tile .svg-composite img {
    max-width: none;
}

/* Лупа: кружок + ручка */
.search-bar {
    position: relative;
}

.search-icon-composite {
    position: absolute;
    left: 12px;
    top: 22px;
    transform: translateY(-50%);

    width: 16px;
    height: 16px;

    z-index: 2;
    pointer-events: none;
}

.search-icon-composite > img {
    position: absolute;
    display: block;
    max-width: none;
    pointer-events: none;
    user-select: none;
}

.search-icon-circle {
    left: 0;
    top: 0;
    width: 14px;
    height: 14px;
}

.search-icon-handle {
    left: 10px;
    top: 10px;
    width: 6px;
    height: 6px;
}

.search-bar input,
.favorites-search-bar input {
    padding-left: 40px !important;
    background-image: none !important;
}


/* Пустое состояние заявок: всё по центральной оси */
#orders-empty-state {
    width: 100%;
    text-align: center;
}

#orders-empty-state .empty-state-icon {
    display: flex;
    justify-content: center;
    align-items: center;
}

#orders-empty-state p {
    text-align: center;
}

#btn-empty-create-order {
    display: block;
    width: 100%;
    max-width: 300px;
    margin: 14px auto 0;
}

/* =========================================================
   Авторизация: третья строка — код приглашения
   ========================================================= */
#screen-auth .auth-body {
    margin-top: 66px;
}

#screen-auth .auth-invite-group {
    margin-top: 0;
    margin-bottom: 10px;
}

#screen-auth #auth-invite {
    border-color: var(--border-color);
    text-transform: uppercase;
    letter-spacing: 0.03em;
}

#screen-auth #auth-invite:focus {
    border-color: #b49a5f;
}

#screen-auth #auth-invite::placeholder {
    text-transform: none;
    letter-spacing: normal;
}

#screen-auth .auth-forgot-password {
    margin: -1px 0 24px;
}

/* =========================================================
   ЭТАП 3: ПРАВОВАЯ ИНФОРМАЦИЯ + ТЕХПОДДЕРЖКА
   ========================================================= */

.legal-screen,
.support-screen {
    padding-top: 16px;
    padding-bottom: 32px;
    overflow-y: auto;
}

.legal-toolbar,
.support-toolbar {
    position: sticky;
    top: 0;
    z-index: 5;
    padding: 0 0 12px;
    background: var(--bg-main);
}

.legal-content,
.support-content {
    padding-top: 10px;
}

.legal-section {
    padding: 18px 0 26px;
}

.legal-section + .legal-section {
    border-top: 1px solid var(--border-color);
}

.legal-section .eyebrow {
    margin-bottom: 8px;
}

.legal-section h2,
.support-intro h2,
.support-history h2 {
    margin: 0 0 12px;
    color: var(--text-white);
    font-size: 20px;
    line-height: 1.3;
}

.legal-section h3 {
    margin: 22px 0 8px;
    color: var(--text-white);
    font-size: 14px;
    line-height: 1.4;
}

.legal-section p,
.support-intro p {
    margin: 0 0 13px;
    color: var(--text-muted);
    font-size: 12px;
    line-height: 1.65;
}

.legal-placeholder-note {
    padding: 12px 13px;
    border: 1px solid rgba(201, 157, 61, .45);
    border-radius: 12px;
    background: rgba(201, 157, 61, .08);
    color: #d9c58d !important;
}

.legal-inline-link {
    appearance: none;
    border: 0;
    padding: 0;
    background: transparent;
    color: var(--gold-main);
    font: inherit;
    cursor: pointer;
}

.legal-inline-link:hover,
.legal-inline-link:focus-visible {
    color: var(--gold-hover);
    outline: none;
    text-decoration: underline;
}

.support-intro {
    margin-bottom: 22px;
}

.support-content .input-group {
    margin-bottom: 16px;
}

.support-content textarea {
    min-height: 148px;
    resize: vertical;
}

.support-success {
    margin: 0 0 14px;
    padding: 10px 12px;
    border: 1px solid rgba(66, 160, 92, .42);
    border-radius: 10px;
    background: rgba(66, 160, 92, .08);
    color: #8bd29f;
    font-size: 12px;
}

.support-history {
    margin-top: 30px;
    padding-top: 24px;
    border-top: 1px solid var(--border-color);
}

.support-history-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    margin-bottom: 12px;
}

.support-history-header h2 {
    margin: 0;
    font-size: 17px;
}

.support-refresh-btn {
    appearance: none;
    border: 0;
    padding: 0;
    background: transparent;
    color: var(--gold-main);
    font-size: 11px;
    cursor: pointer;
}

.support-tickets-list {
    display: grid;
    gap: 10px;
}

.support-ticket {
    padding: 13px;
    border: 1px solid var(--border-color);
    border-radius: 13px;
    background: #15181d;
}

.support-ticket-top {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 10px;
    margin-bottom: 7px;
}

.support-ticket-topic {
    color: var(--text-white);
    font-size: 12px;
    font-weight: 700;
}

.support-ticket-status {
    flex: 0 0 auto;
    padding: 3px 7px;
    border-radius: 999px;
    background: #30343b;
    color: #b8bbc1;
    font-size: 9px;
    font-weight: 700;
}

.support-ticket-status[data-status="new"] {
    background: rgba(184, 137, 41, .18);
    color: #e0bf74;
}

.support-ticket-status[data-status="in_progress"] {
    background: rgba(75, 103, 161, .2);
    color: #a8bce8;
}

.support-ticket-status[data-status="closed"] {
    background: rgba(45, 125, 70, .2);
    color: #8bd29f;
}

.support-ticket-message,
.support-ticket-reply {
    margin: 0;
    color: var(--text-muted);
    font-size: 11px;
    line-height: 1.5;
    white-space: pre-wrap;
}

.support-ticket-reply {
    margin-top: 9px;
    padding-top: 9px;
    border-top: 1px solid rgba(255, 255, 255, .07);
    color: #d3d6dc;
}

.support-ticket-date {
    display: block;
    margin-top: 8px;
    color: #6f747d;
    font-size: 9px;
}

/* =========================================================
   ЧАТЫ: ЧЁРНЫЙ СПИСОК
   ========================================================= */
.chat-blacklist-btn {
    appearance: none;
    border: 0;
    padding: 4px;
    background: transparent;
    cursor: pointer;
}

.chat-blacklist-btn:hover,
.chat-blacklist-btn:focus-visible {
    outline: none;
    opacity: .82;
}

.blacklist-screen {
    padding-top: 16px;
    padding-bottom: 92px;
    overflow-y: auto;
}

.blacklist-toolbar {
    display: flex;
    align-items: center;
    gap: 12px;
    margin-bottom: 18px;
}

.blacklist-toolbar-copy {
    min-width: 0;
}

.blacklist-toolbar-copy .eyebrow {
    margin: 0 0 2px;
}

.blacklist-toolbar h1 {
    margin: 0;
    font-size: 20px;
}

.blacklist-lead {
    margin: 0 0 18px;
    color: var(--text-muted);
    font-size: 11px;
    line-height: 1.55;
}

.blacklist-list {
    display: grid;
    gap: 10px;
}

.blacklist-card {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 13px;
    border: 1px solid var(--border-color);
    border-radius: 14px;
    background: #15181d;
}

.blacklist-avatar {
    display: grid;
    place-items: center;
    width: 42px;
    height: 42px;
    flex: 0 0 42px;
    border-radius: 50%;
    background: #252a31;
    color: #e7e3da;
    font-size: 15px;
    font-weight: 800;
}

.blacklist-user-copy {
    min-width: 0;
    flex: 1 1 auto;
}

.blacklist-user-copy strong {
    display: block;
    overflow: hidden;
    color: var(--text-white);
    font-size: 12px;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.blacklist-user-copy span {
    display: block;
    margin-top: 3px;
    color: var(--text-muted);
    font-size: 9px;
}

.blacklist-unblock-btn {
    appearance: none;
    flex: 0 0 auto;
    border: 1px solid rgba(201, 157, 61, .55);
    border-radius: 9px;
    padding: 7px 9px;
    background: transparent;
    color: var(--gold-main);
    font: inherit;
    font-size: 10px;
    font-weight: 700;
    cursor: pointer;
}

.blacklist-unblock-btn:disabled {
    opacity: .55;
    cursor: default;
}

.blacklist-empty {
    padding: 26px 15px;
    border: 1px dashed var(--border-color);
    border-radius: 14px;
    color: var(--text-muted);
    text-align: center;
    font-size: 11px;
    line-height: 1.5;
}

/* =========================================================
   ЭТАП 3: СДЕЛКА → ЧАТ → ЗАВЕРШЕНИЕ → ОТЗЫВ
   ========================================================= */
.matched-order-info {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 8px;
    margin: 12px 0 9px;
}

.matched-order-info > div {
    min-width: 0;
    padding: 10px 11px;
    border: 1px solid var(--border-color);
    border-radius: 11px;
    background: rgba(255, 255, 255, .025);
}

.matched-order-info span {
    display: block;
    margin-bottom: 4px;
    color: var(--text-muted);
    font-size: 9px;
}

.matched-order-info strong {
    display: block;
    overflow: hidden;
    color: var(--text-white);
    font-size: 11px;
    line-height: 1.35;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.matched-order-actions {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 8px;
    margin-top: 12px;
}

.matched-order-actions:has(.order-open-accepted:only-child),
.matched-order-actions:has(.order-chat-action:only-child) {
    grid-template-columns: 1fr;
}

.order-chat-action {
    width: 100%;
    margin: 9px 0 0;
    border: 1px solid rgba(196, 154, 69, .55);
    border-radius: 10px;
    padding: 10px 12px;
    background: transparent;
    color: var(--gold-main);
    font: inherit;
    font-size: 11px;
    font-weight: 750;
    cursor: pointer;
}

.matched-order-actions .order-chat-action,
.matched-order-actions .order-open-accepted {
    margin-top: 0;
}

.order-chat-action:hover,
.order-chat-action:focus-visible {
    outline: none;
    border-color: var(--gold-main);
    background: rgba(196, 154, 69, .07);
}

/* =========================================================
   ЭТАП 3: РЕГИСТРАЦИЯ И ВОССТАНОВЛЕНИЕ ПАРОЛЯ
   ========================================================= */
#screen-auth .auth-invite-hint {
    display: block;
    margin-top: 5px;
    color: #747981;
    font-size: 9px;
    line-height: 1.35;
}

.auth-success {
    margin: 0 0 14px;
    padding: 10px 12px;
    border: 1px solid rgba(66, 160, 92, .42);
    border-radius: 10px;
    background: rgba(66, 160, 92, .08);
    color: #8bd29f;
    font-size: 11px;
    line-height: 1.45;
}

.reset-password-screen {
    padding-top: 16px;
    padding-bottom: 30px;
    overflow-y: auto;
}

.reset-password-toolbar {
    display: flex;
    align-items: center;
    gap: 12px;
}

.reset-password-toolbar h1 {
    margin: 0;
    font-size: 18px;
}

.reset-password-body {
    margin-top: 54px;
}

.reset-password-body h2 {
    margin: 0 0 8px;
    color: var(--text-white);
    font-size: 21px;
}

.reset-password-body > .text-muted {
    margin: 0 0 28px;
    font-size: 11px;
    line-height: 1.55;
}

.reset-password-body .input-group {
    margin-bottom: 17px;
}

.reset-password-body #btn-reset-send-code {
    margin-top: 8px;
}

/* =========================================================
   ЭТАП 3: ЧАТЫ / БЛОКИРОВКИ / ЖАЛОБЫ / ЧЁРНЫЙ СПИСОК
   ========================================================= */
.blacklist-avatar.has-photo {
    background-position: center;
    background-size: cover;
    background-repeat: no-repeat;
    color: transparent;
}

.safety-success {
    margin: 0 0 12px;
    padding: 9px 10px;
    border: 1px solid rgba(66, 160, 92, .42);
    border-radius: 10px;
    background: rgba(66, 160, 92, .08);
    color: #8bd29f;
    font-size: 10px;
    line-height: 1.45;
}

.chat-list-item.blocked {
    opacity: .82;
}

.chat-blocked-banner {
    line-height: 1.45;
}

/* =========================================================
   ЭТАП 3: ПРОФИЛЬ И НАСТРОЙКИ
   ========================================================= */
.settings-input[readonly] {
    cursor: default;
    opacity: .82;
}

.settings-field-note {
    display: block;
    margin-top: 5px;
    color: #747981;
    font-size: 9px;
    line-height: 1.35;
}

/* =========================================================
   ФИНАЛЬНАЯ ИНТЕГРАЦИЯ: РОЛЕВОЙ СЦЕНАРИЙ
   ========================================================= */
.profile-role-action-hint {
    margin: 10px 0 0;
    padding: 9px 10px;
    border: 1px solid rgba(196, 154, 69, .42);
    border-radius: 10px;
    background: rgba(196, 154, 69, .08);
    color: #d9c58d;
    font-size: 10px;
    line-height: 1.45;
}

/* =========================================================
   ПРЕДРЕЛИЗНАЯ УСТОЙЧИВОСТЬ
   ========================================================= */
.network-status-banner {
    position: fixed;
    top: max(8px, env(safe-area-inset-top));
    left: 50%;
    z-index: 9999;
    width: min(calc(100% - 24px), 420px);
    transform: translateX(-50%);
    padding: 9px 12px;
    border: 1px solid rgba(196, 154, 69, .55);
    border-radius: 11px;
    background: #171a1f;
    color: #e1c47b;
    box-shadow: 0 8px 24px rgba(0, 0, 0, .28);
    text-align: center;
    font-size: 10px;
    line-height: 1.4;
}

/* =========================================================
   ФИНАЛЬНЫЙ UI QA: МОБИЛЬНАЯ ПОЛИРОВКА
   ========================================================= */

/* Нижняя навигация не конфликтует с home indicator на iPhone. */
@media (max-width: 480px) {
    .bottom-nav {
        height: calc(var(--signum-nav-height) + env(safe-area-inset-bottom));
        padding-bottom: calc(6px + env(safe-area-inset-bottom));
    }

    .main-screen {
        padding-bottom: calc(
            var(--signum-nav-height)
            + env(safe-area-inset-bottom)
            + 16px
        );
    }
}

/* На очень узких экранах все три вкладки заказов видны одновременно. */
@media (max-width: 339px) {
    .order-tabs {
        display: grid;
        grid-template-columns: repeat(3, minmax(0, 1fr));
        gap: 4px;
        overflow: visible;
    }

    .order-tab {
        width: 100%;
        min-width: 0;
        padding: 0 3px;
        font-size: 9px;
        white-space: nowrap;
    }

    .order-tab span {
        min-width: 15px;
        height: 16px;
        margin-left: 1px;
        padding: 0 3px;
        font-size: 8px;
    }
}

/* Увеличиваем touch-area небольших текстовых действий без смены визуального стиля. */
#screen-auth .auth-forgot-link,
.settings-role-change,
.support-refresh-btn {
    min-height: 32px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    touch-action: manipulation;
}

#screen-auth .legal-inline-link {
    min-height: 26px;
    display: inline-flex;
    align-items: center;
    touch-action: manipulation;
}

button,
.nav-item,
.settings-link-row,
.choice-chip {
    touch-action: manipulation;
}

/* =========================================================
   ФИНАЛЬНЫЕ ЮРИДИЧЕСКИЕ ДОКУМЕНТЫ
   ========================================================= */
.legal-document-subtitle {
    margin-bottom: 4px !important;
    color: var(--text-white) !important;
    font-weight: 600;
}

.legal-document-version {
    margin-bottom: 20px !important;
    color: #8c9198 !important;
    font-size: 10px !important;
}

.legal-list {
    margin: 0 0 15px;
    padding-left: 19px;
    color: var(--text-muted);
    font-size: 12px;
    line-height: 1.65;
}

.legal-list li {
    margin-bottom: 7px;
}

.legal-table-wrap {
    width: 100%;
    margin: 11px 0 18px;
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
    border: 1px solid var(--border-color);
    border-radius: 12px;
    background: #12151a;
}

.legal-table {
    width: 100%;
    min-width: 520px;
    border-collapse: collapse;
    color: var(--text-muted);
    font-size: 10px;
    line-height: 1.45;
}

.legal-table th,
.legal-table td {
    padding: 9px 10px;
    border-right: 1px solid var(--border-color);
    border-bottom: 1px solid var(--border-color);
    text-align: left;
    vertical-align: top;
}

.legal-table th:last-child,
.legal-table td:last-child {
    border-right: 0;
}

.legal-table tr:last-child td {
    border-bottom: 0;
}

.legal-table th {
    color: var(--text-white);
    font-weight: 600;
    background: rgba(196, 154, 69, .08);
}

@media (max-width: 480px) {
    .legal-table {
        min-width: 470px;
    }

    .legal-section h2 {
        font-size: 18px;
    }
}

/* =========================================================
   ОТДЕЛЬНЫЕ ЮРИДИЧЕСКИЕ ДОКУМЕНТЫ МАСТЕРА
   ========================================================= */
.master-legal-consent-row.hidden {
    display: none;
}

.settings-master-legal-card {
    margin: 10px 0 14px;
    padding: 12px;
    border: 1px solid rgba(196, 154, 69, .35);
    border-radius: 12px;
    background: rgba(196, 154, 69, .06);
}

.settings-master-legal-card.hidden {
    display: none;
}

.settings-master-legal-title {
    margin: 0 0 4px;
    color: var(--text-white);
    font-size: 12px;
    font-weight: 600;
}

.settings-master-legal-copy {
    margin: 0 0 10px;
    color: var(--text-muted);
    font-size: 10px;
    line-height: 1.45;
}

.settings-master-consent-row + .settings-master-consent-row {
    margin-top: 9px;
}

.master-legal-document {
    scroll-margin-top: 12px;
}

/* =========================================================
   ROLE NAVIGATION: MASTER FEED / CLIENT CATALOG
   ========================================================= */
.bottom-nav.master-mode {
    grid-template-columns: repeat(5, minmax(0, 1fr));
}

/* В режиме Мастера сохраняем исходные 5 пунктов навигации. */
.bottom-nav.master-mode #nav-create-order {
    display: flex;
}



/* =========================================
   CHAT UNREAD BADGES
   Сообщения считаются отдельно от обычных уведомлений.
========================================= */
.nav-icon-chat {
    position: relative;
    overflow: visible;
}

.chat-nav-unread-badge {
    position: absolute;
    top: -7px;
    right: -9px;
    z-index: 6;
    min-width: 17px;
    height: 17px;
    padding: 0 4px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border: 1px solid #0b0c10;
    border-radius: 999px;
    background: var(--signum-gold, var(--gold-main));
    color: #17130d;
    font-size: 8px;
    font-weight: 800;
    line-height: 1;
    box-sizing: border-box;
    pointer-events: none;
}

.chat-list-item .chat-unread-badge {
    top: 1px;
    right: 1px;
    z-index: 5;
    min-width: 18px;
    height: 18px;
    border: 1px solid #0b0c10;
    box-shadow: 0 0 0 1px rgba(196, 154, 69, .18);
}

/* =========================================================
   MOBILE / NATIVE PREP V1
   Android + iOS + future Capacitor shell
   ========================================================= */

@media (max-width: 480px) {
    .screen {
        min-height: var(--visual-viewport-height, 100dvh);
        padding-top: max(16px, env(safe-area-inset-top));
        padding-left: max(16px, env(safe-area-inset-left));
        padding-right: max(16px, env(safe-area-inset-right));
    }

    /*
       iOS Safari увеличивает страницу при фокусе,
       если размер текста поля меньше 16px.
    */
    input,
    textarea,
    select,
    .chat-input input,
    #chat-message-input {
        font-size: 16px !important;
    }

    /*
       При открытой экранной клавиатуре нижнее меню
       не должно перекрывать формы и чат.
    */
    body.keyboard-open .bottom-nav {
        opacity: 0;
        pointer-events: none;
        transform: translateX(-50%) translateY(100%);
    }

    body.keyboard-open .main-screen {
        padding-bottom: 16px;
    }
}

html {
    -webkit-text-size-adjust: 100%;
}
