/* ===== ПЕРЕМЕННЫЕ ===== */
:root{
  --navy:      #12243d;
  --navy-2:    #1c3557;
  --steel:     #5b7ba6;
  --gold:      #c9a94e;
  --gold-soft: #e0c77a;
  --paper:     #e9edf3;
  --ink:       #0b1622;
}

/* ===== БАЗОВЫЕ СБРОСЫ ===== */
*{ margin:0; padding:0; box-sizing:border-box; }
html, body{
  height: 100%;
  overflow: hidden;
}
body{
  font-family: "Segoe UI", "Helvetica Neue", Arial, sans-serif;
  color: var(--paper);
  background: var(--ink);
  letter-spacing:.01em;
}

/* ===== ГЛАВНЫЙ ЭКРАН ===== */
.hero{
  position:relative;
  width: 100%;
  height: 100vh;
  height: 100dvh;
  overflow:hidden;
  
  background:
    linear-gradient(180deg, rgba(8,18,32,.85) 0%, rgba(8,18,32,.95) 100%),
    radial-gradient(circle at 30% 20%, var(--navy-2), var(--ink) 60%);
}

/* Слой чертежной сетки */
.hero::before{
  content:"";
  position:absolute;
  inset:-10%;
  z-index:0;
  background-image: 
    linear-gradient(rgba(91,123,166,.18) 1px, transparent 1px),
    linear-gradient(90deg, rgba(91,123,166,.18) 1px, transparent 1px),
    linear-gradient(rgba(201,169,78,.1) 2px, transparent 2px),
    linear-gradient(90deg, rgba(201,169,78,.1) 2px, transparent 2px);
  background-size: 50px 50px, 50px 50px, 200px 200px, 200px 200px;
  background-position: center center;
  animation: drift-blueprint 60s linear infinite;
  opacity: 1;
}

/* Виньетка */
.hero::after{
  content:"";
  position:absolute; inset:0;
  background: radial-gradient(ellipse at center, transparent 60%, rgba(11,22,34,.7) 100%);
  pointer-events:none;
  z-index:1;
}

/* Контент по центру */
.hero__content{
  position:relative;
  z-index:2;
  height: 100%;
  display:flex;
  flex-direction:column;
  justify-content:center;
  align-items:center;
  padding: 24px 24px 80px; /* Нижний отступ больше, чтобы не наезжать на футер */
  text-align:center;
}

@keyframes drift-blueprint {
  0%   { background-position: 0 0, 0 0, 0 0, 0 0; }
  100% { background-position: 100px 100px, 100px 100px, 400px 400px, 400px 400px; }
}

/* ===== ЧЕРТЕЖНЫЕ ДЕТАЛИ ===== */
.blueprint-decor{
  position:absolute;
  inset:0;
  pointer-events:none;
  z-index:1;
}
.draft-item{
  position:absolute;
  width:350px;
  height:350px;
  opacity:0.4;
  filter: drop-shadow(0 0 10px rgba(91,123,166,0.2));
}
.item-1{
  top:10%;
  left:5%;
  animation: spin-slow 120s linear infinite;
}
.item-2{
  bottom:10%;
  right:5%;
  width:450px;
  height:450px;
  animation: float-y 15s ease-in-out infinite alternate;
}
@keyframes spin-slow {
  from { transform: rotate(0deg); }
  to   { transform: rotate(360deg); }
}
@keyframes float-y {
  from { transform: translateY(0); }
  to   { transform: translateY(-30px); }
}

/* ===== ЛОГОТИП ===== */
.logo-wrap{
  perspective: 900px;
  margin-bottom:24px;
}
.logo{
  width:160px; height:160px;
  transition: transform .5s cubic-bezier(.2,.8,.2,1), filter .5s ease;
  transform-style: preserve-3d;
  will-change: transform, filter;
  cursor: pointer;
}
.logo svg{
  width:100%; height:100%;
  display:block;
  overflow:visible;
  filter: drop-shadow(0 10px 20px rgba(0,0,0,.35));
}
.logo .sunshine{
  opacity:0;
  transition: opacity .35s ease;
  mix-blend-mode: screen;
  pointer-events: none;
}
.logo-wrap:hover .logo{
  transform: rotateX(6deg) rotateY(-10deg) translateZ(20px) scale(1.06);
  filter:
    drop-shadow(0 0 18px rgba(255,245,0,.55))
    drop-shadow(0 0 40px rgba(255,245,0,.25));
}
.logo-wrap:hover .logo .sunshine{ opacity:1; }
.logo-wrap:active .logo{
  transform: rotateX(0) rotateY(0) translateZ(0) scale(1.02);
}

