/* 화면군별 배경 — 인트로(.intro-page) 제외 */

/* ========== 공통: body 배경 (최우선) ========== */

body.customer-theme-page,
body.customer-theme {
  min-height: 100vh;
  background-color: #f5f8fc;
  background-image: linear-gradient(
      rgba(245, 248, 252, 0.22),
      rgba(245, 248, 252, 0.22)
    ),
    url("/static/images/bg-customer.png");
  background-position: center center;
  background-size: cover;
  background-repeat: no-repeat;
  background-attachment: fixed;
}

body.hospital-theme-page,
body.hospital-theme {
  min-height: 100vh;
  background-color: #f5f8fc;
  background-image: linear-gradient(
      rgba(245, 248, 252, 0.18),
      rgba(245, 248, 252, 0.18)
    ),
    url("/static/images/bg-hospital.png");
  background-position: calc(50% + 5%) calc(50% + 5%);
  background-size: cover;
  background-repeat: no-repeat;
  background-attachment: fixed;
}

body.operator-theme-page,
body.operator-theme {
  min-height: 100vh;
  background-color: #f5f8fc;
  background-image: linear-gradient(
      rgba(245, 248, 252, 0.24),
      rgba(245, 248, 252, 0.24)
    ),
    url("/static/images/bg-operator.png");
  background-position: center center;
  background-size: cover;
  background-repeat: no-repeat;
  background-attachment: fixed;
}

@media (max-width: 768px) {
  body.customer-theme-page,
  body.customer-theme,
  body.hospital-theme-page,
  body.hospital-theme,
  body.operator-theme-page,
  body.operator-theme {
    background-attachment: scroll;
  }
}

/* 기존 body/page 클래스 단색·그라데이션 덮어쓰기 */

body.customer-theme-page.customer-chat-page,
body.customer-theme.customer-chat-page,
body.customer-theme-page.customer-hub-page,
body.customer-theme-page.customer-result-page,
body.hospital-theme-page.saas-page,
body.hospital-theme.saas-page,
body.hospital-theme-page.hospital-insurance-page,
body.hospital-theme.hospital-insurance-page,
body.hospital-theme-page.rr-landing-page,
body.hospital-theme.rr-landing-page,
body.hospital-theme-page.hospital-hira-page,
body.operator-theme-page.operator-dashboard-page,
body.operator-theme.operator-dashboard-page,
body.operator-theme-page.operator-page,
body.operator-theme.operator-page,
body.operator-theme-page.rr-recv-monitor-page,
body.operator-theme.rr-recv-monitor-page {
  background-color: #f5f8fc;
}

/* ========== wrapper 투명화 (페이지 전체 덮는 레이어만) ========== */

body.customer-theme-page .customer-chat-layout,
body.customer-theme-page .customer-chat-device,
body.customer-theme-page .customer-chat-page__backdrop,
body.customer-theme .customer-chat-layout,
body.customer-theme .customer-chat-device,
body.customer-theme .customer-chat-page__backdrop,
body.hospital-theme-page .hospital-insurance-main,
body.hospital-theme-page .rr-hospital-start-main,
body.hospital-theme-page .rr-hospital-start-shell,
body.hospital-theme-page .analysis-main,
body.hospital-theme-page .hospital-lookup-page main,
body.hospital-theme .hospital-insurance-main,
body.hospital-theme .rr-hospital-start-main,
body.hospital-theme .analysis-main,
body.operator-theme-page .operator-dashboard,
body.operator-theme-page .rr-recv-monitor-main,
body.operator-theme-page .operator-claim-transmissions-main,
body.operator-theme .operator-dashboard,
body.operator-theme .rr-recv-monitor-main {
  background: transparent;
  position: relative;
  z-index: 1;
}

body.customer-theme-page.customer-chat-page,
body.customer-theme.customer-chat-page {
  background: linear-gradient(
      rgba(245, 248, 252, 0.22),
      rgba(245, 248, 252, 0.22)
    ),
    url("/static/images/bg-customer.png") center center / cover no-repeat fixed;
}

body.customer-theme-page .customer-chat-page__backdrop,
body.customer-theme .customer-chat-page__backdrop {
  opacity: 0;
  background: transparent;
  pointer-events: none;
}

.page-bg::before,
.page-bg::after,
.customer-bg::before,
.customer-bg::after,
.hospital-bg::before,
.hospital-bg::after,
.background-overlay,
.customer-chat-page__backdrop,
body.customer-theme-page .customer-chat-page__backdrop,
body.hospital-theme-page .rr-hospital-start-main::before {
  pointer-events: none;
}

.customer-service-progress,
.customer-service-progress a,
.customer-ai-steps,
.customer-ai-steps a,
.flow-step-bar,
.flow-step-bar a,
.rr-top-nav,
.rr-top-nav a {
  position: relative;
  z-index: 5;
}

/* ========== 고객용 — 카드·채팅 내부 유지 ========== */

body.customer-theme-page .customer-chat-shell,
body.customer-theme .customer-chat-shell {
  background: rgba(255, 255, 255, 0.94);
}

