.history-page {
  --text-0: #f7fbff;
  --text-1: rgba(228, 236, 248, 0.92);
  --text-2: rgba(184, 198, 222, 0.82);
  --line: rgba(140, 173, 222, 0.16);
  --line-strong: rgba(255, 255, 255, 0.12);
  --cyan: #7dd3fc;
  --blue: #3b82f6;
  --amber: #fbbf24;
  --orange: #fb923c;
  --green: #4ade80;
  --red: #f87171;
  --violet: #a78bfa;
  position: relative;
  min-height: calc(100vh - var(--navH));
  overflow: clip;
  color: var(--text-0);
}

.history-page__bg,
.history-page__veil,
.history-page__grid {
  position: absolute;
  inset: 0;
  pointer-events: none;
}

.history-page__bg {
  background:
    radial-gradient(900px 480px at 8% 0%, rgba(56, 189, 248, 0.22), transparent 60%),
    radial-gradient(780px 420px at 92% 8%, rgba(251, 191, 36, 0.14), transparent 60%),
    url('/static/img/hero-bg-optimized.jpg?v=20260311_logo_bg1') center / cover no-repeat;
  opacity: 0.2;
  transform: scale(1.03);
}

.history-page__veil {
  background:
    linear-gradient(180deg, rgba(5, 9, 17, 0.6), rgba(5, 9, 17, 0.96)),
    radial-gradient(720px 360px at 50% 0%, rgba(255, 255, 255, 0.04), transparent 74%);
}

.history-page__grid {
  background-image:
    linear-gradient(rgba(125, 211, 252, 0.045) 1px, transparent 1px),
    linear-gradient(90deg, rgba(125, 211, 252, 0.045) 1px, transparent 1px);
  background-size: 92px 92px;
  mask-image: linear-gradient(180deg, rgba(0, 0, 0, 0.58), transparent 78%);
}

.history-shell {
  position: relative;
  z-index: 1;
  width: min(1280px, calc(100% - 28px));
  margin: 0 auto;
  padding: 18px 0 38px;
}

.history-hero,
.stats-grid,
.visual-grid,
.history-table-panel {
  position: relative;
}

.stats-grid,
.visual-grid,
.history-table-panel {
  margin-top: 18px;
}

.history-hero {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(360px, 0.92fr);
  gap: 18px;
  align-items: start;
}

.panel {
  position: relative;
  overflow: hidden;
  border: 1px solid var(--line);
  border-radius: 28px;
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.03), rgba(255, 255, 255, 0.012)),
    linear-gradient(180deg, rgba(8, 13, 24, 0.96), rgba(6, 10, 19, 0.88));
  box-shadow: 0 26px 62px rgba(0, 0, 0, 0.28);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
}

.panel::before {
  content: "";
  position: absolute;
  inset: 0 0 auto;
  height: 1px;
  background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.28), transparent);
  opacity: 0.72;
  pointer-events: none;
}

.history-intro,
.history-controls,
.chart-card,
.insight-panel,
.history-table-panel {
  padding: 20px;
}

.history-intro::after {
  content: "";
  position: absolute;
  inset: auto -80px -90px auto;
  width: 280px;
  height: 280px;
  border-radius: 999px;
  background: radial-gradient(circle, rgba(125, 211, 252, 0.16), transparent 70%);
  pointer-events: none;
}

.history-intro > *,
.history-controls > *,
.chart-card > *,
.insight-panel > *,
.history-table-panel > * {
  position: relative;
  z-index: 1;
}

.eyebrow {
  display: inline-flex;
  align-items: center;
  min-height: 30px;
  padding: 0 12px;
  border-radius: 999px;
  border: 1px solid rgba(125, 211, 252, 0.2);
  background: rgba(125, 211, 252, 0.08);
  color: var(--text-0);
  font-size: 11px;
  font-weight: 800;
  letter-spacing: 0.16em;
  text-transform: uppercase;
}

.hero-kicker {
  margin: 12px 0 0;
  color: var(--cyan);
  font-size: 11px;
  font-weight: 800;
  letter-spacing: 0.18em;
  text-transform: uppercase;
}

