/** {*/
/*    margin: 0;*/
/*    padding: 0;*/
/*    box-sizing: border-box;*/
/*}*/

/*body {*/
/*    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;*/
/*    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);*/
/*    min-height: 100vh;*/
/*    padding: 20px;*/
/*}*/

/*.container {*/
/*    max-width: 1200px;*/
/*    margin: 0 auto;*/
/*}*/

/*header {*/
/*    background: white;*/
/*    border-radius: 16px;*/
/*    padding: 20px 30px;*/
/*    margin-bottom: 30px;*/
/*    box-shadow: 0 10px 40px rgba(0,0,0,0.1);*/
/*    display: flex;*/
/*    justify-content: space-between;*/
/*    align-items: center;*/
/*    flex-wrap: wrap;*/
/*}*/

/*h1 {*/
/*    color: #333;*/
/*    font-size: 1.8rem;*/
/*}*/

/*.btn {*/
/*    padding: 12px 24px;*/
/*    border: none;*/
/*    border-radius: 8px;*/
/*    cursor: pointer;*/
/*    font-size: 16px;*/
/*    font-weight: 600;*/
/*    transition: all 0.3s ease;*/
/*}*/

/*.btn-primary {*/
/*    background: linear-gradient(135deg, #667eea, #764ba2);*/
/*    color: white;*/
/*}*/

/*.btn-primary:hover {*/
/*    transform: translateY(-2px);*/
/*    box-shadow: 0 5px 20px rgba(102,126,234,0.4);*/
/*}*/

/*.gallery {*/
/*    display: grid;*/
/*    grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));*/
/*    gap: 25px;*/
/*}*/

/*.photo-card {*/
/*    background: white;*/
/*    border-radius: 16px;*/
/*    overflow: hidden;*/
/*    box-shadow: 0 5px 20px rgba(0,0,0,0.1);*/
/*    transition: transform 0.3s ease;*/
/*    cursor: pointer;*/
/*}*/

/*.photo-card:hover {*/
/*    transform: translateY(-5px);*/
/*}*/

/*.photo-card img {*/
/*    width: 100%;*/
/*    height: 250px;*/
/*    object-fit: cover;*/
/*}*/

/* 弹窗样式 - 只显示图片 */
/*.modal {*/
/*    display: none;*/
/*    position: fixed;*/
/*    z-index: 1000;*/
/*    left: 0;*/
/*    top: 0;*/
/*    width: 100%;*/
/*    height: 100%;*/
/*    background-color: rgba(0,0,0,0.95);*/
/*}*/

/*.modal-content {*/
/*    position: relative;*/
/*    margin: 5% auto;*/
/*    padding: 20px;*/
/*    width: 90%;*/
/*    max-width: 1000px;*/
/*    text-align: center;*/
/*}*/

/*.close {*/
/*    position: absolute;*/
/*    right: 20px;*/
/*    top: -10px;*/
/*    color: white;*/
/*    font-size: 40px;*/
/*    cursor: pointer;*/
/*    z-index: 1001;*/
/*}*/

/*.modal-image {*/
/*    max-width: 100%;*/
/*    max-height: 85vh;*/
/*    border-radius: 8px;*/
/*}*/

/* 隐藏评分相关所有内容 */
/*.rating-area,*/
/*.rating-display,*/
/*.vote-count,*/
/*.stars-display,*/
/*.score-text,*/
/*.photo-info,*/
/*.rating-title,*/
/*.stars,*/
/*#stars,*/
/*#submitRating,*/
/*.btn-success {*/
/*    display: none !important;*/
/*}*/

/*@media print {*/
/*    body {*/
/*        display: none !important;*/
/*    }*/
/*}*/

/*@media (max-width: 768px) {*/
/*    .gallery {*/
/*        grid-template-columns: repeat(auto-fill, minmax(250px, 1fr));*/
/*    }*/
/*}*/












* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    min-height: 100vh;
    padding: 20px;
}

.container {
    max-width: 1200px;
    margin: 0 auto;
}

header {
    background: white;
    border-radius: 16px;
    padding: 20px 30px;
    margin-bottom: 30px;
    box-shadow: 0 10px 40px rgba(0,0,0,0.1);
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
}

h1 {
    color: #333;
    font-size: 1.8rem;
}

.btn {
    padding: 12px 24px;
    border: none;
    border-radius: 8px;
    cursor: pointer;
    font-size: 16px;
    font-weight: 600;
    transition: all 0.3s ease;
}

.btn-primary {
    background: linear-gradient(135deg, #667eea, #764ba2);
    color: white;
}

.btn-primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 5px 20px rgba(102,126,234,0.4);
}

/* 网格布局：自动填充，最小宽度300px */
.gallery {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
    gap: 25px;
    align-items: start; /* 防止卡片高度拉伸 */
}

.photo-card {
    background: white;
    border-radius: 16px;
    /*overflow: hidden;*/
    box-shadow: 0 5px 20px rgba(0,0,0,0.1);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    cursor: pointer;
    display: flex;
    flex-direction: column;
}

.photo-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 15px 35px rgba(0,0,0,0.2);
}

