/* 基础样式 */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Helvetica Neue', Arial, sans-serif;
    background-color: #f5f7fa;
    color: #333;
    line-height: 1.6;
}

/* 主容器 */
.minimal-container {
	max-width: 1200px;
	width: 100%;
	box-sizing: border-box;
	margin-top: 0;
	margin-right: auto;
	margin-bottom: 0;
	margin-left: auto;
	padding-top: 40px;
	padding-right: 20px;
	padding-bottom: 40px;
	padding-left: 20px;
}

/* 标题区域 */
.minimal-header {
    text-align: center;
    margin-bottom: 40px;
    padding-bottom: 20px;
    border-bottom: 1px solid #e0e0e0;
	
}

.minimal-title {
	font-size: 36px;
    font-weight: 300;
    color: #222;
    margin-bottom: 8px;
}

.minimal-subtitle {
    font-size: 16px;
    color: #666;
}

/* 按钮组 */
.upload-instruction-section {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 30px;
    padding: 20px;
    background: #e7e7e7;
    border-radius: 8px;
}

.section-text h3 {
    color: #333;
    font-size: 18px;
}

.section-text p {
    margin: 0;
    color: #666;
    font-size: 14px;
}

.btn-group {
    display: flex;
    gap: 10px;
    flex-wrap: wrap;
    justify-content: flex-end;
}

/* 按钮样式 */
.minimal-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 10px 20px;
    font-size: 14px;
    font-weight: 500;
    color: #333;
    background-color: white;
    border: 1px solid #ddd;
    border-radius: 4px;
    cursor: pointer;
    transition: all 0.3s ease;
    text-decoration: none;
    white-space: nowrap;
}

.minimal-btn:hover {
    background-color: #f8f9fa;
    border-color: #ccc;
}

.minimal-btn.primary {
    background-color: #2196F3;
    color: white;
    border-color: #2196F3;
}

.minimal-btn.primary:hover {
    background-color: #1976D2;
    border-color: #1976D2;
}

/* 黑色背景按钮 */
.minimal-btn.black {
    background-color: #333;
    color: white;
    border-color: #333;
}

.minimal-btn.black:hover {
    background-color: #222;
    border-color: #222;
}

.minimal-btn.btn-disabled {
    background-color: #e0e0e0 !important;
    color: #9e9e9e !important;
    border-color: #e0e0e0 !important;
    cursor: not-allowed !important;
}

.minimal-btn.btn-disabled:hover {
    background-color: #e0e0e0 !important;
    border-color: #e0e0e0 !important;
}

.minimal-btn.btn-logged-in {
    background-color: #f44336 !important;
    color: white !important;
    border-color: #f44336 !important;
}

.minimal-btn.btn-logged-in:hover {
    background-color: #d32f2f !important;
    border-color: #d32f2f !important;
}

/* 登录/退出按钮容器 */
.login-logout-container {
    display: inline-flex;
    align-items: center;
}

/* 步骤容器 */
.step-container {
    background: white;
    border-radius: 8px;
    padding: 30px;
    margin-bottom: 30px;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
}

.step-header {
    display: flex;
    align-items: center;
    margin-bottom: 25px;
}

.step-number {
    width: 32px;
    height: 32px;
    background-color: #222;
    color: white;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 16px;
    font-weight: 600;
    margin-right: 12px;
}

.step-title {
    font-size: 20px;
    font-weight: 600;
    color: #333;
}

/* 姓名选择区域 */
.name-selection-container {
    margin-top: 20px;
}

.name-buttons-grid {
	display: flex;
    flex-wrap: wrap;
    gap: 12px;
    max-height: 320px;
    overflow-y: auto;
    padding: 5px;
}

.name-btn {
	background: #f8f9fa;
	border: 1px solid #e0e0e0;
	border-radius: 4px;
	text-align: center;
	cursor: pointer;
	transition: all 0.3s ease;
	font-size: 14px;
	padding-top: 12px;
	padding-right: 20px;
	padding-bottom: 12px;
	padding-left: 20px;
}

