/* =============================================
   BREEDS — shared styles for directory + pages
   ============================================= */

/* ---- Directory hero ---- */
.breeds-hero {
  background: linear-gradient(135deg, #0f172a 0%, #134e4a 100%);
  padding: 120px 0 72px;
  text-align: center;
  color: var(--white);
}

.breeds-hero h1 {
  font-family: var(--font-head);
  font-size: clamp(2rem, 4vw, 3.2rem);
  margin-bottom: 14px;
}

.breeds-hero p {
  color: rgba(255,255,255,.65);
  font-size: 1.1rem;
  max-width: 520px;
  margin: 0 auto 32px;
}

/* Search bar */
.search-wrap {
  max-width: 500px;
  margin: 0 auto;
  position: relative;
}

.search-wrap input {
  width: 100%;
  padding: 16px 52px 16px 20px;
  border-radius: 14px;
  border: none;
  font-family: var(--font-body);
  font-size: 1rem;
  color: var(--dark);
  background: var(--white);
  box-shadow: 0 8px 32px rgba(0,0,0,.25);
  outline: none;
}

.search-wrap::after {
  content: '🔍';
  position: absolute;
  right: 18px;
  top: 50%;
  transform: translateY(-50%);
  font-size: 1rem;
  pointer-events: none;
}

/* ---- Filter bar ---- */
.filter-bar {
  background: var(--white);
  border-bottom: 1px solid var(--border);
  padding: 16px 0;
  position: sticky;
  top: 68px;
  z-index: 100;
}

.filter-row {
  display: flex;
  align-items: center;
  gap: 12px;
  flex-wrap: wrap;
}

.filter-label {
  font-size: .78rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: .08em;
  color: var(--soft);
  flex-shrink: 0;
}

.filter-chips {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
  align-items: center;
}

.chip {
  padding: 6px 16px;
  border-radius: 999px;
  border: 1.5px solid var(--border);
  background: var(--white);
  font-family: var(--font-body);
  font-size: .82rem;
  font-weight: 600;
  color: var(--soft);
  cursor: pointer;
  transition: all .2s;
}

.chip:hover { border-color: var(--teal); color: var(--teal); }
.chip.active { background: var(--teal); color: var(--white); border-color: var(--teal); }

.filter-divider { width: 1px; height: 20px; background: var(--border); }

.results-count {
  margin-left: auto;
  font-size: .82rem;
  color: var(--soft);
  font-weight: 500;
  flex-shrink: 0;
}

/* ---- Breeds grid ---- */
.breeds-section {
  padding: 56px 0 100px;
  background: var(--light);
}

.breeds-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 20px;
}

.breed-card {
  background: var(--white);
  border-radius: 18px;
  border: 1px solid var(--border);
  overflow: hidden;
  cursor: pointer;
  transition: transform .25s, box-shadow .25s;
  text-decoration: none;
  color: inherit;
  display: flex;
  flex-direction: column;
}

.breed-card:hover {
  transform: translateY(-5px);
  box-shadow: var(--shadow-lg);
}

.breed-card.hidden { display: none; }

