/* 基于父级 styles.css 进行扩充与适配 */
.back-link {
    color: var(--color-primary);
    text-decoration: none;
    font-size: 0.9rem;
    margin-top: 10px;
    display: inline-block;
}
.back-link:hover {
    text-decoration: underline;
}

.custom-textarea {
    width: 100%;
    height: 300px;
    background: var(--bg-input, rgba(45, 45, 45, 0.9));
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 12px;
    padding: 16px;
    color: #fff;
    font-size: 1rem;
    resize: vertical;
    outline: none;
    font-family: inherit;
    margin-bottom: 16px;
    transition: all 0.3s;
}
.custom-textarea:focus {
    border-color: var(--color-primary);
    box-shadow: 0 0 0 3px rgba(255, 0, 51, 0.2);
}

.controls-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
    gap: 16px;
}

.status-text {
    color: #aaaaaa;
    font-size: 0.95rem;
}

.btn-group {
    display: flex;
    gap: 12px;
}

.hidden {
    display: none !important;
}

/* 动态生成的段落卡片 */
.segment-card {
    background: rgba(45, 45, 45, 0.6);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 12px;
    padding: 20px;
    margin-bottom: 16px;
    transition: transform 0.2s, background 0.2s;
}
.segment-card:hover {
    transform: translateY(-2px);
    background: rgba(55, 55, 55, 0.8);
    border-color: rgba(255, 255, 255, 0.2);
}

.segment-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
    padding-bottom: 12px;
    margin-bottom: 12px;
}

.segment-title {
    font-weight: 600;
    color: var(--color-primary);
    font-size: 1.1rem;
}

.segment-stats {
    font-size: 0.85rem;
    color: #aaaaaa;
}

.segment-content {
    white-space: pre-wrap;
    color: #e0e0e0;
    line-height: 1.8;
    max-height: 350px;
    overflow-y: auto;
    padding-right: 8px;
}
.segment-content::-webkit-scrollbar {
    width: 6px;
}
.segment-content::-webkit-scrollbar-thumb {
    background: rgba(255,255,255,0.2);
    border-radius: 3px;
}

.copy-btn {
    background: transparent;
    color: var(--color-primary);
    border: 1px solid var(--color-primary);
    border-radius: 6px;
    padding: 4px 16px;
    cursor: pointer;
    transition: all 0.2s;
    font-size: 0.9rem;
}
.copy-btn:hover {
    background: rgba(255, 0, 51, 0.1);
}

/* Toast 提示覆盖 */
.toast {
    position: fixed;
    bottom: 30px;
    left: 50%;
    transform: translateX(-50%) translateY(100px);
    background: rgba(30, 30, 30, 0.95);
    border: 1px solid var(--color-primary);
    color: #fff;
    padding: 12px 24px;
    border-radius: 24px;
    opacity: 0;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    z-index: 1000;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.5);
    pointer-events: none;
}
.toast.show {
    transform: translateX(-50%) translateY(0);
    opacity: 1;
}
