/* 基础样式重置 */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen, Ubuntu, Cantarell, sans-serif;
    background: linear-gradient(135deg, #1a1a1f 0%, #2d2d35 100%);
    min-height: 100vh;
    color: rgba(255, 255, 255, 0.9);
    line-height: 1.6;
}

.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 20px;
}

/* 头部样式 */
header {
    position: relative;
    text-align: center;
    margin-bottom: 30px;
    color: white;
}

header h1 {
    font-size: 2.5rem;
    margin-bottom: 10px;
    text-shadow: 0 2px 4px rgba(0,0,0,0.3);
}

header p {
    font-size: 1.1rem;
    opacity: 0.9;
}

/* 外部链接按钮样式 */
.external-link-btn {
    display: inline-block;
    margin-left: 15px;
    padding: 8px 12px;
    background: rgba(255, 255, 255, 0.1);
    border: 1px solid rgba(255, 255, 255, 0.2);
    border-radius: 8px;
    color: rgba(255, 255, 255, 0.9);
    text-decoration: none;
    font-size: 1.2rem;
    transition: all 0.2s ease;
    cursor: pointer;
    vertical-align: middle;
}

.external-link-btn:hover {
    background: rgba(255, 255, 255, 0.2);
    color: white;
    transform: translateY(-1px);
    box-shadow: 0 4px 12px rgba(255, 255, 255, 0.1);
}

.external-link-btn:active {
    transform: translateY(0);
}

/* TURN配置按钮样式 */
.turn-setup-btn {
    background: none;
    border: none;
    color: rgba(255, 255, 255, 0.7);
    cursor: pointer;
    padding: 4px;
    border-radius: 4px;
    transition: all 0.2s ease;
    display: flex;
    align-items: center;
    justify-content: center;
}

.turn-setup-btn:hover {
    background-color: rgba(255, 255, 255, 0.1);
    color: white;
}

.turn-setup-btn:active {
    transform: scale(0.95);
}

.turn-setup-btn svg {
    transition: transform 0.2s ease;
}

.turn-setup-btn:hover svg {
    transform: rotate(45deg);
}

/* 右上角设置按钮样式已移除，现在使用状态指示器中的设置按钮 */

/* 主要内容区域 */
main {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 20px;
    margin-bottom: 30px;
}

/* 面板通用样式 */
.status-panel,
.discovery-panel,
.manual-connect-panel,
.transfer-panel,
.log-panel {
    background: rgba(40, 40, 45, 0.95);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 12px;
    padding: 20px;
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.4);
    transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.status-panel:hover,
.discovery-panel:hover,
.manual-connect-panel:hover {
    /* transform: translateY(-2px); */
    box-shadow: 0 6px 25px rgba(0,0,0,0.15);
}

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

.panel-header h3,
.panel-header h4 {
    color: white;
    font-weight: 600;
}

/* 状态容器 */
.status-container {
    grid-column: 1 / -1;
    display: flex;
    gap: 20px;
    align-items: stretch;
}

/* 状态面板 */
.status-panel {
    flex: 1;
}

/* 二维码面板 */
.qrcode-panel {
    width: 200px;
    min-width: 200px;
    background: rgba(40, 40, 45, 0.95);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 12px;
    padding: 20px;
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.4);
    transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.qrcode-panel:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 25px rgba(0,0,0,0.15);
}

.qrcode-container {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 10px;
}

.qrcode-display {
    width: 150px;
    height: 150px;
    border: 1px solid rgba(255, 255, 255, 0.2);
    border-radius: 8px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: rgba(255, 255, 255, 0.1);
    font-size: 0.9rem;
    color: rgba(255, 255, 255, 0.7);
    text-align: center;
}

.qrcode-hint {
    font-size: 0.8rem;
    color: rgba(255, 255, 255, 0.7);
    text-align: center;
    margin: 0;
}

.status-item {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 10px;
    gap: 10px;
}

.status-item .status-content {
    display: flex;
    align-items: center;
    gap: 10px;
}

.status-label {
    font-weight: 600;
    color: rgba(255, 255, 255, 0.7);
    min-width: 90px;
}

.status-value {
    padding: 4px 12px;
    border-radius: 20px;
    font-size: 0.9rem;
    font-weight: 500;
}

.status-value.connected {
    background: #d4edda;
    color: #155724;
}

.status-value.disconnected {
    background: #f8d7da;
    color: #721c24;
}

