/* === ПЕРЕМЕННЫЕ === */
:root {
  --black: #0a0a0a;
  --dark: #111111;
  --surface: #1a1a1a;
  --surface-hover: #222222;
  --gold: #c9a84c;
  --gold-light: #e4c97a;
  --gold-dim: rgba(201, 168, 76, 0.3);
  --white: #f0ece4;
  --white-dim: rgba(240, 236, 228, 0.6);
  --white-faint: rgba(240, 236, 228, 0.08);
  --font-display: 'Playfair Display', Georgia, serif;
  --font-body: 'Playfair Display', Georgia, serif;
  --radius: 8px;
}

/* === СБРОС === */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; }

body {
  background-color: #1a1816;
  color: var(--white);
  font-family: var(--font-body);
  font-size: 18px;
  line-height: 1.7;
  min-height: 100vh;
  position: relative;
}

/* Фоновая текстура — фиксированная, на всех страницах */
body::before {
  content: '';
  position: fixed;
  inset: 0;
  background-image: url("assets/images/bg-texture.webp");
  background-size: cover;
  background-position: center;
  z-index: -2;
}

/* Тёмный оверлей — только на подстраницах (не на главной) */
body:not(.page-home)::after {
  content: '';
  position: fixed;
  inset: 0;
  background: rgba(8, 6, 5, 0.72);
  z-index: -1;
}

/* === НАВИГАЦИЯ === */
.navbar {
  position: fixed;
  top: 0; left: 0; right: 0;
  z-index: 100;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 48px;
  height: 72px;
  background: rgba(10,10,10,0.92);
  backdrop-filter: blur(12px);
  border-bottom: 1px solid rgba(201,168,76,0.12);
}

.nav-logo {
  display: flex;
  align-items: center;
  gap: 14px;
  text-decoration: none;
}

.logo-frame {
  width: 44px;
  height: 44px;
  border: 1.5px solid var(--gold);
  display: flex;
  align-items: center;
  justify-content: center;
  position: relative;
  border-radius: 4px;
}
.logo-frame::before, .logo-frame::after {
  content: '';
  position: absolute;
  width: 6px; height: 6px;
  border: 1px solid var(--gold);
}
.logo-frame::before { top: -3px; left: -3px; border-right: none; border-bottom: none; }
.logo-frame::after  { bottom: -3px; right: -3px; border-left: none; border-top: none; }

.logo-inner {
  font-family: var(--font-display);
  font-size: 14px;
  color: var(--gold);
  letter-spacing: 1px;
}

.logo-text {
  font-family: var(--font-display);
  font-size: 15px;
  letter-spacing: 4px;
  color: var(--white);
}

.nav-links {
  display: flex;
  list-style: none;
  gap: 40px;
}

.nav-links a {
  font-family: var(--font-display);
  font-size: 14px;
  letter-spacing: 3px;
  color: var(--white-dim);
  text-decoration: none;
  transition: color 0.2s;
  position: relative;
}
.nav-links a::after {
  content: '';
  position: absolute;
  bottom: -4px; left: 0; right: 100%;
  height: 1px;
  background: var(--gold);
  transition: right 0.3s ease;
}
.nav-links a:hover,
.nav-links a.active {
  color: var(--white);
}
.nav-links a:hover::after,
.nav-links a.active::after {
  right: 0;
}

/* === HERO === */
.hero {
  height: calc(100vh - 68px); /* 68px = высота категорий */
  padding-top: 72px;
  display: grid;
  grid-template-columns: minmax(0, 520px) minmax(0, 1fr) minmax(0, 380px);
  grid-template-rows: 1fr;
  position: relative;
  overflow: hidden;
}

/* Градиентные переходы сверху и снизу hero */
.hero::before {
  content: '';
  position: absolute;
  top: 72px; left: 0; right: 0;
  height: 80px;
  background: linear-gradient(to bottom, rgba(8,6,5,0.85), transparent);
  z-index: 3;
  pointer-events: none;
}

.hero::after {
  content: '';
  position: absolute;
  bottom: 0; left: 0; right: 0;
  height: 80px;
  background: linear-gradient(to top, rgba(8,6,5,0.85), transparent);
  z-index: 3;
  pointer-events: none;
}

.hero-artwork {
  position: relative;
  z-index: 2;
  grid-column: 1;
  max-width: 560px;
}

.circles-composition {
  position: relative;
  width: 100%;
  height: 100%;
  min-height: 670px;
  display: flex;
  align-items: center;
  transform: scale(1.1) translate(-20px, -40px);
  transform-origin: top left;
}


/* === PNG-элементы композиции (рамки от мамы) === */
.comp-img {
  position: absolute;
  height: auto;
  pointer-events: none;
  user-select: none;
}

.comp-img:nth-child(1) { animation: fadeUp 0.9s ease 0.05s both; }
.comp-img:nth-child(2) { animation: fadeUp 0.9s ease 0.15s both; }
.comp-img:nth-child(3) { animation: fadeUp 0.9s ease 0.25s both; }
.comp-img:nth-child(4) { animation: fadeUp 0.9s ease 0.35s both; }
.comp-img:nth-child(5) { animation: fadeUp 0.9s ease 0.45s both; }
.comp-img:nth-child(6) { animation: fadeUp 0.9s ease 0.55s both; }
.comp-img:nth-child(7) { animation: fadeUp 0.9s ease 0.65s both; }
.comp-img:nth-child(8) { animation: fadeUp 0.9s ease 0.75s both; }
.comp-img:nth-child(9) { animation: fadeUp 0.9s ease 0.85s both; }


/* === HERO CONTENT (центр) === */
.hero-content {
  min-width: 0;
  position: relative;
  z-index: 3;
  grid-column: 2;
  display: flex;
  flex-direction: column;
  justify-content: center;
  padding: 60px 40px;
}

