@import url('https://fonts.googleapis.com/css2?family=Comfortaa:wght@300..700&display=swap');
@import url('https://fonts.googleapis.com/css2?family=Dela+Gothic+One&display=swap');
@import url('https://fonts.googleapis.com/css2?family=Sansation:ital,wght@0,300;0,400;0,700;1,300;1,400;1,700&display=swap');

:root{
  --max-width: 100%;
  --accent: #2b90d9;
  --text: #ffffff;
  --muted: #969696;
  --bg: #1d2229;
  font-size: 20px;

  --font-h1: "Sansation", sans-serif;
  --font-h2: "Comfortaa", sans-serif;
  --font-h3: "Space Grotesk", sans-serif;
  --font-body: "Inter", sans-serif;
  --font-btn: "Söhne Mono", monospace;
}

h1 { font-family: var(--font-h1); font-weight: 700; letter-spacing: .02em; }
h2 { font-family: var(--font-h2); font-weight: 600; }
h3 { font-family: var(--font-h3); font-weight: 500; }
button { font-family: var(--font-btn); font-weight: 500; text-transform: uppercase; }

body::before {
  content: "";
  position: fixed;
  inset: 0;
  background: radial-gradient(circle at 30% 20%, rgba(255,255,255,0.03), transparent 40%);
  pointer-events: none;
}

body{
  display: flex;
  flex-direction: column;
  
  font-family: var(--font-body);
  font-weight: 400;
  color:var(--text);

  height: 100%;
  background-image: url('../images/Background_1.png' );
  background-size: cover;
  background-position: center;
  background-repeat: no-repeat;
  background-attachment: fixed;
  background-color: var(--bg);
  /* background-blend-mode: overlay; */
  margin:0;
  -webkit-font-smoothing:antialiased;
}

.wrap {
  max-width:var(--max-width);
  margin:0 auto;
}

/* === ШАПКА === */
.site-header {
  padding:12px 0;
  max-width: 980px;
  margin: 0 auto;
}

.site-header .wrap {
  display: flex;
  flex-direction: row;
  align-items: center;      /* вертикальное выравнивание */
  justify-content: space-between; /* бренд слева, меню справа */
}

/* === === === */

.brand{
  font-weight:700;
  font-size: 20px;
  text-decoration:none;
  color:var(--text);
}

.main-nav ul {
  list-style:none;
  display:flex;
  gap:12px;
  margin:0;
  padding:0;
}

.main-nav a {
  text-decoration:none;
  color:var(--muted);
}

/* === ОСНОВНАЯ СТРАНИЦА === */

/*#region ГЛАВНАЯ СТРАНИЦА - ПАНЕЛЬ СЛЕВА */
/* ---- контейнер и базовые стили ---- */
.content-wrapper {
  position: relative;
  overflow: hidden;
  height: 100vh; /* Высота окна просмотра контента — подгони под дизайн */
}

/* панели */
.content {
  position: absolute;
  top: 0;
  left: 15%;
  width: 80%;
  height: 100vh;

  display: flex;
  flex-direction: column;
  justify-content: center;  /* вертикальный центр */
  align-items: center;

  padding: 1.2rem;
  box-sizing: border-box;
  opacity: 0;
  transform: translateY(100%); /* по умолчанию скрыта снизу */
  transition: none; /* выключаем transition, используем keyframes */
  pointer-events: none; /* чтобы скрытые панели не ловили клики */
}

/* активная панель — видимая и на месте */
.content.active {
  opacity: 1;
  transform: translateY(0);
  pointer-events: auto;
}

/* ---- анимации входа/ухода ---- */
@keyframes slideInFromBelow {
  from {
    transform: translateY(100%) scale(0.97);
    opacity: 0;
  }
  to {
    transform: translateY(0) scale(1);
    opacity: 1;
  }
}

@keyframes slideOutToAbove {
  from {
    transform: translateY(0) scale(1);
    opacity: 1;
  }
  to {
    transform: translateY(-100%) scale(0.97);
    opacity: 0;
  }
}

@keyframes slideInFromAbove {
  from {
    transform: translateY(-100%) scale(0.97);
    opacity: 0;
  }
  to {
    transform: translateY(0) scale(1);
    opacity: 1;
  }
}

@keyframes slideOutToBelow {
  from {
    transform: translateY(0) scale(1);
    opacity: 1;
  }
  to {
    transform: translateY(100%) scale(0.97);
    opacity: 0;
  }
}

/* классы, которые JS будет ставить при анимации */
.slide-in {
  animation: slideInFromBelow 1200ms cubic-bezier(.22,1,.36,1) forwards;
  z-index: 20;
  pointer-events: auto;
}
.slide-out {
  animation: slideOutToAbove 1200ms cubic-bezier(.22,1,.36,1) forwards;
  z-index: 10;
  pointer-events: none;
}

.slide-in-down {
  animation: slideInFromAbove 1200ms cubic-bezier(.22,1,.36,1) forwards;
  z-index: 20;
}

.slide-out-down {
  animation: slideOutToBelow 1200ms cubic-bezier(.22,1,.36,1) forwards;
  z-index: 10;
}

/* небольшая эстетика */
.menu { margin-top: 1rem; }
.nav-btn {
  background-color: transparent;
  border: none;

  margin-top: 1rem;
  height: auto;
  width: 100px;

  font-size: 40px;
  color: var(--muted);
}

.nav-btn:hover {
  color: var(--text);
  text-shadow: 0px 0px 6px var(--text);
}

/* аккуратное фокусирование — чтобы видно было клавиатурой */
/* .content :focus { outline: 2px solid rgba(0,255,213,0.2); outline-offset: 2px; } */

/*#endregion*/

