@font-face {
  font-family: 'Inter';
  font-style: normal;
  font-weight: 100 900;
  font-display: swap;
  src: url('/assets/fonts/inter-var.woff2') format('woff2');
}

:root {
  color-scheme: light;
  --bg: #f5f7fa;
  --bg2: #ffffff;
  --card: #ffffff;
  --card2: #f7f9fc;
  --border: #e3e8ef;
  --border2: #cbd5e1;
  --text: #101828;
  --text2: #475467;
  --muted: #98a2b3;
  --primary: #0d9488;
  --primary-strong: #0f766e;
  --primary2: #0891b2;
  --accent: #f59e0b;
  --accent-strong: #b45309;
  --ok: #12b76a;
  --bad: #f04438;
  --grad: linear-gradient(135deg, #0d9488 0%, #0891b2 100%);
  --grad-accent: linear-gradient(135deg, #f59e0b 0%, #fbbf24 100%);
  --shadow: 0 1px 2px rgba(16, 24, 40, 0.05), 0 8px 24px -8px rgba(16, 24, 40, 0.08);
  --shadow-lg: 0 12px 32px -8px rgba(16, 24, 40, 0.16);
  --radius: 14px;
  --nav-h: 62px;
}

[data-theme="dark"] {
  color-scheme: dark;
  --bg: #0a101c;
  --bg2: #0d1524;
  --card: #101a2c;
  --card2: #0d1524;
  --border: #1e2a40;
  --border2: #2c3c58;
  --text: #e7edf6;
  --text2: #a3b1c6;
  --muted: #667891;
  --primary: #2dd4bf;
  --primary-strong: #14b8a6;
  --primary2: #22d3ee;
  --accent: #fbbf24;
  --accent-strong: #f59e0b;
  --shadow: 0 1px 2px rgba(0, 0, 0, 0.4), 0 8px 24px -8px rgba(0, 0, 0, 0.5);
  --shadow-lg: 0 12px 32px -8px rgba(0, 0, 0, 0.6);
}

* { box-sizing: border-box; }

/* Theme-aware scrollbars — no white bars in dark mode */
* {
  scrollbar-width: thin;
  scrollbar-color: var(--border2) transparent;
}
::-webkit-scrollbar { width: 11px; height: 11px; }
::-webkit-scrollbar-track { background: transparent; }
::-webkit-scrollbar-thumb {
  background: var(--border2);
  border-radius: 8px;
  border: 3px solid transparent;
  background-clip: padding-box;
}
::-webkit-scrollbar-thumb:hover { background: var(--muted); background-clip: padding-box; }
::-webkit-scrollbar-corner { background: transparent; }

html { scroll-behavior: smooth; }
body {
  margin: 0;
  font-family: 'Inter', ui-sans-serif, system-ui, -apple-system, 'Segoe UI', Roboto, Arial, sans-serif;
  background: var(--bg);
  color: var(--text);
  line-height: 1.55;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}
::selection { background: color-mix(in srgb, var(--primary) 30%, transparent); }
a { color: var(--primary); text-decoration: none; }
a:hover { color: var(--primary-strong); }
img { max-width: 100%; }
button, input, select { font-family: inherit; }
:focus-visible { outline: 2px solid var(--primary); outline-offset: 2px; border-radius: 6px; }
.container { max-width: 1180px; margin: 0 auto; padding: 0 20px; }

/* ---------- NAV ---------- */
.nav-wrap { position: sticky; top: 12px; z-index: 50; padding: 0 16px; margin-top: 12px; }
.nav {
  max-width: 1180px; margin: 0 auto;
  display: flex; align-items: center; gap: 8px;
  height: var(--nav-h); padding: 0 10px 0 16px;
  background: color-mix(in srgb, var(--bg2) 88%, transparent);
  backdrop-filter: blur(14px); -webkit-backdrop-filter: blur(14px);
  border: 1px solid var(--border);
  border-radius: 999px;
  box-shadow: var(--shadow);
}
.logo { display: inline-flex; align-items: center; gap: 9px; font-weight: 800; font-size: 18px; letter-spacing: -0.5px; color: var(--text); }
.logo:hover { color: var(--text); }
.logo svg { flex: none; }
.logo .lt { color: var(--primary); }
.nav-links { display: flex; gap: 2px; flex: 1; margin-left: 6px; }
.nav-links a {
  padding: 8px 14px; border-radius: 999px;
  color: var(--text2); font-weight: 600; font-size: 14.5px;
}
.nav-links a:hover { background: var(--card2); color: var(--text); }
.nav-links a.active { background: var(--text); color: var(--bg2); }
.nav-search {
  position: relative; display: flex; align-items: center;
}
.nav-search .ns-icon {
  position: absolute; left: 13px; top: 50%; transform: translateY(-50%);
  color: var(--muted); pointer-events: none;
}
.nav-search input {
  width: 200px; padding: 9px 14px 9px 38px;
  border-radius: 999px; border: 1px solid var(--border);
  background: var(--card2); color: var(--text); font-size: 14px; outline: none;
  transition: border-color .15s, width .2s;
}
.nav-search input:focus { border-color: var(--primary); width: 240px; }
.nav-actions { display: flex; gap: 6px; align-items: center; }
.icon-btn {
  width: 40px; height: 40px; border-radius: 999px;
  border: 1px solid var(--border); background: var(--card);
  color: var(--text2); cursor: pointer;
  display: inline-flex; align-items: center; justify-content: center;
  transition: border-color .15s, color .15s;
}
.icon-btn:hover { border-color: var(--primary); color: var(--primary); }
.nav-burger { display: none; }

/* ---------- BUTTONS ---------- */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 9px;
  padding: 13px 26px; border-radius: 999px;
  font-weight: 700; font-size: 15px; border: 1px solid transparent;
  cursor: pointer; transition: transform .15s, box-shadow .15s, background .15s;
  text-decoration: none;
}
.btn-primary { background: var(--primary); color: #fff; box-shadow: 0 6px 16px -4px rgba(13, 148, 136, 0.5); }
.btn-primary:hover { transform: translateY(-1px); color: #fff; background: var(--primary-strong); }
.btn-accent { background: var(--accent); color: #1f1200; box-shadow: 0 6px 16px -4px rgba(245, 158, 11, 0.5); }
.btn-accent:hover { transform: translateY(-1px); color: #1f1200; background: #d97706; }
.btn-ghost { background: var(--card); color: var(--text); border-color: var(--border2); }
.btn-ghost:hover { border-color: var(--primary); color: var(--primary); }

/* ---------- HERO ---------- */
.hero { position: relative; overflow: hidden; padding: 80px 0 60px; text-align: center; }
.hero::before, .hero::after {
  content: ""; position: absolute; border-radius: 50%; filter: blur(100px); pointer-events: none;
}
.hero::before { width: 520px; height: 520px; background: rgba(13, 148, 136, 0.22); top: -220px; left: -140px; }
.hero::after { width: 440px; height: 440px; background: rgba(245, 158, 11, 0.14); bottom: -220px; right: -120px; }
.hero-grid {
  position: absolute; inset: 0; pointer-events: none; opacity: 0.5;
  background-image: radial-gradient(var(--border) 1px, transparent 1px);
  background-size: 26px 26px;
  -webkit-mask-image: radial-gradient(ellipse 70% 60% at 50% 40%, #000 30%, transparent 75%);
  mask-image: radial-gradient(ellipse 70% 60% at 50% 40%, #000 30%, transparent 75%);
}
.hero-inner { position: relative; z-index: 2; }
.eyebrow {
  display: inline-flex; align-items: center; gap: 8px;
  padding: 7px 16px; border-radius: 999px; font-size: 13px; font-weight: 700;
  background: var(--card); border: 1px solid var(--border);
  color: var(--text2); box-shadow: var(--shadow); margin-bottom: 24px;
}
.eyebrow b { color: var(--primary); }
h1.hero-title {
  font-size: clamp(40px, 6.5vw, 68px); line-height: 1.04; margin: 0 0 18px;
  font-weight: 800; letter-spacing: -2.5px;
}
h1.hero-title .teal { color: var(--primary); }
.hero-sub {
  font-size: clamp(16px, 2.2vw, 18.5px); color: var(--text2);
  max-width: 620px; margin: 0 auto 34px;
}
.hero-cta { display: flex; gap: 14px; justify-content: center; flex-wrap: wrap; }
.hero-search { max-width: 540px; margin: 0 auto 26px; position: relative; }
.hero-search input {
  width: 100%; padding: 17px 22px 17px 52px; font-size: 16px;
  border-radius: 999px; border: 1px solid var(--border2);
  background: var(--card); color: var(--text); box-shadow: var(--shadow-lg); outline: none;
}
.hero-search input:focus { border-color: var(--primary); box-shadow: 0 0 0 4px color-mix(in srgb, var(--primary) 16%, transparent); }
.hero-search .s-icon { position: absolute; left: 20px; top: 50%; transform: translateY(-50%); color: var(--muted); }

/* floating pet art */
.pet-float { position: absolute; z-index: 1; pointer-events: none; user-select: none; }
.pet-float img {
  width: 100%; height: auto;
  filter: drop-shadow(0 18px 26px rgba(2, 20, 40, 0.35));
  animation: bob 5.5s ease-in-out infinite;
}
.pet-float.p1 { width: 165px; left: 4%; top: 66px; transform: rotate(-9deg); }
.pet-float.p2 { width: 130px; left: 11%; bottom: 30px; animation-delay: -1.6s; }
.pet-float.p3 { width: 165px; right: 4%; top: 60px; transform: rotate(8deg); }
.pet-float.p4 { width: 130px; right: 11%; bottom: 34px; animation-delay: -3.2s; }
.pet-float.p2 img { animation-delay: -1.6s; }
.pet-float.p3 img { animation-delay: -2.4s; }
.pet-float.p4 img { animation-delay: -4.1s; }
@keyframes bob {
  0%, 100% { transform: translateY(0); }
  50% { transform: translateY(-14px); }
}
@media (max-width: 1060px) { .pet-float { display: none; } }

.powered {
  margin-top: 34px; font-size: 13px; color: var(--muted);
  display: inline-flex; gap: 6px; align-items: center;
  padding: 7px 16px; border: 1px dashed var(--border2); border-radius: 999px;
}
.powered a { font-weight: 700; }

/* stats strip */
.stats { display: flex; gap: 12px; justify-content: center; flex-wrap: wrap; margin-top: 44px; }
.stat {
  background: var(--card); border: 1px solid var(--border); border-radius: 12px;
  padding: 15px 26px; text-align: center; min-width: 148px; box-shadow: var(--shadow);
}
.stat .n { font-size: 25px; font-weight: 800; letter-spacing: -1px; color: var(--primary); font-variant-numeric: tabular-nums; }
.stat .n.amber { color: var(--accent-strong); }
[data-theme="dark"] .stat .n.amber { color: var(--accent); }
.stat .l { font-size: 12px; color: var(--muted); font-weight: 600; text-transform: uppercase; letter-spacing: 0.7px; }

/* ---------- SECTIONS ---------- */
section { padding: 48px 0; }
.section-head { display: flex; align-items: end; justify-content: space-between; gap: 16px; margin-bottom: 22px; flex-wrap: wrap; }
.section-head h2 { font-size: 26px; margin: 0; letter-spacing: -0.8px; font-weight: 800; }
.section-head p { margin: 5px 0 0; color: var(--text2); font-size: 15px; }
.section-head .link { font-weight: 700; font-size: 14.5px; }

/* feature cards */
.features { display: grid; grid-template-columns: repeat(auto-fit, minmax(260px, 1fr)); gap: 16px; }
.feature {
  background: var(--card); border: 1px solid var(--border); border-radius: var(--radius);
  padding: 24px; box-shadow: var(--shadow); transition: transform .15s, border-color .15s;
  display: block; color: var(--text);
}
.feature:hover { transform: translateY(-3px); border-color: var(--primary); color: var(--text); }
.feature .f-icon {
  width: 44px; height: 44px; border-radius: 12px;
  display: flex; align-items: center; justify-content: center;
  background: color-mix(in srgb, var(--primary) 12%, transparent); color: var(--primary);
  margin-bottom: 15px;
}
.feature .f-icon.amber { background: color-mix(in srgb, var(--accent) 15%, transparent); color: var(--accent-strong); }
[data-theme="dark"] .feature .f-icon.amber { color: var(--accent); }
.feature h3 { margin: 0 0 6px; font-size: 17.5px; letter-spacing: -0.3px; font-weight: 750; }
.feature p { margin: 0; color: var(--text2); font-size: 14.5px; }

/* ---------- PET CARDS ---------- */
.pet-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(215px, 1fr)); gap: 15px; }
.pet-card {
  background: var(--card); border: 1px solid var(--border); border-radius: var(--radius);
  padding: 18px 14px 14px; text-align: center; position: relative;
  transition: transform .15s, border-color .15s, box-shadow .15s; color: var(--text);
  display: flex; flex-direction: column; gap: 8px;
}
.pet-card:hover { transform: translateY(-3px); border-color: var(--primary); box-shadow: var(--shadow-lg); color: var(--text); }
.pet-card .rank-chip {
  position: absolute; top: 9px; left: 9px; z-index: 2;
  min-width: 26px; height: 26px; padding: 0 6px; border-radius: 8px;
  background: var(--text); color: var(--bg2);
  font-size: 12.5px; font-weight: 800; display: flex; align-items: center; justify-content: center;
}
.pet-card .rank-chip.gold { background: var(--accent); color: #1f1200; }
.pet-card .rank-chip.silver { background: #98a2b3; color: #fff; }
.pet-card .rank-chip.bronze { background: #b87333; color: #fff; }
.pet-card .img-wrap { height: 96px; display: flex; align-items: center; justify-content: center; }
.pet-card img { max-height: 92px; filter: drop-shadow(0 6px 10px rgba(2, 20, 40, 0.22)); }
.pet-card .p-name { font-weight: 700; font-size: 15px; letter-spacing: -0.2px; line-height: 1.3; }
.pet-card .p-badges { display: flex; gap: 5px; justify-content: center; flex-wrap: wrap; }
.badge {
  font-size: 10px; font-weight: 800; padding: 3px 9px; border-radius: 999px;
  text-transform: uppercase; letter-spacing: 0.5px;
}
.badge.cat-titanic { background: color-mix(in srgb, #7c3aed 14%, transparent); color: #7c3aed; }
.badge.cat-huge { background: color-mix(in srgb, var(--accent) 16%, transparent); color: var(--accent-strong); }
.badge.cat-exclusive { background: color-mix(in srgb, var(--primary) 14%, transparent); color: var(--primary); }
.badge.cat-event { background: color-mix(in srgb, #db2777 13%, transparent); color: #db2777; }
.badge.cat-egg, .badge.cat-gift { background: color-mix(in srgb, var(--primary2) 14%, transparent); color: var(--primary2); }
.badge.cat-regular { background: color-mix(in srgb, var(--muted) 16%, transparent); color: var(--text2); }
.badge.rainbow { background: linear-gradient(90deg, #f43f5e, #f59e0b, #22c55e, #3b82f6, #a855f7); color: #fff; }
.badge.shiny { background: linear-gradient(90deg, #0891b2, #a5f3fc); color: #0e7490; }
.badge.golden { background: linear-gradient(90deg, #f59e0b, #fde68a); color: #78350f; }
.badge.dm { background: #1f2937; color: #e5e7eb; }
.badge.transferred { background: color-mix(in srgb, var(--bad) 14%, transparent); color: var(--bad); }
.p-values { display: flex; flex-direction: column; gap: 5px; width: 100%; }
.p-value-row {
  display: flex; justify-content: space-between; align-items: center; gap: 8px;
  background: var(--card2); border: 1px solid var(--border);
  border-radius: 9px; padding: 6px 10px; font-size: 13px;
}
.p-value-row .v-label { color: var(--text2); font-weight: 600; font-size: 12.5px; }
.p-value-row .v-num { font-weight: 800; color: var(--primary); font-variant-numeric: tabular-nums; }
.p-meta { display: flex; justify-content: space-between; align-items: center; font-size: 12px; color: var(--muted); padding: 0 3px; }
.trend-up { color: var(--ok); font-weight: 700; }
.trend-down { color: var(--bad); font-weight: 700; }
.trend-stable { color: var(--muted); font-weight: 700; }
.demand-wrap { display: flex; align-items: center; gap: 6px; color: var(--text2); font-weight: 600; }
.demand-bar { width: 52px; height: 5px; border-radius: 999px; background: var(--border); overflow: hidden; }
.demand-bar i { display: block; height: 100%; background: var(--primary); border-radius: 999px; }

/* ---------- FILTER BAR ---------- */
.filter-bar {
  background: var(--card); border: 1px solid var(--border); border-radius: var(--radius);
  padding: 15px; box-shadow: var(--shadow); margin-bottom: 20px;
  display: flex; flex-direction: column; gap: 11px;
}
.fb-row { display: flex; gap: 10px; align-items: center; flex-wrap: wrap; }
.fb-search { position: relative; flex: 1; min-width: 220px; }
.fb-search input {
  width: 100%; padding: 11px 16px 11px 42px; border-radius: 11px;
  border: 1px solid var(--border); background: var(--card2); color: var(--text); font-size: 15px; outline: none;
}
.fb-search input:focus { border-color: var(--primary); box-shadow: 0 0 0 3px color-mix(in srgb, var(--primary) 14%, transparent); }
.fb-search .s-icon { position: absolute; left: 14px; top: 50%; transform: translateY(-50%); color: var(--muted); }
.chips { display: flex; gap: 7px; flex-wrap: wrap; }
.chip {
  padding: 7px 14px; border-radius: 999px; font-size: 13px; font-weight: 700;
  border: 1px solid var(--border); background: var(--card2); color: var(--text2);
  cursor: pointer; transition: all .12s; user-select: none;
}
.chip:hover { border-color: var(--primary); color: var(--primary); }
.chip.active { background: var(--primary); border-color: var(--primary); color: #fff; }
.chip.active.amber { background: var(--accent); border-color: var(--accent); color: #1f1200; }
.fb-select {
  padding: 10px 14px; border-radius: 11px; border: 1px solid var(--border);
  background: var(--card2); color: var(--text); font-size: 14px; font-weight: 600; outline: none; cursor: pointer;
}
.result-count { font-size: 13.5px; color: var(--muted); font-weight: 600; margin-left: auto; }

/* ---------- TABLE ---------- */
.table-wrap {
  background: var(--card); border: 1px solid var(--border); border-radius: var(--radius);
  overflow-x: auto; box-shadow: var(--shadow);
}
table.values-table { width: 100%; border-collapse: collapse; font-size: 14.5px; min-width: 640px; }
.values-table th {
  text-align: left; padding: 13px 16px; font-size: 11.5px; text-transform: uppercase;
  letter-spacing: 0.7px; color: var(--muted); border-bottom: 1px solid var(--border);
  background: var(--card2); white-space: nowrap; font-weight: 700;
}
.values-table td { padding: 12px 16px; border-bottom: 1px solid var(--border); vertical-align: middle; }
.values-table tr:last-child td { border-bottom: none; }
.values-table tbody tr:hover { background: var(--card2); }
.values-table .rank { font-weight: 800; color: var(--muted); width: 58px; font-variant-numeric: tabular-nums; }
.values-table .medal {
  display: inline-flex; align-items: center; justify-content: center;
  width: 30px; height: 30px; border-radius: 50%; font-size: 13.5px; font-weight: 800;
}
.medal.gold { background: #fef0c7; color: #b54708; }
.medal.silver { background: #f2f4f7; color: #475467; }
.medal.bronze { background: #fbe9d7; color: #93370d; }
[data-theme="dark"] .medal.gold { background: rgba(245, 158, 11, .18); color: #fbbf24; }
[data-theme="dark"] .medal.silver { background: rgba(152, 162, 179, .18); color: #d0d5dd; }
[data-theme="dark"] .medal.bronze { background: rgba(184, 115, 51, .22); color: #fdba74; }
.pet-cell { display: flex; align-items: center; gap: 12px; }
.pet-cell img { width: 42px; height: 42px; object-fit: contain; }
.pet-cell .pc-name { font-weight: 700; }
.pet-cell .pc-sub { font-size: 12px; color: var(--muted); text-transform: capitalize; }
.val-cell { font-weight: 800; color: var(--primary); font-variant-numeric: tabular-nums; white-space: nowrap; }

/* ---------- CALCULATOR ---------- */
.calc-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 18px; }
.calc-panel {
  background: var(--card); border: 1px solid var(--border); border-radius: var(--radius);
  padding: 20px; box-shadow: var(--shadow); display: flex; flex-direction: column; gap: 12px;
}
.calc-panel h3 { margin: 0; font-size: 16.5px; letter-spacing: -0.3px; display: flex; justify-content: space-between; align-items: center; }
.calc-panel .total { font-size: 19px; font-weight: 800; color: var(--primary); font-variant-numeric: tabular-nums; }
.calc-add { position: relative; }
.calc-add input {
  width: 100%; padding: 11px 14px; border-radius: 11px; border: 1px solid var(--border);
  background: var(--card2); color: var(--text); font-size: 14.5px; outline: none;
}
.calc-add input:focus { border-color: var(--primary); }
.suggest {
  position: absolute; top: calc(100% + 6px); left: 0; right: 0; z-index: 30;
  background: var(--card); border: 1px solid var(--border); border-radius: 12px;
  box-shadow: var(--shadow-lg); max-height: 260px; overflow-y: auto; display: none;
}
.suggest.open { display: block; }
.suggest .s-item { display: flex; align-items: center; gap: 10px; padding: 9px 13px; cursor: pointer; font-size: 14px; }
.suggest .s-item:hover { background: var(--card2); }
.suggest .s-item img { width: 30px; height: 30px; object-fit: contain; }
.suggest .s-item .s-val { margin-left: auto; font-weight: 800; color: var(--primary); font-size: 13px; }
.calc-item {
  display: flex; align-items: center; gap: 10px;
  background: var(--card2); border: 1px solid var(--border);
  border-radius: 11px; padding: 9px 12px;
}
.calc-item img { width: 36px; height: 36px; object-fit: contain; }
.calc-item .ci-info { flex: 1; min-width: 0; }
.calc-item .ci-name { font-weight: 700; font-size: 14px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.calc-item select {
  border: 1px solid var(--border); background: var(--card); color: var(--text2);
  border-radius: 8px; font-size: 12px; padding: 3px 6px; outline: none; cursor: pointer; max-width: 100%;
}
.calc-item .ci-val { font-weight: 800; color: var(--primary); font-size: 14px; font-variant-numeric: tabular-nums; }
.calc-item .ci-x { border: none; background: none; color: var(--muted); cursor: pointer; font-size: 17px; line-height: 1; padding: 2px 5px; }
.calc-item .ci-x:hover { color: var(--bad); }
.calc-item .qty {
  width: 48px; border: 1px solid var(--border); background: var(--card); color: var(--text);
  border-radius: 8px; font-size: 13px; padding: 4px 6px; text-align: center; outline: none;
}
.calc-gems {
  display: flex; align-items: center; gap: 10px;
  background: var(--card2); border: 1px dashed var(--border2);
  border-radius: 11px; padding: 9px 12px;
}
.calc-gems .gicon { display: flex; align-items: center; }
.calc-gems input {
  flex: 1; min-width: 0; border: none; background: none; color: var(--text);
  font-size: 15px; font-weight: 700; outline: none; font-variant-numeric: tabular-nums;
}
.calc-gems input::placeholder { color: var(--muted); font-weight: 500; }
.calc-gems .glabel { color: var(--muted); font-size: 13px; font-weight: 600; }
.calc-gems:focus-within { border-color: var(--primary); border-style: solid; }
.calc-result {
  margin-top: 20px; border-radius: var(--radius); padding: 26px; text-align: center;
  border: 1px solid var(--border); background: var(--card); box-shadow: var(--shadow);
}
.calc-verdict { font-size: 30px; font-weight: 800; letter-spacing: -1px; margin-bottom: 6px; }
.calc-verdict.win { color: var(--ok); }
.calc-verdict.fair { color: var(--primary); }
.calc-verdict.loss { color: var(--bad); }
.calc-diff { font-size: 15px; color: var(--text2); font-weight: 600; }
.calc-both { display: flex; gap: 26px; justify-content: center; margin-top: 14px; flex-wrap: wrap; font-size: 15px; color: var(--text2); }
.calc-both b { color: var(--text); font-variant-numeric: tabular-nums; }

/* ---------- PET DETAIL ---------- */
.detail-hero {
  display: grid; grid-template-columns: 260px 1fr; gap: 30px;
  background: var(--card); border: 1px solid var(--border); border-radius: var(--radius);
  padding: 32px; box-shadow: var(--shadow); margin-bottom: 22px;
}
.detail-hero .d-img {
  display: flex; align-items: center; justify-content: center;
  background: var(--card2); border: 1px dashed var(--border2); border-radius: var(--radius); padding: 20px;
}
.detail-hero .d-img img { max-height: 190px; filter: drop-shadow(0 10px 16px rgba(2, 20, 40, 0.25)); }
.detail-hero h1 { margin: 8px 0 10px; font-size: clamp(26px, 4vw, 34px); letter-spacing: -1px; font-weight: 800; }
.d-badges { display: flex; gap: 7px; flex-wrap: wrap; }
.d-desc { color: var(--text2); font-size: 15.5px; margin: 14px 0 0; }
.d-updated { font-size: 13px; color: var(--muted); margin-top: 14px; }

/* ---------- FAQ ---------- */
.faq { display: flex; flex-direction: column; gap: 11px; max-width: 760px; margin: 0 auto; }
.faq details {
  background: var(--card); border: 1px solid var(--border); border-radius: 12px;
  padding: 17px 22px; box-shadow: var(--shadow);
}
.faq summary {
  font-weight: 700; cursor: pointer; font-size: 15.5px; list-style: none;
  display: flex; justify-content: space-between; align-items: center; gap: 12px;
}
.faq summary::-webkit-details-marker { display: none; }
.faq summary::after { content: ""; width: 10px; height: 10px; border-right: 2.2px solid var(--primary); border-bottom: 2.2px solid var(--primary); transform: rotate(45deg); transition: transform .2s; flex: none; margin-bottom: 4px; }
.faq details[open] summary::after { transform: rotate(225deg); margin-bottom: 0; margin-top: 4px; }
.faq p { margin: 12px 0 0; color: var(--text2); font-size: 15px; }

/* ---------- FOOTER ---------- */
footer { margin-top: 56px; border-top: 1px solid var(--border); background: var(--bg2); }
.footer-inner { display: flex; justify-content: space-between; gap: 32px; padding: 42px 0 34px; flex-wrap: wrap; }
.footer-brand .logo { font-size: 20px; }
.footer-brand p { color: var(--muted); font-size: 14px; max-width: 320px; margin: 10px 0 0; }
.footer-links { display: flex; gap: 52px; flex-wrap: wrap; }
.footer-col h4 { margin: 0 0 12px; font-size: 12.5px; text-transform: uppercase; letter-spacing: 0.8px; color: var(--muted); font-weight: 700; }
.footer-col a { display: block; color: var(--text2); font-size: 14.5px; margin-bottom: 9px; font-weight: 600; }
.footer-col a:hover { color: var(--primary); }
.footer-bottom {
  border-top: 1px solid var(--border); padding: 17px 0; text-align: center;
  color: var(--muted); font-size: 13.5px;
}

/* ---------- MISC ---------- */
.empty {
  text-align: center; padding: 56px 20px; color: var(--text2);
  background: var(--card); border: 1px dashed var(--border2); border-radius: var(--radius);
}
.empty b { display: block; font-size: 18px; color: var(--text); margin-bottom: 6px; }
.loading { text-align: center; padding: 56px 0; color: var(--muted); font-weight: 600; }
.loading::after {
  content: ""; display: block; width: 26px; height: 26px; margin: 14px auto 0;
  border: 3px solid var(--border2); border-top-color: var(--primary); border-radius: 50%;
  animation: spin .7s linear infinite;
}
@keyframes spin { to { transform: rotate(360deg); } }
.page-title { padding: 44px 0 10px; }
.page-title h1 { font-size: clamp(28px, 4vw, 40px); margin: 0; letter-spacing: -1.4px; font-weight: 800; }
.page-title p { color: var(--text2); margin: 8px 0 0; font-size: 16px; }
.breadcrumb { font-size: 13.5px; color: var(--muted); margin-bottom: 10px; }
.breadcrumb a { color: var(--muted); }
.breadcrumb a:hover { color: var(--primary); }

/* ---------- RESPONSIVE ---------- */
@media (max-width: 940px) {
  .nav-search { display: none; }
}
@media (max-width: 860px) {
  .nav-links {
    display: none; position: absolute; top: calc(100% + 10px); left: 0; right: 0;
    flex-direction: column; background: var(--bg2); border: 1px solid var(--border);
    border-radius: 18px; padding: 10px; box-shadow: var(--shadow-lg);
  }
  .nav-links.open { display: flex; }
  .nav-links a { padding: 12px 16px; }
  .nav-burger { display: inline-flex; }
  .nav { position: relative; }
  .calc-grid { grid-template-columns: 1fr; }
  .detail-hero { grid-template-columns: 1fr; text-align: center; }
  .detail-hero .d-badges, .d-desc { justify-content: center; }
  .hero { padding: 54px 0 42px; }
  section { padding: 36px 0; }
  .footer-inner { flex-direction: column; gap: 26px; }
  .footer-links { gap: 34px; }
}
@media (max-width: 480px) {
  .pet-grid { grid-template-columns: repeat(auto-fill, minmax(156px, 1fr)); gap: 10px; }
  .pet-card { padding: 14px 10px 12px; }
  .stat { min-width: 126px; padding: 12px 14px; }
  .hero-cta .btn { width: 100%; max-width: 320px; }
  h1.hero-title { letter-spacing: -1.5px; }
}
