/* ============================================
   🐱 Мир Кошек — Сглаженный дизайн
   ============================================ */

* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

:root {
  --primary: #ff6b9d;
  --primary-light: #ffb3d0;
  --secondary: #c44dff;
  --accent: #4dabf7;
  --accent-light: #d0ebff;
  --success: #51cf66;
  --danger: #ff6b6b;
  --bg: #faf5ff;
  --bg-card: #ffffff;
  --bg-alt: #f3f0ff;
  --text: #2d2b3d;
  --text-secondary: #6e6b7b;
  --shadow-sm: 0 2px 8px rgba(130, 80, 220, 0.08);
  --shadow-md: 0 4px 20px rgba(130, 80, 220, 0.12);
  --shadow-lg: 0 8px 40px rgba(130, 80, 220, 0.16);
  --radius-sm: 12px;
  --radius-md: 20px;
  --radius-lg: 28px;
  --radius-xl: 36px;
}

body {
  font-family: 'Nunito', -apple-system, BlinkMacSystemFont, sans-serif;
  background: var(--bg);
  color: var(--text);
  line-height: 1.7;
  overflow-x: hidden;
}

/* ============================================
   Герой-секция
   ============================================ */
.hero {
  background: linear-gradient(135deg,rgb(151, 151, 151)0%, #ffffff 50%, #ffffff 100%);
  padding: 60px 20px 80px;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 40px;
  flex-wrap: wrap;
  position: relative;
  overflow: hidden;
}

.hero::before {
  content: '';
  position: absolute;
  top: -50%;
  left: -50%;
  width: 200%;
  height: 200%;
  background: radial-gradient(circle, rgba(255,255,255,0.1) 0%, transparent 50%);
  animation: float 15s ease-in-out infinite;
}

@keyframes float {
  0%, 100% { transform: translate(0, 0) rotate(0deg); }
  33% { transform: translate(30px, -30px) rotate(5deg); }
  66% { transform: translate(-20px, 20px) rotate(-5deg); }
}

.hero-content {
  text-align: center;
  max-width: 500px;
  position: relative;
  z-index: 1;
}

.hero-emoji {
  font-size: 64px;
  display: block;
  margin-bottom: 20px;
  animation: bounce 2s ease-in-out infinite;
}

@keyframes bounce {
  0%, 100% { transform: translateY(0); }
  50% { transform: translateY(-10px); }
}

.hero h1 {
  font-size: clamp(2.5rem, 6vw, 4rem);
  font-weight: 800;
  color: white;
  margin-bottom: 16px;
  text-shadow: 0 2px 20px rgba(0,0,0,0.2);
}

.hero-subtitle {
  font-size: 1.2rem;
  color: rgba(255,255,255,0.9);
  margin-bottom: 30px;
}

.btn-hero {
  display: inline-block;
  padding: 16px 36px;
  background: white;
  color: var(--primary);
  text-decoration: none;
  border-radius: var(--radius-xl);
  font-weight: 700;
  font-size: 1.1rem;
  transition: all 0.3s ease;
  box-shadow: 0 4px 20px rgba(0,0,0,0.15);
}

.btn-hero:hover {
  transform: translateY(-3px) scale(1.02);
  box-shadow: 0 8px 30px rgba(0,0,0,0.2);
}

.hero-image {
  max-width: 350px;
  position: relative;
  z-index: 1;
}

.hero-image img {
  width: 100%;
  border-radius: var(--radius-lg);
  box-shadow: 0 20px 60px rgba(0,0,0,0.3);
  transition: transform 0.5s ease;
}

.hero-image img:hover {
  transform: scale(1.03) rotate(1deg);
}

/* ============================================
   Навигация
   ============================================ */
.nav-bar {
  background: var(--bg-card);
  padding: 16px 20px;
  position: sticky;
  top: 0;
  z-index: 100;
  box-shadow: var(--shadow-md);
}

.nav-bar ul {
  display: flex;
  justify-content: center;
  gap: 12px;
  flex-wrap: wrap;
  list-style: none;
}

.nav-bar a {
  display: inline-block;
  padding: 10px 22px;
  text-decoration: none;
  color: var(--text);
  font-weight: 600;
  border-radius: var(--radius-xl);
  transition: all 0.3s ease;
  background: var(--bg);
}

.nav-bar a:hover {
  background: var(--primary-light);
  color: var(--primary);
  transform: translateY(-2px);
}

/* ============================================
   Секции
   ============================================ */
.section {
  padding: 80px 20px;
  max-width: 1200px;
  margin: 0 auto;
}

.section-alt {
  background: var(--bg-alt);
  max-width: 100%;
}

.section-alt > * {
  max-width: 1200px;
  margin-left: auto;
  margin-right: auto;
}

.section-header {
  text-align: center;
  margin-bottom: 50px;
}

.section-icon {
  font-size: 48px;
  display: block;
  margin-bottom: 16px;
}

.section-header h2 {
  font-size: clamp(1.8rem, 4vw, 2.5rem);
  font-weight: 800;
  margin-bottom: 12px;
  background: linear-gradient(135deg, var(--primary), var(--secondary));
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

.section-desc {
  font-size: 1.1rem;
  color: var(--text-secondary);
  max-width: 600px;
  margin: 0 auto;
}

/* ============================================
   Карточки пород
   ============================================ */
.cards-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
  gap: 24px;
  margin-bottom: 40px;
}

.card {
  background: var(--bg-card);
  border-radius: var(--radius-md);
  overflow: hidden;
  box-shadow: var(--shadow-sm);
  transition: all 0.4s ease;
}

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

.card img {
  width: 100%;
  height: 200px;
  object-fit: cover;
}

.card-body {
  padding: 24px;
}

.card-body h3 {
  font-size: 1.3rem;
  font-weight: 700;
  margin-bottom: 10px;
  color: var(--text);
}

.card-body p {
  color: var(--text-secondary);
  margin-bottom: 16px;
  line-height: 1.6;
}

.card-tags {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
}

.tag {
  padding: 6px 14px;
  background: linear-gradient(135deg, var(--primary-light), #e8daff);
  color: var(--primary);
  border-radius: var(--radius-sm);
  font-size: 0.85rem;
  font-weight: 600;
}

/* ============================================
   Таблицы
   ============================================ */
.table-wrapper {
  background: var(--bg-card);
  border-radius: var(--radius-md);
  padding: 32px;
  box-shadow: var(--shadow-md);
  margin-top: 40px;
  overflow-x: auto;
}

.table-title {
  font-size: 1.3rem;
  font-weight: 700;
  margin-bottom: 20px;
  text-align: center;
}

.cat-table {
  width: 100%;
  border-collapse: separate;
  border-spacing: 0;
}

.cat-table th {
  background: linear-gradient(135deg, var(--primary), var(--secondary));
  color: white;
  padding: 14px 20px;
  text-align: left;
  font-weight: 700;
}

.cat-table th:first-child {
  border-radius: var(--radius-sm) 0 0 0;
}

.cat-table th:last-child {
  border-radius: 0 var(--radius-sm) 0 0;
}

.cat-table td {
  padding: 14px 20px;
  border-bottom: 1px solid #f0e6ff;
}

.cat-table tr:last-child td:first-child {
  border-radius: 0 0 0 var(--radius-sm);
}

.cat-table tr:last-child td:last-child {
  border-radius: 0 0 var(--radius-sm) 0;
}

.cat-table tbody tr {
  transition: background 0.3s ease;
}

.cat-table tbody tr:hover {
  background: #f8f4ff;
}

/* ============================================
   Факты
   ============================================ */
.facts-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 24px;
  margin-bottom: 40px;
}

.fact-card {
  background: var(--bg-card);
  border-radius: var(--radius-md);
  padding: 32px;
  box-shadow: var(--shadow-sm);
  transition: all 0.4s ease;
  position: relative;
  overflow: hidden;
}

.fact-card::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  width: 4px;
  height: 100%;
  background: linear-gradient(180deg, var(--primary), var(--secondary));
  border-radius: 0 4px 4px 0;
}

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

