/* ============================================
   选择医院 - 新版样式
   绿色主色调 + 白色卡片浮层 + 背景图
   ============================================ */

/* 全局重置 */
.select-hospital-page * {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

.select-hospital-page body {
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
    background: #f0f4f3;
    color: #333;
    min-height: 100vh;
    padding-bottom: 100px;
}

/* ============================================
   1. 顶部背景与导航区
   ============================================ */

.hero-section {
    position: relative;
    width: 100%;
    height: 220px;
    overflow: hidden;
    flex-shrink: 0;
}

.hero-bg {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background:
        linear-gradient(180deg, rgba(39, 174, 96, 0.15) 0%, rgba(39, 174, 96, 0.05) 100%),
        url('/static/images/nav_hospital_01.jpg') center center / cover no-repeat;
    /* 无实际图片时回退为渐变 */
    background: linear-gradient(135deg, #a8e6cf 0%, #88d8a8 30%, #5cb885 60%, #3d9c6b 100%);
}

/* 模拟山景和人物剪影效果 */
.hero-bg::before {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 100%;
    height: 60%;
    background: linear-gradient(180deg, transparent 0%, rgba(39, 174, 96, 0.3) 100%);
}

.hero-bg::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 100%;
    height: 45px;
    background: linear-gradient(180deg, transparent, #f0f4f3);
}

.hero-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(180deg, rgba(0, 0, 0, 0.15) 0%, transparent 60%);
}

/* 导航栏 */
.hero-nav {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    padding: env(safe-area-inset-top, 12px) 12px 0;
    z-index: 10;
}

.btn-back {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 40px;
    height: 40px;
    background: rgba(255, 255, 255, 0.25);
    backdrop-filter: blur(6px);
    -webkit-backdrop-filter: blur(6px);
    border-radius: 50%;
    text-decoration: none;
    transition: background 0.2s;
}

.btn-back:active {
    background: rgba(255, 255, 255, 0.45);
}

.btn-group {
    display: flex;
    align-items: center;
    gap: 4px;
    background: rgba(255, 255, 255, 0.25);
    backdrop-filter: blur(6px);
    -webkit-backdrop-filter: blur(6px);
    border-radius: 20px;
    padding: 4px 6px;
}

.btn-more,
.btn-refresh {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 32px;
    height: 32px;
    border-radius: 50%;
    cursor: pointer;
    transition: background 0.2s;
}

.btn-more:active,
.btn-refresh:active {
    background: rgba(255, 255, 255, 0.3);
}

/* ============================================
   2. 核心功能卡片
   ============================================ */

.main-card {
    position: relative;
    z-index: 50;
    margin: -40px 12px 16px;
    background: #fff;
    border-radius: 16px;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.1);
    padding: 20px 16px 16px;
}

/* 医院定位栏 */
.card-hospital {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding-bottom: 14px;
    border-bottom: 1px solid #f0f0f0;
}

.hospital-left {
    display: flex;
    align-items: center;
    gap: 8px;
    flex: 1;
    min-width: 0;
}

.icon-location {
    flex-shrink: 0;
}

.hospital-name {
    font-size: 16px;
    font-weight: 600;
    color: #666;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    transition: color 0.2s;
}

.hospital-switch {
    display: flex;
    align-items: center;
    gap: 4px;
    color: #27ae60;
    font-size: 14px;
    cursor: pointer;
    flex-shrink: 0;
    margin-left: 8px;
}

/* 医院选择面板 */
.hospital-panel {
    display: none;
    padding: 12px 0;
    border-bottom: 1px solid #f0f0f0;
    margin-bottom: 14px;
}

.hospital-panel.show {
    display: block;
}

.hospital-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 10px;
}

.hospital-card {
    background: #f8faf9;
    border: 2px solid #e8efe9;
    border-radius: 12px;
    padding: 12px 6px;
    text-align: center;
    cursor: pointer;
    transition: all 0.2s;
}

.hospital-card:active {
    transform: scale(0.96);
}

.hospital-card.selected {
    border-color: #27ae60;
    background: #e8f8ef;
}

.hospital-logo {
    font-size: 36px;
    line-height: 1;
    margin-bottom: 6px;
}

.hospital-logo img {
    width: 40px;
    height: 40px;
    object-fit: contain;
    border-radius: 6px;
}

.hospital-label {
    font-size: 12px;
    font-weight: 600;
    color: #333;
    line-height: 1.3;
    word-break: break-all;
}

/* 科室选择 */
.card-department {
    display: flex;
    align-items: center;
    gap: 10px;
    background: #f7f8f9;
    border: 1px solid #e8e8e8;
    border-radius: 12px;
    padding: 14px 16px;
    margin: 14px 0;
    cursor: pointer;
    transition: background 0.2s;
}

.card-department:active {
    background: #eef0f2;
}

.dept-icon {
    flex-shrink: 0;
}

.dept-text {
    flex: 1;
    font-size: 17px;
    font-weight: 600;
    color: #333;
}

.dept-arrow {
    font-size: 22px;
    color: #bbb;
    flex-shrink: 0;
}

