body {
    font-family: Arial, sans-serif;
    margin: 0;
    padding: 20px;
    background-color: #f5f5f5;
}

#welcome-screen {
    max-width: 600px;
    margin: 0 auto;
    background: white;
    padding: 40px;
    border-radius: 10px;
    box-shadow: 0 2px 10px rgba(0,0,0,0.1);
    text-align: center;
}

#welcome-screen h1 {
    color: #2c3e50;
    margin-bottom: 20px;
}

#welcome-screen p {
    color: #666;
    line-height: 1.6;
    margin-bottom: 30px;
}

#begin-test {
    background: #3498db;
    color: white;
    border: none;
    padding: 15px 30px;
    font-size: 16px;
    border-radius: 5px;
    cursor: pointer;
    transition: background-color 0.3s;
}

#begin-test:hover {
    background: #2980b9;
}

#test-area {
    max-width: 800px;
    margin: 0 auto;
    background: white;
    padding: 30px;
    border-radius: 10px;
    box-shadow: 0 2px 10px rgba(0,0,0,0.1);
}

#study-progress {
    width: 100%;
    height: 10px;
    background-color: #ecf0f1;
    border-radius: 5px;
    margin-bottom: 30px;
    overflow: hidden;
}

.progress-bar {
    height: 100%;
    background-color: #27ae60;
    width: 0%;
    transition: width 0.5s ease;
}

#study-cue {
    font-size: 24px;
    font-weight: bold;
    text-align: center;
    margin-bottom: 30px;
    color: #2c3e50;
}

#study-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 15px;
    max-width: 400px;
    margin: 0 auto;
}

.study-item {
    background: #ecf0f1;
    border: 2px solid #bdc3c7;
    padding: 20px;
    text-align: center;
    font-size: 18px;
    font-weight: bold;
    border-radius: 8px;
    cursor: pointer;
    transition: all 0.3s ease;
    color: #2c3e50;
}

.study-item:hover {
    background: #d5dbdb;
    border-color: #95a5a6;
}

.study-item.correct {
    background: #d4edda;
    border-color: #27ae60;
    color: #155724;
    cursor: default;
}

.study-item.incorrect {
    background: #f8d7da;
    border-color: #e74c3c;
    color: #721c24;
}

/* Recall Interface Styles */
.recall-interface {
    text-align: center;
}

.recall-interface h2 {
    color: #2c3e50;
    margin-bottom: 10px;
}

.recall-interface p {
    color: #666;
    margin-bottom: 20px;
    line-height: 1.6;
}

#recall-input, #delayed-recall-input {
    width: 100%;
    height: 120px;
    padding: 15px;
    border: 2px solid #bdc3c7;
    border-radius: 8px;
    font-size: 16px;
    resize: vertical;
    margin-bottom: 20px;
    box-sizing: border-box;
}

#recall-input:focus, #delayed-recall-input:focus {
    outline: none;
    border-color: #3498db;
}

#recall-submit, #delayed-recall-submit, #cued-submit, #delayed-cued-submit {
    background: #3498db;
    color: white;
    border: none;
    padding: 12px 24px;
    font-size: 16px;
    border-radius: 5px;
    cursor: pointer;
    transition: background-color 0.3s;
}

#recall-submit:hover, #delayed-recall-submit:hover, 
#cued-submit:hover, #delayed-cued-submit:hover {
    background: #2980b9;
}

#recalled-words-display {
    margin-top: 20px;
    padding: 15px;
    background: #f8f9fa;
    border-radius: 5px;
    text-align: left;
}

/* Cued Recall Styles */
#cued-recall-container, #delayed-cued-container {
    margin: 20px 0;
}

.cued-item {
    background: #f8f9fa;
    padding: 25px;
    border-radius: 8px;
    margin-bottom: 15px;
}

.cued-item p {
    font-size: 18px;
    margin-bottom: 15px;
    color: #2c3e50;
}

#cued-input, #delayed-cued-input {
    width: 100%;
    max-width: 500px;
    padding: 10px;
    border: 2px solid #bdc3c7;
    border-radius: 5px;
    font-size: 16px;
    margin-bottom: 10px;
    resize: vertical;
    box-sizing: border-box;
}

#cued-input:focus, #delayed-cued-input:focus {
    outline: none;
    border-color: #3498db;
}

#cued-recall-done {
    background: #27ae60;
    color: white;
    border: none;
    padding: 12px 24px;
    font-size: 16px;
    border-radius: 5px;
    cursor: pointer;
    margin-top: 20px;
}

