/* style.css */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    font-family: system-ui, 'Segoe UI', 'Roboto', 'Helvetica Neue', sans-serif;
}

body {
    background: #f8f9fa;
    
    padding: 2rem 1.5rem;
    display: flex;
    justify-content: center;
    align-items: center;
}
.navbar {
    height: 80px !important;
}

/* 主容器卡片 */
.container1 {
    max-width: 1400px;
    width: 100%;
    background: rgba(255,255,255,0.96);
    backdrop-filter: blur(0px);
    border-radius: 2.5rem;
    box-shadow: 0 5px 15px 2px rgba(0, 0, 0, 0.1), 0 1px 2px rgba(0, 0, 0, 0.05);
    overflow: hidden;
    transition: all 0.2s ease;
	margin-top:60px;
}

/* 头部简介区域 - 使用主题色 */
.hero {
    
    border-bottom: 1px solid #eef2f6;
    padding: 1.8rem 2rem;
}

.hero h1 {
    
    font-size: 2rem;
    font-weight: 700;
    margin: 0 0 0.5rem 0;
    background: linear-gradient(135deg, #667eea, #764ba2);
    -webkit-background-clip: text;
    background-clip: text;
    color: #333;
    text-align: center;


}

.hero h1 small {
    font-size: 0.85rem;
    background: #f0f6ff;
    padding: 4px 12px;
    border-radius: 40px;
    font-weight: normal;
	color: #6b7280;
}

.hero p {
   text-align: center;
    color: #6b7280;
    margin-bottom: 2rem;
    font-size: 0.95rem;

}

.badge-info {
    background: rgba(255,255,255,0.15);
    border-radius: 20px;
    padding: 4px 12px;
    font-size: 0.75rem;
    font-family: monospace;
    display: inline-block;
    margin-top: 10px;
}

/* 两列布局 */
.main-grid {
    display: grid;
    grid-template-columns: 1fr 1.2fr;
    gap: 1.8rem;
    padding: 2rem;
}

/* 左侧上传区 和 预览区 */
.upload-section {
    background: #ffffff;
    border-radius: 1.8rem;
    box-shadow: 0 8px 20px rgba(13,110,253,0.08);
    padding: 1.2rem;
}

.drop-zone {
    border: 2px dashed #b8d4ff;
    border-radius: 1.8rem;
    background: #f8fcff;
    transition: all 0.25s ease;
    text-align: center;
    padding: 2.5rem 1rem;
    cursor: pointer;
    margin-bottom: 1.8rem;
    position: relative;
}

.drop-zone.drag-over {
    border-color: #0D6EFD;
    background: #e8f1fe;
    transform: scale(0.99);
}

.drop-zone-icon {
    font-size: 3.2rem;
    margin-bottom: 12px;
    opacity: 0.7;
}

.drop-zone p {
    color: #1a3a5c;
    font-weight: 500;
}

.drop-zone .hint {
    font-size: 0.8rem;
    color: #6c8db0;
    margin-top: 10px;
}

.file-input-hidden {
    display: none;
}

.preview-card {
    background: #fff;
    border-radius: 1.5rem;
    padding: 1rem;
    box-shadow: 0 2px 8px rgba(13,110,253,0.06);
    border: 1px solid #e0edff;
}

.preview-title {
    font-weight: 600;
    margin-bottom: 12px;
    font-size: 1rem;
    color: #1e3a5f;
    display: flex;
    align-items: center;
    gap: 8px;
    border-left: 4px solid #0D6EFD;
    padding-left: 12px;
}

.image-preview-box {
    background: #f5f9ff;
    border-radius: 1.2rem;
    display: flex;
    justify-content: center;
    align-items: center;
    min-height: 180px;
    padding: 20px;
    margin-top: 8px;
}

.preview-img {
    max-width: 100%;
    max-height: 220px;
    object-fit: contain;
    border-radius: 16px;
    box-shadow: 0 4px 12px rgba(13,110,253,0.12);
}

.img-placeholder {
    color: #8aa7c4;
    text-align: center;
    font-size: 0.9rem;
}

/* 右侧编码结果区域 */
.result-section {
    background: #ffffff;
    border-radius: 1.8rem;
    box-shadow: 0 8px 20px rgba(13,110,253,0.08);
    padding: 1.2rem;
    display: flex;
    flex-direction: column;
    gap: 1.5rem;
}

.code-block {
    background: #0a192f;
    border-radius: 1.2rem;
    overflow: hidden;
    box-shadow: 0 4px 10px rgba(0,0,0,0.1);
}

.code-header {
    background: #0f2a44;
    padding: 0.6rem 1rem;
    color: #fff;
    font-size: 1.1rem !important;
    font-weight: 500;
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
    gap: 8px;
    border-bottom: 1px solid #1e3a5f;
}
.title1{
	font-size: 1rem !important;
}

.code-header span {
    font-family: monospace;
    background: #0a192f;
    padding: 2px 8px;
    border-radius: 20px;
    font-size: 0.7rem;
}

.copy-btn {
    background: #0D6EFD;
    border: none;
    color: white;
    padding: 4px 12px;
    border-radius: 40px;
    font-size: 0.7rem;
    cursor: pointer;
    transition: 0.2s;
    font-weight: 500;
}

.copy-btn:hover {
    background: #0f6EFD;
	transform: scale(1.2);
}

.code-content {
    padding: 1rem;
    overflow-x: auto;
    font-family: 'SF Mono', 'Fira Code', monospace;
    font-size: 0.75rem;
    line-height: 1.5;
    color: #bdd4ff;
    background: #0a192f;
    white-space: pre-wrap;
    word-break: break-all;
    max-height: 180px;
    overflow-y: auto;
}

.full-base64-area {
    max-height: 200px;
}

.description-note {
    background: #f0f6ff;
    border-radius: 1rem;
    padding: 1rem;
    font-size: 0.8rem;
    color: #1a4972;
    border-left: 3px solid #0D6EFD;
    margin-top: 0.2rem;
	height:8rem;
	line-height:1.5rem;
}

.description-note strong {
    color: #0D6EFD;
}

hr {
    margin: 8px 0;
    border-color: #d4e4ff;
}

footer {
    margin-top: 10px;
	margin-bottom: 10px;
    text-align: center;
    font-size: 0.8rem;
    color: #9ca3af;
}










@media (max-width: 1110px) {
    
	.description-note{
		height:11rem;
	}
}

@media (max-width: 865px) {
    
	.description-note{
		height:12rem;
	}
}
@media (max-width: 822px) {
    
	.description-note{
		height:13rem;
	}
}


@media (max-width: 800px) {
    .main-grid {
        grid-template-columns: 1fr;
        gap: 1.2rem;
        padding: 1.2rem;
    }
    .hero p {
        max-width: 100%;
    }
    body {
        padding: 1rem;
    }
	.container1 {
		
		margin-top:80px !important;
	}
	.description-note{
		height:8rem;
	}
}

@media (max-width: 561px) {
    
	.description-note{
		height:9rem;
	}
}


@media (max-width: 480px) {
    
	.description-note{
		height:11rem;
	}
}

@media (max-width: 460px) {
    
	.description-note{
		height:12rem;
	}
}



button {
    background: none;
    border: none;
}
.alert-msg {
    background: #fee2e2;
    color: #b91c1c;
    padding: 8px 14px;
    border-radius: 50px;
    font-size: 0.8rem;
    margin-top: 12px;
    text-align: center;
}