.hero-title {
  margin: 16px 0 12px;
  max-width: 15ch;
  font-size: clamp(28px, 3.2vw, 46px);
  line-height: 1.02;
  letter-spacing: -0.05em;
  text-wrap: balance;
}

.hero-text,
.panel-text,
.stat-card__meta,
.card-note,
.month-chip__meta,
.insight-card__meta,
.table-empty,
.monthly-empty,
.insight-empty {
  color: var(--text-1);
  font-size: 13px;
  line-height: 1.58;
}

.hero-text,
.panel-text {
  margin: 0;
}

.hero-pills,
.stats-grid,
.monthly-breakdown,
.insight-list {
  display: grid;
  gap: 12px;
}

.hero-pills {
  grid-template-columns: repeat(3, minmax(0, 1fr));
  margin-top: 18px;
}

.hero-pill,
.stat-card,
.month-chip,
.insight-card {
  position: relative;
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 20px;
  background: rgba(255, 255, 255, 0.045);
}

.hero-pill {
  display: grid;
  gap: 6px;
  padding: 16px;
}

.hero-pill strong,
.stat-card__value,
.month-chip__value,
.insight-card__value {
  font-size: 18px;
  font-weight: 900;
  line-height: 1.12;
  letter-spacing: -0.03em;
}

.hero-pill span,
.stat-card__label,
.month-chip__label,
.insight-card__title,
.quick-picks__label,
.toolbar-field span,
.field span {
  color: var(--text-2);
  font-size: 11px;
  font-weight: 800;
  letter-spacing: 0.14em;
  text-transform: uppercase;
}

.panel-head,
.card-head,
.card-head--table {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 14px;
}

.panel-title,
.section-title {
  margin: 12px 0 0;
  font-size: clamp(20px, 1.8vw, 28px);
  line-height: 1.08;
  letter-spacing: -0.034em;
}

.panel-badge {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 74px;
  min-height: 32px;
  padding: 0 12px;
  border-radius: 999px;
  border: 1px solid rgba(74, 222, 128, 0.28);
  background: rgba(74, 222, 128, 0.12);
  color: #e3ffeb;
  font-size: 10px;
  font-weight: 900;
  letter-spacing: 0.16em;
}

.panel-text {
  margin-top: 14px;
}

.control-grid {
  display: grid;
  grid-template-columns: minmax(0, 1.1fr) repeat(2, minmax(0, 0.7fr)) auto;
  gap: 12px;
  align-items: end;
  margin-top: 18px;
}

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

.field--wide {
  min-width: 0;
}

.field-search {
  position: relative;
}

.search-helper {
  margin-top: 8px;
  color: var(--text-2);
  font-size: 12px;
  line-height: 1.5;
}

.search-helper.is-ok {
  color: #d9ffe8;
}

.search-helper.is-warning {
  color: #fff1c6;
}

.search-helper.is-error {
  color: #ffd6d6;
}

.search-suggestions {
  position: absolute;
  inset: calc(100% - 2px) 0 auto;
  z-index: 30;
  display: grid;
  gap: 6px;
  padding: 10px;
  border: 1px solid rgba(125, 211, 252, 0.18);
  border-radius: 18px;
  background: rgba(6, 10, 19, 0.98);
  box-shadow: 0 22px 48px rgba(0, 0, 0, 0.32);
}

.search-suggestions.is-hidden {
  display: none;
}

.search-suggestion {
  display: grid;
  gap: 4px;
  width: 100%;
  padding: 12px 14px;
  border: 1px solid transparent;
  border-radius: 14px;
  background: rgba(255, 255, 255, 0.04);
  color: var(--text-0);
  text-align: left;
  cursor: pointer;
  transition: background 0.16s ease, border-color 0.16s ease, transform 0.16s ease;
}

.search-suggestion:hover,
.search-suggestion.is-active {
  border-color: rgba(125, 211, 252, 0.34);
  background: rgba(125, 211, 252, 0.12);
  transform: translateY(-1px);
}

.search-suggestion__title {
  font-size: 14px;
  font-weight: 800;
  line-height: 1.24;
}

.search-suggestion__meta {
  color: var(--text-2);
  font-size: 12px;
  line-height: 1.4;
}

