/* ───────────────────────────────────────── */
/* 공통 기본 설정 (폰트, body 등)            */
/* ───────────────────────────────────────── */
:root{
  /* Brand */
  --brand-primary: #6297ad;   /* Delphinium Blue */
  --brand-primary-dark: #4f8196;
  --brand-primary-light: #8ab4c7;

  /* Background */
  --bg-main: #f4f5f0;         /* Bright White */
  --bg-surface: #ffffff;
  --bg-muted: #f7f8f6;

  /* Text */
  --text-main: #243445;
  --text-sub: #6b7b8c;
  --text-muted: #9aa7b2;

  /* Line */
  --line: #d9e1e7;

  /* State */
  --success: #5fa8a3;
  --danger: #e46363;

  /* Shadow */
  --shadow-soft: 0 8px 24px rgba(36,52,69,0.08);
}

*{
  -webkit-box-sizing: border-box;
    -moz-box-sizing: border-box;
    box-sizing: border-box;
}
body {
    background: linear-gradient(129deg, #e0f4f3 3.42%, #e9f4d8 98.91%);
    margin: 0;
    padding: 0;
    font-size: 16px !important;
    font-family: 'Pretendard', -apple-system, BlinkMacSystemFont, system-ui, Roboto, 'Helvetica Neue', 'Segoe UI', 'Apple SD Gothic Neo', sans-serif;
     /* 하단 네비 가리지 않게 */
  }
  .container {
        width: 100%;
        max-width: 1280px;
        margin: 0 auto;
        z-index: 1;

}
  /* 공통 버튼 스타일 */
  .btn1{
    background: linear-gradient(94deg, #3eb7ee 0.08%, #00b59b 99.92%);
    border-radius: 30px;
    padding: 20px;
    text-align: center;
    color: #fff;
    font-size: 30px;
    font-style: normal;
    font-weight: 600;
    line-height: 1.4;
    text-decoration: none;
  }
.btn-nav {
    display: inline-block;
    padding: 6px 18px;
    border-radius: 30px;
    font-size: 14px;
    font-weight: bold;
    text-decoration: none;
    transition: 0.3s ease-in-out;
    border: 1.5px solid transparent;
    margin-left: 4px;
  }
  
  /* 로그인 버튼 - 녹색 배경 */
  .btn-nav.login {
    background-color: #00b89c;
    color: #fff !important;
    border-color: #00b89c;
  }
  
  /* 가입 버튼 - 흰 배경, 녹색 테두리 */
  .btn-nav.signup {
    background-color: white;
    color: #00b59b !important;
    border: 1.5px solid #00b89c;
  }
  
  /* 로그아웃 버튼 - 동일한 녹색 배경 */
  .btn-nav.logout {
    background-color: #00b89c;
    color: white !important;
    border-color: #00b89c;
  }
  
  /* 마이페이지 버튼 - 회색 또는 흰색 배경 */
  .btn-nav.mypage {
    background-color: #ffffff;
    color: #00b59b;
    border: 1.5px solid #00b89c;
  }
  
  /* hover 효과 */
  .btn-nav:hover {
    opacity: 0.85;
  }
  /* ───────────────────────────────────────── */
  /* 공통 헤더 스타일                          */
  /* ───────────────────────────────────────── */
  .app-header {
    background: transparent;
    padding: 20px 0;
  }
  .logo{
    font-size: 2rem;
  }
  .app-header .container {
    display: flex;
    align-items: center;
    justify-content: space-between;
    max-width: 1280px;
    margin: 0 auto;
    padding: 40px 20px;
    background: #fff;
    border-radius: 100px;
    box-shadow: 0 8px 30px rgba(26, 175, 128, 0.2);
  }
  .app-header .logo img {
    display: block;
    height: 40px;
  }
  .app-header .main-nav ul {
    list-style: none;
    margin: 0;
    padding: 0;
    display: flex;
    gap: 1.8rem;
    align-items: center;
  }
  .app-header .main-nav a {
    color: #333;
    font-weight: 500;
    text-decoration: none;
    font-size: 20px;
  }
  
  /* ───────────────────────────────────────── */
  /* 공통 푸터 스타일                          */
  /* ───────────────────────────────────────── */
  .app-footer {
    background: linear-gradient(to bottom, rgba(234, 247, 243, 0), rgba(255, 255, 255, 1));
    padding: 2rem 1rem;
    font-size: 0.875rem;
    color: #333;
  }
  
  .app-footer .footer-top {
    text-align: center;
    margin-bottom: 1.5rem;
  }
  
  .app-footer .footer-links {
    display: flex;
    justify-content: center;
    gap: 1rem;
    padding: 0;
    margin: 0;
    list-style: none;
  }
  
  .app-footer .footer-links a {
    color: #666;
    text-decoration: none;
    font-weight: 500;
  }
  
  .app-footer .footer-links a:hover {
    text-decoration: underline;
  }
  
  .footer-main {
    max-width: 1280px;
    margin: 0 auto;
    padding-top: 1rem;
  }
  
  .footer-flex {
    display: flex;
    gap: 2rem;
    align-items: flex-start;
    flex-wrap: wrap;
  }
  
  .footer-logo img {
    background: #fff;
    border-radius: 30px;
    padding: 10px;
    display: block;
    height: 60px;
  }
  
  .footer-info {
    flex: 1;
    min-width: 250px;
  }
  
  .footer-info p {
    margin: 0.5rem 0;
    line-height: 1.6;
    color: #444;
  }
  
  .footer-disclaimer {
    font-size: 0.75rem;
    color: #999;
  }
  
  /* 반응형 대응 */
  @media screen and (max-width: 768px) {
    .footer-flex {
      flex-direction: column;
      align-items: center;
      text-align: center;
    }
  
    .footer-logo img {
      height: 50px;
    }
  
    .footer-info {
      width: 100%;
    }
  
    .footer-info p {
      font-size: 0.8125rem;
    }
  }
  /* ───────────────────────────────────────── */
  /* 모바일 하단 네비게이션                    */
  /* ───────────────────────────────────────── */
  .mobile-nav {
    display: none;
  }
  
  /* ───────────────────────────────────────── */
  /* 슬라이드 메뉴 (기본: PC에선 숨김)         */
  /* ───────────────────────────────────────── */
  .menu-toggle {
    display: none;
  }
  .slide-menu {
    display: none;
  }
  .mo{
    display: none;
  }
  /* ───────────────────────────────────────── */
  /* 모바일 반응형 (768px 이하)                */
  /* ───────────────────────────────────────── */
  @media (max-width: 768px) {
    .mo{
      display:block
    }
    
    .container {
        width: 100%;
        max-width: 100%;
        margin: 0 auto;
    
    }
    /* ▶ 헤더 반응형 */
    .menu-toggle {
      display: block;
      font-size: 28px;
      line-height: 1;
      background: none;
      border: none;
      padding: 0;
      margin: 0;
      color: #333;
      cursor: pointer;
    }
  
    .main-nav {
      display: none;
      flex-direction: column;
      background: #fff;
      width: 100%;
      position: absolute;
      top: 60px;
      left: 0;
      z-index: 100;
      box-shadow: 0 4px 8px rgba(0,0,0,0.1);
    }
  
    .main-nav.active {
      display: flex;
    }
  
    .main-nav ul {
      width: 100%;
      padding: 1rem;
    }
  
    .main-nav li {
      margin-bottom: 10px;
    }
  
    .app-header .container {
      flex-direction: row;
      align-items: center;
      justify-content: space-between;
      border-radius: 100px;
      padding: 14px 24px;
      gap: 0;
      width: 90%;
    }
  
    .app-header .main-nav ul {
      flex-direction: column;
      align-items: center;
      gap: 0.8rem;
    }
  
    /* ▶ 하단 고정 네비게이션 */
    .mobile-nav {
      display: flex;
      position: fixed;
      bottom: 0;
      left: 0;
      width: 100%;
      background: #fff;
      border-top: 1px solid #e5e5e5;
      justify-content: space-around;
      align-items: center;
      padding: 0.5rem 0;
      z-index: 1000;
    }
  
    .mobile-nav a {
      flex: 1;
      display: flex;
      justify-content: center;
      align-items: center;
      text-align: center;
      font-size: 0.75rem;
      color: #333;
      text-decoration: none;
      flex-direction: column;
    }
  
    .mobile-nav a .icon {
      display: block;
      font-size: 1.5rem;
      margin-bottom: 0.25rem;
    }
  
    /* ▶ 슬라이드 메뉴 */
    .slide-menu {
      display: flex;
      flex-direction: column;
      position: fixed;
      top: 0;
      left: 0;
      width: 100vw;
      height: 100vh;
      background: #fff;
      z-index: 9999;
      transition: transform 0.3s ease-in-out;
      transform: translateX(100%);
      overflow-y: auto;
      padding: 2rem 1.5rem;
      box-shadow: -4px 0 12px rgba(0,0,0,0.15);
    }
  
    .slide-menu.active {
      transform: translateX(0);
    }
  
    .slide-menu .container,
    .slide-menu .menu-header {
      max-width: none;
      width: 100%;
      padding: 0;
    }
  
    .menu-header {
      display: flex;
      justify-content: space-around;
      align-items: center;
      margin-bottom: 2rem;
      padding-right: 4px;
    }
  
    .menu-close {
      font-size: 24px;
      background: none;
      border: none;
      cursor: pointer;
    }
    .btn1{
      padding: 10px 20px;
      font-size: 18px;
    }
    .menu-auth-buttons {
      display: flex;
      width: 90%;
      gap: 0.5rem;
      margin-bottom: 2rem;
      justify-content: center;
    }
  
    .menu-auth-buttons .btn {
      flex: 1;
      padding: 0.75rem;
      border-radius: 25px;
      border: 1px solid #00b89c;
      font-weight: 600;
      text-align: center;
      background: #fff;
      color: #00b89c;
      text-decoration: none;
    }
  
    .menu-auth-buttons .btn.login {
      background: #00b89c;
      color: white;
    }
  
    .slide-nav {
      list-style: none;
      padding: 0;
      margin: 0;
      width: 90%;
    }
  
    .slide-nav li {
      border-bottom: 1px solid #eee;
      padding: 1rem 0;
    }
  
    .slide-nav li a {
      color: #111;
      text-decoration: none;
      font-size: 1rem;
      display: block;
    }
  
    /* ▶ 푸터 반응형 */
    .app-footer{
        padding: 2rem 1rem;
    }
    .app-footer .footer-content {
      flex-direction: column;
      align-items: center;
      gap: 2rem;
    }
    .app-footer .company-info img{
        width: 55%;
    }
    .app-footer .company-info {
        display: flex;
        flex-direction: column;
        order: 2;
    }
  
    .app-footer .contact-box {
      background: #2a2a2a;
      border-radius: 10px;
      width: 100%;
      padding: 0rem;
      text-align: center;
      order: 1;
    }
    .app-footer .company-info p{
        font-size: 11px;
        color: rgb(161 161 170 / var(--tw-text-opacity, 1));
    }
  
    .app-footer .contact-box h4 {
      font-size: 1rem;
      margin-bottom: 0.5rem;
      color: #fff;
    }
  
    .app-footer .contact-box p {
      font-size: 0.875rem;
      line-height: 1.4;
      color: #ccc;
    }
  }
  
  /* 보드css */
  #bo_list,#bo_w,#bo_v{
    width: 100%;
    max-width: 1280px;
    margin: 0 auto;
    min-height: 100vh;
    padding-top: 8rem;
  }


  /* ====== Theme tokens ====== */
:root{
  --c-bg:#ffffff;
  --c-muted:#f7fafb;
  --c-line:#d5dee7;
  --c-text:#243445;
  --c-sub:#6b7b8c;
  --c-primary:#3b82f6;
  --c-primary-2:#2563eb;
  --c-accent:#19b58e;
  --ring:0 0 0 3px rgba(59,130,246,.18);
}

/* ===== 모달 기본 ===== */
.modal-overlay{
  position:fixed; inset:0;
  background:rgba(0,0,0,.35);
  backdrop-filter:saturate(120%) blur(2px);
  opacity:0; visibility:hidden;
  transition:opacity .22s ease, visibility .22s ease;
  z-index:9998;
}
.modal{
  position:fixed; inset:0;
  display:flex; align-items:center; justify-content:center;
  opacity:0; visibility:hidden;
  transition:opacity .22s ease, visibility .22s ease;
  z-index:9999;
}
.modal-overlay.open,.modal.open{ opacity:1; visibility:visible; }

.modal-box{
  width:min(560px,92vw);
  background:var(--c-bg);
  border-radius:16px;
  box-shadow:0 20px 60px rgba(0,0,0,.25);
  overflow:hidden;
  transform:translateY(6px) scale(.985);
  transition:transform .24s cubic-bezier(.22,.61,.36,1), box-shadow .24s ease;
}
.modal.open .modal-box{ transform:translateY(0) scale(1); }

.modal-header{
  display:flex; align-items:center; justify-content:space-between;
  padding:16px 18px;
  background:linear-gradient(135deg,#eff7ff 0%, var(--c-muted) 100%);
  border-bottom:1px solid #e6eef4;
}
.modal-header h3{ font-size:16px; margin:0; color:var(--c-text); }
.modal-close{ border:0; background:transparent; font-size:18px; cursor:pointer; }

.modal-body{ padding:18px; }
.field{ margin-bottom:16px; }
.field label{ display:block; font-weight:700; margin-bottom:6px; color:var(--c-text); }
.field .note{ display:block; margin-top:6px; color:var(--c-sub); font-size:12px; }

/* 입력 공통 */
.account-row{ display:flex; gap:8px; }
.account-row input,
.account-row select{
  flex:1; padding:10px 12px;
  border:1px solid var(--c-line);
  border-radius:10px; background:#fff; font-size:14px;
  box-shadow:0 1px 0 rgba(0,0,0,.02);
}
.account-row input:focus,
.account-row select:focus{
  outline:none; border-color:var(--c-primary); box-shadow:var(--ring);
}
/* RRN(주민번호) 필드 */
.rrn-field .label-row{display:flex;align-items:center;justify-content:space-between;margin-bottom:6px}
.privacy-chip{font-size:12px;color:#466086;background:#f1f6ff;border:1px solid #d7e4ff;padding:4px 8px;border-radius:999px}

.rrn-group{
  display:flex;align-items:center;gap:6px;
  background:#fff;border:1px solid var(--c-line,#d5dee7);border-radius:12px;
  padding:6px 10px;transition:box-shadow .2s ease,border-color .2s ease
}
.rrn-group.valid{border-color:#22c55e;box-shadow:0 0 0 3px rgba(34,197,94,.15)}
.rrn-group.invalid{border-color:#ef4444;box-shadow:0 0 0 3px rgba(239,68,68,.12)}

.rrn-group .seg{position:relative}
.rrn-group .dash{color:#8ea0b3;font-weight:600}
.rrn-group input{
  width:130px;padding:10px 12px;border:0;background:transparent;outline:none;
  font-size:15px;letter-spacing:2px
}
.rrn-group #rrn2{width:160px}

.seg-eye{
  position:absolute;right:6px;top:50%;transform:translateY(-50%);
  width:32px;height:32px;border:1px solid var(--c-line,#d5dee7);
  border-radius:8px;background:#fff;cursor:pointer
}
.seg-eye::before{content:'👁';display:block;text-align:center;line-height:30px;font-size:16px}

.state{position:absolute;right:-22px;top:50%;transform:translateY(-50%);width:16px;height:16px}
.rrn-group.valid .state::after{content:'✓';color:#22c55e;font-weight:700}
.rrn-group.invalid .state::after{content:'!';color:#ef4444;font-weight:700}
/* 서명 */
.sig{
  width:100%; height:160px;
  border:1px solid var(--c-line); border-radius:10px; display:block;
  background:
    linear-gradient(transparent 31px,#f1f5f9 32px) repeat-y,
    linear-gradient(90deg,transparent 31px,#f1f5f9 32px) repeat-x,
    #fff;
  background-size:100% 32px, 32px 100%, auto;
}
.sig-actions{ display:flex; justify-content:flex-end; margin-top:8px; }

/* 버튼 */
.btn-line{
  padding:8px 12px; border:1px solid var(--c-line);
  background:#fff; border-radius:10px; cursor:pointer;
}
.modal-actions{ display:flex; justify-content:flex-end; gap:10px; margin-top:10px; }
.btn-secondary{
  padding:10px 14px; border:1px solid #cfd9e3; background:#fff;
  border-radius:10px; cursor:pointer;
}
.btn-secondary:hover{ border-color:#b8c6d6; }
.btn-primary{
  padding:10px 14px; border:0; background:var(--c-primary); color:#fff;
  border-radius:10px; cursor:pointer; box-shadow:0 6px 14px rgba(59,130,246,.18);
}
.btn-primary:hover{ background:var(--c-primary-2); }

/* ===== 역할 토글 ===== */
.app-header{ position:relative; }
.rolebar{ display:flex; justify-content:center; z-index:15; pointer-events:none; }
.rolebar__inner{
  width:100%; max-width:1280px; padding:0 16px;
  display:flex; justify-content:flex-end; align-items:center;
  pointer-events:auto; margin-bottom:15px;
}
.role-toggle{
  position:relative; display:inline-flex; align-items:center; padding:4px;
  border-radius:999px; background:var(--c-muted);
  box-shadow:0 12px 28px rgba(30,60,90,.10),0 4px 10px rgba(30,60,90,.06), inset 0 0 0 1px #d6dee5;
  white-space:nowrap;
}
.role-chip{
  position:relative; z-index:2; flex:0 0 110px; text-align:center;
  border:0; background:transparent; padding:8px 18px;
  font-size:14px; font-weight:600; line-height:1;
  color:#5b6b7a; cursor:pointer; opacity:.85;
  transition:color .22s ease, transform .22s ease, opacity .22s ease;
}
.role-chip.active{ color:#fff; transform:translateY(-1px); opacity:1; }

.role-slider{
  position:absolute; inset:4px auto 4px 4px; width:calc(50% - 4px);
  border-radius:999px; background:var(--c-accent);
  box-shadow:0 2px 8px rgba(0,0,0,.08);
  transform:translate3d(0,0,0);
  will-change:transform, background-color, box-shadow;
  transition:transform 360ms cubic-bezier(.22,.61,.36,1), background-color 360ms ease, box-shadow 360ms ease;
}
.role-slider::after{
  content:""; position:absolute; inset:0; border-radius:999px;
  background:radial-gradient(120% 100% at 0% 0%, rgba(255,255,255,.35), transparent 70%);
  opacity:0; transition:opacity 360ms ease;
}
.role-toggle.animating .role-slider::after{ opacity:.45; }

body.caregiver-mode .role-slider{ transform:translateX(100%); background:var(--c-primary); }

/* 배경 그라데이션 */
body{ transition:background 420ms ease; }
body.applicant-mode{
  background:#fff;
}
body.caregiver-mode{
  background:#fff;
}

/* 접근성: 모션 감소 */
@media (prefers-reduced-motion: reduce){
  .role-slider, .role-chip, body, .modal-box{ transition:none !important; }
}

/* 반응형 */
@media (max-width:560px){
  .rolebar{ position:static; margin:8px 12px 0 auto; }
  .rolebar__inner{ justify-content:flex-end; }
  .role-chip{ flex-basis:96px; padding:8px 14px; font-size:13px; }
}

/* 설계사 알림 뱃지 */
.badge-planner {
  display:inline-block;
  margin-left:4px;
  padding:0 6px;
  min-width:18px;
  height:18px;
  border-radius:999px;
  background:#ff4d4f;
  color:#fff;
  font-size:11px;
  line-height:18px;
  text-align:center;
  vertical-align:middle;
}

/* 메뉴 자체도 살짝 강조 */
.planner-alert {
  position:relative;
  font-weight:600;
}

/* =====================================================
   외국인 서류 업로드 필드 — .alien-doc-field
   ===================================================== */
@keyframes slideDown {
  from { opacity:0; transform:translateY(-8px); }
  to   { opacity:1; transform:translateY(0); }
}

.alien-doc-field {
  animation: slideDown .25s ease;
}

.alien-doc-note {
  margin: 4px 0 10px;
  color: #555;
  font-size: 13px;
  line-height: 1.6;
}

/* 파일 드롭존 박스 */
.alien-doc-box {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 14px 16px;
  border: 2px dashed #c5cae9;
  border-radius: 10px;
  background: #f5f6ff;
  cursor: pointer;
  transition: border-color .2s, background .2s;
  min-height: 54px;
  user-select: none;
}
.alien-doc-box:hover,
.alien-doc-box.drag-over {
  border-color: #5c6bc0;
  background: #eef0fb;
}
.alien-doc-box.has-file {
  border-color: #43a047;
  background: #f1f8e9;
}

.alien-doc-icon {
  font-size: 22px;
  line-height: 1;
  flex-shrink: 0;
}

.alien-doc-name {
  font-size: 13px;
  color: #444;
  word-break: break-all;
  flex: 1;
}
.alien-doc-box.has-file .alien-doc-name {
  color: #2e7d32;
  font-weight: 600;
}

/* 필수 표시 */
.required-mark {
  color: #e53935;
  font-size: 14px;
  margin-left: 2px;
}

/* 스크린리더 전용 숨김 */
.sr-only {
  position: absolute !important;
  width: 1px; height: 1px;
  overflow: hidden;
  clip: rect(0,0,0,0);
  white-space: nowrap;
}

/* App common alert popup */
body.hk-app-alert-open {
  overflow: hidden;
}

.hk-app-alert {
  position: fixed;
  inset: 0;
  z-index: 99999;
  display: none;
  align-items: center;
  justify-content: center;
  padding: 24px;
  background: rgba(15, 23, 42, 0.48);
}

.hk-app-alert.is-open {
  display: flex;
}

.hk-app-alert__panel {
  width: min(420px, 100%);
  border-radius: 16px;
  background: #fff;
  box-shadow: 0 24px 70px rgba(15, 23, 42, 0.24);
  overflow: hidden;
}

.hk-app-alert__body {
  padding: 28px 28px 20px;
  text-align: center;
}

.hk-app-alert__icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 52px;
  height: 52px;
  margin-bottom: 16px;
  border-radius: 50%;
  background: #eaf7f4;
  color: #0f9f8d;
  font-size: 26px;
  font-weight: 800;
}

.hk-app-alert__title {
  margin: 0 0 10px;
  color: #0f172a;
  font-size: 20px;
  line-height: 1.35;
  letter-spacing: 0;
}

.hk-app-alert__message {
  margin: 0;
  color: #334155;
  font-size: 15px;
  line-height: 1.65;
  word-break: keep-all;
}

.hk-app-alert__actions {
  display: flex;
  justify-content: center;
  padding: 0 28px 28px;
}

.hk-app-alert__button {
  min-width: 112px;
  min-height: 44px;
  padding: 0 20px;
  border: 0;
  border-radius: 10px;
  background: #0f9f8d;
  color: #fff;
  font-size: 15px;
  font-weight: 800;
  cursor: pointer;
}

.hk-app-alert__button:focus {
  outline: 3px solid rgba(15, 159, 141, 0.22);
  outline-offset: 2px;
}

@media (max-width: 480px) {
  .hk-app-alert {
    padding: 18px;
  }

  .hk-app-alert__body {
    padding: 24px 22px 18px;
  }

  .hk-app-alert__actions {
    padding: 0 22px 24px;
  }

  .hk-app-alert__button {
    width: 100%;
  }
}
