/* ============================================================
   Дизайн-токены
   ============================================================ */
:root {
    --sidebar-bg: #1e293b;
    --sidebar-hover: #334155;
    --sidebar-active: rgba(59, 130, 246, 0.18);
    --sidebar-text: #cbd5e1;
    --sidebar-text-muted: #94a3b8;

    --bg-page: #f8fafc;
    --bg-card: #ffffff;
    --bg-subtle: #f1f5f9;
    --bg-hover: #f8fafc;

    --text-primary: #0f172a;
    --text-secondary: #64748b;
    --text-tertiary: #94a3b8;

    --border: #e2e8f0;
    --border-strong: #cbd5e1;

    --brand: #3b82f6;
    --brand-hover: #2563eb;

    --success-bg: #dcfce7; --success-text: #166534;
    --warning-bg: #fef3c7; --warning-text: #92400e;
    --danger-bg:  #fee2e2; --danger-text:  #991b1b;
    --info-bg:    #dbeafe; --info-text:    #1e40af;

    --radius-sm: 6px;
    --radius-md: 8px;
    --radius-lg: 12px;

    --shadow-sm: 0 1px 2px rgba(15, 23, 42, 0.04);
}

* { box-sizing: border-box; }

html, body { margin: 0; padding: 0; height: 100%; }

body {
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", "Inter",
                 Roboto, "Helvetica Neue", Arial, sans-serif;
    background: var(--bg-page);
    color: var(--text-primary);
    font-size: 14px;
    line-height: 1.5;
    -webkit-font-smoothing: antialiased;
}

a { color: var(--brand); text-decoration: none; }
a:hover { text-decoration: underline; }

/* ============================================================
   Макет с боковой панелью
   ============================================================ */
.app-layout {
    display: grid;
    grid-template-columns: 240px 1fr;
    min-height: 100vh;
}

.sidebar {
    background: var(--sidebar-bg);
    color: var(--sidebar-text);
    display: flex;
    flex-direction: column;
    position: sticky;
    top: 0;
    height: 100vh;
}

.sidebar-brand {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 20px 20px 18px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.08);
}

.sidebar-brand-icon {
    width: 36px;
    height: 36px;
    border-radius: 9px;
    background: var(--brand);
    color: white;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 18px;
    flex-shrink: 0;
}

.sidebar-brand-text { line-height: 1.2; }
.sidebar-brand-title { color: white; font-weight: 600; font-size: 15px; }
.sidebar-brand-sub { font-size: 11px; color: var(--sidebar-text-muted); }

.sidebar-nav {
    padding: 14px 10px;
    display: flex;
    flex-direction: column;
    gap: 2px;
    flex: 1;
}

.sidebar-nav a {
    display: flex;
    align-items: center;
    gap: 11px;
    padding: 10px 13px;
    border-radius: var(--radius-sm);
    color: var(--sidebar-text);
    font-size: 13.5px;
    transition: background 0.15s, color 0.15s;
}

.sidebar-nav a:hover { background: var(--sidebar-hover); color: white; text-decoration: none; }
.sidebar-nav a.active { background: var(--sidebar-active); color: white; }
.sidebar-nav .nav-icon { font-size: 17px; width: 17px; text-align: center; flex-shrink: 0; }

/* Отдельная ссылка «Настройки» — между навигацией и блоком пользователя */
.sidebar-settings {
    margin: 0 10px 4px;
    display: flex;
    align-items: center;
    gap: 11px;
    padding: 10px 13px;
    border-radius: var(--radius-sm);
    color: var(--sidebar-text);
    font-size: 13.5px;
    text-decoration: none;
    transition: background 0.15s, color 0.15s;
}

.sidebar-settings:hover {
    background: var(--sidebar-hover);
    color: white;
    text-decoration: none;
}

.sidebar-settings.active {
    background: var(--sidebar-active);
    color: white;
}

