/*
 * numbered-list.css
 * Styles for the numbered list tool.
 * © 2025 TeacherToybox.com. All Rights Reserved.
 */

.numbered-list-container {
    display: flex;
    flex-direction: column;
    width: 100%;
    height: 100%;
    padding: 16px;
    box-sizing: border-box;
    font-family: 'Inter', sans-serif;
}

.list-title {
    text-align: center;
    font-size: 2em;
    font-weight: 700;
    color: var(--text-primary);
    margin: 0 0 16px 0;
    padding: 4px 8px;
    border-radius: 6px;
    cursor: text;
    outline: none;
    transition: background-color 0.2s;
}

.list-title:focus {
    background-color: rgba(0, 0, 0, 0.2);
}

.list-table-wrapper {
    flex-grow: 1;
    overflow-y: auto;
    border: 1px solid var(--border-color);
    border-radius: 8px;
    background-color: rgba(0, 0, 0, 0.1);
}

.list-table {
    width: 100%;
    border-collapse: collapse;
}

.list-table th, .list-table td {
    padding: 12px;
    text-align: left;
    border-bottom: 1px solid var(--border-color);
}

.list-table th {
    color: var(--text-secondary);
    font-weight: 500;
    font-size: 0.9em;
}

.col-number {
    width: 40px;
    text-align: center;
    color: var(--text-secondary);
    font-weight: 500;
}

.col-text input {
    width: 100%;
    background: transparent;
    border: none;
    color: var(--text-primary);
    font-size: 1em;
    outline: none;
    border-bottom: 2px solid transparent;
    transition: border-color 0.2s;
}

.col-text input:focus {
    border-bottom-color: var(--accent-color);
}

.col-counter {
    width: 120px;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
}

.counter-value {
    font-weight: 700;
    font-size: 1.2em;
    min-width: 25px;
    text-align: center;
}

.counter-btn {
    width: 28px;
    height: 28px;
    border-radius: 50%;
    border: none;
    background-color: rgba(255, 255, 255, 0.1);
    color: var(--text-primary);
    cursor: pointer;
    font-size: 1.1em;
    transition: background-color 0.2s;
}

.counter-btn:hover {
    background-color: rgba(255, 255, 255, 0.2);
}

.list-controls {
    display: flex;
    justify-content: center;
    gap: 12px;
    padding-top: 16px;
    flex-shrink: 0;
}

.control-btn-large {
    width: 50px;
    height: 50px;
    font-size: 1.5em;
    border-radius: 8px;
    border: none;
    color: var(--text-primary);
    cursor: pointer;
    background-color: var(--sidebar-bg);
    border: 1px solid var(--border-color);
    transition: all 0.2s;
}

.control-btn-large:hover {
    background-color: var(--accent-color);
    border-color: var(--accent-color);
}

/* --- Light Mode Adjustments --- */
body.light-mode .list-title:focus {
    background-color: rgba(0, 0, 0, 0.05);
}

body.light-mode .list-table-wrapper {
    background-color: rgba(0, 0, 0, 0.02);
}

body.light-mode .col-text input:focus {
    border-bottom-color: var(--accent-color);
}

body.light-mode .counter-btn {
    background-color: rgba(0, 0, 0, 0.08);
}

body.light-mode .counter-btn:hover {
    background-color: rgba(0, 0, 0, 0.15);
}