:root {
  --bg: #fbf6ef;
  --bg-soft: #f5ece0;
  --surface: #ffffff;
  --surface-warm: #fffaf3;
  --ink: #4b3a33;
  --ink-soft: #7a665d;
  --ink-mute: #a6948b;
  --line: #ecdfd0;
  --pink: #f7c3cf;
  --pink-deep: #e29aaa;
  --pink-soft: #fde6ec;
  --mint: #b9e3d4;
  --mint-deep: #7fc0aa;
  --mint-soft: #e2f4ec;
  --warn: #e6b7af;
  --warn-deep: #b8554a;
  --warn-soft: #fbeae5;
  --shadow-sm: 0 2px 6px rgba(102, 78, 64, 0.06);
  --shadow-md: 0 6px 20px rgba(102, 78, 64, 0.08);
  --shadow-lg: 0 14px 40px rgba(102, 78, 64, 0.12);
  --radius-sm: 12px;
  --radius-md: 18px;
  --radius-lg: 26px;
}

* { box-sizing: border-box; }

html, body {
  margin: 0;
  padding: 0;
  background: var(--bg);
  color: var(--ink);
  font-family: 'Noto Sans KR', -apple-system, BlinkMacSystemFont, 'Apple SD Gothic Neo', sans-serif;
  font-size: 15px;
  line-height: 1.65;
  letter-spacing: -0.01em;
  -webkit-font-smoothing: antialiased;
  min-height: 100vh;
}

