* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

button,
a,
.nav-item,
.dropdown-item,
.theme-option,
.model-option,
.model-selector,
.logo,
.mobile-menu-btn,
.sidebar-overlay,
.fa-compress-alt,
[onclick] {
    -webkit-tap-highlight-color: rgba(0, 0, 0, 0.1);
    touch-action: manipulation;
    cursor: pointer;
    -webkit-user-select: none;
    -moz-user-select: none;
    -ms-user-select: none;
    user-select: none;
}

input,
textarea {
    touch-action: manipulation;
    -webkit-tap-highlight-color: transparent;
    font-size: 16px !important;
}

/* 防止iOS Safari在输入框聚焦时自动缩放 */
@media screen and (max-width: 768px) {
    input,
    textarea,
    select {
        font-size: 16px !important;
    }
}

:root {
    --vh: 1vh;
    --safe-area-inset-top: env(safe-area-inset-top, 0px);
    --safe-area-inset-right: env(safe-area-inset-right, 0px);
    --safe-area-inset-bottom: env(safe-area-inset-bottom, 0px);
    --safe-area-inset-left: env(safe-area-inset-left, 0px);
}

.hidden {
    display: none;
}

@supports (padding: max(0px)) {
    body {
        padding-left: var(--safe-area-inset-left);
        padding-right: var(--safe-area-inset-right);
    }
}

body {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', 'Roboto', 'Oxygen', 'Ubuntu', 'Cantarell', 'Fira Sans', 'Droid Sans', 'Helvetica Neue', sans-serif;
    background-color: #ffffff;
    color: #333333;
    line-height: 1.6;
    overflow: hidden;
    height: 100vh;
    height: 100dvh;
    height: 100vh;
    position: fixed;
    width: 100%;
    -webkit-overflow-scrolling: touch;
}

.container {
    display: flex;
    height: 100vh;
    overflow: hidden;
}

.container.popup-open {
    overflow: visible;
}

.sidebar {
    width: 240px;
    background-color: #f7f7f8;
    /* border-right: 1px solid #e5e5e5; */
    display: flex;
    flex-direction: column;
    height: 100vh;
    transition: width 0.3s ease;
}

.sidebar.collapsed {
    width: 60px;
}

.sidebar-header {
    position: relative;
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 17px 18px;
    border-bottom: 1px solid #ececf1;
    transition: padding 0.3s ease;
    flex-shrink: 0;
}

.sidebar.collapsed .sidebar-header {
    padding: 20px 12px;
    justify-content: center;
}

.sidebar-header .logo {
    display: flex;
    align-items: center;
    gap: 12px;
    color: #202123;
    font-weight: 600;
    font-size: 16px;
    transition: all 0.3s ease;
}

.sidebar-header .logo .icon {
    width: 20px;
    height: 20px;
    vertical-align: top;
}

.sidebar-header .logo .icon img {
    width: 100%;
    height: 100%;
    object-fit: contain;
}

.sidebar.collapsed .sidebar-header .logo {
    display: none;
}

.sidebar-header .logo i {
    font-size: 12px;
}

.sidebar-header .header-right {
    display: flex;
    align-items: center;
}

.sidebar-header .header-right i {
    color: #4b5563;
    font-size: 14px;
    cursor: pointer;
}

