:root {
  --primary: #4a6bfe;
  --secondary: #2e3b5b;
  --accent: #ffc107;
  --dark: #1a1a2e;
  --light: #f5f5f7;
  --gray: #6c757d;
  --light-gray: #e9ecef;
  --font-main: 'Inter', system-ui, -apple-system, sans-serif;
  --container-width: 1140px;
  --header-height: 70px;
  --section-spacing: 100px;
}

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

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  font-family: var(--font-main);
  background-color: var(--light);
  color: var(--dark);
  line-height: 1.6;
  font-size: 16px;
}

a {
  color: var(--primary);
  text-decoration: none;
  transition: color 0.3s ease;
}

a:hover {
  color: var(--secondary);
}

img {
  max-width: 100%;
  height: auto;
  display: block;
}

ul {
  list-style: none;
}

.container {
  width: 100%;
  max-width: var(--container-width);
  margin: 0 auto;
  padding: 0 15px;
}

.section {
  padding: 80px 0;
}

.section-title {
  font-size: 2.5rem;
  margin-bottom: 50px;
  text-align: center;
  position: relative;
}

.section-title:after {
  content: '';
  display: block;
  width: 60px;
  height: 4px;
  background-color: var(--primary);
  margin: 15px auto 0;
}

/* Хедер */
.header {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  background-color: rgba(255, 255, 255, 0.95);
  box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
  padding: 15px 0;
  z-index: 1000;
}

.header .container {
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
}

.brand {
  display: flex;
  flex-direction: column;
}

.name {
  font-size: 1.8rem;
  font-weight: 700;
  margin: 0;
}

.title {
  color: var(--primary);
  margin: 0;
  font-size: 1rem;
}

.navigation {
  display: flex;
  gap: 30px;
}

.navigation a {
  font-weight: 500;
  padding: 5px 0;
  position: relative;
}

.navigation a:after {
  content: '';
  position: absolute;
  bottom: 0;
  left: 0;
  width: 0;
  height: 2px;
  background-color: var(--primary);
  transition: width 0.3s ease;
}

.navigation a:hover:after {
  width: 100%;
}

/* Секция Обо мне */
.about {
  padding-top: 150px;
}

.hero-title {
  font-size: 2.2rem;
  text-align: center;
  margin-bottom: 20px;
}

.about-content {
  display: flex;
  gap: 40px;
  align-items: center;
  justify-content: center;
}

.about-text {
  max-width: 600px;
}

.about-text p {
  margin-bottom: 20px;
}

.about-actions {
  display: flex;
  gap: 12px;
  flex-wrap: wrap;
}

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 10px 16px;
  border-radius: 8px;
  font-weight: 600;
  line-height: 1.2;
  border: 1px solid transparent;
  transition: background-color 0.2s ease, color 0.2s ease, border-color 0.2s ease;
}

.btn-primary {
  background-color: var(--primary);
  color: #fff;
}

.btn-primary:hover {
  background-color: var(--secondary);
}

.btn-outline {
  background-color: transparent;
  color: var(--primary);
  border-color: var(--primary);
}

.btn-outline:hover {
  background-color: var(--primary);
  color: #fff;
}

/* Секция Навыки */
.skills-container {
  display: flex;
  flex-wrap: wrap;
  gap: 30px;
  justify-content: center;
}

.skill-category {
  flex: 1;
  min-width: 250px;
  background-color: white;
  border-radius: 8px;
  padding: 25px;
  box-shadow: 0 5px 15px rgba(0, 0, 0, 0.05);
  transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.skill-category:hover {
  transform: translateY(-5px);
  box-shadow: 0 8px 25px rgba(0, 0, 0, 0.1);
}

.skill-category h3 {
  color: var(--primary);
  margin-bottom: 15px;
  font-size: 1.3rem;
}

.skill-list li {
  margin-bottom: 10px;
  position: relative;
  padding-left: 20px;
}

.skill-list li:before {
  content: '•';
  color: var(--primary);
  position: absolute;
  left: 0;
  font-size: 1.2rem;
}

/* Секция Проекты */
.projects-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 30px;
}

/* Ограничение ширины карточек и выравнивание */
.projects .container {
  display: flex;
  flex-direction: column;
  align-items: center;
}

.projects-grid {
  width: 100%;
  max-width: 840px;
}

.project-card {
  width: 100%;
}

/* Карусель проектов */
.projects-carousel {
  position: relative;
  width: 100%;
  max-width: 900px;
  margin: 0 auto;
}

.carousel-viewport {
  overflow: hidden;
}

.projects-carousel .projects-grid {
  display: flex;
  gap: 0;
  max-width: none;
}

.projects-carousel .project-card {
  flex: 0 0 100%;
}

.carousel-btn {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  width: 44px;
  height: 60px;
  border-radius: 8px;
  border: none;
  background: transparent;
  box-shadow: none;
  cursor: pointer;
  z-index: 5;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--secondary);
  font-size: 28px;
}

