/* 基础样式 */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    font-family: 'Segoe UI', 'Microsoft YaHei', sans-serif;
}

body {
    background: linear-gradient(135deg, #f5f7fa 0%, #c3cfe2 100%);
    color: #333;
    line-height: 1.6;
    min-height: 100vh;
    padding: 20px;
}

.container {
    max-width: 1200px;
    margin: 0 auto;
    background-color: white;
    border-radius: 20px;
    box-shadow: 0 15px 35px rgba(0, 0, 0, 0.1);
    overflow: hidden;
}

/* 头部样式 */
header {
    background: linear-gradient(135deg, #6a11cb 0%, #2575fc 100%);
    color: white;
    padding: 30px 40px;
    text-align: center;
}

.logo {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 15px;
    margin-bottom: 10px;
}

.logo i {
    font-size: 2.5rem;
}

.logo h1 {
    font-size: 2.2rem;
    font-weight: 700;
}

.subtitle {
    font-size: 1.1rem;
    opacity: 0.9;
    max-width: 700px;
    margin: 0 auto;
}

/* 主内容区 */
main {
    padding: 40px;
}

.input-section {
    background-color: #f8f9fa;
    border-radius: 15px;
    padding: 30px;
    margin-bottom: 40px;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.05);
}

.input-group {
    margin-bottom: 25px;
}

.input-group label {
    display: block;
    font-weight: 600;
    margin-bottom: 10px;
    font-size: 1.1rem;
    color: #495057;
}

.input-group label i {
    margin-right: 8px;
    color: #6a11cb;
}

.input-with-button {
    display: flex;
    gap: 10px;
}

.input-with-button input {
    flex: 1;
    padding: 15px 20px;
    border: 2px solid #dee2e6;
    border-radius: 10px;
    font-size: 1rem;
    transition: all 0.3s ease;
}

.input-with-button input:focus {
    outline: none;
    border-color: #6a11cb;
    box-shadow: 0 0 0 3px rgba(106, 17, 203, 0.1);
}

.input-with-button input#converted-url {
    background-color: #e9ecef;
    color: #495057;
}

button {
    padding: 15px 25px;
    border: none;
    border-radius: 10px;
    font-weight: 600;
    cursor: pointer;
    font-size: 1rem;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
}

button:active {
    transform: translateY(2px);
}

.btn-convert {
    background: linear-gradient(135deg, #6a11cb 0%, #2575fc 100%);
    color: white;
}

.btn-convert:hover {
    opacity: 0.9;
    box-shadow: 0 5px 15px rgba(106, 17, 203, 0.3);
}

.btn-copy {
    background-color: #20c997;
    color: white;
}

.btn-copy:hover {
    background-color: #1baa7f;
    box-shadow: 0 5px 15px rgba(32, 201, 151, 0.3);
}

.btn-secondary {
    background-color: #6c757d;
    color: white;
}

.btn-secondary:hover {
    background-color: #5a6268;
    box-shadow: 0 5px 15px rgba(108, 117, 125, 0.3);
}

.action-buttons {
    display: flex;
    gap: 15px;
    margin-top: 30px;
}

/* 平台区域 */
.platform-section {
    margin-bottom: 40px;
}

.platform-section h2 {
    font-size: 1.8rem;
    margin-bottom: 20px;
    color: #343a40;
    display: flex;
    align-items: center;
    gap: 10px;
}

.platform-tabs {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    margin-bottom: 30px;
}

.platform-tab {
    padding: 10px 20px;
    background-color: #e9ecef;
    border-radius: 50px;
    font-weight: 600;
    color: #495057;
    border: 2px solid transparent;
}

.platform-tab.active {
    background-color: #6a11cb;
    color: white;
}

.platform-tab:hover:not(.active) {
    background-color: #d0d7e1;
}

.platform-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
    gap: 20px;
}

.platform-card {
    background-color: white;
    border-radius: 10px;
    padding: 20px;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.05);
    border-left: 5px solid #6a11cb;
    transition: all 0.3s ease;
}

.platform-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 10px 25px rgba(0, 0, 0, 0.1);
}

.platform-card h3 {
    font-size: 1.2rem;
    margin-bottom: 8px;
    color: #343a40;
}

.platform-card .prefix {
    display: inline-block;
    background-color: #e9ecef;
    padding: 3px 10px;
    border-radius: 20px;
    font-size: 0.85rem;
    font-weight: 600;
    color: #6a11cb;
    margin-bottom: 10px;
}

.platform-card p {
    color: #6c757d;
    font-size: 0.95rem;
    line-height: 1.5;
}

