/* 랜딩 · 대시보드 · 에디터 공용 스타일 */
:root {
  --bg: #fdfbf7;
  --bg-alt: #f7f1e8;
  --ink: #3f3a36;
  --ink-soft: #7a726a;
  --accent: #b98a7f;
  --accent-deep: #9c6b60;
  --line: #e5dcd0;
  --white: #ffffff;
  --danger: #c0564a;
  --serif: "Gowun Batang", serif;
  --sans: "Noto Sans KR", sans-serif;
}

* { margin: 0; padding: 0; box-sizing: border-box; }

body {
  font-family: var(--sans);
  background: var(--bg);
  color: var(--ink);
  line-height: 1.7;
  -webkit-font-smoothing: antialiased;
  word-break: keep-all;
  min-height: 100vh;
}

.container {
  max-width: 640px;
  margin: 0 auto;
  padding: 0 20px 80px;
}

a { color: var(--accent-deep); }

/* ---------- 헤더 ---------- */
.topbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  max-width: 640px;
  margin: 0 auto;
  padding: 18px 20px;
}

.topbar .logo {
  font-family: var(--serif);
  font-size: 17px;
  font-weight: 700;
  color: var(--ink);
  text-decoration: none;
}

.topbar .logo .heart { color: var(--accent); }

.topbar-user {
  display: flex;
  align-items: center;
  gap: 10px;
  font-size: 13px;
  color: var(--ink-soft);
}

.topbar-user img {
  width: 30px;
  height: 30px;
  border-radius: 50%;
  border: 1px solid var(--line);
}

.topbar-user a { font-size: 12px; }

/* ---------- 버튼 ---------- */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  font-family: var(--sans);
  font-size: 15px;
  padding: 13px 28px;
  border-radius: 12px;
  border: 1px solid var(--accent);
  background: var(--accent);
  color: var(--white);
  cursor: pointer;
  text-decoration: none;
  transition: opacity 0.15s;
}

.btn:hover { opacity: 0.9; }

.btn.btn-outline {
  background: transparent;
  color: var(--accent-deep);
}

.btn.btn-ghost {
  background: transparent;
  border-color: var(--line);
  color: var(--ink-soft);
}

.btn.btn-danger {
  background: transparent;
  border-color: var(--line);
  color: var(--danger);
}

.btn.btn-google {
  background: var(--white);
  border-color: #dadce0;
  color: #3c4043;
  font-weight: 500;
}

.btn:disabled { opacity: 0.5; cursor: not-allowed; }

.btn.btn-sm { font-size: 13px; padding: 8px 16px; border-radius: 9px; }

/* ---------- 랜딩 ---------- */
.hero {
  min-height: 82vh;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
  padding: 40px 24px;
  background:
    radial-gradient(ellipse at 15% 10%, rgba(185, 138, 127, 0.10), transparent 55%),
    radial-gradient(ellipse at 85% 90%, rgba(185, 138, 127, 0.12), transparent 50%);
}

.hero-eyebrow {
  font-family: var(--serif);
  font-size: 12px;
  letter-spacing: 5px;
  color: var(--accent);
  margin-bottom: 16px;
}

.hero h1 {
  font-family: var(--serif);
  font-size: 30px;
  line-height: 1.5;
  margin-bottom: 14px;
}

.hero p.sub {
  font-size: 15px;
  color: var(--ink-soft);
  margin-bottom: 36px;
}

.hero-actions { display: flex; flex-direction: column; gap: 12px; width: 100%; max-width: 320px; }

.hero-note { margin-top: 22px; font-size: 12px; color: #b6ada2; }

/* ---------- 카드 ---------- */
.page-title {
  font-family: var(--serif);
  font-size: 22px;
  margin: 26px 0 6px;
}

.page-sub { font-size: 14px; color: var(--ink-soft); margin-bottom: 26px; }

.card {
  background: var(--white);
  border: 1px solid var(--line);
  border-radius: 16px;
  padding: 22px;
  margin-bottom: 14px;
}

.inv-card { display: flex; gap: 16px; align-items: center; }

.inv-thumb {
  flex-shrink: 0;
  width: 64px;
  height: 84px;
  border-radius: 32px 32px 6px 6px;
  background: var(--bg-alt);
  border: 1px solid var(--line);
  overflow: hidden;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--accent);
  font-size: 22px;
}

.inv-thumb img { width: 100%; height: 100%; object-fit: cover; }

.inv-info { flex: 1; min-width: 0; }

.inv-info .names { font-family: var(--serif); font-size: 17px; font-weight: 700; }

.inv-info .meta { font-size: 12.5px; color: var(--ink-soft); margin-top: 2px; }

.inv-actions { display: flex; flex-direction: column; gap: 6px; }

.empty-state {
  text-align: center;
  padding: 60px 20px;
  border: 1.5px dashed var(--line);
  border-radius: 16px;
  color: var(--ink-soft);
}

