/* 在线录屏工具样式 - 简洁版 */

/* 页面容器 */
.screen-recorder-page {
    max-width: 1200px;
    margin: 0 auto;
    padding: 40px 20px 80px;
}

/* 页面标题 */
.page-header {
    text-align: center;
    margin-bottom: 48px;
}

.page-header .header-icon {
    width: 56px;
    height: 56px;
    margin: 0 auto 20px;
    padding: 14px;
    background: #3b82f6;
    border-radius: 12px;
    color: white;
}

.page-header h1 {
    font-size: 32px;
    font-weight: 700;
    color: #1e293b;
    margin: 0 0 12px 0;
}

.page-header p {
    font-size: 16px;
    color: #64748b;
    margin: 0;
    max-width: 600px;
    margin: 0 auto;
    line-height: 1.6;
}

/* 录屏应用容器 */
.recorder-app {
    background: white;
    border: 1px solid #e2e8f0;
    border-radius: 12px;
    padding: 32px;
    margin-bottom: 48px;
    min-height: 500px;
}

/* 加载屏幕 */
.loading-screen {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    min-height: 400px;
    gap: 16px;
}

.loading-spinner {
    width: 40px;
    height: 40px;
    border: 3px solid #e2e8f0;
    border-top-color: #3b82f6;
    border-radius: 50%;
    animation: spin 0.8s linear infinite;
}

@keyframes spin {
    to { transform: rotate(360deg); }
}

.loading-screen p {
    color: #64748b;
    font-size: 15px;
}

/* 功能特性 */
.features-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 20px;
    margin-top: 32px;
}

.feature-card {
    padding: 24px;
    border: 1px solid #e2e8f0;
    border-radius: 8px;
    transition: all 0.2s ease;
}

.feature-card:hover {
    border-color: #cbd5e0;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.05);
}

.feature-icon {
    width: 40px;
    height: 40px;
    margin-bottom: 16px;
    color: #3b82f6;
}

.feature-icon svg {
    width: 100%;
    height: 100%;
}

.feature-card h3 {
    font-size: 16px;
    font-weight: 600;
    color: #1e293b;
    margin: 0 0 8px 0;
}

.feature-card p {
    font-size: 14px;
    color: #64748b;
    line-height: 1.6;
    margin: 0;
}

/* 使用步骤 */
.steps-container {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 16px;
    margin-top: 32px;
}

.step-item {
    padding: 20px;
    background: #f8fafc;
    border-radius: 8px;
    border: 1px solid #e2e8f0;
}

.step-number {
    width: 32px;
    height: 32px;
    background: #3b82f6;
    color: white;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 16px;
    font-weight: 700;
    margin-bottom: 12px;
}

.step-content h4 {
    font-size: 15px;
    font-weight: 600;
    color: #1e293b;
    margin: 0 0 6px 0;
}

.step-content p {
    font-size: 13px;
    color: #64748b;
    line-height: 1.5;
    margin: 0;
}

/* 兼容性表格 */
.compatibility-table {
    margin-top: 32px;
    overflow-x: auto;
}

.compatibility-table table {
    width: 100%;
    border-collapse: collapse;
    background: white;
    border: 1px solid #e2e8f0;
    border-radius: 8px;
    overflow: hidden;
}

.compatibility-table thead {
    background: #f8fafc;
}

.compatibility-table th {
    padding: 12px 16px;
    text-align: left;
    font-weight: 600;
    font-size: 13px;
    color: #475569;
    border-bottom: 1px solid #e2e8f0;
}

.compatibility-table td {
    padding: 12px 16px;
    border-bottom: 1px solid #f1f5f9;
    font-size: 14px;
    color: #64748b;
}

.compatibility-table tbody tr:last-child td {
    border-bottom: none;
}

.compatibility-table tbody tr:hover {
    background: #f8fafc;
}

