* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

body {
  font-family: "Courier New", monospace;
  background: linear-gradient(
    180deg,
    rgba(0, 187, 255, 0.7),
    rgba(0, 187, 255, 0.5),
    rgba(0, 187, 255, 0.3)
  );
  min-height: 100vh;
  padding: 20px;
  position: relative;
  overflow-x: hidden;
}

/* language */
.lang-menu {
  position: fixed;
  width: 100px;
  overflow: hidden;
  height: 50px;
  color: #1a1a1a;
  border-radius: 12px;
  background: linear-gradient(
    135deg,
    rgba(255, 255, 255, 0.95),
    rgba(245, 245, 250, 0.95)
  );
  backdrop-filter: blur(10px);
  bottom: 20px;
  border: 1.5px solid #e0e0e0;
  box-shadow: 0 4px 15px rgba(0, 0, 0, 0.08);
  transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
  right: 20px;
  display: flex;
  align-items: center;
  justify-content: space-around;
  padding: 8px;
  z-index: 1000;
}

.title-lang {
  text-align: center;
  position: absolute;
  transition: all 0.4s 0.2s cubic-bezier(0.4, 0, 0.2, 1);
  width: 150px;
  overflow: hidden;
  font-weight: 600;
  font-size: 14px;
  letter-spacing: 0.3px;
  color: #2c3e50;
}

.lang-menu:hover {
  width: 180px;
  box-shadow: 0 6px 25px rgba(0, 0, 0, 0.12);
  border-color: #d0d0d0;
}

.lang-menu:hover .title-lang {
  width: 0px;
  opacity: 0;
  transition: all 0.3s 0s cubic-bezier(0.4, 0, 0.2, 1);
}

.lang-menu:hover .lang-items {
  transition: all 0.3s 0.3s cubic-bezier(0.4, 0, 0.2, 1);
  right: 0;
  opacity: 1;
  transform: translateX(0);
}

.lang-items {
  transition: all 0.2s ease-out;
  background: #ffffff;
  color: #2c3e50;
  border: 1.5px solid #e0e0e0;
  right: -200px;
  bottom: 0;
  position: relative;
  padding: 6px 12px;
  border-radius: 8px;
  cursor: pointer;
  font-size: 13px;
  font-weight: 500;
  opacity: 0;
  transform: translateX(20px);
  letter-spacing: 0.5px;
}

.lang-items:hover {
  background: #f8f9fa;
  border-color: #3498db;
  transform: translateX(0) scale(1.05);
  box-shadow: 0 2px 8px rgba(52, 152, 219, 0.15);
}

.lang-items-action {
  color: #3498db;
  border-color: #3498db;
  background: linear-gradient(
    135deg,
    rgba(52, 152, 219, 0.08),
    rgba(52, 152, 219, 0.12)
  );
  font-weight: 600;
  box-shadow: 0 2px 8px rgba(52, 152, 219, 0.2);
}

.lang-items-action:hover {
  background: linear-gradient(
    135deg,
    rgba(52, 152, 219, 0.15),
    rgba(52, 152, 219, 0.2)
  );
}
.clouds {
  position: fixed;
  width: 100%;
  height: 100%;
  pointer-events: none;
  z-index: 0;
}

.cloud {
  position: absolute;
  background: white;
  border-radius: 100px;
  opacity: 0.8;
  animation: float 30s infinite ease-in-out;
}

.cloud::before,
.cloud::after {
  content: "";
  position: absolute;
  background: white;
  border-radius: 100px;
}

@keyframes float {
  0%,
  100% {
    transform: translate(0, 0);
  }
  50% {
    transform: translate(200px, -10px);
  }
}

.container {
  max-width: 1200px;
  margin: 0 auto;
  position: relative;
  z-index: 2;
}

.window {
  background: rgba(255, 255, 255, 0.95);
  border: 3px solid #2c3e50;
  border-radius: 15px;
  margin-bottom: 30px;
  box-shadow: 8px 8px 0 rgba(0, 0, 0, 0.1);
}

.window-header {
  background: #ecf0f1;
  padding: 12px 20px;
  border-bottom: 3px solid #2c3e50;
  border-radius: 12px 12px 0 0;
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.window-title {
  font-weight: bold;
  color: #2c3e50;
  font-size: 1.1em;
}

.window-controls {
  display: flex;
  gap: 8px;
}

.window-btn {
  width: 15px;
  height: 15px;
  border-radius: 50%;
  border: 2px solid #2c3e50;
  background: white;
}

.window-content {
  padding: 30px;
}

.header-section {
  display: grid;
  grid-template-columns: 350px 1fr;
  gap: 30px;
  align-items: start;
}

#card {
  transition: all 0.2s ease;
}

