/* =============================================
   年终总结 - year_end_summary.css
   温暖金秋主题，三栏布局，支持暗黑模式
   ============================================= */

/* ========== 主容器 ========== */
.yes-container {
    display: flex;
    flex-direction: column;
    height: calc(100vh - 200px);
    min-height: 600px;
    background: #fffdf7;
    border-radius: 8px;
    overflow: hidden;
    box-shadow: 0 2px 12px rgba(180, 120, 0, 0.1);
    transition: all 0.3s ease;
    border: 1px solid #fde68a;
}

/* 全屏模式 */
.yes-container.fullscreen {
    position: fixed;
    top: 0;
    left: 0;
    width: 100vw !important;
    height: 100vh !important;
    z-index: 9999;
    border-radius: 0;
    margin: 0;
    min-height: unset;
}

/* ========== 顶部工具栏 ========== */
.yes-toolbar {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 8px 14px;
    background: linear-gradient(135deg, #b45309 0%, #92400e 50%, #78350f 100%);
    color: white;
    flex-wrap: wrap;
    gap: 8px;
    box-shadow: 0 2px 10px rgba(146, 64, 14, 0.45);
    flex-shrink: 0;
    position: relative;
    overflow: hidden;
}

/* 工具栏装饰纹 */
.yes-toolbar::before {
    content: '总结 · 回顾 · 展望 · 成长 · 总结 · 回顾 · 展望 · 成长 · 总结 · 回顾';
    position: absolute;
    top: 50%;
    left: 0;
    transform: translateY(-50%);
    font-size: 10px;
    color: rgba(255, 255, 255, 0.07);
    white-space: nowrap;
    pointer-events: none;
    letter-spacing: 6px;
}

.yes-toolbar .toolbar-title {
    font-size: 13px;
    font-weight: 600;
    color: rgba(254, 243, 199, 0.95);
    letter-spacing: 1px;
    margin-right: 8px;
    position: relative;
}

.toolbar-group {
    display: flex;
    gap: 6px;
    align-items: center;
    flex-wrap: wrap;
    min-height: 28px;
    position: relative;
}

.yes-toolbar-btn {
    padding: 5px 11px;
    background: rgba(254, 243, 199, 0.92);
    border: 1px solid rgba(251, 191, 36, 0.5);
    border-radius: 4px;
    cursor: pointer;
    font-size: 12px;
    font-weight: 500;
    color: #78350f;
    transition: all 0.2s;
    white-space: nowrap;
    position: relative;
}

.yes-toolbar-btn:hover:not(:disabled) {
    background: #fff;
    transform: translateY(-1px);
    box-shadow: 0 3px 8px rgba(120, 53, 15, 0.25);
    border-color: #fbbf24;
}

.yes-toolbar-btn:active:not(:disabled) {
    transform: translateY(0);
}

.yes-toolbar-btn:disabled {
    opacity: 0.45;
    cursor: not-allowed;
}

/* 主操作按钮（生成总结） */
.yes-toolbar-btn-primary {
    background: linear-gradient(135deg, #f59e0b 0%, #d97706 100%);
    color: #fff;
    font-weight: 600;
    border: 1px solid rgba(251, 191, 36, 0.7);
    box-shadow: 0 2px 6px rgba(217, 119, 6, 0.5);
}

.yes-toolbar-btn-primary:hover:not(:disabled) {
    background: linear-gradient(135deg, #fbbf24 0%, #f59e0b 100%);
    box-shadow: 0 4px 12px rgba(217, 119, 6, 0.65);
    color: #fff;
}

/* 取消按钮 */
.yes-toolbar-btn-cancel {
    background: rgba(254, 226, 226, 0.95);
    color: #991b1b;
    border-color: rgba(252, 165, 165, 0.6);
}

.yes-toolbar-btn-cancel:hover:not(:disabled) {
    background: #fee2e2;
    color: #7f1d1d;
}

/* Shake 抖动动画 */
@keyframes yes-shake {
    0%, 100% { transform: translateX(0); }
    15%, 55%, 95% { transform: translateX(-4px); }
    35%, 75% { transform: translateX(4px); }
}

.yes-input.shake,
.yes-textarea.shake,
.yes-select.shake {
    animation: yes-shake 0.45s ease-in-out;
    border-color: #ef4444 !important;
    box-shadow: 0 0 0 3px rgba(239, 68, 68, 0.12) !important;
}

/* ========== 主内容区：三栏 ========== */
.yes-main-content {
    display: flex;
    flex: 1;
    overflow: hidden;
    background: #fffdf7;
}

/* ========== 左栏：历史记录 ========== */
.yes-history-panel {
    width: 192px;
    flex-shrink: 0;
    background: #fff;
    border-right: 1px solid #fde68a;
    display: flex;
    flex-direction: column;
    overflow: hidden;
}

.history-panel-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 11px 12px;
    background: linear-gradient(to bottom, #fffbeb 0%, #fef3c7 100%);
    border-bottom: 1px solid #fde68a;
    flex-shrink: 0;
}

.history-panel-header h3 {
    margin: 0;
    font-size: 12px;
    font-weight: 600;
    color: #92400e;
}

.history-count {
    font-size: 11px;
    color: #b45309;
    font-weight: 400;
    margin-left: 3px;
}

.history-clear-btn {
    background: #fff0f0;
    border: none;
    color: #ef4444;
    font-size: 11px;
    cursor: pointer;
    padding: 2px 7px;
    border-radius: 3px;
    transition: background 0.2s;
    white-space: nowrap;
}

.history-clear-btn:hover {
    background: #fde8e8;
}

.history-search {
    padding: 7px;
    border-bottom: 1px solid #fde68a;
    flex-shrink: 0;
}

.history-search input {
    width: 100%;
    padding: 5px 9px;
    border: 1px solid #fde68a;
    border-radius: 4px;
    font-size: 12px;
    outline: none;
    transition: all 0.2s;
    box-sizing: border-box;
    background: #fffbf0;
}

.history-search input:focus {
    border-color: #f59e0b;
    box-shadow: 0 0 0 2px rgba(245, 158, 11, 0.12);
}

.history-list {
    flex: 1;
    overflow-y: auto;
    padding: 6px;
}

.history-empty {
    padding: 28px 10px;
    text-align: center;
    font-size: 12px;
    color: #c0997a;
}

.history-item {
    padding: 9px 10px;
    margin-bottom: 5px;
    background: #fffbf0;
    border: 1px solid #fde68a;
    border-radius: 6px;
    cursor: pointer;
    transition: all 0.2s;
    position: relative;
    animation: fadeIn 0.2s ease;
}

.history-item:hover {
    background: #fef3c7;
    border-color: #f59e0b;
    transform: translateX(2px);
}

.history-item.active {
    background: #fef3c7;
    border-color: #f59e0b;
    box-shadow: 0 1px 4px rgba(245, 158, 11, 0.2);
}

.history-item-title {
    font-size: 12px;
    font-weight: 600;
    color: #78350f;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    margin-bottom: 3px;
}

.history-item-meta {
    font-size: 11px;
    color: #b45309;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.history-item-delete {
    position: absolute;
    top: 4px;
    right: 4px;
    width: 16px;
    height: 16px;
    background: #fde8e8;
    color: #ef4444;
    border-radius: 3px;
    border: none;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 10px;
    cursor: pointer;
    opacity: 0;
    transition: opacity 0.2s;
    line-height: 1;
    padding: 0;
}

.history-item:hover .history-item-delete {
    opacity: 1;
}

.history-item-delete:hover {
    background: #fca5a5;
}

/* 历史记录滚动条 */
.history-list::-webkit-scrollbar {
    width: 4px;
}

.history-list::-webkit-scrollbar-thumb {
    background: #fde68a;
    border-radius: 2px;
}

.history-list::-webkit-scrollbar-track {
    background: transparent;
}

/* ========== 中栏：参数输入 ========== */
.yes-input-panel {
    flex: 1;
    min-width: 0;
    display: flex;
    flex-direction: column;
    border-right: 1px solid #fde68a;
    background: #fff;
    overflow: hidden;
}

.panel-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 11px 16px;
    background: linear-gradient(to bottom, #fffbeb 0%, #fff9f0 100%);
    border-bottom: 1px solid #fde68a;
    flex-shrink: 0;
}

.panel-header h3 {
    margin: 0;
    font-size: 13px;
    font-weight: 600;
    color: #78350f;
}

.panel-tip {
    font-size: 11px;
    color: #b45309;
    font-weight: 400;
}

.yes-input-body {
    flex: 1;
    overflow-y: auto;
    padding: 14px 16px;
    background: #fff;
}

.yes-input-body::-webkit-scrollbar {
    width: 5px;
}

.yes-input-body::-webkit-scrollbar-thumb {
    background: #fde68a;
    border-radius: 2px;
}

.yes-input-body::-webkit-scrollbar-track {
    background: transparent;
}

/* 表单组 */
.form-group {
    margin-bottom: 14px;
}

.form-row {
    display: flex;
    gap: 10px;
    margin-bottom: 0;
}

.form-row-three .form-group {
    flex: 1;
    min-width: 0;
    margin-bottom: 14px;
}

.form-row-two .form-group {
    flex: 1;
    min-width: 0;
    margin-bottom: 14px;
}

.form-group label {
    display: block;
    font-size: 12px;
    font-weight: 600;
    color: #7c5026;
    margin-bottom: 5px;
}

.required-mark {
    color: #ef4444;
    margin-left: 2px;
}

.label-tip {
    font-size: 11px;
    font-weight: 400;
    color: #b45309;
}

/* 输入框 */
.yes-input {
    width: 100%;
    padding: 7px 10px;
    border: 1px solid #fde68a;
    border-radius: 5px;
    font-size: 13px;
    color: #3d2b00;
    background: #fffdf7;
    outline: none;
    transition: all 0.2s;
    box-sizing: border-box;
    font-family: inherit;
}

.yes-input:focus {
    border-color: #f59e0b;
    box-shadow: 0 0 0 3px rgba(245, 158, 11, 0.1);
    background: #fff;
}

/* 文本域 */
.yes-textarea {
    width: 100%;
    padding: 8px 10px;
    border: 1px solid #fde68a;
    border-radius: 5px;
    font-size: 13px;
    color: #3d2b00;
    background: #fffdf7;
    outline: none;
    resize: vertical;
    transition: all 0.2s;
    box-sizing: border-box;
    line-height: 1.6;
    min-height: 72px;
    font-family: inherit;
}

.yes-textarea:focus {
    border-color: #f59e0b;
    box-shadow: 0 0 0 3px rgba(245, 158, 11, 0.1);
    background: #fff;
}

/* 字符计数 */
.char-counter {
    text-align: right;
    font-size: 11px;
    color: #b45309;
    margin-top: 3px;
}

/* 下拉框 */
.yes-select {
    width: 100%;
    padding: 7px 10px;
    border: 1px solid #fde68a;
    border-radius: 5px;
    font-size: 13px;
    color: #3d2b00;
    background: #fffdf7;
    outline: none;
    cursor: pointer;
    transition: all 0.2s;
    box-sizing: border-box;
    font-family: inherit;
    appearance: none;
    background-image: url("data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' fill='none' viewBox='0 0 20 20'%3e%3cpath stroke='%23b45309' stroke-linecap='round' stroke-linejoin='round' stroke-width='1.5' d='M6 8l4 4 4-4'/%3e%3c/svg%3e");
    background-repeat: no-repeat;
    background-position: right 8px center;
    background-size: 18px;
    padding-right: 32px;
}

.yes-select:focus {
    border-color: #f59e0b;
    box-shadow: 0 0 0 3px rgba(245, 158, 11, 0.1);
}

/* 成果快捷标签 */
.achievement-tags {
    display: flex;
    flex-wrap: wrap;
    gap: 6px;
    margin-top: 2px;
}

.achievement-tag {
    display: inline-block;
    padding: 4px 9px;
    background: #fef9c3;
    border: 1px solid #fde68a;
    border-radius: 14px;
    font-size: 12px;
    color: #78350f;
    cursor: pointer;
    transition: all 0.2s;
    user-select: none;
}

.achievement-tag:hover {
    background: #fef3c7;
    border-color: #f59e0b;
    transform: scale(1.03);
    box-shadow: 0 1px 4px rgba(245, 158, 11, 0.2);
}

.achievement-tag:active {
    transform: scale(0.97);
}

/* 快捷键提示 */
.shortcut-tip {
    margin-top: 6px;
    padding: 6px 10px;
    background: #fef9c3;
    border: 1px dashed #fde68a;
    border-radius: 5px;
    font-size: 11px;
    color: #92400e;
}

kbd {
    background: #fff;
    border: 1px solid #fde68a;
    border-radius: 3px;
    padding: 1px 5px;
    font-size: 11px;
    font-family: monospace;
    color: #78350f;
    box-shadow: 0 1px 2px rgba(0,0,0,0.1);
}

/* ========== 右栏：总结展示 ========== */
.yes-result-panel {
    flex: 1.1;
    min-width: 0;
    display: flex;
    flex-direction: column;
    background: #fffef9;
    overflow: hidden;
}

.yes-result-panel .panel-header {
    border-bottom: 1px solid #fde68a;
}

.result-meta {
    display: flex;
    align-items: center;
    gap: 8px;
    flex-wrap: wrap;
    justify-content: flex-end;
}

.result-badge {
    padding: 2px 8px;
    background: #fef3c7;
    border-radius: 10px;
    font-size: 11px;
    color: #92400e;
    border: 1px solid #fde68a;
}

.result-time {
    font-size: 11px;
    color: #b45309;
}

.yes-result-body {
    flex: 1;
    overflow-y: auto;
    padding: 20px;
    position: relative;
}

.yes-result-body::-webkit-scrollbar {
    width: 5px;
}

.yes-result-body::-webkit-scrollbar-thumb {
    background: #fde68a;
    border-radius: 2px;
}

.yes-result-body::-webkit-scrollbar-track {
    background: transparent;
}

/* 初始占位 */
.result-placeholder {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    min-height: 360px;
    text-align: center;
    color: #b45309;
}

/* 年终总结装饰 */
.year-decoration {
    margin-bottom: 24px;
}

.year-circle {
    display: flex;
    gap: 10px;
    justify-content: center;
}

.year-num {
    width: 44px;
    height: 44px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: linear-gradient(135deg, #f59e0b, #d97706);
    color: #fff;
    font-size: 17px;
    font-weight: 700;
    border-radius: 50%;
    box-shadow: 0 3px 10px rgba(217, 119, 6, 0.35);
    animation: yearPulse 2.5s ease-in-out infinite;
}

.year-num:nth-child(1) { animation-delay: 0s; }
.year-num:nth-child(2) { animation-delay: 0.2s; }
.year-num:nth-child(3) { animation-delay: 0.4s; }
.year-num:nth-child(4) { animation-delay: 0.6s; }

@keyframes yearPulse {
    0%, 100% { transform: translateY(0); }
    50% { transform: translateY(-5px); }
}

.placeholder-title {
    font-size: 17px;
    font-weight: 700;
    color: #78350f;
    margin: 0 0 10px 0;
}

.placeholder-desc {
    font-size: 13px;
    color: #b45309;
    margin: 4px 0;
    line-height: 1.6;
}

.placeholder-features {
    display: flex;
    gap: 8px;
    flex-wrap: wrap;
    justify-content: center;
    margin-top: 16px;
}

.feature-badge {
    padding: 4px 10px;
    background: #fef9c3;
    border: 1px solid #fde68a;
    border-radius: 12px;
    font-size: 12px;
    color: #78350f;
}

/* 加载动画 */
.result-loading {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    min-height: 340px;
    text-align: center;
}

.loading-pen {
    margin-bottom: 20px;
}

.pen-icon {
    font-size: 38px;
    animation: penWrite 1.2s ease-in-out infinite alternate;
    display: block;
    margin-bottom: 14px;
}

@keyframes penWrite {
    0% { transform: rotate(-10deg) translateX(-4px); }
    100% { transform: rotate(10deg) translateX(4px); }
}

.loading-typing {
    display: flex;
    gap: 4px;
    justify-content: center;
}

.typing-char {
    display: inline-block;
    font-size: 20px;
    font-weight: 700;
    color: #d97706;
    animation: typingBounce 1.4s ease-in-out infinite;
}

.typing-char:nth-child(1) { animation-delay: 0s; }
.typing-char:nth-child(2) { animation-delay: 0.1s; }
.typing-char:nth-child(3) { animation-delay: 0.2s; }
.typing-char:nth-child(4) { animation-delay: 0.3s; }
.typing-char:nth-child(5) { animation-delay: 0.4s; }
.typing-char:nth-child(6) { animation-delay: 0.5s; }
.typing-char:nth-child(7) { animation-delay: 0.6s; }

.typing-dots {
    font-size: 20px;
    color: #f59e0b;
    animation: typingBounce 1.4s ease-in-out infinite;
    animation-delay: 0.7s;
}

@keyframes typingBounce {
    0%, 60%, 100% { transform: translateY(0); opacity: 1; }
    30% { transform: translateY(-8px); opacity: 0.7; }
}

.loading-text {
    font-size: 13px;
    color: #92400e;
    margin: 12px 0 0 0;
    animation: loadingFade 2s ease-in-out infinite alternate;
}

@keyframes loadingFade {
    0% { opacity: 0.6; }
    100% { opacity: 1; }
}

/* 总结展示区 */
.summary-display {
    /* 入场动画由 jQuery fadeIn 统一控制，不在CSS中添加animation避免冲突 */
}

@keyframes fadeIn {
    from { opacity: 0; transform: translateY(6px); }
    to { opacity: 1; transform: translateY(0); }
}

.summary-header {
    padding: 12px 0 10px;
    margin-bottom: 14px;
    border-bottom: 2px solid #fde68a;
    font-size: 13px;
    color: #92400e;
    display: flex;
    gap: 10px;
    flex-wrap: wrap;
}

.summary-header .summary-meta-item {
    display: flex;
    align-items: center;
    gap: 4px;
    background: #fef9c3;
    border: 1px solid #fde68a;
    border-radius: 12px;
    padding: 3px 10px;
    font-size: 12px;
    color: #78350f;
}

/* ========== Markdown 渲染样式 ========== */
.summary-content {
    line-height: 1.8;
    color: #2d1a00;
    font-size: 14px;
}

.summary-content h2 {
    font-size: 16px;
    font-weight: 700;
    color: #78350f;
    margin: 20px 0 10px;
    padding: 8px 14px;
    background: linear-gradient(to right, #fef3c7, #fffbeb);
    border-left: 4px solid #f59e0b;
    border-radius: 0 5px 5px 0;
}

.summary-content h3 {
    font-size: 14px;
    font-weight: 600;
    color: #92400e;
    margin: 14px 0 8px;
}

.summary-content h4,
.summary-content h5 {
    font-size: 13px;
    font-weight: 600;
    color: #b45309;
    margin: 12px 0 6px;
}

.summary-content p {
    margin: 8px 0;
    line-height: 1.8;
}

.summary-content ul,
.summary-content ol {
    padding-left: 20px;
    margin: 8px 0;
}

.summary-content li {
    margin: 4px 0;
    line-height: 1.7;
}

.summary-content li::marker {
    color: #f59e0b;
}

.summary-content strong {
    color: #78350f;
    font-weight: 700;
}

.summary-content em {
    color: #92400e;
    font-style: italic;
}

.summary-content blockquote {
    margin: 0;
    padding: 10px 16px;
    background: #fef9c3;
    border-left: 3px solid #f59e0b;
    border-radius: 0 5px 5px 0;
    color: #78350f;
    font-size: 13px;
}

.summary-content code {
    background: #fef3c7;
    border: 1px solid #fde68a;
    border-radius: 3px;
    padding: 1px 5px;
    font-size: 12px;
    font-family: monospace;
    color: #78350f;
}

.summary-content pre {
    background: #fffbeb;
    border: 1px solid #fde68a;
    border-radius: 5px;
    padding: 12px;
    overflow-x: auto;
    margin: 12px 0;
}

.summary-content pre code {
    background: none;
    border: none;
    padding: 0;
}

.summary-content hr {
    border: none;
    border-top: 1px solid #fde68a;
    margin: 16px 0;
}

.summary-content table {
    width: 100%;
    border-collapse: collapse;
    margin: 12px 0;
    font-size: 13px;
    border-radius: 6px;
    overflow: hidden;
}

.summary-content th,
.summary-content td {
    padding: 8px 12px;
    border: 1px solid #fde68a;
    text-align: left;
    vertical-align: top;
    line-height: 1.6;
}

.summary-content th {
    background: #fef3c7;
    color: #78350f;
    font-weight: 600;
    font-size: 13px;
}

.summary-content tr:nth-child(even) td {
    background: #fffbeb;
}

.summary-content a {
    color: #d97706;
    text-decoration: underline;
}

/* ========== Toast 通知 ========== */
.yes-toast {
    position: fixed;
    bottom: 28px;
    left: 50%;
    transform: translateX(-50%) translateY(16px);
    background: #1e293b;
    color: #f8fafc;
    padding: 10px 20px;
    border-radius: 20px;
    font-size: 13px;
    font-weight: 500;
    z-index: 99999;
    pointer-events: none;
    opacity: 0;
    transition: all 0.3s ease;
    white-space: nowrap;
    max-width: 90vw;
    text-align: center;
    box-shadow: 0 4px 18px rgba(0, 0, 0, 0.22);
}

.yes-toast.show {
    opacity: 1;
    transform: translateX(-50%) translateY(0);
}

.yes-toast.toast-success { background: #15803d; }
.yes-toast.toast-error { background: #dc2626; }
.yes-toast.toast-warning { background: #d97706; }
.yes-toast.toast-info { background: #1d4ed8; }

/* ========== 示例模态框 ========== */
.yes-modal {
    position: fixed;
    top: 50%;    left: 50%;
    transform: translate(-50%, -50%) scale(0.94);
    z-index: 10001;
    width: 680px;
    max-width: 94vw;
    max-height: 84vh;
    background: #fff;
    border-radius: 12px;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.22);
    overflow: hidden;
    display: flex;
    flex-direction: column;
    animation: meModalSlideIn 0.28s cubic-bezier(.34,1.4,.64,1) forwards;
}

@keyframes meModalSlideIn {
    from { transform: translate(-50%, -50%) scale(0.9); opacity: 0; }
    to   { transform: translate(-50%, -50%) scale(1);   opacity: 1; }
}

.yes-modal-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.45);
    z-index: 10000;
    backdrop-filter: blur(2px);
    animation: meOverlayFadeIn 0.2s ease;
}

@keyframes meOverlayFadeIn {
    from { opacity: 0; }
    to   { opacity: 1; }
}

.yes-modal-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 16px 20px;
    background: linear-gradient(135deg, #b45309, #92400e);
    color: #fff;
    flex-shrink: 0;
}

.yes-modal-header h3 {
    margin: 0;
    font-size: 15px;
    font-weight: 600;
}

.yes-modal-close {
    background: rgba(255, 255, 255, 0.2);
    border: none;
    color: #fff;
    cursor: pointer;
    width: 26px;
    height: 26px;
    border-radius: 5px;
    font-size: 13px;
    transition: background 0.2s;
    display: flex;
    align-items: center;
    justify-content: center;
}

.yes-modal-close:hover {
    background: rgba(255, 255, 255, 0.35);
}

.yes-modal-body {
    flex: 1;
    min-height: 0;
    overflow-y: auto;
    padding: 16px;
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 10px;
}

.yes-modal-body::-webkit-scrollbar {
    width: 5px;
}

.yes-modal-body::-webkit-scrollbar-thumb {
    background: #fde68a;
    border-radius: 2px;
}

/* 示例卡片 */
.example-card {
    padding: 13px 15px;
    background: #fffdf7;
    border: 1px solid #fde68a;
    border-radius: 8px;
    cursor: pointer;
    transition: all 0.2s;
}

.example-card:hover {
    border-color: #f59e0b;
    background: #fffbeb;
    box-shadow: 0 3px 12px rgba(245, 158, 11, 0.15);
    transform: translateY(-2px);
}

.example-card-title {
    font-size: 13px;
    font-weight: 600;
    color: #78350f;
    margin-bottom: 5px;
    display: flex;
    align-items: center;
    gap: 5px;
}

.example-card-title::before {
    content: '🏢';
}

.example-card-meta {
    font-size: 11px;
    color: #b45309;
    line-height: 1.5;
}

.example-card-style {
    display: inline-block;
    margin-top: 6px;
    padding: 2px 7px;
    background: #fef9c3;
    border: 1px solid #fde68a;
    border-radius: 10px;
    font-size: 11px;
    color: #78350f;
}

/* ========== 暗黑模式 ========== */

/* 主容器 */
body.dark .yes-container {
    background: #1a1208;
    border-color: #3d2800;
    box-shadow: 0 2px 12px rgba(0, 0, 0, 0.4);
}

/* 工具栏 */
body.dark .yes-toolbar {
    background: linear-gradient(135deg, #78350f 0%, #451a03 50%, #3b1200 100%);
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.5);
}

body.dark .yes-toolbar-btn {
    background: rgba(254, 215, 170, 0.15);
    border-color: rgba(217, 119, 6, 0.4);
    color: #fde68a;
}

body.dark .yes-toolbar-btn:hover:not(:disabled) {
    background: rgba(254, 215, 170, 0.25);
    box-shadow: 0 3px 8px rgba(0, 0, 0, 0.3);
    color: #fef3c7;
}

body.dark .yes-toolbar-btn-primary {
    background: linear-gradient(135deg, #d97706 0%, #b45309 100%);
    color: #fff;
}

body.dark .yes-toolbar-btn-primary:hover:not(:disabled) {
    background: linear-gradient(135deg, #f59e0b 0%, #d97706 100%);
    color: #fff;
}

body.dark .yes-toolbar-btn-cancel {
    background: rgba(254, 202, 202, 0.1);
    color: #fca5a5;
    border-color: rgba(252, 165, 165, 0.3);
}

/* 主内容区 */
body.dark .yes-main-content {
    background: #1a1208;
}

/* 历史面板 */
body.dark .yes-history-panel {
    background: #1e150a;
    border-right-color: #3d2800;
}

body.dark .history-panel-header {
    background: linear-gradient(to bottom, #261a0a 0%, #1e130a 100%);
    border-bottom-color: #3d2800;
}

body.dark .history-panel-header h3 {
    color: #fde68a;
}

body.dark .history-count {
    color: #f59e0b;
}

body.dark .history-clear-btn {
    background: rgba(254, 226, 226, 0.1);
    color: #fca5a5;
}

body.dark .history-clear-btn:hover {
    background: rgba(254, 202, 202, 0.15);
}

body.dark .history-search {
    border-bottom-color: #3d2800;
}

body.dark .history-search input {
    background: #261a0a;
    border-color: #3d2800;
    color: #fde68a;
}

body.dark .history-search input:focus {
    border-color: #f59e0b;
}

body.dark .history-search input::placeholder {
    color: #7a5a30;
}

body.dark .history-empty {
    color: #7a5a30;
}

body.dark .history-list {
    background: transparent;
}

body.dark .history-item {
    background: #261a0a;
    border-color: #3d2800;
}

body.dark .history-item:hover,
body.dark .history-item.active {
    background: #2e1f0c;
    border-color: #d97706;
}

body.dark .history-item-title {
    color: #fde68a;
}

body.dark .history-item-meta {
    color: #b45309;
}

body.dark .history-list::-webkit-scrollbar-thumb {
    background: #3d2800;
}

/* 输入面板 */
body.dark .yes-input-panel {
    background: #1a1208;
    border-right-color: #3d2800;
}

body.dark .panel-header {
    background: linear-gradient(to bottom, #261a0a 0%, #1e130a 100%);
    border-bottom-color: #3d2800;
}

body.dark .panel-header h3 {
    color: #fde68a;
}

body.dark .panel-tip {
    color: #b45309;
}

body.dark .yes-input-body {
    background: #1a1208;
}

body.dark .yes-input-body::-webkit-scrollbar-thumb {
    background: #3d2800;
}

body.dark .form-group label {
    color: #fde68a;
}

body.dark .label-tip {
    color: #92400e;
}

body.dark .yes-input,
body.dark .yes-textarea,
body.dark .yes-select {
    background: #261a0a;
    border-color: #3d2800;
    color: #fde68a;
}

body.dark .yes-input:focus,
body.dark .yes-textarea:focus,
body.dark .yes-select:focus {
    border-color: #f59e0b;
    background: #2e1f0c;
}

body.dark .yes-input::placeholder,
body.dark .yes-textarea::placeholder {
    color: #5a3a18;
}

body.dark .yes-select {
    background-image: url("data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' fill='none' viewBox='0 0 20 20'%3e%3cpath stroke='%23f59e0b' stroke-linecap='round' stroke-linejoin='round' stroke-width='1.5' d='M6 8l4 4 4-4'/%3e%3c/svg%3e");
}

body.dark .yes-select option {
    background: #261a0a;
    color: #fde68a;
}

body.dark .char-counter {
    color: #b45309;
}

body.dark .achievement-tags {
    /* inherited */
}

body.dark .achievement-tag {
    background: #2e1f0c;
    border-color: #3d2800;
    color: #fde68a;
}

body.dark .achievement-tag:hover {
    background: #3d2800;
    border-color: #f59e0b;
}

body.dark .shortcut-tip {
    background: #261a0a;
    border-color: #3d2800;
    color: #b45309;
}

body.dark kbd {
    background: #2e1f0c;
    border-color: #3d2800;
    color: #fde68a;
}

/* 结果面板 */
body.dark .yes-result-panel {
    background: #1c1409;
}

body.dark .yes-result-panel .panel-header {
    background: linear-gradient(to bottom, #261a0a 0%, #1e130a 100%);
    border-bottom-color: #3d2800;
}

body.dark .yes-result-panel .panel-header h3 {
    color: #fde68a;
}

body.dark .result-badge {
    background: #2e1f0c;
    border-color: #3d2800;
    color: #fde68a;
}

body.dark .result-time {
    color: #b45309;
}

body.dark .yes-result-body::-webkit-scrollbar-thumb {
    background: #3d2800;
}

/* 占位区 */
body.dark .result-placeholder {
    color: #b45309;
}

body.dark .placeholder-title {
    color: #fde68a;
}

body.dark .placeholder-desc {
    color: #b45309;
}

body.dark .feature-badge {
    background: #2e1f0c;
    border-color: #3d2800;
    color: #fde68a;
}

/* 加载区 */
body.dark .loading-text {
    color: #b45309;
}

body.dark .typing-char {
    color: #f59e0b;
}

body.dark .typing-dots {
    color: #fbbf24;
}

body.dark .history-item-delete {
    background: rgba(254, 226, 226, 0.12);
    color: #fca5a5;
}

body.dark .history-item-delete:hover {
    background: rgba(252, 165, 165, 0.22);
}

/* 摘要内容 */
body.dark .summary-content {
    color: #fde68a;
}

body.dark .summary-content h2 {
    color: #fef3c7;
    background: linear-gradient(to right, #2e1f0c, #261a0a);
    border-left-color: #f59e0b;
}

body.dark .summary-content h3 {
    color: #fde68a;
}

body.dark .summary-content h4,
body.dark .summary-content h5 {
    color: #f59e0b;
}

body.dark .summary-content p {
    color: #e2d4b5;
}

body.dark .summary-content strong {
    color: #fbbf24;
}

body.dark .summary-content em {
    color: #f59e0b;
}

body.dark .summary-content blockquote {
    background: #2e1f0c;
    border-left-color: #f59e0b;
    color: #fde68a;
}

body.dark .summary-content code {
    background: #2e1f0c;
    border-color: #3d2800;
    color: #fbbf24;
}

body.dark .summary-content pre {
    background: #261a0a;
    border-color: #3d2800;
}

body.dark .summary-content hr {
    border-top-color: #3d2800;
}

body.dark .summary-content a {
    color: #fbbf24;
}

body.dark .summary-content li {
    color: #e2d4b5;
}

body.dark .summary-content li::marker {
    color: #fbbf24;
}

body.dark .summary-content ul,
body.dark .summary-content ol {
    color: #e2d4b5;
}

body.dark .summary-content table {
    border-color: #3d2800;
}

body.dark .summary-content th {
    background: #2e1f0c;
    color: #fde68a;
    border-color: #3d2800;
}

body.dark .summary-content td {
    border-color: #3d2800;
    color: #e2d4b5;
}

body.dark .summary-content tr:nth-child(even) td {
    background: #261a0a;
}

body.dark .summary-header {
    border-bottom-color: #3d2800;
}

body.dark .summary-header .summary-meta-item {
    background: #2e1f0c;
    border-color: #3d2800;
    color: #fde68a;
}

/* Toast 暗黑 */
body.dark .yes-toast {
    background: #1e293b;
}

/* 模态框暗黑 */
body.dark .yes-modal-overlay {
    background: rgba(0, 0, 0, 0.65);
}

body.dark .yes-modal {
    background: #1a1208;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.6);
}

body.dark .yes-modal-header {
    background: linear-gradient(135deg, #78350f, #451a03);
}

body.dark .yes-modal-body {
    background: #1a1208;
}

body.dark .yes-modal-body::-webkit-scrollbar-thumb {
    background: #3d2800;
}

body.dark .example-card {
    background: #261a0a;
    border-color: #3d2800;
}

body.dark .example-card:hover {
    background: #2e1f0c;
    border-color: #f59e0b;
}

body.dark .example-card-title {
    color: #fde68a;
}

body.dark .example-card-meta {
    color: #b45309;
}

body.dark .example-card-style {
    background: #2e1f0c;
    border-color: #3d2800;
    color: #fde68a;
}

/* ========== 响应式 ========== */
@media (max-width: 900px) {
    .yes-history-panel {
        display: none;
    }

    .yes-main-content {
        flex-direction: column;
    }

    .yes-input-panel,
    .yes-result-panel {
        flex: none;
        min-height: 300px;
        height: 50%;
    }

    .yes-input-panel {
        border-right: none;
        border-bottom: 1px solid #fde68a;
    }

    body.dark .yes-input-panel {
        border-bottom-color: #3d2800;
    }

    .form-row-three {
        flex-direction: column;
    }

    .form-row-two {
        flex-direction: column;
    }
}

@media (max-width: 639px) {
    .yes-toolbar {
        padding: 6px 10px;
    }

    .yes-toolbar .toolbar-title {
        display: none;
    }

    .yes-modal-body {
        grid-template-columns: 1fr;
    }
}
