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

body {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, 'Helvetica Neue', Arial, sans-serif;
    background-color: #f5f7fa;
    color: #333;
    line-height: 1.6;
}

.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 20px;
}

header {
    text-align: center;
    margin-bottom: 40px;
    padding: 30px 0;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    border-radius: 10px;
}

header h1 {
    font-size: 2.5em;
    margin-bottom: 10px;
}

header p {
    font-size: 1.1em;
    opacity: 0.9;
}

main {
    background: white;
    border-radius: 10px;
    padding: 30px;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
}

.input-section {
    margin-bottom: 30px;
}

label {
    display: block;
    font-weight: bold;
    margin-bottom: 10px;
    color: #555;
}

#textInput {
    width: 100%;
    padding: 15px;
    border: 2px solid #e0e0e0;
    border-radius: 8px;
    font-size: 16px;
    font-family: inherit;
    resize: vertical;
    transition: border-color 0.3s;
}

#textInput:focus {
    outline: none;
    border-color: #667eea;
}

.analyze-btn {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    border: none;
    padding: 12px 30px;
    font-size: 18px;
    border-radius: 8px;
    cursor: pointer;
    margin-top: 15px;
    transition: transform 0.2s, box-shadow 0.2s;
}

.analyze-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(102, 126, 234, 0.4);
}

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

.results-section {
    animation: fadeIn 0.5s ease-in;
}

.hidden {
    display: none;
}

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

.results-section h2 {
    color: #667eea;
    margin-bottom: 25px;
    font-size: 1.8em;
}

.metrics-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 20px;
    margin-bottom: 30px;
}

.metric-card {
    background: #f8f9fa;
    border-radius: 10px;
    padding: 20px;
    border: 1px solid #e9ecef;
}

.metric-card h3 {
    color: #764ba2;
    margin-bottom: 15px;
    font-size: 1.2em;
}

.metric-content {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.metric-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 8px 0;
    border-bottom: 1px solid #e0e0e0;
}

.metric-item:last-child {
    border-bottom: none;
}

.metric-label {
    color: #666;
    font-weight: 500;
}

.metric-value {
    font-weight: bold;
    color: #333;
    font-size: 1.1em;
}

.suggestions-section {
    background: #f0f4ff;
    border-radius: 10px;
    padding: 20px;
    margin-bottom: 30px;
}

.suggestions-section h3 {
    color: #667eea;
    margin-bottom: 15px;
}

.suggestions-list {
    list-style: none;
    padding: 0;
}

.suggestions-list li {
    background: white;
    padding: 15px;
    margin-bottom: 10px;
    border-radius: 8px;
    border-left: 4px solid #667eea;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.05);
}

.suggestions-list li:last-child {
    margin-bottom: 0;
}

.difficulty-visualization {
    background: #f8f9fa;
    border-radius: 10px;
    padding: 20px;
}

.difficulty-visualization h3 {
    color: #764ba2;
    margin-bottom: 20px;
}

.difficulty-bar {
    height: 30px;
    background: linear-gradient(to right, #4CAF50 0%, #FFC107 50%, #F44336 100%);
    border-radius: 15px;
    position: relative;
    margin-bottom: 10px;
}

.difficulty-indicator {
    width: 20px;
    height: 20px;
    background: white;
    border: 3px solid #333;
    border-radius: 50%;
    position: absolute;
    top: 50%;
    transform: translate(-50%, -50%);
    transition: all 0.5s ease;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.3);
}

.difficulty-labels {
    display: flex;
    justify-content: space-between;
    color: #666;
    font-size: 0.9em;
}

footer {
    text-align: center;
    margin-top: 40px;
    padding: 20px;
    color: #666;
    font-size: 0.9em;
}

@media (max-width: 768px) {
    header h1 {
        font-size: 2em;
    }
    
    .metrics-grid {
        grid-template-columns: 1fr;
    }
    
    .container {
        padding: 10px;
    }
    
    main {
        padding: 20px;
    }
}