.profile-card {
  background: white;
  height: 450px;
  border: 3px solid #2c3e50;
  border-radius: 10px;
  transition: all 0.2s ease;
  padding: 15px;
  text-align: center;
}

.profile-card:hover {
  box-shadow: 8px 8px 0 rgba(0, 0, 0, 0.1);
}

.profile-card-header {
  background: #ecf0f1;
  padding: 8px;
  border: 2px solid #2c3e50;
  border-radius: 5px;
  margin-bottom: 15px;
  font-weight: bold;
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.profile-img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  border: 3px solid #2c3e50;
  border-radius: 10px;
  margin-bottom: 15px;

  opacity: 0;
  visibility: hidden;
  transition:
    opacity 0.8s ease,
    visibility 0.8s ease;
  position: absolute;
  inset: 0;
}

.profile-images-wrapper {
  position: relative;
  height: 350px;
  margin-bottom: 15px;
}

.profile-img.active {
  opacity: 1;
  visibility: visible;
}

.pixel-art {
  image-rendering: pixelated;
  image-rendering: -moz-crisp-edges;
  image-rendering: crisp-edges;
}

.speech-bubble {
  background: white;
  border: 3px solid #2c3e50;
  border-radius: 20px;
  padding: 14px 26px;
  position: relative;
  margin-top: 20px;
  font-size: 16px;
  color: #2c3e50;
}

.speech-bubble::before {
  content: "";
  position: absolute;
  left: 30px;
  top: -15px;
  width: 0;
  height: 0;
  border-left: 15px solid transparent;
  border-right: 15px solid transparent;
  border-bottom: 15px solid #2c3e50;
}

.speech-bubble::after {
  content: "";
  position: absolute;
  left: 33px;
  top: -10px;
  width: 0;
  height: 0;
  border-left: 12px solid transparent;
  border-right: 12px solid transparent;
  border-bottom: 12px solid white;
}

.programs-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
  gap: 20px;
  margin-top: 20px;
}

.program-box {
  background: white;
  border: 3px solid #2c3e50;
  border-radius: 10px;
  padding: 20px;
}

.program-header {
  background: #ecf0f1;
  padding: 8px 15px;
  border: 2px solid #2c3e50;
  border-radius: 5px;
  margin-bottom: 15px;
  font-weight: bold;
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.progress-bar {
  width: 100%;
  height: 8px;
  background: #ecf0f1;
  border: 2px solid #2c3e50;
  border-radius: 5px;
  overflow: hidden;
}

.progress-fill {
  height: 100%;
  background: linear-gradient(90deg, #3498db, #2ecc71);
  transition: width 0.3s ease;
}

/* music */
.music-player {
  background: white;
  margin-top: 20px;
  border: 3px solid #2c3e50;
  border-radius: 10px;
  padding: 20px;
  text-align: center;
}

.music-controls {
  display: flex;
  align-items: center;
  gap: 15px;
  margin: 15px 0;
  justify-content: center;
}

.control-btn {
  width: 50px;
  height: 50px;
  border: 3px solid #2c3e50;
  border-radius: 50%;
  background: white;
  cursor: pointer;
  font-size: 1.2em;
  display: flex;
  align-items: center;
  justify-content: center;
}

.control-btn:hover {
  background: #ecf0f1;
}

#time-display {
  color: #7f8c8d;
  font-size: 0.9em;
  margin-top: 20px;
}

#progress-fill {
  height: 100%;
  background: #2c3e50;
  width: 0%;
  transition: width 0.2s ease;
}

/*  */

.contact-section {
  text-align: center;
  padding: 40px 20px;
}

.contact-title {
  font-size: 2.5em;
  color: white;
  text-shadow: 3px 3px 0 #2c3e50;
  margin-bottom: 20px;
}

.contact-box {
  background: white;
  border: 3px solid #2c3e50;
  border-radius: 10px;
  padding: 25px;
  max-width: 600px;
  margin: 0 auto;
  text-align: left;
}

.contact-item {
  padding: 10px 0;
  color: #2c3e50;
  display: flex;
  gap: 10px;
}