/* ===== НАЗВАНИЕ ===== */
.brand{
  font-size: clamp(1.8rem, 5vw, 3.8rem);
  font-weight:800;
  letter-spacing:.1em;
  text-transform:uppercase;
  line-height:1;
  animation: fadeUp .8s .1s ease both;
}
.brand .accent{ color: var(--gold); }
.tagline{
  margin-top:10px;
  font-size: clamp(.75rem, 1.8vw, .95rem);
  letter-spacing:.4em;
  text-transform:uppercase;
  color: var(--steel);
  animation: fadeUp .8s .2s ease both;
}

/* ===== КОНТАКТЫ ===== */
.contacts{
  margin-top:32px;
  display:flex;
  flex-wrap:wrap;
  justify-content:center;
  gap:12px 40px;
  font-size: clamp(.9rem, 2vw, 1.05rem);
  animation: fadeUp .8s .3s ease both;
}
.contacts a{
  color: var(--paper);
  text-decoration:none;
  position:relative;
  padding:6px 0;
  transition: color .25s;
}
.contacts a::after{
  content:"";
  position:absolute; left:0; bottom:0;
  width:0; height:1px;
  background: var(--gold);
  transition: width .3s ease;
}
.contacts a:hover{ color: var(--gold-soft); }
.contacts a:hover::after{ width:100%; }
.contacts .label{
  color: var(--steel);
  font-size:.72em;
  letter-spacing:.22em;
  text-transform:uppercase;
  display:block;
  margin-bottom:2px;
}

/* ===== ФУТЕР (ПРИБИТ К НИЗУ) ===== */
.footer{
  position: absolute;
  bottom: 0;
  left: 0;
  width: 100%;
  padding: 20px 24px;
  text-align: center;
  z-index: 2;
  font-size: .8rem;
  letter-spacing: .16em;
  text-transform: uppercase;
  color: var(--steel);
  border-top: 1px solid rgba(91,123,166,.18);
  background: linear-gradient(0deg, rgba(11,22,34,.8), transparent);
}
.footer .accent{ color: var(--gold); }

/* ===== АНИМАЦИИ ===== */
@keyframes fadeUp{
  from{ opacity:0; transform: translateY(24px); }
  to  { opacity:1; transform: translateY(0); }
}

/* ===== АДАПТИВ ===== */
/* На невысоких экранах уменьшаем отступы */
@media (max-height: 700px) {
  .logo{ width: 120px; height: 120px; }
  .logo-wrap{ margin-bottom: 16px; }
  .brand{ font-size: clamp(1.5rem, 4vw, 2.8rem); }
  .tagline{ margin-top: 8px; letter-spacing: .3em; }
  .contacts{ margin-top: 20px; gap: 8px 30px; }
  .footer{ padding: 16px 24px; }
  .hero__content { padding-bottom: 60px; }
}

@media (max-height: 550px) {
  .logo{ width: 90px; height: 90px; }
  .logo-wrap{ margin-bottom: 12px; }
  .brand{ font-size: 1.6rem; }
  .tagline{ display: none; }
  .contacts{ margin-top: 16px; font-size: .85rem; }
  .draft-item{ display: none; }
  .footer { padding: 12px 24px; font-size: .7rem; }
  .hero__content { padding-bottom: 40px; }
}

/* ===== ДОСТУПНОСТЬ ===== */
@media (prefers-reduced-motion: reduce){
  *{ animation:none !important; transition:none !important; }
  .logo-wrap:hover .logo{ transform:none; }
  .logo .sunshine{ display:none; }
}