/* =========================================================
   APM — Athlete Performance Matrix
   main.css  |  Font: DM Sans  |  sports.ivirth.in
   ========================================================= */

/* ── Design tokens ─────────────────────────────────────── */
:root {
  --bg:          #0b0e14;
  --bg-card:     #131720;
  --bg-card-2:   #1a2030;
  --border:      #222840;
  --border-light:#2a3450;

  --accent:      #3d7fff;
  --accent-glow: rgba(61,127,255,0.18);
  --accent-2:    #00e5a0;   /* secondary teal-green */
  --accent-warn: #ff9d3d;
  --accent-danger:#ff4d6d;

  --text-primary:  #edf0f7;
  --text-secondary:#8a94b0;
  --text-muted:    #4a5270;

  --font: 'DM Sans', system-ui, sans-serif;
  --radius:   10px;
  --radius-lg:16px;
  --shadow:   0 2px 12px rgba(0,0,0,.45);
  --shadow-lg:0 8px 40px rgba(0,0,0,.6);
  --transition: 0.18s ease;
}

/* ── Reset & base ──────────────────────────────────────── */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html { font-size: 16px; scroll-behavior: smooth; }
body {
  font-family: var(--font);
  background: var(--bg);
  color: var(--text-primary);
  min-height: 100vh;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}
