/* ═══════════════════════════════════════════════════════════
   Cutest Dogs Guide — warm/playful dog theme
   ═══════════════════════════════════════════════════════════ */

:root {
  --color-bg: #fff8f0;
  --color-surface: #ffffff;
  --color-surface-elevated: #fff0e0;
  --color-border: #f0dcc0;
  --color-border-hover: #e17055;
  --color-primary: #e17055;
  --color-primary-hover: #d05a40;
  --color-primary-muted: rgba(225, 112, 85, 0.1);
  --color-text: #2d3436;
  --color-text-heading: #2d3436;
  --color-text-muted: #636e72;
  --color-text-dim: #999;
  --color-danger: #ef4444;
  --color-warning: #f59e0b;
  --color-success: #22c55e;
  --color-info: #e17055;
  --radius-sm: 6px;
  --radius: 10px;
  --radius-lg: 16px;
  --radius-xl: 20px;
  --font: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen, Ubuntu, sans-serif;
  --ease-out: cubic-bezier(0.16, 1, 0.3, 1);
  --shadow-sm: 0 1px 3px rgba(0,0,0,0.06);
  --shadow: 0 2px 12px rgba(0,0,0,0.08);
  --shadow-lg: 0 8px 32px rgba(0,0,0,0.1);
}

/* ═══ Reset ═══ */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; }
body {
  font-family: var(--font);
  background: var(--color-bg);
  color: var(--color-text);
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
}

.skip-link {
  position: absolute; top: -100px; left: 16px;
  background: var(--color-primary); color: #fff;
  padding: 10px 20px; border-radius: 0 0 8px 8px;
  z-index: 1000; font-weight: 600; text-decoration: none; font-size: 14px;
}
.skip-link:focus { top: 0; }
.sr-only { position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip: rect(0,0,0,0); white-space: nowrap; border: 0; }

/* ═══ Navigation ═══ */
.nav-bar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 24px;
  height: 56px;
  background: color-mix(in srgb, var(--color-surface) 90%, transparent);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border-bottom: 1px solid var(--color-border);
  position: sticky;
  top: 0;
  z-index: 100;
}
.nav-brand {
  font-size: 1.15rem;
  font-weight: 700;
  color: var(--color-text-heading);
  text-decoration: none;
}
.nav-brand:hover { color: var(--color-primary); }
.nav-links { display: flex; gap: 2px; align-items: center; }
.nav-links a {
  color: var(--color-text-muted);
  text-decoration: none;
  font-size: 0.82rem;
  padding: 6px 12px;
  border-radius: var(--radius-sm);
  transition: all .2s var(--ease-out);
  white-space: nowrap;
}
.nav-links a:hover { color: var(--color-text); background: var(--color-primary-muted); }
.nav-links a.active { color: var(--color-primary); background: var(--color-primary-muted); font-weight: 600; }
.nav-toggle { display: none; background: none; border: none; color: var(--color-text); font-size: 1.4rem; cursor: pointer; padding: 4px 8px; }

/* ═══ Layout ═══ */
.container { max-width: 960px; margin: 0 auto; padding: 0 20px; width: 100%; }
.content-section { flex: 1; padding-bottom: 60px; }