.platform-card.dev { border-left-color: #2575fc; }
.platform-card.pkg { border-left-color: #20c997; }
.platform-card.linux { border-left-color: #fd7e14; }
.platform-card.ai { border-left-color: #e83e8c; }
.platform-card.container { border-left-color: #6f42c1; }
.platform-card.other { border-left-color: #17a2b8; }

/* 使用说明 */
.instructions h2 {
    font-size: 1.8rem;
    margin-bottom: 30px;
    color: #343a40;
    display: flex;
    align-items: center;
    gap: 10px;
}

.steps {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
    gap: 25px;
}

.step {
    text-align: center;
    padding: 25px 15px;
    background-color: #f8f9fa;
    border-radius: 15px;
    transition: all 0.3s ease;
}

.step:hover {
    background-color: #e9ecef;
    transform: translateY(-5px);
}

.step-number {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 50px;
    height: 50px;
    background: linear-gradient(135deg, #6a11cb 0%, #2575fc 100%);
    color: white;
    border-radius: 50%;
    font-size: 1.5rem;
    font-weight: 700;
    margin-bottom: 15px;
}

.step h3 {
    font-size: 1.3rem;
    margin-bottom: 10px;
    color: #343a40;
}

.step p {
    color: #6c757d;
    font-size: 0.95rem;
}

/* 页脚 */
footer {
    background-color: #343a40;
    color: white;
    text-align: center;
    padding: 25px;
    border-top: 1px solid #495057;
}

footer p {
    margin-bottom: 8px;
}

.footer-note {
    font-size: 0.9rem;
    opacity: 0.7;
}

/* 模态框 */
.modal {
    display: none;
    position: fixed;
    z-index: 1000;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.5);
    animation: fadeIn 0.3s;
}

@keyframes fadeIn {
    from { opacity: 0; }
    to { opacity: 1; }
}

.modal-content {
    background-color: white;
    margin: 5% auto;
    width: 90%;
    max-width: 700px;
    border-radius: 15px;
    overflow: hidden;
    box-shadow: 0 20px 50px rgba(0, 0, 0, 0.2);
    animation: slideIn 0.3s;
}

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

.modal-header {
    background: linear-gradient(135deg, #6a11cb 0%, #2575fc 100%);
    color: white;
    padding: 20px 30px;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.modal-header h2 {
    font-size: 1.5rem;
    display: flex;
    align-items: center;
    gap: 10px;
}

.close-modal {
    font-size: 2rem;
    cursor: pointer;
    transition: transform 0.2s;
}

.close-modal:hover {
    transform: scale(1.2);
}

.modal-body {
    padding: 30px;
    max-height: 60vh;
    overflow-y: auto;
}

.example-category {
    margin-bottom: 25px;
    padding-bottom: 25px;
    border-bottom: 1px solid #e9ecef;
}

.example-category:last-child {
    margin-bottom: 0;
    padding-bottom: 0;
    border-bottom: none;
}

.example-category h3 {
    color: #6a11cb;
    margin-bottom: 15px;
    font-size: 1.3rem;
}

.example-category p {
    margin-bottom: 8px;
    line-height: 1.6;
}

/* 通知 */
.notification {
    position: fixed;
    bottom: 30px;
    right: 30px;
    background-color: #20c997;
    color: white;
    padding: 15px 25px;
    border-radius: 10px;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.2);
    display: none;
    z-index: 1001;
    animation: slideUp 0.3s;
}

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

/* 响应式设计 */
@media (max-width: 768px) {
    .container {
        border-radius: 15px;
    }
    
    header {
        padding: 20px;
    }
    
    .logo h1 {
        font-size: 1.8rem;
    }
    
    main {
        padding: 20px;
    }
    
    .input-section {
        padding: 20px;
    }
    
    .input-with-button {
        flex-direction: column;
    }
    
    button {
        width: 100%;
        justify-content: center;
    }
    
    .platform-grid {
        grid-template-columns: 1fr;
    }
    
    .platform-tabs {
        justify-content: center;
    }
    
    .steps {
        grid-template-columns: 1fr;
    }
    
    .modal-content {
        width: 95%;
        margin: 10% auto;
    }
}

@media (max-width: 480px) {
    body {
        padding: 10px;
    }
    
    .logo {
        flex-direction: column;
        gap: 10px;
    }
    
    .logo h1 {
        font-size: 1.5rem;
    }
    
    .platform-tabs {
        flex-direction: column;
    }
    
    .platform-tab {
        text-align: center;
    }
    
    .notification {
        left: 10px;
        right: 10px;
        bottom: 10px;
    }
}