body.customer-theme-page .customer-hub-card,
body.customer-theme-page .customer-hub-panel,
body.customer-theme-page .customer-ai-result-page .customer-hub-card,
body.customer-theme-page .customer-documents-page .customer-hub-panel,
body.customer-theme-page .customer-claims-page .customer-hub-panel,
body.customer-theme-page .customer-claim-finder-start-page .customer-chat-shell,
body.customer-theme-page .customer-ai-claim-result-page .customer-chat-shell,
body.customer-theme .customer-hub-card,
body.customer-theme .customer-hub-panel {
  background: rgba(255, 255, 255, 0.92);
}

body.customer-theme-page .customer-chat-bubble--bot,
body.customer-theme .customer-chat-bubble--bot {
  background: rgba(255, 255, 255, 0.96);
}

body.customer-theme-page .customer-chat-bubble--user,
body.customer-theme .customer-chat-bubble--user {
  background: rgba(255, 244, 214, 0.96);
}

body.customer-theme-page .customer-chat-input-area,
body.customer-theme .customer-chat-input-area {
  background: rgba(255, 255, 255, 0.96);
}

body.customer-theme-page .ai-analysis-page--customer .saas-card,
body.customer-theme-page .ai-analysis-page--customer .analysis-section,
body.customer-theme-page .ai-analysis-page--customer .stat-card,
body.customer-theme .ai-analysis-page--customer .saas-card {
  background: rgba(255, 255, 255, 0.94);
}

body.customer-theme-page .customer-result-page main .saas-card,
body.customer-theme-page .customer-result-page .medical-records-full-page__inner {
  background: rgba(255, 255, 255, 0.94);
}

/* ========== 병원용 — 카드·헤더 ========== */

body.hospital-theme-page.hospital-insurance-page,
body.hospital-theme.hospital-insurance-page {
  background: linear-gradient(
      rgba(245, 248, 252, 0.18),
      rgba(245, 248, 252, 0.18)
    ),
    url("/static/images/bg-hospital.png") center center / cover no-repeat fixed;
}

body.hospital-theme-page .saas-card,
body.hospital-theme-page .stat-card,
body.hospital-theme-page .hospital-panel,
body.hospital-theme-page .hospital-insurance-start-card,
body.hospital-theme-page .hospital-insurance-user-input__card,
body.hospital-theme-page .hospital-hira-summary,
body.hospital-theme-page .hospital-insurance-notice,
body.hospital-theme-page .analysis-ready-page .analysis-cta-panel,
body.hospital-theme-page .analysis-main .saas-card,
body.hospital-theme-page .hospital-lookup-card,
body.hospital-theme-page .hospital-customer-form-card,
body.hospital-theme-page .rr-hospital-task-card,
body.hospital-theme .saas-card,
body.hospital-theme .rr-hospital-task-card {
  background: rgba(255, 255, 255, 0.94);
  box-shadow: 0 4px 18px rgba(11, 31, 68, 0.06);
}

body.hospital-theme-page .app-header,
body.hospital-theme .app-header {
  background: rgba(255, 255, 255, 0.92);
  backdrop-filter: blur(8px);
}

body.hospital-theme-page .rr-landing-header,
body.hospital-theme .rr-landing-header {
  background: rgba(255, 255, 255, 0.9);
  backdrop-filter: blur(8px);
}

/* ========== 운영자용 — 테이블 카드 ========== */

body.operator-theme-page.operator-dashboard-page,
body.operator-theme.operator-dashboard-page,
body.operator-theme-page.operator-page,
body.operator-theme.operator-page,
body.operator-theme-page.rr-recv-monitor-page,
body.operator-theme.rr-recv-monitor-page {
  background: linear-gradient(
      rgba(245, 248, 252, 0.24),
      rgba(245, 248, 252, 0.24)
    ),
    url("/static/images/bg-operator.png") center center / cover no-repeat fixed;
}

body.operator-theme-page .operator-dashboard__panel,
body.operator-theme-page .operator-kpi-card,
body.operator-theme-page .operator-feature-card,
body.operator-theme-page .operator-printer-guide,
body.operator-theme-page .operator-claim-table-panel,
body.operator-theme-page .operator-claim-kpi,
body.operator-theme-page .operator-claim-filters,
body.operator-theme-page .operator-claim-empty,
body.operator-theme-page .rr-recv-table-panel,
body.operator-theme-page .rr-recv-stat-card,
body.operator-theme-page .rr-recv-kpi-card,
body.operator-theme-page .rr-recv-filters,
body.operator-theme-page .stat-card,
body.operator-theme-page .operator-section.saas-card,
body.operator-theme-page .operator-package-summary,
body.operator-theme .operator-kpi-card,
body.operator-theme .rr-recv-table-panel {
  background: rgba(255, 255, 255, 0.94);
}

body.operator-theme-page .app-header,
body.operator-theme-page .rr-landing-header,
body.operator-theme .app-header,
body.operator-theme .rr-landing-header {
  background: rgba(255, 255, 255, 0.92);
  backdrop-filter: blur(8px);
}