.name-btn:hover {
    background: #e9ecef;
    border-color: #ccc;
}

.name-btn.active {
    background-color: #2196F3;
    color: white;
    border-color: #2196F3;
}

.empty-message {
    text-align: center;
    padding: 40px 20px;
    color: #999;
    font-size: 16px;
    grid-column: 1 / -1;
}

/* 二维码选择容器 */
.qrcode-selection-container {
    background: white;
    border-radius: 8px;
    padding: 30px;
    margin-bottom: 30px;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
    width: 100%;
    max-width: 1200px;
    margin-left: auto;
    margin-right: auto;
}

/* 选择头部样式 */
.selection-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-top: 20px;
    padding: 15px 0;
    border-bottom: 1px solid #e0e0e0;
    width: 100%;
    flex-wrap: wrap;
    gap: 10px;
}

.selected-info {
    font-size: 14px;
    color: #666;
}

.selected-info .selected-name {
    font-weight: 600;
    color: #333;
}

.selected-info .selected-name.status-empty {
    color: #999;
    font-style: italic;
    font-weight: normal;
}

.action-buttons {
    display: flex;
    gap: 10px;
}

/* 二维码网格布局 */
.qrcode-grid.six-columns {
    display: grid;
    grid-template-columns: repeat(6, 1fr);
    gap: 15px;
    margin-top: 20px;
    width: 100%;
}

/* 二维码项目样式 */
.qrcode-item {
	background: white;
	padding: 12px;
	transition: all 0.3s ease;
	display: flex;
	flex-direction: column;
	align-items: center;
	text-align: center;
	border: 1px solid #CCCCCC;
	box-sizing: border-box;
	overflow: hidden;
	height: auto;
	min-height: 280px;
}

.qrcode-item.selected {
    border-color: #2196F3;
    background-color: #f5faff;
    box-shadow: 0 4px 12px rgba(33, 150, 243, 0.2);
}

/* 二维码标题样式 */
.qrcode-title {
    font-size: 14px;
    color: #333;
    margin: 0 0 10px 0;
    padding: 0;
    text-align: center;
    width: 100%;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

/* 二维码图片容器 */
.qrcode-img-container {
	width: auto;
	height: 140px;
	display: flex;
	align-items: center;
	justify-content: center;
	background: #f8f9fa;
	padding: 8px;
	overflow: hidden;
	flex-shrink: 0;
	margin-top: 0;
	margin-right: auto;
	margin-bottom: 12px;
	margin-left: auto;
}

.qrcode-img {
    max-width: 100%;
    max-height: 100%;
    object-fit: contain;
}

/* 二维码操作按钮区域 */
.qrcode-actions {
    display: flex;
    gap: 8px;
    margin-bottom: 12px;
    width: 100%;
    justify-content: center;
    flex-wrap: nowrap;
}

.qrcode-actions .minimal-btn {
    padding: 6px 12px;
    font-size: 13px;
    min-width: 70px;
    flex: 1;
    max-width: 80px;
}

/* 默认选择按钮样式（与下载按钮相同） */
.qrcode-actions .btn-select {
    background-color: #e0e0e0;
    color: #333;
    border-color: #e0e0e0;
}

.qrcode-actions .btn-select:hover {
    background-color: #d5d5d5;
    border-color: #d5d5d5;
}

/* 选中后的选择按钮样式 */
.qrcode-actions .btn-select.selected {
    background-color: #2196F3;
    color: white;
    border-color: #2196F3;
}

.qrcode-actions .btn-select.selected:hover {
    background-color: #1976D2;
    border-color: #1976D2;
}

/* 二维码描述 */
.qrcode-description {
    font-size: 13px;
    color: #666;
    margin: 0;
    line-height: 1.4;
    text-align: center;
    width: 100%;
    word-break: break-word;
    display: -webkit-box;
    -webkit-line-clamp: 3;
    -webkit-box-orient: vertical;
    overflow: hidden;
    text-overflow: ellipsis;
    flex-grow: 1;
    min-height: 36px;
}

/* 海报选择容器 */
.poster-selection-container {
    background: white;
    border-radius: 8px;
    padding: 30px;
    margin-bottom: 30px;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
}

.poster-controls {
    display: flex;
    align-items: center;
    gap: 15px;
    flex-wrap: wrap;
    margin-bottom: 30px;
}

.minimal-select {
    width: 100%;
    padding: 10px 12px;
    border: 1px solid #ddd;
    border-radius: 4px;
    font-size: 14px;
    background-color: white;
    color: #333;
    cursor: pointer;
}

.minimal-select:focus {
    outline: none;
    border-color: #2196F3;
}

.poster-preview {
    min-height: 300px;
    border: 1px dashed #ddd;
    border-radius: 4px;
    display: flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 20px;
    background-color: #f8f9fa;
}

.poster-actions {
    display: flex;
    gap: 10px;
    justify-content: flex-end;
}

/* 模态框样式 */
.modal-overlay {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.5);
    z-index: 1000;
    align-items: center;
    justify-content: center;
    opacity: 0;
    transition: opacity 0.3s ease;
}