.fact-number {
  font-size: 3rem;
  font-weight: 800;
  background: linear-gradient(135deg, var(--primary-light), #e8daff);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  line-height: 1;
  margin-bottom: 12px;
}

.fact-card h3 {
  font-size: 1.2rem;
  font-weight: 700;
  margin-bottom: 10px;
}

.fact-card p {
  color: var(--text-secondary);
  line-height: 1.6;
}

/* ============================================
   Уход за кошками
   ============================================ */
.care-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
  gap: 24px;
  margin-bottom: 40px;
}

.care-card {
  background: var(--bg-card);
  border-radius: var(--radius-md);
  padding: 32px;
  text-align: center;
  box-shadow: var(--shadow-sm);
  transition: all 0.4s ease;
}

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

.care-icon {
  font-size: 48px;
  margin-bottom: 16px;
}

.care-card h3 {
  font-size: 1.2rem;
  font-weight: 700;
  margin-bottom: 10px;
}

.care-card p {
  color: var(--text-secondary);
  line-height: 1.6;
}

/* ============================================
   Питание
   ============================================ */
.food-flex {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 24px;
  margin-bottom: 40px;
}

.food-card {
  border-radius: var(--radius-md);
  padding: 32px;
  box-shadow: var(--shadow-sm);
}

.food-card.good {
  background: linear-gradient(135deg, #d3f9d8, #b2f2bb);
  border: 2px solid #51cf66;
}

.food-card.bad {
  background: linear-gradient(135deg, #ffe3e3, #ffc9c9);
  border: 2px solid #ff6b6b;
}

.food-card h3 {
  font-size: 1.3rem;
  font-weight: 700;
  margin-bottom: 16px;
}

.food-card ul {
  list-style: none;
  padding: 0;
}

.food-card li {
  padding: 10px 0;
  border-bottom: 1px solid rgba(0,0,0,0.08);
  font-size: 1rem;
}

.food-card li:last-child {
  border-bottom: none;
}

/* ============================================
   Галерея
   ============================================ */
.gallery-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  gap: 20px;
}

.gallery-item {
  position: relative;
  border-radius: var(--radius-md);
  overflow: hidden;
  aspect-ratio: 1;
  cursor: pointer;
}

.gallery-item img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.5s ease;
}

