:root {
  --bg0: #0f1f17;
  --bg1: #152820;
  --surface: #1c3228;
  --surface-2: #243f32;
  --line: rgba(196, 214, 180, 0.14);
  --text: #e8f0e2;
  --muted: #9bb09a;
  --brand: #6fbf7a;
  --brand-deep: #3d8f4a;
  --accent: #e2b35a;
  --accent-soft: rgba(226, 179, 90, 0.16);
  --danger: #e07a6a;
  --radius: 14px;
  --shadow: 0 18px 50px rgba(0, 0, 0, 0.35);
  --font: "Manrope", system-ui, sans-serif;
  --display: "Newsreader", Georgia, serif;
}

*,
*::before,
*::after {
  box-sizing: border-box;
}

[hidden],
.is-hidden {
  display: none !important;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  min-height: 100vh;
  font-family: var(--font);
  color: var(--text);
  background:
    radial-gradient(1200px 600px at 10% -10%, rgba(111, 191, 122, 0.18), transparent 55%),
    radial-gradient(900px 500px at 100% 0%, rgba(226, 179, 90, 0.1), transparent 50%),
    linear-gradient(180deg, var(--bg0), var(--bg1) 40%, #122019);
  line-height: 1.5;
}

.bg-glow {
  pointer-events: none;
  position: fixed;
  inset: 0;
  background-image:
    linear-gradient(rgba(255, 255, 255, 0.02) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255, 255, 255, 0.02) 1px, transparent 1px);
  background-size: 48px 48px;
  mask-image: radial-gradient(ellipse at center, black 20%, transparent 75%);
  opacity: 0.45;
}

.site-header {
  position: sticky;
  top: 0;
  z-index: 40;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  padding: 0.9rem 1.25rem;
  backdrop-filter: blur(14px);
  background: rgba(15, 31, 23, 0.82);
  border-bottom: 1px solid var(--line);
}

.brand {
  display: flex;
  align-items: center;
  gap: 0.85rem;
}