.field input,
.toolbar-field input,
.toolbar-field select {
  width: 100%;
  min-height: 44px;
  padding: 0 14px;
  border-radius: 14px;
  border: 1px solid rgba(255, 255, 255, 0.1);
  background: rgba(255, 255, 255, 0.05);
  color: var(--text-0);
  font-size: 13px;
}

.field input:focus,
.toolbar-field input:focus,
.toolbar-field select:focus {
  outline: none;
  border-color: rgba(125, 211, 252, 0.42);
  box-shadow: 0 0 0 3px rgba(56, 189, 248, 0.14);
}

.field input::placeholder,
.toolbar-field input::placeholder {
  color: rgba(186, 199, 221, 0.7);
}

.actions {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  justify-content: flex-end;
}

.btn,
.btn-primary,
.quick-chip {
  min-height: 44px;
  padding: 0 16px;
  border-radius: 14px;
  border: 1px solid rgba(255, 255, 255, 0.12);
  color: var(--text-0);
  font-size: 13px;
  font-weight: 800;
  cursor: pointer;
  transition: transform 0.16s ease, border-color 0.16s ease, background 0.16s ease, box-shadow 0.16s ease, opacity 0.16s ease;
}

.btn,
.quick-chip {
  background: rgba(255, 255, 255, 0.05);
}

.btn-primary {
  background: linear-gradient(135deg, rgba(8, 145, 178, 0.96), rgba(37, 99, 235, 0.92));
  border-color: rgba(125, 211, 252, 0.32);
  box-shadow: 0 14px 28px rgba(37, 99, 235, 0.22);
}

.btn:hover,
.btn-primary:hover,
.quick-chip:hover:not(:disabled) {
  transform: translateY(-1px);
}

.quick-picks {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 16px;
}

.quick-chip {
  min-height: 38px;
  padding: 0 13px;
  font-size: 13px;
}

.quick-chip.is-active {
  border-color: rgba(125, 211, 252, 0.36);
  background: rgba(125, 211, 252, 0.12);
}

.quick-chip:disabled,
.btn:disabled,
.btn-primary:disabled {
  opacity: 0.7;
  cursor: wait;
}

.status-row {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 10px;
  margin-top: 16px;
}

.status-badge {
  display: inline-flex;
  align-items: center;
  min-height: 34px;
  padding: 0 12px;
  border-radius: 999px;
  border: 1px solid rgba(125, 211, 252, 0.35);
  background: rgba(125, 211, 252, 0.12);
  color: var(--text-0);
  font-size: 11px;
  font-weight: 800;
}

.status-badge.is-error {
  border-color: rgba(248, 113, 113, 0.36);
  background: rgba(248, 113, 113, 0.14);
  color: #ffe1e1;
}

.status-badge.is-loading {
  border-color: rgba(251, 191, 36, 0.34);
  background: rgba(251, 191, 36, 0.12);
  color: #fff2ca;
}

.status-badge.is-warning {
  border-color: rgba(251, 191, 36, 0.34);
  background: rgba(251, 191, 36, 0.12);
  color: #fff2ca;
}

.meta {
  color: var(--text-2);
  font-size: 13px;
  line-height: 1.55;
}

.history-empty-state {
  display: grid;
  gap: 12px;
  margin-top: 18px;
  padding: 20px;
}

.history-empty-state__title {
  margin: 0;
  max-width: 24ch;
  font-size: clamp(22px, 2.1vw, 32px);
  line-height: 1.08;
  letter-spacing: -0.03em;
}

.history-empty-state__text {
  margin: 0;
  max-width: 72ch;
  color: var(--text-1);
  font-size: 14px;
  line-height: 1.6;
}

.history-empty-state__tips {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}

.history-empty-state__tip {
  display: inline-flex;
  align-items: center;
  min-height: 38px;
  padding: 0 14px;
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.045);
  color: var(--text-1);
  font-size: 12px;
  font-weight: 700;
}

.history-results.is-hidden,
.history-empty-state.is-hidden {
  display: none;
}

.stats-grid {
  grid-template-columns: repeat(6, minmax(0, 1fr));
}