/* ═══ Header Hero ═══ */
header.hero {
  background: linear-gradient(135deg, #f7d794, #f8c291);
  padding: 60px 0 50px;
  text-align: center;
}
header.hero h1 { font-size: 2em; color: #2d3436; margin-bottom: 12px; }
header.hero p { font-size: 1.05em; color: #636e72; max-width: 600px; margin: 0 auto; }
header.hero .count { display: inline-block; background: rgba(255,255,255,0.5); padding: 4px 16px; border-radius: 20px; font-size: 0.9em; margin-bottom: 10px; color: #555; }

/* ═══ TOC ═══ */
.toc { background: #f8f9fa; padding: 25px 0; border-bottom: 1px solid #eee; }
.toc h2 { text-align: center; margin-bottom: 12px; font-size: 1.1em; color: #555; }
.toc-list { display: flex; flex-wrap: wrap; gap: 6px; justify-content: center; }
.toc-list a { display: inline-block; padding: 5px 12px; background: #fff; border: 1px solid #ddd; border-radius: 20px; color: #2d3436; text-decoration: none; font-size: 0.85em; transition: all .2s; }
.toc-list a:hover { background: #f7d794; border-color: #f7d794; }

/* ═══ Intro ═══ */
.intro { padding: 35px 0 25px; }
.intro p { max-width: 780px; margin: 0 auto; font-size: 1em; color: #555; }

/* ═══ Breed Cards ═══ */
.breed-cards { display: grid; gap: 30px; padding: 10px 0 35px; }
.breed-card { background: #fafafa; border-radius: 12px; padding: 25px; border: 1px solid #eee; scroll-margin-top: 60px; }
.breed-card h2 { font-size: 1.3em; margin-bottom: 5px; display: flex; align-items: center; gap: 8px; }
.breed-card .rank { display: inline-block; background: #f7d794; color: #2d3436; width: 26px; height: 26px; text-align: center; line-height: 26px; border-radius: 50%; font-size: 0.8em; font-weight: 700; flex-shrink: 0; }
.breed-card .stars { color: #f5a623; letter-spacing: 1px; margin-bottom: 8px; font-size: 0.9em; }
.breed-card .meta { display: flex; flex-wrap: wrap; gap: 6px; margin: 8px 0 10px; }
.breed-card .meta span { background: #e8f4f8; padding: 3px 10px; border-radius: 12px; font-size: 0.8em; color: #2d3436; }
.breed-card p { color: #555; font-size: 0.93em; }
.breed-img { width: 100%; height: 180px; object-fit: cover; border-radius: 8px; margin-bottom: 12px; }
.detail-link { margin-top: 10px; }
.detail-link a { color: #e17055; text-decoration: none; font-size: 0.88em; font-weight: 500; }
.detail-link a:hover { text-decoration: underline; }

/* ═══ Comparison Table ═══ */
.comparison { padding: 35px 0; }
.comparison h2 { text-align: center; margin-bottom: 18px; font-size: 1.2em; }
.comparison .table-wrapper { overflow-x: auto; }
.comparison table { width: 100%; border-collapse: collapse; font-size: 0.82em; min-width: 600px; }
.comparison th, .comparison td { padding: 8px 6px; text-align: left; border-bottom: 1px solid #eee; }
.comparison th { background: #f7d794; font-weight: 600; font-size: 0.85em; white-space: nowrap; }
.comparison tr:hover { background: #f8f9fa; }

/* ═══ FAQ ═══ */
.faq { padding: 35px 0; }
.faq h2 { text-align: center; margin-bottom: 20px; font-size: 1.2em; }
.faq-item { margin-bottom: 8px; }
.faq-item details { background: #f8f9fa; border-radius: 8px; }
.faq-item summary { padding: 12px 16px; cursor: pointer; font-weight: 600; font-size: 0.95em; list-style: none; display: flex; align-items: center; gap: 8px; }
.faq-item summary::-webkit-details-marker { display: none; }
.faq-item summary::before { content: '▶'; font-size: 0.75em; transition: transform .2s; }
.faq-item details[open] summary::before { transform: rotate(90deg); }
.faq-item .answer { padding: 0 16px 12px; color: #555; font-size: 0.9em; }

/* ═══ Footer ═══ */
.site-footer {
  background: #2d3436;
  color: #aaa;
  padding: 32px 24px;
  text-align: center;
  margin-top: auto;
}
.footer-inner {
  max-width: 960px;
  margin: 0 auto;
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}
.footer-links { display: flex; gap: 16px; flex-wrap: wrap; justify-content: center; }
.footer-links a { color: #aaa; text-decoration: none; font-size: 0.85rem; }
.footer-links a:hover { color: #fff; }
.footer-copy { color: #aaa; font-size: 0.82em; }

/* ═══ Back to Top ═══ */
.back-to-top {
  position: fixed; bottom: 24px; right: 24px; z-index: 50;
  width: 44px; height: 44px; border-radius: 50%;
  background: var(--color-primary); color: #fff; border: none; cursor: pointer;
  font-size: 18px; display: flex; align-items: center; justify-content: center;
  opacity: 0; transform: translateY(12px); pointer-events: none;
  transition: all .25s var(--ease-out); box-shadow: var(--shadow);
}
.back-to-top.visible { opacity: 1; transform: translateY(0); pointer-events: auto; }
.back-to-top:hover { background: var(--color-primary-hover); transform: translateY(-3px); }

/* ═══ Responsive ═══ */
@media (max-width: 768px) {
  .nav-links { display: none; }
  .nav-links.open { display: flex; flex-wrap: wrap; position: absolute; top: 56px; left: 0; right: 0; padding: 12px 24px 16px; background: var(--color-surface); border-bottom: 1px solid var(--color-border); gap: 4px; }
  .nav-toggle { display: block; }
  header.hero h1 { font-size: 1.4em; }
  .breed-card { padding: 16px; }
  .breed-img { height: 150px; }
  .footer-inner { flex-direction: column; text-align: center; }
}
@media (max-width: 480px) {
  .nav-bar { padding: 0 16px; }
  .nav-brand { font-size: 1rem; }
}