.brand-mark {
  width: 42px;
  height: 42px;
  border-radius: 12px;
  background:
    linear-gradient(145deg, var(--brand), var(--brand-deep)),
    radial-gradient(circle at 30% 30%, #b7f0bf, transparent 55%);
  box-shadow: 0 8px 24px rgba(61, 143, 74, 0.35);
  position: relative;
}

.brand-mark::after {
  content: "";
  position: absolute;
  inset: 10px 12px 14px;
  border-radius: 40% 40% 45% 45%;
  background: rgba(15, 31, 23, 0.35);
  clip-path: polygon(50% 0, 80% 35%, 70% 100%, 30% 100%, 20% 35%);
}

.brand-name {
  margin: 0;
  font-family: var(--display);
  font-size: 1.35rem;
  font-weight: 700;
  letter-spacing: -0.02em;
}

.brand-sub {
  margin: 0;
  font-size: 0.78rem;
  color: var(--muted);
}

.layout {
  width: min(1120px, calc(100% - 2rem));
  margin: 0 auto;
  padding: 1.5rem 0 4rem;
}

.hero h1 {
  margin: 0 0 0.6rem;
  font-family: var(--display);
  font-size: clamp(1.7rem, 3.5vw, 2.45rem);
  font-weight: 700;
  letter-spacing: -0.02em;
  line-height: 1.15;
  max-width: 18ch;
}

.lede {
  margin: 0 0 1.4rem;
  color: var(--muted);
  max-width: 52ch;
  font-size: 1.02rem;
}

.stats {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 0.75rem;
  margin-bottom: 1.5rem;
}

.stat {
  padding: 0.95rem 1rem;
  background: linear-gradient(180deg, var(--surface), rgba(28, 50, 40, 0.65));
  border: 1px solid var(--line);
  border-radius: var(--radius);
}

.stat strong {
  display: block;
  font-size: 1.45rem;
  font-weight: 800;
  letter-spacing: -0.03em;
  color: var(--brand);
}

.stat span {
  font-size: 0.78rem;
  color: var(--muted);
}

.view-tabs {
  display: inline-flex;
  gap: 0.35rem;
  margin: 0 0 1rem;
  padding: 0.3rem;
  background: rgba(15, 31, 23, 0.55);
  border: 1px solid var(--line);
  border-radius: 12px;
}

.view-tab {
  border: 0;
  background: transparent;
  color: var(--muted);
  font: inherit;
  font-weight: 650;
  font-size: 0.9rem;
  padding: 0.55rem 1rem;
  border-radius: 9px;
  cursor: pointer;
  transition: background 0.15s, color 0.15s;
  -webkit-appearance: none;
  appearance: none;
  color-scheme: dark;
}

.view-tab:hover {
  color: var(--text);
  background: rgba(255, 255, 255, 0.04);
}

.view-tab.active,
.view-tab.is-active {
  background: rgba(111, 191, 122, 0.22);
  color: #b7f0bf;
  box-shadow: inset 0 0 0 1px rgba(111, 191, 122, 0.35);
}

.view-panel {
  display: block;
}

.filter-count {
  margin: 0 0 0.75rem;
  color: var(--muted);
  font-size: 0.88rem;
}

.filter-row-gecmis {
  grid-template-columns: 1.6fr 1fr 1.2fr auto;
}

.score-analysis {
  margin: 0 0 1.25rem;
  padding: 1.1rem 1.15rem 1.25rem;
  border: 1px solid var(--line);
  border-radius: calc(var(--radius) + 2px);
  background: linear-gradient(180deg, rgba(28, 50, 40, 0.95), rgba(18, 32, 25, 0.9));
  box-shadow: var(--shadow);
}

.score-analysis-head {
  display: flex;
  flex-wrap: wrap;
  gap: 1rem;
  justify-content: space-between;
  align-items: flex-end;
  margin-bottom: 0.75rem;
}

.score-analysis h3 {
  margin: 0 0 0.35rem;
  font-family: var(--display);
  font-size: 1.25rem;
}

.score-analysis-hint {
  margin: 0;
  max-width: 40rem;
  color: var(--muted);
  font-size: 0.88rem;
  line-height: 1.45;
}

.score-analysis-hint strong {
  color: var(--text);
  font-weight: 650;
}

.score-form {
  display: flex;
  gap: 0.55rem;
  align-items: end;
  flex-wrap: wrap;
}

.score-field {
  min-width: 140px;
}

.score-field input {
  width: 100%;
  appearance: none;
  border: 1px solid var(--line);
  background: var(--bg0);
  color: var(--text);
  border-radius: 10px;
  padding: 0.7rem 0.85rem;
  font: inherit;
  font-size: 1.05rem;
  font-weight: 700;
  letter-spacing: 0.02em;
}

.score-field input:focus {
  outline: none;
  border-color: rgba(226, 179, 90, 0.55);
  box-shadow: 0 0 0 3px rgba(226, 179, 90, 0.18);
}

.btn-analyze {
  background: linear-gradient(180deg, #efc979, var(--accent));
  color: #1f1708;
  border: none;
  height: 42px;
  padding: 0 1.15rem;
  font-weight: 750;
}

.btn-analyze:hover {
  filter: brightness(1.05);
}

.score-note {
  margin: 0 0 0.85rem;
  font-size: 0.8rem;
  color: var(--muted);
}

.score-insight {
  margin-bottom: 0.9rem;
  padding: 0.85rem 1rem;
  border-radius: 12px;
  background: rgba(111, 191, 122, 0.1);
  border: 1px solid rgba(111, 191, 122, 0.22);
  font-size: 0.95rem;
  line-height: 1.5;
}

.score-insight p {
  margin: 0 0 0.55rem;
}

.score-insight p:last-child {
  margin-bottom: 0;
}

.insight-caveat {
  font-size: 0.82rem !important;
  color: var(--muted) !important;
}

.insight-idle {
  margin: 0;
  color: var(--muted);
}

.linkish {
  border: 0;
  background: transparent;
  color: var(--accent);
  font: inherit;
  font-weight: 700;
  cursor: pointer;
  text-decoration: underline;
  padding: 0;
}

.yordama {
  margin: 0 0 1.15rem;
  padding: 1rem 1.05rem 1.15rem;
  border-radius: 14px;
  border: 1px solid rgba(226, 179, 90, 0.28);
  background: linear-gradient(165deg, rgba(226, 179, 90, 0.1), rgba(15, 31, 23, 0.55));
}

.yordama-head h3 {
  margin: 0 0 0.35rem;
  font-family: var(--display);
  font-size: 1.2rem;
}

.yordama-disclaimer {
  margin: 0 0 0.85rem;
  font-size: 0.82rem;
  color: var(--muted);
  line-height: 1.4;
}

.verdict-card {
  padding: 1rem 1.1rem;
  border-radius: 12px;
  border: 1px solid var(--line);
  background: rgba(15, 31, 23, 0.65);
  margin-bottom: 0.85rem;
}

.verdict-card.yuksek,
.verdict-card.orta-yuksek {
  border-color: rgba(111, 191, 122, 0.45);
  background: linear-gradient(165deg, rgba(111, 191, 122, 0.18), rgba(15, 31, 23, 0.7));
}

.verdict-card.orta {
  border-color: rgba(226, 179, 90, 0.4);
}

.verdict-card.dusuk {
  border-color: rgba(224, 122, 106, 0.4);
  background: linear-gradient(165deg, rgba(224, 122, 106, 0.12), rgba(15, 31, 23, 0.7));
}

.verdict-badge {
  display: inline-block;
  font-size: 0.7rem;
  font-weight: 800;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  padding: 0.25rem 0.55rem;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.08);
  color: var(--muted);
  margin-bottom: 0.45rem;
}

.verdict-title {
  margin: 0 0 0.45rem;
  font-size: 1.25rem;
  font-weight: 800;
  letter-spacing: -0.02em;
}

.verdict-body {
  margin: 0;
  font-size: 0.9rem;
  line-height: 1.5;
  color: var(--text);
}

.yordama-metrics {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 0.55rem;
  margin-bottom: 1rem;
}

.ym {
  padding: 0.7rem 0.75rem;
  border-radius: 10px;
  border: 1px solid var(--line);
  background: rgba(15, 31, 23, 0.5);
}

.ym strong {
  display: block;
  font-size: 1.15rem;
  font-weight: 800;
  color: var(--accent);
  margin-bottom: 0.2rem;
}

.ym span {
  font-size: 0.72rem;
  color: var(--muted);
  line-height: 1.3;
}

.yordama-places h4 {
  margin: 0 0 0.3rem;
  font-size: 1rem;
}

.yordama-places-hint {
  margin: 0 0 0.75rem;
  font-size: 0.82rem;
  color: var(--muted);
}

.places-cols {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 0.85rem;
}

.place-tier {
  margin: 0 0 0.45rem;
  font-size: 0.78rem;
  font-weight: 750;
  text-transform: uppercase;
  letter-spacing: 0.04em;
}

.place-tier.safe {
  color: var(--brand);
}

.place-tier.stretch {
  color: var(--accent);
}

.place-list {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  flex-direction: column;
  gap: 0.45rem;
}

.place-list li {
  padding: 0.65rem 0.75rem;
  border-radius: 10px;
  border: 1px solid var(--line);
  background: rgba(28, 50, 40, 0.55);
}

.place-il {
  font-weight: 750;
  margin-bottom: 0.2rem;
}

.place-bolge {
  font-weight: 500;
  font-size: 0.78rem;
  color: var(--muted);
  margin-left: 0.35rem;
}

.place-meta {
  font-size: 0.78rem;
  color: var(--muted);
  line-height: 1.35;
}

.place-empty {
  color: var(--muted);
  font-size: 0.85rem;
}

.bolge-chips {
  display: flex;
  flex-wrap: wrap;
  gap: 0.4rem;
  align-items: center;
  margin-top: 0.85rem;
}

.bolge-label {
  font-size: 0.8rem;
  color: var(--muted);
  margin-right: 0.25rem;
}

.bolge-chip {
  display: inline-flex;
  padding: 0.3rem 0.6rem;
  border-radius: 999px;
  font-size: 0.78rem;
  font-weight: 650;
  background: rgba(111, 191, 122, 0.14);
  border: 1px solid rgba(111, 191, 122, 0.28);
  color: var(--text);
}

@media (max-width: 860px) {
  .yordama-metrics,
  .places-cols {
    grid-template-columns: 1fr;
  }
}

.above-below {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 0.75rem;
  margin: 0.85rem 0 0.75rem;
}

.ab-card {
  padding: 1rem 1.05rem 1.1rem;
  border-radius: 14px;
  border: 1px solid var(--line);
  background: rgba(15, 31, 23, 0.55);
  display: flex;
  flex-direction: column;
  gap: 0.35rem;
  min-height: 8.5rem;
}

.ab-eyebrow {
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--muted);
}

