body {
    margin: 0;
    padding: 0;
    font-family: 'Lato', sans-serif;
    height: 100vh;
    display: flex;
    flex-direction: column;
}


h2 {
    font-size: 16px;
    line-height: 20px;
    margin-bottom: 1px;
    color: #5f5b5a;
}

p {
    width: 100%;
    font-size: 9px;
    width: 98%;
    color: #777;
}

#p_source a {
  color: #777;            /* 设置为灰色 */
}

#p_source a:visited {
  color: #777;            /* 保持访问后的颜色 */
}

#p_source a:hover {
  color: #CA9542;         
}



#map-container {
    flex: 1;
    position: relative;
}

#map {
    height: 100%;
    width: 100%;
}

.map-controls {
    position: absolute;
    top: 20px;
    right: 20px;
    z-index: 1000;
    display: flex;
    flex-direction: column;
}

.map-controls button {
    background-color: white;
    border: 1px solid #ccc;
    width: 40px;
    height: 40px;
    margin-bottom: 5px;
    font-size: 18px;
    cursor: pointer;
    border-radius: 4px;
    box-shadow: 0 1px 5px rgba(0,0,0,0.2);
}

.map-controls button:hover {
    background-color: #f1f1f1;
}





.footer {
    background-color: #2c3e50;
    color: white;
    text-align: center;
    padding: 10px;
    font-size: 12px;
}

.bowl-marker {
    width: 50px;  /* 调整为合适的大小 */
    height: 50px;
    cursor: pointer;
}

.bowl-marker img {
    width: 100%;
    height: 100%;
    object-fit: contain;
}

.circle-marker {
    width: 10px;
    height: 10px;
    border-radius: 50%;
    border: 2px solid #ffffff;
    box-shadow: 0 0 5px rgba(0,0,0,0.3);
    position: relative;
}

.marker-label {
    position: absolute;
    bottom: -25px;
    left: 50%;
    transform: translateX(-50%);
    white-space: nowrap;
    padding: 2px 5px;
    border-radius: 3px;
    font-size: 12px;
    font-weight: bold;
}

/* 图片面板样式 */
.icons-buttons-container {
    position: absolute;
    top: 70px;
    left: 5px;
    background-color: rgba(255, 255, 255, 0.2); /* 更透明 */
    border-radius: 20px; /* 圆角更大，类似您图片中的效果 */
    padding: 10px 15px; /* 垂直内边距更小 */
    z-index: 1000;
    display: flex;
    flex-direction: column;
    gap:5px;
}

/* 图标面板 - 水平排列 */
.image-panel-horizontal {
    display: flex;
    flex-direction: row;
    gap: 10px;
    background-color: transparent;
}

/* 按钮面板 */
.buttons-panel {
    width: 100%;
    min-height: 50px;
}





/* 按钮组 */
.button-group {
    display: flex;
    flex-direction: row;
    gap: 20px;
    margin-top: 10px;
}

/* 操作按钮样式 */
.action-button {
    padding: 1px 30px;
    background-color: white;
    border: 2px solid #eab63e;
    border-radius: 15px;
    color: #a86923;
    font-size: 14px;
    cursor: pointer;
    transition: all 0.2s ease;
    min-width: 100px;
    text-align: center;
    box-shadow: 0 2px 5px rgba(0,0,0,0.1);
}

.action-button:hover {
    background-color: #eab63e;
    color: white;
    transform: translateX(3px);
}

/* 修改宽按钮的宽度 */
.wide-button {
    min-width: 150px;
}


.map-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-image: url('gjlimages/paper-texture2.jpg');
    background-size: cover;
    opacity: 0.2;
    pointer-events: none; /* 使覆盖层不拦截鼠标事件 */
    z-index: 1;
}

#map::after {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    box-shadow: inset 0 0 50px rgba(139, 98, 58, 0.4);
    pointer-events: none;
}

 #console {
     position: absolute;
     left: -5px;
     width: 350px;
     height: 95%;
     margin-left: 8px;
     padding: 10px 10px 20px 20px;
     background-image: url('gjlimages/scroll5.png');
     background-size: 100% 100%; /* 确保背景图片拉伸填充整个元素 */
     opacity: 1;
     box-shadow: 0px 1px 8px 3px rgba(0,0,0,0.2);
}

.description {
    position: relative;
    top: 5px;
}

