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

body {
font-family: Arial, sans-serif;
background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
min-height: 100vh;
display: flex;
justify-content: center;
align-items: center;
padding: 20px;
}

.container {
background: white;
border-radius: 20px;
padding: 30px;
box-shadow: 0 20px 40px rgba(0,0,0,0.1);
max-width: 600px;
width: 100%;
}

.title {
text-align: center;
color: #333;
margin-bottom: 30px;
font-size: 24px;
}

.input-group {
display: flex;
gap: 15px;
margin-bottom: 20px;
flex-wrap: wrap;
}

.input-field {
flex: 1;
min-width: 150px;
}

.input-field label {
display: block;
margin-bottom: 5px;
color: #555;
font-weight: bold;
}

.input-field input {
width: 100%;
padding: 12px;
border: 2px solid #ddd;
border-radius: 8px;
font-size: 16px;
transition: border-color 0.3s;
text-transform: uppercase;
}

.input-field input:focus {
outline: none;
border-color: #667eea;
}

.toggle-container {
display: flex;
justify-content: center;
align-items: center;
margin: 20px 0;
gap: 15px;
}

.toggle-switch {
position: relative;
width: 80px;
height: 40px;
background: #ddd;
border-radius: 20px;
cursor: pointer;
transition: background 0.3s;
}

.toggle-switch.active {
background: #4CAF50;
}

.toggle-slider {
position: absolute;
top: 4px;
left: 4px;
width: 32px;
height: 32px;
background: white;
border-radius: 50%;
transition: transform 0.3s;
box-shadow: 0 2px 4px rgba(0,0,0,0.2);
}

.toggle-switch.active .toggle-slider {
transform: translateX(40px);
}

.toggle-label {
font-weight: bold;
color: #555;
}

.infogram {
display: none;
justify-content: center;
align-items: center;
margin: 20px 0;
font-size: 24px;
font-weight: bold;
color: #333;
gap: 15px;
opacity: 0;
transform: translateY(-10px);
transition: all 0.5s ease;
}

.infogram.show {
display: flex;
opacity: 1;
transform: translateY(0);
}

.infogram-letter {
width: 50px;
height: 50px;
display: flex;
align-items: center;
justify-content: center;
background: #4CAF50;
color: white;
border-radius: 10px;
font-size: 24px;
font-weight: bold;
animation: pulse 0.5s ease;
}

.infogram-arrow {
font-size: 30px;
color: #667eea;
animation: bounce 0.5s ease;
}

@keyframes pulse {
0% { transform: scale(0.8); }
50% { transform: scale(1.1); }
100% { transform: scale(1); }
}

@keyframes bounce {
0%, 100% { transform: translateX(0); }
50% { transform: translateX(5px); }
}

.start-button {
display: block;
width: 200px;
margin: 20px auto;
padding: 15px;
background: linear-gradient(45deg, #FF6B6B, #4ECDC4);
color: white;
border: none;
border-radius: 25px;
font-size: 18px;
font-weight: bold;
cursor: pointer;
transition: transform 0.3s, box-shadow 0.3s;
}

.start-button:hover {
transform: translateY(-2px);
box-shadow: 0 10px 20px rgba(0,0,0,0.2);
}

.start-button:active {
transform: translateY(0);
}

.start-button:disabled {
opacity: 0.6;
cursor: not-allowed;
transform: none;
background: #ccc;
}

.alphabet-container {
margin: 30px 0;
height: 120px;
overflow: hidden;
border: 2px solid #ddd;
border-radius: 10px;
position: relative;
background: linear-gradient(90deg, #f9f9f9 0%, #ffffff 50%, #f9f9f9 100%);
}

.alphabet-track {
display: flex;
position: absolute;
top: 0;
left: 0;
height: 100%;
align-items: center;
transition: transform 2s cubic-bezier(0.25, 0.46, 0.45, 0.94);
}

/* Базовые стили для букв (десктоп) */
.letter {
min-width: 50px;
width: 50px;
height: 50px;
display: flex;
align-items: center;
justify-content: center;
font-size: 18px;
font-weight: bold;
color: #666;
background: white;
border-radius: 8px;
margin: 0 4px;
transition: all 0.3s ease;
opacity: 0.6;
border: 1px solid #eee;
}

.letter.center {
font-size: 28px;
color: #4CAF50;
background: linear-gradient(135deg, #e8f5e8, #c8e6c9);
transform: scale(1.4);
opacity: 1;
z-index: 10;
position: relative;
box-shadow: 0 8px 16px rgba(76, 175, 80, 0.3);
border: 2px solid #4CAF50;
}

.letter.near-center-1 {
transform: scale(1.2);
opacity: 0.85;
color: #555;
font-size: 22px;
}

.letter.near-center-2 {
transform: scale(1.1);
opacity: 0.75;
color: #777;
font-size: 20px;
}

/* Адаптивные стили для планшетов */
@media (max-width: 768px) {
  .container {
      padding: 20px;
      max-width: 100%;
  }

  .title {
      font-size: 20px;
      margin-bottom: 20px;
  }

  .input-field input {
      padding: 10px;
      font-size: 14px;
  }

  .toggle-switch {
      width: 70px;
      height: 35px;
  }

  .toggle-slider {
      width: 28px;
      height: 28px;
  }

  .toggle-switch.active .toggle-slider {
      transform: translateX(35px);
  }

  .infogram {
      margin: 15px 0;
  }

  .infogram-letter {
      width: 50px;
      height: 50px;
      font-size: 18px;
  }

  .infogram-arrow {
      font-size: 20px;
  }

  .start-button {
      padding: 12px;
      font-size: 16px;
  }

  .alphabet-container {
      height: 100px;
  }

  /* Стили букв для планшетов */
  .letter {
      min-width: 40px;
      width: 40px;
      height: 40px;
      font-size: 14px;
      margin: 0 2px;
  }

  .letter.center {
      font-size: 22px;
      transform: scale(1.3);
  }

  .letter.near-center-1 {
      transform: scale(1.15);
      font-size: 18px;
  }

  .letter.near-center-2 {
      transform: scale(1.05);
      font-size: 16px;
  }
}

/* Адаптивные стили для мобильных устройств */
@media (max-width: 480px) {
  .container {
      padding: 15px;
      border-radius: 15px;
  }

  .title {
      font-size: 18px;
  }

  .input-field input {
      padding: 8px;
      font-size: 12px;
  }

  .toggle-switch {
      width: 60px;
      height: 30px;
  }

  .toggle-slider {
      width: 24px;
      height: 24px;
  }

  .toggle-switch.active .toggle-slider {
      transform: translateX(30px);
  }

  .toggle-label {
      font-size: 14px;
  }

  .infogram-letter {
      width: 45px;
      height: 45px;
      font-size: 16px;
  }

  .infogram-arrow {
      font-size: 18px;
  }

  .start-button {
      padding: 10px;
      font-size: 14px;
  }

  .alphabet-container {
      height: 80px;
      margin: 20px 0;
  }

  /* Стили букв для мобильных устройств */
  .letter {
      min-width: 35px;
      width: 35px;
      height: 35px;
      font-size: 12px;
      margin: 0 1px;
      border-radius: 6px;
  }

  .letter.center {
      font-size: 18px;
      transform: scale(1.2);
  }

  .letter.near-center-1 {
      transform: scale(1.1);
      font-size: 14px;
  }

  .letter.near-center-2 {
      transform: scale(1.05);
      font-size: 13px;
  }
}