.ab-num {
  font-family: var(--display);
  font-size: clamp(2rem, 4vw, 2.75rem);
  font-weight: 700;
  line-height: 1;
  letter-spacing: -0.03em;
  color: var(--brand);
}

.ab-label {
  font-size: 0.88rem;
  color: var(--text);
  line-height: 1.35;
  margin-top: auto;
}

.ab-above {
  border-color: rgba(226, 179, 90, 0.4);
  background: linear-gradient(165deg, rgba(226, 179, 90, 0.16), rgba(28, 50, 40, 0.7));
}

.ab-above .ab-num {
  color: var(--accent);
}

.ab-below {
  border-color: rgba(111, 191, 122, 0.4);
  background: linear-gradient(165deg, rgba(111, 191, 122, 0.14), rgba(28, 50, 40, 0.7));
}

.ab-total .ab-num {
  color: #d7e8d4;
}

.score-insight {
  margin: 0 0 1rem;
  padding: 0.75rem 0.9rem;
  border-radius: 10px;
  background: rgba(111, 191, 122, 0.08);
  border: 1px solid rgba(111, 191, 122, 0.18);
  font-size: 0.9rem;
  line-height: 1.45;
  color: var(--text);
}

@media (max-width: 860px) {
  .above-below {
    grid-template-columns: 1fr;
  }
}