.stat-card {
  display: grid;
  gap: 10px;
  padding: 16px;
}

.stat-card__value {
  font-size: 24px;
}

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

.chart-card,
.insight-panel,
.history-table-panel {
  border-radius: 28px;
}

.chart-card .section-title,
.insight-panel .section-title,
.history-table-panel .section-title {
  font-size: clamp(22px, 1.8vw, 28px);
}

.card-note {
  margin-top: 10px;
  font-size: 11px;
}

.chart-box {
  position: relative;
  height: 320px;
  margin-top: 16px;
}

.chart-box--compact {
  height: 280px;
}

.chart-box canvas {
  width: 100% !important;
  height: 100% !important;
  display: block;
}

.monthly-breakdown {
  grid-template-columns: repeat(auto-fit, minmax(140px, 1fr));
  margin-top: 16px;
}

.month-chip {
  display: grid;
  gap: 6px;
  padding: 14px;
}

.month-chip__value {
  font-size: 18px;
}

.month-chip__meta {
  font-size: 11px;
  line-height: 1.5;
}

.monthly-empty,
.insight-empty,
.table-empty {
  padding: 14px;
  border-radius: 18px;
  border: 1px dashed rgba(255, 255, 255, 0.12);
  background: rgba(255, 255, 255, 0.03);
}

.insight-list {
  grid-template-columns: repeat(2, minmax(0, 1fr));
  margin-top: 16px;
}

.insight-card {
  display: grid;
  gap: 8px;
  min-height: 140px;
  padding: 16px;
}

.insight-card--soft {
  background: rgba(255, 255, 255, 0.035);
}

.insight-card--empty {
  border-style: dashed;
}

.insight-card__title {
  display: block;
}

.insight-card__value {
  font-size: 20px;
}

.insight-card__meta {
  font-size: 11px;
  line-height: 1.55;
}

.insight-card__icon {
  width: 34px;
  height: 34px;
  object-fit: contain;
  margin-top: auto;
}

.card-head--table {
  gap: 18px;
}

.table-toolbar {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}

.toolbar-field {
  display: flex;
  flex-direction: column;
  gap: 6px;
  min-width: 180px;
}

.toolbar-field--grow {
  min-width: 240px;
  flex: 1 1 280px;
}

.history-table {
  margin-top: 16px;
  overflow: auto;
}

.history-table table {
  width: 100%;
  border-collapse: collapse;
  min-width: 980px;
}

.history-table th,
.history-table td {
  padding: 12px 10px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.08);
  text-align: left;
  vertical-align: top;
}