/* ARTFLYSTORY над заголовком */
.hero-brand {
  display: block;
  font-family: var(--font-display);
  font-size: 18px;
  letter-spacing: 8px;
  color: var(--gold);
  margin-bottom: 16px;
}

.hero-title {
  font-family: var(--font-display);
  font-size: clamp(38px, 3.8vw, 56px);
  font-weight: 700;
  line-height: 1.0;
  color: var(--white);
  letter-spacing: 2px;
  margin-bottom: 20px;
  text-shadow: 0 2px 20px rgba(0,0,0,0.5);
}

.hero-title-group {
  display: inline-block;
}

.hero-subtitle {
  font-family: var(--font-body);
  color: var(--white-dim);
  letter-spacing: 2px;
  text-transform: uppercase;
  display: block;
  white-space: nowrap;
  margin-bottom: 40px;
  /* font-size подбирается JS-ом по ширине ЭЛЕГАНТНОСТЬ */
}

.hero-buttons {
  display: flex;
  gap: 16px;
  flex-wrap: wrap;
}

/* === КНОПКИ === */
.btn {
  display: inline-block;
  font-family: var(--font-display);
  font-size: 14px;
  letter-spacing: 3px;
  padding: 14px 32px;
  text-decoration: none;
  cursor: pointer;
  border: none;
  transition: all 0.25s ease;
  border-radius: 6px;
}

.btn-gold {
  background: var(--gold);
  color: var(--black);
  font-weight: 700;
}
.btn-gold:hover {
  background: var(--gold-light);
  transform: translateY(-1px);
  box-shadow: 0 6px 20px rgba(201,168,76,0.35);
}

.btn-outline {
  background: transparent;
  color: var(--white);
  border: 1px solid rgba(240,236,228,0.4);
}
.btn-outline:hover {
  border-color: var(--white);
  background: var(--white-faint);
}

.btn-full { width: 100%; text-align: center; }

/* === ФОРМА СПРАВА === */
.hero-form {
  position: relative;
  z-index: 3;
  grid-column: 3;
  background: rgba(10,8,8,0.45);
  backdrop-filter: blur(16px);
  border-left: 1px solid rgba(201,168,76,0.2);
  padding: 48px 36px;
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-self: stretch;
}

.form-title {
  font-family: var(--font-display);
  font-size: 26px;
  font-weight: 400;
  color: var(--white);
  margin-bottom: 8px;
  letter-spacing: 1px;
}

.form-subtitle {
  font-size: 15px;
  color: var(--white-dim);
  margin-bottom: 28px;
  line-height: 1.5;
}

.form-group {
  margin-bottom: 16px;
}

.form-group label {
  display: block;
  font-family: var(--font-display);
  font-size: 14px;
  letter-spacing: 2px;
  color: var(--white-dim);
  margin-bottom: 6px;
}

.form-group input,
.form-group textarea {
  width: 100%;
  background: rgba(255,255,255,0.06);
  border: 1px solid rgba(255,255,255,0.12);
  color: var(--white);
  padding: 10px 14px;
  font-family: var(--font-body);
  font-size: 16px;
  outline: none;
  transition: border-color 0.2s;
  resize: none;
  border-radius: var(--radius);
}

.form-group input:focus,
.form-group textarea:focus {
  border-color: rgba(201,168,76,0.5);
}

/* === КАТЕГОРИИ === */
.categories {
  position: relative;
  z-index: 2;
  display: flex;
  height: 68px;
  border-top: 1px solid rgba(201,168,76,0.15);
  background: rgba(10,10,10,0.97);
}

.category-item {
  flex: 1;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 0 16px;
  font-family: var(--font-display);
  font-size: 10px;
  letter-spacing: 3px;
  color: var(--white);
  text-decoration: none;
  border-right: 1px solid rgba(201,168,76,0.12);
  transition: all 0.25s ease;
  text-align: center;
}
.category-item:last-child { border-right: none; }

.category-item:hover {
  color: var(--gold);
  background: rgba(201,168,76,0.05);
}

/* === АНИМАЦИИ ПОЯВЛЕНИЯ === */
@keyframes fadeUp {
  from { opacity: 0; transform: translateY(20px); }
  to   { opacity: 1; transform: translateY(0); }
}

.hero-brand    { animation: fadeUp 0.8s ease 0.1s both; }
.hero-title    { animation: fadeUp 0.8s ease 0.2s both; }
.hero-subtitle { animation: fadeUp 0.8s ease 0.4s both; }
.hero-buttons  { animation: fadeUp 0.8s ease 0.6s both; }
.hero-form     { animation: fadeUp 0.8s ease 0.3s both; }

.art-circle:nth-child(1) { animation: fadeUp 1s ease 0.1s both; }
.art-circle:nth-child(2) { animation: fadeUp 1s ease 0.2s both; }
.art-circle:nth-child(3) { animation: fadeUp 1s ease 0.3s both; }
.art-circle:nth-child(4) { animation: fadeUp 1s ease 0.4s both; }
.art-circle:nth-child(5) { animation: fadeUp 1s ease 0.5s both; }

/* === СНОСКА-ЗАКАЗ === */
.order-note {
  padding-top: 72px;
  text-align: right;
  padding: 72px 48px 10px;
  border-bottom: 1px solid rgba(201, 168, 76, 0.12);
}

.order-note p {
  font-family: var(--font-body);
  font-size: 14px;
  color: var(--white-dim);
  letter-spacing: 0.5px;
  line-height: 1.5;
  margin: 0;
}

.order-note a {
  color: var(--gold);
  text-decoration: none;
  letter-spacing: 0.5px;
}

.order-note a:hover { text-decoration: underline; }
