/* Общие стили */
* {
  box-sizing: border-box;
}

@import url('https://fonts.googleapis.com/css2?family=Roboto:wght@400;700&display=swap');

body {
  font-family: 'Roboto', sans-serif;
  line-height: 1.6;
  color: #333;
  background: rgba(255, 255, 255, 0.95);
  margin: 0;
  padding: 20px;
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
}

/* Шапка */
header {
  width: 400px;
  height: 500px;
  background: rgba(255, 255, 255, 0.95);
  border: 2px solid #667eea;
  padding: 40px;
  border-radius: 12px;
  box-shadow: 0 15px 35px rgba(0, 0, 0, 0.1);
}

header h1 {
  text-align: center;
  color: #667eea;
  margin-bottom: 30px;
  font-size: 28px;
}

/* Навигация */
nav {
  display: flex;
  flex-wrap: wrap;
  gap: 15px;
  justify-content: center;
}

.nav-link {
  display: inline-block;
  width: calc(50% - 7.5px); /* 2 кнопки в ряд на средних экранах */
  background: #ffffff;
  color: #667eea;
  text-align: center;
  cursor: pointer;
  padding: 12px 24px;
  text-decoration: none;
  font-weight: 600;
  border: 2px solid #667eea;
  border-radius: 8px;
  transition: all 0.3s ease;
  font-size: 1rem;
}

.nav-link:hover {
  background-color: #667eea;
  color: white;
  transform: translateY(-2px);
  box-shadow: 0 5px 15px rgba(102, 126, 234, 0.4);
}

/* Адаптивность */
@media (max-width: 768px) {
  header {
    padding: 30px 20px;
    width: 95%;
  }
  
  header h1 {
    font-size: 2rem;
  }
  
  .nav-link {
    width: calc(50% - 7.5px); /* 2 кнопки в ряд */
  }
}

@media (max-width: 480px) {
  nav {
    flex-direction: column;
    align-items: center;
  }
  
  .nav-link {
    width: 100%; /* 1 кнопка на всю ширину */
    text-align: center;
  }
}

@media (max-width: 360px) {
  header {
    padding: 20px 15px;
  }
  
  header h1 {
    font-size: 1.5rem;
    margin-bottom: 20px;
  }
  
  .nav-link {
    padding: 10px 15px;
    font-size: 0.9rem;
  }
}
