@import url('https://fonts.googleapis.com/css2?family=Inter:wght@400;600&display=swap');

:root {
  --glass-bg: rgba(255, 255, 255, 0.07);
  --glass-border: rgba(255, 255, 255, 0.15);
  --text-color: #fff;
  --accent: #4db8ff;
}

body {
  margin: 0;
  font-family: 'Inter', sans-serif;
  color: var(--text-color);
  background: #000;
  overflow-x: hidden;
}

/* ===== Фон ===== */
.background {
  position: fixed;
  top: 0; left: 0;
  width: 100%; height: 100%;
  overflow: hidden;
  z-index: -2;
}

.background img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  filter: brightness(60%);
}

.overlay {
  position: absolute;
  top: 0; left: 0;
  width: 100%; height: 100%;
  background: rgba(0, 0, 0, 0.4);
  z-index: -1;
}

/* ===== Glass ===== */
.glass {
  background: var(--glass-bg);
  backdrop-filter: blur(20px);
  border: 1px solid var(--glass-border);
  border-radius: 20px;
  padding: 2rem;
  margin: 2rem auto;
  max-width: 800px;
  box-shadow: 0 0 40px rgba(0, 0, 0, 0.3);
  transition: transform 0.3s ease, opacity 0.3s ease;
}

/* ===== Navbar ===== */
.navbar {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 1rem 2rem;
  margin: 1rem auto;
  max-width: 900px;
}

.logo {
  font-weight: 600;
  font-size: 1.3rem;
}

.controls {
  display: flex;
  align-items: center;
  gap: 0.8rem;
}

.icon-btn {
  display: flex;
  align-items: center;
  justify-content: center;
  background: transparent;
  border: none;
  color: white;
  cursor: pointer;
  transition: all 0.3s ease;
  font-weight: 600;
}

.icon-btn:hover {
  transform: scale(1.1);
  color: var(--accent);
}

#music-toggle.active svg path,
#music-toggle.active svg circle {
  stroke: var(--accent);
  filter: drop-shadow(0 0 6px var(--accent));
}

/* ===== Hero ===== */
.hero {
  text-align: center;
  margin-top: 3rem;
}

.avatar {
  width: 150px;
  height: 150px;
  border-radius: 50%;
  box-shadow: 0 0 25px rgba(255,255,255,0.15);
  margin-bottom: 1rem;
  position: relative;
}

/* отражение под аватаром */
.avatar::after {
  content: '';
  position: absolute;
  bottom: -10px;
  left: 50%;
  width: 100px;
  height: 20px;
  transform: translateX(-50%);
  background: radial-gradient(circle, rgba(255,255,255,0.3), transparent 70%);
  border-radius: 50%;
  filter: blur(6px);
}

/* ===== Соцсети ===== */
.socials {
  display: flex;
  justify-content: center;
  gap: 1rem;
  flex-wrap: wrap;
}

.social-btn {
  width: 52px;
  height: 52px;
  display: flex;
  justify-content: center;
  align-items: center;
  background: var(--glass-bg);
  border-radius: 14px;
  transition: all 0.3s ease;
}

.social-btn:hover {
  background: var(--accent);
  transform: translateY(-3px);
}

.social-btn img {
  width: 28px;
  height: 28px;
  object-fit: contain;
  filter: none; /* ← Убираем перекраску */
}

.social-btn:hover img {
  transform: scale(1.05);
  filter: drop-shadow(0 0 6px rgba(77, 184, 255, 0.6));
}


/* ===== Projects ===== */
.projects {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
  gap: 1rem;
}

.project-card {
  background: var(--glass-bg);
  border: 1px solid var(--glass-border);
  border-radius: 16px;
  padding: 1.5rem;
  text-align: center;
}

.project-image {
  width: 100%;
  height: 180px;
  border-radius: 14px;
  overflow: hidden;
  position: relative;
  margin-bottom: 1rem;
}

.project-image img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.6s ease, filter 0.6s ease;
}

.project-image::after {
  content: "";
  position: absolute;
  bottom: 0;
  left: 0;
  width: 100%;
  height: 40%;
  background: linear-gradient(to top, rgba(0,0,0,0.6), transparent);
}

.project-card:hover .project-image img {
  transform: scale(1.05);
  filter: brightness(1.1);
}

.project-info h3 {
  margin-bottom: 0.4rem;
  font-size: 1.2rem;
  font-weight: 600;
}

.project-info p {
  opacity: 0.85;
  font-size: 0.95rem;
  line-height: 1.4;
}

.buttons {
  display: flex;
  justify-content: center;
  gap: 0.5rem;
  margin-top: 1rem;
}

.btn {
  padding: 0.5rem 1rem;
  background: var(--accent);
  color: #000;
  border-radius: 12px;
  text-decoration: none;
  font-weight: 600;
  transition: background 0.3s;
}

.btn:hover {
  background: #fff;
}

/* ===== Footer ===== */
.footer {
  text-align: center;
  padding: 1rem;
  opacity: 0.6;
}

/* ===== Fade-in ===== */
.fade-in {
  opacity: 0;
  transform: translateY(40px);
  transition: opacity 1s ease, transform 1s ease;
}

.fade-in.visible {
  opacity: 1;
  transform: translateY(0);
}

/* ===== Адаптив ===== */
@media (max-width: 600px) {
  .glass {
    margin: 1rem;
    padding: 1rem;
  }
}