#cued-recall-done:hover {
    background: #229954;
}

/* Results Display Styles */
.results-display {
    text-align: center;
}

.results-display h2 {
    color: #27ae60;
    margin-bottom: 30px;
}

.results-summary {
    background: #f8f9fa;
    padding: 25px;
    border-radius: 8px;
    margin-bottom: 30px;
    text-align: left;
}

.results-summary h3, .results-summary h4 {
    color: #2c3e50;
    margin-top: 20px;
    margin-bottom: 10px;
}

.results-summary h3:first-child {
    margin-top: 0;
}

.results-summary p {
    margin: 8px 0;
    color: #444;
}

#download-results, #restart-test {
    background: #3498db;
    color: white;
    border: none;
    padding: 12px 24px;
    font-size: 16px;
    border-radius: 5px;
    cursor: pointer;
    margin: 0 10px;
    transition: background-color 0.3s;
}

#download-results:hover, #restart-test:hover {
    background: #2980b9;
}

#restart-test {
    background: #27ae60;
}

#restart-test:hover {
    background: #229954;
}

/* Responsive Design */
@media (max-width: 768px) {
    body {
        padding: 10px;
    }
    
    #test-area, #welcome-screen {
        padding: 20px;
    }
    
    #study-grid {
        grid-template-columns: 1fr;
        max-width: 300px;
    }
    
    .study-item {
        padding: 15px;
        font-size: 16px;
    }
    
    #study-cue {
        font-size: 20px;
    }
    
    #cued-input, #delayed-cued-input {
        width: 100%;
        max-width: 100%;
        margin-right: 0;
        margin-bottom: 10px;
    }
    
    #dev-controls {
        position: relative !important;
        top: auto !important;
        right: auto !important;
        width: 100% !important;
        margin-top: 20px;
        margin-bottom: 20px;
    }
}

/* Dev Controls Styles */
#dev-controls {
    position: fixed;
    top: 20px;
    right: 20px;
    width: 320px;
    background: #2c3e50;
    color: white;
    border-radius: 8px;
    box-shadow: 0 4px 12px rgba(0,0,0,0.3);
    z-index: 1000;
    font-size: 12px;
    max-height: 80vh;
    overflow-y: auto;
}

.dev-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 10px 15px;
    background: #34495e;
    border-radius: 8px 8px 0 0;
    border-bottom: 1px solid #4a5f7a;
}

.dev-header h3 {
    margin: 0;
    font-size: 14px;
    color: #ecf0f1;
}

.dev-btn-small {
    background: #e74c3c;
    color: white;
    border: none;
    width: 24px;
    height: 24px;
    border-radius: 3px;
    cursor: pointer;
    font-size: 14px;
    font-weight: bold;
}

.dev-btn-small:hover {
    background: #c0392b;
}

.dev-content {
    padding: 15px;
}

.dev-section {
    margin-bottom: 20px;
}

.dev-section:last-child {
    margin-bottom: 0;
}

.dev-section h4 {
    margin: 0 0 10px 0;
    color: #3498db;
    font-size: 13px;
    border-bottom: 1px solid #4a5f7a;
    padding-bottom: 5px;
}

.dev-btn {
    display: block;
    width: 100%;
    background: #3498db;
    color: white;
    border: none;
    padding: 8px 12px;
    margin: 5px 0;
    border-radius: 4px;
    cursor: pointer;
    font-size: 11px;
    transition: background-color 0.2s;
}

.dev-btn:hover {
    background: #2980b9;
}

#dev-words-list {
    background: #34495e;
    padding: 10px;
    border-radius: 4px;
    max-height: 200px;
    overflow-y: auto;
}

.dev-category {
    margin-bottom: 8px;
    font-size: 11px;
}

.dev-category strong {
    color: #f39c12;
    text-transform: capitalize;
}

.dev-word {
    display: inline-block;
    background: #4a5f7a;
    padding: 2px 6px;
    margin: 2px;
    border-radius: 3px;
    font-size: 10px;
}

.dev-word.learned {
    background: #27ae60;
    color: white;
}

#dev-status {
    background: #34495e;
    padding: 10px;
    border-radius: 4px;
    font-size: 11px;
}

#dev-status div {
    margin-bottom: 4px;
}

#dev-status div:last-child {
    margin-bottom: 0;
}

#dev-status strong {
    color: #f39c12;
}