* {
    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;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 20px;
    color: #333;
}

.container {
    background: white;
    border-radius: 20px;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.3);
    max-width: 600px;
    width: 100%;
    padding: 40px;
    animation: fadeIn 0.5s ease-in;
}

@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

h1 {
    text-align: center;
    color: #667eea;
    margin-bottom: 10px;
    font-size: 2.5em;
}

.subtitle {
    text-align: center;
    color: #666;
    margin-bottom: 30px;
    font-size: 1.1em;
}

.info-box {
    background: #f0f4ff;
    border-left: 4px solid #667eea;
    padding: 20px;
    border-radius: 8px;
    margin-bottom: 20px;
}

.info-box h2 {
    color: #667eea;
    margin-bottom: 15px;
    font-size: 1.2em;
}

.info-box ul {
    list-style: none;
    padding-left: 0;
}

.info-box li {
    padding: 8px 0;
    color: #555;
}

.warning-box {
    background: #fff3cd;
    border-left: 4px solid #ffc107;
    padding: 15px;
    border-radius: 8px;
    margin-bottom: 30px;
    font-size: 0.9em;
    color: #856404;
    position: relative;
}

.warning-content {
    transition: max-height 0.3s ease;
    overflow: hidden;
}

.warning-box.collapsed .warning-content {
    max-height: 3.6em; /* Примерно 2 строки */
}

.warning-box:not(.collapsed) .warning-content {
    max-height: 500px;
}

.warning-toggle {
    background: transparent;
    border: none;
    color: #999;
    cursor: pointer;
    padding: 5px 0;
    margin-top: 8px;
    font-size: 0.75em;
    font-weight: normal;
    width: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 5px;
    transition: color 0.2s;
    text-decoration: none;
}

.warning-toggle:hover {
    color: #666;
    text-decoration: underline;
}

.toggle-icon {
    transition: transform 0.3s ease;
    font-size: 0.9em;
}

.warning-box:not(.collapsed) .toggle-icon {
    transform: rotate(180deg);
}

.btn-primary {
    width: 100%;
    padding: 15px;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    border: none;
    border-radius: 10px;
    font-size: 1.1em;
    font-weight: 600;
    cursor: pointer;
    transition: transform 0.2s, box-shadow 0.2s;
}

.btn-primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 5px 20px rgba(102, 126, 234, 0.4);
}

.btn-primary:active {
    transform: translateY(0);
}

/* Test Screen */
.progress-bar {
    width: 100%;
    height: 8px;
    background: #e0e0e0;
    border-radius: 4px;
    margin-bottom: 20px;
    overflow: hidden;
}