.sidebar-user {
    padding: 14px 16px;
    border-top: 1px solid rgba(255, 255, 255, 0.08);
    display: flex;
    align-items: center;
    gap: 11px;
}

.sidebar-avatar {
    width: 34px; height: 34px;
    border-radius: 50%;
    color: white;
    display: flex; align-items: center; justify-content: center;
    font-size: 13px; font-weight: 600;
    flex-shrink: 0;
}

.sidebar-avatar.role-admin          { background: #ef4444; }
.sidebar-avatar.role-company_owner  { background: #f59e0b; }
.sidebar-avatar.role-client         { background: #14b8a6; }

.sidebar-user-info { flex: 1; min-width: 0; line-height: 1.25; }
.sidebar-user-name {
    color: white; font-size: 13px; font-weight: 500;
    overflow: hidden; text-overflow: ellipsis; white-space: nowrap;
}
.sidebar-user-role { font-size: 11px; color: var(--sidebar-text-muted); }

.sidebar-logout {
    color: var(--sidebar-text-muted);
    font-size: 18px;
    padding: 6px;
    border-radius: var(--radius-sm);
    transition: all 0.15s;
}
.sidebar-logout:hover { color: white; background: var(--sidebar-hover); text-decoration: none; }

/* ============================================================
   Основная область
   ============================================================ */
.main {
    padding: 24px 32px 40px;
    max-width: 100%;
    overflow-x: hidden;
}

.page-header {
    display: flex;
    align-items: flex-end;
    justify-content: space-between;
    margin-bottom: 22px;
    flex-wrap: wrap;
    gap: 12px;
}

.page-eyebrow {
    font-size: 11px;
    color: var(--text-secondary);
    text-transform: uppercase;
    letter-spacing: 0.7px;
    margin-bottom: 4px;
    font-weight: 500;
}

.page-header h1 {
    margin: 0;
    font-size: 22px;
    font-weight: 600;
    color: var(--text-primary);
}

.page-header .counter {
    color: var(--text-secondary);
    font-weight: 400;
    margin-left: 4px;
}

/* ============================================================
   Карточки статистики
   ============================================================ */
.stats-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(160px, 1fr));
    gap: 12px;
    margin-bottom: 20px;
}

.stat-card {
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: var(--radius-md);
    padding: 14px 16px;
}

.stat-label { font-size: 12px; color: var(--text-secondary); margin-bottom: 4px; }
.stat-value { font-size: 22px; font-weight: 600; line-height: 1.2; }

.stat-new      { color: var(--info-text); }
.stat-progress { color: var(--warning-text); }
.stat-resolved { color: var(--success-text); }
.stat-overdue  { color: var(--danger-text); }

/* ============================================================
   Кнопки
   ============================================================ */
.btn {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 9px 16px;
    border-radius: var(--radius-md);
    font-size: 13.5px;
    font-weight: 500;
    cursor: pointer;
    border: 1px solid transparent;
    transition: all 0.15s;
    text-decoration: none;
    line-height: 1.2;
    font-family: inherit;
}

.btn:hover { text-decoration: none; }

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

.btn-secondary {
    background: var(--bg-card);
    color: var(--text-primary);
    border-color: var(--border);
}
.btn-secondary:hover { background: var(--bg-subtle); border-color: var(--border-strong); }

.btn .icon { font-size: 16px; }

/* ============================================================
   Flash-сообщения
   ============================================================ */
.flash-block { margin-bottom: 18px; }

.flash {
    padding: 12px 16px;
    border-radius: var(--radius-md);
    margin-bottom: 8px;
    border: 1px solid;
    font-size: 13.5px;
}

.flash-success { background: var(--success-bg); color: var(--success-text); border-color: #86efac; }
.flash-danger  { background: var(--danger-bg);  color: var(--danger-text);  border-color: #fca5a5; }
.flash-warning { background: var(--warning-bg); color: var(--warning-text); border-color: #fcd34d; }
.flash-info    { background: var(--info-bg);    color: var(--info-text);    border-color: #93c5fd; }

/* ============================================================
   Фильтры и поиск
   ============================================================ */
.filters {
    display: flex;
    gap: 8px;
    margin-bottom: 14px;
    flex-wrap: wrap;
}

.search-box { position: relative; flex: 1; min-width: 240px; }

.search-box .search-icon {
    position: absolute;
    left: 12px; top: 50%;
    transform: translateY(-50%);
    color: var(--text-tertiary);
    font-size: 16px;
    pointer-events: none;
}

.search-box input {
    width: 100%;
    padding: 9px 12px 9px 36px;
    border: 1px solid var(--border);
    border-radius: var(--radius-md);
    font-size: 13.5px;
    background: var(--bg-card);
    font-family: inherit;
    transition: border-color 0.15s, box-shadow 0.15s;
}

.search-box input:focus,
.filters select:focus {
    outline: none;
    border-color: var(--brand);
    box-shadow: 0 0 0 3px rgba(59, 130, 246, 0.12);
}

.filters select {
    padding: 9px 30px 9px 12px;
    border: 1px solid var(--border);
    border-radius: var(--radius-md);
    font-size: 13.5px;
    background: var(--bg-card);
    cursor: pointer;
    min-width: 170px;
    appearance: none;
    background-image: url("data:image/svg+xml;charset=UTF-8,%3csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 24 24' fill='none' stroke='%2364748b' stroke-width='2'%3e%3cpolyline points='6 9 12 15 18 9'/%3e%3c/svg%3e");
    background-repeat: no-repeat;
    background-position: right 10px center;
    font-family: inherit;
}

/* ============================================================
   Таблица
   ============================================================ */
.table-card {
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: var(--radius-md);
    overflow: hidden;
    box-shadow: var(--shadow-sm);
}

.table-wrapper { overflow-x: auto; }

.tickets-table {
    width: 100%;
    border-collapse: collapse;
    font-size: 13px;
    white-space: nowrap;
}

.tickets-table thead { background: var(--bg-subtle); }

.tickets-table th {
    padding: 11px 14px;
    text-align: left;
    font-weight: 600;
    font-size: 11px;
    color: var(--text-secondary);
    text-transform: uppercase;
    letter-spacing: 0.5px;
    border-bottom: 1px solid var(--border);
}

.tickets-table td {
    padding: 12px 14px;
    border-bottom: 1px solid var(--border);
    color: var(--text-primary);
}

.tickets-table tbody tr:last-child td { border-bottom: none; }

.tickets-table tbody tr {
    cursor: pointer;
    transition: background 0.1s;
}

.tickets-table tbody tr:hover { background: var(--bg-hover); }
.tickets-table tbody tr.hidden { display: none; }

.cell-id, .cell-number {
    font-family: ui-monospace, "SF Mono", Menlo, Consolas, monospace;
    font-size: 12.5px;
}

.cell-id { color: var(--text-secondary); }
.cell-number { color: var(--text-primary); font-weight: 500; }

.cell-truncate {
    max-width: 240px;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.cell-muted { color: var(--text-tertiary); }

.no-results {
    padding: 40px 20px;
    text-align: center;
    color: var(--text-secondary);
    display: none;
}

/* ============================================================
   Бейджи: состояния и приоритеты
   ============================================================ */
.state {
    display: inline-block;
    padding: 3px 10px;
    border-radius: 999px;
    font-size: 11.5px;
    font-weight: 500;
    line-height: 1.4;
    white-space: nowrap;
}

.state-Новая    { background: #DBEAFE; color: #1E40AF; }
.state-В_работе { background: #FEF3C7; color: #92400E; }
.state-Ожидание { background: #E5E7EB; color: #374151; }
.state-Решена   { background: #D1FAE5; color: #065F46; }
.state-Закрыта  { background: #F1F5F9; color: #475569; }
.state-Отменена { background: #FEE2E2; color: #991B1B; }

.priority {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    font-size: 12.5px;
    white-space: nowrap;
}

.priority::before {
    content: '';
    width: 7px; height: 7px;
    border-radius: 50%;
    flex-shrink: 0;
}

.priority-Критический::before { background: #DC2626; }
.priority-Высокий::before     { background: #F59E0B; }
.priority-Средний::before     { background: #EAB308; }
.priority-Низкий::before      { background: #9CA3AF; }

/* ============================================================
   Пустое состояние
   ============================================================ */
.empty-state {
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: var(--radius-md);
    padding: 60px 20px;
    text-align: center;
}

.empty-state .empty-icon {
    font-size: 48px;
    color: var(--text-tertiary);
    margin-bottom: 12px;
    display: block;
}

.empty-state p {
    color: var(--text-secondary);
    font-size: 15px;
    margin: 0 0 16px;
}

/* ============================================================
   Формы
   ============================================================ */
.form-card {
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: var(--radius-md);
    padding: 24px 28px;
    box-shadow: var(--shadow-sm);
    max-width: 1100px;
}

.form-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 16px 20px;
}

.form-grid .col-2 { grid-column: span 2; }

.form-field {
    display: flex;
    flex-direction: column;
    gap: 6px;
}

.form-field label {
    font-size: 12.5px;
    font-weight: 500;
    color: var(--text-secondary);
}

.form-field .required { color: #ef4444; }

.form-field input,
.form-field select,
.form-field textarea {
    width: 100%;
    padding: 9px 12px;
    border: 1px solid var(--border);
    border-radius: var(--radius-md);
    font-size: 14px;
    font-family: inherit;
    background: var(--bg-card);
    color: var(--text-primary);
    transition: border-color 0.15s, box-shadow 0.15s;
}

.form-field textarea {
    resize: vertical;
    min-height: 80px;
}

.form-field input:focus,
.form-field select:focus,
.form-field textarea:focus {
    outline: none;
    border-color: var(--brand);
    box-shadow: 0 0 0 3px rgba(59, 130, 246, 0.12);
}

.form-field input[readonly],
.form-field textarea[readonly],
.form-field select[disabled] {
    background: var(--bg-subtle);
    color: var(--text-secondary);
    cursor: not-allowed;
}

/* Подсветка ошибки валидации поля */
.form-field input.has-error,
.form-field textarea.has-error,
.form-field select.has-error {
    border-color: #ef4444;
    box-shadow: 0 0 0 3px rgba(239, 68, 68, 0.12);
}

.form-field .field-error {
    display: flex;
    align-items: center;
    gap: 5px;
    margin-top: 4px;
    color: #b91c1c;
    font-size: 12.5px;
    font-weight: 500;
}

.form-field .field-error i {
    font-size: 14px;
    flex-shrink: 0;
}

.form-field select {
    appearance: none;
    background-image: url("data:image/svg+xml;charset=UTF-8,%3csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 24 24' fill='none' stroke='%2364748b' stroke-width='2'%3e%3cpolyline points='6 9 12 15 18 9'/%3e%3c/svg%3e");
    background-repeat: no-repeat;
    background-position: right 10px center;
    padding-right: 30px;
}

.form-actions {
    margin-top: 24px;
    padding-top: 20px;
    border-top: 1px solid var(--border);
    display: flex;
    gap: 10px;
}

.info-box {
    background: var(--bg-subtle);
    border: 1px solid var(--border);
    border-radius: var(--radius-md);
    padding: 14px 16px;
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 10px 20px;
    font-size: 13px;
}

.info-box .label {
    color: var(--text-secondary);
    font-size: 12px;
    display: block;
    margin-bottom: 2px;
}

.info-box .value {
    color: var(--text-primary);
    font-weight: 500;
}

.readonly-notice {
    margin-top: 18px;
    padding: 12px 16px;
    background: var(--info-bg);
    border: 1px solid #93c5fd;
    border-radius: var(--radius-md);
    color: var(--info-text);
    font-size: 13px;
    display: flex;
    align-items: center;
    gap: 8px;
}

/* ============================================================
   Авторизация
   ============================================================ */
.auth-page {
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 20px;
    background: linear-gradient(135deg, #f1f5f9 0%, #e0e7ff 100%);
}

.auth-card {
    width: 100%;
    max-width: 420px;
    background: var(--bg-card);
    padding: 36px 32px;
    border-radius: var(--radius-lg);
    box-shadow: 0 10px 25px -5px rgba(15, 23, 42, 0.1),
                0 8px 10px -6px rgba(15, 23, 42, 0.04);
}

.auth-brand {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    margin-bottom: 8px;
}

.auth-brand .brand-icon {
    width: 40px; height: 40px;
    border-radius: 10px;
    background: var(--brand);
    color: white;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 20px;
}

.auth-brand .brand-name {
    font-size: 18px;
    font-weight: 600;
    color: var(--text-primary);
}

.auth-card h1 {
    text-align: center;
    font-size: 20px;
    font-weight: 600;
    margin: 0 0 4px;
    color: var(--text-primary);
}

.auth-card .auth-subtitle {
    text-align: center;
    color: var(--text-secondary);
    font-size: 13.5px;
    margin: 0 0 24px;
}

.auth-card .form-field { margin-bottom: 14px; }
.auth-card .btn { width: 100%; justify-content: center; padding: 11px 16px; }

.muted {
    color: var(--text-secondary);
    font-size: 13px;
    text-align: center;
    margin-top: 18px;
}

.hint {
    margin-top: 22px;
    padding: 12px 14px;
    background: var(--bg-subtle);
    border: 1px solid var(--border);
    border-radius: var(--radius-md);
    font-size: 12px;
    color: var(--text-secondary);
    line-height: 1.6;
}

.hint strong { color: var(--text-primary); font-weight: 600; }

.hint code {
    background: var(--bg-card);
    border: 1px solid var(--border);
    padding: 1px 6px;
    border-radius: 4px;
    font-family: ui-monospace, "SF Mono", Menlo, Consolas, monospace;
    font-size: 11.5px;
    color: var(--text-primary);
}

/* ============================================================
   Блок отображения учётных данных
   ============================================================ */
.credentials {
    display: flex;
    flex-direction: column;
    gap: 10px;
    margin-bottom: 8px;
}

.cred-row {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 14px 16px;
    background: var(--bg-subtle);
    border: 1px solid var(--border);
    border-radius: var(--radius-md);
}

.cred-label {
    font-size: 12px;
    color: var(--text-secondary);
    width: 110px;
    flex-shrink: 0;
    font-weight: 500;
}

.cred-value {
    flex: 1;
    font-family: ui-monospace, "SF Mono", Menlo, Consolas, monospace;
    font-size: 20px;
    font-weight: 600;
    letter-spacing: 1.5px;
    color: var(--text-primary);
    user-select: all;
}

.cred-copy {
    flex-shrink: 0;
    padding: 7px 12px;
    font-size: 12.5px;
}

/* Маленькая кнопка-иконка для копирования из таблиц */
.btn-icon-copy {
    background: transparent;
    border: 1px solid var(--border);
    color: var(--text-secondary);
    width: 28px;
    height: 28px;
    border-radius: var(--radius-sm);
    cursor: pointer;
    margin-left: 6px;
    font-size: 13px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    vertical-align: middle;
    transition: all 0.15s;
    padding: 0;
}

.btn-icon-copy:hover {
    background: var(--bg-subtle);
    color: var(--text-primary);
    border-color: var(--border-strong);
}

.btn-icon-copy.copied {
    background: var(--success-bg);
    color: var(--success-text);
    border-color: #86efac;
}

.pwd-mono {
    font-family: ui-monospace, "SF Mono", Menlo, Consolas, monospace;
    font-weight: 600;
    letter-spacing: 1px;
    background: var(--warning-bg);
    color: var(--warning-text);
    padding: 2px 8px;
    border-radius: 4px;
    font-size: 13px;
}

/* ============================================================
   Вложения к заявкам
   ============================================================ */
.attachments-list {
    display: flex;
    flex-direction: column;
    gap: 8px;
    margin-bottom: 8px;
}

.attachment-row {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 10px 12px;
    background: var(--bg-subtle);
    border: 1px solid var(--border);
    border-radius: var(--radius-md);
    transition: background 0.15s;
}

.attachment-row:hover {
    background: var(--bg-hover);
}

.attachment-icon {
    width: 36px;
    height: 36px;
    border-radius: var(--radius-sm);
    background: var(--bg-card);
    border: 1px solid var(--border);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 18px;
    color: var(--brand);
    flex-shrink: 0;
}

.attachment-info {
    flex: 1;
    min-width: 0;
}

.attachment-name {
    color: var(--text-primary);
    font-weight: 500;
    text-decoration: none;
    word-break: break-all;
}

.attachment-name:hover {
    color: var(--brand);
    text-decoration: underline;
}

.attachment-meta {
    font-size: 12px;
    color: var(--text-secondary);
    margin-top: 2px;
}

.attachment-actions {
    display: flex;
    gap: 6px;
    flex-shrink: 0;
}

.attachment-actions .btn {
    padding: 7px 10px;
}

/* Кнопка-иконка для опасного действия (удалить вложение) */
.btn-danger-icon {
    background: var(--bg-card);
    border: 1px solid var(--border);
    color: #b91c1c;
    padding: 7px 10px;
    border-radius: var(--radius-md);
    cursor: pointer;
    font-size: 14px;
    transition: all 0.15s;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    line-height: 1;
}

.btn-danger-icon:hover {
    background: #fee2e2;
    border-color: #fca5a5;
}

.btn-danger-icon i {
    font-size: 16px;
}

/* Двухколоночная сетка для страницы настроек */
.settings-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 20px;
    max-width: 1100px;
}

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

/* Раскрывающиеся секции настроек */
.settings-buttons {
    display: flex;
    gap: 10px;
    flex-wrap: wrap;
}

.settings-buttons .btn {
    flex: 1;
    min-width: 180px;
    justify-content: center;
    padding: 12px 18px;
}

.settings-section {
    margin-top: 24px;
    padding-top: 24px;
    border-top: 1px solid var(--border);
}

.settings-section[hidden] {
    display: none;
}

.settings-section-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 6px;
}

.settings-section-header h2 {
    margin: 0;
    font-size: 17px;
    font-weight: 600;
    display: inline-flex;
    align-items: center;
    gap: 8px;
}

.btn-close-section {
    background: transparent;
    border: 1px solid var(--border);
    color: var(--text-secondary);
    width: 32px;
    height: 32px;
    border-radius: var(--radius-sm);
    cursor: pointer;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    transition: all 0.15s;
}

.btn-close-section:hover {
    background: var(--bg-subtle);
    color: var(--text-primary);
}

/* Форма загрузки */
.upload-form {
    display: flex;
    align-items: center;
    flex-wrap: wrap;
    gap: 0;
    padding: 16px;
    border: 2px dashed var(--border-strong);
    border-radius: var(--radius-md);
    background: var(--bg-subtle);
}

.upload-label {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 9px 16px;
    background: var(--brand);
    color: white;
    border-radius: var(--radius-md);
    cursor: pointer;
    font-size: 13.5px;
    font-weight: 500;
    transition: background 0.15s;
}

.upload-label:hover {
    background: var(--brand-hover);
}

/* ============================================================
   Адаптивность
   ============================================================ */
@media (max-width: 900px) {
    .app-layout { grid-template-columns: 1fr; }
    .sidebar { position: relative; height: auto; }
    .main { padding: 18px; }
    .form-grid { grid-template-columns: 1fr; }
    .form-grid .col-2 { grid-column: span 1; }
    .info-box { grid-template-columns: 1fr; }
}