/* 床号填写 */
.card-bed {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 10px 0;
}

.bed-label {
    font-size: 13px;
    color: #999;
    white-space: nowrap;
    flex-shrink: 0;
}

.bed-hint {
    color: #ccc;
}

.bed-input {
    flex: 1;
    border: none;
    border-bottom: 1px solid #e8e8e8;
    font-size: 15px;
    color: #333;
    padding: 6px 0;
    outline: none;
    background: transparent;
}

.bed-input::placeholder {
    color: #ccc;
}

/* 分割线 */
.card-divider {
    height: 1px;
    background: #f0f0f0;
    margin: 4px 0 14px;
}

/* 服务方信息 */
.card-company {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 10px 0;
    cursor: pointer;
}

.company-icon {
    flex-shrink: 0;
}

.company-info {
    flex: 1;
    font-size: 13px;
    color: #666;
    line-height: 1.5;
    min-width: 0;
}

.company-info a {
    color: #333;
    text-decoration: underline;
    text-decoration-style: dotted;
    text-underline-offset: 3px;
    font-weight: 500;
}

.company-arrow {
    font-size: 20px;
    color: #ccc;
    flex-shrink: 0;
}

/* 主操作按钮 */
.btn-order {
    display: block;
    width: 100%;
    padding: 14px;
    margin: 18px 0 10px;
    background: linear-gradient(135deg, #27ae60 0%, #219a52 100%);
    color: #fff;
    font-size: 17px;
    font-weight: 600;
    letter-spacing: 2px;
    border: none;
    border-radius: 25px;
    cursor: pointer;
    transition: all 0.2s;
    opacity: 1;
    box-shadow: 0 4px 12px rgba(39, 174, 96, 0.35);
}

.btn-order:active {
    transform: scale(0.98);
    box-shadow: 0 2px 8px rgba(39, 174, 96, 0.25);
}

.btn-order:disabled {
    opacity: 0.45;
    box-shadow: none;
    cursor: not-allowed;
    transform: none;
}

/* 电话咨询 */
.card-phone {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 6px;
    padding: 8px 0 2px;
    color: #27ae60;
    font-size: 14px;
    cursor: pointer;
}

/* ============================================
   3. 在院护工列表
   ============================================ */

.nurse-section {
    margin: 0 12px;
}

.nurse-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 16px 4px 12px;
}

.nurse-title {
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 17px;
    font-weight: 700;
    color: #333;
}

.nurse-icon {
    flex-shrink: 0;
}

.nurse-filter {
    display: flex;
    align-items: center;
    cursor: pointer;
    padding: 4px;
}

/* 护工卡片 */
.nurse-list {
    padding-bottom: 8px;
}

.nurse-card-item {
    display: flex;
    align-items: flex-start;
    background: #fff;
    border-radius: 12px;
    padding: 14px;
    margin-bottom: 10px;
    box-shadow: 0 1px 6px rgba(0, 0, 0, 0.06);
}

.nurse-photo {
    width: 56px;
    height: 56px;
    border-radius: 10px;
    overflow: hidden;
    flex-shrink: 0;
    background: #f0f4f3;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 28px;
    margin-right: 12px;
}

.nurse-photo img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.nurse-detail {
    flex: 1;
    min-width: 0;
}

.nurse-top {
    display: flex;
    align-items: center;
    gap: 8px;
    margin-bottom: 6px;
}

.nurse-nname {
    font-size: 16px;
    font-weight: 600;
    color: #333;
}

.nurse-tag {
    display: inline-block;
    background: #fef0f5;
    color: #e84393;
    font-size: 12px;
    font-weight: 500;
    padding: 2px 10px;
    border-radius: 12px;
    white-space: nowrap;
}

.nurse-rating {
    display: flex;
    align-items: center;
    gap: 6px;
}

.stars {
    color: #ddd;
    font-size: 13px;
    letter-spacing: 1px;
}

.rate-text {
    font-size: 12px;
    color: #bbb;
}

.nurse-view {
    flex-shrink: 0;
    font-size: 14px;
    color: #27ae60;
    text-decoration: none;
    padding: 4px 0;
    align-self: center;
    white-space: nowrap;
}

/* 空状态 & 加载 */
.nurse-loading,
.nurse-empty {
    text-align: center;
    padding: 30px 20px;
    color: #bbb;
    font-size: 14px;
    background: #fff;
    border-radius: 12px;
}

/* ============================================
   4. 悬浮按钮
   ============================================ */

.float-orders {
    position: fixed;
    bottom: 28px;
    right: 16px;
    z-index: 200;
    display: flex;
    align-items: center;
    gap: 6px;
    background: linear-gradient(135deg, #00b894 0%, #00a381 100%);
    color: #fff;
    padding: 10px 16px;
    border-radius: 28px;
    text-decoration: none;
    font-size: 13px;
    font-weight: 600;
    box-shadow: 0 4px 16px rgba(0, 184, 148, 0.4);
    transition: transform 0.2s;
}

.float-orders:active {
    transform: scale(0.95);
}