@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(-5px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.nav-menu {
    padding: 8px 0;
    flex-shrink: 0;
}

.nav-item {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 8px 18px;
    color: #374151;
    cursor: pointer;
    font-weight: 500;
    transition: padding 0.3s ease;
    min-height: 44px;
    font-size: 14px;
}

.sidebar.collapsed .nav-item {
    padding: 12px;
    justify-content: center;
}

.nav-item:hover,
.nav-item:active {
    background-color: #f5f5f5;
}

@media (hover: none) and (pointer: coarse) {
    .nav-item:active {
        background-color: #e5e5e5;
    }
}

.nav-item i {
    font-size: 16px;
    width: 20px;
}

.chat-history {
    flex: 1;
    padding: 0 24px;
    overflow-y: auto;
}

.history-section {
    margin-bottom: 24px;
}

.history-title {
    font-size: 12px;
    font-weight: 600;
    color: #888;
    margin-bottom: 12px;
    letter-spacing: 0.5px;
    padding-left: 8px;
}

.history-item {
    display: flex;
    align-items: center;
    gap: 3px;
    padding: 8px 8px 8px 0;
    cursor: pointer;
    transition: all 0.2s ease;
    margin-bottom: 4px;
}

.history-item:hover {
    background-color: #f5f5f5;
}

.history-item.active {
    background-color: #eee;
    border: 1px solid #eee;
    border-radius: 3px;
}

.history-icon {
    width: 12px;
    height: 12px;
    border-radius: 4px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 700;
    font-size: 10px;
    color: #ffffff;
    flex-shrink: 0;
}

.history-icon i {
    display: inline-block;
    width: 3px;
    height: 3px;
    background-color: #ddd;
    border-radius: 3px;
}

.history-content {
    flex: 1;
    min-width: 0;
}

.history-question {
    font-size: 14px;
    font-weight: 500;
    color: #4b5563;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.sidebar-bottom {
    margin-top: auto;
    padding: 20px 20px;
    border-top: 1px solid #e5e5e5;
    transition: padding 0.3s ease;
    flex-shrink: 0;
}

.sidebar.collapsed .sidebar-bottom {
    padding: 20px 12px;
}

.footer-links {
    display: flex;
    gap: 12px;
    justify-content: space-between;
}

.footer-links li {
    color: #9ca3af;
    text-decoration: none;
    font-size: 10px;
    display: block;
    cursor: pointer;
}

.footer-links li:hover {
    color: #666666;
}

.chat-history {
    padding: 0 10px;
}

.history-question {
    font-size: 13px;
}

.main-content {
    flex: 1;
    display: flex;
    flex-direction: column;
    height: 100vh;
}

.main-header {
    padding: 12px 28px 11px 18px;
    border-bottom: 1px solid #ececf1;
    display: flex;
    align-items: center;
    justify-content: space-between;
    flex-shrink: 0;
    min-height: 60px;
    position: relative;
    z-index: 10;
    background-color: #ffffff;
}

.mobile-menu-btn {
    display: none;
}

.model-selector {
    position: relative;
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 6px 12px;
    background-color: #f5f5f5;
    border-radius: 8px;
    cursor: pointer;
    font-size: 14px;
    color: #333333;
}

.model-selector i {
    font-size: 12px;
}

.model-dropdown {
    position: absolute;
    top: 100%;
    left: 0;
    width: 400px;
    height: auto;
    max-height: 500px;
    background-color: #ffffff;
    border: 1px solid #e5e5e5;
    border-radius: 5px;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
    z-index: 1002;
    display: none;
    margin-top: 4px;
    overflow: hidden;
    opacity: 0;
    transform: translateY(-10px);
    transition: opacity 0.2s ease, transform 0.2s ease;
}

.model-dropdown.show {
    display: block;
    opacity: 1;
    transform: translateY(0);
}

.model-search {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 12px 16px;
    background-color: #fff;
    border-bottom: 1px solid #e5e5e5;
    height: 58px;
}

.model-search i {
    color: #9ca3af;
    font-size: 14px;
}

.search-input {
    flex: 1;
    border: none;
    outline: none;
    background: transparent;
    font-size: 14px;
    color: #333333;
}

.search-input::placeholder {
    color: #9ca3af;
}

.all-models-section {
    background-color: #ffffff;
}

.model-list {
    height: 280px;
    overflow-y: auto;
    padding-bottom: 8px;
}

.model-option {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 14px 16px;
    cursor: pointer;
    transition: background-color 0.15s ease;
    min-height: 44px;
    border-bottom: 1px solid #fff;
}

.model-option:hover,
.model-option:active {
    background-color: #f5f5f5;
}

.model-option.selected {
    background-color: #f5f5f5;
}

@media (hover: none) and (pointer: coarse) {
    .model-option:active {
        background-color: #e5e5e5;
    }
}

.model-info {
    display: flex;
    align-items: center;
    gap: 12px;
    flex: 1;
}

.model-info .model-logo {
    width: 20px;
    height: 20px;
}

.model-info .model-logo img {
    width: 100%;
    height: 100%;
    margin-top: 2px;
}

.model-option .model-logo {
    width: 20px;
    height: 20px;
}

.model-option .model-logo img {
    width: 100%;
    height: 100%;
    margin-top: 2px;
}

.model-option span {
    font-size: 14px;
    color: #333333;
}

.model-option i.fa-check {
    color: #333333;
    font-size: 12px;
}

.model-selected-logo {
    width: 16px;
    height: 16px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.model-selected-logo img {
    width: 100%;
    height: 100%;
    margin-top: 2px;
}

.main-header-right {
    display: flex;
    align-items: center;
}

.main-header-right .logined-btn {
    width: 28px;
    height: auto;
    cursor: pointer;
}

.main-header-right .login-btn {
    background-color: #000000;
    color: #ffffff;
    border: none;
    padding: 8px 16px;
    border-radius: 6px;
    font-weight: 500;
    font-size: 14px;
}

.content-center {
    flex: 1;
    padding: 80px 40px;
    padding-bottom: max(80px, calc(80px + var(--safe-area-inset-bottom)));
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    text-align: center;
}

.input-container {
    width: 100%;
    max-width: 800px;
    min-width: 800px;
    position: relative;
    background-color: #ffffff;
    border: 1px solid #e5e5e5;
    border-radius: 12px;
    padding: 16px;
}

.content-chat-mode {
    padding: 0;
    align-items: stretch;
    text-align: left;
    justify-content: flex-start;
    max-height: calc(100vh - 80px);
    display: flex;
    flex-direction: column;
    overflow: hidden;
    background-color: #ffffff;
    width: 100%;
}

.chat-content {
    flex: 1;
    overflow-y: auto;
    display: flex;
    justify-content: center;
    min-height: 0;
    scrollbar-width: thin;
    scrollbar-color: #888 #ffffff;
    width: 100%;
}

.chat-content::-webkit-scrollbar {
    width: 5px;
}

.chat-content::-webkit-scrollbar-track {
    background: transparent;
    border-radius: 4px;
}

.chat-content::-webkit-scrollbar-thumb {
    background: #888;
    border-radius: 4px;
}

.chat-content::-webkit-scrollbar-thumb:hover {
    background: #555;
}

.chat-content .default-message {
    font-size: 38px;
    font-weight: 600;
    color: #333333;
    margin-bottom: 16px;
    line-height: 1.2;
    text-align: center;
    padding: 88px;
}

#content-container {
    max-width: 1200px;
    width: 100%;
    padding: 3%;
    display: flex;
    flex-direction: column;
    gap: 20px;
    padding-bottom: 50px;
}

.chat-question {
    display: flex;
    flex-direction: column;
    justify-content: flex-end;
    align-items: flex-end;
    max-width: 90%;
    margin-left: auto;
}

.question-bubble {
    display: flex;
    justify-content: end;
}

.question-text {
    color: #333333;
    font-size: 16px;
    display: block;
    padding: 0 5px;
}

.question-text ol,
.question-text ul {
    margin: 12px 0;
    padding-left: 24px;
    list-style-position: outside;
}

.question-text li {
    margin: 8px 0;
    line-height: 1.5;
}
.question-text p{
    margin: 12px 0;
}
.chat-response {
    display: flex;
    flex-direction: column;
    padding-bottom: 50px;
    max-width: 90%;
}

.response-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 18px 5px;
}

.model-info {
    display: flex;
    align-items: center;
    gap: 12px;
}

.model-info .model-name {
    font-weight: 600;
    font-size: 16px;
    color: #333333;
}

.response-actions {
    display: flex;
    gap: 8px;
    align-items: center;
}

.response-content {
    line-height: 1.6;
    color: #333333;
    padding: 0 5px;
}

.response-content h1 {
    margin: 8px 0;
    font-weight: 900;
    font-size: 18px;
    color: #333333;
}

.response-content h2 {
    margin: 8px 0;
    font-weight: 700;
    font-size: 18px;
    color: #333333;
}

.response-content h3 {
    margin: 20px 0;
    font-weight: 500;
    font-size: 18px;
    color: #333333;
}

.response-content p {
    margin: 12px 0;
    font-size: 14px;
}

.response-content ol,
.response-content ul {
    margin: 12px 0;
    padding-left: 24px;
    list-style-position: outside;
}

.response-content li {
    margin: 8px 0;
    font-size: 14px;
    line-height: 1.5;
}

