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

body {
    font-family: 'Nunito', 'Rounded Mplus 1c', -apple-system, BlinkMacSystemFont, 'Segoe UI', system-ui, sans-serif;
    background: #FFF8F0;
    color: #3D2E1F;
    font-size: 19px;
    line-height: 1.7;
    min-height: 100vh;
    -webkit-font-smoothing: antialiased;
}

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

/* Navigation */
.nav {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 24px 0;
    margin-bottom: 40px;
    border-bottom: 2px solid #F0E6D8;
}

.nav-brand {
    font-size: 22px;
    font-weight: 800;
    color: #E8734A;
    text-decoration: none;
    letter-spacing: -0.5px;
}

.nav-left {
    display: flex;
    align-items: center;
    gap: 16px;
}

.nav-right {
    display: flex;
    align-items: center;
    gap: 24px;
}

.nav-link {
    font-size: 17px;
    font-weight: 600;
    color: #7A6B5D;
    text-decoration: none;
    padding: 8px 16px;
    border-radius: 12px;
    transition: all 0.2s;
}

.nav-link:hover {
    background: #FFF0E0;
    color: #E8734A;
}

.nav-home {
    font-size: 20px;
    font-weight: 700;
    color: #E8734A;
}

.nav-home:hover {
    color: #D45A30;
}

.nav-user {
    font-size: 15px;
    font-weight: 600;
    color: #9E8E7E;
    padding: 6px 10px;
}

.nav-user-wrap {
    position: relative;
}

.nav-user-btn {
    display: flex;
    align-items: center;
    gap: 6px;
    font-size: 15px;
    font-weight: 600;
    color: #9E8E7E;
    padding: 6px 10px;
    background: none;
    border: none;
    cursor: pointer;
    font-family: inherit;
    border-radius: 8px;
    transition: background 0.15s;
}

.nav-user-btn:hover {
    background: #FFF0E0;
    color: #E8734A;
}

.nav-dropdown {
    display: none;
    position: absolute;
    top: calc(100% + 8px);
    right: 0;
    background: #FFFFFF;
    border: 2px solid #E8DDD0;
    border-radius: 16px;
    padding: 8px;
    min-width: 220px;
    box-shadow: 0 12px 40px rgba(60, 40, 20, 0.12);
    z-index: 500;
}

.nav-dropdown.open {
    display: block;
    animation: modalFadeIn 0.15s ease-out;
}

.nav-dropdown-item {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 10px 14px;
    font-size: 15px;
    font-weight: 600;
    color: #5A4A3A;
    border-radius: 10px;
    text-decoration: none;
}

.nav-dropdown-item:hover {
    background: #FFF8F4;
}

.nav-dropdown-logout {
    color: #C04040;
    justify-content: center;
}

.nav-dropdown-divider {
    height: 1px;
    background: #F0E6D8;
    margin: 6px 8px;
}

.toggle-lang {
    display: flex;
    border: 2px solid #E8DDD0;
    border-radius: 8px;
    overflow: hidden;
}

.lang-opt {
    padding: 4px 12px;
    font-size: 13px;
    font-weight: 700;
    border: none;
    background: none;
    cursor: pointer;
    color: #7A6B5D;
    font-family: inherit;
    transition: all 0.15s;
}

.lang-opt.active {
    background: #E8734A;
    color: #fff;
}

.toggle-switch {
    position: relative;
    width: 44px;
    height: 24px;
    flex-shrink: 0;
}

.toggle-switch input {
    opacity: 0;
    width: 0;
    height: 0;
}

.toggle-slider {
    position: absolute;
    inset: 0;
    background: #D0C4B8;
    border-radius: 24px;
    cursor: pointer;
    transition: background 0.2s;
}

.toggle-slider::before {
    content: '';
    position: absolute;
    width: 18px;
    height: 18px;
    left: 3px;
    top: 3px;
    background: #fff;
    border-radius: 50%;
    transition: transform 0.2s;
    box-shadow: 0 1px 4px rgba(0,0,0,0.15);
}

.toggle-switch input:checked + .toggle-slider {
    background: #E8734A;
}

.toggle-switch input:checked + .toggle-slider::before {
    transform: translateX(20px);
}

/* Flash messages */
.flash-messages {
    margin-bottom: 24px;
}

.flash {
    padding: 16px 20px;
    border-radius: 16px;
    font-size: 17px;
    font-weight: 600;
}

.flash-error {
    background: #FFF0F0;
    color: #C04040;
    border: 2px solid #FFD4D4;
}

.flash-success {
    background: #F0FFF4;
    color: #2E7D4A;
    border: 2px solid #C8F0D4;
}

/* Language toggle */
.lang-toggle {
    font-weight: 700;
    font-size: 14px;
    padding: 4px 10px;
    border-radius: 6px;
    background: #F0E6D8;
    color: #5A4A3A;
}

.lang-toggle:hover {
    background: #E8DDD0;
}

.auth-lang-toggle {
    text-align: right;
    margin-bottom: 12px;
}

.lang-toggle-btn {
    display: inline-block;
    font-weight: 700;
    font-size: 14px;
    padding: 4px 10px;
    border-radius: 6px;
    background: #F0E6D8;
    color: #5A4A3A;
    text-decoration: none;
}

.lang-toggle-btn:hover {
    background: #E8DDD0;
}

/* Auth */
.auth-container {
    max-width: 420px;
    margin: 60px auto;
    text-align: center;
    background: #FFFFFF;
    padding: 48px 40px;
    border-radius: 28px;
    box-shadow: 0 8px 40px rgba(140, 100, 60, 0.08), 0 2px 8px rgba(140, 100, 60, 0.04);
}

.auth-container h1 {
    font-size: 32px;
    font-weight: 800;
    color: #E8734A;
    margin-bottom: 8px;
    letter-spacing: -0.5px;
}

.auth-subtitle {
    color: #7A6B5D;
    font-size: 18px;
    margin-bottom: 36px;
    font-weight: 500;
}

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

.auth-link {
    margin-top: 28px;
    font-size: 17px;
    color: #7A6B5D;
    font-weight: 500;
}

.auth-link a {
    color: #E8734A;
    text-decoration: none;
    font-weight: 700;
}

.auth-link a:hover {
    color: #D45A30;
    text-decoration: underline;
}

/* Forms */
.form-group {
    margin-bottom: 24px;
}

.form-group label {
    display: block;
    font-size: 16px;
    font-weight: 700;
    color: #5A4A3A;
    margin-bottom: 10px;
}

.form-group input[type="email"],
.form-group input[type="password"],
.form-group input[type="text"] {
    width: 100%;
    padding: 16px 20px;
    font-size: 18px;
    border: 2px solid #E8DDD0;
    border-radius: 14px;
    background: #FFFCF8;
    color: #3D2E1F;
    transition: border-color 0.2s, box-shadow 0.2s;
    font-family: inherit;
}

.form-group input:focus {
    outline: none;
    border-color: #E8734A;
    box-shadow: 0 0 0 4px rgba(232, 115, 74, 0.12);
}

/* Buttons */
.btn {
    display: inline-block;
    padding: 18px 36px;
    font-size: 18px;
    font-weight: 700;
    border: none;
    border-radius: 16px;
    cursor: pointer;
    text-decoration: none;
    text-align: center;
    transition: all 0.2s;
    font-family: inherit;
}

.btn:active {
    transform: scale(0.97);
}

.btn-primary {
    background: linear-gradient(135deg, #E8734A 0%, #F5A623 100%);
    color: #fff;
    width: 100%;
    box-shadow: 0 4px 16px rgba(232, 115, 74, 0.25);
}

.btn-primary:hover {
    box-shadow: 0 6px 24px rgba(232, 115, 74, 0.35);
    transform: translateY(-1px);
}

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

.btn-secondary {
    background: #FFFFFF;
    color: #5A4A3A;
    border: 2px solid #E8DDD0;
}

.btn-secondary:hover {
    border-color: #E8734A;
    color: #E8734A;
    background: #FFF8F4;
}

.btn-large {
    padding: 20px 40px;
    font-size: 20px;
}

/* Dashboard */
.dashboard h1 {
    font-size: 28px;
    font-weight: 800;
    margin-bottom: 6px;
    color: #3D2E1F;
    letter-spacing: -0.5px;
}

.dashboard-intro {
    color: #7A6B5D;
    font-size: 18px;
    margin-bottom: 36px;
    font-weight: 500;
}

.dashboard-section {
    margin-bottom: 40px;
}

.dashboard-section h2 {
    font-size: 15px;
    font-weight: 700;
    color: #A08060;
    margin-bottom: 16px;
    text-transform: uppercase;
    letter-spacing: 1px;
}

.category-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 12px;
}