/*#region БЛОК КОНТАКТОВ*/
.contacts {
  position: absolute;
  top:50vh;
  transform: translateY(-50%);
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  width: 40px;
  color: var(--muted);
  gap: 60px;
  padding-left: 1.2rem;
}

.contacts a {
  width: 32px;
  height: 32px;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: transform 0.2s ease, opacity 0.2s ease;
}

.contacts .email-icon {
  color: var(--muted)
}

.contacts a:hover {
  transform: scale(1.15);
  opacity: 0.8;
}

.contacts svg {
  width: 100%;
  height: 100%;
  fill: var(--muted);
}

.contacts a:hover {
  transform: translateY(-3px);
  color: var(--text);
  filter: drop-shadow(0 0 6px var(--text));
}
/*#endregion*/

.home-intro.wrap{
  min-height: 100vh;
  display: flex;
  align-items: center;
}

.panel {
  display: none;
}

.panel.active {
  display: flex;
}

.menu {
  color: var(--muted);
  font-size: 32px;
}

.menu button {
  background: transparent;
  border: none;
  color: var(--muted);
  font-size: 32px;
}

.menu button:hover {
  background: transparent;
  border: none;
  color: var(--text);
}

.menu button:active {
  color: var(--text);
}

.hero {
  width: var(--max-width);
  display:grid;
  grid-template-columns: 3fr 2fr; /* 60% — 40% */
  position: relative;             /* <— это важно! */
  gap:20px;
  /* padding-left:24px; */
  align-items:center;
  /* border-top:1px solid #eee;
  border-bottom:1px solid #eee; */
}

.hero-text {
  min-height: 100vh;
  display: flex;
  justify-content: center;
  flex-direction: column;
  gap: 20px;
  text-align: center;
}

.hero-text h1 {
  font-size: 60px;
}

.hero-content {
  position: relative; /* локальная система координат */
  display: flex;
  justify-content: flex-start; /* аватар в центре колонки */
  align-items: flex-start;
}

.avatar {
  position: absolute;
  bottom: -50vh;
  right: 0;
  /* width:100%; */
  height:100vh;
  object-fit:cover;
}



/*#region МЕНЮ ПОРТФОЛИО*/
/* Контейнер */
.menu-deck {
  position: relative;
  width: max-content; /* чтобы колода могла расширяться под все карточки */
  height: 60px;       /* высота карточек */
}

/* Каждая карточка */
.menu-deck .card {
  position: absolute;
  top: 0;
  left: 0;
  width: 100px; /* ширина одной карточки, можно подгонять */
  height: 60px;
  background: #2a2a2a;
  color: white;
  border: none;
  cursor: pointer;
  box-shadow: 0 5px 15px rgba(0,0,0,0.3);
  transition: transform 0.3s ease, z-index 0.3s ease;
}

/* Горизонтальное смещение для "колоды" */
.menu-deck .card:nth-child(1) { transform: translateX(0px); z-index: 1; }
.menu-deck .card:nth-child(2) { transform: translateX(30px); z-index: 2; }
.menu-deck .card:nth-child(3) { transform: translateX(60px); z-index: 3; }
.menu-deck .card:nth-child(4) { transform: translateX(90px); z-index: 4; }

/* Hover — фокусная карточка */
.menu-deck .card:hover {
  transform: translateX(-5px) scale(1.05); /* всплывает чуть вперёд */
  z-index: 10; /* поверх остальных */
}

/* Сдвигаем соседние элементы после наведения */
.menu-deck .card:hover ~ .card {
  transform: translateX(calc(30px * var(--i))) ; /* сохраняем базовый отступ */
}
/*#endregion*/
.sammary {
  width: 980px;
  margin: 0 auto;
}
/* === === === */

.cta {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.btn {
  padding:8px 14px;
  margin-right:8px;
  background:var(--accent);
  color:#fff;
  border-radius:6px;
  text-decoration:none;
}

.projects-grid {
  display:grid;
  grid-template-columns:repeat(auto-fit,minmax(220px,1fr));
  gap:20px;
  padding:0;
  list-style:none;
}

.project-card img {
  width:100%;
  height:140px;
  object-fit:cover;
  border-radius:6px;
}

.project-card h3 {
  margin:8px 0 4px;
}

.site-footer {
  /* border-top:1px solid #eee; */
  padding:18px 0;
  margin: 0 auto;
  margin-top:40px;
  color:var(--muted);
  text-align:center;
  font-size:14px;
}

/* Контейнер раздела с боковой панелью */
.section-container {
  display: flex;
  gap: 24px;
  margin-top: 24px;
}

/* Сайдбар */
.sidebar {
  flex: 0 0 220px;
  background: #f9f9f9;
  padding: 16px;
  border-radius: 8px;
  box-shadow: 0 0 6px rgba(0,0,0,0.03);
}

.sidebar h3 {
  margin-top: 0;
  margin-bottom: 12px;
  font-size: 16px;
  color: var(--accent);
}

.sidebar ul {
  list-style: none;
  padding: 0;
  margin: 0;
}

.sidebar li {
  margin-bottom: 8px;
}

.sidebar a {
  text-decoration: none;
  color: var(--text);
  transition: color 0.2s;
}

.sidebar a:hover {
  color: var(--accent);
}

/* Основной контент */
.section-content {
  flex: 1;
  padding: 16px;
  background: #fff;
  border-radius: 8px;
  box-shadow: 0 0 8px rgba(0,0,0,0.05);
}

/* Адаптивность для мобильных */
@media (max-width: 768px) {
  .section-container {
    flex-direction: column;
  }

  .sidebar {
    width: 100%;
    margin-bottom: 16px;
  }

  .section-content {
    width: 100%;
  }
}

