/* ════════════════════════════════════════════
   COZYFEET KOREA - Common Style
   풀스크린 좌(고정폭 패널) + 우(가변 콘텐츠) 2단 레이아웃
   ════════════════════════════════════════════ */

@import url('https://fonts.googleapis.com/css2?family=Noto+Sans+KR:wght@400;500;600;700;800;900&display=swap');

*, *::before, *::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

:root {
  --blue-900: #0F2557;
  --blue-800: #14306E;
  --blue-700: #1A3C8F;
  --blue-600: #2447A8;
  --blue-500: #2F5FD8;
  --blue-100: #E8EEFF;
  --blue-50:  #F4F7FF;

  --text-900: #14172B;
  --text-700: #3A3F55;
  --text-500: #6B7280;
  --text-300: #9CA3AF;

  --border: #E5E9F2;
  --white: #FFFFFF;

  --yellow: #FEE500;
  --shadow-soft: 0 8px 32px rgba(15, 37, 87, 0.10);
  --shadow-card: 0 4px 16px rgba(15, 37, 87, 0.06);

  --panel-width: 320px;
}

html, body {
  height: 100%;
}

body {
  font-family: 'Noto Sans KR', -apple-system, BlinkMacSystemFont, sans-serif;
  background: var(--white);
  color: var(--text-900);
  min-height: 100vh;
  -webkit-font-smoothing: antialiased;
}

/* ════════════════════════════════════════════
   1. 풀스크린 좌우 2단 레이아웃 (모든 페이지 공통 골격)
   ════════════════════════════════════════════ */
.app-shell {
  display: grid;
  grid-template-columns: var(--panel-width) 1fr;
  min-height: 100vh;
  width: 100%;
}