.score-compare {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 0.65rem;
  margin-bottom: 1.1rem;
}

.compare-card {
  padding: 0.75rem 0.85rem;
  border-radius: 12px;
  border: 1px solid var(--line);
  background: rgba(15, 31, 23, 0.45);
}

.compare-card strong {
  display: block;
  font-size: 1.05rem;
  font-weight: 800;
  color: var(--brand);
  margin-bottom: 0.2rem;
}

.compare-card span {
  font-size: 0.75rem;
  color: var(--muted);
}

.compare-card.accent strong {
  color: var(--accent);
}

.score-dist h4 {
  margin: 0 0 0.35rem;
  font-size: 1rem;
}

.score-dist-hint {
  margin: 0 0 0.75rem;
  font-size: 0.82rem;
  color: var(--muted);
}

.dist-bars {
  display: flex;
  flex-direction: column;
  gap: 0.45rem;
  margin-bottom: 0.9rem;
}

.dist-bar-row {
  display: grid;
  grid-template-columns: 6.5rem 1fr 3rem;
  gap: 0.55rem;
  align-items: center;
}

.dist-bar-label {
  font-size: 0.8rem;
  color: var(--muted);
  font-weight: 600;
}

.dist-bar-track {
  height: 10px;
  border-radius: 999px;
  background: rgba(15, 31, 23, 0.65);
  overflow: hidden;
  border: 1px solid var(--line);
}