.modal-overlay.active {
    opacity: 1;
}

.modal-container {
    background: white;
    border-radius: 8px;
    width: 90%;
    max-width: 600px;
    max-height: 80vh;
    overflow-y: auto;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.2);
    animation: modalAppear 0.3s ease;
}

@keyframes modalAppear {
    from {
        opacity: 0;
        transform: translateY(-20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.modal-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 20px;
    border-bottom: 1px solid #e0e0e0;
}

.modal-title {
    font-size: 18px;
    font-weight: 500;
    color: #333;
    margin: 0;
}

.modal-close-btn {
    background: none;
    border: none;
    font-size: 24px;
    color: #999;
    cursor: pointer;
    width: 30px;
    height: 30px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
}

.modal-close-btn:hover {
    background-color: #f5f5f5;
    color: #666;
}

.modal-content {
    padding: 20px;
}

/* 表单样式 */
.form-group {
    margin-bottom: 20px;
}

.form-group label {
    display: block;
    margin-bottom: 6px;
    font-weight: 500;
    color: #333;
    font-size: 14px;
}

.form-group input,
.form-group textarea,
.form-group select {
    width: 100%;
    padding: 10px 12px;
    border: 1px solid #ddd;
    border-radius: 4px;
    font-size: 14px;
    transition: border-color 0.3s;
    box-sizing: border-box;
}

.form-group input:focus,
.form-group textarea:focus,
.form-group select:focus {
    outline: none;
    border-color: #2196F3;
}

.form-group textarea {
    resize: vertical;
    min-height: 80px;
}

.help-text {
    font-size: 12px;
    color: #999;
    margin-top: 4px;
}

.form-actions {
    display: flex;
    gap: 10px;
    justify-content: flex-end;
    margin-top: 20px;
}

/* 使用说明列表 */
.instruction-list {
    padding-left: 20px;
}

.instruction-list li {
    margin-bottom: 10px;
    color: #333;
}

/* 管理列表 */
.manage-list {
    max-height: 400px;
    overflow-y: auto;
}

.person-item {
    padding: 15px;
    border: 1px solid #e0e0e0;
    border-radius: 4px;
    margin-bottom: 15px;
    background-color: #f8f9fa;
}

.qrcodes-list {
    margin-top: 10px;
    max-height: 200px;
    overflow-y: auto;
}

/* 登录模态框样式 */
#login-modal .modal-container {
    max-width: 400px;
    width: 90%;
}

#login-message {
    margin-top: 15px;
    padding: 8px 12px;
    border-radius: 4px;
    font-size: 14px;
    text-align: center;
}

.login-success {
    background-color: #e8f5e9;
    color: #2e7d32;
    border: 1px solid #c8e6c9;
}

.login-error {
    background-color: #ffebee;
    color: #c62828;
    border: 1px solid #ffcdd2;
}