.contact-item strong {
  min-width: 100px;
}

.stars {
  position: fixed;
  font-size: 2em;
  color: white;
  text-shadow: 0 0 10px white;
  animation: twinkle 2s infinite;
}

@keyframes twinkle {
  0%,
  100% {
    opacity: 0.3;
  }
  50% {
    opacity: 1;
  }
}

/* Базовые стили для всех карточек с tilt-анимацией */
.tilt-card {
  transition: all 0.15s ease;
  cursor: pointer;
  box-shadow: 8px 8px 0 rgba(0, 0, 0, 0.1);
  transform: perspective(1000px) rotateX(0deg) rotateY(0deg) scale(1);
}

/* Усиливаем тень на hover (для тех, у кого её нет) */
.tilt-card:hover {
  box-shadow: 12px 12px 0 rgba(0, 0, 0, 0.15);
}

/* Специально для skill-card (которые у тебя новые) */
.skill-card {
  background: white;
  border: 3px solid #2c3e50;
  border-radius: 10px;
  padding: 15px;
  text-align: left;
}

.languages-flex {
  display: flex;
  flex-direction: column;
  gap: 12px;
  margin-top: 10px;
}

.lang-item {
  background: #ecf0f1;
  border: 2px solid #2c3e50;
  padding: 10px;
  border-radius: 6px;
  text-align: center;
  font-weight: bold;
}

.skill-item {
  border-bottom: 2px dashed #2c3e50;
  padding: 10px;
  padding-bottom: 15px;
  margin-bottom: 8px;
  display: flex;
  align-items: center;
  gap: 10px;
  font-size: 0.95em;
}

.skill-item:last-child {
  border-bottom: none;
}

.skill-item span {
  width: 200px;
  font-weight: 600;
}

.progress-fill {
  height: 100%;
  background: #2c3e50;
  transition: width 1.5s ease; /* плавное заполнение при загрузке */
}

.skills-container {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(360px, 1fr));
  gap: 20px;
  margin-bottom: 30px;
}

.achievements-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 20px;
}

.achievement-card {
  background: white;
  border: 3px solid #2c3e50;
  border-radius: 10px;
  overflow: hidden;
  cursor: pointer;
  text-decoration: none;
  color: inherit;
  display: block;
}

.achievement-img {
  width: 100%;
  height: 200px;
  object-fit: cover;
  border-bottom: 3px solid #2c3e50;
  background: #ecf0f1;
}

.achievement-content {
  padding: 15px;
}

.achievement-title {
  font-weight: bold;
  font-size: 1.1em;
  color: #2c3e50;
  text-transform: uppercase;
  margin-bottom: 8px;
}

.achievement-link {
  color: #3498db;
  font-size: 0.85em;
  word-break: break-all;
}

.loading {
  text-align: center;
  padding: 40px;
  color: #7f8c8d;
  font-size: 1.2em;
}

.contact-section {
  text-align: center;
  padding: 40px 20px;
}

.contact-title {
  font-size: 2.5em;
  color: white;
  text-shadow: 3px 3px 0 #2c3e50;
  margin-bottom: 20px;
}

.contact-box {
  background: white;
  border: 3px solid #2c3e50;
  border-radius: 10px;
  padding: 25px;
  max-width: 600px;
  margin: 0 auto;
  text-align: left;
}

.contact-item {
  padding: 10px 0;
  color: #2c3e50;
  display: flex;
  gap: 10px;
}

.contact-item strong {
  min-width: 100px;
}

.tilt-card {
  transition: all 0.15s ease;
  cursor: pointer;
  box-shadow: 8px 8px 0 rgba(0, 0, 0, 0.1);
}

.tilt-card:hover {
  box-shadow: 12px 12px 0 rgba(0, 0, 0, 0.15);
}

@media (max-width: 768px) {
  .header-section {
    grid-template-columns: 1fr;
  }

  .window-title {
    font-size: 14px;
  }

  .speech-bubble {
    font-size: 14px;
  }

  .skills-container {
    width: auto;
    grid-template-columns: repeat(1, 1fr);
  }

  .programs-grid {
    grid-template-columns: 1fr;
  }

  .contact-title {
    font-size: 1.8em;
  }

  .contact-section {
    padding: 0;
  }

  .achievements-grid {
    grid-template-columns: 1fr;
  }

  .contact-item {
    flex-direction: column;
  }
}