.response-content hr {
    margin: 18px 0;
    border: none;
    border-top: 1px solid #ccc;
    background: linear-gradient(to right, transparent, #ddd, transparent);
    height: 1px;
    opacity: 0.6;
}

.image-container {

overflow: hidden;

max-width: 500px;

width: 100%;
}

.image-container .image-item {
    width: 100%;
    overflow: hidden;
}

.image-container .image-item img {
    width: 100%;
    height: auto;
    object-fit: contain;
    border-radius: 8px;
}

/* 文档容器样式 */
.document-container {
    margin: 12px 0;
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.document-item {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 12px 16px;
    background-color: #f8f9fa;
    border: 1px solid #e1e4e8;
    border-radius: 8px;
    transition: all 0.2s ease;
}

.document-item:hover {
    background-color: #e9ecef;
    border-color: #d1d5db;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.05);
}

.document-link {
    display: flex;
    align-items: center;
    gap: 12px;
    flex: 1;
    text-decoration: none;
    color: #333333;
    min-width: 0;
}

.document-link:hover {
    color: #1976d2;
}

.document-icon {
    font-size: 24px;
    color: #6c757d;
    flex-shrink: 0;
}

.document-name {
    font-size: 14px;
    font-weight: 500;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.document-actions {
    display: flex;
    gap: 8px;
    flex-shrink: 0;
}

.document-action-btn {
    width: 32px;
    height: 32px;
    border: none;
    background-color: #ffffff;
    border-radius: 6px;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: all 0.2s ease;
    color: #666666;
    font-size: 14px;
}

.document-action-btn:hover {
    background-color: #e9ecef;
    color: #333333;
    transform: translateY(-1px);
}

.document-action-btn.download-btn:hover {
    background-color: #e3f2fd;
    color: #1976d2;
}

/* 暗色主题下的文档样式 */
[data-theme="dark"] .document-item {
    background-color: #2d2d2d;
    border-color: #404040;
}

[data-theme="dark"] .document-item:hover {
    background-color: #363636;
    border-color: #4a4a4a;
}

[data-theme="dark"] .document-link {
    color: #e0e0e0;
}

[data-theme="dark"] .document-link:hover {
    color: #64b5f6;
}

[data-theme="dark"] .document-icon {
    color: #9e9e9e;
}

[data-theme="dark"] .document-action-btn {
    background-color: #363636;
    color: #9e9e9e;
}

[data-theme="dark"] .document-action-btn:hover {
    background-color: #404040;
    color: #e0e0e0;
}

[data-theme="dark"] .document-action-btn.download-btn:hover {
    background-color: #1e3a5f;
    color: #64b5f6;
}

.chat-response .response-actions-bottom {
    display: flex;
    gap: 8px;
    justify-content: start;
    padding-top: 8px;
}

.chat-question .response-actions-bottom {
    display: flex;
    gap: 12px;
    justify-content: end;
    padding-top: 8px;
}

.action-btn-bottom {
    width: 30px;
    height: 30px;
    border: none;
    background-color: #ffffff;
    border-radius: 5px;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: all 0.2s ease;
    color: #666666;
    font-size: 14px;
}

.action-btn-bottom:hover {
    background-color: #f8f9fa;
    border-color: #d1d5db;
    color: #333333;
    transform: translateY(-1px);
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
}

.action-btn-bottom:active {
    transform: translateY(0);
    box-shadow: 0 1px 2px rgba(0, 0, 0, 0.1);
}

.copy-btn:hover {
    background-color: #f3e5f5;
    border-color: #7b1fa2;
    color: #7b1fa2;
}

.delete-btn:hover {
    background-color: #fef2f2;
    color: #c61616;
}

.chat-input-container {
    display: flex;
    justify-content: center;
    width: 100%;
    background-color: #ffffff;
    padding: 28px 3% 18px 3%;
    padding-bottom: max(18px, calc(18px + var(--safe-area-inset-bottom)));
    box-sizing: border-box;
    flex-shrink: 0;
    max-width: 1200px;
    margin: 0 auto;
}

.chat-input-container .input-container {
    width: 100%;
    max-width: 100%;
    min-width: 100%;
}

.question-text {
    background-color: #f8f8f8;
    border: none;
    border-radius: 18px;
    padding: 8px 26px;
    display: inline-block;
    line-height: 1.5;
    word-break: break-all;
}

.ai-logos {
    display: flex;
    gap: 20px;
    margin-bottom: 18px;
    flex-wrap: wrap;
    justify-content: center;
}

.ai-logos img {
    width: 22px;
    height: 22px;
}

.main-title {
    font-size: 42px;
    font-weight: 600;
    color: #000;
    padding: 8px 0 28px 0;
    line-height: 1.2;
}

.subtitle {
    font-size: 15px;
    color: #333;
    margin-bottom: 40px;
    max-width: 750px;
    line-height: 1.5;
}

.input-container {
    width: 100%;
    position: relative;
    background-color: #ffffff;
    border: 1px solid #e5e5e5;
    border-radius: 12px;
    padding: 16px;
}

.send-input {
    width: 100%;
    border: none;
    outline: none;
    font-size: 16px;
    background: transparent;
    color: #333333;
    resize: none;
    min-height: 38px;
    max-height: 180px;
    overflow-y: auto;
    line-height: 1.5;
    box-sizing: border-box;
}

.send-input::placeholder {
    color: #9ca3af;
    font-size: 16px;
}

.input-params {
    display: block;
    width: 100%;
    overflow: visible;
    background-color: #f9f9f9;
    font-size: 12px;
    padding: 10px 8px;
    border-radius: 3px;
    margin: 8px 0;
    box-sizing: border-box;
}

.input-params::after {
    content: "";
    display: block;
    clear: both;
}

.input-params li {
    width: 23%;
    font-style: normal;
    display: flex;
    align-items: center;
    justify-content: space-between;
    float: left;
    border: 1px solid #ccc;
    padding: 0 8px 0 3px;
    font-size: 12px;
    border-radius: 3px;
    background-color: #fff;
    cursor: pointer;
    margin: 1%;
    line-height: 30px;
    position: relative;
    text-align: center;
}

.input-params li .param-label {
    flex: 1;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.input-params li .param-arrow {
    font-size: 10px;
    color: #666;
    margin-left: 4px;
    flex-shrink: 0;
}

.input-bottom {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-top: 12px;
}

.input-left-icons {
    display: flex;
    gap: 12px;
}

.input-left-icons i {
    color: #6b7280;
    font-size: 14px;
    cursor: pointer;
    padding: 6px;
    border: 1px solid #e5e5e5;
    border-radius: 3px;
    background-color: #ffffff;
    transition: all 0.2s ease;
}

.input-left-icons i:hover {
    background-color: #f9fafb;
    border-color: #d1d5db;
}

.input-left-icons i.active {

    border: 1px solid #333;

    background-color: #333;

    color: #fff;
}

.input-right-icons {
    display: flex;
    align-items: center;
    gap: 12px;
}

.input-right-icons .send-history {
    background-color: transparent;
    border: none;
    border-radius: 3px;
    height: 30px;
    padding: 0 8px;
    line-height: 30px;
    font-size: 14px;
    color: #999;
}

.input-right-icons .send-history i {
    color: transparent;
    margin-right: 5px;
    border: 1px solid #999;
    padding: 2px;
    border-radius: 2px;
}

.input-right-icons .send-history.active {
    color: #333;
}

.input-right-icons .send-history.active i {
    color: #333;
    border-color: #333;
}

.input-right-icons .send-btn {
    background-color: #374151;
    color: #fff;
    width: 32px;
    height: 32px;
    border-radius: 6px;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    font-size: 14px;
}

/* Plus icon floating menu styles */
.plus-menu {
    position: absolute;
    background: #ffffff;
    border: 1px solid #e5e7eb;
    border-radius: 8px;
    box-shadow: 0 4px 16px rgba(0, 0, 0, 0.12);
    padding: 6px;
    min-width: 160px;
    z-index: 1000;
    animation: fadeInUp 0.2s ease-out;
}

@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(8px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.plus-menu-item {
    display: flex;
    align-items: center;
    padding: 10px 12px;
    border-radius: 6px;
    cursor: pointer;
    transition: background-color 0.15s ease;
    gap: 10px;
}

.plus-menu-item:hover {
    background-color: #f3f4f6;
}

.plus-menu-item i {
    width: 18px;
    font-size: 14px;
    color: #666;
    text-align: center;
}

.plus-menu-item span {
    font-size: 14px;
    color: #111827;
    font-weight: 400;
}

.plus-menu-divider {
    height: 1px;
    background-color: #e5e7eb;
    margin: 4px 0;
}

.plus-menu-section-title {
    padding: 5px;
    font-size: 14px;
    color: #999;
    display: flex;
    align-items: center;
    gap: 8px;
    cursor: default;
    pointer-events: none;
    text-align: center;
}

.plus-menu-section-title i {
    width: 18px;
    font-size: 14px;
    color: #374151;
    text-align: center;
}

.swal2-title {
    font-size: 20px !important;
    font-weight: normal;
    color: #000;
}

.swal2-html-container {
    font-size: 14px !important;
    color: #333;
}

.swal2-confirm,
.swal2-cancel {
    font-size: 14px !important;
    padding: 8px 20px;
}

.swal-popup-full {
    display: flex !important;
    flex-direction: column !important;
    max-width: 90vw;
    max-height: 90vh;
    padding: 38px 18px 8px 18px !important;
}

.swal-html-full {
    flex: 1 !important;
    width: 100% !important;
    padding: 0;
    margin: 0 !important;
    box-sizing: border-box;
}

.swal-iframe {
    width: 100%;
    height: 100%;
    border: none;
    display: block;
}

.swal-close-outside {
    width: 30px;
    height: 30px;
    font-size: 18px;
    position: absolute !important;
    top: 0;
    right: 0;
    background: transparent;
    color: #555;
}

.codeblock {
    position: relative;
    margin: 18px 0;
    padding: 0;
    border-radius: 3px;
    overflow: hidden;
    background-color: #eee;
    max-width: 100%;
}

.codeblock-toolbar {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 8px;
    backdrop-filter: blur(4px);
}

.codeblock-lang {
    opacity: .7;
    text-transform: uppercase;
    letter-spacing: .06em;
    font-size: 14px;
}

.codeblock-actions {
    display: flex;
    gap: .5rem;
}

.codeblock-btn {
    border: 0;
    padding: .25rem .6rem;
    border-radius: 6px;
    font-size: 12px;
    cursor: pointer;
}

.codeblock-btn:active {
    transform: translateY(1px);
}

.codeblock pre {
    margin: 0;
    /* 移除max-height，让代码块根据内容自动撑开 */
    overflow-x: auto;
    overflow-y: visible;
    tab-size: 2;
    display: block;
    /* 统一使用深色背景，与高亮后保持一致 */
    background: #282b2e;
    max-width: 100%;
}

.codeblock pre code {
    display: block;
    padding: 1rem 1.2rem;
    white-space: pre;
    /* 移除overflow，让代码完全显示 */
    overflow-x: auto;
    margin: 5px;
    /* 统一使用深色背景和浅色文字 */
    background: #282b2e;
    color: #a9b7c6;
    max-width: 100%;
}

.bottom-user {
    display: none;
    overflow: hidden;
    padding: 10px 8px 10px 12px;
}


.bottom-user .thumbnail {
    width: 32px;
    height: 32px;
    border-radius: 50%;
    display: block;
    float: left;
}

.bottom-user .info {
    float: left;
}

.bottom-user .nickname {
    font-size: 14px;
    line-height: 1;
    padding-left: 8px;
    color: #000;
}

.bottom-user .balance {
    font-size: 12px;
    padding-left: 8px;
    cursor: pointer;
}

.bottom-user .balance i {
    font-style: normal;
    color: #666;
}

.bottom-user .balance span {
    font-size: 10px;
    color: #0061ff;
}

.bottom-user .logout {
    border: none;
    background: transparent;
    cursor: pointer;
    float: right;
    overflow: hidden;
    display: block;
}

.bottom-user .logout svg {
    width: 20px;
    height: auto;
    color: #666;
    vertical-align: top;
    margin: 3px 5px 0 0;
}

@supports (-webkit-touch-callout: none) {
    @media (max-width: 768px) {
        .sidebar-bottom {
            padding-bottom: max(100px, calc(20px + var(--safe-area-inset-bottom))) !important;
        }

        .content-center {
            padding-bottom: max(40px, calc(40px + var(--safe-area-inset-bottom))) !important;
        }

        .chat-input-container {
            padding-bottom: max(16px, calc(16px + var(--safe-area-inset-bottom))) !important;
        }
    }
}

.reasoning {
    display: block;
    background-color: #f5f5f5;
    font-size: 12px;
    padding: 18px;
    border-radius: 5px;
    color: #666;
    line-height: 1.3;
}

.reasoning p {
    margin: 8px 0;
}

.fee {
    border: none;
    overflow: hidden;
    background-color: #f5f5f5;
    line-height: 20px;
    border-radius: 3px;
    padding: 0 12px;
    font-size: 12px;
}

.fee i {
    display: inline-block;
    font-style: normal;
    padding: 0;
    color: #333;
    font-weight: 600;
}

.fee span {
    color: #666;
    display: inline-block;
    padding: 0 8px;
}

.loading-gif {
    width: 20px;
    height: 20px;
    margin: 18px auto;
}

@media (max-width: 768px) {
    body {
        height: calc(100vh - var(--safe-area-inset-bottom));
    }

    .container {
        height: calc(100vh - var(--safe-area-inset-bottom));
    }

    .container .main-content {
        height: calc(100vh - var(--safe-area-inset-bottom));
    }

    .sidebar {
        width: 280px;
        position: fixed;
        left: -280px;
        top: 0;
        height: calc(100vh - var(--safe-area-inset-bottom));
        z-index: 1000;
        transition: left 0.3s ease;
        box-shadow: 2px 0 10px rgba(0, 0, 0, 0.1);
    }

    .sidebar.show {
        left: 0;
    }

    .main-content {
        width: 100%;
        margin-left: 0;
        height: calc(var(--vh, 1vh) * 100);
    }

    .sidebar-overlay {
        position: fixed;
        top: 0;
        left: 0;
        width: 100%;
        height: calc(var(--vh, 1vh) * 100);
        background-color: rgba(0, 0, 0, 0.5);
        z-index: 999;
        display: none;
    }

    .sidebar-overlay.show {
        display: block;
    }

    /* 模型选择器蒙版 - 仅移动端显示 */
    .model-selector-overlay {
        position: fixed;
        top: 0;
        left: 0;
        width: 100%;
        height: 100%;
        background-color: rgba(0, 0, 0, 0.5);
        z-index: 997;
        opacity: 0;
        visibility: hidden;
        transition: opacity 0.3s ease, visibility 0.3s ease;
        pointer-events: none;
    }

    .model-selector-overlay.show {
        opacity: 1;
        visibility: visible;
        pointer-events: auto;
    }

    .mobile-menu-btn {
        width: 40px;
        height: 38px;
        background-color: #ffffff;
        border: 1px solid #e5e5e5;
        border-radius: 5px;
        display: flex;
        align-items: center;
        justify-content: center;
        cursor: pointer;
        box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
        transition: all 0.3s ease;
        flex-shrink: 0;
    }

    .model-selector-container {
        width: 100%;
        justify-content: center;
        align-items: center;
        display: flex;
        overflow: hidden;
    }

    .mobile-menu-btn:hover {
        background-color: #f5f5f5;
    }

    .mobile-menu-btn i {
        font-size: 16px;
        color: #4b5563;
    }

    .main-header {
        padding: 16px 20px;
        flex-direction: row;
        gap: 0;
        align-items: center;
        justify-content: space-between;
        flex-shrink: 0;
        min-height: 60px;
        position: relative;
        z-index: 998;
        background-color: #ffffff;
        -webkit-transform: translateZ(0);
        transform: translateZ(0);
        box-sizing: border-box;
    }

    .dropdown-menu {
        width: calc(100% - 40px);
        max-width: 240px;
        min-width: 180px;
        left: 20px;
        right: auto;
        top: calc(100% + 8px);
        transform: none;
        margin-top: 0;
        position: absolute;
        box-sizing: border-box;
        z-index: 1001;
    }

    .dropdown-item {
        padding: 6px 10px;
        font-size: 12px;
        white-space: nowrap;
        overflow: hidden;
        text-overflow: ellipsis;
        min-height: 32px;
        display: flex;
        align-items: center;
    }

    .dropdown-item span {
        flex: 1;
        overflow: hidden;
        text-overflow: ellipsis;
        white-space: nowrap;
        font-size: 12px;
    }

    .dropdown-item i {
        font-size: 12px;
        width: 14px;
        flex-shrink: 0;
    }

    .model-selector {
        flex: 1;
        max-width: 100%;
        padding: 6px 12px;
        font-size: 14px;
        min-height: auto;
        height: auto;
        border-radius: 6px;
        background-color: #ffffff;
        position: relative;
        cursor: pointer;
        justify-content: center;
        overflow: hidden;
    }

    .model-selector span {
        max-width: 80%;
        overflow: hidden;
        display: inline-block;
        word-break: keep-all;
    }

    .model-list .model-option span {
        max-width: none;
        overflow: visible;
        text-overflow: initial;
        white-space: normal;
        display: inline;
        word-wrap: break-word;
        word-break: break-word;
    }

    .model-dropdown {
        position: fixed;
        top: 58px;
        left: 0;
        right: 0;
        width: 100vw;
        height: auto;
        background-color: #ffffff;
        border: 1px solid #e5e5e5;
        border-radius: 0;
        box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
        z-index: 1002;
        display: none;
        margin-top: 4px;
        overflow: hidden;
        opacity: 0;
        transform: translateY(-10px);
        transition: opacity 0.2s ease, transform 0.2s ease;
        z-index: 1000;
    }

    .model-dropdown.show {
        display: block;
        opacity: 1;
        transform: translateY(0);
    }

    .popular-models-scroll {
        padding: 0 8px;
    }

    .popular-models {
        padding: 0 0 12px 0;
        gap: 6px;
    }

    .popular-model-item {
        padding: 8px 5px;
        gap: 5px;
    }

    .popular-model-logo {
        width: 20px;
        height: 20px;
    }

    .popular-model-name {
        font-size: 11px;
    }

    .model-list {
        height: 50vh;
    }

    .content-center {
        padding: 40px 20px;
    }

    .main-title {
        font-size: 38px;
    }

    .subtitle {
        font-size: 16px;
        margin-bottom: 32px;
    }

    .ai-logos {
        gap: 12px;
        margin-bottom: 24px;
    }

    .input-container {
        min-width: 100%;
        max-width: 100%;
        padding: 12px;
    }

    .input-bottom {
        margin-top: 16px;
        flex-direction: row;
        gap: 12px;
        align-items: center;
        justify-content: space-between;
    }

    .input-left-icons {
        gap: 8px;
    }

    .input-left-icons i {
        padding: 4px;
        font-size: 12px;
    }

    .input-right-icons {
        gap: 8px;
    }

    .input-right-icons .send-history {
        padding: 0 6px;
        font-size: 12px;
        height: 28px;
        line-height: 28px;
        white-space: nowrap;
        flex-shrink: 0;
    }

    .input-right-icons .send-history i {
        margin-right: 4px;
        padding: 1px;
        font-size: 10px;
    }

    .input-right-icons .send-btn {
        width: 28px;
        height: 28px;
        font-size: 12px;
        flex-shrink: 0;
    }

    /* Mobile styles for plus menu */
    .plus-menu {
        min-width: 200px;
        max-width: calc(100vw - 40px);
    }

    .plus-menu-item {
        padding: 12px 10px;
    }

    .plus-menu-item i {
        font-size: 14px;
    }

    .plus-menu-item span {
        font-size: 13px;
    }

    .plus-menu-section-title {
        padding: 8px 10px 4px;
        font-size: 11px;
    }

    .plus-menu-section-title i {
        font-size: 13px;
    }

    .vs-indicator {
        font-size: 12px;
        padding: 4px 8px;
        margin: 0;
        flex-shrink: 0;
        color: #666666;
        font-weight: 600;
    }

    .main-header-right .login-btn {
        flex-shrink: 0;
        margin-right: 8px;
    }

    .question-display {
        justify-content: flex-end;
        margin-bottom: 16px;
    }

    .question-text {
        max-width: 100%;
        padding: 10px 12px;
    }

    .question-label {
        font-size: 13px;
    }

    .question-content {
        font-size: 13px;
    }

    .ai-response-container {
        flex-direction: column;
        gap: 16px;
        margin-bottom: 16px;
    }

    .ai-response-card {
        min-height: 250px;
        max-height: 350px;
        padding: 16px;
    }

    .card-header {
        margin-bottom: 16px;
        padding-bottom: 12px;
    }

    .card-header .model-name {
        font-size: 14px;
    }

    .card-actions {
        gap: 6px;
    }

    .action-btn {
        width: 28px;
        height: 28px;
        font-size: 12px;
    }

    .card-content h1 {
        font-size: 18px;
    }

    .card-content h2 {
        font-size: 16px;
    }

    .card-content h3 {
        font-size: 15px;
    }

    .card-content p,
    .card-content li {
        font-size: 13px;
    }

    .card-content pre {
        padding: 8px;
        font-size: 12px;
        white-space: pre;
    }

    .card-content code {
        font-size: 12px;
        white-space: pre;
    }

    .content-center.direct-chat-mode {
        height: calc(100vh - 100px);
        max-height: calc(100vh - 100px);
        display: flex;
        flex-direction: column;
        position: relative;
        overflow: hidden;
        background-color: #ffffff;
    }

    .content-chat-mode {
        height: calc(100vh - 150px - var(--safe-area-inset-bottom));
        min-height: 400px;
    }

    .chat-content {
        padding: 16px 3% 180px 3%;
    }

    .question-bubble {
        max-width: 100%;
        padding: 0;
    }

    .question-text {
        border-radius: 5px;
        padding: 0 16px;
    }

    .question-text ol,
    .question-text ul {
        padding-left: 24px;
        list-style-position: outside;
    }

    .response-header {
        padding: 12px 0;
        flex-direction: column;
        align-items: flex-start;
        gap: 12px;
    }

    .model-info .model-name {
        font-size: 14px;
    }

    .response-actions {
        align-self: flex-end;
        gap: 6px;
    }
    
    .response-content h3 {
        font-size: 16px;
        margin: 16px 0 8px 0;
    }

    .response-content p,
    .response-content li {
        font-size: 16px;
    }

    .response-content ol,
    .response-content ul {
        padding-left: 24px;
        list-style-position: outside;
        margin-left: 0;
    }

    .response-content hr {
        margin: 20px 0;
    }

    .chat-input-container {
        margin-top: 16px;
        padding: 0 16px;
        padding-bottom: max(16px, calc(16px + var(--safe-area-inset-bottom)));
        box-sizing: border-box;
    }

    .chat-input-container .input-container {
        width: 100%;
        max-width: 100%;
        min-width: 100%;
    }

    .input-disclaimer {
        font-size: 11px;
    }

    .chat-question {
        max-width: 100%;
    }

    .chat-question .response-actions-bottom {
        padding: 0;
    }

    .chat-response {
        max-width: 100%;
    }

    .chat-response .response-actions-bottom {
        padding: 0;
    }

    .action-btn-bottom {
        width: 36px;
        height: 36px;
        font-size: 14px;
    }

    .fee {
        padding: 0 8px;
    }
}

/* 参数选项浮窗样式 */
.param-options-popup {
    position: fixed;
    z-index: 99999;
    opacity: 0;
    transform: translateY(-10px);
    transition: all 0.2s ease;
    pointer-events: none;
}

.param-options-popup.show {
    opacity: 1;
    transform: translateY(0);
    pointer-events: auto;
}

.param-options-content {
    background: #ffffff;
    border-radius: 8px;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
    max-height: 300px;
    overflow-y: auto;
    border: 1px solid #e0e0e0;
    min-width: 150px;
}

.param-option-item {
    padding: 12px 16px;
    cursor: pointer;
    transition: background 0.15s ease;
    border-bottom: 1px solid #f5f5f5;
    font-size: 14px;
    color: #333;
}

.param-option-item:last-child {
    border-bottom: none;
}

.param-option-item:hover {
    background: #f5f5f5;
}

.param-option-item:active {
    background: #e8e8e8;
}

/* 滚动条样式 */
.param-options-content::-webkit-scrollbar {
    width: 6px;
}

.param-options-content::-webkit-scrollbar-track {
    background: #f1f1f1;
    border-radius: 3px;
}

.param-options-content::-webkit-scrollbar-thumb {
    background: #c1c1c1;
    border-radius: 3px;
}

.param-options-content::-webkit-scrollbar-thumb:hover {
    background: #a8a8a8;
}

/* 图片容器样式 */
.image-item {
    position: relative;
    display: inline-block;
}

.image-item img {
    display: block;
    max-width: 100%;
    height: auto;
    border-radius: 8px;
}

/* 浮动按钮容器 */
.image-actions {
    position: absolute;
    top: 8px;
    right: 8px;
    display: flex;
    gap: 8px;
    opacity: 0;
    transition: opacity 0.2s ease;
}

.image-item:hover .image-actions {
    opacity: 1;
}

/* 图片操作按钮样式 */
.image-action-btn {
    width: 36px;
    height: 36px;
    border: none;
    border-radius: 6px;
    background: rgba(0, 0, 0, 0.6);
    color: white;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 14px;
    transition: all 0.2s ease;
    backdrop-filter: blur(4px);
}

.image-action-btn:hover {
    background: rgba(0, 0, 0, 0.8);
    transform: scale(1.1);
}

.image-action-btn:active {
    transform: scale(0.95);
}

/* 大图模态框 */
.image-modal {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 10000;
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0;
    transition: opacity 0.3s ease;
}

.image-modal.active {
    opacity: 1;
}

.image-modal-backdrop {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.85);
    cursor: pointer;
}

.image-modal-content {
    position: relative;
    max-width: 90%;
    max-height: 90%;
    z-index: 10001;
    display: flex;
    align-items: center;
    justify-content: center;
}

.image-modal-content img {
    max-width: 100%;
    max-height: 90vh;
    border-radius: 8px;
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.5);
}

.image-modal-close {
    position: absolute;
    top: -40px;
    right: 0;
    width: 40px;
    height: 40px;
    border: none;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.9);
    color: #333;
    cursor: pointer;
    font-size: 20px;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.2s ease;
}

.image-modal-close:hover {
    background: white;
    transform: rotate(90deg);
}

/* 移动端适配 */
@media (max-width: 768px) {
    .param-options-content {
        max-height: 250px;
        min-width: 200px;
        box-shadow: 0 6px 16px rgba(0, 0, 0, 0.2);
    }

    .param-option-item {
        padding: 14px 16px;
        font-size: 15px;
        min-height: 48px;
        display: flex;
        align-items: center;
    }

    .param-option-item:active {
        background: #d8d8d8;
    }

    .input-params li {
        width: 48%;
    }

    .response-content .image-container {
        width: 100%;
    }

    /* 移动端图片按钮始终显示 */
    .image-actions {
        opacity: 1;
    }

    .image-action-btn {
        width: 32px;
        height: 32px;
        font-size: 12px;
    }

    .image-modal-close {
        top: 10px;
        right: 10px;
    }

    .image-modal-content {
        max-width: 95%;
        max-height: 95%;
    }
}

/* 音频播放器组件样式 */
.audio-container {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 16px;
    margin: 12px 0;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    border-radius: 16px;
    box-shadow: 0 4px 15px rgba(102, 126, 234, 0.3);
    transition: all 0.3s ease;
    position: relative;
    overflow: hidden;
}

.audio-container .audio-text {
    display: none;
}

.audio-container::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: linear-gradient(135deg, rgba(255, 255, 255, 0.1) 0%, rgba(255, 255, 255, 0) 100%);
    pointer-events: none;
}

.audio-container:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(102, 126, 234, 0.4);
}