.dist-bar-fill {
  height: 100%;
  border-radius: 999px;
  background: linear-gradient(90deg, var(--brand-deep), var(--brand));
  min-width: 2px;
  transition: width 0.35s ease;
}

.dist-bar-val {
  text-align: right;
  font-weight: 750;
  font-variant-numeric: tabular-nums;
  font-size: 0.85rem;
}

.dist-table-wrap {
  max-height: none;
}

@media (max-width: 960px) {
  .score-stats,
  .score-compare {
    grid-template-columns: 1fr 1fr;
  }
}

@media (max-width: 640px) {
  .score-stats,
  .score-compare {
    grid-template-columns: 1fr;
  }

  .dist-bar-row {
    grid-template-columns: 5.5rem 1fr 2.5rem;
  }

  .filter-row-gecmis {
    grid-template-columns: 1fr;
  }
}

.il-summary-toolbar {
  display: flex;
  flex-wrap: wrap;
  gap: 1rem;
  align-items: end;
  justify-content: space-between;
  margin-bottom: 1rem;
}

.il-summary-toolbar h2 {
  margin: 0 0 0.35rem;
  font-family: var(--display);
  font-size: 1.35rem;
}

.il-summary-hint {
  margin: 0;
  color: var(--muted);
  font-size: 0.9rem;
  max-width: 42rem;
}

.il-sort-field {
  min-width: 220px;
}

.il-grand {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 0.75rem;
  margin-bottom: 1rem;
}

.il-table {
  min-width: 640px;
}

.il-row {
  cursor: pointer;
}

.il-row:hover {
  background: rgba(111, 191, 122, 0.12) !important;
}

.il-row:focus-visible {
  outline: 2px solid rgba(111, 191, 122, 0.55);
  outline-offset: -2px;
}

.col-rank {
  width: 48px;
  color: var(--muted);
  font-variant-numeric: tabular-nums;
}

.num-plain {
  font-weight: 750;
  font-variant-numeric: tabular-nums;
}

.break-text {
  font-size: 0.82rem;
  color: var(--muted);
}

.col-break {
  min-width: 10rem;
}

.filters {
  position: sticky;
  top: 68px;
  z-index: 30;
  margin-bottom: 1rem;
  padding: 1rem;
  background: rgba(28, 50, 40, 0.92);
  border: 1px solid var(--line);
  border-radius: calc(var(--radius) + 2px);
  backdrop-filter: blur(12px);
  box-shadow: var(--shadow);
}

.filter-row {
  display: grid;
  grid-template-columns: 1.6fr repeat(4, 1fr) auto;
  gap: 0.7rem;
  align-items: end;
}

.field {
  display: flex;
  flex-direction: column;
  gap: 0.35rem;
  min-width: 0;
}

.field-label {
  font-size: 0.72rem;
  font-weight: 600;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: var(--muted);
}

input[type="search"],
select {
  width: 100%;
  appearance: none;
  border: 1px solid var(--line);
  background: var(--bg0);
  color: var(--text);
  border-radius: 10px;
  padding: 0.7rem 0.85rem;
  font: inherit;
  font-size: 0.92rem;
  transition: border-color 0.15s, box-shadow 0.15s;
}

input[type="search"]:focus,
select:focus {
  outline: none;
  border-color: rgba(111, 191, 122, 0.55);
  box-shadow: 0 0 0 3px rgba(111, 191, 122, 0.18);
}

.btn {
  border: 1px solid transparent;
  border-radius: 10px;
  padding: 0.65rem 1rem;
  font: inherit;
  font-weight: 650;
  font-size: 0.9rem;
  cursor: pointer;
  transition: transform 0.12s, background 0.15s, border-color 0.15s;
}

.btn:active {
  transform: translateY(1px);
}