.status-value.connecting {
    background: #fff3cd;
    color: #856404;
}

/* 状态面板项目样式 */
.status-item {
    margin-bottom: 15px;
}

.status-item label {
    display: flex;
    align-items: center;
    gap: 8px;
    cursor: pointer;
    font-weight: 500;
    min-width: 90px;
    white-space: nowrap;
}

.status-item input[type="text"] {
    width: 100%;
    padding: 12px 16px;
    background: rgba(255, 255, 255, 0.1);
    border: 1px solid rgba(255, 255, 255, 0.2);
    border-radius: 8px;
    color: white;
    font-size: 1rem;
    transition: all 0.2s ease;
    box-sizing: border-box;
}

.status-item input[type="text"]:focus {
    outline: none;
    border-color: rgba(59, 130, 246, 0.6);
    background: rgba(255, 255, 255, 0.15);
    box-shadow: 0 0 0 3px rgba(59, 130, 246, 0.1);
}

.status-item input[type="text"]::placeholder {
    color: rgba(255, 255, 255, 0.5);
}

/* 节点列表 */
.peer-list {
    max-height: 300px;
    overflow-y: auto;
}

.peer-list-empty {
    text-align: center;
    color: rgba(255, 255, 255, 0.7);
    padding: 20px;
}

.peer-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 12px;
    margin-bottom: 8px;
    background: rgba(255, 255, 255, 0.1);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 8px;
    transition: all 0.2s ease;
    cursor: pointer;
}

.peer-item:hover {
    background: rgba(255, 255, 255, 0.15);
    border-color: rgba(255, 255, 255, 0.2);
}

.peer-info {
    display: flex;
    flex-direction: column;
}

.peer-name {
    font-weight: 600;
    color: white;
}

.peer-id {
    font-size: 0.8rem;
    color: rgba(255, 255, 255, 0.7);
    font-family: monospace;
}

/* 手动连接 */
.manual-connect-form {
    display: flex;
    gap: 10px;
}

.manual-connect-form input {
    flex: 1;
    padding: 12px 16px;
    background: rgba(255, 255, 255, 0.1);
    border: 1px solid rgba(255, 255, 255, 0.2);
    border-radius: 8px;
    color: white;
    font-size: 1rem;
    transition: all 0.2s ease;
    box-sizing: border-box;
}

.manual-connect-form input:focus {
    outline: none;
    border-color: rgba(59, 130, 246, 0.6);
    background: rgba(255, 255, 255, 0.15);
    box-shadow: 0 0 0 3px rgba(59, 130, 246, 0.1);
}

.manual-connect-form input::placeholder {
    color: rgba(255, 255, 255, 0.5);
}

/* 传输面板 */
.transfer-panel {
    grid-column: 1 / -1;
}

.file-drop-zone {
    border: 2px dashed rgba(255, 255, 255, 0.3);
    border-radius: 12px;
    padding: 40px;
    text-align: center;
    transition: all 0.3s ease;
    cursor: pointer;
    margin-bottom: 20px;
    background: rgba(255, 255, 255, 0.05);
}

.file-drop-zone:hover,
.file-drop-zone.drag-over {
    border-color: rgba(59, 130, 246, 0.6);
    background: rgba(59, 130, 246, 0.1);
}

.drop-zone-content {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 15px;
}

.drop-icon {
    font-size: 3rem;
    opacity: 0.6;
}

/* 传输进度 */
.transfer-progress {
    margin-top: 20px;
}

.progress-info {
    display: flex;
    justify-content: space-between;
    margin-bottom: 10px;
}

.progress-bar {
    width: 100%;
    height: 8px;
    background: rgba(255, 255, 255, 0.1);
    border-radius: 4px;
    overflow: hidden;
    margin-bottom: 10px;
}

.progress-fill {
    height: 100%;
    background: linear-gradient(90deg, rgba(59, 130, 246, 0.8), rgba(59, 130, 246, 1));
    transition: width 0.3s ease;
    width: 0%;
}

.transfer-stats {
    display: flex;
    justify-content: space-between;
    font-size: 0.9rem;
    color: rgba(255, 255, 255, 0.7);
    margin-bottom: 15px;
}

/* 接收文件信息 */
.receive-info {
    background: rgba(59, 130, 246, 0.1);
    border: 1px solid rgba(59, 130, 246, 0.3);
    border-radius: 8px;
    padding: 20px;
    margin-top: 20px;
}