@media (max-width: 900px) {
    .category-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

.category-card {
    width: 100%;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 24px 16px;
    background: #FFFFFF;
    border: 2px solid #E8DDD0;
    border-radius: 20px;
    cursor: pointer;
    font-family: inherit;
    transition: all 0.2s;
    box-shadow: 0 2px 8px rgba(140, 100, 60, 0.04);
    text-align: center;
}

.category-card:hover {
    border-color: #E8734A;
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(232, 115, 74, 0.12);
}

.category-label {
    font-size: 19px;
    font-weight: 700;
    color: #3D2E1F;
    margin-bottom: 4px;
}

.category-count {
    font-size: 14px;
    color: #A08060;
    font-weight: 600;
}

.start-option {
    margin: 0;
}

.session-card-action {
    width: 100%;
    cursor: pointer;
    text-align: left;
    font-family: inherit;
    border: 2px solid #E8DDD0;
    font-size: 18px;
}

.session-card-action:hover {
    border-color: #E8734A;
    background: #FFF8F4;
    transform: translateY(-1px);
    box-shadow: 0 4px 16px rgba(232, 115, 74, 0.1);
}

.session-meta {
    font-size: 15px;
    color: #A08060;
    font-weight: 600;
}

/* File upload */
.import-form,
.custom-form {
    background: #FFFFFF;
    border: 2px solid #E8DDD0;
    border-radius: 20px;
    padding: 24px;
    margin-bottom: 12px;
    box-shadow: 0 4px 16px rgba(140, 100, 60, 0.06);
}

.file-upload-area {
    position: relative;
    border: 3px dashed #E0D0C0;
    border-radius: 16px;
    padding: 36px 20px;
    text-align: center;
    cursor: pointer;
    transition: all 0.2s;
    background: #FFFCF8;
}

.file-upload-area:hover,
.file-upload-area.dragover {
    border-color: #E8734A;
    background: #FFF8F4;
}

.file-upload-area.has-file {
    border-color: #5BAE7C;
    border-style: solid;
    background: #F0FFF4;
}

.file-upload-area input[type="file"] {
    position: absolute;
    inset: 0;
    opacity: 0;
    cursor: pointer;
}

.file-upload-label {
    font-size: 17px;
    color: #7A6B5D;
    font-weight: 600;
}

.card-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 12px;
    margin-top: 16px;
}

.card-option {
    cursor: pointer;
}

.card-option input {
    display: none;
}

.card-content {
    display: flex;
    flex-direction: column;
    align-items: center;
    padding: 24px 16px;
    background: #FFFFFF;
    border: 2px solid #E8DDD0;
    border-radius: 16px;
    transition: all 0.2s;
}

.card-option input:checked + .card-content {
    border-color: #E8734A;
    background: #FFF8F4;
    box-shadow: 0 4px 16px rgba(232, 115, 74, 0.1);
}

.card-title {
    font-size: 18px;
    font-weight: 700;
}

.card-count {
    font-size: 15px;
    color: #A08060;
    margin-top: 4px;
    font-weight: 600;
}

.depth-options {
    display: flex;
    flex-direction: column;
    gap: 10px;
    margin-top: 16px;
}

.depth-option {
    cursor: pointer;
}

.depth-option input {
    display: none;
}

.depth-content {
    display: flex;
    flex-direction: column;
    padding: 18px 22px;
    background: #FFFFFF;
    border: 2px solid #E8DDD0;
    border-radius: 16px;
    transition: all 0.2s;
}

.depth-option input:checked + .depth-content {
    border-color: #E8734A;
    background: #FFF8F4;
}

.depth-title {
    font-size: 18px;
    font-weight: 700;
}

.depth-desc {
    font-size: 16px;
    color: #7A6B5D;
    margin-top: 4px;
}

.custom-textarea {
    width: 100%;
    padding: 16px 20px;
    font-size: 18px;
    border: 2px solid #E8DDD0;
    border-radius: 14px;
    background: #FFFCF8;
    color: #3D2E1F;
    resize: vertical;
    min-height: 140px;
    line-height: 1.7;
    font-family: inherit;
    margin-top: 8px;
}

.custom-textarea:focus {
    outline: none;
    border-color: #E8734A;
    box-shadow: 0 0 0 4px rgba(232, 115, 74, 0.12);
}

.session-form .btn {
    margin-top: 32px;
}

/* Active sessions */
.active-sessions {
    margin-top: 48px;
    padding-top: 32px;
    border-top: 2px solid #F0E6D8;
}

.active-sessions h2 {
    font-size: 18px;
    font-weight: 700;
    color: #5A4A3A;
    margin-bottom: 16px;
}

.session-progress {
    font-size: 15px;
    color: #A08060;
    font-weight: 700;
}

.session-card {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 18px 24px;
    background: #FFFFFF;
    border: 2px solid #E8DDD0;
    border-radius: 16px;
    text-decoration: none;
    color: inherit;
    margin-bottom: 12px;
    font-size: 17px;
    transition: all 0.2s;
    box-shadow: 0 2px 8px rgba(140, 100, 60, 0.04);
}

.session-card:hover {
    border-color: #E8734A;
    transform: translateY(-1px);
    box-shadow: 0 4px 16px rgba(232, 115, 74, 0.1);
}

.session-info {
    font-weight: 700;
}

.session-card-wrapper {
    position: relative;
    display: flex;
    align-items: center;
    gap: 10px;
    margin-bottom: 12px;
}

.session-card-wrapper .session-card {
    flex: 1;
    margin-bottom: 0;
}

.session-card-preparing {
    border-color: #E8DDD0;
    background: #FFFCF8;
}

.session-card-preparing:hover {
    border-color: #F5A623;
    box-shadow: 0 4px 16px rgba(245, 166, 35, 0.1);
}

.session-card-recording {
    border-color: #D0E8D8;
    background: #F8FFF8;
}

.session-card-recording:hover {
    border-color: #5BAE7C;
    box-shadow: 0 4px 16px rgba(91, 174, 124, 0.12);
}

.session-status-badge {
    font-size: 13px;
    font-weight: 700;
    padding: 4px 12px;
    border-radius: 20px;
    white-space: nowrap;
}

.status-preparing {
    background: #FFF3E0;
    color: #C07A20;
}

.status-recording {
    background: #E8F8EC;
    color: #2E7D4A;
}

.session-delete-btn {
    width: 30px;
    height: 30px;
    min-width: 30px;
    border-radius: 50%;
    border: 1.5px solid #C0A090;
    background: none;
    color: #C0A090;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: color 0.2s, border-color 0.2s;
}

.session-delete-btn:hover {
    color: #D32F2F;
    border-color: #D32F2F;
}

.session-delete-btn svg {
    width: 14px;
    height: 14px;
}

/* Preview / Edit questions */
.preview-page h1 {
    font-size: 26px;
    font-weight: 800;
    margin-bottom: 8px;
    color: #3D2E1F;
}

.preview-heading {
    font-size: 22px;
    font-weight: 700;
    color: #3D2E1F;
    margin-bottom: 8px;
    margin-top: 28px;
}

.preview-intro {
    color: #7A6B5D;
    font-size: 17px;
    margin-bottom: 28px;
    font-weight: 500;
}

.question-edit-list {
    display: flex;
    flex-direction: column;
    gap: 8px;
    margin-bottom: 20px;
}

.question-edit-item {
    display: flex;
    align-items: center;
    gap: 10px;
}

.question-edit-num {
    font-size: 15px;
    color: #A08060;
    min-width: 28px;
    text-align: right;
    font-weight: 700;
}

.question-edit-input {
    flex: 1;
    padding: 14px 18px;
    font-size: 17px;
    border: 2px solid #E8DDD0;
    border-radius: 12px;
    background: #FFFCF8;
    color: #3D2E1F;
    font-family: inherit;
    transition: all 0.2s;
    resize: none;
    overflow: hidden;
    line-height: 1.5;
}

.question-edit-input:focus {
    outline: none;
    border-color: #E8734A;
    box-shadow: 0 0 0 4px rgba(232, 115, 74, 0.12);
}

.question-delete-btn {
    width: 30px;
    height: 30px;
    min-width: 30px;
    border-radius: 50%;
    border: 1.5px solid #C0A090;
    background: none;
    color: #C0A090;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: color 0.2s, border-color 0.2s;
}

.question-delete-btn:hover {
    color: #D32F2F;
    border-color: #D32F2F;
}

.question-delete-btn svg {
    width: 14px;
    height: 14px;
}

.preview-buttons {
    margin-bottom: 32px;
}

.preview-actions {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 16px;
}

.preview-actions .btn-primary {
    width: 100%;
}

.preview-actions .btn-secondary {
    width: 100%;
}

.btn-restore {
    color: #A08060;
    font-size: 16px;
    font-weight: 600;
}

.btn-restore:hover {
    color: #C04040;
}

/* Record page */
.record-page {
    padding-bottom: 60px;
}

.record-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 40px;
}

.record-count {
    font-size: 16px;
    color: #A08060;
    font-weight: 600;
}

.record-edit-link {
    font-size: 16px;
    color: #A08060;
    text-decoration: none;
    font-weight: 600;
}

.record-edit-link:hover {
    color: #E8734A;
}

.record-current {
    text-align: center;
    margin-bottom: 48px;
}

.record-question {
    font-size: 24px;
    font-weight: 600;
    line-height: 1.5;
    color: #3D2E1F;
    margin-bottom: 8px;
}

.record-hint-text {
    font-size: 17px;
    color: #7A6B5D;
    margin-bottom: 40px;
    font-style: italic;
}

.record-controls {
    display: flex;
    flex-direction: column;
    align-items: center;
    margin-bottom: 24px;
}

.record-timer {
    font-size: 26px;
    font-family: 'SF Mono', 'JetBrains Mono', 'Fira Code', monospace;
    color: #A08060;
    margin-bottom: 24px;
    min-height: 32px;
    font-weight: 400;
}

.record-btn {
    width: 88px;
    height: 88px;
    border-radius: 50%;
    border: 4px solid #D32F2F;
    background: #FFF5F5;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 0;
    transition: transform 0.1s;
}

.record-btn:active {
    transform: scale(0.94);
}

.record-btn-inner {
    width: 34px;
    height: 34px;
    border-radius: 50%;
    background: #D32F2F;
    transition: border-radius 0.2s, width 0.2s, height 0.2s;
}

.record-btn.recording .record-btn-inner {
    width: 26px;
    height: 26px;
    border-radius: 6px;
}

.record-btn.recording {
    animation: pulse 2s infinite;
    border-color: #E85040;
}