/* 图片容器：自适应高度，不裁剪 */
.photo-card img {
    display: block;
    width: 100%;
    height: auto;          /* 高度自动，保持原始宽高比 */
    object-fit: contain;  /* 确保图片完整显示（一般不需要，但保留） */
    background-color: #f5f5f5;
}

/* 如果需要图片背景色或加载占位，可以保留背景 */
/* 但为了自适应，移除了固定高度 */

/* 可选：给图片一个浅色背景，防止透明图片显示异常 */
.photo-card img {
    background: #eaeef7;
}

/* 隐藏评分相关所有内容（如果有照片信息栏也需要隐藏） */
.rating-area,
.rating-display,
.vote-count,
.stars-display,
.score-text,
.photo-info,
.rating-title,
.stars,
#stars,
#submitRating,
.btn-success {
    display: none !important;
}

/* ========== 全屏弹窗样式（保留点击放大功能） ========== */
.modal {
    display: none;
    position: fixed;
    z-index: 1000;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0,0,0,0.95);
}

.modal-content {
    position: relative;
    margin: 5% auto;
    padding: 20px;
    width: 90%;
    max-width: 1000px;
    text-align: center;
}

.close {
    position: absolute;
    right: 20px;
    top: -10px;
    color: white;
    font-size: 40px;
    cursor: pointer;
    z-index: 1001;
}

.modal-image {
    max-width: 100%;
    max-height: 85vh;
    border-radius: 8px;
    display: block;
    margin: 0 auto;
}

/* 打印时隐藏 */
@media print {
    body {
        display: none !important;
    }
}

/* 响应式：小屏幕下卡片最小宽度减小 */
@media (max-width: 768px) {
    .gallery {
        grid-template-columns: repeat(auto-fill, minmax(250px, 1fr));
        gap: 15px;
    }
    
    .close {
        right: 15px;
        top: 5px;
        font-size: 35px;
    }
}


/* 照片信息区域 - 显示编号和日期 */
.photo-info {
    display: flex !important;
    justify-content: space-between;
    align-items: center;
    padding: 12px 15px;
    background: white;
    border-top: 1px solid #eee;
}

.photo-number {
    font-size: 14px;
    font-weight: 600;
    color: #667eea;
    background: #f0f0ff;
    padding: 4px 12px;
    border-radius: 20px;
}

.photo-date {
    font-size: 12px;
    color: #999;
}

/* 全屏弹窗底部的编号 */
.modal-number {
    position: fixed;
    bottom: 20px;
    left: 50%;
    transform: translateX(-50%);
    background: rgba(0,0,0,0.7);
    color: white;
    padding: 8px 20px;
    border-radius: 30px;
    font-size: 14px;
    font-weight: 500;
    z-index: 10001;
    backdrop-filter: blur(5px);
}

/* 照片信息区域 - 显示编号 */
.photo-info {
    display: flex;
    justify-content: center;  /* 或 center，根据需要 */
    align-items: center;
    padding: 12px 15px;
    background: white;
    border-top: 1px solid #eee;
}

.photo-number {
    font-size: 14px;
    font-weight: 600;
    color: #667eea;
    background: #f0f0ff;
    padding: 4px 12px;
    border-radius: 20px;
}

/* 全屏弹窗底部的编号 */
.modal-number {
    position: fixed;
    bottom: 20px;
    left: 50%;
    transform: translateX(-50%);
    background: rgba(0,0,0,0.7);
    color: white;
    padding: 8px 20px;
    border-radius: 30px;
    font-size: 14px;
    font-weight: 500;
    z-index: 10001;
    backdrop-filter: blur(5px);
}


.photo-card {
    cursor: grab;
}
.photo-card:active {
    cursor: grabbing;
}
.sortable-drag {
    opacity: 0.4;
}


/* 删除按钮样式 */
/*.photo-card {*/
/*    position: relative;*/
/*}*/

/*.photo-delete-btn {*/
/*    position: absolute;*/
/*    top: 10px;*/
/*    right: 10px;*/
/*    width: 36px;*/
/*    height: 36px;*/
/*    background: rgba(255, 255, 255, 0.95);*/
/*    border-radius: 50%;*/
/*    display: flex;*/
/*    align-items: center;*/
/*    justify-content: center;*/
/*    cursor: pointer;*/
/*    font-size: 18px;*/
/*    color: #dc3545;*/
/*    transition: all 0.2s ease;*/
/*    z-index: 10;*/
/*    box-shadow: 0 2px 8px rgba(0,0,0,0.2);*/
/*    font-weight: bold;*/
/*}*/

/*.photo-delete-btn:hover {*/
/*    background: #dc3545;*/
/*    color: white;*/
/*    transform: scale(1.1);*/
/*}*/
.photo-delete-btn {
    background: #fee;
    color: #dc3545;
    padding: 4px 10px;
    border-radius: 20px;
    font-size: 12px;
    cursor: pointer;
    transition: 0.2s;
    display: inline-block;
}
.photo-delete-btn:hover {
    background: #dc3545;
    color: white;
}
.photo-info {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 10px 15px;
}