/* 保存位置信息 */
.save-location {
    margin-top: 8px;
    font-size: 0.9em;
    color: rgba(255, 255, 255, 0.8);
}

.save-location-label {
    color: rgba(255, 255, 255, 0.6);
    margin-right: 5px;
}

/* 传输完成信息 */
.transfer-complete {
    background: rgba(0, 255, 0, 0.1);
    border: 1px solid rgba(0, 255, 0, 0.3);
    border-radius: 8px;
    padding: 15px;
    margin-top: 15px;
    animation: slideIn 0.3s ease-out;
}

.complete-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 15px;
}

.complete-header h4 {
    color: #4ade80;
    margin: 0;
}

.complete-info {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 15px;
}

.completed-save-location {
    flex: 1;
    font-size: 0.9em;
    color: rgba(255, 255, 255, 0.8);
    padding: 8px 12px;
    background: rgba(255, 255, 255, 0.05);
    border-radius: 4px;
    border-left: 3px solid #4ade80;
}

.completed-save-location span {
    color: rgba(255, 255, 255, 0.9);
}

.complete-info button {
    font-size: 0.9em;
    padding: 8px 16px;
    min-width: 100px;
    flex-shrink: 0;
}

@keyframes slideIn {
    from {
        opacity: 0;
        transform: translateY(-10px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.file-info {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-top: 15px;
}

.file-details {
    display: flex;
    flex-direction: column;
}

.file-actions {
    display: flex;
    gap: 10px;
}

/* 日志面板 */
.log-panel {
    grid-column: 1 / -1;
    max-height: 300px;
}

.log-content {
    max-height: 200px;
    overflow-y: auto;
    background: rgba(30, 30, 35, 0.95);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 8px;
    padding: 15px;
    font-family: monospace;
    font-size: 0.9rem;
    line-height: 1.4;
}

.log-entry {
    margin-bottom: 5px;
    padding: 2px 0;
}

.log-entry.info {
    color: #0066cc;
}

.log-entry.success {
    color: #28a745;
}

.log-entry.warning {
    color: #ffc107;
}

.log-entry.error {
    color: #dc3545;
}

.log-entry.success {
    color: #28a745;
}

/* 按钮样式 */
.btn-primary,
.btn-secondary,
.btn-small,
.btn-danger,
.btn-close {
    padding: 10px 20px;
    border: none;
    border-radius: 8px;
    font-size: 1rem;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.2s ease;
    text-decoration: none;
    display: inline-block;
    text-align: center;
    /* 移动端触摸优化 */
    -webkit-tap-highlight-color: transparent;
    touch-action: manipulation;
    user-select: none;
    -webkit-user-select: none;
}

/* 按钮禁用状态 */
.btn-primary:disabled,
.btn-secondary:disabled,
.btn-small:disabled,
.btn-danger:disabled {
    opacity: 0.5;
    cursor: not-allowed;
    pointer-events: none;
    transform: none !important;
    box-shadow: none !important;
}

.btn-primary:disabled {
    background: rgba(59, 130, 246, 0.3);
    border-color: rgba(59, 130, 246, 0.3);
}

.btn-secondary:disabled {
    background: rgba(255, 255, 255, 0.05);
    color: rgba(255, 255, 255, 0.4);
    border-color: rgba(255, 255, 255, 0.1);
}

.btn-small:disabled {
    background: rgba(255, 255, 255, 0.05);
    color: rgba(255, 255, 255, 0.4);
    border-color: rgba(255, 255, 255, 0.1);
}

.btn-danger:disabled {
    background: rgba(220, 53, 69, 0.3);
    color: rgba(255, 255, 255, 0.4);
}

.btn-primary {
    background: rgba(59, 130, 246, 0.8);
    color: white;
    border: 1px solid rgba(59, 130, 246, 1);
}

.btn-primary:hover {
    background: rgba(59, 130, 246, 1);
    transform: translateY(-1px);
    box-shadow: 0 4px 12px rgba(59, 130, 246, 0.3);
}

.btn-secondary {
    background: rgba(255, 255, 255, 0.1);
    color: rgba(255, 255, 255, 0.9);
    border: 1px solid rgba(255, 255, 255, 0.2);
}

.btn-secondary:hover {
    background: rgba(255, 255, 255, 0.15);
    color: white;
    transform: translateY(-1px);
}

.btn-small {
    padding: 6px 12px;
    font-size: 0.9rem;
    background: rgba(255, 255, 255, 0.1);
    color: rgba(255, 255, 255, 0.9);
    border: 1px solid rgba(255, 255, 255, 0.2);
}

.btn-small:hover {
    background: rgba(255, 255, 255, 0.25);
    color: white;
    border-color: #08680d;
}

.btn-danger {
    background: #dc3545;
    color: white;
}

.btn-danger:hover {
    background: #c82333;
    transform: translateY(-1px);
}

.btn-close {
    background: none;
    border: none;
    font-size: 1.5rem;
    padding: 8px;
    color: rgba(255, 255, 255, 0.6);
    cursor: pointer;
    border-radius: 6px;
    transition: all 0.2s ease;
    display: flex;
    align-items: center;
    justify-content: center;
    width: 32px;
    height: 32px;
}

.btn-close:hover {
    color: rgba(255, 255, 255, 0.9);
    background: rgba(255, 255, 255, 0.1);
    transform: scale(1.1);
}

/* 模态框 */
.modal {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0,0,0,0.5);
    display: flex;
    justify-content: center;
    align-items: center;
    z-index: 1000;
}

.modal-content {
    background: rgba(40, 40, 45, 0.95);
    color: white;
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 12px;
    max-width: 500px;
    width: 90%;
    max-height: 80vh;
    overflow-y: auto;
    box-shadow: 0 10px 30px rgba(0,0,0,0.5);
}

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

.modal-body {
    padding: 20px;
}

.modal-body p.success {
    color: #10b981;
    font-weight: 500;
}

.modal-body p.error {
    color: #ef4444;
    font-weight: 500;
}

.modal-footer {
    display: flex;
    justify-content: flex-end;
    gap: 10px;
    padding: 20px;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
    background: transparent;
}

/* 确保模态框中的按钮样式正确 */
.modal .btn-primary {
    background: rgba(59, 130, 246, 0.8) !important;
    color: white !important;
    border: 1px solid rgba(59, 130, 246, 1) !important;
}

.modal .btn-primary:hover {
    background: rgba(59, 130, 246, 1) !important;
}

.modal .btn-secondary {
    background: rgba(255, 255, 255, 0.1) !important;
    color: rgba(255, 255, 255, 0.9) !important;
    border: 1px solid rgba(255, 255, 255, 0.2) !important;
}

.modal .btn-secondary:hover {
    background: rgba(255, 255, 255, 0.15) !important;
    color: white !important;
}

/* 通知 */
.notifications {
    position: fixed;
    top: 20px;
    right: 20px;
    z-index: 1100;
}

.notification {
    background: rgba(40, 40, 45, 0.95);
    color: white;
    border-radius: 8px;
    padding: 15px 20px;
    margin-bottom: 10px;
    box-shadow: 0 4px 12px rgba(0,0,0,0.3);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-left: 4px solid #3b82f6;
    animation: slideIn 0.3s ease;
    max-width: 300px;
}

.notification.success {
    border-left-color: #10b981;
}

.notification.warning {
    border-left-color: #f59e0b;
}

.notification.error {
    border-left-color: #ef4444;
}

@keyframes slideIn {
    from {
        transform: translateX(100%);
        opacity: 0;
    }
    to {
        transform: translateX(0);
        opacity: 1;
    }
}

/* 工具类 */
.hidden {
    display: none !important;
}

.text-center {
    text-align: center;
}

.text-muted {
    color: #666;
}

.mb-10 {
    margin-bottom: 10px;
}

.mb-20 {
    margin-bottom: 20px;
}

/* 响应式设计 */
@media (max-width: 768px) {
    .container {
        padding: 10px;
    }
    
    main {
        grid-template-columns: 1fr;
        gap: 15px;
    }
    
    /* 移动端状态容器竖直排列 */
    .status-container {
        flex-direction: column;
    }
    
    .qrcode-panel {
        width: 100%;
        min-width: auto;
    }
    
    header h1 {
        font-size: 2rem;
    }
    
    .manual-connect-form {
        flex-direction: row;
        flex-wrap: nowrap;
    }
    
    .manual-connect-form input {
        min-width: 0;
        flex: 1;
    }
    
    .manual-connect-form button {
        flex-shrink: 0;
        white-space: nowrap;
    }
    
    /* 移动端按钮优化 */
    .btn-primary,
    .btn-secondary,
    .btn-small,
    .btn-danger {
        min-height: 44px;
        padding: 12px 20px;
        font-size: 1.1rem;
    }
    
    .file-info {
        flex-direction: column;
        gap: 15px;
        align-items: stretch;
    }
    
    .file-actions {
        justify-content: center;
    }
    
    .modal-content {
        width: 95%;
        margin: 10px;
    }
}

/* 滚动条样式 */
::-webkit-scrollbar {
    width: 8px;
}

::-webkit-scrollbar-track {
    background: rgba(255, 255, 255, 0.1);
    border-radius: 4px;
}

::-webkit-scrollbar-thumb {
    background: rgba(255, 255, 255, 0.3);
    border-radius: 4px;
}

::-webkit-scrollbar-thumb:hover {
    background: rgba(255, 255, 255, 0.5);
}

/* 动画效果 */
.fade-in {
    animation: fadeIn 0.3s ease;
}

@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(10px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.pulse {
    animation: pulse 2s infinite;
}

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

/* 文件接收授权对话框样式 */
.file-auth-modal {
    max-width: 600px;
    width: 90%;
}

.file-info {
    background: rgba(255, 255, 255, 0.1);
    border: 1px solid rgba(255, 255, 255, 0.2);
    border-radius: 8px;
    padding: 15px;
    margin-bottom: 20px;
}

.file-info h4 {
    color: rgba(255, 255, 255, 0.9);
    margin-bottom: 10px;
    font-size: 1.1rem;
}

.file-info p {
    margin: 5px 0;
    font-size: 0.95rem;
    color: rgba(255, 255, 255, 0.8);
}

.auth-settings {
    margin-bottom: 20px;
}

.auth-settings h4 {
    color: rgba(255, 255, 255, 0.9);
    margin-bottom: 15px;
    font-size: 1.1rem;
    border-bottom: 2px solid rgba(255, 255, 255, 0.2);
    padding-bottom: 5px;
}

.setting-group {
    margin-bottom: 20px;
}

.setting-group label {
    display: block;
    margin-bottom: 5px;
    font-weight: 500;
    color: rgba(255, 255, 255, 0.8);
}

.setting-group input[type="checkbox"] {
    margin-right: 8px;
}

.setting-group small {
    display: block;
    color: rgba(255, 255, 255, 0.6);
    font-size: 0.85rem;
    margin-top: 5px;
}

.radio-group {
    margin-top: 8px;
}

.radio-group label {
    display: flex;
    align-items: center;
    margin-bottom: 10px;
    font-weight: normal;
    cursor: pointer;
    color: rgba(255, 255, 255, 0.8);
}

.radio-group input[type="radio"] {
    margin-right: 8px;
}

.radio-group label.disabled {
    color: rgba(255, 255, 255, 0.4);
    cursor: not-allowed;
}

.radio-group label.disabled input {
    cursor: not-allowed;
}

/* .btn-small {
    padding: 4px 8px;
    font-size: 0.8rem;
    margin-left: 10px;
    background: #007bff;
    color: white;
    border: none;
    border-radius: 4px;
    cursor: pointer;
    transition: background-color 0.2s;
}

.btn-small:hover:not(:disabled) {
    background: #0056b3;
}

.btn-small:disabled {
    background: #6c757d;
    cursor: not-allowed;
} */

.setting-group input[type="number"] {
    width: 100px;
    padding: 5px 8px;
    border: 1px solid rgba(255, 255, 255, 0.2);
    border-radius: 4px;
    font-size: 0.9rem;
    background: rgba(255, 255, 255, 0.1);
    color: white;
}

.setting-group select {
    width: 100%;
    padding: 8px;
    border: 1px solid rgba(255, 255, 255, 0.2);
    border-radius: 4px;
    font-size: 0.9rem;
    background: rgba(255, 255, 255, 0.1);
    color: white;
}

.setting-group select[multiple] {
    height: 120px;
}

/* 确保模态框中的表单元素样式正确 */
.modal input[type="text"],
.modal input[type="number"],
.modal select,
.modal textarea {
    background: rgba(255, 255, 255, 0.1) !important;
    border: 1px solid rgba(255, 255, 255, 0.2) !important;
    color: white !important;
}

.modal input[type="text"]:focus,
.modal input[type="number"]:focus,
.modal select:focus,
.modal textarea:focus {
    border-color: rgba(59, 130, 246, 0.6) !important;
    background: rgba(255, 255, 255, 0.15) !important;
    box-shadow: 0 0 0 3px rgba(59, 130, 246, 0.1) !important;
}

.modal input::placeholder,
.modal textarea::placeholder {
    color: rgba(255, 255, 255, 0.5) !important;
}

#directory-info {
    background: rgba(40, 167, 69, 0.2);
    border: 1px solid rgba(40, 167, 69, 0.4);
    border-radius: 4px;
    padding: 8px;
    margin-top: 8px;
    font-size: 0.9rem;
    color: rgba(255, 255, 255, 0.9);
}

.browser-support-info {
    background: rgba(255, 255, 255, 0.05);
    border-top: 1px solid rgba(255, 255, 255, 0.1);
    padding: 10px 0;
    margin-top: 15px;
}

.browser-support-info small {
    display: block;
    font-size: 0.8rem;
}

.support-yes {
    color: #28a745;
    margin-right: 15px;
}

.support-no {
    color: #dc3545;
    margin-right: 15px;
}

/* 连接确认对话框样式 */
.connection-auth-modal {
    max-width: 500px;
    width: 90%;
}

.connection-info {
    background: rgba(59, 130, 246, 0.2);
    border: 1px solid rgba(59, 130, 246, 0.4);
    border-radius: 8px;
    padding: 15px;
    margin-bottom: 20px;
}

.connection-info h4 {
    color: rgba(255, 255, 255, 0.9);
    margin-bottom: 10px;
}

.connection-settings {
    margin-bottom: 20px;
}

.connection-settings h4 {
    color: rgba(255, 255, 255, 0.9);
    margin-bottom: 15px;
    font-size: 1.1rem;
    border-bottom: 2px solid rgba(255, 255, 255, 0.2);
    padding-bottom: 5px;
}

/* 自动接收状态指示器 */
.auto-receive-indicator {
    background: #28a745;
    color: white;
    padding: 6px 10px;
    border-radius: 15px;
    font-size: 0.75rem;
    box-shadow: 0 2px 6px rgba(0,0,0,0.15);
    transition: all 0.3s ease;
    white-space: nowrap;
}

.auto-receive-indicator.hidden {
    opacity: 0;
    transform: translateX(100%);
}

.auto-receive-indicator .settings-btn {
    background: none;
    border: none;
    color: white;
    margin-left: 8px;
    cursor: pointer;
    font-size: 0.9rem;
    text-decoration: underline;
}

.auto-receive-indicator .settings-btn:hover {
    opacity: 0.8;
}

/* 调试控制台样式 */
.debug-console {
    position: fixed;
    bottom: 0;
    left: 0;
    right: 0;
    height: 300px;
    background: rgba(0, 0, 0, 0.95);
    color: #00ff00;
    font-family: 'Courier New', monospace;
    font-size: 12px;
    z-index: 10000;
    border-top: 2px solid #333;
    transition: transform 0.3s ease;
}

.debug-console.collapsed {
    transform: translateY(calc(100% - 40px));
}

.debug-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 8px 12px;
    background: #1a1a1a;
    border-bottom: 1px solid #333;
    height: 40px;
    box-sizing: border-box;
}

.debug-title {
    font-weight: bold;
    color: #fff;
}

.debug-controls {
    display: flex;
    gap: 8px;
}

.debug-btn {
    background: #333;
    color: #fff;
    border: 1px solid #555;
    padding: 4px 8px;
    border-radius: 3px;
    cursor: pointer;
    font-size: 11px;
}

.debug-btn:hover {
    background: #555;
}

.debug-content {
    height: calc(100% - 40px);
    overflow-y: auto;
    padding: 8px;
    white-space: pre-wrap;
    word-break: break-all;
}

.debug-log {
    margin: 2px 0;
    padding: 2px 0;
}

.debug-log.error {
    color: #ff6b6b;
}

.debug-log.warn {
    color: #ffd93d;
}

.debug-log.info {
    color: #74c0fc;
}

.debug-log.log {
    color: #00ff00;
}

.debug-timestamp {
    color: #888;
    margin-right: 8px;
}

/* 移动端调试窗口优化 */
@media (max-width: 768px) {
    .debug-console {
        height: 250px;
        font-size: 11px;
    }
    
    .debug-content {
        padding: 6px;
    }
    
    .debug-btn {
        padding: 6px 10px;
        font-size: 12px;
        min-height: 32px;
    }
}