.progress-fill {
    height: 100%;
    background: linear-gradient(90deg, #667eea 0%, #764ba2 100%);
    width: 0%;
    transition: width 0.3s ease;
    border-radius: 4px;
}

.question-counter {
    text-align: center;
    color: #666;
    margin-bottom: 30px;
    font-weight: 500;
}

.question-container {
    margin-bottom: 30px;
}

.question h2 {
    color: #333;
    margin-bottom: 15px;
    font-size: 1.3em;
    text-align: left;
}

.question-data {
    background: #f8f9fa;
    padding: 15px;
    border-radius: 8px;
    margin-bottom: 20px;
    font-size: 1.2em;
    text-align: center;
    font-weight: 600;
    color: #667eea;
    border: 2px solid #e0e7ff;
}

.options {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.option {
    padding: 15px 20px;
    background: #f8f9fa;
    border: 2px solid #e0e0e0;
    border-radius: 10px;
    cursor: pointer;
    transition: all 0.2s;
    font-size: 1em;
}

.option:hover {
    background: #f0f4ff;
    border-color: #667eea;
    transform: translateX(5px);
}

.option.selected {
    background: #e0e7ff;
    border-color: #667eea;
}

.option.correct {
    background: #d4edda;
    border-color: #28a745;
    color: #155724;
}

.option.wrong {
    background: #f8d7da;
    border-color: #dc3545;
    color: #721c24;
}

/* Result Screen */
.result-box {
    text-align: center;
    margin: 30px 0;
}

.iq-value {
    font-size: 4em;
    font-weight: bold;
    color: #667eea;
    margin-bottom: 10px;
}

.iq-range {
    font-size: 1.3em;
    color: #666;
    margin-bottom: 15px;
}

.iq-description {
    font-size: 1.1em;
    color: #555;
    margin-bottom: 20px;
    font-weight: 500;
}

.result-warning {
    background: #fff3cd;
    border-left: 4px solid #ffc107;
    padding: 15px;
    border-radius: 8px;
    margin-top: 20px;
    font-size: 0.9em;
    color: #856404;
    text-align: left;
}

.result-warning p {
    margin-bottom: 10px;
}

.result-warning p:last-child {
    margin-bottom: 0;
}

/* CTA Box - Форма сбора контактов */
.cta-box {
    background: linear-gradient(135deg, #f0f4ff 0%, #e8f0ff 100%);
    border: 2px solid #667eea;
    border-radius: 15px;
    padding: 30px;
    margin: 30px 0;
    text-align: center;
    animation: slideUp 0.5s ease-out;
}

@keyframes slideUp {
    from {
        opacity: 0;
        transform: translateY(30px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.cta-icon {
    font-size: 3em;
    margin-bottom: 15px;
}

.cta-box h3 {
    color: #667eea;
    margin-bottom: 10px;
    font-size: 1.5em;
}

.cta-text {
    color: #555;
    margin-bottom: 25px;
    line-height: 1.6;
    font-size: 1em;
}

.contact-form {
    text-align: left;
}

.form-group {
    margin-bottom: 15px;
}

.form-input {
    width: 100%;
    padding: 12px 15px;
    border: 2px solid #e0e0e0;
    border-radius: 8px;
    font-size: 1em;
    transition: all 0.3s;
    font-family: inherit;
}

.form-input:focus {
    outline: none;
    border-color: #667eea;
    box-shadow: 0 0 0 3px rgba(102, 126, 234, 0.1);
}

.form-checkboxes {
    margin: 20px 0;
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.checkbox-label {
    display: flex;
    align-items: center;
    cursor: pointer;
    padding: 12px;
    background: white;
    border-radius: 8px;
    border: 2px solid #e0e0e0;
    transition: all 0.2s;
}

.checkbox-label:hover {
    border-color: #667eea;
    background: #f8f9ff;
}

.checkbox-label input[type="checkbox"] {
    width: 20px;
    height: 20px;
    margin-right: 12px;
    cursor: pointer;
    accent-color: #667eea;
}

.checkbox-label input[type="checkbox"]:checked + span {
    color: #667eea;
    font-weight: 500;
}

.checkbox-label span {
    flex: 1;
    color: #333;
    font-size: 0.95em;
}

.btn-cta {
    margin-top: 20px;
    font-size: 1.1em;
    padding: 16px;
}

.form-note {
    margin-top: 15px;
    font-size: 0.85em;
    color: #888;
    text-align: center;
}

.cta-success {
    text-align: center;
    padding: 20px;
}

.success-icon {
    font-size: 3em;
    margin-bottom: 15px;
}

.cta-success h3 {
    color: #28a745;
    margin-bottom: 10px;
    font-size: 1.5em;
}

.cta-success p {
    color: #555;
    line-height: 1.6;
}

.btn-secondary {
    width: 100%;
    padding: 12px;
    background: white;
    color: #667eea;
    border: 2px solid #667eea;
    border-radius: 10px;
    font-size: 1em;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.2s;
    margin-top: 15px;
}

.btn-secondary:hover {
    background: #f0f4ff;
    transform: translateY(-2px);
}

.btn-secondary:active {
    transform: translateY(0);
}

/* Отправить результаты на email */
.send-results-box {
    background: #f0f4ff;
    border: 2px solid #667eea;
    border-radius: 15px;
    padding: 25px;
    margin: 30px 0;
    text-align: center;
}

.send-results-box h3 {
    color: #667eea;
    margin-bottom: 10px;
    font-size: 1.3em;
}

.send-results-text {
    color: #666;
    margin-bottom: 20px;
    font-size: 0.95em;
}

.send-results-form {
    max-width: 400px;
    margin: 0 auto;
}

.send-results-form .form-group {
    margin-bottom: 15px;
}

.btn-send-results {
    width: 100%;
    margin-top: 10px;
}

.send-results-success {
    text-align: center;
    padding: 20px;
}

.send-results-success .success-icon {
    font-size: 2em;
    margin-bottom: 10px;
}

.send-results-success p {
    color: #28a745;
    font-weight: 500;
}

/* Поделиться результатами */
.share-box {
    background: #f8f9fa;
    border: 2px solid #e0e0e0;
    border-radius: 15px;
    padding: 25px;
    margin: 30px 0;
    text-align: center;
}

.share-box h3 {
    color: #667eea;
    margin-bottom: 10px;
    font-size: 1.3em;
}

.share-text {
    color: #666;
    margin-bottom: 20px;
    font-size: 0.95em;
}

.share-buttons {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    justify-content: center;
}

.btn-share {
    padding: 12px 20px;
    border: none;
    border-radius: 8px;
    font-size: 0.95em;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.2s;
    color: white;
    min-width: 120px;
}

.btn-share-vk {
    background: #4C75A3;
}

.btn-share-vk:hover {
    background: #3d5f87;
    transform: translateY(-2px);
}

.btn-share-telegram {
    background: #0088cc;
}

.btn-share-telegram:hover {
    background: #006ba3;
    transform: translateY(-2px);
}

.btn-share-whatsapp {
    background: #25D366;
}

.btn-share-whatsapp:hover {
    background: #1da851;
    transform: translateY(-2px);
}

.btn-share-link {
    background: #667eea;
}

.btn-share-link:hover {
    background: #5568d3;
    transform: translateY(-2px);
}

.share-success {
    margin-top: 15px;
    color: #28a745;
    font-weight: 500;
    font-size: 0.95em;
}

/* Форма сбора контактов на стартовой странице */
.cta-box-start {
    background: linear-gradient(135deg, #f0f4ff 0%, #e8f0ff 100%);
    border: 2px solid #667eea;
    border-radius: 15px;
    padding: 30px;
    margin: 30px 0;
    text-align: center;
    animation: slideUp 0.5s ease-out;
}

.cta-box-start .cta-icon {
    font-size: 3em;
    margin-bottom: 15px;
}

.cta-box-start h3 {
    color: #667eea;
    margin-bottom: 10px;
    font-size: 1.5em;
}

.cta-box-start .cta-text {
    color: #555;
    margin-bottom: 25px;
    line-height: 1.6;
    font-size: 1em;
}

/* Поделиться на стартовой странице */
.share-box-start {
    margin-top: 25px;
    padding-top: 20px;
    border-top: 1px solid #e0e0e0;
    text-align: center;
}

.share-buttons-start {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    justify-content: center;
    margin-bottom: 10px;
}

.btn-share-start {
    padding: 10px 16px;
    border: none;
    border-radius: 8px;
    font-size: 0.9em;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.2s;
    color: white;
    min-width: 100px;
}

.btn-share-start.btn-share-vk {
    background: #4C75A3;
}

.btn-share-start.btn-share-vk:hover {
    background: #3d5f87;
    transform: translateY(-2px);
}

.btn-share-start.btn-share-telegram {
    background: #0088cc;
}

.btn-share-start.btn-share-telegram:hover {
    background: #006ba3;
    transform: translateY(-2px);
}

.btn-share-start.btn-share-whatsapp {
    background: #25D366;
}

.btn-share-start.btn-share-whatsapp:hover {
    background: #1da851;
    transform: translateY(-2px);
}

.btn-share-start.btn-share-link {
    background: #667eea;
}

.btn-share-start.btn-share-link:hover {
    background: #5568d3;
    transform: translateY(-2px);
}

.btn-share-start.btn-share-bookmark {
    background: #ffc107;
    color: #333;
}

.btn-share-start.btn-share-bookmark:hover {
    background: #e0a800;
    transform: translateY(-2px);
}

.share-success-start,
.bookmark-success {
    margin-top: 10px;
    color: #28a745;
    font-weight: 500;
    font-size: 0.9em;
}

/* Ссылка на полноценные тесты */
.full-test-link {
    margin-top: 20px;
    text-align: center;
    padding-top: 20px;
    border-top: 1px solid #e0e0e0;
}

.full-test-link a {
    color: #667eea;
    text-decoration: none;
    font-size: 0.9em;
    transition: color 0.2s;
}

.full-test-link a:hover {
    color: #764ba2;
    text-decoration: underline;
}

/* Страница полноценных тестов */
.full-tests-screen {
    animation: fadeIn 0.5s ease-in;
}

.back-link {
    display: inline-block;
    color: #667eea;
    text-decoration: none;
    margin-bottom: 20px;
    font-size: 0.95em;
    transition: color 0.2s;
}

.back-link:hover {
    color: #764ba2;
    text-decoration: underline;
}

.tests-info {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 20px;
    margin: 30px 0;
}

.test-type-box {
    background: #f8f9fa;
    border: 2px solid #e0e0e0;
    border-radius: 12px;
    padding: 25px;
    text-align: center;
    transition: all 0.3s;
}

.test-type-box:hover {
    border-color: #667eea;
    box-shadow: 0 5px 20px rgba(102, 126, 234, 0.1);
    transform: translateY(-3px);
}

.test-icon {
    font-size: 3em;
    margin-bottom: 15px;
}

.test-type-box h3 {
    color: #667eea;
    margin-bottom: 10px;
    font-size: 1.3em;
}

.test-duration {
    color: #888;
    font-size: 0.9em;
    margin-bottom: 15px;
    font-weight: 500;
}

.test-type-box ul {
    list-style: none;
    padding: 0;
    text-align: left;
    margin-top: 15px;
}

.test-type-box li {
    padding: 8px 0;
    color: #555;
    font-size: 0.95em;
}

/* Responsive */
@media (max-width: 600px) {
    .container {
        padding: 20px;
    }
    
    h1 {
        font-size: 2em;
    }
    
    .iq-value {
        font-size: 3em;
    }
    
    .tests-info {
        grid-template-columns: 1fr;
    }
    
    .share-buttons {
        flex-direction: column;
    }
    
    .btn-share {
        width: 100%;
    }
    
    .share-buttons-start {
        flex-direction: column;
    }
    
    .btn-share-start {
        width: 100%;
    }
}

