/* ========== 一键生成朋友圈 - 主容器 ========== */
.om-container {
    display: flex;
    flex-direction: column;
    height: calc(100vh - 200px);
    min-height: 600px;
    background: #f8fafc;
    border-radius: 8px;
    overflow: hidden;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.05);
    transition: all 0.3s ease;
}

/* 全屏模式 */
.om-container.fullscreen {
    position: fixed;
    top: 0;
    left: 0;
    width: 100vw !important;
    height: 100vh !important;
    z-index: 9999;
    border-radius: 0;
    margin: 0;
}

/* ========== 顶部工具栏 ========== */
.om-toolbar {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 8px 14px;
    background: linear-gradient(135deg, #f093fb 0%, #f5576c 100%);
    color: white;
    flex-wrap: wrap;
    gap: 8px;
    box-shadow: 0 2px 10px rgba(240, 147, 251, 0.35);
    flex-shrink: 0;
}

.toolbar-group {
    display: flex;
    gap: 6px;
    align-items: center;
    flex-wrap: wrap;
}

.toolbar-title-group {
    flex: 1;
    justify-content: center;
}

.om-toolbar-title {
    font-size: 14px;
    font-weight: 600;
    color: #fff;
    letter-spacing: 0.5px;
    text-shadow: 0 1px 2px rgba(0,0,0,0.1);
}

.om-toolbar-btn {
    padding: 6px 12px;
    background: rgba(255,255,255,0.95);
    border: none;
    border-radius: 5px;
    cursor: pointer;
    font-size: 12px;
    font-weight: 500;
    color: #e8408a;
    transition: all 0.2s;
    white-space: nowrap;
}

.om-toolbar-btn:hover:not(:disabled) {
    background: #fff;
    transform: translateY(-1px);
    box-shadow: 0 3px 8px rgba(0,0,0,0.15);
}

.om-toolbar-btn:disabled {
    opacity: 0.5;
    cursor: not-allowed;
}

/* ========== 主内容区域 ========== */
.om-main-content {
    display: flex;
    flex: 1;
    overflow: hidden;
    background: #f8fafc;
}

/* ========== 左侧历史面板 ========== */
.om-history-panel {
    width: 190px;
    min-width: 160px;
    background: #fff;
    border-right: 1px solid #e2e8f0;
    display: flex;
    flex-direction: column;
    overflow: hidden;
    flex-shrink: 0;
}

.om-history-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 12px 14px;
    background: linear-gradient(to bottom, #fafafa, #f5f5f5);
    border-bottom: 1px solid #e2e8f0;
    flex-shrink: 0;
}

.om-history-header h3 {
    margin: 0;
    font-size: 13px;
    font-weight: 600;
    color: #475569;
}

.om-history-clear-btn {
    background: #fff0f0;
    border: none;
    color: #ef4444;
    font-size: 11px;
    cursor: pointer;
    padding: 2px 7px;
    border-radius: 3px;
    transition: background 0.2s;
}

.om-history-clear-btn:hover { background: #fde8e8; }

.om-history-search {
    padding: 8px;
    margin-bottom: 2px;
    flex-shrink: 0;
}

.om-history-search-wrap {
    display: flex;
    align-items: center;
    position: relative;
}

.om-history-search-wrap input {
    width: 100%;
    padding: 6px 28px 6px 10px;
    border: 1px solid #e0e0e0;
    border-radius: 4px;
    font-size: 12px;
    outline: none;
    box-sizing: border-box;
    transition: border-color 0.2s;
}

.om-history-search-wrap input:focus { border-color: #f093fb; }

.om-search-clear-btn {
    position: absolute;
    right: 6px;
    background: none;
    border: none;
    color: #94a3b8;
    cursor: pointer;
    font-size: 14px;
    line-height: 1;
    padding: 0;
}

.om-history-list {
    flex: 1;
    overflow-y: auto;
    padding: 6px;
    scrollbar-width: thin;
    scrollbar-color: transparent transparent;
}

.om-history-list:hover {
    scrollbar-color: #f97316 transparent;
}

.om-history-list::-webkit-scrollbar { width: 4px; }
.om-history-list::-webkit-scrollbar-track { background: transparent; }
.om-history-list::-webkit-scrollbar-thumb { background: transparent; border-radius: 2px; }
.om-history-list:hover::-webkit-scrollbar-thumb { background: #f97316; }

.om-history-empty {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 24px 12px;
    color: #94a3b8;
    font-size: 12px;
    gap: 4px;
}

.om-history-empty small { font-size: 11px; color: #cbd5e1; }

.om-history-item {
    display: flex;
    flex-direction: column;
    padding: 9px 10px;
    margin: 3px 0;
    background: #f8fafc;
    border: 1px solid #e2e8f0;
    border-radius: 6px;
    cursor: pointer;
    transition: all 0.2s;
    position: relative;
    animation: omFadeIn 0.2s ease;
}

.om-history-item:hover {
    background: #fdf4ff;
    border-color: #f093fb;
    transform: translateX(2px);
}

.om-history-item.active {
    background: #fdf4ff;
    border-color: #e879f9;
    box-shadow: 0 1px 4px rgba(232, 121, 249, 0.2);
}

.om-history-item-delete {
    position: absolute;
    top: 4px;
    right: 4px;
    width: 18px;
    height: 18px;
    background: #fde8e8;
    color: #ef4444;
    border: none;
    border-radius: 3px;
    font-size: 12px;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0;
    transition: opacity 0.2s;
}

.om-history-item:hover .om-history-item-delete { opacity: 1; }

.om-history-item-title {
    font-size: 12px;
    font-weight: 600;
    color: #334155;
    margin-right: 20px;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.om-history-item-meta {
    font-size: 11px;
    color: #94a3b8;
    margin-top: 2px;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.om-history-item-time {
    font-size: 10px;
    color: #cbd5e1;
    margin-top: 3px;
}

.om-history-footer {
    padding: 6px 12px;
    border-top: 1px solid #e2e8f0;
    background: #fafafa;
    text-align: center;
}

.om-history-count {
    font-size: 11px;
    color: #94a3b8;
}

/* ========== 中间输入面板 ========== */
.om-input-panel {
    width: 320px;
    min-width: 280px;
    background: #fff;
    border-right: 1px solid #e2e8f0;
    display: flex;
    flex-direction: column;
    overflow: hidden;
    flex-shrink: 0;
}

.om-panel-header {
    padding: 12px 16px;
    background: linear-gradient(to bottom, #fafafa, #f5f5f5);
    border-bottom: 1px solid #e2e8f0;
    flex-shrink: 0;
}

.om-panel-header h3 {
    margin: 0;
    font-size: 14px;
    font-weight: 600;
    color: #475569;
}

.om-input-section {
    flex: 1;
    overflow-y: auto;
    padding: 14px;
    scrollbar-width: thin;
    scrollbar-color: transparent transparent;
}

.om-input-section:hover {
    scrollbar-color: #f97316 transparent;
}

.om-input-section::-webkit-scrollbar { width: 4px; }
.om-input-section::-webkit-scrollbar-track { background: transparent; }
.om-input-section::-webkit-scrollbar-thumb { background: transparent; border-radius: 2px; }
.om-input-section:hover::-webkit-scrollbar-thumb { background: #f97316; }

.om-form-row {
    display: flex;
    gap: 10px;
    margin-bottom: 14px;
}

.om-form-field {
    flex: 1;
    min-width: 0;
}

.om-field-wide {
    flex: none;
    width: 100%;
}

.om-input-label {
    display: block;
    font-size: 12px;
    font-weight: 600;
    color: #475569;
    margin-bottom: 6px;
}

.om-required {
    color: #f5576c;
    margin-left: 2px;
}

.om-select-input {
    width: 100%;
    padding: 8px 10px;
    border: 1px solid #e2e8f0;
    border-radius: 6px;
    font-size: 13px;
    color: #334155;
    background: #fafafa;
    outline: none;
    cursor: pointer;
    transition: border-color 0.2s;
    box-sizing: border-box;
}

.om-select-input:focus { border-color: #f093fb; background: #fff; }

.om-textarea {
    width: 100%;
    padding: 10px 12px;
    border: 1px solid #e2e8f0;
    border-radius: 6px;
    font-size: 13px;
    color: #334155;
    line-height: 1.6;
    resize: vertical;
    outline: none;
    transition: border-color 0.2s, box-shadow 0.2s;
    box-sizing: border-box;
    font-family: inherit;
    scrollbar-width: thin;
    scrollbar-color: transparent transparent;
}

.om-textarea:hover {
    scrollbar-color: #f97316 transparent;
}

.om-textarea::-webkit-scrollbar { width: 4px; }
.om-textarea::-webkit-scrollbar-thumb { background: transparent; border-radius: 2px; }
.om-textarea:hover::-webkit-scrollbar-thumb { background: #f97316; }

.om-textarea:focus {
    border-color: #f093fb;
    box-shadow: 0 0 0 3px rgba(240, 147, 251, 0.1);
}

.om-textarea.is-error { border-color: #f5576c; }

.om-char-counter-row {
    display: flex;
    justify-content: flex-end;
    margin-top: 4px;
}

.om-char-counter {
    font-size: 11px;
    color: #94a3b8;
}

.om-char-counter.is-warn { color: #d97706; }
.om-char-counter.is-many { color: #f5576c; }

/* Emoji 密度选择 */
.om-emoji-level-group {
    display: flex;
    gap: 6px;
    flex-wrap: wrap;
}

.om-emoji-radio {
    display: flex;
    align-items: center;
    gap: 5px;
    padding: 7px 12px;
    border: 1.5px solid #e2e8f0;
    border-radius: 20px;
    cursor: pointer;
    font-size: 12px;
    color: #475569;
    transition: all 0.2s;
    user-select: none;
    background: #fafafa;
}

.om-emoji-radio:hover { border-color: #f093fb; color: #e8408a; background: #fdf4ff; }

.om-emoji-radio input[type="radio"] { display: none; }

.om-emoji-radio:has(input:checked) {
    border-color: #f5576c;
    background: linear-gradient(135deg, #fdf4ff, #fff0f5);
    color: #e8408a;
    font-weight: 600;
    box-shadow: 0 1px 4px rgba(240, 147, 251, 0.2);
}

/* ========== 操作按钮区 ========== */
.om-action-section {
    padding: 14px;
    border-top: 1px solid #e2e8f0;
    background: #fafafa;
    display: flex;
    gap: 8px;
    flex-shrink: 0;
}

.om-generate-btn {
    flex: 1;
    padding: 12px;
    background: linear-gradient(135deg, #f093fb 0%, #f5576c 100%);
    color: #fff;
    border: none;
    border-radius: 8px;
    font-size: 14px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.2s;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 6px;
}

.om-generate-btn:hover:not(:disabled) {
    transform: translateY(-1px);
    box-shadow: 0 6px 20px rgba(240, 147, 251, 0.4);
}

.om-generate-btn:active:not(:disabled) { transform: translateY(0); }

.om-generate-btn:disabled {
    opacity: 0.6;
    cursor: not-allowed;
    transform: none;
}

.om-generate-btn.om-btn-generating {
    background: linear-gradient(135deg, #e879f9 0%, #f5576c 100%);
    background-size: 200% auto;
    animation: omBtnShimmer 1.8s linear infinite;
    cursor: wait;
}

@keyframes omBtnShimmer {
    0%   { background-position: 0%   center; }
    50%  { background-position: 100% center; }
    100% { background-position: 0%   center; }
}

.om-btn-icon { font-size: 16px; }

.om-cancel-btn {
    padding: 12px 16px;
    background: #f1f5f9;
    color: #64748b;
    border: 1px solid #e2e8f0;
    border-radius: 8px;
    font-size: 13px;
    cursor: pointer;
    transition: all 0.2s;
    display: flex;
    align-items: center;
    gap: 5px;
}

.om-cancel-btn:hover { background: #e2e8f0; }

/* ========== 右侧结果面板 ========== */
.om-result-panel {
    flex: 1;
    display: flex;
    flex-direction: column;
    overflow: hidden;
    background: #f8fafc;
    min-width: 0;
}

.om-result-panel-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-shrink: 0;
}

.om-result-actions {
    display: flex;
    gap: 6px;
}

.om-result-action-btn {
    padding: 5px 10px;
    background: #fff;
    border: 1px solid #e2e8f0;
    border-radius: 5px;
    font-size: 11px;
    color: #64748b;
    cursor: pointer;
    transition: all 0.2s;
}

.om-result-action-btn:hover {
    border-color: #f093fb;
    color: #e8408a;
    background: #fdf4ff;
}

/* ========== 占位符 ========== */
.om-result-placeholder {
    flex: 1;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 40px 30px;
    text-align: center;
    overflow-y: auto;
    scrollbar-width: thin;
    scrollbar-color: transparent transparent;
}

.om-result-placeholder:hover {
    scrollbar-color: #f97316 transparent;
}

.om-result-placeholder::-webkit-scrollbar { width: 4px; }
.om-result-placeholder::-webkit-scrollbar-thumb { background: transparent; border-radius: 2px; }
.om-result-placeholder:hover::-webkit-scrollbar-thumb { background: #f97316; }

.om-placeholder-icon {
    font-size: 52px;
    margin-bottom: 16px;
    filter: grayscale(0.2);
}

.om-placeholder-title {
    font-size: 18px;
    font-weight: 700;
    color: #334155;
    margin: 0 0 10px;
}

.om-placeholder-desc {
    font-size: 13px;
    color: #94a3b8;
    max-width: 360px;
    line-height: 1.7;
    margin: 0 0 20px;
}

.om-placeholder-tips {
    display: flex;
    flex-direction: column;
    gap: 8px;
    margin-bottom: 24px;
}

.om-tip-item {
    font-size: 12px;
    color: #64748b;
    padding: 7px 14px;
    background: #fff;
    border-radius: 20px;
    border: 1px solid #e2e8f0;
}

.om-placeholder-quick-start {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 10px;
}

.om-placeholder-btn {
    padding: 12px 24px;
    background: linear-gradient(135deg, #f093fb 0%, #f5576c 100%);
    color: #fff;
    border: none;
    border-radius: 25px;
    font-size: 14px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.2s;
    box-shadow: 0 4px 15px rgba(240, 147, 251, 0.35);
}

.om-placeholder-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(240, 147, 251, 0.45);
}

.om-placeholder-shortcut { font-size: 11px; color: #cbd5e1; }

/* ========== 加载状态 ========== */
.om-result-loading {
    flex: 1;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 16px;
    padding: 40px;
}

.om-loading-animation {
    display: flex;
    gap: 8px;
}

.om-loading-dot {
    width: 10px;
    height: 10px;
    border-radius: 50%;
    background: linear-gradient(135deg, #f093fb, #f5576c);
    animation: omLoadingBounce 1.2s ease-in-out infinite;
}

@keyframes omLoadingBounce {
    0%, 80%, 100% { transform: scale(0.6); opacity: 0.5; }
    40%           { transform: scale(1.1); opacity: 1; }
}

.om-loading-dot:nth-child(1) { background: #f093fb; }
.om-loading-dot:nth-child(2) { animation-delay: 0.16s; background: #e879f9; }
.om-loading-dot:nth-child(3) { animation-delay: 0.32s; background: #f5576c; }

.om-loading-text {
    font-size: 14px;
    font-weight: 600;
    color: #475569;
    margin: 0;
}

.om-loading-sub {
    font-size: 12px;
    color: #94a3b8;
    margin: 0;
}

/* ========== 结果内容 ========== */
.om-result-content {
    flex: 1;
    min-height: 0;
    overflow-y: auto;
    padding: 14px;
    display: flex;
    flex-direction: column;
    gap: 12px;
    scrollbar-width: thin;
    scrollbar-color: transparent transparent;
}

.om-result-content:hover {
    scrollbar-color: #f97316 transparent;
}

.om-result-content::-webkit-scrollbar { width: 4px; }
.om-result-content::-webkit-scrollbar-track { background: transparent; }
.om-result-content::-webkit-scrollbar-thumb { background: transparent; border-radius: 2px; }
.om-result-content:hover::-webkit-scrollbar-thumb { background: #f97316; }

/* ========== 手机预览模块 ========== */
.om-phone-preview {
    background: #fff;
    border-radius: 16px;
    padding: 16px;
    box-shadow: 0 4px 20px rgba(0,0,0,0.08);
    border: 1px solid #f0e6fa;
    position: relative;
}

.om-phone-header {
    display: flex;
    align-items: center;
    gap: 10px;
    margin-bottom: 12px;
    padding-bottom: 10px;
    border-bottom: 1px solid #f5e8ff;
}

.om-phone-avatar {
    width: 38px;
    height: 38px;
    background: linear-gradient(135deg, #f093fb, #f5576c);
    border-radius: 8px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 18px;
    flex-shrink: 0;
}

.om-phone-name {
    font-size: 13px;
    font-weight: 700;
    color: #1a1a2e;
}

.om-phone-meta {
    display: flex;
    flex-direction: column;
    min-width: 0;
}

.om-phone-time {
    font-size: 11px;
    color: #94a3b8;
    margin-top: 2px;
}

.om-phone-body {
    font-size: 14px;
    line-height: 1.75;
    color: #2d2d2d;
    white-space: pre-wrap;
    word-break: break-word;
    margin-bottom: 10px;
    min-height: 36px;
}

.om-phone-hashtags {
    font-size: 12px;
    color: #1d6fa4;
    margin-bottom: 10px;
    word-break: break-word;
}

.om-phone-actions {
    display: flex;
    gap: 8px;
}

.om-phone-copy-btn {
    padding: 6px 14px;
    background: linear-gradient(135deg, #f093fb 0%, #f5576c 100%);
    color: #fff;
    border: none;
    border-radius: 20px;
    font-size: 12px;
    cursor: pointer;
    transition: all 0.2s;
}

.om-phone-copy-btn:hover { transform: translateY(-1px); box-shadow: 0 3px 10px rgba(240,147,251,0.35); }

/* ========== 结果区块（可折叠） ========== */
.om-result-section {
    background: #fff;
    border-radius: 10px;
    border: 1px solid #e2e8f0;
    overflow: hidden;
    flex-shrink: 0;
    transition: all 0.2s;
}

.om-result-section-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 11px 14px;
    cursor: pointer;
    background: linear-gradient(to right, #fdf4ff, #fff);
    border-bottom: 1px solid #f0e6fa;
    transition: all 0.2s;
    user-select: none;
}

.om-result-section-header:hover {
    background: linear-gradient(to right, #fae8ff, #fff0f5);
}

.om-section-header-left {
    display: flex;
    align-items: center;
    gap: 8px;
}

.om-section-icon { font-size: 15px; }

.om-section-title {
    font-size: 13px;
    font-weight: 600;
    color: #334155;
}

.om-section-header-right {
    display: flex;
    align-items: center;
    gap: 8px;
}

.om-section-copy-btn {
    padding: 3px 8px;
    background: none;
    border: 1px solid #e2e8f0;
    border-radius: 4px;
    font-size: 11px;
    cursor: pointer;
    color: #64748b;
    transition: all 0.2s;
}

.om-section-copy-btn:hover { border-color: #f093fb; color: #e8408a; }

.om-section-collapse-icon {
    font-size: 12px;
    color: #94a3b8;
    transition: transform 0.25s;
}

.om-result-section.collapsed .om-section-collapse-icon {
    transform: rotate(-90deg);
}

.om-result-section.collapsed .om-result-section-header {
    border-bottom-color: transparent;
}

.om-section-body {
    padding: 14px;
    font-size: 13px;
    color: #334155;
    line-height: 1.75;
}

.om-main-post-body {
    white-space: pre-wrap;
    font-size: 14px;
    line-height: 1.8;
    word-break: break-word;
}

.om-raw-text-body {
    white-space: pre-wrap;
    font-family: inherit;
    font-size: 13px;
}

/* 备选文案卡片 */
.om-alt-card {
    background: #fafafa;
    border: 1px solid #e2e8f0;
    border-radius: 8px;
    padding: 12px;
    margin-bottom: 10px;
    position: relative;
    transition: all 0.2s;
}

.om-alt-card:last-child { margin-bottom: 0; }

.om-alt-card:hover { border-color: #f093fb; background: #fdf4ff; }

.om-alt-card-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 8px;
}

.om-alt-card-actions {
    display: flex;
    gap: 5px;
    align-items: center;
}

.om-alt-card-label {
    font-size: 11px;
    font-weight: 600;
    color: #94a3b8;
    background: #f1f5f9;
    padding: 2px 8px;
    border-radius: 10px;
}

.om-alt-card-copy-btn {
    padding: 3px 10px;
    background: none;
    border: 1px solid #e2e8f0;
    border-radius: 4px;
    font-size: 11px;
    cursor: pointer;
    color: #64748b;
    transition: all 0.2s;
}

.om-alt-card-copy-btn:hover { border-color: #f093fb; color: #e8408a; }

.om-use-alt-btn {
    padding: 3px 10px;
    background: linear-gradient(135deg, #fdf4ff, #fff0f5);
    border: 1px solid #f093fb;
    border-radius: 4px;
    font-size: 11px;
    cursor: pointer;
    color: #e8408a;
    font-weight: 600;
    transition: all 0.2s;
}

.om-use-alt-btn:hover {
    background: linear-gradient(135deg, #f093fb, #f5576c);
    color: #fff;
    border-color: #f5576c;
}

.om-alt-card.active {
    border-color: #f093fb;
    background: linear-gradient(to bottom, #fdf4ff, #fff);
    box-shadow: 0 2px 8px rgba(240, 147, 251, 0.18);
}

.om-alt-card-text {
    font-size: 13px;
    line-height: 1.75;
    color: #334155;
    white-space: pre-wrap;
    word-break: break-word;
}

/* ========== AI 内容基础标签渲染 ========== */
.om-section-body p { margin: 0 0 10px; line-height: 1.75; }
.om-section-body p:last-child { margin-bottom: 0; }
.om-section-body ul, .om-section-body ol { margin: 8px 0 8px 20px; padding: 0; }
.om-section-body li { margin-bottom: 5px; line-height: 1.65; }
.om-section-body h3, .om-section-body h4 { margin: 12px 0 6px; font-size: 13px; color: #334155; }
.om-section-body strong { color: #1e293b; }
.om-section-body blockquote {
    margin: 10px 0;
    padding: 8px 14px;
    border-left: 3px solid #f093fb;
    background: #fdf4ff;
    border-radius: 0 6px 6px 0;
    color: #64748b;
    font-style: italic;
}
.om-section-body hr { border: none; border-top: 1px solid #e2e8f0; margin: 12px 0; }

/* ========== AI 结果表格样式 ========== */
.om-section-body table {
    width: 100%;
    border-collapse: collapse;
    border-radius: 8px;
    overflow: hidden;
    font-size: 12px;
    margin: 10px 0;
    box-shadow: 0 1px 4px rgba(0,0,0,0.06);
}

.om-section-body table th {
    background: linear-gradient(135deg, #f093fb 0%, #f5576c 100%);
    color: #fff;
    padding: 8px 12px;
    text-align: left;
    font-weight: 600;
    font-size: 12px;
    white-space: nowrap;
}

.om-section-body table td {
    padding: 7px 12px;
    border-bottom: 1px solid #f0e6fa;
    color: #334155;
    line-height: 1.6;
}

.om-section-body table tr:nth-child(even) td { background: #fdf4ff; }
.om-section-body table tr:hover td { background: #fae8ff; transition: background 0.15s; }
.om-section-body table tr:last-child td { border-bottom: none; }

/* ========== 错误提示 ========== */
.om-error-notice {
    display: flex;
    align-items: flex-start;
    gap: 8px;
    padding: 12px 14px;
    background: #fff7ed;
    border: 1px solid #fed7aa;
    border-radius: 8px;
    font-size: 13px;
    color: #9a3412;
}

.om-error-msg {
    flex: 1;
    line-height: 1.6;
}

/* ========== 话题标签气泡 ========== */
.om-hashtags-body {
    display: flex;
    flex-wrap: wrap;
    gap: 6px;
    padding: 2px 0;
}

.om-hashtag-chip {
    display: inline-flex;
    align-items: center;
    padding: 4px 12px;
    background: linear-gradient(135deg, #f0e6ff, #fce8f8);
    border: 1px solid #e9d5ff;
    border-radius: 14px;
    font-size: 12px;
    color: #7c3aed;
    cursor: default;
    transition: all 0.18s;
    user-select: none;
    white-space: nowrap;
}

.om-hashtag-chip:hover {
    background: linear-gradient(135deg, #f093fb 0%, #f5576c 100%);
    color: #fff;
    border-color: #f5576c;
    transform: translateY(-1px);
    box-shadow: 0 3px 8px rgba(240, 147, 251, 0.3);
}

/* ========== 模态框 ========== */
.om-modal {
    display: none;
    position: fixed;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%) scale(0.95);
    width: 90%;
    max-width: 560px;
    max-height: 80vh;
    background: #fff;
    border-radius: 14px;
    box-shadow: 0 20px 60px rgba(0,0,0,0.15);
    z-index: 10001;
    overflow: hidden;
    flex-direction: column;
    transition: transform 0.25s ease, opacity 0.25s ease;
    opacity: 0;
}

.om-modal.show {
    display: flex;
    transform: translate(-50%, -50%) scale(1);
    opacity: 1;
}

.om-modal-overlay {
    display: none;
    position: fixed;
    inset: 0;
    background: rgba(0,0,0,0.35);
    z-index: 10000;
}

.om-modal-overlay.show { display: block; }

.om-modal-content {
    display: flex;
    flex-direction: column;
    flex: 1;
    overflow: hidden;
}

.om-modal-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 16px 20px;
    border-bottom: 1px solid #e2e8f0;
    background: linear-gradient(to right, #fdf4ff, #fff0f5);
    flex-shrink: 0;
}

.om-modal-header h3 {
    margin: 0;
    font-size: 15px;
    font-weight: 700;
    color: #334155;
}

.om-modal-close {
    background: none;
    border: none;
    font-size: 16px;
    cursor: pointer;
    color: #94a3b8;
    padding: 4px 8px;
    border-radius: 4px;
    transition: all 0.2s;
}

.om-modal-close:hover { background: #fde8e8; color: #ef4444; }

.om-modal-body {
    overflow-y: auto;
    padding: 16px;
    flex: 1;
    scrollbar-width: thin;
    scrollbar-color: transparent transparent;
}

.om-modal-body:hover {
    scrollbar-color: #f97316 transparent;
}

.om-modal-body::-webkit-scrollbar { width: 4px; }
.om-modal-body::-webkit-scrollbar-thumb { background: transparent; border-radius: 2px; }
.om-modal-body:hover::-webkit-scrollbar-thumb { background: #f97316; }

.om-example-category { margin-bottom: 20px; }

.om-example-category-header {
    display: flex;
    align-items: center;
    gap: 8px;
    margin-bottom: 10px;
}

.om-cat-icon { font-size: 18px; }

.om-cat-name {
    font-size: 14px;
    font-weight: 700;
    color: #334155;
}

.om-cat-count {
    font-size: 11px;
    color: #94a3b8;
    background: #f1f5f9;
    padding: 2px 8px;
    border-radius: 10px;
}

.om-example-items {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 8px;
}

.om-example-item {
    padding: 12px;
    background: #fafafa;
    border: 1.5px solid #e2e8f0;
    border-radius: 8px;
    cursor: pointer;
    transition: all 0.2s;
}

.om-example-item:hover {
    border-color: #f093fb;
    background: #fdf4ff;
    transform: translateY(-1px);
}

.om-example-item-label {
    font-size: 13px;
    font-weight: 600;
    color: #334155;
    margin-bottom: 4px;
}

.om-example-item-desc {
    font-size: 11px;
    color: #94a3b8;
    line-height: 1.5;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

/* ========== 动画 ========== */
@keyframes omFadeIn {
    from { opacity: 0; transform: translateY(4px); }
    to { opacity: 1; transform: translateY(0); }
}

/* ========== 响应式布局 ========== */
@media (max-width: 900px) {
    .om-history-panel { display: none; }
    .om-input-panel { width: 280px; min-width: 240px; }
}

@media (max-width: 640px) {
    .om-main-content { flex-direction: column; }
    .om-input-panel { width: 100%; border-right: none; border-bottom: 1px solid #e2e8f0; max-height: 55%; }
    .om-result-panel { max-height: 45%; }
    .toolbar-title-group { display: none; }
    .om-example-items { grid-template-columns: 1fr; }
}

/* ========== 打印样式 ========== */
@media print {
    .om-container { height: auto !important; position: static !important; }
    .om-toolbar, .om-history-panel, .om-input-panel, .om-phone-actions,
    .om-result-actions, .om-section-copy-btn, .om-section-collapse-icon { display: none !important; }
    .om-main-content { flex-direction: column; }
    .om-result-panel { width: 100%; overflow: visible; }
    .om-result-content { overflow: visible; }
    .om-result-section { break-inside: avoid; }
}