/* 加载动画 */
.spinner {
    display: inline-block;
    width: 20px;
    height: 20px;
    border: 2px solid rgba(0, 0, 0, 0.1);
    border-radius: 50%;
    border-top-color: #2196F3;
    animation: spin 1s ease-in-out infinite;
    margin-left: 10px;
}

@keyframes spin {
    to { transform: rotate(360deg); }
}

/* 响应式调整 */
@media (max-width: 1200px) {
    .qrcode-grid.six-columns {
        grid-template-columns: repeat(5, 1fr);
    }
    
    .qrcode-item {
        padding: 10px;
    }
    
    .qrcode-img-container {
        width: 110px;
        height: 110px;
    }
}

@media (max-width: 992px) {
    .qrcode-grid.six-columns {
        grid-template-columns: repeat(4, 1fr);
    }
}

@media (max-width: 768px) {
    .qrcode-grid.six-columns {
        grid-template-columns: repeat(3, 1fr);
    }
    
    .qrcode-img-container {
        width: 100px;
        height: 100px;
    }
    
    .qrcode-actions .minimal-btn {
        padding: 5px 10px;
        font-size: 12px;
        min-width: 65px;
    }
    
    .qrcode-description {
        font-size: 12px;
        -webkit-line-clamp: 3;
    }
    
    .upload-instruction-section {
        flex-direction: column;
        align-items: flex-start;
        gap: 15px;
    }
    
    .btn-group {
        width: 100%;
        justify-content: flex-start;
    }
	.minimal-title {
	font-size: 24px;
    font-weight: 300;
    color: #222;
    margin-bottom: 8px;
}
}

@media (max-width: 576px) {
    .qrcode-grid.six-columns {
        grid-template-columns: repeat(2, 1fr);
    }
    
    .qrcode-img-container {
        width: 90px;
        height: 90px;
    }
    
    .qrcode-item {
        min-height: 250px;
    }
    
    .qrcode-actions .minimal-btn {
        padding: 4px 8px;
        font-size: 12px;
        min-width: 60px;
    }
    
    .minimal-container {
        padding-top: 40px;
		padding-bottom: 40px;
    }
    
    .step-container,
    .qrcode-selection-container,
    .poster-selection-container {
        padding: 20px;
    }
}

@media (max-width: 375px) {
    .qrcode-grid.six-columns {
        grid-template-columns: repeat(1, 1fr);
        gap: 12px;
    }
    
    .qrcode-img-container {
        width: 100px;
        height: 100px;
    }
    
    .qrcode-item {
        min-height: 240px;
    }
}


/* 在响应式调整部分添加以下代码 */

@media (max-width: 768px) {
    /* 手机端按钮组调整 */
    .upload-instruction-section {
        flex-direction: column;
        align-items: stretch;
        gap: 15px;
    }
    
    .btn-group {
        width: 100%;
        display: flex;
        flex-direction: column;
        gap: 12px;
    }
    
    /* 手机端按钮统一样式 */
    .minimal-btn {
        width: 100%;
        justify-content: center;
        padding: 14px 20px;
        font-size: 16px;
        text-align: center;
        white-space: nowrap;
    }
    
    /* 登录/退出容器调整 */
    .login-logout-container {
        display: flex;
        width: 100%;
    }
    
    .login-logout-container .minimal-btn {
        width: 100%;
    }
    
    /* 按钮图标调整 */
    .minimal-btn .material-icons {
        font-size: 20px;
        margin-right: 10px;
    }
    
    /* 主标题调整 */
    .minimal-title {
        font-size: 24px;
        font-weight: 600;
    }
    
    .minimal-subtitle {
        font-size: 14px;
    }
    
    /* 步骤容器调整 */
    .step-container,
    .qrcode-selection-container,
    .poster-selection-container {
        padding: 20px;
    }
    
    /* 二维码网格调整为2列 */
    .qrcode-grid.six-columns {
        grid-template-columns: repeat(2, 1fr);
        gap: 12px;
    }
    
    .qrcode-item {
        min-height: 260px;
        padding: 12px;
    }
    
    .qrcode-img-container {
        width: 100px;
        height: 100px;
    }
    
    .qrcode-actions {
        flex-wrap: wrap;
    }
    
    .qrcode-actions .minimal-btn {
        padding: 8px 12px;
        font-size: 14px;
        min-width: auto;
        flex: 1;
    }
    
    /* 海报控制区域调整 */
    .poster-controls {
        flex-direction: column;
        align-items: stretch;
        gap: 12px;
    }
    
    .poster-controls > div {
        width: 100%;
    }
    
    .poster-controls select,
    .poster-controls .minimal-btn {
        width: 100%;
        padding: 14px;
    }
}

