/* ==========================================================================
   1. Тема
   ========================================================================== */
:root {
  --accent: #ffb347;
  --text: #f4f4f4;
  --muted: #b0b0b0;
  --bg: #23272f;
  --block-radius: 22px;
  --block-gradient: linear-gradient(135deg, #1e2229 0%, #292f38 100%);
}

.light-theme {
  --text: #222222;
  --muted: #555555;
  --bg: #f9f9f9;
  --block-gradient: linear-gradient(135deg, #f0f0f0 0%, #e8e8e8 100%);
}

/* ==========================================================================
   2. База и глобальные стили
   ========================================================================== */
*, *::before, *::after {
  box-sizing: border-box;
}

html, body {
  margin: 0;
  padding: 0;
  background: var(--bg);
  color: var(--text);
  font-family: 'Montserrat', Arial, sans-serif;
  min-height: 100vh;
  position: relative;
  overflow-x: hidden;
}

body {
  position: relative;
  z-index: 1;
}

.background-image, .aboutfurry-bg-img {
  pointer-events: none;
  user-select: none;
}

/* ==========================================================================
   3. Основные стилистики сайта
   ========================================================================== */
header {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  width: 100%;
  z-index: 10;
  background: linear-gradient(to bottom, rgba(35, 39, 47, 0.92) 60%, rgba(35, 39, 47, 0.65) 100%);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  display: flex;
  align-items: center;
  justify-content: flex-end;
  padding: 0 32px;
  height: 68px;
  user-select: none;
  border-bottom: 1px solid rgba(80, 80, 80, 0.13);
}

main {
  max-width: 900px;
  margin: 0 auto;
  padding: 110px 24px 0 24px;
  position: relative;
  z-index: 2;
}

.content-wrapper {
  width: 100%;
}

.site-footer {
  text-align: center;
  color: var(--muted);
  margin: 60px 0 24px 0;
  font-size: 0.97rem;
  z-index: 2;
  position: relative;
}

/* ==========================================================================
   4. Отдел компонентов
   ========================================================================== */

/* --- Хэдер-меню --- */
nav.menu {
  display: flex;
  gap: 28px;
}

.menu-link {
  font-size: 1.09rem;
  font-weight: 600;
  text-decoration: none;
  color: var(--text);
  position: relative;
  white-space: nowrap;
}

.menu-link:hover, .menu-link:focus-visible {
  color: var(--accent);
  outline: none;
}

/* --- Контент страниц --- */
.site-title {
  text-align: center;
  font-size: 2.1rem;
  font-weight: 700;
  letter-spacing: 2px;
  margin: 0 0 0.2em 0;
  color: var(--accent);
  line-height: 1.1;
  user-select: none;
  opacity: 0;
  animation: fadeInUp 0.8s cubic-bezier(0.4, 0, 0.2, 1) 0.1s forwards;
}

.subtitle {
  text-align: center;
  color: var(--muted);
  font-size: 1.22rem;
  margin-bottom: 38px;
  letter-spacing: 0.01em;
  opacity: 0;
  animation: fadeInUp 0.8s cubic-bezier(0.4, 0, 0.2, 1) 0.3s forwards;
}

.main-text {
  font-size: 1.15rem;
  line-height: 1.7;
  letter-spacing: 0.01em;
  margin-bottom: 48px;
  opacity: 0;
  animation: fadeInUp 0.8s cubic-bezier(0.4, 0, 0.2, 1) 0.4s forwards;
  max-width: 760px;
  margin-left: auto;
  margin-right: auto;
  overflow-wrap: break-word;

}

.main-text strong {
  color: var(--accent);
  font-weight: 700;
}


/* --- Другие компоненты --- */
.links-block {
  color: var(--muted);
  font-size: 1.03rem;
  margin-bottom: 44px;
  text-align: center;
}

.footer-link {
  color: inherit;
  text-decoration: none;
  font-weight: 600;
  transition: color 0.2s ease;
}

.footer-link:hover, .footer-link:focus-visible {
  color: var(--accent);
  outline: none;
}

.aboutfurry-bg-img {
  position: absolute;
  width: 480px;
  height: auto;
  z-index: 1;
  filter: invert(1) brightness(1.15) drop-shadow(0 4px 24px #0008);
  opacity: 0.2;
}
.aboutfurry-bg-img.left { top: 120px; left: 0; }
.aboutfurry-bg-img.right { top: 50%; right: 0; transform: translateY(-50%) scaleX(-1); }

.background-image {
  display: none;
  width: 400px;
  height: auto;
  filter: grayscale(1) brightness(1) invert(-1);
  mix-blend-mode: lighten;
}

/* ==========================================================================
   5. Анимации на сайте
   ========================================================================== */
@keyframes fadeInUp {
  from { opacity: 0; transform: translateY(30px); }
  to { opacity: 1; transform: translateY(0); }
}

.reveal {
  opacity: 0;
  transform: translateY(40px);
  transition: opacity 0.6s cubic-bezier(0.4, 0, 0.2, 1), transform 0.6s cubic-bezier(0.4, 0, 0.2, 1);
  will-change: opacity, transform;
}

.reveal.visible {
  opacity: 1;
  transform: none;
}

/* ==========================================================================
   6. Настройки белой темы
   ========================================================================== */
.light-theme header {
  background: rgba(255, 255, 255, 0.85);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  border-bottom-color: rgba(150, 150, 150, 0.2);
}

.light-theme .background-image {
  filter: grayscale(0) brightness(0.8) invert(0);
  mix-blend-mode: multiply;
}

.light-theme .aboutfurry-bg-img {
  filter: grayscale(1) brightness(0.5) invert(0);
  mix-blend-mode: multiply;
  opacity: 0.15;
}

/* ==========================================================================
   7. Адаптивности
   ========================================================================== */
@media (min-width: 1360px) {
  body.homepage main {
    max-width: 1300px;
  }
  body.homepage .background-image {
    display: block;
    position: absolute;
    top: 222px;
    left: 46%;
    margin-left: calc(380px + 20px);
    animation: fadeInUp 1.2s cubic-bezier(0.4, 0, 0.2, 1) 0.5s forwards;
    opacity: 0;
  }
}

@media (max-width: 700px) {
  header {
    padding: 0 10px;
    height: 54px;
    justify-content: center;
  }
  nav.menu { gap: 12px; }
  main { padding: 74px 12px 0 12px; }
  .site-title { font-size: 1.8rem; }
  .main-text { font-size: 1.01rem; }
  .links-block { font-size: 0.95rem; }
  .aboutfurry-bg-img { width: 180px; opacity: 0.3; }
  .aboutfurry-bg-img.left { top: 30px; }
  .aboutfurry-bg-img.right { top: 1500px; right: 12px; transform: none; }
}

@media (max-width: 360px) {
  nav.menu { gap: 8px; }
  .menu-link { font-size: 0.9rem; }
}