.audio-player {
    flex: 1;
    display: flex;
    align-items: center;
    gap: 12px;
    position: relative;
    z-index: 1;
}

.audio-play-btn {
    width: 48px;
    height: 48px;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.95);
    border: none;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: all 0.3s ease;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.15);
    flex-shrink: 0;
}

.audio-play-btn:hover {
    background: white;
    transform: scale(1.05);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.2);
}

.audio-play-btn:active {
    transform: scale(0.98);
}

.audio-play-btn i {
    color: #667eea;
    font-size: 20px;
    margin-left: 2px;
}

.audio-play-btn.playing i::before {
    content: '\f04c';
    margin-left: 0;
}

.audio-info {
    flex: 1;
    min-width: 0;
}

.audio-waveform {
    display: flex;
    align-items: center;
    gap: 2px;
    height: 32px;
    margin-bottom: 6px;
}

.audio-bar {
    flex: 1;
    background: rgba(255, 255, 255, 0.3);
    border-radius: 2px;
    transition: all 0.3s ease;
    position: relative;
    overflow: hidden;
}

.audio-bar::after {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: var(--progress, 0%);
    height: 100%;
    background: white;
    transition: width 0.1s linear;
}

.audio-container.playing .audio-bar {
    animation: audioWave 1.2s ease-in-out infinite;
}