body {
  background:
    radial-gradient(circle at 8% 5%, #fde6ec 0%, transparent 38%),
    radial-gradient(circle at 95% 10%, #e2f4ec 0%, transparent 35%),
    radial-gradient(circle at 50% 100%, #f5ece0 0%, transparent 55%),
    var(--bg);
}

.bg-decor {
  position: fixed;
  inset: 0;
  z-index: 0;
  pointer-events: none;
  overflow: hidden;
}
.bg-decor .dot {
  position: absolute;
  border-radius: 50%;
  filter: blur(40px);
  opacity: 0.55;
}
.dot-1 { width: 220px; height: 220px; background: #fbd5dc; top: 8%; left: -60px; }
.dot-2 { width: 260px; height: 260px; background: #cde9dd; top: 30%; right: -80px; }
.dot-3 { width: 180px; height: 180px; background: #f5ece0; bottom: 8%; left: 12%; }
.dot-4 { width: 200px; height: 200px; background: #fde6ec; bottom: 14%; right: 20%; }

.topbar {
  position: relative;
  z-index: 1;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding: 24px clamp(20px, 5vw, 56px) 8px;
  max-width: 1100px;
  margin: 0 auto;
}
.brand { display: flex; align-items: center; gap: 14px; }
.brand-icon {
  width: 56px; height: 56px;
  border-radius: 18px;
  background: var(--surface);
  display: grid; place-items: center;
  box-shadow: var(--shadow-sm);
  border: 1px solid var(--line);
}
.brand-text h1 {
  margin: 0;
  font-family: 'Gaegu', 'Noto Sans KR', sans-serif;
  font-size: 26px;
  font-weight: 700;
  letter-spacing: -0.02em;
  color: var(--ink);
}
.brand-text p {
  margin: 2px 0 0;
  color: var(--ink-soft);
  font-size: 13px;
}

.container {
  position: relative;
  z-index: 1;
  max-width: 1100px;
  margin: 0 auto;
  padding: 24px clamp(20px, 5vw, 56px) 60px;
}

/* === 우리집 토끼 카드 === */
.rabbit-card {
  background: linear-gradient(135deg, #fffaf3 0%, #fdf3ec 100%);
  border-radius: var(--radius-lg);
  border: 1px solid var(--line);
  box-shadow: var(--shadow-md);
  padding: 28px 28px;
  margin-bottom: 28px;
  position: relative;
  overflow: hidden;
}
.rabbit-card::before {
  content: '';
  position: absolute;
  right: -40px; top: -40px;
  width: 180px; height: 180px;
  background: radial-gradient(circle, var(--pink-soft) 0%, transparent 70%);
}
.rabbit-card-inner {
  position: relative;
  display: flex;
  align-items: center;
  gap: 20px;
  flex-wrap: wrap;
}
.rabbit-illu {
  width: 80px; height: 80px;
  border-radius: 50%;
  background: var(--pink-soft);
  display: grid; place-items: center;
  box-shadow: inset 0 0 0 6px #fff;
  flex-shrink: 0;
}
.rabbit-illu-lg {
  width: 96px; height: 96px;
  background: linear-gradient(135deg, var(--pink-soft) 0%, var(--mint-soft) 100%);
}
.rabbit-empty-text { flex: 1; min-width: 200px; }
.rabbit-empty-text h2 {
  margin: 0 0 4px;
  font-size: 20px;
  color: var(--ink);
}
.rabbit-empty-text p {
  margin: 0;
  color: var(--ink-soft);
  font-size: 14px;
}

.rabbit-info { flex: 1; min-width: 220px; }
.rabbit-greet {
  display: inline-block;
  font-size: 13px;
  color: var(--ink-soft);
  margin-bottom: 6px;
}
.rabbit-name {
  margin: 0 0 10px;
  font-family: 'Gaegu', 'Noto Sans KR', sans-serif;
  font-size: 30px;
  font-weight: 700;
  color: var(--ink);
  letter-spacing: -0.02em;
}
.rabbit-meta {
  display: flex; gap: 8px; flex-wrap: wrap;
  margin-bottom: 10px;
}
.meta-chip {
  display: inline-flex;
  align-items: center;
  padding: 4px 12px;
  background: var(--pink-soft);
  color: var(--pink-deep);
  border-radius: 999px;
  font-size: 13px;
  font-weight: 500;
}
.meta-chip.muted {
  background: var(--mint-soft);
  color: var(--mint-deep);
}
.rabbit-tagline {
  margin: 0;
  color: var(--ink-soft);
  font-size: 13px;
}

/* === 버튼 === */
.primary-btn {
  background: var(--pink-deep);
  color: #fff;
  border: none;
  padding: 10px 22px;
  border-radius: 999px;
  font-size: 14px;
  font-weight: 600;
  cursor: pointer;
  transition: transform 0.15s ease, box-shadow 0.2s ease, background 0.2s ease;
  box-shadow: 0 4px 12px rgba(226, 154, 170, 0.35);
  font-family: inherit;
}
.primary-btn:hover { background: #d88898; transform: translateY(-2px); box-shadow: 0 8px 18px rgba(226, 154, 170, 0.4); }
.primary-btn:active { transform: translateY(0); }

.ghost-btn {
  background: var(--surface);
  color: var(--ink);
  border: 1px solid var(--line);
  padding: 9px 18px;
  border-radius: 999px;
  font-size: 14px;
  font-weight: 500;
  cursor: pointer;
  transition: all 0.18s ease;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-family: inherit;
}
.ghost-btn:hover { background: var(--bg-soft); border-color: var(--pink); color: var(--pink-deep); }
.ghost-btn.small { padding: 7px 14px; font-size: 13px; }
.btn-ico { font-size: 16px; line-height: 1; color: var(--pink-deep); font-weight: 700; }

.icon-btn {
  background: transparent;
  border: none;
  color: var(--ink-mute);
  width: 32px; height: 32px;
  border-radius: 50%;
  cursor: pointer;
  font-size: 16px;
  transition: all 0.15s ease;
}
.icon-btn:hover { background: var(--bg-soft); color: var(--ink); }

/* === 탭 === */
.tabs {
  display: flex;
  gap: 6px;
  background: var(--surface);
  padding: 6px;
  border-radius: 999px;
  border: 1px solid var(--line);
  box-shadow: var(--shadow-sm);
  margin-bottom: 24px;
  overflow-x: auto;
  scrollbar-width: none;
}
.tabs::-webkit-scrollbar { display: none; }
.tab {
  flex: 1;
  min-width: max-content;
  background: transparent;
  border: none;
  color: var(--ink-soft);
  padding: 10px 18px;
  border-radius: 999px;
  font-size: 14px;
  font-weight: 500;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  transition: all 0.2s ease;
  font-family: inherit;
  white-space: nowrap;
}
.tab:hover { color: var(--ink); background: var(--bg-soft); }
.tab.active {
  background: linear-gradient(135deg, var(--pink-soft), var(--mint-soft));
  color: var(--ink);
  font-weight: 600;
  box-shadow: var(--shadow-sm);
}
.tab.active .tab-ico { color: var(--pink-deep); }
.tab-ico { display: inline-flex; color: var(--ink-mute); }

/* === 패널 + 페이드 트랜지션 === */
.panel {
  display: none;
  opacity: 0;
  transform: translateY(8px);
  transition: opacity 0.35s ease, transform 0.35s ease;
}
.panel.active {
  display: block;
  opacity: 1;
  transform: translateY(0);
  animation: fadeUp 0.35s ease;
}
@keyframes fadeUp {
  from { opacity: 0; transform: translateY(10px); }
  to { opacity: 1; transform: translateY(0); }
}
.panel-header { margin-bottom: 18px; }
.panel-header h2 {
  margin: 0 0 6px;
  font-size: 22px;
  color: var(--ink);
  letter-spacing: -0.02em;
}
.panel-header p {
  margin: 0;
  color: var(--ink-soft);
  font-size: 14px;
  max-width: 640px;
}

/* === 카드 그리드 === */
.card-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
  gap: 16px;
  margin-bottom: 20px;
}
.info-card {
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius-md);
  padding: 22px 22px 20px;
  box-shadow: var(--shadow-sm);
  transition: transform 0.25s ease, box-shadow 0.25s ease, border-color 0.25s ease;
  position: relative;
  overflow: hidden;
}
.info-card::after {
  content: '';
  position: absolute;
  inset: 0;
  border-radius: var(--radius-md);
  background: linear-gradient(135deg, transparent 60%, var(--pink-soft) 100%);
  opacity: 0;
  transition: opacity 0.3s ease;
  pointer-events: none;
}
.info-card:hover {
  transform: translateY(-4px);
  box-shadow: var(--shadow-lg);
  border-color: var(--pink);
}
.info-card:hover::after { opacity: 0.45; }
.info-card > * { position: relative; z-index: 1; }
.card-icon {
  width: 44px; height: 44px;
  border-radius: 14px;
  background: var(--pink-soft);
  display: grid; place-items: center;
  color: var(--pink-deep);
  margin-bottom: 12px;
}
.info-card.mint .card-icon { background: var(--mint-soft); color: var(--mint-deep); }
.info-card.warm .card-icon { background: #fff0e6; color: #d99272; }
.card-title {
  margin: 0 0 6px;
  font-size: 16px;
  font-weight: 700;
  color: var(--ink);
}
.card-sub {
  font-size: 12px;
  color: var(--ink-mute);
  margin-bottom: 10px;
  font-weight: 500;
  letter-spacing: 0.02em;
}
.card-desc {
  margin: 0 0 12px;
  font-size: 13.5px;
  color: var(--ink-soft);
  line-height: 1.65;
}
.card-meta-row {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
}
.tag {
  display: inline-flex;
  align-items: center;
  padding: 3px 10px;
  background: var(--bg-soft);
  color: var(--ink-soft);
  border-radius: 999px;
  font-size: 12px;
  font-weight: 500;
}
.tag.pink { background: var(--pink-soft); color: var(--pink-deep); }
.tag.mint { background: var(--mint-soft); color: var(--mint-deep); }
.tag.warm { background: #fff0e6; color: #c4825f; }

/* === 경고 카드 === */
.warn-card {
  display: flex;
  gap: 14px;
  align-items: flex-start;
  background: var(--warn-soft);
  border: 1px solid var(--warn);
  border-radius: var(--radius-md);
  padding: 18px 20px;
  margin-bottom: 20px;
}
.warn-card strong {
  display: block;
  color: var(--warn-deep);
  font-size: 15px;
  margin-bottom: 4px;
}
.warn-card p {
  margin: 0;
  color: #8a4a40;
  font-size: 13.5px;
}
.warn-ico {
  flex-shrink: 0;
  width: 36px; height: 36px;
  background: #fff;
  border-radius: 12px;
  display: grid; place-items: center;
}

/* === 위험 증상 카드 === */
.warning-grid .info-card {
  border-color: var(--warn);
  background: #fffaf8;
}
.warning-grid .info-card .card-icon {
  background: var(--warn-soft);
  color: var(--warn-deep);
}
.warning-grid .info-card:hover { border-color: var(--warn-deep); }

/* === 노트 박스 === */
.note-box {
  background: var(--surface-warm);
  border: 1px dashed var(--line);
  border-radius: var(--radius-md);
  padding: 16px 20px;
  color: var(--ink-soft);
  font-size: 13px;
}
.note-box strong { display: block; color: var(--ink); margin-bottom: 4px; font-size: 14px; }
.note-box p { margin: 0; }

/* === 체크리스트 === */
.checklist-card {
  background: linear-gradient(135deg, var(--mint-soft) 0%, var(--pink-soft) 100%);
  border-radius: var(--radius-md);
  padding: 22px;
  margin-top: 8px;
  border: 1px solid var(--line);
}
.checklist-card h3 {
  margin: 0 0 4px;
  font-size: 17px;
  color: var(--ink);
}
.checklist-help {
  margin: 0 0 14px;
  font-size: 12.5px;
  color: var(--ink-soft);
}
.checklist {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(220px, 1fr));
  gap: 8px;
}
.checklist li {
  background: rgba(255, 255, 255, 0.7);
  border-radius: 12px;
  padding: 10px 14px;
  display: flex;
  align-items: center;
  gap: 10px;
  cursor: pointer;
  transition: background 0.18s ease, transform 0.15s ease;
  font-size: 13.5px;
  color: var(--ink);
  user-select: none;
}
.checklist li:hover { background: #fff; transform: translateY(-1px); }
.checklist li .check-box {
  width: 20px; height: 20px;
  border-radius: 7px;
  border: 2px solid var(--pink-deep);
  background: #fff;
  display: grid; place-items: center;
  flex-shrink: 0;
  transition: all 0.18s ease;
}
.checklist li.done .check-box {
  background: var(--pink-deep);
  border-color: var(--pink-deep);
}
.checklist li.done .check-box::after {
  content: '';
  width: 6px; height: 10px;
  border: solid #fff;
  border-width: 0 2px 2px 0;
  transform: rotate(45deg) translate(-1px, -1px);
}
.checklist li.done span.label {
  text-decoration: line-through;
  color: var(--ink-mute);
}

/* === 모달 === */
.modal-backdrop {
  position: fixed;
  inset: 0;
  background: rgba(70, 55, 48, 0.35);
  backdrop-filter: blur(4px);
  z-index: 50;
  display: grid;
  place-items: center;
  padding: 20px;
  animation: backdropIn 0.2s ease;
}
@keyframes backdropIn { from { opacity: 0; } to { opacity: 1; } }
.modal {
  background: var(--surface);
  border-radius: var(--radius-lg);
  width: 100%;
  max-width: 420px;
  box-shadow: var(--shadow-lg);
  overflow: hidden;
  animation: modalIn 0.25s cubic-bezier(0.2, 0.8, 0.2, 1);
}
@keyframes modalIn {
  from { opacity: 0; transform: translateY(20px) scale(0.96); }
  to { opacity: 1; transform: translateY(0) scale(1); }
}
.modal-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 20px 24px 8px;
}
.modal-header h2 {
  margin: 0;
  font-size: 18px;
  color: var(--ink);
}
.modal-body {
  padding: 12px 24px 24px;
  display: flex;
  flex-direction: column;
  gap: 14px;
}
.field {
  display: flex;
  flex-direction: column;
  gap: 6px;
  font-size: 13px;
  color: var(--ink-soft);
  font-weight: 500;
}
.field input {
  border: 1.5px solid var(--line);
  background: var(--surface-warm);
  padding: 12px 14px;
  border-radius: 12px;
  font-size: 14.5px;
  color: var(--ink);
  font-family: inherit;
  transition: all 0.18s ease;
}
.field input:focus {
  outline: none;
  border-color: var(--pink-deep);
  background: #fff;
  box-shadow: 0 0 0 4px var(--pink-soft);
}
.field-hint {
  font-size: 11.5px;
  color: var(--ink-mute);
  font-weight: 400;
}
.modal-actions {
  display: flex;
  gap: 10px;
  justify-content: flex-end;
  margin-top: 6px;
}

/* === 토스트 === */
.toast {
  position: fixed;
  bottom: 28px;
  left: 50%;
  transform: translateX(-50%);
  background: var(--ink);
  color: #fff;
  padding: 12px 22px;
  border-radius: 999px;
  font-size: 13.5px;
  box-shadow: var(--shadow-lg);
  z-index: 60;
  animation: toastIn 0.25s ease;
}
@keyframes toastIn {
  from { opacity: 0; transform: translate(-50%, 12px); }
  to { opacity: 1; transform: translate(-50%, 0); }
}

/* === 푸터 === */
.footer {
  text-align: center;
  padding: 24px 20px 40px;
  color: var(--ink-mute);
  font-size: 12px;
  position: relative;
  z-index: 1;
}
.footer p { margin: 0; }

/* === 반응형 === */
@media (max-width: 600px) {
  .topbar { padding: 18px 18px 4px; flex-wrap: wrap; }
  .brand-text h1 { font-size: 22px; }
  .brand-text p { font-size: 12px; }
  .container { padding: 18px 18px 50px; }
  .rabbit-card { padding: 22px 20px; }
  .rabbit-card-inner { gap: 14px; }
  .rabbit-name { font-size: 26px; }
  .panel-header h2 { font-size: 19px; }
  .tabs { padding: 5px; }
  .tab { padding: 9px 14px; font-size: 13px; }
}