.gallery-item:hover img {
  transform: scale(1.1);
}

.gallery-overlay {
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  padding: 20px;
  background: linear-gradient(transparent, rgba(0,0,0,0.7));
  color: white;
  font-weight: 600;
  transform: translateY(100%);
  transition: transform 0.3s ease;
}

.gallery-item:hover .gallery-overlay {
  transform: translateY(0);
}

/* ============================================
   Футер
   ============================================ */
.footer {
  background: linear-gradient(135deg, #2d2b3d, #1a1828);
  color: white;
  text-align: center;
  padding: 50px 20px;
}

.footer-emoji {
  font-size: 48px;
  margin-bottom: 16px;
}

.footer p {
  font-size: 1.1rem;
  margin-bottom: 8px;
}

.footer-small {
  font-size: 0.9rem;
  opacity: 0.7;
}

/* ============================================
   Адаптивность
   ============================================ */
@media (max-width: 768px) {
  .hero {
    flex-direction: column;
    padding: 40px 20px 60px;
    text-align: center;
  }

  .hero-image {
    max-width: 250px;
    order: -1;
  }

  .section {
    padding: 50px 20px;
  }

  .nav-bar ul {
    gap: 8px;
  }

  .nav-bar a {
    padding: 8px 16px;
    font-size: 0.9rem;
  }

  .cat-table {
    font-size: 0.9rem;
  }

  .cat-table th, .cat-table td {
    padding: 10px 12px;
  }

  .gallery-grid {
    grid-template-columns: repeat(2, 1fr);
  }
}

@media (max-width: 480px) {
  .hero h1 {
    font-size: 2rem;
  }

  .cards-grid {
    grid-template-columns: 1fr;
  }

  .facts-grid {
    grid-template-columns: 1fr;
  }

  .care-grid {
    grid-template-columns: 1fr;
  }

  .food-flex {
    grid-template-columns: 1fr;
  }
}