.audio-container.playing .audio-bar:nth-child(even) {
    animation-delay: 0.1s;
}

.audio-container.playing .audio-bar:nth-child(3n) {
    animation-delay: 0.2s;
}

@keyframes audioWave {

    0%,
    100% {
        opacity: 0.5;
    }

    50% {
        opacity: 1;
    }
}

@keyframes audioProgress {
    from {
        width: 0%;
    }

    to {
        width: 100%;
    }
}

.audio-time {
    display: flex;
    justify-content: space-between;
    font-size: 12px;
    color: rgba(255, 255, 255, 0.9);
    font-weight: 500;
}

.audio-actions {
    display: flex;
    gap: 8px;
    position: relative;
    z-index: 1;
}

.audio-action-btn {
    width: 36px;
    height: 36px;
    border-radius: 8px;
    background: rgba(255, 255, 255, 0.2);
    border: 1px solid rgba(255, 255, 255, 0.3);
    color: white;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: all 0.3s ease;
    backdrop-filter: blur(10px);
}

.audio-action-btn:hover {
    background: rgba(255, 255, 255, 0.3);
    transform: scale(1.1);
}

.audio-action-btn:active {
    transform: scale(0.95);
}

.audio-action-btn i {
    font-size: 14px;
}

/* 隐藏原生音频控件 */
.audio-container audio {
    display: none;
}