.side-panel {
  background: linear-gradient(165deg, #0F2557 0%, #1A3C8F 60%, #2447A8 100%);
  color: #fff;
  padding: 44px 36px;
  display: flex;
  flex-direction: column;
  position: relative;
  overflow: hidden;
}
.side-panel::before {
  content: '';
  position: absolute;
  top: -90px; right: -110px;
  width: 320px; height: 320px;
  background: radial-gradient(circle, rgba(47,95,216,.35) 0%, transparent 70%);
}
.side-panel::after {
  content: '';
  position: absolute;
  bottom: -70px; left: -90px;
  width: 260px; height: 260px;
  background: radial-gradient(circle, rgba(47,95,216,.22) 0%, transparent 70%);
}

.side-panel .sp-logo {
  display: flex;
  align-items: center;
  gap: 12px;
  position: relative;
  z-index: 2;
}
.side-panel .sp-logo-slot {
  width: 38px; height: 38px;
  background: rgba(255,255,255,0.08);
  border: 1.5px dashed rgba(255,255,255,0.35);
  border-radius: 11px;
  color: rgba(255,255,255,0.6);
  font-size: 9px;
}
.side-panel .sp-name { font-size: 14px; font-weight: 800; letter-spacing: 2.5px; }
.side-panel .sp-sub { font-size: 8.5px; font-weight: 700; letter-spacing: 2px; color: rgba(255,255,255,.5); margin-top: -2px; }

.side-panel .sp-copy {
  margin-top: auto;
  position: relative;
  z-index: 2;
}
.side-panel .sp-copy h2 {
  font-size: 23px;
  font-weight: 800;
  line-height: 1.45;
  margin-bottom: 12px;
}
.side-panel .sp-copy h2 b {
  background: linear-gradient(90deg, #8FB1FF, #fff);
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
}
.side-panel .sp-copy p {
  font-size: 12.5px;
  line-height: 1.75;
  color: rgba(255,255,255,0.6);
  font-weight: 500;
}

.side-panel .sp-footer {
  position: relative;
  z-index: 2;
  font-size: 10.5px;
  color: rgba(255,255,255,.35);
  font-weight: 500;
  letter-spacing: .5px;
  margin-top: 28px;
}

.main-panel {
  display: flex;
  flex-direction: column;
  width: 100%;
  min-height: 100vh;
  background: var(--white);
}

.main-inner {
  width: 100%;
  max-width: 480px;
  margin: 0 auto;
  flex: 1;
  display: flex;
  flex-direction: column;
}

@media (max-width: 860px) {
  .app-shell { grid-template-columns: 1fr; }
  .side-panel.desktop-only { display: none; }
  .main-inner {  }
}

/* ════════════════════════════════════════════
   2. 공통 버튼
   ════════════════════════════════════════════ */
.btn {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 100%;
  padding: 16px;
  border-radius: 14px;
  font-size: 15px;
  font-weight: 700;
  cursor: pointer;
  border: none;
  transition: transform .15s ease, opacity .15s ease, box-shadow .15s ease;
  font-family: inherit;
}
.btn:active { transform: scale(0.98); }

.btn-primary {
  background: linear-gradient(135deg, var(--blue-600), var(--blue-700));
  color: #fff;
  box-shadow: 0 6px 20px rgba(26, 60, 143, 0.28);
}
.btn-primary:hover { box-shadow: 0 8px 24px rgba(26, 60, 143, 0.36); }

.btn-outline {
  background: var(--white);
  color: var(--text-700);
  border: 1.5px solid var(--border);
}
.btn-outline:hover { border-color: var(--text-300); }

.btn-kakao {
  background: var(--yellow);
  color: #181600;
}
.btn-kakao:hover { filter: brightness(1.03); }

.btn-ghost {
  background: transparent;
  color: var(--text-500);
  font-weight: 600;
  text-decoration: underline;
  text-underline-offset: 3px;
}

/* ════════════════════════════════════════════
   3. 이미지 placeholder
   ════════════════════════════════════════════ */
.img-slot {
  display: flex;
  align-items: center;
  justify-content: center;
  background: var(--blue-50);
  border: 1.5px dashed #C7D4F0;
  border-radius: 20px;
  color: var(--blue-500);
  font-size: 12px;
  font-weight: 600;
  text-align: center;
  overflow: hidden;
}
.img-slot img {
  width: 100%;
  height: 100%;
  object-fit: contain;
}

/* ════════════════════════════════════════════
   4. 유틸
   ════════════════════════════════════════════ */
.fade-up {
  animation: fadeUp .6s ease both;
}
@keyframes fadeUp {
  from { opacity: 0; transform: translateY(16px); }
  to   { opacity: 1; transform: translateY(0); }
}

.divider-row {
  display: flex;
  align-items: center;
  gap: 12px;
  margin: 4px 0;
}
.divider-row .line { flex: 1; height: 1px; background: var(--border); }
.divider-row span { font-size: 12px; color: var(--text-300); font-weight: 500; }

/* ════════════════════════════════════════════
   5. 하단 탭바 (모바일 전용, 로그인 후 모든 화면 공통)
   홈 / 자가진단 / 쇼핑 / 마이페이지
   includes/tabbar.php 에서 사용
   ════════════════════════════════════════════ */
.tabbar {
  display: none;
}

.main-panel.has-tabbar {
  min-height: 100vh;
}

@media (max-width: 860px) {
  .tabbar {
    display: flex;
    position: sticky;
    bottom: 0;
    left: 0;
    width: 100%;
    background: #ffffff;
    border-top: 1px solid var(--border);
    padding-top: 8px;
    padding-bottom: max(8px, env(safe-area-inset-bottom));
    z-index: 30;
    margin-top: auto;
  }

  .tabbar a {
    flex: 1 1 0;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 3px;
    padding: 6px 0;
    text-decoration: none;
    color: var(--text-300);
    font-size: 10.5px;
    font-weight: 600;
  }

  .tabbar a .tab-icon {
    font-size: 19px;
    line-height: 1;
  }

  .tabbar a.active {
    color: var(--blue-700);
  }
}