@media (max-width: 576px) {
    /* 在小屏幕手机上进一步调整 */
  
    .qrcode-grid.six-columns {
        grid-template-columns: 1fr;
        gap: 10px;
    }
    
    .qrcode-item {
        min-height: 240px;
    }
    
    .qrcode-img-container {
        width: 120px;
        height: 120px;
    }
    
    /* 选择头部调整 */
    .selection-header {
        flex-direction: column;
        align-items: flex-start;
        gap: 10px;
    }
    
    .action-buttons {
        width: 100%;
    }
    
    .action-buttons .minimal-btn {
        width: 100%;
    }
    
    /* 海报操作按钮调整 */
    .poster-actions {
        flex-direction: column;
        gap: 10px;
    }
    
    .poster-actions .minimal-btn {
        width: 100%;
        padding: 14px;
    }
}

@media (max-width: 375px) {
    /* 在非常小的屏幕上 */
    .minimal-title {
        font-size: 22px;
    }
    
    .step-title {
        font-size: 18px;
    }
    
    .minimal-btn {
        padding: 12px 16px;
        font-size: 15px;
    }
    
    .qrcode-img-container {
        width: 100px;
        height: 100px;
    }
}

/* --- 使用说明模态框美化 (时间轴风格) --- */

.instruction-timeline {
    padding: 10px 10px 10px 20px;
    position: relative;
}

/* 左侧连接线 */
.instruction-timeline::before {
    content: '';
    position: absolute;
    top: 15px;
    bottom: 30px;
    left: 34px; /* 根据圆圈大小调整 */
    width: 2px;
    background: #e0e0e0;
    z-index: 0;
}

.timeline-item {
    position: relative;
    margin-bottom: 30px;
    padding-left: 45px;
    z-index: 1;
}

.timeline-item:last-child {
    margin-bottom: 0;
}

/* 圆形数字标记 */
.timeline-marker {
    position: absolute;
    left: 0;
    top: 0;
    width: 30px;
    height: 30px;
    background-color: #2196F3;
    color: white;
    border-radius: 50%;
    text-align: center;
    line-height: 30px;
    font-weight: 600;
    font-size: 14px;
    box-shadow: 0 0 0 4px #e3f2fd; /* 外部光晕效果 */
}

/* 内容区域 */
.timeline-content h4 {
    margin: 0 0 8px 0;
    font-size: 16px;
    color: #333;
    font-weight: 600;
}

.timeline-content p {
    margin: 0;
    font-size: 14px;
    color: #666;
    line-height: 1.6;
    text-align: justify;
}

/* 子列表样式 (用于阶段二) */
.sub-list {
    margin: 8px 0 0 0;
    padding-left: 0;
    list-style: none;
}

.sub-list li {
    font-size: 13px;
    color: #555;
    margin-bottom: 4px;
    position: relative;
    padding-left: 12px;
}

.sub-list li::before {
    content: "•";
    color: #2196F3;
    position: absolute;
    left: 0;
    font-weight: bold;
}

/* 移动端适配 */
@media (max-width: 576px) {
    .instruction-timeline {
        padding-left: 10px;
    }
    .instruction-timeline::before {
        left: 24px;
    }
    .timeline-marker {
        width: 24px;
        height: 24px;
        line-height: 24px;
        font-size: 12px;
    }
    .timeline-item {
        padding-left: 35px;
    }
}