.carousel-btn:hover { color: var(--primary); }
.carousel-btn.prev { left: -24px; transform: translate(-60%, -50%); }
.carousel-btn.next { right: -24px; transform: translate(60%, -50%); }

.carousel-dots {
  display: flex;
  justify-content: center;
  gap: 8px;
  margin-top: 12px;
}

.carousel-dots button {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  border: 0;
  background: var(--light-gray);
  cursor: pointer;
}

.carousel-dots button.active { background: var(--primary); }

@media (max-width: 768px) {
  .carousel-btn { width: 40px; height: 56px; font-size: 26px; }
  .carousel-btn.prev { left: 0; transform: translate(-30%, -50%); }
  .carousel-btn.next { right: 0; transform: translate(30%, -50%); }
}

.project-card {
  background-color: white;
  border-radius: 8px;
  overflow: hidden;
  box-shadow: 0 5px 15px rgba(0, 0, 0, 0.05);
  transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.project-card:hover {
  transform: translateY(-5px);
  box-shadow: 0 8px 25px rgba(0, 0, 0, 0.1);
}

.project-image {
  height: 200px;
  overflow: hidden;
}

.project-image img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.5s ease;
}

.project-card:hover .project-image img {
  transform: scale(1.05);
}

.project-info {
  padding: 20px;
}

.project-title {
  font-size: 1.3rem;
  margin-bottom: 10px;
}

.project-description {
  color: var(--gray);
  margin-bottom: 15px;
  font-size: 0.95rem;
}

.project-role {
  color: var(--secondary);
  font-weight: 600;
  margin-bottom: 8px;
}

.project-stack {
  color: var(--gray);
  font-size: 0.9rem;
  margin-bottom: 12px;
}

.project-results {
  padding-left: 18px;
}

.project-results li {
  margin-bottom: 8px;
  list-style: disc;
}

/* Вложенные списки в результатах проекта */
.project-results ul {
  padding-left: 18px;
}

.project-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-bottom: 15px;
}

.tag {
  background-color: var(--light-gray);
  color: var(--secondary);
  padding: 4px 10px;
  border-radius: 50px;
  font-size: 0.8rem;
}

.project-links {
  display: flex;
  gap: 15px;
}

.project-links a {
  padding: 8px 15px;
  border-radius: 4px;
  font-weight: 500;
  font-size: 0.9rem;
  transition: all 0.3s ease;
}

.project-links a:first-child {
  background-color: var(--primary);
  color: white;
}

.project-links a:first-child:hover {
  background-color: var(--secondary);
}

.project-links a:last-child {
  border: 1px solid var(--primary);
}

.project-links a:last-child:hover {
  background-color: var(--primary);
  color: white;
}

/* Секции внутри карточки проекта */
.project-section {
  margin-top: 14px;
  padding-top: 8px;
  border-top: 1px solid var(--light-gray);
}

.project-section:first-of-type {
  border-top: 0;
  padding-top: 0;
}

.project-section h4 {
  font-size: 1.02rem;
  margin-bottom: 8px;
  color: var(--primary);
}

.project-section p {
  color: var(--gray);
  margin-bottom: 8px;
}

.project-section ul {
  padding-left: 18px;
}

.project-section ul li {
  list-style: disc;
  margin-bottom: 6px;
}

/* Секция Контакты */
.contact-content {
  max-width: 600px;
  margin: 0 auto;
}

.contact-info p {
  margin-bottom: 30px;
  text-align: center;
}

.contact-list {
  display: flex;
  flex-direction: column;
  gap: 15px;
}

.contact-list li {
  display: flex;
  align-items: center;
  padding: 15px;
  background-color: white;
  border-radius: 8px;
  box-shadow: 0 3px 10px rgba(0, 0, 0, 0.05);
}

.contact-label {
  font-weight: 600;
  margin-right: 10px;
  min-width: 80px;
}

/* Футер */
.footer {
  background-color: var(--secondary);
  color: white;
  padding: 30px 0;
  text-align: center;
}

/* Адаптив */
@media (max-width: 768px) {
  .header .container {
    flex-direction: column;
    gap: 15px;
  }
  
  .navigation {
    margin-top: 15px;
    gap: 15px;
  }
  
  .section {
    padding: 60px 0;
  }
  
  .about {
    padding-top: 180px;
  }
  .hero-title {
    font-size: 1.8rem;
  }
  
  .section-title {
    font-size: 2rem;
    margin-bottom: 30px;
  }
  
  .skills-container {
    flex-direction: column;
  }
  
  .skill-category {
    width: 100%;
  }
  
  .projects-grid {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 480px) {
  .navigation {
    flex-wrap: wrap;
    justify-content: center;
  }
  
  .contact-list li {
    flex-direction: column;
    align-items: flex-start;
    gap: 5px;
  }
  
  .contact-label {
    margin-right: 0;
  }
} 