/* 深色模式适配 */
[data-theme="dark"] .audio-container {
    background: linear-gradient(135deg, #4a5568 0%, #2d3748 100%);
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.3);
}

[data-theme="dark"] .audio-container:hover {
    box-shadow: 0 6px 20px rgba(0, 0, 0, 0.4);
}

[data-theme="dark"] .audio-play-btn {
    background: rgba(255, 255, 255, 0.15);
}

[data-theme="dark"] .audio-play-btn:hover {
    background: rgba(255, 255, 255, 0.25);
}

[data-theme="dark"] .audio-play-btn i {
    color: #90cdf4;
}

/* 响应式设计 */
@media (max-width: 768px) {
    .audio-container {
        padding: 12px;
        gap: 10px;
    }

    .audio-play-btn {
        width: 40px;
        height: 40px;
    }

    .audio-play-btn i {
        font-size: 18px;
    }

    .audio-waveform {
        height: 28px;
    }

    .audio-action-btn {
        width: 32px;
        height: 32px;
    }

    .audio-action-btn i {
        font-size: 12px;
    }
}

/* ===== 视频容器样式 ===== */
.video-container {
    margin: 16px 0;
    background: #000;
    border-radius: 16px;
    padding: 16px;
    transition: all 0.3s ease;
    position: relative;
    overflow: hidden;
    max-width: 500px;
    width: 100%;
}