.description h1 {
    font-family: 'Cormorant Garamond', serif;
    text-shadow: 1px 1px 4px rgba(137, 46, 11, 0.69); 
    font-size: 34px; 
    font-weight: 700;
    position: relative;
    top: -30px;
    left: -10px;
    text-align: center;
    color: #CA9542;
    padding: 13px; 
    z-index: 1; 
}

/* 修改 slider-container 类，确保水平排列 */
.slider-container {
    display: flex;
    flex-direction: row;         /* 确保水平排列 */
    justify-content: space-between; /* 均匀分布 */
    align-items: center;
    padding: 15px 10px;
    margin-top: -50px;
}

/* 修改 icon-item 类，减小每个图标容器的尺寸 */
.icon-item {
    display: flex;
    flex-direction: column;
    align-items: center;
    width: 60px;  /* 减小宽度 */
    margin: 0 5px;
}

/* 修改 icon-image 类，减小图标的尺寸 */
.icon-image {
    width: 60px;  /* 减小图标尺寸 */
    height: 60px; /* 减小图标尺寸 */
    object-fit: contain;
    transition: transform 0.2s ease;
}

/* 修改 icon-text 类，确保文字大小适合 */
.icon-text {
    margin-top: 5px;
    font-size: 14px; /* 减小文字大小 */
    text-align: center;
    font-weight: bold;
}

/* 选中状态的图标 */
.icon-item.selected .icon-image {
    filter: drop-shadow(0 0 10px rgba(169, 115, 38, 0.8));
}

/* 文字框容器 */
.text-boxes-container {
    display: flex;
    flex-direction: column;
    gap: 10px;
    margin-top: 5px;
    max-width: 90%;
    margin-left: auto;
    margin-right: auto;
    position:relative;
    z-index:10;
}

/* 文字框样式 */
.info-text-box {
    background-color: rgba(255, 245, 220, 0.95);
    border: 1px solid #e1cf99;
    border-radius: 8px;
    padding: 12px 15px;
    font-size: 12px;
    color: #5a4a3a;
    box-shadow: 0 2px 6px rgba(0, 0, 0, 0.1);
    position: relative;
    opacity: 1;
    line-height: 1.5;
}

.info-text-box:hover {
    background-color: rgba(240, 230, 205, 0.95);
    box-shadow: 0 3px 10px rgba(0, 0, 0, 0.2);
}

/* 激活状态 */
.info-text-box.active {
    background-color: rgba(240, 220, 190, 0.95);
    border-color: #d4b76e;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.2);
    transform: translateY(-1px);
}

/* 点击动画 */
.info-text-box.clicked {
    animation: pulse 0.3s ease;
}

@keyframes pulse {
    0% {
        transform: scale(1);
        background-color: rgba(255, 245, 220, 0.95);
    }
    50% {
        transform: scale(1.03);
        background-color: rgba(255, 220, 180, 0.95);
    }
    100% {
        transform: scale(1);
        background-color: rgba(240, 220, 190, 0.95);
    }
}

/* 错误信息 */
.error-message {
    background-color: rgba(255, 200, 200, 0.9);
    color: #721c24;
    padding: 10px;
    border-radius: 4px;
    margin-top: 10px;
    font-weight: bold;
    transition: opacity 0.5s ease;
}


/* 文字框关闭按钮 */
.text-box-close {
    position: absolute;
    top: 5px;
    right: 8px;
    font-size: 16px;
    color: #bd7446;
    cursor: pointer;
    opacity: 0.7;
}

.text-box-close:hover {
    opacity: 1;
}

/* 响应式设计 */
@media (max-width: 600px) {
    .info-text-box {
        font-size: 12px;
        padding: 10px;
    }
}

.source {
    position: relative;
    margin-top:  -8px;
    padding-top: 15px;
}

/* 卷轴弹出框样式 */
.city-info-popup {
  background-image: url('gjlimages/scroll9.png');
  background-size: cover;
  background-position: center;
  padding: 20px 15px;
  border-radius: 8px;
  z-index: 1000;
  width: 200px;
  max-height: 180px;
  overflow-y: auto;
  text-align: center;
  border: none;
  animation: fadeIn 0.3s ease-out;
}