@keyframes pulse {
    0% { box-shadow: 0 0 0 0 rgba(232, 115, 74, 0.35); }
    70% { box-shadow: 0 0 0 18px rgba(232, 115, 74, 0); }
    100% { box-shadow: 0 0 0 0 rgba(232, 115, 74, 0); }
}

.record-status {
    margin-top: 16px;
    font-size: 16px;
    color: #7A6B5D;
    font-weight: 600;
}

.record-status.error {
    color: #C04040;
}

.record-status.done {
    color: #2E7D4A;
}

.btn-next {
    margin-top: 24px;
    width: 100%;
}

.record-done {
    text-align: center;
    padding: 40px 0;
}

.record-done h2 {
    font-size: 26px;
    color: #3D2E1F;
    font-weight: 800;
    margin-bottom: 8px;
}

.record-done p {
    color: #7A6B5D;
    font-size: 18px;
    margin-bottom: 28px;
}

/* Completed recordings list */
.completed-recordings {
    border-top: 2px solid #F0E6D8;
    padding-top: 28px;
    margin-top: 32px;
}

.completed-recordings h3 {
    font-size: 16px;
    font-weight: 700;
    color: #A08060;
    margin-bottom: 16px;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.completed-item {
    padding: 14px 8px;
    border-bottom: 1px solid #F0E6D8;
    border-radius: 4px;
}

.completed-item:nth-child(even) {
    background-color: #F8F4EF;
}

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

.completed-row-top {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 14px;
}

.completed-question {
    flex: 1;
    font-size: 16px;
    color: #5A4A3A;
    line-height: 1.5;
    font-weight: 500;
}

.completed-index {
    color: #A08060;
    font-weight: 700;
}

.completed-actions {
    display: flex;
    align-items: center;
    gap: 12px;
    flex-shrink: 0;
}

.completed-row-bottom {
    display: flex;
    align-items: center;
    gap: 12px;
    margin-top: 4px;
    padding-left: 2px;
}

.completed-date {
    font-size: 13px;
    color: #A08060;
}

.completed-duration {
    font-size: 15px;
    color: #A08060;
    font-family: 'SF Mono', 'JetBrains Mono', 'Fira Code', monospace;
    font-weight: 600;
}

.completed-note {
    font-size: 13px;
    color: #7A6B5D;
    font-style: italic;
}

.delete-btn {
    width: 30px;
    height: 30px;
    min-width: 30px;
    border-radius: 50%;
    border: 1.5px solid #C0A090;
    background: none;
    color: #C0A090;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: color 0.2s, border-color 0.2s;
}

.delete-btn:hover {
    color: #D32F2F;
    border-color: #D32F2F;
}

.delete-btn svg {
    width: 14px;
    height: 14px;
}

/* Dashboard alt */
.dashboard-alt {
    margin-top: 16px;
    text-align: center;
}

.btn-text {
    background: none;
    border: none;
    color: #A08060;
    font-size: 17px;
    cursor: pointer;
    padding: 10px;
    font-weight: 600;
}

.btn-text:hover {
    color: #E8734A;
}

/* History */
.history h1 {
    font-size: 28px;
    font-weight: 800;
    margin-bottom: 28px;
    color: #3D2E1F;
}

.history-empty {
    color: #7A6B5D;
    font-size: 18px;
    font-weight: 500;
}

.history-session {
    margin-bottom: 24px;
    background: #FFFFFF;
    border: 2px solid #E8DDD0;
    border-radius: 20px;
    padding: 24px;
    box-shadow: 0 4px 16px rgba(140, 100, 60, 0.06);
}

.history-session-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 16px;
    padding-bottom: 14px;
    border-bottom: 2px solid #F0E6D8;
}

.history-category {
    font-size: 18px;
    font-weight: 700;
    color: #3D2E1F;
}

.history-meta {
    font-size: 15px;
    color: #A08060;
    font-weight: 600;
}

.history-recordings {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 12px;
}

