/* ============ DES加密解密 - 容器 ============ */
#des-encrypt-container {
    margin-bottom: 15px;
}

/* ============ 左右两栏布局 ============ */
#des-encrypt-container > .section-row {
    display: flex;
    gap: 15px;
    margin-bottom: 15px;
}

#des-encrypt-container > .section-row > .settings-card,
#des-encrypt-container > .section-row > .preview-card {
    flex: 1;
    margin-top: 0;
    margin-bottom: 0;
}

/* ============ Tab 按钮增强 ============ */
#des-encrypt-container .tabs {
    margin-bottom: 20px;
    flex-wrap: wrap;
}

#des-encrypt-container .tab-item {
    white-space: nowrap;
    font-size: 13px;
    padding: 12px 16px;
}

/* ============ 配置项横排 ============ */
.config-row {
    display: flex;
    gap: 12px;
    margin-bottom: 15px;
}

.config-col {
    flex: 1;
    min-width: 0;
}

.config-col .form-select {
    width: 100%;
}

/* ============ 输入框+按钮并排 ============ */
.input-with-btn {
    display: flex;
    gap: 10px;
    align-items: center;
}

.input-with-btn .form-input {
    flex: 1;
}

.input-with-btn .btn-sm {
    flex-shrink: 0;
}

/* ============ 密钥/结果展示列表 ============ */
.id-list {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.id-item {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 8px;
    padding: 12px 15px;
    background: #f9fafb;
    border: 2px solid #e5e7eb;
    border-radius: 8px;
    cursor: pointer;
    transition: all 0.2s;
}

.id-item:hover {
    background: #f3f4f6;
    border-color: #8b5cf6;
}

.id-label {
    font-size: 12px;
    color: #6b7280;
    font-weight: 500;
    flex-shrink: 0;
    min-width: 70px;
    text-align: left;
}

.id-text {
    font-family: 'Consolas', 'Monaco', monospace;
    font-size: 13px;
    color: #1f2937;
    word-break: break-all;
    flex: 1;
    overflow: hidden;
    max-height: 4.8em;
    line-height: 1.6;
    display: -webkit-box;
    -webkit-line-clamp: 3;
    -webkit-box-orient: vertical;
}

.id-text:hover {
    max-height: none;
    -webkit-line-clamp: unset;
}

/* ============ 输出结果卡片 ============ */
#des-encrypt-container + .settings-card {
    margin-top: 15px;
}

/* ============ 功能说明信息区 ============ */
#app > .info-section {
    margin-top: 20px;
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 16px;
}

/* ============ 响应式 ============ */
@media (max-width: 768px) {
    #des-encrypt-container > .section-row {
        flex-direction: column;
        gap: 12px;
    }

    .config-row {
        flex-wrap: wrap;
    }

    .config-col {
        flex: 1 1 120px;
    }

    .input-with-btn {
        flex-direction: column;
    }

    .input-with-btn .btn-sm {
        width: 100%;
    }

    .id-text {
        max-height: none;
        -webkit-line-clamp: unset;
    }

    .id-item {
        flex-wrap: wrap;
    }

    #des-encrypt-container .tabs {
        gap: 4px;
    }

    #des-encrypt-container .tab-item {
        font-size: 12px;
        padding: 10px 12px;
    }

    #app > .info-section {
        grid-template-columns: 1fr;
    }
}

@media (max-width: 480px) {
    .id-item {
        flex-direction: column;
        align-items: flex-start;
        gap: 6px;
    }

    .id-label {
        min-width: auto;
    }

    .id-text {
        width: 100%;
    }
}