* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen, Ubuntu, Cantarell, sans-serif;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    min-height: 100vh;
    color: #333;
}

.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 20px;
}

header {
    text-align: center;
    color: white;
    margin-bottom: 40px;
    padding: 40px 0;
}

header h1 {
    font-size: 3em;
    margin-bottom: 10px;
}

.subtitle {
    font-size: 1.2em;
    opacity: 0.9;
}

main {
    background: white;
    border-radius: 20px;
    padding: 40px;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.3);
}

.card {
    text-align: center;
    margin-bottom: 40px;
}

.card h2 {
    font-size: 2em;
    margin-bottom: 30px;
    color: #667eea;
}

.steps {
    display: flex;
    flex-direction: column;
    gap: 30px;
    margin-bottom: 40px;
}

.step {
    display: flex;
    align-items: flex-start;
    gap: 20px;
    text-align: left;
    padding: 20px;
    background: #f8f9fa;
    border-radius: 10px;
    transition: transform 0.2s;
}

.step:hover {
    transform: translateX(10px);
}

.step-number {
    width: 50px;
    height: 50px;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.5em;
    font-weight: bold;
    flex-shrink: 0;
}

.step-content h3 {
    font-size: 1.3em;
    margin-bottom: 10px;
    color: #333;
}

.step-content p {
    color: #666;
    line-height: 1.6;
}

.cta {
    margin-top: 40px;
}

.btn-primary {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    border: none;
    padding: 15px 40px;
    font-size: 1.2em;
    border-radius: 50px;
    cursor: pointer;
    transition: transform 0.2s, box-shadow 0.2s;
    font-weight: bold;
}

.btn-primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 10px 20px rgba(102, 126, 234, 0.4);
}

.features {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 30px;
    margin-top: 40px;
}

.feature {
    text-align: center;
    padding: 30px;
    background: #f8f9fa;
    border-radius: 10px;
}

.feature h3 {
    font-size: 1.5em;
    margin-bottom: 10px;
    color: #667eea;
}

.feature p {
    color: #666;
    line-height: 1.6;
}

footer {
    text-align: center;
    color: white;
    margin-top: 40px;
    opacity: 0.8;
}

@media (max-width: 768px) {
    header h1 {
        font-size: 2em;
    }

    .steps {
        gap: 20px;
    }

    .step {
        flex-direction: column;
        text-align: center;
    }

    .step:hover {
        transform: translateY(-5px);
    }
}

/* Стили для формы конструктора */
.builder-form {
    max-width: 800px;
    margin: 0 auto;
}

.form-section {
    margin-bottom: 40px;
    padding: 20px;
    background: #f8f9fa;
    border-radius: 10px;
}

.form-section h2 {
    color: #667eea;
    margin-bottom: 10px;
    font-size: 1.4em;
}

.hint {
    color: #666;
    margin-bottom: 15px;
    font-size: 0.95em;
}

textarea {
    width: 100%;
    padding: 15px;
    border: 2px solid #e0e0e0;
    border-radius: 8px;
    font-size: 1em;
    font-family: inherit;
    resize: vertical;
    margin-bottom: 15px;
}

textarea:focus {
    outline: none;
    border-color: #667eea;
}

.btn-secondary {
    background: #fff;
    color: #667eea;
    border: 2px solid #667eea;
    padding: 10px 25px;
    font-size: 1em;
    border-radius: 50px;
    cursor: pointer;
    font-weight: bold;
    transition: all 0.2s;
}

.btn-secondary:hover {
    background: #667eea;
    color: white;
}

.btn-secondary:disabled {
    opacity: 0.6;
    cursor: not-allowed;
}

.hidden {
    display: none;
}

.variables-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(250px, 1fr));
    gap: 15px;
    margin-top: 15px;
}

.var-item {
    background: white;
    padding: 15px;
    border-radius: 8px;
    border: 1px solid #e0e0e0;
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.var-item code {
    background: #e3f2fd;
    color: #1976d2;
    padding: 5px 8px;
    border-radius: 4px;
    font-weight: bold;
    font-size: 0.9em;
}

.var-item span {
    color: #666;
    font-size: 0.9em;
}

.var-item button {
    background: #667eea;
    color: white;
    border: none;
    padding: 8px;
    border-radius: 6px;
    cursor: pointer;
    font-size: 0.85em;
    transition: background 0.3s ease, transform 0.1s; /* <-- ДОБАВИЛИ ЭТУ СТРОКУ */
}

.var-item button:hover {
    background: #5a6fd6;
}

.var-item button:active {
    transform: scale(0.95); /* Легкое нажатие при клике */
}

.file-input {
    width: 100%;
    padding: 15px;
    background: white;
    border: 2px dashed #ccc;
    border-radius: 8px;
    cursor: pointer;
}