.history-table th {
  color: var(--text-2);
  font-size: 11px;
  font-weight: 800;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.history-table tbody tr:hover {
  background: rgba(255, 255, 255, 0.03);
}

.table-condition {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  min-width: 0;
}

.table-condition__icon {
  width: 24px;
  height: 24px;
  object-fit: contain;
}

@media (max-width: 1180px) {
  .history-hero,
  .visual-grid,
  .stats-grid {
    grid-template-columns: 1fr;
  }

  .hero-title {
    max-width: none;
  }

  .hero-pills,
  .insight-list {
    grid-template-columns: 1fr;
  }

  .control-grid,
  .panel-head,
  .card-head,
  .card-head--table {
    grid-template-columns: 1fr;
    flex-direction: column;
  }

  .table-toolbar {
    width: 100%;
  }
}

@media (max-width: 920px) {
  .history-shell {
    width: min(1280px, calc(100% - 20px));
    padding-top: 14px;
  }

  .history-intro,
  .history-controls,
  .chart-card,
  .insight-panel,
  .history-table-panel,
  .panel,
  .stat-card {
    padding: 18px;
    border-radius: 22px;
  }

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

  .control-grid {
    grid-template-columns: 1fr 1fr;
  }

  .actions {
    justify-content: flex-start;
  }

  .history-table table {
    min-width: 820px;
  }
}

@media (max-width: 640px) {
  .history-shell {
    width: calc(100% - 16px);
  }

  .hero-title {
    font-size: clamp(26px, 8vw, 34px);
  }

  .history-empty-state__title {
    max-width: none;
  }

  .history-empty-state__tips {
    flex-direction: column;
  }

  .search-suggestions {
    inset: calc(100% + 6px) 0 auto;
  }

  .stats-grid,
  .hero-pills,
  .monthly-breakdown,
  .insight-list,
  .control-grid {
    grid-template-columns: 1fr;
  }

  .actions,
  .table-toolbar,
  .quick-picks {
    align-items: stretch;
  }

  .btn,
  .btn-primary,
  .quick-chip {
    width: 100%;
  }

  .toolbar-field,
  .toolbar-field--grow {
    min-width: 0;
  }

  .history-table {
    overflow: visible;
  }

  .history-table table,
  .history-table thead,
  .history-table tbody,
  .history-table tr,
  .history-table th,
  .history-table td {
    display: block;
  }

  .history-table thead {
    display: none;
  }

  .history-table table {
    min-width: 0;
  }

  .history-table tbody {
    display: grid;
    gap: 12px;
  }

  .history-table tr {
    padding: 14px;
    border: 1px solid rgba(255, 255, 255, 0.08);
    border-radius: 18px;
    background: rgba(255, 255, 255, 0.04);
  }

  .history-table td {
    padding: 0;
    border-bottom: none;
  }

  .history-table td + td {
    margin-top: 10px;
  }

  .history-table td::before {
    content: attr(data-label);
    display: block;
    margin-bottom: 4px;
    color: var(--text-2);
    font-size: 10px;
    font-weight: 800;
    letter-spacing: 0.12em;
    text-transform: uppercase;
  }
}

@media (prefers-reduced-motion: no-preference) {
  .panel,
  .stat-card,
  .month-chip,
  .insight-card {
    animation: historyReveal 0.68s cubic-bezier(0.22, 1, 0.36, 1) both;
  }

  .history-controls { animation-delay: 0.05s; }
  .stat-card:nth-child(1) { animation-delay: 0.08s; }
  .stat-card:nth-child(2) { animation-delay: 0.1s; }
  .stat-card:nth-child(3) { animation-delay: 0.12s; }
  .stat-card:nth-child(4) { animation-delay: 0.14s; }
  .stat-card:nth-child(5) { animation-delay: 0.16s; }
  .stat-card:nth-child(6) { animation-delay: 0.18s; }
}

@keyframes historyReveal {
  from {
    opacity: 0;
    transform: translateY(16px);
  }

  to {
    opacity: 1;
    transform: translateY(0);
  }
}


/* v4: uproszczony układ góry strony, bez lewej kolumny */
.history-hero--single {
  grid-template-columns: 1fr;
}

.history-controls--search {
  padding: 24px;
}

.history-search-head {
  display: grid;
  gap: 12px;
  max-width: 860px;
}

.history-search-title {
  margin: 0;
  font-size: clamp(34px, 3.6vw, 56px);
  line-height: 1.04;
  letter-spacing: -0.05em;
  text-wrap: balance;
}

.history-search-text {
  margin: 0;
  max-width: 74ch;
  color: var(--text-1);
  font-size: 15px;
  line-height: 1.58;
}

.history-search-box {
  margin-top: 18px;
  padding: 18px;
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 24px;
  background: linear-gradient(180deg, rgba(255, 255, 255, 0.06), rgba(255, 255, 255, 0.03));
  box-shadow: inset 0 10px 26px rgba(0, 0, 0, 0.16);
}

.history-search__label {
  display: block;
  margin: 0 0 10px;
  color: var(--text-2);
  font-size: 12px;
  font-weight: 800;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.history-search__inputWrap {
  position: relative;
}

.history-search__input {
  width: 100%;
  min-height: 58px;
  padding: 0 54px 0 16px;
  border-radius: 18px;
  border: 1px solid rgba(255, 255, 255, 0.16);
  background: linear-gradient(180deg, rgba(0, 0, 0, 0.18), rgba(0, 0, 0, 0.28));
  color: var(--text-0);
  font-size: 17px;
  transition: border-color 0.16s ease, box-shadow 0.16s ease, background 0.16s ease;
}

.history-search__input::placeholder {
  color: rgba(186, 199, 221, 0.62);
}

.history-search__input:focus {
  outline: none;
  border-color: rgba(125, 211, 252, 0.4);
  box-shadow: 0 0 0 3px rgba(56, 189, 248, 0.14);
}

.history-search__clear {
  position: absolute;
  top: 50%;
  right: 10px;
  transform: translateY(-50%);
  width: 34px;
  height: 34px;
  border-radius: 999px;
  border: 1px solid rgba(255, 255, 255, 0.14);
  background: rgba(255, 255, 255, 0.08);
  color: rgba(255, 255, 255, 0.92);
  font-size: 20px;
  line-height: 1;
  cursor: pointer;
  transition: background 0.16s ease, border-color 0.16s ease, transform 0.16s ease;
}

.history-search__clear:hover {
  background: rgba(255, 255, 255, 0.12);
  border-color: rgba(255, 255, 255, 0.22);
}

.history-search__guide {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  align-items: center;
  margin-top: 12px;
  color: rgba(255, 255, 255, 0.72);
  font-size: 13px;
}

.history-search__guideItem {
  padding: 6px 10px;
  border: 1px solid rgba(255, 255, 255, 0.12);
  border-radius: 999px;
  background: rgba(0, 0, 0, 0.16);
}

.history-search__guideDot {
  color: rgba(255, 255, 255, 0.34);
}

.search-helper {
  margin-top: 10px;
}

.search-suggestions {
  position: static;
  inset: auto;
  margin-top: 10px;
  padding: 8px;
  border: 1px solid rgba(255, 255, 255, 0.14);
  border-radius: 16px;
  background: rgba(0, 0, 0, 0.24);
  box-shadow: 0 16px 32px rgba(0, 0, 0, 0.18);
}

.search-suggestion {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  width: 100%;
  padding: 12px;
  border: 1px solid transparent;
  border-radius: 14px;
  background: transparent;
}

.search-suggestion__main {
  display: flex;
  flex-direction: column;
  gap: 4px;
  min-width: 0;
}

.search-suggestion__title,
.search-suggestion__meta {
  text-align: left;
}

.search-suggestion__tag {
  flex-shrink: 0;
  padding: 4px 8px;
  border: 1px solid rgba(255, 255, 255, 0.14);
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.05);
  color: rgba(255, 255, 255, 0.84);
  font-size: 12px;
  font-weight: 700;
}

.control-grid--history {
  grid-template-columns: repeat(2, minmax(0, 0.72fr)) auto;
  margin-top: 18px;
}

.control-grid--history .actions {
  align-self: end;
}

.history-empty-state {
  display: flex;
  align-items: center;
  gap: 14px;
}

.history-empty-state__icon {
  flex: 0 0 auto;
  width: 52px;
  height: 52px;
  display: grid;
  place-items: center;
  border-radius: 16px;
  background: rgba(255, 255, 255, 0.05);
  font-size: 26px;
}

.history-empty-state__body {
  display: grid;
  gap: 6px;
}

.history-empty-state__title {
  max-width: none;
  font-size: clamp(22px, 2vw, 30px);
}

.history-empty-state__text {
  max-width: none;
}

@media (max-width: 920px) {
  .history-controls--search {
    padding: 20px;
  }

  .control-grid--history {
    grid-template-columns: 1fr 1fr;
  }

  .control-grid--history .actions {
    grid-column: 1 / -1;
  }
}

@media (max-width: 640px) {
  .history-search-title {
    font-size: clamp(28px, 9vw, 38px);
  }

  .history-search-box {
    padding: 16px;
    border-radius: 20px;
  }

  .history-search__input {
    min-height: 54px;
    font-size: 16px;
  }

  .history-search__guide {
    flex-direction: column;
    align-items: stretch;
  }

  .search-suggestion {
    flex-direction: column;
    align-items: flex-start;
  }

  .search-suggestion__tag {
    align-self: flex-start;
  }

  .control-grid--history {
    grid-template-columns: 1fr;
  }

  .history-empty-state {
    flex-direction: column;
    align-items: flex-start;
  }
}

.history-search__clear.is-hidden {
  opacity: 0;
  pointer-events: none;
  transform: translateY(-50%) scale(0.9);
}