#teacher-tools { display: none; }
#teacher-tools.active { display: block; }
#teacher-tools-inner { max-width: 1000px; margin: 0 auto; padding: 24px 16px; }

.toolbox-header { margin-bottom: 24px; }
.toolbox-title { font-size: 24px; font-weight: 700; color: var(--text-primary); margin: 0 0 6px 0; }
.toolbox-subtitle { font-size: 14px; color: var(--text-secondary); margin: 0; }

.tools-grid { display: grid; grid-template-columns: repeat(2, minmax(0,1fr)); gap: 12px; }
@media (min-width: 640px) { .tools-grid { grid-template-columns: repeat(2, minmax(0,1fr)); } }
@media (min-width: 768px) { .tools-grid { grid-template-columns: repeat(3, minmax(0,1fr)); gap: 16px; } }

.tool-card {
    background: #FFFFFF; border-radius: 16px; padding: 16px;
    border: 1px solid #e5e7eb;
    display: flex; flex-direction: column; gap: 12px;
    text-align: left; cursor: pointer;
    transition: all 0.15s ease;
}
.tool-card:hover {
    border-color: #F5DEB3; box-shadow: 0 4px 12px rgba(0,0,0,.06);
    transform: translateY(-1px);
}
.tool-card:active { transform: scale(0.97); }

.tool-card .tc-icon {
    width: 48px; height: 48px; border-radius: 12px;
    display: flex; align-items: center; justify-content: center;
    font-size: 24px; flex-shrink: 0;
}
.tool-card .tc-name-row {
    display: flex; align-items: center; gap: 6px;
    flex-wrap: wrap;
}
.tool-card .tc-name {
    font-size: 14px; font-weight: 700; color: #111827; line-height: 1.4;
}
.tool-card:hover .tc-name { color: #e06020; }
.tool-card .tc-badge {
    font-size: 10px; font-weight: 600;
    padding: 1px 6px; border-radius: 999px; white-space: nowrap;
}
.tool-card .tc-badge-new { background: var(--brand-500); color: #FFFFFF; }
.tool-card .tc-badge-mic { background: var(--sun-100); color: var(--gold-700); }
.tool-card .tc-desc {
    font-size: 12px; color: #9ca3af; line-height: 1.4;
    display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden;
    min-height: 2.5em;
}
.tool-card .tc-enter {
    font-size: 11px; color: #9ca3af; margin-top: auto; padding-top: 4px;
    transition: color 0.2s;
}
.tool-card:hover .tc-enter { color: #e06020; }

.tool-detail-toolbar {
    display: flex; align-items: center; gap: 16px; padding: 0 0 20px 0;
    border-bottom: 1px solid #e5e7eb; margin-bottom: 20px; flex-shrink: 0;
}
.tool-back-btn {
    background: #f3f4f6; border: 1px solid #e5e7eb; border-radius: 8px;
    padding: 8px 16px; font-size: 14px; color: #4B5563; cursor: pointer;
    transition: all 0.15s;
}
.tool-back-btn:hover { background: #e5e7eb; }
.tool-detail-title { font-size: 18px; font-weight: 700; color: #111827; flex: 1; }
.tool-fullscreen-btn {
    background: #fff; border: 1px solid #e5e7eb; border-radius: 8px;
    padding: 8px 16px; font-size: 14px; color: #6b7280; cursor: pointer;
}
.tool-fullscreen-btn:hover { background: #f9fafb; }
.tool-detail-body { flex: 1; }

/* 课堂工具全屏模式（课堂计时器 / 视力挑战等） */
#teacher-tools-inner.tool-fs {
    position: fixed;
    inset: 0;
    z-index: 9999;
    width: 100vw;
    max-width: none;
    height: 100vh;
    margin: 0;
    background: #fff;
    overflow: auto;
    padding: 20px 24px;
}

/* 静音挑战 */
.challenge-overlay {
    position: fixed; top: 0; left: 0; right: 0; bottom: 0;
    background: rgba(0,0,0,0.35); z-index: 9999; display: flex;
    align-items: flex-start; justify-content: center;
    padding: 24px; overflow-y: auto; -webkit-overflow-scrolling: touch;
}
.challenge-modal {
    background: #fff; border-radius: 12px; padding: 28px 32px; margin: auto;
    width: 420px; max-width: 92vw; box-shadow: 0 8px 32px rgba(0,0,0,0.12);
}
