/* akaturk Genel İstatistikler — sidebar + ranking table */

.aka-stats-body {
  background: var(--aka-body-bg, #f4f6fb);
}

.aka-stats__shell {
  width: 100%;
  padding: 0 0 3rem;
  position: relative;
  z-index: 2;
}

.aka-stats__sidebar-toggle {
  display: none;
  margin: 0.85rem clamp(0.85rem, 2.2vw, 1.5rem) 0;
  align-items: center;
  gap: 0.5rem;
  padding: 0.55rem 0.85rem;
  border: 1px solid rgba(15, 35, 90, 0.12);
  border-radius: 10px;
  background: #fff;
  color: var(--aka-navy-dark, #0f235a);
  font-weight: 600;
  font-size: 0.875rem;
  cursor: pointer;
}

.aka-stats__backdrop {
  position: fixed;
  inset: 0;
  background: rgba(10, 18, 40, 0.45);
  z-index: 40;
}

.aka-stats__layout {
  display: grid;
  grid-template-columns: minmax(240px, 300px) minmax(0, 1fr);
  gap: 0;
  align-items: start;
  min-height: 60vh;
}

.aka-stats__sidebar {
  position: sticky;
  top: calc(var(--aka-nav-h, 52px) + 0.5rem);
  max-height: calc(100vh - var(--aka-nav-h, 52px) - 1rem);
  overflow: auto;
  background: #fff;
  border-right: 1px solid rgba(15, 35, 90, 0.08);
  padding: 1.1rem 0.85rem 1.5rem;
}

.aka-stats__sidebar-head-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.5rem;
}

.aka-stats__sidebar-title {
  margin: 0;
  font-size: 0.95rem;
  font-weight: 700;
  color: var(--aka-navy-dark, #0f235a);
}

.aka-stats__sidebar-close {
  display: none;
  border: 0;
  background: transparent;
  font-size: 1.4rem;
  line-height: 1;
  cursor: pointer;
  color: #64748b;
}

.aka-stats__sidebar-lead {
  margin: 0.45rem 0 0.85rem;
  font-size: 0.78rem;
  line-height: 1.45;
  color: #64748b;
}

.aka-stats__nav {
  display: flex;
  flex-direction: column;
  gap: 0.2rem;
}

.aka-stats__nav-link {
  display: block;
  padding: 0.55rem 0.7rem;
  border-radius: 8px;
  text-decoration: none;
  color: #1e293b;
  font-size: 0.8125rem;
  line-height: 1.35;
  font-weight: 500;
  transition: background 0.15s ease, color 0.15s ease;
}

.aka-stats__nav-link:hover {
  background: rgba(15, 35, 90, 0.05);
  color: var(--aka-navy-dark, #0f235a);
}

.aka-stats__nav-link.is-active {
  background: rgba(15, 35, 90, 0.09);
  color: var(--aka-navy-dark, #0f235a);
  font-weight: 700;
}

.aka-stats__main {
  padding: 1.25rem clamp(0.85rem, 2.2vw, 1.75rem) 2rem;
  min-width: 0;
}

.aka-stats__cards {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  gap: 0.65rem;
}

.aka-stats__card {
  display: flex;
  flex-direction: column;
  gap: 0.35rem;
  padding: 0.95rem 1.05rem;
  background: #fff;
  border: 1px solid rgba(15, 35, 90, 0.08);
  border-radius: 12px;
  text-decoration: none;
  color: inherit;
  transition: border-color 0.15s ease, box-shadow 0.15s ease;
}

.aka-stats__card:hover {
  border-color: rgba(15, 35, 90, 0.22);
  box-shadow: 0 6px 18px rgba(15, 35, 90, 0.06);
}

.aka-stats__card-title {
  font-weight: 700;
  font-size: 0.95rem;
  color: var(--aka-navy-dark, #0f235a);
}

.aka-stats__card-desc {
  font-size: 0.8125rem;
  color: #64748b;
  line-height: 1.45;
}

.aka-stats__qbar {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.65rem 1rem;
  margin-bottom: 1rem;
}

.aka-stats__qbar-label {
  font-size: 0.8125rem;
  font-weight: 600;
  color: #475569;
}

.aka-stats__seg {
  display: inline-flex;
  border: 1px solid rgba(15, 35, 90, 0.14);
  border-radius: 999px;
  overflow: hidden;
  background: #fff;
}

.aka-stats__seg-btn {
  padding: 0.4rem 0.95rem;
  font-size: 0.8125rem;
  font-weight: 600;
  text-decoration: none;
  color: #475569;
}

.aka-stats__seg-btn.is-active {
  background: var(--aka-navy-dark, #0f235a);
  color: #fff;
}

.aka-stats__meta {
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  gap: 0.5rem 1rem;
  margin-bottom: 0.85rem;
}

.aka-stats__metric {
  margin: 0;
  font-size: 0.9rem;
  color: #334155;
}

.aka-stats__limit {
  margin: 0;
  font-size: 0.8rem;
  color: #64748b;
}

.aka-stats__table-wrap {
  overflow-x: auto;
  background: #fff;
  border: 1px solid rgba(15, 35, 90, 0.08);
  border-radius: 12px;
}

.aka-stats__table {
  width: 100%;
  border-collapse: collapse;
  font-size: 0.875rem;
}

.aka-stats__table th,
.aka-stats__table td {
  padding: 0.7rem 0.85rem;
  text-align: left;
  border-bottom: 1px solid rgba(15, 35, 90, 0.06);
  vertical-align: top;
}

.aka-stats__table thead th {
  font-size: 0.72rem;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  color: #64748b;
  background: #f8fafc;
  font-weight: 700;
}

.aka-stats__rank {
  width: 3.2rem;
  font-variant-numeric: tabular-nums;
  font-weight: 700;
  color: var(--aka-navy-dark, #0f235a);
}

.aka-stats__name {
  font-weight: 600;
  color: var(--aka-navy-dark, #0f235a);
  text-decoration: none;
}

a.aka-stats__name:hover {
  text-decoration: underline;
}

.aka-stats__sub {
  display: block;
  margin-top: 0.15rem;
  font-size: 0.75rem;
  font-weight: 500;
  color: #64748b;
}

.aka-stats__th-num,
.aka-stats__num {
  text-align: right !important;
  font-variant-numeric: tabular-nums;
  white-space: nowrap;
}

.aka-stats__num {
  font-weight: 700;
  color: #0f172a;
}

.aka-stats__empty {
  margin: 1rem 0;
  padding: 1rem;
  background: #fff;
  border-radius: 10px;
  color: #64748b;
}

.aka-stats__note {
  margin: 1.15rem 0 0;
  font-size: 0.78rem;
  line-height: 1.5;
  color: #64748b;
  max-width: 48rem;
}

@media (max-width: 920px) {
  .aka-stats__sidebar-toggle {
    display: inline-flex;
  }

  .aka-stats__layout {
    grid-template-columns: 1fr;
  }

  .aka-stats__sidebar {
    position: fixed;
    top: 0;
    left: 0;
    bottom: 0;
    width: min(88vw, 320px);
    max-height: none;
    z-index: 50;
    transform: translateX(-105%);
    transition: transform 0.2s ease;
    box-shadow: 8px 0 24px rgba(10, 18, 40, 0.12);
  }

  .aka-stats__sidebar.is-open {
    transform: translateX(0);
  }

  .aka-stats__sidebar-close {
    display: inline-flex;
  }
}