.empty-state .big { font-size: 40px; margin-bottom: 10px; }

.empty-state p { margin-bottom: 24px; font-size: 15px; }

/* ---------- 에디터 ---------- */
.steps {
  display: flex;
  gap: 4px;
  margin: 24px 0 20px;
  overflow-x: auto;
  padding-bottom: 4px;
}

.step-chip {
  flex-shrink: 0;
  font-size: 12.5px;
  padding: 7px 13px;
  border-radius: 999px;
  border: 1px solid var(--line);
  background: var(--white);
  color: var(--ink-soft);
  cursor: pointer;
}

.step-chip.active {
  background: var(--accent);
  border-color: var(--accent);
  color: var(--white);
  font-weight: 500;
}

.step-chip.done { border-color: var(--accent); color: var(--accent-deep); }

.step-panel { display: none; }
.step-panel.active { display: block; }

.step-title { font-family: var(--serif); font-size: 19px; margin-bottom: 4px; }
.step-desc { font-size: 13.5px; color: var(--ink-soft); margin-bottom: 20px; }

.form-group { margin-bottom: 16px; }

.form-label {
  display: block;
  font-size: 13px;
  font-weight: 500;
  color: var(--ink);
  margin-bottom: 6px;
}

.form-label .opt { color: #b6ada2; font-weight: 400; font-size: 12px; }

input[type="text"], input[type="tel"], input[type="date"], input[type="time"], textarea, select {
  width: 100%;
  font-family: var(--sans);
  font-size: 15px;
  padding: 11px 14px;
  border: 1px solid var(--line);
  border-radius: 10px;
  background: var(--white);
  color: var(--ink);
  outline: none;
}

input:focus, textarea:focus, select:focus { border-color: var(--accent); }

textarea { resize: vertical; min-height: 140px; line-height: 1.9; }

.form-row { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
.form-row-3 { display: grid; grid-template-columns: 1fr 1fr 1fr; gap: 10px; }

.form-section-title {
  font-size: 14px;
  font-weight: 700;
  color: var(--accent-deep);
  margin: 26px 0 12px;
  padding-bottom: 8px;
  border-bottom: 1px solid var(--line);
}

.form-section-title:first-child { margin-top: 0; }

.editor-nav {
  display: flex;
  justify-content: space-between;
  gap: 10px;
  margin-top: 24px;
}

.editor-nav .btn { flex: 1; }

.save-status {
  text-align: center;
  font-size: 12px;
  color: #b6ada2;
  margin-top: 12px;
  min-height: 18px;
}

/* ---------- 업로드 ---------- */
.upload-box {
  border: 1.5px dashed var(--line);
  border-radius: 14px;
  padding: 28px 16px;
  text-align: center;
  color: var(--ink-soft);
  font-size: 14px;
  cursor: pointer;
  transition: border-color 0.15s, background 0.15s;
  background: var(--white);
}

.upload-box:hover { border-color: var(--accent); background: #fffdfa; }

.upload-box .icon { font-size: 26px; display: block; margin-bottom: 6px; }

.cover-preview {
  position: relative;
  width: 170px;
  margin: 0 auto 12px;
}

.cover-preview img {
  width: 170px;
  height: 224px;
  object-fit: cover;
  border-radius: 85px 85px 8px 8px;
  border: 1px solid var(--line);
}

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

.thumb {
  position: relative;
  aspect-ratio: 3 / 4;
  border-radius: 10px;
  overflow: hidden;
  border: 1px solid var(--line);
}

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

.thumb-remove {
  position: absolute;
  top: 5px;
  right: 5px;
  width: 24px;
  height: 24px;
  border-radius: 50%;
  border: none;
  background: rgba(40, 34, 30, 0.65);
  color: #fff;
  font-size: 14px;
  line-height: 1;
  cursor: pointer;
}

.upload-progress { font-size: 12.5px; color: var(--accent-deep); margin-top: 10px; min-height: 18px; }

/* ---------- 완료 단계 ---------- */
.share-box {
  background: var(--bg-alt);
  border: 1px solid var(--line);
  border-radius: 12px;
  padding: 14px;
  display: flex;
  gap: 8px;
  align-items: center;
  margin: 14px 0;
}

.share-box input {
  flex: 1;
  border: none;
  background: transparent;
  font-size: 13px;
  color: var(--ink-soft);
  padding: 0;
}

/* ---------- 토스트 ---------- */
.toast {
  position: fixed;
  left: 50%;
  bottom: 36px;
  transform: translate(-50%, 20px);
  background: rgba(50, 42, 38, 0.92);
  color: #fff;
  font-size: 13px;
  padding: 11px 22px;
  border-radius: 999px;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.25s, transform 0.25s;
  z-index: 120;
}

.toast.show { opacity: 1; transform: translate(-50%, 0); }

.hidden { display: none !important; }