.video-container::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: linear-gradient(135deg, rgba(255, 255, 255, 0.1) 0%, rgba(255, 255, 255, 0) 100%);
    pointer-events: none;
}

.video-container:hover {
    box-shadow: 0 6px 20px rgba(102, 126, 234, 0.4);
    transform: translateY(-2px);
}

.video-wrapper {
    position: relative;
    width: 100%;
    background: #000;
    border-radius: 12px;
    overflow: hidden;
    min-height: 200px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.video-element {
    width: 100%;
    height: auto;
    display: block;
    max-height: 500px;
    min-height: 200px;
    object-fit: contain;
    background: #000;
}

.video-controls {
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    background: linear-gradient(to top, rgba(0, 0, 0, 0.8) 0%, rgba(0, 0, 0, 0) 100%);
    padding: 16px;
    display: flex;
    align-items: center;
    gap: 12px;
    opacity: 0;
    transition: opacity 0.3s ease;
}

.video-wrapper:hover .video-controls,
.video-container.playing .video-controls {
    opacity: 1;
}

.video-play-btn {
    width: 48px;
    height: 48px;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.2);
    backdrop-filter: blur(10px);
    border: 2px solid rgba(255, 255, 255, 0.3);
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: all 0.3s ease;
    flex-shrink: 0;
}