a { color: var(--accent); text-decoration: none; }
a:hover { color: #6fa3ff; }
img { max-width: 100%; display: block; }
input, select, textarea, button { font-family: var(--font); }

/* ── Scrollbar ─────────────────────────────────────────── */
::-webkit-scrollbar { width: 6px; height: 6px; }
::-webkit-scrollbar-track { background: var(--bg); }
::-webkit-scrollbar-thumb { background: var(--border-light); border-radius: 99px; }

/* ── Typography ────────────────────────────────────────── */
h1 { font-size: 1.75rem; font-weight: 700; letter-spacing: -.02em; }
h2 { font-size: 1.35rem; font-weight: 600; letter-spacing: -.015em; }
h3 { font-size: 1.1rem;  font-weight: 600; }
h4 { font-size: .95rem;  font-weight: 600; }
p  { color: var(--text-secondary); }
small { font-size: .8rem; }

/* ── Layout utility ────────────────────────────────────── */
.container { max-width: 1240px; margin: 0 auto; padding: 0 20px; }
.flex       { display: flex; }
.flex-col   { display: flex; flex-direction: column; }
.items-center { align-items: center; }
.justify-between { justify-content: space-between; }
.gap-2  { gap: .5rem; }
.gap-4  { gap: 1rem; }
.gap-6  { gap: 1.5rem; }
.w-full { width: 100%; }
.mt-1 { margin-top: .25rem; }
.mt-2 { margin-top: .5rem; }
.mt-4 { margin-top: 1rem; }
.mt-6 { margin-top: 1.5rem; }
.mt-8 { margin-top: 2rem; }
.mb-4 { margin-bottom: 1rem; }
.mb-6 { margin-bottom: 1.5rem; }
.mb-8 { margin-bottom: 2rem; }
.text-right { text-align: right; }
.text-center { text-align: center; }
.text-muted { color: var(--text-muted); }
.text-secondary { color: var(--text-secondary); }
.text-accent { color: var(--accent); }
.text-green  { color: var(--accent-2); }
.text-warn   { color: var(--accent-warn); }
.text-danger { color: var(--accent-danger); }

/* ── Grid layouts ──────────────────────────────────────── */
.grid-2 { display: grid; grid-template-columns: repeat(2, 1fr); gap: 1.5rem; }
.grid-3 { display: grid; grid-template-columns: repeat(3, 1fr); gap: 1.5rem; }
.grid-4 { display: grid; grid-template-columns: repeat(4, 1fr); gap: 1.5rem; }
.grid-auto { display: grid; grid-template-columns: repeat(auto-fill, minmax(260px,1fr)); gap: 1.5rem; }
@media (max-width: 900px) {
  .grid-4 { grid-template-columns: repeat(2,1fr); }
  .grid-3 { grid-template-columns: repeat(2,1fr); }
}
@media (max-width: 600px) {
  .grid-2,.grid-3,.grid-4 { grid-template-columns: 1fr; }
}

/* ── Navigation ────────────────────────────────────────── */
.nav {
  position: sticky; top: 0; z-index: 100;
  background: rgba(11,14,20,.92);
  backdrop-filter: blur(16px);
  border-bottom: 1px solid var(--border);
}
.nav__inner {
  max-width: 1240px; margin: 0 auto; padding: 0 20px;
  height: 60px; display: flex; align-items: center; gap: 2rem;
}
.nav__brand {
  display: flex; align-items: center; gap: 10px;
  text-decoration: none; flex-shrink: 0;
}
.nav__logo { width: 32px; height: 32px; }
.nav__wordmark {
  font-size: 1.05rem; font-weight: 700; color: var(--text-primary); letter-spacing: -.02em;
}
.nav__wordmark em { font-style: normal; color: var(--accent); }

.nav__links {
  display: flex; list-style: none; gap: .25rem; align-items: center; flex: 1;
}
.nav__links a, .nav__drop-btn {
  color: var(--text-secondary); padding: .45rem .75rem;
  border-radius: 6px; font-size: .9rem; font-weight: 500; transition: all var(--transition);
  background: none; border: none; cursor: pointer; display: flex; align-items: center; gap: 4px;
}
.nav__links a:hover, .nav__drop-btn:hover, .nav__links a.active {
  color: var(--text-primary); background: var(--bg-card-2);
}

/* Dropdown */
.nav__dropdown { position: relative; }
.nav__dropdown-menu {
  display: none; position: absolute; top: calc(100% + 8px); left: 0;
  background: var(--bg-card); border: 1px solid var(--border); border-radius: var(--radius);
  padding: .4rem 0; min-width: 210px; box-shadow: var(--shadow-lg); z-index: 200; list-style: none;
}
.nav__dropdown:hover .nav__dropdown-menu,
.nav__dropdown.open .nav__dropdown-menu { display: block; }
.nav__dropdown-menu li a {
  display: block; padding: .5rem 1rem; font-size: .875rem; color: var(--text-secondary);
  border-radius: 0; transition: all var(--transition);
}
.nav__dropdown-menu li a:hover { background: var(--bg-card-2); color: var(--text-primary); }

/* User avatar */
.nav__user { position: relative; margin-left: auto; }
.nav__avatar-btn {
  display: flex; align-items: center; gap: 8px; background: none; border: none; cursor: pointer;
  color: var(--text-secondary); padding: 4px 8px; border-radius: 6px; transition: all var(--transition);
}
.nav__avatar-btn:hover { background: var(--bg-card-2); color: var(--text-primary); }
.nav__avatar-img { width: 30px; height: 30px; border-radius: 50%; object-fit: cover; border: 1.5px solid var(--border-light); }
.nav__avatar-initial {
  width: 30px; height: 30px; border-radius: 50%; background: var(--accent);
  color: #fff; font-weight: 700; font-size: .85rem; display: flex; align-items: center; justify-content: center;
}
.nav__username { font-size: .875rem; font-weight: 500; }
.nav__user-dropdown {
  display: none; position: absolute; top: calc(100% + 8px); right: 0;
  background: var(--bg-card); border: 1px solid var(--border); border-radius: var(--radius);
  padding: .5rem 0; min-width: 220px; box-shadow: var(--shadow-lg); z-index: 200;
}
.nav__user-dropdown.open { display: block; }
.nav__user-info { padding: .75rem 1rem; }
.nav__user-info strong { display: block; font-size: .9rem; color: var(--text-primary); }
.nav__user-info span { display: block; font-size: .8rem; color: var(--text-secondary); margin-top: 2px; }
.nav__user-dropdown hr { border: none; border-top: 1px solid var(--border); margin: .35rem 0; }
.nav__user-dropdown a {
  display: block; padding: .5rem 1rem; font-size: .875rem; color: var(--text-secondary);
  transition: all var(--transition);
}
.nav__user-dropdown a:hover { background: var(--bg-card-2); color: var(--text-primary); }

/* ── Page wrapper ──────────────────────────────────────── */
.page-wrapper { max-width: 1240px; margin: 0 auto; padding: 2rem 20px 4rem; }
.page-header {
  display: flex; align-items: flex-start; justify-content: space-between;
  gap: 1rem; margin-bottom: 2rem; flex-wrap: wrap;
}
.page-header h1 { font-size: 1.6rem; }
.page-header p { color: var(--text-secondary); font-size: .9rem; margin-top: .25rem; }
.page-header__actions { display: flex; gap: .75rem; align-items: center; flex-shrink: 0; }

/* ── Cards ─────────────────────────────────────────────── */
.card {
  background: var(--bg-card); border: 1px solid var(--border);
  border-radius: var(--radius-lg); padding: 1.5rem;
}
.card--hover { transition: border-color var(--transition), transform var(--transition); }
.card--hover:hover { border-color: var(--border-light); transform: translateY(-2px); }
.card__header {
  display: flex; align-items: center; justify-content: space-between; margin-bottom: 1.25rem;
}
.card__title { font-size: 1rem; font-weight: 600; color: var(--text-primary); }
.card__subtitle { font-size: .8rem; color: var(--text-muted); margin-top: 2px; }

/* KPI / stat card */
.stat-card {
  background: var(--bg-card); border: 1px solid var(--border); border-radius: var(--radius-lg);
  padding: 1.25rem 1.5rem; display: flex; flex-direction: column; gap: .35rem;
}
.stat-card__label { font-size: .78rem; font-weight: 500; color: var(--text-muted); text-transform: uppercase; letter-spacing: .06em; }
.stat-card__value { font-size: 2rem; font-weight: 700; letter-spacing: -.03em; color: var(--text-primary); line-height: 1.1; }
.stat-card__sub { font-size: .8rem; color: var(--text-secondary); }
.stat-card__delta { font-size: .78rem; font-weight: 600; }
.stat-card__delta--up   { color: var(--accent-2); }
.stat-card__delta--down { color: var(--accent-danger); }
.stat-card--accent { border-color: var(--accent); }

/* ── Buttons ────────────────────────────────────────────── */
.btn {
  display: inline-flex; align-items: center; gap: .4rem; padding: .55rem 1.2rem;
  border-radius: 8px; font-family: var(--font); font-size: .875rem; font-weight: 600;
  cursor: pointer; border: none; transition: all var(--transition); white-space: nowrap; line-height: 1.4;
}
.btn--primary { background: var(--accent); color: #fff; }
.btn--primary:hover { background: #2d6fef; box-shadow: 0 0 20px var(--accent-glow); }
.btn--secondary { background: var(--bg-card-2); color: var(--text-primary); border: 1px solid var(--border); }
.btn--secondary:hover { border-color: var(--border-light); background: var(--border); }
.btn--danger { background: rgba(255,77,109,.15); color: var(--accent-danger); border: 1px solid rgba(255,77,109,.25); }
.btn--danger:hover { background: rgba(255,77,109,.25); }
.btn--ghost { background: transparent; color: var(--text-secondary); }
.btn--ghost:hover { color: var(--text-primary); background: var(--bg-card-2); }
.btn--sm { padding: .35rem .8rem; font-size: .8rem; }
.btn--lg { padding: .7rem 1.6rem; font-size: 1rem; }
.btn:disabled { opacity: .45; cursor: not-allowed; }

/* ── Forms ──────────────────────────────────────────────── */
.form-group { display: flex; flex-direction: column; gap: .4rem; }
label { font-size: .82rem; font-weight: 600; color: var(--text-secondary); letter-spacing: .02em; }
input[type=text], input[type=email], input[type=number], input[type=date],
input[type=password], select, textarea {
  background: var(--bg); border: 1px solid var(--border); border-radius: 8px;
  color: var(--text-primary); font-family: var(--font); font-size: .9rem;
  padding: .6rem .9rem; width: 100%; transition: border-color var(--transition);
  -webkit-appearance: none; appearance: none;
}
input:focus, select:focus, textarea:focus {
  outline: none; border-color: var(--accent); box-shadow: 0 0 0 3px var(--accent-glow);
}
input::placeholder, textarea::placeholder { color: var(--text-muted); }
select { background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='10' height='6' viewBox='0 0 10 6'%3E%3Cpath d='M1 1l4 4 4-4' stroke='%238a94b0' stroke-width='1.5' fill='none' stroke-linecap='round'/%3E%3C/svg%3E"); background-repeat: no-repeat; background-position: right .85rem center; padding-right: 2.2rem; cursor: pointer; }
textarea { resize: vertical; min-height: 90px; }
.form-row { display: grid; grid-template-columns: 1fr 1fr; gap: 1rem; }
.form-row--3 { grid-template-columns: repeat(3, 1fr); }
@media (max-width: 600px) { .form-row, .form-row--3 { grid-template-columns: 1fr; } }
.form-hint { font-size: .78rem; color: var(--text-muted); }
.form-error { font-size: .78rem; color: var(--accent-danger); }

/* ── Tables ─────────────────────────────────────────────── */
.table-wrap { overflow-x: auto; border-radius: var(--radius); border: 1px solid var(--border); }
table { width: 100%; border-collapse: collapse; }
thead tr { background: var(--bg-card-2); }
th {
  font-size: .75rem; font-weight: 700; text-transform: uppercase; letter-spacing: .06em;
  color: var(--text-muted); padding: .75rem 1rem; text-align: left; white-space: nowrap;
}
td { padding: .75rem 1rem; font-size: .875rem; color: var(--text-secondary); border-top: 1px solid var(--border); }
tbody tr { transition: background var(--transition); }
tbody tr:hover { background: var(--bg-card-2); }
td strong { color: var(--text-primary); }
.td--right { text-align: right; }
.td--center { text-align: center; }

/* ── Badges ─────────────────────────────────────────────── */
.badge {
  display: inline-flex; align-items: center; padding: .2rem .55rem;
  border-radius: 99px; font-size: .72rem; font-weight: 700; letter-spacing: .04em; text-transform: uppercase;
}
.badge--athlete  { background: rgba(61,127,255,.15); color: var(--accent); }
.badge--coach    { background: rgba(0,229,160,.15);  color: var(--accent-2); }
.badge--admin    { background: rgba(255,157,61,.15); color: var(--accent-warn); }
.badge--info     { background: rgba(61,127,255,.12); color: var(--accent); }
.badge--success  { background: rgba(0,229,160,.12);  color: var(--accent-2); }
.badge--warning  { background: rgba(255,157,61,.12); color: var(--accent-warn); }
.badge--danger   { background: rgba(255,77,109,.12); color: var(--accent-danger); }
.badge--speed    { background: rgba(255,77,109,.12); color: var(--accent-danger); }
.badge--hybrid   { background: rgba(255,157,61,.12); color: var(--accent-warn); }
.badge--endurance{ background: rgba(0,229,160,.12);  color: var(--accent-2); }

/* ── Zone pills ─────────────────────────────────────────── */
.zone { display: inline-block; padding: .25rem .65rem; border-radius: 6px; font-size: .78rem; font-weight: 600; }
.zone--low      { background: rgba(61,127,255,.12); color: var(--accent); }
.zone--optimal  { background: rgba(0,229,160,.12);  color: var(--accent-2); }
.zone--elevated { background: rgba(255,157,61,.12); color: var(--accent-warn); }
.zone--high     { background: rgba(255,77,109,.12); color: var(--accent-danger); }

/* ── Progress bar ───────────────────────────────────────── */
.progress-bar { background: var(--border); border-radius: 99px; height: 7px; overflow: hidden; }
.progress-bar__fill { height: 100%; border-radius: 99px; transition: width .5s ease; }
.progress-bar__fill--blue  { background: var(--accent); }
.progress-bar__fill--green { background: var(--accent-2); }
.progress-bar__fill--warn  { background: var(--accent-warn); }
.progress-bar__fill--danger{ background: var(--accent-danger); }

/* ── Alert / Flash ──────────────────────────────────────── */
.flash {
  padding: .85rem 1.2rem; border-radius: var(--radius); font-size: .875rem; font-weight: 500;
  margin-bottom: 1.25rem; border-left: 4px solid;
}
.flash--success { background: rgba(0,229,160,.08); border-color: var(--accent-2); color: var(--accent-2); }
.flash--error   { background: rgba(255,77,109,.08); border-color: var(--accent-danger); color: var(--accent-danger); }
.flash--warning { background: rgba(255,157,61,.08); border-color: var(--accent-warn); color: var(--accent-warn); }
.flash--info    { background: rgba(61,127,255,.08); border-color: var(--accent); color: var(--accent); }

/* ── Tabs ───────────────────────────────────────────────── */
.tabs { display: flex; gap: 0; border-bottom: 1px solid var(--border); margin-bottom: 1.5rem; overflow-x: auto; }
.tab-btn {
  padding: .65rem 1.1rem; font-size: .875rem; font-weight: 500; color: var(--text-secondary);
  background: none; border: none; border-bottom: 2px solid transparent; cursor: pointer;
  transition: all var(--transition); white-space: nowrap; margin-bottom: -1px;
}
.tab-btn:hover { color: var(--text-primary); }
.tab-btn.active { color: var(--accent); border-bottom-color: var(--accent); font-weight: 600; }
.tab-pane { display: none; }
.tab-pane.active { display: block; }

/* ── Empty state ────────────────────────────────────────── */
.empty-state {
  text-align: center; padding: 3rem 1.5rem; color: var(--text-muted);
}
.empty-state svg { margin: 0 auto 1rem; opacity: .35; }
.empty-state h3 { color: var(--text-secondary); margin-bottom: .5rem; }
.empty-state p { font-size: .875rem; }

/* ── Footer ─────────────────────────────────────────────── */
.footer {
  border-top: 1px solid var(--border); padding: 1.25rem 20px;
  color: var(--text-muted); font-size: .78rem;
}
.footer__inner {
  max-width: 1240px; margin: 0 auto;
  display: flex; justify-content: space-between; gap: 1rem; flex-wrap: wrap;
}

/* ── Login page ─────────────────────────────────────────── */
.login-page {
  min-height: 100vh; display: flex; align-items: center; justify-content: center;
  background: radial-gradient(ellipse at 30% 20%, rgba(61,127,255,.08) 0%, transparent 60%),
              radial-gradient(ellipse at 80% 80%, rgba(0,229,160,.05) 0%, transparent 55%),
              var(--bg);
  padding: 2rem;
}
.login-box {
  background: var(--bg-card); border: 1px solid var(--border);
  border-radius: var(--radius-lg); padding: 2.5rem 2rem; width: 100%; max-width: 420px;
  box-shadow: var(--shadow-lg);
}
.login-box__logo {
  display: flex; align-items: center; gap: 10px; justify-content: center; margin-bottom: 2rem;
}
.login-box__logo svg { width: 40px; height: 40px; }
.login-box h1 { text-align: center; font-size: 1.4rem; margin-bottom: .35rem; }
.login-box p  { text-align: center; font-size: .875rem; margin-bottom: 1.75rem; }
.login-divider {
  display: flex; align-items: center; gap: .75rem; color: var(--text-muted); font-size: .78rem;
  margin: 1.25rem 0;
}
.login-divider::before, .login-divider::after {
  content: ''; flex: 1; height: 1px; background: var(--border);
}
.btn--helix {
  width: 100%; background: linear-gradient(135deg, var(--accent), #6fa3ff);
  color: #fff; justify-content: center; font-size: .95rem; padding: .75rem;
}
.btn--helix:hover { opacity: .9; box-shadow: 0 0 30px var(--accent-glow); }
.btn--google {
  width: 100%; background: var(--bg); border: 1px solid var(--border); color: var(--text-primary);
  justify-content: center; font-size: .95rem; padding: .75rem;
}
.btn--google:hover { border-color: var(--border-light); background: var(--bg-card-2); }

/* ── Dashboard ──────────────────────────────────────────── */
.dashboard-hero {
  background: linear-gradient(135deg, rgba(61,127,255,.12) 0%, rgba(0,229,160,.06) 100%);
  border: 1px solid rgba(61,127,255,.2); border-radius: var(--radius-lg);
  padding: 2rem; margin-bottom: 2rem;
  display: flex; align-items: center; justify-content: space-between; gap: 1.5rem; flex-wrap: wrap;
}
.dashboard-hero h2 { font-size: 1.5rem; margin-bottom: .3rem; }
.dashboard-hero p  { color: var(--text-secondary); max-width: 520px; }

/* ACWR color scale bar */
.acwr-scale {
  display: flex; align-items: center; gap: 0; border-radius: 99px; overflow: hidden;
  height: 12px; flex: 1; min-width: 200px;
}
.acwr-scale__seg { flex: 1; height: 100%; }
.acwr-scale__seg--low     { background: var(--accent); }
.acwr-scale__seg--optimal { background: var(--accent-2); }
.acwr-scale__seg--elevated{ background: var(--accent-warn); }
.acwr-scale__seg--high    { background: var(--accent-danger); }

/* ── Chart placeholder ──────────────────────────────────── */
.chart-area {
  background: var(--bg); border: 1px solid var(--border); border-radius: var(--radius);
  min-height: 240px; display: flex; align-items: center; justify-content: center;
  color: var(--text-muted); font-size: .85rem; position: relative; overflow: hidden;
}

/* ── Modal ──────────────────────────────────────────────── */
.modal-backdrop {
  display: none; position: fixed; inset: 0; background: rgba(0,0,0,.65);
  z-index: 300; align-items: center; justify-content: center; padding: 1rem;
}
.modal-backdrop.open { display: flex; }
.modal {
  background: var(--bg-card); border: 1px solid var(--border); border-radius: var(--radius-lg);
  padding: 1.75rem; width: 100%; max-width: 560px; max-height: 90vh;
  overflow-y: auto; box-shadow: var(--shadow-lg);
}
.modal__header { display: flex; justify-content: space-between; align-items: center; margin-bottom: 1.25rem; }
.modal__header h2 { font-size: 1.1rem; }
.modal__close { background: none; border: none; color: var(--text-muted); cursor: pointer; font-size: 1.4rem; line-height: 1; }
.modal__close:hover { color: var(--text-primary); }
.modal__footer { display: flex; gap: .75rem; justify-content: flex-end; margin-top: 1.5rem; }

/* ── Sidebar layout ─────────────────────────────────────── */
.sidebar-layout { display: grid; grid-template-columns: 240px 1fr; gap: 2rem; align-items: start; }
.sidebar { background: var(--bg-card); border: 1px solid var(--border); border-radius: var(--radius-lg); padding: 1.25rem; }
.sidebar__item { display: flex; align-items: center; gap: .6rem; padding: .5rem .75rem; border-radius: 7px; font-size: .875rem; color: var(--text-secondary); transition: all var(--transition); cursor: pointer; }
.sidebar__item:hover, .sidebar__item.active { background: var(--bg-card-2); color: var(--text-primary); }
.sidebar__item.active { color: var(--accent); font-weight: 600; }
@media (max-width: 800px) { .sidebar-layout { grid-template-columns: 1fr; } .sidebar { display: none; } }

/* ── Animate ────────────────────────────────────────────── */
@keyframes fadeInUp {
  from { opacity: 0; transform: translateY(12px); }
  to   { opacity: 1; transform: translateY(0); }
}
.animate-in { animation: fadeInUp .3s ease both; }
.delay-1 { animation-delay: .05s; }
.delay-2 { animation-delay: .10s; }
.delay-3 { animation-delay: .15s; }
.delay-4 { animation-delay: .20s; }

/* ── Hooper ring ────────────────────────────────────────── */
.hooper-ring { position: relative; display: inline-flex; align-items: center; justify-content: center; }
.hooper-ring svg { transform: rotate(-90deg); }
.hooper-ring__label {
  position: absolute; text-align: center; line-height: 1.2;
}
.hooper-ring__val { font-size: 1.5rem; font-weight: 700; color: var(--text-primary); }
.hooper-ring__max { font-size: .7rem; color: var(--text-muted); }

/* ── Misc ───────────────────────────────────────────────── */
.section-divider { border: none; border-top: 1px solid var(--border); margin: 2rem 0; }
.dot { display: inline-block; width: 8px; height: 8px; border-radius: 50%; }
.dot--green  { background: var(--accent-2); }
.dot--warn   { background: var(--accent-warn); }
.dot--danger { background: var(--accent-danger); }
.dot--blue   { background: var(--accent); }

.tooltip { position: relative; }
.tooltip::after {
  content: attr(data-tip); position: absolute; bottom: calc(100% + 6px); left: 50%;
  transform: translateX(-50%); background: var(--bg-card-2); color: var(--text-primary);
  font-size: .75rem; padding: .3rem .6rem; border-radius: 5px; white-space: nowrap;
  border: 1px solid var(--border); opacity: 0; pointer-events: none; transition: opacity .15s;
}
.tooltip:hover::after { opacity: 1; }

.tag { display: inline-block; padding: .2rem .55rem; background: var(--bg-card-2); border: 1px solid var(--border); border-radius: 5px; font-size: .75rem; color: var(--text-secondary); }

/* ── Pagination ─────────────────────────────────────────── */
.pagination { display: flex; gap: .4rem; align-items: center; justify-content: center; margin-top: 1.5rem; }
.page-link {
  display: inline-flex; align-items: center; justify-content: center;
  width: 34px; height: 34px; border-radius: 7px; font-size: .85rem; font-weight: 500;
  color: var(--text-secondary); border: 1px solid var(--border); background: var(--bg-card);
  transition: all var(--transition);
}
.page-link:hover { background: var(--bg-card-2); color: var(--text-primary); }
.page-link.active { background: var(--accent); color: #fff; border-color: var(--accent); }
