/* ========== 应用管理样式 ========== */

.appinfo-container {
    padding: 24px;
}

.appinfo-toolbar {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 20px;
    padding: 16px 20px;
    background: #f8f9fa;
    border-radius: 12px;
}

.appinfo-toolbar-left {
    display: flex;
    align-items: center;
    gap: 16px;
}

.appinfo-toolbar h3 {
    font-size: 16px;
    color: #202124;
    margin: 0;
}

.appinfo-count {
    background: rgba(91, 127, 255, 0.1);
    color: var(--business-color, #5B7FFF);
    padding: 4px 12px;
    border-radius: 12px;
    font-size: 13px;
    font-weight: 500;
}

.appinfo-list {
    background: white;
    border-radius: 12px;
    border: 1px solid #e8eaed;
}

.appinfo-item {
    display: flex;
    align-items: center;
    padding: 16px 20px;
    border-bottom: 1px solid #f1f3f4;
    transition: background 0.15s;
}

.appinfo-item:hover {
    background: #f8f9fa;
}

.appinfo-item:last-child {
    border-bottom: none;
}

.appinfo-item-cover {
    width: 80px;
    height: 60px;
    border-radius: 6px;
    overflow: hidden;
    background: #f1f3f4;
    flex-shrink: 0;
    margin-right: 16px;
    cursor: pointer;
}

.appinfo-item-cover img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.appinfo-item-cover-empty {
    width: 100%;
    height: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #9aa0a6;
    font-size: 11px;
}

.appinfo-item-info {
    flex: 1;
    min-width: 0;
}

.appinfo-item-name {
    font-size: 15px;
    font-weight: 600;
    color: #202124;
    margin-bottom: 4px;
}

.appinfo-item-meta {
    font-size: 12px;
    color: #9aa0a6;
}

.appinfo-item-actions {
    display: flex;
    gap: 8px;
    flex-shrink: 0;
}

.appinfo-empty {
    text-align: center;
    padding: 60px 20px;
    color: #9aa0a6;
}

/* 编辑弹窗样式 */
.appinfo-modal {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.5);
    z-index: 3000;
    justify-content: center;
    align-items: center;
}

.appinfo-modal.active {
    display: flex;
}

.appinfo-modal-content {
    background: white;
    border-radius: 16px;
    width: 90%;
    max-width: 600px;
    max-height: 85vh;
    overflow: hidden;
    display: flex;
    flex-direction: column;
    box-shadow: 0 24px 48px rgba(0, 0, 0, 0.2);
}

.appinfo-modal-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 20px 24px;
    border-bottom: 1px solid #e8eaed;
}

.appinfo-modal-title {
    font-size: 18px;
    font-weight: 600;
    color: #202124;
}

.appinfo-modal-close {
    width: 36px;
    height: 36px;
    border: none;
    background: #f1f3f4;
    border-radius: 50%;
    font-size: 20px;
    cursor: pointer;
    color: #5f6368;
    display: flex;
    align-items: center;
    justify-content: center;
}

.appinfo-modal-close:hover {
    background: #e8eaed;
}

.appinfo-modal-body {
    padding: 24px;
    overflow-y: auto;
    flex: 1;
}

.appinfo-modal-section {
    margin-bottom: 24px;
}

.appinfo-modal-section:last-child {
    margin-bottom: 0;
}

.appinfo-modal-label {
    font-size: 13px;
    font-weight: 600;
    color: #5f6368;
    margin-bottom: 8px;
    display: block;
}

.appinfo-modal-input {
    width: 100%;
    padding: 12px 14px;
    border: 1px solid #dadce0;
    border-radius: 8px;
    font-size: 14px;
    outline: none;
    transition: border-color 0.2s;
    box-sizing: border-box;
}

.appinfo-modal-input:focus {
    border-color: var(--business-color, #5B7FFF);
}

.appinfo-modal-covers {
    display: flex;
    flex-wrap: wrap;
    gap: 12px;
    margin-top: 12px;
}

.appinfo-modal-cover-item {
    position: relative;
    border-radius: 8px;
    overflow: hidden;
    border: 1px solid #e8eaed;
}

.appinfo-modal-cover-img {
    width: 120px;
    height: 90px;
    object-fit: cover;
    cursor: pointer;
}

.appinfo-modal-cover-delete {
    position: absolute;
    top: 4px;
    right: 4px;
    width: 24px;
    height: 24px;
    background: rgba(234, 67, 53, 0.9);
    color: white;
    border: none;
    border-radius: 50%;
    cursor: pointer;
    font-size: 14px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.appinfo-modal-cover-delete:hover {
    background: #ea4335;
}

.appinfo-modal-add-url {
    display: flex;
    gap: 8px;
    margin-top: 12px;
}

.appinfo-modal-add-url input {
    flex: 1;
    padding: 10px 12px;
    border: 1px solid #dadce0;
    border-radius: 6px;
    font-size: 13px;
    outline: none;
}

.appinfo-modal-add-url input:focus {
    border-color: var(--business-color, #5B7FFF);
}

.appinfo-modal-preview {
    margin-top: 12px;
    padding: 12px;
    background: #f8f9fa;
    border-radius: 8px;
    text-align: center;
}

.appinfo-modal-preview img {
    max-width: 200px;
    max-height: 150px;
    border-radius: 6px;
}

.appinfo-modal-no-cover {
    color: #9aa0a6;
    font-size: 13px;
    padding: 30px;
    text-align: center;
    background: #f8f9fa;
    border-radius: 8px;
}

/* URL文本列表样式 */
.appinfo-modal-url-list {
    margin-top: 12px;
    border: 1px solid #e8eaed;
    border-radius: 8px;
    overflow: hidden;
}

.appinfo-modal-url-item {
    display: flex;
    align-items: center;
    padding: 10px 12px;
    border-bottom: 1px solid #e8eaed;
    gap: 10px;
}

.appinfo-modal-url-item:last-child {
    border-bottom: none;
}

.appinfo-modal-url-text {
    flex: 1;
    font-size: 12px;
    color: #5f6368;
    word-break: break-all;
    font-family: monospace;
}

.appinfo-modal-url-actions {
    display: flex;
    gap: 6px;
    flex-shrink: 0;
}

.appinfo-modal-footer {
    padding: 16px 24px;
    border-top: 1px solid #e8eaed;
    display: flex;
    justify-content: flex-end;
    gap: 12px;
}

/* 图片预览弹窗 */
.image-preview-modal {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.85);
    z-index: 4000;
    justify-content: center;
    align-items: center;
}

.image-preview-modal.active {
    display: flex;
}

.image-preview-content {
    position: relative;
    max-width: 90%;
    max-height: 90%;
}

.image-preview-content img {
    max-width: 100%;
    max-height: 85vh;
    border-radius: 8px;
}

.image-preview-close {
    position: absolute;
    top: -40px;
    right: 0;
    width: 36px;
    height: 36px;
    background: white;
    border: none;
    border-radius: 50%;
    font-size: 24px;
    cursor: pointer;
    color: #5f6368;
}

.image-preview-close:hover {
    background: #f1f3f4;
}