/* FAQ */
.faq-container {
    margin-top: 32px;
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.faq-item {
    background: white;
    border: 1px solid #e2e8f0;
    border-radius: 8px;
    overflow: hidden;
}

.faq-item summary {
    padding: 16px 20px;
    font-size: 15px;
    font-weight: 600;
    color: #1e293b;
    cursor: pointer;
    user-select: none;
    list-style: none;
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.faq-item summary::-webkit-details-marker {
    display: none;
}

.faq-item summary::after {
    content: '+';
    font-size: 20px;
    color: #3b82f6;
    transition: transform 0.2s ease;
}

.faq-item[open] summary::after {
    transform: rotate(45deg);
}

.faq-item p,
.faq-item ul {
    padding: 0 20px 16px;
    margin: 0;
    color: #64748b;
    font-size: 14px;
    line-height: 1.7;
}

.faq-item ul {
    padding-left: 40px;
    padding-top: 8px;
}

.faq-item li {
    margin-bottom: 6px;
}

/* 隐私保护框 */
.privacy-box {
    background: #eff6ff;
    border: 1px solid #bfdbfe;
    border-radius: 8px;
    padding: 20px;
    margin-top: 32px;
    display: flex;
    gap: 16px;
    align-items: flex-start;
}

.privacy-box svg {
    width: 40px;
    height: 40px;
    flex-shrink: 0;
    color: #3b82f6;
}

.privacy-box strong {
    display: block;
    font-size: 16px;
    color: #1e40af;
    margin-bottom: 8px;
}

.privacy-box p {
    color: #1e40af;
    font-size: 14px;
    line-height: 1.6;
    margin: 0;
}

/* 信息区域 */
.info-section {
    margin-top: 48px;
    padding: 32px;
    background: white;
    border: 1px solid #e2e8f0;
    border-radius: 12px;
}

.info-section h2 {
    font-size: 24px;
    font-weight: 700;
    color: #1e293b;
    margin: 0 0 24px 0;
    padding-bottom: 12px;
    border-bottom: 2px solid #3b82f6;
}

.info-section h3 {
    font-size: 18px;
    font-weight: 600;
    color: #1e293b;
    margin: 32px 0 16px 0;
}

.info-section h3:first-of-type {
    margin-top: 0;
}

.info-content {
    color: #64748b;
    font-size: 15px;
    line-height: 1.7;
}

/* 应用界面样式 */

/* 仪表盘 */
.dashboard-view {
    animation: fadeIn 0.3s ease-out;
}

.dashboard-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 16px;
    margin-bottom: 24px;
}

.search-box {
    position: relative;
    flex: 1;
    max-width: 400px;
}

.search-box svg {
    position: absolute;
    left: 12px;
    top: 50%;
    transform: translateY(-50%);
    width: 18px;
    height: 18px;
    color: #94a3b8;
}

.search-box input {
    width: 100%;
    padding: 10px 12px 10px 40px;
    border: 1px solid #e2e8f0;
    border-radius: 8px;
    font-size: 14px;
    transition: all 0.2s ease;
}

.search-box input:focus {
    outline: none;
    border-color: #3b82f6;
    box-shadow: 0 0 0 3px rgba(59, 130, 246, 0.1);
}

/* 按钮 */
.btn-primary {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 10px 20px;
    background: #3b82f6;
    color: white;
    border: none;
    border-radius: 8px;
    font-size: 14px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.2s ease;
}

.btn-primary:hover {
    background: #2563eb;
}

.btn-primary svg {
    width: 18px;
    height: 18px;
}

.btn-back {
    display: flex;
    align-items: center;
    gap: 6px;
    padding: 8px 14px;
    background: white;
    border: 1px solid #e2e8f0;
    border-radius: 6px;
    font-size: 14px;
    color: #64748b;
    cursor: pointer;
    transition: all 0.2s ease;
}

.btn-back:hover {
    border-color: #cbd5e0;
    background: #f8fafc;
}

.btn-back svg {
    width: 16px;
    height: 16px;
}

.btn-icon {
    padding: 6px;
    background: transparent;
    border: none;
    border-radius: 6px;
    cursor: pointer;
    transition: all 0.2s ease;
    color: #64748b;
}

.btn-icon:hover {
    background: #f1f5f9;
    color: #334155;
}

.btn-icon.btn-danger:hover {
    background: #fee2e2;
    color: #dc2626;
}

.btn-icon svg {
    width: 16px;
    height: 16px;
    display: block;
}

/* 录屏网格 */
.recordings-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
    gap: 20px;
}

