.shell {
  width: min(100% - 2.5rem, var(--shell));
  margin-inline: auto;
}

main { display: block; }

section { position: relative; }

.band {
  padding: clamp(4rem, 9vw, 7.5rem) 0;
}

.band-tight { padding: clamp(3rem, 6vw, 4.5rem) 0; }

.band-line { border-top: 1px solid var(--line); }

.site-header {
  position: sticky;
  top: 0;
  z-index: 60;
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
  background: rgba(4, 6, 12, 0.72);
  border-bottom: 1px solid transparent;
  transition: border-color 0.25s ease, background 0.25s ease;
}

.site-header.is-stuck {
  border-bottom-color: var(--line);
  background: rgba(4, 6, 12, 0.92);
}

.header-inner {
  display: flex;
  align-items: center;
  gap: 1.5rem;
  height: 74px;
}

.brand {
  display: flex;
  align-items: center;
  gap: 0.65rem;
  color: var(--text);
  flex-shrink: 0;
}

.brand img {
  filter: drop-shadow(0 0 12px rgba(59, 130, 246, 0.55));
}

.brand-name {
  font-family: var(--f-head);
  font-weight: 700;
  font-size: 1.35rem;
  letter-spacing: 0.01em;
}

.nav {
  display: flex;
  align-items: center;
  gap: 0.35rem;
  margin-left: auto;
}

.nav a {
  position: relative;
  padding: 0.5rem 0.85rem;
  color: var(--text-soft);
  font-size: 0.94rem;
  font-weight: 500;
  border-radius: var(--r-sm);
}

.nav a::after {
  content: "";
  position: absolute;
  left: 0.85rem;
  right: 0.85rem;
  bottom: 0.15rem;
  height: 2px;
  background: var(--accent);
  transform: skewX(var(--slant)) scaleX(0);
  transform-origin: left;
  transition: transform 0.24s ease;
}

.nav a:hover { color: var(--text); }
.nav a:hover::after { transform: skewX(var(--slant)) scaleX(1); }

.nav a.is-active { color: var(--text); }
.nav a.is-active::after {
  transform: skewX(var(--slant)) scaleX(1);
  box-shadow: var(--glow-soft);
}

.header-side {
  display: flex;
  align-items: center;
  gap: 0.7rem;
  flex-shrink: 0;
}

.account {
  display: flex;
  align-items: center;
  gap: 0.55rem;
  padding: 0.3rem 0.7rem 0.3rem 0.35rem;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: rgba(17, 26, 44, 0.6);
  font-size: 0.85rem;
}

.account img { border-radius: 50%; }
.account span { color: var(--text); font-weight: 500; }
.account a { color: var(--muted); font-size: 0.78rem; }
.account a:hover { color: var(--bad); }

.burger {
  display: none;
  width: 42px;
  height: 38px;
  border: 1px solid var(--line);
  border-radius: var(--r-sm);
  background: transparent;
  cursor: pointer;
  padding: 0;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 5px;
}

.burger span {
  display: block;
  width: 18px;
  height: 2px;
  background: var(--text);
  transition: transform 0.25s ease, opacity 0.2s ease;
}

.burger[aria-expanded="true"] span:nth-child(1) { transform: translateY(7px) rotate(45deg); }
.burger[aria-expanded="true"] span:nth-child(2) { opacity: 0; }
.burger[aria-expanded="true"] span:nth-child(3) { transform: translateY(-7px) rotate(-45deg); }

.site-footer {
  border-top: 1px solid var(--line);
  background: linear-gradient(180deg, rgba(11, 17, 31, 0.4), rgba(4, 6, 12, 0.9));
}

.footer-grid {
  display: grid;
  grid-template-columns: 1.6fr 1fr 1fr 1fr;
  gap: 2.5rem;
  padding: 3.5rem 0 2.5rem;
}

.footer-brand img { margin-bottom: 1rem; filter: drop-shadow(0 0 14px rgba(59, 130, 246, 0.5)); }
.footer-brand p { font-size: 0.9rem; color: var(--muted); max-width: 34ch; }

.footer-links h3,
.footer-social h3 {
  font-size: 0.95rem;
  margin-bottom: 0.9rem;
  color: var(--text);
}

.footer-links a {
  display: block;
  color: var(--muted);
  font-size: 0.9rem;
  padding: 0.22rem 0;
}

.footer-links a:hover { color: var(--accent-hi); }

.social-row { display: flex; flex-direction: column; gap: 0.55rem; }

.social-row a {
  display: inline-flex;
  align-items: center;
  gap: 0.55rem;
  color: var(--muted);
  font-size: 0.9rem;
  border: 1px solid var(--line);
  border-radius: var(--r-sm);
  padding: 0.45rem 0.75rem;
  transition: border-color 0.2s ease, color 0.2s ease, background 0.2s ease;
}

.social-row a:hover {
  color: var(--text);
  border-color: var(--line-strong);
  background: rgba(59, 130, 246, 0.08);
}

.footer-bottom {
  display: flex;
  justify-content: space-between;
  gap: 1rem;
  flex-wrap: wrap;
  padding: 1.4rem 0 2.2rem;
  border-top: 1px solid var(--line);
}

.footer-bottom p {
  margin: 0;
  font-size: 0.8rem;
  color: var(--muted);
}

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

@media (max-width: 860px) {
  .burger { display: flex; }

  .nav {
    position: fixed;
    inset: 74px 0 auto 0;
    flex-direction: column;
    align-items: stretch;
    gap: 0;
    background: rgba(6, 10, 20, 0.98);
    border-bottom: 1px solid var(--line);
    padding: 0.6rem 1.25rem 1.4rem;
    transform: translateY(-130%);
    transition: transform 0.3s ease;
    margin-left: 0;
  }

  .nav.is-open { transform: translateY(0); }

  .nav a { padding: 0.85rem 0.2rem; border-bottom: 1px solid var(--line); font-size: 1rem; }
  .nav a::after { display: none; }

  .account span { display: none; }
}

@media (max-width: 560px) {
  .shell { width: min(100% - 1.6rem, var(--shell)); }
  .footer-grid { grid-template-columns: 1fr; gap: 2rem; }
  .brand-name { font-size: 1.15rem; }
}

@media (max-width: 380px) {
  .header-side .btn-sm { padding: 0.4rem 0.6rem; font-size: 0.72rem; }
}