.btn-ghost {
  background: rgba(111, 191, 122, 0.12);
  border-color: rgba(111, 191, 122, 0.28);
  color: var(--text);
}

.btn-ghost:hover {
  background: rgba(111, 191, 122, 0.2);
}

.btn-clear {
  background: transparent;
  border-color: var(--line);
  color: var(--muted);
  white-space: nowrap;
  height: 42px;
}

.btn-clear:hover {
  color: var(--text);
  border-color: rgba(196, 214, 180, 0.35);
}

.btn-danger {
  background: rgba(224, 122, 106, 0.12);
  border-color: rgba(224, 122, 106, 0.35);
  color: #f0b4aa;
}

.btn-icon {
  background: transparent;
  border: none;
  color: var(--muted);
  font-size: 1.6rem;
  line-height: 1;
  padding: 0.2rem 0.5rem;
}

.badge {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 1.4rem;
  height: 1.4rem;
  padding: 0 0.35rem;
  margin-left: 0.35rem;
  border-radius: 999px;
  background: var(--accent);
  color: #1a1408;
  font-size: 0.75rem;
  font-weight: 800;
}

.table-wrap {
  overflow: auto;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: rgba(28, 50, 40, 0.55);
}

.data-table {
  width: 100%;
  border-collapse: collapse;
  min-width: 720px;
}

.data-table th,
.data-table td {
  padding: 0.85rem 1rem;
  text-align: left;
  border-bottom: 1px solid var(--line);
  vertical-align: middle;
}

.data-table th {
  position: sticky;
  top: 0;
  font-size: 0.72rem;
  letter-spacing: 0.05em;
  text-transform: uppercase;
  color: var(--muted);
  background: #1a2e24;
  z-index: 1;
}

.data-table tbody tr {
  transition: background 0.12s;
}

.data-table tbody tr:hover {
  background: rgba(111, 191, 122, 0.08);
}

.data-table tbody tr.is-fav {
  background: var(--accent-soft);
}

.col-fav {
  width: 52px;
}

.col-num {
  text-align: right !important;
  white-space: nowrap;
}

.il-cell {
  font-weight: 700;
  letter-spacing: -0.01em;
}

.birim-cell {
  display: flex;
  flex-direction: column;
  gap: 0.15rem;
}

.birim-main {
  font-weight: 600;
}

.birim-sub {
  font-size: 0.8rem;
  color: var(--muted);
}

.tip-pill {
  display: inline-flex;
  padding: 0.2rem 0.55rem;
  border-radius: 999px;
  font-size: 0.75rem;
  font-weight: 650;
  background: rgba(155, 176, 154, 0.12);
  color: var(--muted);
  border: 1px solid var(--line);
}

.tip-pill.sube {
  background: rgba(226, 179, 90, 0.12);
  color: #efd09a;
  border-color: rgba(226, 179, 90, 0.25);
}

.kont-badge {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 2.4rem;
  padding: 0.35rem 0.65rem;
  border-radius: 999px;
  font-weight: 800;
  font-size: 0.95rem;
  background: linear-gradient(180deg, #efc979, var(--accent));
  color: #1f1708;
  box-shadow: 0 6px 16px rgba(226, 179, 90, 0.25);
}

.star-btn {
  width: 36px;
  height: 36px;
  border-radius: 10px;
  border: 1px solid var(--line);
  background: transparent;
  color: var(--muted);
  font-size: 1.1rem;
  cursor: pointer;
  transition: all 0.15s;
}

.star-btn:hover {
  border-color: rgba(226, 179, 90, 0.45);
  color: var(--accent);
}

.star-btn.active {
  background: var(--accent-soft);
  border-color: rgba(226, 179, 90, 0.55);
  color: var(--accent);
}

.empty {
  text-align: center;
  color: var(--muted);
  padding: 2.5rem 1rem;
}

.drawer-backdrop {
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, 0.45);
  z-index: 50;
}