.breed-emoji-wrap {
  height: 140px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 4rem;
  background: linear-gradient(135deg, var(--teal-light) 0%, #fef3c7 100%);
  position: relative;
  overflow: hidden;
}

.breed-card-real-photo {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: none;
}

.breed-card-emoji-fallback {
  transition: opacity .3s;
}

.size-badge {
  position: absolute;
  top: 10px; right: 10px;
  font-size: .68rem;
  font-weight: 700;
  padding: 3px 10px;
  border-radius: 999px;
  text-transform: uppercase;
  letter-spacing: .06em;
}

.size-badge.small  { background: #dbeafe; color: #1d4ed8; }
.size-badge.medium { background: #fef3c7; color: #92400e; }
.size-badge.large  { background: #dcfce7; color: #166534; }
.size-badge.giant  { background: #fce7f3; color: #9d174d; }

.breed-info {
  padding: 18px;
  flex: 1;
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.breed-info h3 {
  font-size: .95rem;
  font-weight: 700;
  color: var(--dark);
  line-height: 1.3;
}

.breed-info p {
  font-size: .8rem;
  color: var(--soft);
  line-height: 1.5;
  flex: 1;
}

.trait-dots {
  display: flex;
  gap: 12px;
  margin-top: 4px;
}

.trait {
  display: flex;
  flex-direction: column;
  gap: 4px;
  flex: 1;
}

.trait-name {
  font-size: .65rem;
  text-transform: uppercase;
  letter-spacing: .06em;
  color: var(--soft);
  font-weight: 600;
}

.trait-bar {
  height: 4px;
  background: var(--border);
  border-radius: 999px;
  overflow: hidden;
}

.trait-fill {
  height: 100%;
  border-radius: 999px;
  background: var(--teal);
}

.breed-link-row {
  padding: 12px 18px;
  border-top: 1px solid var(--border);
  font-size: .8rem;
  font-weight: 600;
  color: var(--teal);
  display: flex;
  align-items: center;
  justify-content: space-between;
}

/* No results */
.no-results {
  display: none;
  text-align: center;
  padding: 60px 20px;
  color: var(--soft);
  grid-column: 1 / -1;
}
.no-results.show { display: block; }
.no-results .emoji { font-size: 3rem; margin-bottom: 12px; }

/* =============================================
   INDIVIDUAL BREED PAGE
   ============================================= */
.breed-page-hero {
  background: linear-gradient(135deg, #0f172a 0%, #134e4a 100%);
  padding: 120px 0 60px;
  color: var(--white);
}

.breed-page-hero .breadcrumb {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: .8rem;
  color: rgba(255,255,255,.5);
  margin-bottom: 20px;
}

.breed-page-hero .breadcrumb a { color: rgba(255,255,255,.5); transition: color .2s; }
.breed-page-hero .breadcrumb a:hover { color: var(--teal-light); }
.breed-page-hero .breadcrumb span { color: rgba(255,255,255,.25); }

.breed-hero-layout {
  display: grid;
  grid-template-columns: auto 1fr;
  gap: 48px;
  align-items: center;
}

.breed-hero-emoji {
  width: 200px; height: 200px;
  border-radius: 24px;
  background: linear-gradient(135deg, var(--teal-light) 0%, #fef3c7 100%);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 7rem;
  flex-shrink: 0;
  overflow: hidden;
  position: relative;
}

.breed-hero-real-photo {
  width: 100%;
  height: 100%;
  object-fit: cover;
  border-radius: 24px;
  display: none;
  position: absolute;
  inset: 0;
}

.breed-emoji-fallback {
  transition: opacity .3s;
}

.breed-hero-text h1 {
  font-family: var(--font-head);
  font-size: clamp(2rem, 4vw, 3rem);
  margin-bottom: 8px;
}

.breed-hero-text .breed-subtitle {
  color: rgba(255,255,255,.6);
  font-size: 1rem;
  margin-bottom: 24px;
}

.breed-quick-stats {
  display: flex;
  gap: 16px;
  flex-wrap: wrap;
}

.quick-stat {
  background: rgba(255,255,255,.08);
  border: 1px solid rgba(255,255,255,.12);
  border-radius: 12px;
  padding: 12px 18px;
  text-align: center;
  min-width: 100px;
}

.quick-stat-value {
  display: block;
  font-size: 1rem;
  font-weight: 700;
  color: var(--white);
  margin-bottom: 2px;
}

.quick-stat-label {
  font-size: .7rem;
  color: rgba(255,255,255,.5);
  text-transform: uppercase;
  letter-spacing: .06em;
}

/* Breed content layout */
.breed-content-wrap {
  display: grid;
  grid-template-columns: 1fr 300px;
  gap: 40px;
  padding: 60px 0 100px;
  align-items: flex-start;
}

/* Sticky sidebar */
.breed-sidebar {
  position: sticky;
  top: 100px;
  display: flex;
  flex-direction: column;
  gap: 20px;
}

.sidebar-card {
  background: var(--white);
  border: 1px solid var(--border);
  border-radius: 18px;
  padding: 24px;
}

.sidebar-card h4 {
  font-size: .85rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: .08em;
  color: var(--soft);
  margin-bottom: 16px;
}

/* Trait bars in sidebar */
.trait-row {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.trait-item {
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.trait-header {
  display: flex;
  justify-content: space-between;
  font-size: .82rem;
}

.trait-header span:first-child { font-weight: 600; color: var(--dark); }
.trait-header span:last-child { color: var(--soft); }

.trait-bar-bg {
  height: 6px;
  background: var(--border);
  border-radius: 999px;
  overflow: hidden;
}

.trait-bar-fill {
  height: 100%;
  border-radius: 999px;
  background: linear-gradient(90deg, var(--teal) 0%, var(--teal-dark) 100%);
}

/* CTA sidebar card */
.sidebar-cta {
  background: linear-gradient(135deg, var(--teal) 0%, var(--teal-dark) 100%);
  color: var(--white);
  border: none;
}

.sidebar-cta h4 { color: rgba(255,255,255,.7); }
.sidebar-cta p { font-size: .88rem; color: rgba(255,255,255,.85); margin-bottom: 14px; line-height: 1.6; }

.sidebar-cta .btn-white {
  display: block;
  text-align: center;
  background: var(--white);
  color: var(--teal);
  padding: 11px 16px;
  border-radius: 10px;
  font-weight: 700;
  font-size: .88rem;
  transition: opacity .2s;
  margin-bottom: 8px;
}
.sidebar-cta .btn-white:hover { opacity: .92; }

.sidebar-cta .btn-outline-white {
  display: block;
  text-align: center;
  border: 1.5px solid rgba(255,255,255,.4);
  color: rgba(255,255,255,.9);
  padding: 10px 16px;
  border-radius: 10px;
  font-weight: 600;
  font-size: .88rem;
  transition: background .2s;
}
.sidebar-cta .btn-outline-white:hover { background: rgba(255,255,255,.1); }

/* Main content sections */
.breed-main { display: flex; flex-direction: column; gap: 40px; }

.breed-section {
  background: var(--white);
  border-radius: 20px;
  padding: 36px;
  border: 1px solid var(--border);
}

.breed-section h2 {
  font-family: var(--font-head);
  font-size: 1.5rem;
  margin-bottom: 16px;
  color: var(--dark);
  display: flex;
  align-items: center;
  gap: 10px;
}

.breed-section p {
  color: var(--soft);
  line-height: 1.8;
  font-size: .95rem;
  margin-bottom: 12px;
}
.breed-section p:last-child { margin-bottom: 0; }

.breed-section ul {
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 8px;
  margin-top: 12px;
}

.breed-section ul li {
  padding-left: 22px;
  position: relative;
  color: var(--soft);
  font-size: .92rem;
  line-height: 1.6;
}

.breed-section ul li::before {
  content: '✓';
  position: absolute;
  left: 0;
  color: var(--teal);
  font-weight: 700;
}

/* Info grid inside sections */
.info-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 16px;
  margin-top: 16px;
}

.info-box {
  background: var(--light);
  border-radius: 12px;
  padding: 16px;
  border: 1px solid var(--border);
}

.info-box-label {
  font-size: .72rem;
  text-transform: uppercase;
  letter-spacing: .08em;
  color: var(--soft);
  font-weight: 700;
  margin-bottom: 4px;
}

.info-box-value {
  font-size: .95rem;
  font-weight: 600;
  color: var(--dark);
}

/* Health concerns */
.health-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 12px;
}

.health-tag {
  background: #fef2f2;
  color: #dc2626;
  font-size: .78rem;
  font-weight: 600;
  padding: 4px 12px;
  border-radius: 999px;
  border: 1px solid #fecaca;
}

/* Related breeds */
.related-breeds {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 12px;
  margin-top: 16px;
}

.related-card {
  background: var(--light);
  border: 1px solid var(--border);
  border-radius: 14px;
  padding: 16px;
  text-align: center;
  text-decoration: none;
  color: inherit;
  transition: all .2s;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 6px;
}
.related-card:hover { border-color: var(--teal); background: var(--teal-light); }
.related-card .rel-emoji { font-size: 2rem; }
.related-card span { font-size: .82rem; font-weight: 600; color: var(--dark); }

/* Compatibility grid */
.compat-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 12px;
  margin-top: 16px;
}

.compat-item {
  background: var(--light);
  border-radius: 12px;
  padding: 14px;
  text-align: center;
  border: 1px solid var(--border);
}

.compat-icon { font-size: 1.6rem; display: block; margin-bottom: 6px; }
.compat-label { font-size: .75rem; font-weight: 600; color: var(--soft); display: block; margin-bottom: 6px; }

.compat-stars { color: var(--orange); font-size: .85rem; }

/* Travel tip box */
.travel-tip-box {
  background: linear-gradient(135deg, var(--teal-light) 0%, #e0f2fe 100%);
  border-radius: 14px;
  padding: 20px 24px;
  margin-top: 16px;
  border-left: 4px solid var(--teal);
}

.travel-tip-box h4 {
  font-size: .9rem;
  font-weight: 700;
  color: var(--teal-dark);
  margin-bottom: 6px;
}

.travel-tip-box p {
  font-size: .88rem;
  color: var(--teal-dark);
  margin: 0;
  line-height: 1.6;
}

/* ---- Breed Page Tabs ---- */
.breed-tabs-nav {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
  margin-bottom: 24px;
  background: var(--white);
  border: 1px solid var(--border);
  border-radius: 16px;
  padding: 8px;
}

.breed-tab {
  flex: 1;
  min-width: 120px;
  padding: 11px 16px;
  border: none;
  border-radius: 10px;
  background: none;
  font-family: var(--font-body);
  font-size: .85rem;
  font-weight: 600;
  color: var(--soft);
  cursor: pointer;
  transition: all .2s;
  white-space: nowrap;
  text-align: center;
}

.breed-tab:hover { background: var(--light); color: var(--dark); }

.breed-tab.active {
  background: var(--teal);
  color: var(--white);
  box-shadow: 0 3px 12px rgba(13,148,136,.3);
}

.breed-tab-panel { display: none; flex-direction: column; gap: 24px; }
.breed-tab-panel.active { display: flex; }

/* ---- Photo Gallery ---- */
.breed-gallery {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 12px;
  margin-top: 16px;
}

.gallery-photo {
  width: 100%;
  aspect-ratio: 1 / 1;
  object-fit: cover;
  border-radius: 12px;
  background: var(--light);
  display: block;
  transition: transform .25s, box-shadow .25s;
  cursor: pointer;
}

.gallery-photo:hover {
  transform: scale(1.03);
  box-shadow: var(--shadow-lg);
}

/* Lightbox (click to enlarge) */
.lightbox {
  display: none;
  position: fixed;
  inset: 0;
  background: rgba(0,0,0,.88);
  z-index: 2000;
  align-items: center;
  justify-content: center;
  padding: 24px;
}

.lightbox.open { display: flex; }

.lightbox img {
  max-width: 90vw;
  max-height: 88vh;
  object-fit: contain;
  border-radius: 16px;
  box-shadow: 0 24px 80px rgba(0,0,0,.6);
}

.lightbox-close {
  position: absolute;
  top: 20px; right: 24px;
  background: rgba(255,255,255,.15);
  border: none;
  color: white;
  font-size: 1.8rem;
  width: 44px; height: 44px;
  border-radius: 50%;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: background .2s;
}
.lightbox-close:hover { background: rgba(255,255,255,.3); }

/* ---- Responsive ---- */
@media (max-width: 1024px) {
  .breeds-grid { grid-template-columns: repeat(3, 1fr); }
  .breed-content-wrap { grid-template-columns: 1fr; }
  .breed-sidebar { position: static; }
  .breed-sidebar { display: grid; grid-template-columns: 1fr 1fr; }
}

@media (max-width: 768px) {
  .breeds-grid { grid-template-columns: repeat(2, 1fr); }
  .breed-hero-layout { grid-template-columns: 1fr; text-align: center; }
  .breed-hero-emoji { margin: 0 auto; }
  .breed-quick-stats { justify-content: center; }
  .info-grid { grid-template-columns: 1fr; }
  .compat-grid { grid-template-columns: repeat(2, 1fr); }
  .related-breeds { grid-template-columns: repeat(2, 1fr); }
  .breed-sidebar { display: flex; }
  .filter-row { gap: 8px; }
  .results-count { display: none; }
}

@media (max-width: 480px) {
  .breeds-grid { grid-template-columns: 1fr 1fr; }
}
