@import url('/base.css');

[hidden] { display: none !important; }
input, button, select { font: inherit; }
input:focus-visible, summary:focus-visible, a:focus-visible { outline: 3px solid #b9d5fc; outline-offset: 3px; }
.dashboard { max-width: 1120px; }
.loading-message { padding: 80px 20px; text-align: center; color: var(--muted); }
.login-wrap { display: grid; min-height: calc(100dvh - 100px); place-items: center; }
.login-card { width: min(420px, 100%); padding: 32px; border: 1px solid var(--line); border-radius: 20px; background: white; box-shadow: var(--shadow); }
.brand-cross { width: 44px; height: 44px; margin-bottom: 24px; display: grid; place-items: center; color: white; font-size: 30px; font-weight: 800; background: #18bfbc; border-radius: 13px; }
.login-card h1 { margin: 0 0 8px; font-size: 27px; letter-spacing: -.035em; }
.login-card > p { color: var(--muted); line-height: 1.5; font-size: 14px; }
.login-card form { display: grid; gap: 16px; margin-top: 26px; }
.login-card label { display: grid; gap: 8px; font-size: 13px; font-weight: 650; }
.login-card input { width: 100%; height: 46px; padding: 12px; border: 1px solid var(--line); border-radius: 10px; color: var(--ink); background: white; }
.primary-button, .quiet-button { min-height: 42px; padding: 10px 16px; border: 1px solid var(--line); border-radius: 10px; font-size: 12px; font-weight: 750; cursor: pointer; }
.primary-button { color: white; background: var(--blue); border-color: var(--blue); }
.quiet-button { color: var(--ink); background: white; }
button:disabled { opacity: .6; cursor: wait; }
.form-error { color: #b33737; font-size: 13px; line-height: 1.5; margin: 0; }
.cabinet-toolbar { display: flex; justify-content: space-between; align-items: center; gap: 12px; margin-bottom: 26px; }
.cabinet-brand { font-size: 13px; font-weight: 800; }
.toolbar-actions { display: flex; align-items: center; gap: 8px; }
.toolbar-actions .quiet-button { min-height: 38px; }
.intro { align-items: center; }
.intro-profile { display: flex; align-items: center; gap: 14px; min-width: 0; }
.intro-profile .avatar { width: 56px; height: 56px; font-size: 16px; }
.intro p { line-height: 1.5; font-size: 13px; }
.cabinet-filter { display: flex; flex-wrap: wrap; gap: 10px; margin: 22px 0 14px; align-items: end; }
.cabinet-filter .period-switch { min-width: 250px; grid-template-columns: repeat(3, 1fr); }
.simple-field { display: grid; gap: 5px; font-size: 10px; color: var(--muted); }
.simple-field select, .simple-field input { min-height: 46px; max-width: 100%; padding: 10px 12px; border: 1px solid var(--line); border-radius: 10px; color: var(--ink); background: white; }
.date-range { display: flex; flex-wrap: wrap; gap: 8px; width: 100%; align-items: end; }
.date-range .simple-field { flex: 1; min-width: 120px; max-width: 200px; }
.date-range input { min-width: 0; width: 100%; }
.period-caption { color: var(--muted); font-size: 11px; margin: 8px 0 16px; }
.kpi-grid small { line-height: 1.5; }
.trend-positive { color: #087557; }
.trend-negative { color: #b53f3f; }
.support-note { font-size: 11px; line-height: 1.6; color: var(--muted); margin: 14px 0; }
.main-section { margin-top: 16px; padding: 23px; background: white; border: 1px solid var(--line); border-radius: var(--radius); }
.main-section h2 { font-size: 21px; margin: 0; letter-spacing: -.025em; }
.main-section .section-heading { margin-bottom: 18px; align-items: start; }
.report-switch { width: 200px; flex: 0 0 auto; }
.recommendation-focus { display: grid; gap: 10px; padding: 18px; margin-top: 14px; border: 1px solid #cee0fb; border-radius: 12px; background: var(--blue-soft); }
.recommendation-focus h3 { margin: 0; color: var(--blue); font-size: 13px; }
.recommendation-focus p { margin: 0; font-size: 13px; line-height: 1.6; }
.recommendation-focus small { color: var(--muted); line-height: 1.5; }
.manager-report-summary { font-size: 13px; line-height: 1.65; }
.feedback-box li strong { font-size: 12px; }
.feedback-box li p { font-size: 12px; }
.feedback-box li span { font-size: 11px; }
.report-more { margin-top: 14px; }
.report-more > summary { cursor: pointer; font-size: 12px; color: var(--blue); font-weight: 700; padding: 8px 0; }
.team-table-wrap { overflow-x: auto; }
.team-table { width: 100%; border-collapse: collapse; }
.team-table th { padding: 9px 10px; color: var(--muted); text-align: left; font-weight: 600; font-size: 11px; white-space: nowrap; }
.team-table td { padding: 15px 10px; border-top: 1px solid var(--line); font-size: 14px; }
.team-table .current { background: #f3f8ff; }
.team-table .manager-identity strong { font-size: 13px; }
.team-table .manager-identity small { font-size: 11px; }
.team-table .avatar { width: 34px; height: 34px; font-size: 10px; }
.team-name-button { color: var(--blue); border: 0; padding: 0; background: transparent; cursor: pointer; text-align: left; font-weight: 750; }
.recognitions { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 14px; }
.recognition { padding: 9px 12px; border-radius: 9px; color: #875f06; background: var(--amber-soft); font-size: 12px; line-height: 1.5; }
.small-sample { display: block; margin-top: 5px; color: var(--muted); font-size: 10px; }
.trend-chart { height: 190px; margin-top: 12px; }
.trend-chart svg { width: 100%; height: 100%; }
.weekly-labels { display: grid; grid-template-columns: repeat(6, 1fr); gap: 8px; margin-top: 6px; }
.weekly-labels div { color: var(--muted); font-size: 10px; text-align: center; line-height: 1.6; }
.weekly-labels strong { display: block; color: var(--ink); font-size: 12px; }
.call-filter-row { display: flex; flex-wrap: wrap; align-items: center; gap: 10px; margin-bottom: 14px; }
.call-filter-row .simple-field { min-width: 180px; }
.call-filter-count { color: var(--muted); font-size: 11px; margin-left: auto; }
.recent-call-list { gap: 9px; }
.recent-call-row { grid-template-columns: 125px 120px minmax(0, 1fr) auto 18px; padding: 15px; }
.recent-call-date strong, .recent-call-client strong { font-size: 13px; }
.recent-call-date small, .recent-call-client small { font-size: 11px; }
.recent-call-direction { font-size: 12px; }
.call-status { font-size: 11px; }
.call-accordion-panel { display: grid; grid-template-rows: 0fr; transition: grid-template-rows 250ms ease; }
.call-accordion.is-expanded .call-accordion-panel { grid-template-rows: 1fr; }
.call-accordion-content { overflow: hidden; min-height: 0; }
.call-accordion-content > section { margin: 0 15px 15px; }
.call-recommendation { padding: 12px; background: #eaf2ff; border-radius: 10px; font-size: 13px; line-height: 1.6; }
.call-recommendation strong { color: var(--blue); }
.call-transcript { font-size: 12px; color: var(--muted); line-height: 1.8; white-space: pre-wrap; }
.call-transcript summary { cursor: pointer; font-weight: 750; }
.legacy-label { color: var(--muted); font-size: 11px; line-height: 1.5; }
.load-more { display: block; margin: 18px auto 0; }
.data-error { display: flex; align-items: center; justify-content: space-between; gap: 12px; margin: 0 0 16px; padding: 12px; border: 1px solid #eac1c1; border-radius: 10px; background: #fff5f5; color: #923737; font-size: 12px; }
.telegram-status { font-size: 12px; color: var(--muted); }
.telegram-link { color: var(--blue); text-decoration: none; font-weight: 700; }
.footer-note { padding: 16px 0 0; color: var(--muted); font-size: 11px; line-height: 1.6; }
@media (max-width: 700px) {
  .dashboard { width: calc(100% - 24px); padding-top: 20px; }
  .intro { align-items: start; gap: 12px; flex-direction: column; }
  .intro h1 { font-size: 28px; }
  .toolbar-actions { gap: 5px; }
  .toolbar-actions .quiet-button { font-size: 11px; padding: 8px 10px; }
  .cabinet-filter { gap: 8px; }
  .cabinet-filter .period-switch { flex: 1 1 100%; }
  .cabinet-filter > .simple-field { flex: 1; min-width: 0; }
  .kpi-grid { grid-template-columns: repeat(2, 1fr); gap: 8px; }
  .kpi-card { padding: 15px; }
  .kpi-card strong { font-size: 28px; }
  .main-section { padding: 16px; }
  .main-section .section-heading { flex-direction: column; gap: 12px; }
  .report-switch { width: 100%; margin-bottom: 0; }
  .feedback-grid { grid-template-columns: 1fr; }
  .team-table th, .team-table td { padding: 12px 5px; }
  .team-table th { font-size: 9px; }
  .team-table td { font-size: 12px; }
  .team-table .manager-identity { gap: 7px; }
  .team-table .avatar { display: none; }
  .team-table .manager-identity strong { font-size: 12px; }
  .recent-call-row { grid-template-columns: minmax(0, 1fr) auto 18px; gap: 10px 8px; padding: 14px; }
  .recent-call-date { grid-column: 1; grid-row: 1; }
  .recent-call-direction { grid-column: 2; grid-row: 1; font-size: 10px; }
  .recent-call-direction b { width: 20px; height: 20px; margin-right: 3px; }
  .recent-call-client { grid-column: 1 / 3; grid-row: 2; }
  .call-status { grid-column: 1 / 3; grid-row: 3; justify-self: start; font-size: 10px; }
  .recent-call-chevron { grid-column: 3; grid-row: 1 / 4; }
  .recent-call-client strong, .recent-call-client small { white-space: normal; overflow-wrap: anywhere; }
  .call-technical .call-party { grid-column: 1 / -1; }
  .call-technical dd { overflow-wrap: anywhere; white-space: normal; }
  .analysis-columns { grid-template-columns: 1fr; }
  .call-accordion-content > section { margin: 0 10px 10px; padding: 14px; }
  .weekly-labels { gap: 3px; }
  .weekly-labels div { font-size: 9px; }
  .login-card { padding: 24px; }
}
@media (prefers-reduced-motion: reduce) { *, *::before, *::after { transition: none !important; } }