.drawer {
  position: fixed;
  inset: 0 0 0 auto;
  width: min(420px, 100%);
  z-index: 60;
  pointer-events: none;
  transform: translateX(100%);
  transition: transform 0.28s cubic-bezier(0.22, 1, 0.36, 1);
}

.drawer.open {
  transform: translateX(0);
  pointer-events: auto;
}

.drawer-panel {
  height: 100%;
  display: flex;
  flex-direction: column;
  background: linear-gradient(180deg, #1a2e24, #122019);
  border-left: 1px solid var(--line);
  box-shadow: -20px 0 50px rgba(0, 0, 0, 0.35);
  padding: 1.1rem 1.1rem 1.4rem;
}

.drawer-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.5rem;
}

.drawer-head h2 {
  margin: 0;
  font-family: var(--display);
  font-size: 1.35rem;
}

.drawer-hint {
  margin: 0.5rem 0 1rem;
  font-size: 0.85rem;
  color: var(--muted);
}

.fav-list {
  list-style: none;
  margin: 0;
  padding: 0;
  overflow: auto;
  flex: 1;
  display: flex;
  flex-direction: column;
  gap: 0.55rem;
}

.fav-item {
  display: grid;
  grid-template-columns: auto 1fr auto;
  gap: 0.65rem;
  align-items: start;
  padding: 0.75rem;
  border-radius: 12px;
  border: 1px solid var(--line);
  background: rgba(15, 31, 23, 0.55);
}

.fav-rank {
  width: 28px;
  height: 28px;
  border-radius: 8px;
  display: grid;
  place-items: center;
  font-weight: 800;
  font-size: 0.85rem;
  background: rgba(111, 191, 122, 0.18);
  color: var(--brand);
}

.fav-title {
  margin: 0;
  font-weight: 700;
  font-size: 0.92rem;
}

.fav-meta {
  margin: 0.2rem 0 0;
  font-size: 0.78rem;
  color: var(--muted);
}

.fav-controls {
  display: flex;
  flex-direction: column;
  gap: 0.25rem;
}

.fav-controls button {
  width: 28px;
  height: 28px;
  border-radius: 8px;
  border: 1px solid var(--line);
  background: transparent;
  color: var(--muted);
  cursor: pointer;
}

.fav-controls button:hover {
  color: var(--text);
  border-color: rgba(196, 214, 180, 0.35);
}

.empty-fav {
  color: var(--muted);
  text-align: center;
  padding: 2rem 0.5rem;
}

.drawer-actions {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 0.55rem;
  margin-top: 1rem;
}

.site-footer {
  width: min(1120px, calc(100% - 2rem));
  margin: 0 auto 2rem;
  color: var(--muted);
  font-size: 0.82rem;
}

.toast {
  position: fixed;
  bottom: 1.25rem;
  left: 50%;
  transform: translateX(-50%) translateY(20px);
  background: var(--surface-2);
  color: var(--text);
  border: 1px solid var(--line);
  padding: 0.7rem 1rem;
  border-radius: 999px;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.2s, transform 0.2s;
  z-index: 80;
  font-size: 0.9rem;
  box-shadow: var(--shadow);
}

.toast.show {
  opacity: 1;
  transform: translateX(-50%) translateY(0);
}

@media (max-width: 960px) {
  .filter-row {
    grid-template-columns: 1fr 1fr;
  }

  .search-field {
    grid-column: 1 / -1;
  }

  .btn-clear {
    grid-column: 1 / -1;
  }

  .stats {
    grid-template-columns: 1fr 1fr;
  }

  .il-grand {
    grid-template-columns: 1fr;
  }

  .il-sort-field {
    width: 100%;
  }
}

@media (max-width: 640px) {
  .site-header {
    padding: 0.75rem 1rem;
  }

  .brand-sub {
    display: none;
  }

  .hero h1 {
    max-width: none;
  }

  .filters {
    top: 60px;
  }

  .filter-row {
    grid-template-columns: 1fr;
  }
}