.city-info-popup h4 {
  margin: 0 0 5px 0;
  color: #3A2A1D;
  font-size: 16px;
  text-shadow: 0px 1px 2px rgba(255, 255, 255, 0.8);
  border-bottom: 1px solid rgba(150, 120, 90, 0.5);
  padding-bottom: 4px;
}

.city-info-popup p {
  margin: 0;
  font-size: 12px;
  color: #4A3A2D;
  line-height: 1.5;
  text-shadow: 0px 1px 2px rgba(255, 255, 255, 0.6);
}

/* 信息弹出框样式 */
.info-box {
    width: 80%;
    left:10px;
    max-width: 400px;
    background-color: rgba(255, 255, 255, 0.95);
    border-radius: 10px 10px 0 0;
    box-shadow: 0 -4px 12px rgba(0, 0, 0, 0.2);
    z-index: 2000;
    opacity: 0;
    transition: opacity 0.3s ease;
    border: 1px solid #e1cf99;
}

.info-box.visible {
    opacity: 1;
}

.info-box-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 15px 20px;
    background-color: #f8f2e4;
    border-bottom: 1px solid #e1cf99;
}

.info-box-header h3 {
    margin: 0;
    color: #bd7446;
    font-size: 18px;
}


.city-info-popup.icon-source {
  max-width: 200px;
  padding: 10px;
  font-size: 12px;
}

.city-info-popup.textbox-source {
  max-width: 280px;
  padding: 18px 14px;
  font-size: 13px;
  word-wrap: break-word;
  overflow-wrap: break-word;
  white-space: normal;
  box-sizing: border-box;
}


.close-btn {
    background: none;
    border: none;
    font-size: 24px;
    color: #777;
    cursor: pointer;
    padding: 0;
    line-height: 1;
}

.info-box-content {
    padding: 20px;
    display: flex;
    flex-direction: row;
    gap: 20px;
}

.info-text {
    flex: 2;
}

.info-text p {
    margin: 0 0 15px 0;
    line-height: 1.6;
    color: #333;
}

.info-image {
    flex: 1;
    display: flex;
    flex-direction: column;
    align-items: center;
}

.info-image img {
    max-width: 100%;
    border: 1px solid #e1cf99;
    border-radius: 5px;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
}

.image-caption {
    margin-top: 8px;
    text-align: center;
    color: #777;
    font-size: 14px;
}

/* 响应式调整 */
@media (max-width: 768px) {
    .info-box-content {
        flex-direction: column;
    }
    
    .info-image {
        margin-top: 15px;
    }
}

/* 图例样式 */
.map-legend {
    border-radius: 8px;
    margin-bottom: 10px;
    padding: 2px 10px;
}


.legend-title {
    color: #5f5b5a;
    margin: 0 0 12px 0;
    font-weight: bold;
    font-size: 16px;
    line-height: 20px;
}

.legend-item {
    display: flex;
    align-items: center;
    margin-bottom: 8px;
}

.legend-color {
    width: 20px;
    height: 4px;
    margin-right: 10px;
    flex-shrink: 0;
}

.legend-icon {
    width: 20px;
    height: 20px;
    margin-right: 10px;
    flex-shrink: 0;
    display: flex;
    align-items: center;
    justify-content: center;
}

.legend-icon img {
    max-width: 100%;
    max-height: 100%;
    object-fit: contain;
}

.legend-label {
    color: #333;
    font-size: 14px;
}

/* 移除图标容器的边框 */
.slider-container {
    border-bottom: none !important;
    margin-bottom: 15px; /* 添加适当的下边距 */
}

/* 移除文字框容器的边框 */
.text-boxes-container {
    border-top: none !important;
    margin-top: 5px; /* 添加适当的上边距 */
}

/* 控制分割线的显示 */
hr, .divider {
    display: none; /* 默认隐藏所有分割线 */
}

/* 只显示带有特定 ID 的分割线 */
#legend-divider {
    display: block !important; /* 强制显示图例上方的分割线 */
}

/* 确保 source 元素上方没有边框 */
.source {
    border-top: none !important;
}

/* 移除可能的背景图像边界 */
#console {
    background-image: url('gjlimages/scroll5.png');
    background-size: 100% 100%;
    border: none !important;
}

/* 确保文字框和图例之间的间距适当 */
.map-legend {
    margin-top: 20px !important;
}

.text-boxes-container {
    margin-bottom: 20px !important;
}