@media (max-width: 900px) {
    .history-recordings {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (max-width: 600px) {
    .history-recordings {
        grid-template-columns: 1fr;
    }
}

.history-item {
    display: flex;
    flex-direction: column;
    gap: 8px;
    padding: 12px;
    border: 1px solid #F0E6D8;
    border-radius: 10px;
    background: #FFFCF8;
    position: relative;
}

.history-item-number {
    position: absolute;
    top: 8px;
    right: 10px;
    font-size: 13px;
    font-weight: 700;
    color: #C0A090;
}

.history-item:last-child {
}

.history-item.dragging {
    opacity: 0.4;
}

.history-item.drag-over-top {
    box-shadow: 0 -2px 0 #E8734A;
}

.history-item.drag-over-bottom {
    box-shadow: 0 2px 0 #E8734A;
}

.history-item-left {
    flex: 1;
    min-width: 0;
}

.history-question {
    font-size: 17px;
    line-height: 1.5;
    color: #5A4A3A;
    font-weight: 500;
}

.history-index {
    color: #A08060;
    margin-right: 8px;
    font-size: 15px;
    font-weight: 700;
}

.history-note {
    font-size: 14px;
    color: #8A7A6A;
    font-style: italic;
    margin-top: 4px;
    padding-left: 26px;
}

.history-date {
    font-size: 13px;
    color: #9E8E7E;
    margin-top: 4px;
    padding-left: 26px;
}

.history-duration {
    font-size: 15px;
    color: #A08060;
    white-space: nowrap;
    font-family: 'SF Mono', 'JetBrains Mono', 'Fira Code', monospace;
    font-weight: 600;
}

.history-no-file {
    font-size: 14px;
    color: #C0A080;
    white-space: nowrap;
}

.history-header-right {
    display: flex;
    align-items: center;
    gap: 12px;
}

.history-item-actions {
    display: flex;
    align-items: center;
    gap: 8px;
    flex-shrink: 0;
}

.history-delete-btn {
    width: 30px;
    height: 30px;
    border-radius: 50%;
    border: 1.5px solid #C0A090;
    background: none;
    color: #C0A090;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: color 0.2s, border-color 0.2s;
}

.history-delete-btn svg {
    width: 14px;
    height: 14px;
}

.history-delete-btn:hover {
    color: #D32F2F;
    border-color: #D32F2F;
}

.history-delete-session-btn {
    width: 30px;
    height: 30px;
    border-radius: 50%;
    border: 1.5px solid #C0A090;
    background: none;
    color: #C0A090;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: color 0.2s, border-color 0.2s;
}

.history-delete-session-btn:hover {
    color: #D32F2F;
    border-color: #D32F2F;
}

.play-btn {
    width: 52px;
    height: 52px;
    min-width: 52px;
    border-radius: 50%;
    border: 2px solid #5BAE7C;
    background: #F0FFF4;
    color: #5BAE7C;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.2s;
}

.play-btn:hover {
    background: #5BAE7C;
    color: #FFFFFF;
    box-shadow: 0 4px 12px rgba(91, 174, 124, 0.3);
}

.play-btn svg {
    width: 20px;
    height: 20px;
}

.history-audio {
    display: none;
}

/* Wide container for record page */
.container-wide {
    max-width: 1100px;
    margin: 0 auto;
    padding: 0 40px;
}

.container-dashboard {
    max-width: 1200px;
}

/* ============================================
   QUESTION CLOUD - The Star of the Show
   ============================================ */
.question-cloud {
    display: flex;
    flex-wrap: wrap;
    gap: 14px;
    margin-bottom: 44px;
    justify-content: center;
    padding: 24px;
    background: linear-gradient(135deg, #FFFAF5 0%, #FFF5EE 50%, #FFF8F5 100%);
    border-radius: 32px;
    border: 2px solid #F0E6D8;
    box-shadow: inset 0 2px 20px rgba(232, 180, 120, 0.06);
}

.question-chip {
    padding: 20px 30px;
    border-radius: 24px;
    font-size: 20px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    line-height: 1.4;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    text-align: center;
    position: relative;
    border: 2px solid transparent;
    animation: float 6s ease-in-out infinite;
}

/* Varying colors for chips - warm pastel palette */
.question-chip:nth-child(7n+1) {
    background: linear-gradient(135deg, #FFE8D6 0%, #FFDBC4 100%);
    color: #8B4513;
    animation-delay: 0s;
}

.question-chip:nth-child(7n+2) {
    background: linear-gradient(135deg, #E8F4FD 0%, #D4ECFB 100%);
    color: #2C5F7A;
    animation-delay: -1s;
}

.question-chip:nth-child(7n+3) {
    background: linear-gradient(135deg, #F0FFF4 0%, #DCF5E4 100%);
    color: #2E6B3F;
    animation-delay: -2s;
}

.question-chip:nth-child(7n+4) {
    background: linear-gradient(135deg, #FFF3E0 0%, #FFE8CC 100%);
    color: #8B6914;
    animation-delay: -3s;
}

.question-chip:nth-child(7n+5) {
    background: linear-gradient(135deg, #F3E8FF 0%, #E8D5FF 100%);
    color: #5B2E8B;
    animation-delay: -4s;
}

.question-chip:nth-child(7n+6) {
    background: linear-gradient(135deg, #FFE8F0 0%, #FFD4E8 100%);
    color: #8B2E5B;
    animation-delay: -5s;
}

.question-chip:nth-child(7n+7) {
    background: linear-gradient(135deg, #E8FFF8 0%, #D4FFF0 100%);
    color: #1A6B5A;
    animation-delay: -0.5s;
}


@keyframes float {
    0%, 100% { transform: translateY(0px); }
    50% { transform: translateY(-6px); }
}

.question-chip:hover {
    transform: translateY(-4px) scale(1.04);
    box-shadow: 0 8px 28px rgba(0, 0, 0, 0.1);
    border-color: #E8734A;
    z-index: 2;
}

.question-chip.active {
    transform: translateY(-4px) scale(1.05);
    border-color: #E8734A;
    box-shadow: 0 8px 32px rgba(232, 115, 74, 0.2);
    animation: none;
    z-index: 3;
}

.question-chip.recorded {
    background: linear-gradient(135deg, #E8F8EC 0%, #D0F0D8 100%) !important;
    color: #2E6B3F !important;
    border-color: #5BAE7C;
    opacity: 0.85;
}

.question-chip.recorded:hover {
    opacity: 1;
    transform: translateY(-4px) scale(1.04);
    box-shadow: 0 8px 24px rgba(91, 174, 124, 0.2);
}

.question-chip-check {
    width: 26px;
    height: 26px;
    min-width: 26px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    font-size: 14px;
    font-weight: 800;
    background: #5BAE7C;
    color: #FFFFFF;
    box-shadow: 0 2px 8px rgba(91, 174, 124, 0.3);
}

.question-chip-text {
    word-break: break-word;
}

.add-question-area {
    margin-bottom: 32px;
    text-align: center;
}

.btn-add-question {
    background: none;
    border: 2px dashed #E0D0C0;
    border-radius: 16px;
    padding: 14px 28px;
    font-size: 17px;
    font-weight: 700;
    color: #A08060;
    cursor: pointer;
    font-family: inherit;
    transition: all 0.2s;
}

.btn-add-question:hover {
    border-color: #E8734A;
    color: #E8734A;
}

.add-question-form {
    display: flex;
    gap: 12px;
    margin-top: 14px;
    align-items: center;
}

.add-question-input {
    flex: 1;
    padding: 14px 20px;
    font-size: 17px;
    border: 2px solid #E8DDD0;
    border-radius: 14px;
    background: #FFFFFF;
    color: #3D2E1F;
    font-family: inherit;
}

.add-question-input:focus {
    outline: none;
    border-color: #E8734A;
    box-shadow: 0 0 0 4px rgba(232, 115, 74, 0.12);
}

.btn-add-submit {
    width: auto;
    white-space: nowrap;
    padding: 14px 24px;
}

.btn-save-questions {
    background: none;
    border: none;
    color: #A08060;
    font-size: 15px;
    font-weight: 600;
    cursor: pointer;
    padding: 10px 16px;
    margin-top: 10px;
    font-family: inherit;
    transition: color 0.2s;
}

.btn-save-questions:hover {
    color: #E8734A;
}

.cloud-header {
    display: flex;
    justify-content: space-between;
    align-items: baseline;
    margin-bottom: 24px;
    padding-bottom: 20px;
    border-bottom: 2px solid #F0E6D8;
}

.cloud-title {
    font-size: 28px;
    font-weight: 800;
    color: #3D2E1F;
    letter-spacing: -0.5px;
}

.cloud-progress {
    font-size: 17px;
    color: #E8734A;
    font-weight: 700;
}

.cloud-edit-link {
    font-size: 16px;
    color: #A08060;
    text-decoration: none;
    margin-left: 16px;
    font-weight: 600;
    transition: color 0.2s;
}

.cloud-edit-link:hover {
    color: #E8734A;
}

/* ============================================
   RECORD MODAL
   ============================================ */
.record-modal {
    display: none;
    position: fixed;
    inset: 0;
    z-index: 1000;
    background: rgba(60, 40, 20, 0.5);
    backdrop-filter: blur(8px);
    -webkit-backdrop-filter: blur(8px);
    align-items: center;
    justify-content: center;
    padding: 24px;
}

.record-modal.open {
    display: flex;
    animation: modalFadeIn 0.25s ease-out;
}

@keyframes modalFadeIn {
    from { opacity: 0; transform: scale(0.96); }
    to { opacity: 1; transform: scale(1); }
}

.record-modal-content {
    background: #FFFFFF;
    border: 2px solid #E8DDD0;
    border-radius: 32px;
    padding: 48px 40px;
    max-width: 760px;
    width: 100%;
    text-align: center;
    position: relative;
    max-height: 90vh;
    display: flex;
    flex-direction: column;
    overflow-y: auto;
    box-shadow: 0 24px 80px rgba(60, 40, 20, 0.15), 0 8px 24px rgba(60, 40, 20, 0.08);
}

.modal-close {
    position: absolute;
    top: 20px;
    right: 20px;
    width: 44px;
    height: 44px;
    border: none;
    border-radius: 50%;
    background: #FFF0E8;
    color: #E8734A;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 24px;
    font-weight: 700;
    transition: all 0.2s;
}

.modal-close:hover {
    background: #E8734A;
    color: #FFFFFF;
}

.modal-question {
    font-size: 24px;
    font-weight: 700;
    line-height: 1.5;
    color: #3D2E1F;
    margin-bottom: 10px;
    margin-top: 12px;
    flex-shrink: 0;
}

.modal-hint {
    font-size: 17px;
    color: #7A6B5D;
    margin-bottom: 36px;
    font-style: italic;
    line-height: 1.6;
    font-weight: 500;
    flex-shrink: 0;
}

.modal-recordings-list {
    margin-top: 24px;
    margin-bottom: 0;
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
    gap: 10px;
    padding-right: 0;
}


.modal-recording-item {
    padding: 12px 14px;
    background: #FFF8F4;
    border: 1px solid #F0E6D8;
    border-radius: 12px;
    transition: background 0.15s;
    display: flex;
    flex-direction: column;
    gap: 6px;
}

.modal-recording-item:hover {
    background: #FFF0E8;
}

.modal-recording-item.dragging {
    opacity: 0.4;
}

.modal-recording-item.drag-over-top {
    box-shadow: 0 -2px 0 #E8734A;
}

.modal-recording-item.drag-over-bottom {
    box-shadow: 0 2px 0 #E8734A;
}

.drag-handle {
    cursor: grab;
    color: #C0A090;
    font-size: 16px;
    user-select: none;
    padding: 2px 4px;
    line-height: 1;
}

.drag-handle:active {
    cursor: grabbing;
}

.modal-item-header {
    display: flex;
    align-items: center;
    gap: 8px;
}

.modal-item-label {
    font-size: 14px;
    font-weight: 600;
    color: #3D2E1F;
    flex: 1;
    text-align: left;
}

.modal-item-info {
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 12px;
    color: #A08060;
    text-align: left;
}

.modal-item-duration {
    font-family: 'SF Mono', 'JetBrains Mono', 'Fira Code', monospace;
    letter-spacing: 0.5px;
}

.modal-item-note-row {
    margin-top: 2px;
}

.modal-item-note {
    width: 100%;
    border: 1px solid #E8DDD0;
    border-radius: 8px;
    padding: 5px 8px;
    font-size: 13px;
    font-family: 'Nunito', sans-serif;
    color: #3D2E1F;
    background: #FFFFFF;
    outline: none;
    transition: border-color 0.15s;
    box-sizing: border-box;
}

.modal-item-note:focus {
    border-color: #E8734A;
}

.modal-item-note::placeholder {
    color: #C0B0A0;
}

.modal-item-play {
    width: 30px;
    height: 30px;
    border-radius: 50%;
    border: none;
    background: #5BAE7C;
    color: #FFFFFF;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: transform 0.1s, background 0.15s;
    flex-shrink: 0;
}

.modal-item-play:hover {
    background: #4A9A6A;
    transform: scale(1.08);
}

.modal-item-play.playing {
    background: #4A9A6A;
}

.modal-item-play svg {
    width: 14px;
    height: 14px;
}

.modal-item-delete {
    width: 28px;
    height: 28px;
    border-radius: 50%;
    border: 1.5px solid #C0A090;
    background: none;
    color: #C0A090;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: color 0.2s, border-color 0.2s;
    flex-shrink: 0;
}

.modal-item-delete:hover {
    color: #D32F2F;
    border-color: #D32F2F;
}

.modal-item-delete svg {
    width: 14px;
    height: 14px;
}

.modal-controls {
    display: flex;
    flex-direction: column;
    align-items: center;
    margin-bottom: 0;
    flex-shrink: 0;
}

.modal-timer {
    font-size: 32px;
    font-family: 'SF Mono', 'JetBrains Mono', 'Fira Code', monospace;
    color: #A08060;
    margin-bottom: 28px;
    min-height: 40px;
    font-weight: 400;
    letter-spacing: 2px;
    padding: 6px 18px;
    border-radius: 8px;
    transition: background 0.2s, color 0.2s;
}

.modal-timer.recording {
    background: #D32F2F;
    color: #fff !important;
}

.modal-shortcut-hint {
    font-size: 12px;
    color: #999;
    margin-top: 12px;
    letter-spacing: 0.3px;
}

.modal-timer.countdown {
    font-size: 56px;
    font-weight: 700;
    color: #D32F2F !important;
    animation: countdown-pop 0.9s ease-out;
}

@keyframes countdown-pop {
    0% {
        transform: scale(1.8);
        opacity: 0;
    }
    20% {
        opacity: 1;
    }
    60% {
        transform: scale(1);
    }
    100% {
        transform: scale(0.8);
        opacity: 0.3;
    }
}

.modal-record-btn {
    width: 96px;
    height: 96px;
    border-radius: 50%;
    border: 4px solid #D32F2F;
    background: #FFF5F5;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 4px 24px rgba(211, 47, 47, 0.1);
    padding: 0;
    transition: transform 0.1s, background 0.2s, box-shadow 0.2s;
}

.modal-record-btn:active {
    transform: scale(0.94);
}

.modal-record-btn:disabled {
    opacity: 0.4;
    cursor: not-allowed;
}

.modal-record-btn-inner {
    width: 38px;
    height: 38px;
    border-radius: 50%;
    background: #D32F2F;
    transition: all 0.2s;
    box-shadow: 0 2px 12px rgba(211, 47, 47, 0.2);
}

.modal-record-btn.recording {
    animation: pulse 2s infinite;
    border-color: #D32F2F;
    background: #D32F2F;
    box-shadow: 0 4px 24px rgba(211, 47, 47, 0.3);
}

.modal-record-btn.recording .modal-record-btn-inner {
    width: 28px;
    height: 28px;
    border-radius: 6px;
    background: #FFFFFF;
    box-shadow: none;
}

.modal-status {
    margin-top: 24px;
    font-size: 17px;
    color: #7A6B5D;
    font-weight: 600;
}

.modal-status.error {
    color: #C04040;
}

.modal-status.done {
    color: #2E7D4A;
}

.modal-playback {
    margin-top: 28px;
    padding-top: 24px;
    border-top: 2px solid #F0E6D8;
}

.modal-playback-label {
    font-size: 14px;
    color: #A08060;
    margin-bottom: 18px;
    text-transform: uppercase;
    letter-spacing: 1px;
    font-weight: 700;
}

.modal-playback-controls {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 16px;
    flex-wrap: wrap;
}

.modal-play-btn {
    width: 56px;
    height: 56px;
    min-width: 56px;
    border-radius: 50%;
    border: 2px solid #5BAE7C;
    background: #F0FFF4;
    color: #5BAE7C;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.2s;
}

.modal-play-btn:hover {
    background: #5BAE7C;
    color: #FFFFFF;
    box-shadow: 0 4px 16px rgba(91, 174, 124, 0.3);
}

.modal-play-btn svg {
    width: 22px;
    height: 22px;
}

.modal-duration {
    font-size: 18px;
    color: #7A6B5D;
    font-family: 'SF Mono', 'JetBrains Mono', 'Fira Code', monospace;
    font-weight: 500;
    letter-spacing: 1px;
}

.modal-redo-btn {
    padding: 14px 24px;
    font-size: 16px;
    font-weight: 700;
    background: #FFF0E8;
    border: 2px solid #E8DDD0;
    border-radius: 14px;
    color: #E8734A;
    cursor: pointer;
    transition: all 0.2s;
    font-family: inherit;
}

.modal-redo-btn:hover {
    background: #E8734A;
    color: #FFFFFF;
    border-color: #E8734A;
}

.modal-delete-btn {
    padding: 14px 24px;
    font-size: 16px;
    font-weight: 700;
    background: #FFF0F0;
    border: 2px solid #FFD4D4;
    border-radius: 14px;
    color: #C04040;
    cursor: pointer;
    transition: all 0.2s;
    font-family: inherit;
}

.modal-delete-btn:hover {
    background: #C04040;
    color: #FFFFFF;
    border-color: #C04040;
}

/* Admin */
.admin-page h1 {
    font-size: 28px;
    font-weight: 800;
    margin-bottom: 28px;
    color: #3D2E1F;
}

/* Admin Statistics Dashboard */
.admin-stats-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 16px;
    margin-bottom: 28px;
}

.admin-stat-card {
    display: flex;
    align-items: center;
    gap: 16px;
    padding: 20px;
    background: #FFFFFF;
    border: 2px solid #E8DDD0;
    border-radius: 16px;
    box-shadow: 0 2px 8px rgba(140, 100, 60, 0.04);
}

.stat-icon {
    font-size: 28px;
    width: 50px;
    height: 50px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 12px;
    background: #F5F0E8;
}

.stat-primary .stat-icon { background: #EEF2FF; }
.stat-accent .stat-icon { background: #FFF7ED; }
.stat-success .stat-icon { background: #ECFDF5; }
.stat-info .stat-icon { background: #F0F9FF; }

.stat-content {
    flex: 1;
}

.stat-value {
    font-size: 28px;
    font-weight: 800;
    color: #3D2E1F;
    line-height: 1.1;
}

.stat-label {
    font-size: 14px;
    color: #7A6B5D;
    font-weight: 600;
}

.admin-section {
    background: #FFFFFF;
    border: 2px solid #E8DDD0;
    border-radius: 16px;
    padding: 20px 24px;
    margin-bottom: 20px;
}

.admin-section h2 {
    font-size: 16px;
    font-weight: 700;
    color: #3D2E1F;
    margin: 0 0 16px 0;
}

.activity-timeline {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 12px;
}

.timeline-item {
    text-align: center;
    padding: 16px 12px;
    background: #F5F0E8;
    border-radius: 12px;
}

.timeline-period {
    display: block;
    font-size: 12px;
    font-weight: 700;
    color: #7A6B5D;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    margin-bottom: 8px;
}

.timeline-value {
    display: block;
    font-size: 32px;
    font-weight: 800;
    color: #E8734A;
    line-height: 1;
}

.timeline-label {
    display: block;
    font-size: 12px;
    color: #9E8E7E;
    margin-top: 4px;
}

.admin-two-col {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 20px;
    margin-bottom: 28px;
}

.top-users-list {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.top-user-item {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 10px 12px;
    background: #F5F0E8;
    border-radius: 10px;
}

.top-user-rank {
    font-size: 14px;
    font-weight: 800;
    color: #E8734A;
    min-width: 24px;
}

.top-user-name {
    flex: 1;
    font-weight: 600;
    color: #3D2E1F;
}

.top-user-stats {
    font-size: 13px;
    color: #7A6B5D;
}

.recent-list {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.recent-item {
    padding: 10px 12px;
    background: #F5F0E8;
    border-radius: 10px;
}

.recent-question {
    font-size: 14px;
    font-weight: 600;
    color: #3D2E1F;
    margin-bottom: 4px;
}

.recent-meta {
    font-size: 12px;
    color: #7A6B5D;
}

.empty-state {
    color: #9E8E7E;
    font-style: italic;
    font-size: 14px;
    margin: 0;
    padding: 16px 0;
}

.admin-users-title {
    font-size: 20px;
    font-weight: 700;
    color: #3D2E1F;
    margin: 0 0 16px 0;
}

@media (max-width: 900px) {
    .admin-stats-grid {
        grid-template-columns: repeat(2, 1fr);
    }
    .admin-two-col {
        grid-template-columns: 1fr;
    }
    .activity-timeline {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (max-width: 500px) {
    .admin-stats-grid {
        grid-template-columns: 1fr;
    }
    .activity-timeline {
        grid-template-columns: 1fr 1fr;
    }
}

.admin-users {
    display: flex;
    flex-direction: column;
    gap: 10px;
    margin-bottom: 40px;
}

.admin-user-card {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 18px 24px;
    background: #FFFFFF;
    border: 2px solid #E8DDD0;
    border-radius: 16px;
    box-shadow: 0 2px 8px rgba(140, 100, 60, 0.04);
}

.admin-user-info {
    display: flex;
    flex-direction: column;
    gap: 2px;
}

.admin-user-name {
    font-size: 18px;
    font-weight: 700;
    color: #3D2E1F;
}

.admin-user-username {
    font-size: 15px;
    color: #A08060;
    font-weight: 600;
}

.admin-user-actions {
    display: flex;
    align-items: center;
    gap: 12px;
}

.admin-badge {
    font-size: 13px;
    font-weight: 700;
    color: #E8734A;
    background: #FFF0E8;
    padding: 4px 12px;
    border-radius: 20px;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.inline-form {
    display: inline;
}

.admin-create {
    background: #FFFFFF;
    border: 2px solid #E8DDD0;
    border-radius: 20px;
    padding: 28px;
    box-shadow: 0 4px 16px rgba(140, 100, 60, 0.06);
}

.admin-create h2 {
    font-size: 20px;
    font-weight: 700;
    color: #3D2E1F;
    margin-bottom: 20px;
}

.admin-form .btn-primary {
    margin-top: 8px;
}

.admin-user-email {
    display: block;
    font-size: 13px;
    color: #9E8E7E;
    margin-top: 2px;
}

.btn-sm {
    padding: 6px 10px;
    font-size: 14px;
    border-radius: 8px;
}

.btn-secondary {
    background: #F0E6D8;
    color: #5A4A3A;
    border: none;
    cursor: pointer;
    transition: all 0.2s;
    text-decoration: none;
    display: inline-flex;
    align-items: center;
    justify-content: center;
}

.btn-secondary:hover {
    background: #E8DDD0;
}

.label-optional {
    font-weight: 400;
    color: #9E8E7E;
    font-size: 14px;
}

/* Admin Edit Page */
.admin-edit-section {
    background: #FFFFFF;
    border: 2px solid #E8DDD0;
    border-radius: 20px;
    padding: 28px;
    margin-bottom: 24px;
    box-shadow: 0 4px 16px rgba(140, 100, 60, 0.06);
}

.admin-edit-section h2 {
    font-size: 18px;
    font-weight: 700;
    color: #3D2E1F;
    margin-bottom: 20px;
}

.input-disabled {
    background: #F5F0E8;
    color: #9E8E7E;
    cursor: not-allowed;
}

.form-hint {
    display: block;
    font-size: 13px;
    color: #9E8E7E;
    margin-top: 4px;
}

.form-checkbox {
    display: flex;
    align-items: center;
}

.form-checkbox label {
    display: flex;
    align-items: center;
    gap: 10px;
    cursor: pointer;
    font-weight: 500;
}

.form-checkbox input[type="checkbox"] {
    width: 20px;
    height: 20px;
    accent-color: #E8734A;
}

.form-actions {
    display: flex;
    gap: 12px;
    margin-top: 20px;
}

.btn-warning {
    background: #F59E0B;
    color: white;
    border: none;
    padding: 12px 24px;
    border-radius: 12px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.2s;
}

.btn-warning:hover {
    background: #D97706;
}

.btn-danger {
    background: #DC2626;
    color: white;
    border: none;
    padding: 12px 24px;
    border-radius: 12px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.2s;
}

.btn-danger:hover {
    background: #B91C1C;
}

.admin-password-section {
    border-color: #FCD34D;
}

.admin-danger-section {
    border-color: #FCA5A5;
}

.danger-text {
    color: #991B1B;
    margin-bottom: 16px;
    font-size: 15px;
}

.user-stats {
    margin-bottom: 20px;
    padding: 16px;
    border-radius: 12px;
    background: #FEF3C7;
}

.stats-warning {
    color: #92400E;
    font-size: 15px;
    margin: 0;
}

.stats-empty {
    color: #065F46;
    font-size: 15px;
    margin: 0;
    background: #D1FAE5;
    padding: 16px;
    border-radius: 12px;
}

.user-stats:has(.stats-empty) {
    background: transparent;
    padding: 0;
}

/* Auth forgot password link */
.auth-forgot {
    text-align: center;
    margin-top: 20px;
    font-size: 15px;
}

.auth-forgot a {
    color: #9E8E7E;
    text-decoration: none;
}

.auth-forgot a:hover {
    color: #E8734A;
    text-decoration: underline;
}

/* ============================================
   MOBILE HAMBURGER MENU
   ============================================ */

.nav-top {
    display: none;
}

.nav-hamburger {
    display: none;
}

.nav-menu {
    display: contents;
}

@media (max-width: 768px) {
    .modal-shortcut-hint {
        display: none;
    }

    .nav {
        flex-direction: column;
        align-items: stretch;
        padding: 16px 0;
        margin-bottom: 24px;
    }

    .nav-top {
        display: flex;
        justify-content: space-between;
        align-items: center;
    }

    .nav-hamburger {
        display: flex;
        flex-direction: column;
        justify-content: center;
        gap: 5px;
        width: 40px;
        height: 40px;
        padding: 8px;
        background: none;
        border: none;
        cursor: pointer;
        border-radius: 8px;
        transition: background 0.2s;
    }

    .nav-hamburger:hover {
        background: #FFF0E0;
    }

    .nav-hamburger span {
        display: block;
        width: 100%;
        height: 3px;
        background: #5A4A3A;
        border-radius: 2px;
        transition: all 0.3s;
    }

    .nav.nav-open .nav-hamburger span:nth-child(1) {
        transform: rotate(45deg) translate(5px, 6px);
    }

    .nav.nav-open .nav-hamburger span:nth-child(2) {
        opacity: 0;
    }

    .nav.nav-open .nav-hamburger span:nth-child(3) {
        transform: rotate(-45deg) translate(5px, -6px);
    }

    .nav-menu {
        display: none;
        flex-direction: column;
        gap: 8px;
        padding-top: 16px;
        margin-top: 16px;
        border-top: 2px solid #F0E6D8;
    }

    .nav.nav-open .nav-menu {
        display: flex;
    }

    .nav-left,
    .nav-right {
        flex-direction: column;
        align-items: stretch;
        gap: 4px;
    }

    .nav-link {
        padding: 12px 16px;
        border-radius: 12px;
        background: #FFFCF8;
    }

    .nav-link:hover {
        background: #FFF0E0;
    }

    .nav-user-wrap {
        margin-top: 8px;
    }

    .nav-user-btn {
        width: 100%;
        justify-content: space-between;
        padding: 12px 16px;
        background: #FFFCF8;
        border-radius: 12px;
    }

    .nav-dropdown {
        position: static;
        margin-top: 8px;
        box-shadow: none;
        border: 1px solid #E8DDD0;
    }
}

/* Dark mode hamburger */
.dark .nav-hamburger:hover {
    background: #2A2218;
}

.dark .nav-hamburger span {
    background: #A89880;
}

.dark .nav-menu {
    border-top-color: #3A2E22;
}

.dark .nav-link {
    background: #1E1810;
}

.dark .nav-link:hover {
    background: #2A2218;
}

.dark .nav-user-btn {
    background: #1E1810;
}

.dark .nav-dropdown {
    border-color: #3A2E22;
}

/* Responsive - smaller screens */
@media (max-width: 480px) {
    .nav-dropdown {
        right: -10px;
        min-width: 200px;
    }

    .card-grid {
        grid-template-columns: 1fr;
    }

    .record-question {
        font-size: 22px;
    }

    .container {
        padding: 0 16px;
    }

    .container-wide {
        padding: 0 12px;
    }

    .question-cloud {
        gap: 10px;
        padding: 16px;
    }

    .question-chip {
        font-size: 16px;
        padding: 14px 18px;
    }

    .record-modal {
        padding: 8px;
    }

    .record-modal-content {
        padding: 28px 20px;
        border-radius: 20px;
    }

    .modal-recordings-list {
        grid-template-columns: 1fr;
    }

    .cloud-header {
        flex-wrap: wrap;
        gap: 8px;
    }

    .cloud-title {
        font-size: 22px;
    }

    .category-grid {
        grid-template-columns: 1fr;
    }

    .add-question-form {
        flex-direction: column;
    }

    .auth-container {
        margin: 24px auto;
        padding: 28px 20px;
        border-radius: 20px;
    }

    .modal-record-btn {
        width: 80px;
        height: 80px;
    }

    .modal-question {
        font-size: 20px;
    }

    .modal-timer {
        font-size: 26px;
    }

    .dashboard h1,
    .history h1 {
        font-size: 24px;
    }

    .btn {
        padding: 14px 24px;
        font-size: 16px;
    }

    .btn-large {
        padding: 16px 28px;
        font-size: 18px;
    }

    .history-session {
        padding: 16px;
        border-radius: 16px;
    }

    .session-card {
        padding: 14px 16px;
        flex-direction: column;
        align-items: flex-start;
        gap: 8px;
    }

    .session-card-wrapper {
        flex-direction: column;
        align-items: stretch;
    }

    .completed-row-top {
        flex-direction: column;
        align-items: flex-start;
        gap: 8px;
    }

    .completed-actions {
        width: 100%;
        justify-content: flex-start;
    }
}

/* Trash page */
.trash-info-text {
    font-size: 13px;
    color: #9E8E7E;
}

.trash-expires-label {
    font-size: 12px;
    color: #D32F2F;
    font-weight: 600;
    margin-top: 4px;
}

.trash-restore-btn {
    padding: 6px 12px;
    border: 2px solid #5BAE7C;
    background: #F0FFF4;
    color: #5BAE7C;
    border-radius: 8px;
    font-weight: 700;
    font-size: 12px;
    cursor: pointer;
    transition: all 0.2s;
    font-family: inherit;
}

.trash-restore-btn:hover {
    background: #5BAE7C;
    color: #fff;
}

/* Crop button */
.crop-btn {
    display: var(--crop-display, flex);
    width: 30px;
    height: 30px;
    min-width: 30px;
    border-radius: 50%;
    border: 1.5px solid #C0A090;
    background: none;
    color: #C0A090;
    cursor: pointer;
    align-items: center;
    justify-content: center;
    transition: color 0.2s, border-color 0.2s;
}

.crop-btn:hover {
    color: #E8734A;
    border-color: #E8734A;
}

.crop-btn svg {
    width: 14px;
    height: 14px;
}

.restore-btn {
    display: flex;
    width: 30px;
    height: 30px;
    min-width: 30px;
    border-radius: 50%;
    border: 1.5px solid #5A9A6A;
    background: none;
    color: #5A9A6A;
    cursor: pointer;
    align-items: center;
    justify-content: center;
    transition: color 0.2s, border-color 0.2s;
}

.restore-btn:hover {
    color: #2E7D4A;
    border-color: #2E7D4A;
}

.restore-btn svg {
    width: 14px;
    height: 14px;
}

/* Crop modal */
.crop-modal {
    display: none;
    position: fixed;
    inset: 0;
    z-index: 1100;
    background: rgba(60, 40, 20, 0.5);
    backdrop-filter: blur(8px);
    -webkit-backdrop-filter: blur(8px);
    align-items: center;
    justify-content: center;
    padding: 24px;
}

.crop-modal.open {
    display: flex;
    animation: modalFadeIn 0.25s ease-out;
}

.crop-modal-content {
    background: #FFFFFF;
    border: 2px solid #E8DDD0;
    border-radius: 32px;
    padding: 40px;
    max-width: 700px;
    width: 100%;
    position: relative;
    box-shadow: 0 24px 80px rgba(60, 40, 20, 0.15), 0 8px 24px rgba(60, 40, 20, 0.08);
}

.crop-modal-title {
    font-size: 22px;
    font-weight: 700;
    color: #3D2E1F;
    margin-bottom: 20px;
    text-align: center;
}

.crop-modal-close {
    position: absolute;
    top: 20px;
    right: 20px;
}

.crop-loading {
    text-align: center;
    font-size: 17px;
    color: #7A6B5D;
    padding: 40px 0;
    font-weight: 600;
}

.crop-waveform-wrap {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.crop-canvas {
    width: 100%;
    height: 150px;
    border: 1px solid #E8DDD0;
    border-radius: 12px;
    cursor: crosshair;
    touch-action: none;
}

.crop-time-labels {
    display: flex;
    justify-content: space-between;
    font-size: 14px;
    font-family: 'SF Mono', 'JetBrains Mono', 'Fira Code', monospace;
    color: #7A6B5D;
    font-weight: 600;
}

#crop-start-label {
    color: #2E7D4A;
}

#crop-end-label {
    color: #D32F2F;
}

#crop-duration-label {
    color: #E8734A;
    font-weight: 700;
}

.crop-buttons {
    display: flex;
    gap: 12px;
    justify-content: center;
    margin-top: 8px;
}

.btn-crop-preview,
.btn-crop-save,
.btn-crop-restore,
.btn-crop-cancel {
    padding: 12px 24px;
    font-size: 16px;
    font-weight: 700;
    border-radius: 14px;
    cursor: pointer;
    font-family: inherit;
    transition: all 0.2s;
    border: 2px solid;
}

.btn-crop-preview {
    background: #F0FFF4;
    border-color: #5BAE7C;
    color: #5BAE7C;
}

.btn-crop-preview:hover {
    background: #5BAE7C;
    color: #fff;
}

.btn-crop-save {
    background: linear-gradient(135deg, #E8734A 0%, #F5A623 100%);
    border-color: transparent;
    color: #fff;
    box-shadow: 0 4px 16px rgba(232, 115, 74, 0.25);
}

.btn-crop-save:hover {
    box-shadow: 0 6px 24px rgba(232, 115, 74, 0.35);
    transform: translateY(-1px);
}

.btn-crop-save:disabled {
    opacity: 0.6;
    cursor: not-allowed;
    transform: none;
}

.btn-crop-cancel {
    background: #FFFFFF;
    border-color: #E8DDD0;
    color: #7A6B5D;
}

.btn-crop-cancel:hover {
    border-color: #D32F2F;
    color: #D32F2F;
}

.btn-crop-restore {
    background: #F0FFF4;
    border-color: #5A9A6A;
    color: #5A9A6A;
}

.btn-crop-restore:hover {
    background: #5A9A6A;
    color: #fff;
}

.btn-crop-restore:disabled {
    opacity: 0.6;
    cursor: not-allowed;
}

@media (max-width: 480px) {
    .crop-modal-content {
        padding: 28px 20px;
        border-radius: 24px;
    }

    .crop-buttons {
        flex-direction: column;
    }

    .crop-canvas {
        height: 120px;
    }
}

/* ============================================
   DARK MODE
   ============================================ */
.dark,
.dark body {
    background: #1A1512;
    color: #E8DDD0;
}

.dark .nav {
    border-bottom-color: #3A2E22;
}

.dark .nav-brand {
    color: #F5A623;
}

.dark .nav-link {
    color: #A89880;
}

.dark .nav-link:hover {
    background: #2A2218;
    color: #F5A623;
}

.dark .nav-home {
    color: #F5A623;
}

.dark .nav-home:hover {
    color: #FFB84D;
}

.dark .nav-user-btn {
    color: #A89880;
}

.dark .nav-user-btn:hover {
    background: #2A2218;
    color: #F5A623;
}

.dark .nav-dropdown {
    background: #2A2218;
    border-color: #3A2E22;
    box-shadow: 0 12px 40px rgba(0, 0, 0, 0.4);
}

.dark .nav-dropdown-item {
    color: #E8DDD0;
}

.dark .nav-dropdown-item:hover {
    background: #3A2E22;
}

.dark .nav-dropdown-divider {
    background: #3A2E22;
}

.dark .toggle-lang {
    border-color: #3A2E22;
}

.dark .lang-opt {
    color: #A89880;
}

.dark .toggle-slider {
    background: #3A2E22;
}

.dark .dashboard h1,
.dark .history h1,
.dark .cloud-title,
.dark .preview-page h1 {
    color: #E8DDD0;
}

.dark .dashboard-intro,
.dark .dashboard-section h2 {
    color: #A89880;
}

.dark .category-card {
    background: #2A2218;
    border-color: #3A2E22;
    box-shadow: none;
}

.dark .category-card:hover {
    border-color: #F5A623;
    box-shadow: 0 4px 16px rgba(245, 166, 35, 0.1);
}

.dark .category-label {
    color: #E8DDD0;
}

.dark .category-count {
    color: #A89880;
}

.dark .question-cloud {
    background: linear-gradient(135deg, #2A2218 0%, #1E1810 100%);
    border-color: #3A2E22;
    box-shadow: inset 0 2px 20px rgba(0, 0, 0, 0.2);
}

.dark .question-chip:nth-child(7n+1) { background: linear-gradient(135deg, #3A2A1A 0%, #4A3020 100%); color: #E8B080; }
.dark .question-chip:nth-child(7n+2) { background: linear-gradient(135deg, #1A2A3A 0%, #203040 100%); color: #80B8E0; }
.dark .question-chip:nth-child(7n+3) { background: linear-gradient(135deg, #1A3020 0%, #203828 100%); color: #80C898; }
.dark .question-chip:nth-child(7n+4) { background: linear-gradient(135deg, #3A3018 0%, #4A3820 100%); color: #E8C880; }
.dark .question-chip:nth-child(7n+5) { background: linear-gradient(135deg, #2A1A3A 0%, #382040 100%); color: #B890E0; }
.dark .question-chip:nth-child(7n+6) { background: linear-gradient(135deg, #3A1A2A 0%, #402030 100%); color: #E890B8; }
.dark .question-chip:nth-child(7n+7) { background: linear-gradient(135deg, #1A3A30 0%, #204838 100%); color: #80E0C8; }

.dark .question-chip.recorded {
    background: linear-gradient(135deg, #1A3020 0%, #203828 100%) !important;
    color: #80C898 !important;
    border-color: #4A8A60;
}

.dark .cloud-progress {
    color: #F5A623;
}

.dark .record-modal,
.dark .crop-modal {
    background: rgba(10, 8, 5, 0.7);
}

.dark .record-modal-content,
.dark .crop-modal-content {
    background: #2A2218;
    border-color: #3A2E22;
    box-shadow: 0 24px 80px rgba(0, 0, 0, 0.4);
}

.dark .modal-close {
    background: #3A2E22;
    color: #F5A623;
}

.dark .modal-close:hover {
    background: #F5A623;
    color: #1A1512;
}

.dark .modal-question,
.dark .crop-modal-title {
    color: #E8DDD0;
}

.dark .modal-hint {
    color: #A89880;
}

.dark .modal-recording-item {
    background: #1E1810;
    border-color: #3A2E22;
}

.dark .modal-recording-item:hover {
    background: #2A2218;
}

.dark .modal-item-label {
    color: #E8DDD0;
}

.dark .modal-item-note {
    background: #1A1512;
    border-color: #3A2E22;
    color: #E8DDD0;
}

.dark .modal-timer {
    color: #A89880;
}

.dark .completed-recordings {
    border-top-color: #3A2E22;
}

.dark .completed-item {
    border-bottom-color: #3A2E22;
}

.dark .completed-item:nth-child(even) {
    background-color: #2A2018;
}

.dark .completed-question {
    color: #E8DDD0;
}

.dark .history-session {
    background: #2A2218;
    border-color: #3A2E22;
    box-shadow: none;
}

.dark .history-session-header {
    border-bottom-color: #3A2E22;
}

.dark .history-category {
    color: #E8DDD0;
}

.dark .history-item {
    border-color: #3A2E22;
    background: #1E1810;
}

.dark .history-question {
    color: #E8DDD0;
}

.dark .play-btn {
    border-color: #4A8A60;
    background: #1A3020;
    color: #80C898;
}

.dark .play-btn:hover {
    background: #4A8A60;
    color: #fff;
}

.dark .crop-btn {
    border-color: #6A5A4A;
    color: #A89880;
}

.dark .crop-btn:hover {
    border-color: #F5A623;
    color: #F5A623;
}

.dark .restore-btn {
    border-color: #4A8A60;
    color: #6AAA80;
}

.dark .restore-btn:hover {
    border-color: #80CC98;
    color: #80CC98;
}

.dark .delete-btn,
.dark .history-delete-btn,
.dark .history-delete-session-btn {
    border-color: #6A5A4A;
    color: #A89880;
}

.dark .delete-btn:hover,
.dark .history-delete-btn:hover,
.dark .history-delete-session-btn:hover {
    border-color: #D32F2F;
    color: #D32F2F;
}

.dark .session-card {
    background: #2A2218;
    border-color: #3A2E22;
    box-shadow: none;
}

.dark .session-card:hover {
    border-color: #F5A623;
}

.dark .cloud-header {
    border-bottom-color: #3A2E22;
}

.dark .flash-success {
    background: #1A3020;
    color: #80C898;
    border-color: #2A4A30;
}

.dark .flash-error {
    background: #3A1A1A;
    color: #E88080;
    border-color: #4A2020;
}

.dark .crop-canvas {
    border-color: #3A2E22;
}

.dark .crop-loading {
    color: #A89880;
}

.dark .btn-crop-cancel {
    background: #2A2218;
    border-color: #3A2E22;
    color: #A89880;
}

.dark .btn-crop-restore {
    background: #1A2E20;
    border-color: #2A4A30;
    color: #80C898;
}

.dark .btn-crop-restore:hover {
    background: #2A4A30;
    color: #B0E8C0;
}

.dark .form-group input[type="text"],
.dark .form-group input[type="email"],
.dark .form-group input[type="password"],
.dark input[type="text"],
.dark input[type="email"],
.dark input[type="password"] {
    background: #1E1810 !important;
    border-color: #3A2E22 !important;
    color: #E8DDD0 !important;
}

.dark input::placeholder {
    color: #6A5A4A !important;
}

.dark input:focus {
    border-color: #F5A623 !important;
    box-shadow: 0 0 0 4px rgba(245, 166, 35, 0.15) !important;
}

.dark .form-group label,
.dark label {
    color: #E8DDD0;
}

.dark .auth-container {
    background: #2A2218;
    box-shadow: 0 8px 40px rgba(0, 0, 0, 0.3);
}

.dark .auth-container h1 {
    color: #E8DDD0;
}

.dark .auth-subtitle {
    color: #A89880;
}

.dark .auth-form input[type="text"],
.dark .auth-form input[type="email"],
.dark .auth-form input[type="password"] {
    background: #1E1810;
    border-color: #3A2E22;
    color: #E8DDD0;
}

.dark .auth-form input::placeholder {
    color: #6A5A4A;
}

.dark .auth-form label {
    color: #E8DDD0;
}

.dark .auth-lang-toggle .lang-toggle-btn {
    color: #A89880;
    border-color: #3A2E22;
}

.dark .auth-lang-toggle .lang-toggle-btn:hover {
    background: #3A2E22;
    color: #F5A623;
}

/* Autosave indicator */
.autosave-indicator {
    font-size: 0.85rem;
    font-weight: 600;
    color: var(--text-muted, #888);
    white-space: nowrap;
    min-width: 5rem;
    padding: 0.4rem 0.6rem;
    border-radius: 6px;
    transition: background 0.2s, color 0.2s;
}
.autosave-indicator.success {
    color: #2E7D4A;
    background: #f0fff4;
}
.autosave-indicator.error {
    color: #e53e3e;
    background: #fff5f5;
}
.drive-set-label {
    font-size: 0.9rem;
    font-weight: 600;
    color: var(--text-muted, #7a6b5d);
    white-space: nowrap;
}
.dark .autosave-indicator.success {
    color: #80C898;
    background: #1A3020;
}
.dark .autosave-indicator.error {
    color: #E88080;
    background: #3A1A1A;
}

/* Dark mode for admin edit page */
.dark .admin-edit-section {
    background: #2A2218;
    border-color: #3A2E22;
    box-shadow: none;
}

.dark .admin-edit-section h2 {
    color: #E8DDD0;
}

.dark .input-disabled {
    background: #1E1810;
    color: #6A5A4A;
}

.dark .form-hint {
    color: #7A6A5A;
}

.dark .label-optional {
    color: #7A6A5A;
}

.dark .admin-password-section {
    border-color: #6B5A10;
}

.dark .admin-danger-section {
    border-color: #6B2020;
}

.dark .danger-text {
    color: #F87171;
}

.dark .user-stats {
    background: #3A3018;
}

.dark .stats-warning {
    color: #FCD34D;
}

.dark .stats-empty {
    background: #1A3020;
    color: #6EE7B7;
}

.dark .btn-secondary {
    background: #3A2E22;
    color: #E8DDD0;
}

.dark .btn-secondary:hover {
    background: #4A3E32;
}

.dark .auth-forgot a {
    color: #7A6A5A;
}

.dark .auth-forgot a:hover {
    color: #F5A623;
}

/* Dark mode for admin page */
.dark .admin-page h1 {
    color: #E8DDD0;
}

.dark .admin-user-card {
    background: #2A2218;
    border-color: #3A2E22;
    box-shadow: none;
}

.dark .admin-user-name {
    color: #E8DDD0;
}

.dark .admin-user-username {
    color: #A89880;
}

.dark .admin-user-email {
    color: #7A6A5A;
}

.dark .admin-badge {
    background: #3A2A1A;
    color: #F5A623;
}

.dark .admin-create {
    background: #2A2218;
    border-color: #3A2E22;
    box-shadow: none;
}

.dark .admin-create h2 {
    color: #E8DDD0;
}

.dark .admin-form input[type="text"],
.dark .admin-form input[type="email"],
.dark .admin-form input[type="password"] {
    background: #1E1810 !important;
    border-color: #3A2E22 !important;
    color: #E8DDD0 !important;
}

.dark .admin-form input::placeholder {
    color: #6A5A4A !important;
}

.dark .admin-form input:focus {
    border-color: #F5A623 !important;
    box-shadow: 0 0 0 4px rgba(245, 166, 35, 0.15) !important;
}

.dark .admin-form label {
    color: #E8DDD0;
}

/* Dark mode for sessions/script page */
.dark .category-section {
    border-color: #3A2E22;
}

.dark .category-header {
    background: #2A2218;
}

.dark .category-header:hover {
    background: #3A2E22;
}

.dark .category-toggle {
    color: #A89880;
}

.dark .category-label-text {
    color: #E8DDD0;
}

.dark .category-count {
    color: #A89880;
}

.dark .category-body {
    background: #1E1810;
}

.dark .category-actions {
    border-bottom-color: #3A2E22;
}

.dark .cat-action-btn {
    background: #2A2218;
    border-color: #3A2E22;
    color: #A89880;
}

.dark .cat-action-btn:hover {
    background: #3A2E22;
}

.dark .cat-action-delete {
    color: #F87171;
    border-color: #6B2020;
}

.dark .cat-action-delete:hover {
    background: #3A1A1A;
}

.dark .question-item {
    border-bottom-color: #3A2E22;
}

.dark .question-number {
    color: #A89880;
}

.dark .question-text {
    color: #E8DDD0;
}

.dark .question-hint {
    color: #7A6A5A;
}

.dark .q-btn {
    background: #2A2218;
    border-color: #3A2E22;
}

.dark .q-btn:hover {
    background: #3A2E22;
}

.dark .q-btn-edit {
    color: #90CDF4;
    border-color: #2B6CB0;
}

.dark .q-btn-edit:hover {
    background: #1A2A3A;
}

.dark .q-btn-delete {
    color: #FEB2B2;
    border-color: #C53030;
}

.dark .q-btn-delete:hover {
    background: #3A1A1A;
}

.dark .btn-add-question {
    background: #2A2218;
    border-color: #4A3E32;
    color: #A89880;
}

.dark .btn-add-question:hover {
    background: #3A2218;
    border-color: #F5A623;
    color: #F5A623;
}

.dark .btn-clear {
    color: #F87171;
    border-color: #6B2020;
}

.dark .btn-clear:hover {
    background: #3A1A1A;
}

.dark .drive-section {
    background: #2A2218;
    border-color: #3A2E22;
}

.dark .drive-section h2 {
    color: #E8DDD0;
}

.dark .drive-info {
    color: #7A6A5A;
}

.dark .drive-name-input {
    background: #1E1810;
    border-color: #3A2E22;
    color: #E8DDD0;
}

.dark .drive-name-input:focus {
    border-color: #5A9A6A;
}

.dark .btn-drive {
    background: #2A2218;
    border-color: #3A2E22;
    color: #A89880;
}

.dark .btn-drive:hover {
    background: #3A2E22;
}

.dark .btn-drive-save {
    border-color: #5A9A6A;
    color: #6AAA80;
}

.dark .btn-drive-save:hover {
    background: #1A3020;
}

.dark .drive-set-item {
    background: #2A2218;
    border-color: #3A2E22;
}

.dark .drive-set-name {
    color: #E8DDD0;
}

.dark .drive-set-date {
    color: #7A6A5A;
}

.dark .drive-set-count {
    color: #7A6A5A;
}

.dark .drive-set-btn {
    background: #1E1810;
    border-color: #3A2E22;
}

.dark .drive-set-btn:hover {
    background: #3A2E22;
}

.dark .drive-set-btn-load {
    color: #90CDF4;
    border-color: #3182CE;
}

.dark .drive-set-btn-load:hover {
    background: #1A2A3A;
}

.dark .drive-set-btn-delete {
    color: #FEB2B2;
    border-color: #E53E3E;
}

.dark .drive-set-btn-delete:hover {
    background: #3A1A1A;
}

.dark .drive-set-btn-save-ml {
    color: #6AAA80;
    border-color: #5A9A6A;
}

.dark .drive-set-btn-save-ml:hover {
    background: #1A3020;
}

.dark .drive-set-permanent {
    background: #1E1810;
}

.dark .drive-sets-loading,
.dark .drive-sets-empty {
    color: #7A6A5A;
}

.dark .edit-input {
    background: #1E1810;
    border-color: #E8734A;
    color: #E8DDD0;
}

.dark .edit-input-hint {
    border-color: #3A2E22;
}

.dark .edit-input-hint:focus {
    border-color: #5A5A5A;
}

.dark .edit-cancel-btn {
    background: #2A2218;
    border-color: #3A2E22;
    color: #A89880;
}

.dark .edit-cancel-btn:hover {
    background: #3A2E22;
}

.dark .session-delete-btn {
    border-color: #6A5A4A;
    color: #A89880;
}

.dark .session-delete-btn:hover {
    border-color: #D32F2F;
    color: #D32F2F;
}

/* Dark mode for admin statistics */
.dark .admin-stat-card {
    background: #2A2218;
    border-color: #3A2E22;
}

.dark .stat-icon {
    background: #3A2E22;
}

.dark .stat-primary .stat-icon { background: #2A2A3A; }
.dark .stat-accent .stat-icon { background: #3A2A1A; }
.dark .stat-success .stat-icon { background: #1A3020; }
.dark .stat-info .stat-icon { background: #1A2A3A; }

.dark .stat-value {
    color: #E8DDD0;
}

.dark .stat-label {
    color: #A89880;
}

.dark .admin-section {
    background: #2A2218;
    border-color: #3A2E22;
}

.dark .admin-section h2 {
    color: #E8DDD0;
}

.dark .timeline-item {
    background: #1E1810;
}

.dark .timeline-period {
    color: #A89880;
}

.dark .timeline-value {
    color: #F5A623;
}

.dark .timeline-label {
    color: #7A6A5A;
}

.dark .top-user-item {
    background: #1E1810;
}

.dark .top-user-rank {
    color: #F5A623;
}

.dark .top-user-name {
    color: #E8DDD0;
}

.dark .top-user-stats {
    color: #A89880;
}

.dark .recent-item {
    background: #1E1810;
}

.dark .recent-question {
    color: #E8DDD0;
}

.dark .recent-meta {
    color: #A89880;
}

.dark .empty-state {
    color: #7A6A5A;
}

.dark .admin-users-title {
    color: #E8DDD0;
}