.video-play-btn:hover {
    background: rgba(255, 255, 255, 0.3);
    transform: scale(1.1);
    border-color: rgba(255, 255, 255, 0.5);
}

.video-play-btn i {
    color: white;
    font-size: 20px;
    transition: all 0.3s ease;
}

.video-play-btn.playing i {
    animation: pulse 1.5s ease-in-out infinite;
}

.video-progress-container {
    flex: 1;
    display: flex;
    flex-direction: column;
    gap: 6px;
}

.video-progress-bar {
    width: 100%;
    height: 6px;
    background: rgba(255, 255, 255, 0.2);
    border-radius: 3px;
    cursor: pointer;
    position: relative;
    overflow: hidden;
}

.video-progress-filled {
    height: 100%;
    background: linear-gradient(90deg, #667eea 0%, #764ba2 100%);
    border-radius: 3px;
    width: 0%;
    transition: width 0.1s linear;
}

.video-time {
    display: flex;
    justify-content: space-between;
    color: white;
    font-size: 12px;
    font-family: 'Courier New', monospace;
}

.video-volume-btn,
.video-fullscreen-btn {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.2);
    backdrop-filter: blur(10px);
    border: none;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: all 0.3s ease;
    flex-shrink: 0;
}

.video-volume-btn:hover,
.video-fullscreen-btn:hover {
    background: rgba(255, 255, 255, 0.3);
    transform: scale(1.1);
}

.video-volume-btn i,
.video-fullscreen-btn i {
    color: white;
    font-size: 16px;
}

.video-actions {
    display: flex;
    justify-content: flex-end;
    gap: 8px;
    margin-top: 12px;
}

.video-action-btn {
    width: 36px;
    height: 36px;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.15);
    backdrop-filter: blur(10px);
    border: none;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: all 0.3s ease;
}

.video-action-btn:hover {
    background: rgba(255, 255, 255, 0.25);
    transform: scale(1.1);
}

.video-action-btn i {
    color: white;
    font-size: 14px;
}

/* 深色模式适配 */
[data-theme="dark"] .video-container {
    background: linear-gradient(135deg, #4a5568 0%, #2d3748 100%);
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.3);
}

[data-theme="dark"] .video-container:hover {
    box-shadow: 0 6px 20px rgba(0, 0, 0, 0.4);
}

/* 响应式设计 */
@media (max-width: 768px) {
    .video-container {
        padding: 12px;
    }

    .video-element {
        max-height: 300px;
    }

    .video-play-btn {
        width: 40px;
        height: 40px;
    }

    .video-play-btn i {
        font-size: 18px;
    }

    .video-controls {
        padding: 12px;
        gap: 8px;
    }

    .video-volume-btn,
    .video-fullscreen-btn {
        width: 36px;
        height: 36px;
    }

    .video-volume-btn i,
    .video-fullscreen-btn i {
        font-size: 14px;
    }

    .video-action-btn {
        width: 32px;
        height: 32px;
    }

    .video-action-btn i {
        font-size: 12px;
    }
}

/* Image Upload Preview Styles */
.image-preview-container {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    padding: 10px 0;
    margin-bottom: 10px;
}

.image-preview-item {
    position: relative;
    width: 80px;
    height: 80px;
    border-radius: 8px;
    overflow: hidden;
    border: 2px solid #e0e0e0;
    transition: all 0.3s ease;
}

.image-preview-item:hover {
    border-color: #3773ff;
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(55, 115, 255, 0.2);
}

.image-preview-item img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.image-preview-delete {
    position: absolute;
    top: 2px;
    right: 2px;
    background: rgba(255, 68, 68, 0.9);
    border: none;
    color: white;
    width: 20px;
    height: 20px;
    border-radius: 50%;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.3s ease;
    z-index: 10;
}

.image-preview-delete:hover {
    background: #cc0000;
    transform: scale(1.15);
}

.image-preview-delete i {
    font-size: 10px;
}

.image-preview-name {
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    background: rgba(0, 0, 0, 0.7);
    color: white;
    font-size: 10px;
    padding: 4px;
    text-align: center;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.fa-image {
    cursor: pointer;
    transition: all 0.3s ease;
}

.fa-image:hover {
    color: #3773ff;
    transform: scale(1.1);
}

@media (max-width: 768px) {
    .image-preview-item {
        width: 60px;
        height: 60px;
    }
    
    .image-preview-delete {
        width: 18px;
        height: 18px;
    }
    
    .image-preview-delete i {
        font-size: 9px;
    }
}