<style>
.hospital-table {
    width: 100% !important;
    border-collapse: collapse !important;
    font-family: Arial, sans-serif;
    /*margin: 20px 0;*/
    border: 1px solid #ddd;
    margin: 0 !important;           /* 清除表格外边距 */
    border-spacing: 0 !important;   /* 消除单元格间距 */
    table-layout: auto !important;  /* 改为自动布局 */
    word-wrap: break-word !important;
    overflow-wrap: break-word !important;
    overflow: visible !important;
    max-width: 100% !important;
}

.hospital-table th,
.hospital-table td:first-child {
    /* 桌面端设置第一列为20%宽度 */
    width: 20% !important;
}

.hospital-table td:not(:first-child) {
    /* 桌面端设置第二列为80%宽度 */
    width: 80% !important;
}

.hospital-table th, .hospital-table td {
    /*padding: 12px;*/
    text-align: left;
    border: 1px solid #ddd;
    word-wrap: break-word !important;
    overflow-wrap: break-word !important;
    max-width: none !important;
    overflow: visible !important;
    padding: 8px !important;
    padding-right: 8px !important;
    box-sizing: border-box !important;
}

.hospital-table th {
    background-color: #f2f2f2;
    font-weight: bold;
    color: #333;
}

.hospital-table tr:nth-child(even) {
    background-color: #f9f9f9;
}

.hospital-table tr:hover {
    background-color: #f1f1f1;
}

.hospital-table img {
    float: none !important;
    max-width: 100% !important;
    height: auto !important;
    display: block !important;
    margin: 0 auto !important;
    object-fit: cover; /* 保持图片比例不变 */
}
  .fixed-size {
    width: 30px;
    height: 30px;
    object-fit: cover; /* Ensures the image fills the space without distortion */
}
    .rounded-box {
        border: 1px solid #09c;
        border-radius: 5px;      /* 圆角半径 */
        padding: 5px;
      }
      .box {
        display: inline-block; /* 关键属性 */
        border: 1px solid #000; /* 必须有边框 */
        background: #f0f0f0;    /* 或设置背景色 */
        border-radius: 6px;
      }

/* 移动端响应式表格样式 */
@media (max-width: 768px) {
    .hospital-table {
        table-layout: auto !important;
        width: 100% !important;
    }

    .hospital-table th, .hospital-table td {
        display: block !important;
        width: 100% !important;
        box-sizing: border-box !important;
        padding: 10px !important;
    }

    .hospital-table th {
        background-color: #ADD8E6 !important;
        padding: 8px 10px !important;
        font-size: 14px;
    }

    .hospital-table th,
    .hospital-table td {
        /* 在移动端强制覆盖宽度 */
        width: 100% !important;
    }
    .hospital-table td {
        border-left: none !important;
        border-right: none !important;
        padding-left: 15px !important;
    }

    /* 使用data-label显示标签 */
    .hospital-table td::before {
        content: attr(data-label);
        font-weight: bold;
        color: #333;
        display: block;
        margin-bottom: 5px;
        font-size: 13px;
    }

    /* 隐藏原有的th标签（如果存在的话） */
    .hospital-table th {
        display: none;
    }

    .hospital-table tr {
        display: block !important;
        margin-bottom: 15px;
        border: 1px solid #ddd;
        border-radius: 5px;
        overflow: hidden;
        width: 100% !important;
        box-sizing: border-box !important;
    }

    .hospital-table tr:nth-child(even) {
        background-color: #fff;
    }

    /* 处理包含两个td的行（就医指南中的表格） */
    .hospital-table td[width="20%"] {
        display: none;
    }

    .hospital-table td[width="80%"] {
        width: 100%;
        border-left: none;
        border-right: none;
    }

    /* 处理链接和图片 */
    .hospital-table a {
        word-break: break-word;
    }

    .hospital-table img {
        max-width: 100%;
        height: auto;
    }
}

/* 超小屏幕优化（iPhone SE等） */
@media (max-width: 375px) {
    .hospital-table td {
        padding: 8px;
        padding-left: 10px;
    }

    .hospital-table td::before {
        font-size: 12px;
    }
}

/* 就医指南区域响应式布局 */
.hospitalization-guide {
    display: flex;
    width: 100%;
    border: 1px solid #ddd;
    padding: 0;
    margin: 0;
    box-sizing: border-box;
}

#hg1-container {
    width: 75%;
    padding-right: 10px;
    box-sizing: border-box;
}

#hg2-container {
    width: 25%;
    box-sizing: border-box;
}

#basic-introduction {
    width: 100%;
    overflow-x: visible;
    box-sizing: border-box;
}

@media (max-width: 768px) {
    .hospitalization-guide {
        flex-direction: column;
    }

    #hg1-container, #hg2-container {
        width: 100% !important;
        padding-right: 0;
    }

    #hg1-container {
        margin-bottom: 20px;
    }
}
</style>