.recording-card {
    background: white;
    border: 1px solid #e2e8f0;
    border-radius: 8px;
    overflow: hidden;
    transition: all 0.2s ease;
}

.recording-card:hover {
    border-color: #cbd5e0;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.05);
}

.recording-header {
    padding: 12px 16px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    border-bottom: 1px solid #f1f5f9;
}

.recording-header h3 {
    font-size: 15px;
    font-weight: 600;
    color: #1e293b;
    margin: 0;
    flex: 1;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.recording-actions {
    display: flex;
    gap: 4px;
}

.recording-video {
    position: relative;
    aspect-ratio: 16 / 9;
    background: #0f172a;
    overflow: hidden;
}

.recording-video video {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.video-overlay {
    position: absolute;
    inset: 0;
    background: rgba(0, 0, 0, 0);
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0;
    transition: all 0.2s ease;
}

.recording-card:hover .video-overlay {
    background: rgba(0, 0, 0, 0.3);
    opacity: 1;
}

.play-btn {
    width: 48px;
    height: 48px;
    background: white;
    border: none;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: all 0.2s ease;
}

.play-btn:hover {
    transform: scale(1.1);
}

.play-btn svg {
    width: 20px;
    height: 20px;
    color: #3b82f6;
    margin-left: 2px;
}

.video-duration {
    position: absolute;
    bottom: 8px;
    right: 8px;
    background: rgba(0, 0, 0, 0.7);
    color: white;
    padding: 3px 8px;
    border-radius: 4px;
    font-size: 11px;
    font-family: monospace;
}

.recording-footer {
    padding: 10px 16px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    font-size: 12px;
    color: #64748b;
}

.recording-slug {
    font-family: monospace;
    background: #f1f5f9;
    padding: 2px 6px;
    border-radius: 3px;
}

/* 空状态 */
.empty-state {
    text-align: center;
    padding: 60px 20px;
    color: #94a3b8;
}

.empty-state svg {
    width: 64px;
    height: 64px;
    margin: 0 auto 20px;
    opacity: 0.3;
}

.empty-state h3 {
    font-size: 18px;
    color: #475569;
    margin: 0 0 8px 0;
}

.empty-state p {
    font-size: 14px;
    margin: 0;
}

/* 录制器 */
.recorder-view {
    animation: fadeIn 0.3s ease-out;
}

.recorder-header {
    display: flex;
    align-items: center;
    gap: 12px;
    margin-bottom: 24px;
    padding-bottom: 16px;
    border-bottom: 1px solid #e2e8f0;
}

.recorder-header h2 {
    font-size: 20px;
    font-weight: 700;
    color: #1e293b;
    margin: 0;
}

.recorder-content {
    display: grid;
    grid-template-columns: 2fr 1fr;
    gap: 24px;
}

.recorder-preview {
    position: relative;
    aspect-ratio: 16 / 9;
    background: #0f172a;
    border-radius: 8px;
    overflow: hidden;
}

.recorder-preview video {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: none;
}

.preview-placeholder {
    position: absolute;
    inset: 0;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    color: #64748b;
}

.preview-placeholder svg {
    width: 48px;
    height: 48px;
    margin-bottom: 12px;
    opacity: 0.3;
}

.preview-placeholder p {
    font-size: 14px;
    margin: 0;
}

.recorder-controls {
    display: flex;
    flex-direction: column;
    gap: 16px;
}

.control-group {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.control-group label {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 10px 12px;
    background: #f8fafc;
    border: 1px solid #e2e8f0;
    border-radius: 6px;
    cursor: pointer;
    transition: all 0.2s ease;
}

.control-group label:hover {
    background: white;
    border-color: #cbd5e0;
}

.control-group input[type="checkbox"] {
    width: 18px;
    height: 18px;
    cursor: pointer;
}

.control-group span {
    font-size: 14px;
    color: #334155;
    font-weight: 500;
}

.recording-status {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 12px;
    background: #f8fafc;
    border-radius: 6px;
    border: 1px solid #e2e8f0;
}

.status-dot {
    width: 10px;
    height: 10px;
    background: #94a3b8;
    border-radius: 50%;
    transition: all 0.3s ease;
}

.status-dot.recording {
    background: #ef4444;
    animation: pulse 1.5s ease-in-out infinite;
}

@keyframes pulse {
    0%, 100% { opacity: 1; }
    50% { opacity: 0.5; }
}

.status-text {
    flex: 1;
    font-size: 14px;
    color: #475569;
    font-weight: 500;
}

.status-time {
    font-family: monospace;
    font-size: 16px;
    font-weight: 700;
    color: #1e293b;
}

.control-buttons {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.btn-record,
.btn-stop {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    padding: 12px;
    border: none;
    border-radius: 8px;
    font-size: 15px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.2s ease;
}

.btn-record {
    background: #3b82f6;
    color: white;
}

.btn-record:hover {
    background: #2563eb;
}

.btn-stop {
    background: #ef4444;
    color: white;
}

.btn-stop:hover {
    background: #dc2626;
}

.btn-record svg,
.btn-stop svg {
    width: 20px;
    height: 20px;
}

/* 预览模态框 */
.preview-modal {
    position: fixed;
    inset: 0;
    z-index: 9999;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 20px;
}

.modal-overlay {
    position: absolute;
    inset: 0;
    background: rgba(0, 0, 0, 0.75);
}

.modal-content {
    position: relative;
    background: white;
    border-radius: 12px;
    padding: 24px;
    max-width: 800px;
    width: 100%;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.3);
}

.modal-close {
    position: absolute;
    top: 12px;
    right: 12px;
    width: 32px;
    height: 32px;
    background: #f1f5f9;
    border: none;
    border-radius: 50%;
    font-size: 20px;
    color: #64748b;
    cursor: pointer;
    transition: all 0.2s ease;
}

.modal-close:hover {
    background: #e2e8f0;
    color: #334155;
}

.modal-content h3 {
    font-size: 20px;
    font-weight: 700;
    color: #1e293b;
    margin: 0 0 16px 0;
}

.modal-content video {
    width: 100%;
    border-radius: 8px;
    background: #000;
}

/* 错误状态 */
.error-state {
    text-align: center;
    padding: 60px 20px;
}

.error-state h3 {
    font-size: 20px;
    color: #dc2626;
    margin: 0 0 12px 0;
}

.error-state p {
    font-size: 15px;
    color: #64748b;
    margin: 0 0 20px 0;
}

.error-state button {
    padding: 10px 20px;
    background: #3b82f6;
    color: white;
    border: none;
    border-radius: 8px;
    font-size: 14px;
    font-weight: 600;
    cursor: pointer;
}

/* 响应式设计 */
@media (max-width: 1024px) {
    .recorder-content {
        grid-template-columns: 1fr;
    }

    .features-grid {
        grid-template-columns: repeat(2, 1fr);
    }

    .steps-container {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (max-width: 768px) {
    .screen-recorder-page {
        padding: 24px 16px 60px;
    }

    .page-header h1 {
        font-size: 26px;
    }

    .recorder-app {
        padding: 20px;
    }

    .info-section {
        padding: 24px 20px;
    }

    .dashboard-header {
        flex-direction: column;
        align-items: stretch;
    }

    .search-box {
        max-width: none;
    }

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

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

    .steps-container {
        grid-template-columns: 1fr;
    }

    .privacy-box {
        flex-direction: column;
        gap: 12px;
    }
}

/* 动画 */
@keyframes fadeIn {
    from { opacity: 0; }
    to { opacity: 1; }
}
