:root {
  --cream: #fff8f2;
  --paper: #fffdf8;
  --blush: #f47f8f;
  --rose: #d95670;
  --lavender: #9a8af6;
  --mint: #8bd5c0;
  --ink: #27222b;
  --muted: #7a737c;
  --line: rgba(39, 34, 43, 0.1);
  --shadow: 0 24px 70px rgba(128, 88, 96, 0.16);
}

.pregnancy-section {
  border-top: 1px solid rgba(244, 127, 143, 0.14);
}

.pregnancy-heading {
  align-items: flex-end;
}

.pregnancy-layout {
  display: grid;
  grid-template-columns: minmax(0, 1.35fr) minmax(320px, 0.65fr);
  gap: 24px;
  align-items: start;
}

.pregnancy-form,
.pregnancy-preview {
  border: 1px solid var(--line);
  border-radius: 28px;
  background: rgba(255, 255, 255, 0.76);
  box-shadow: var(--shadow);
  backdrop-filter: blur(18px);
}

.pregnancy-form {
  display: grid;
  gap: 18px;
  padding: 28px;
}

.pregnancy-form-head h3,
.pregnancy-preview h3 {
  margin: 0 0 8px;
  font-size: clamp(1.3rem, 3vw, 1.8rem);
  letter-spacing: 0;
}

.pregnancy-form-head p,
.pregnancy-preview p {
  margin: 0;
  color: var(--muted);
  line-height: 1.65;
  word-break: keep-all;
}

.compact-head {
  padding-top: 6px;
}

.profile-fieldset {
  display: grid;
  gap: 16px;
  margin: 0;
  padding: 18px;
  border: 1px solid rgba(244, 127, 143, 0.18);
  border-radius: 22px;
  background: rgba(255, 246, 248, 0.72);
}

.profile-fieldset legend {
  padding: 0 8px;
  color: var(--rose);
  font-weight: 900;
}

.profile-fieldset-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}

.profile-fieldset-head p {
  margin: 0;
  color: var(--muted);
  line-height: 1.55;
  word-break: keep-all;
}

.mini-edit-btn {
  min-width: 64px;
  border: 0;
  border-radius: 999px;
  padding: 10px 14px;
  background: #fff;
  color: var(--rose);
  font-weight: 900;
  cursor: pointer;
  box-shadow: 0 10px 24px rgba(244, 127, 143, 0.14);
}

.fixed-profile-grid.is-locked {
  opacity: 0.68;
}

.fixed-profile-grid input:disabled,
.fixed-profile-grid select:disabled {
  background: rgba(255, 255, 255, 0.66);
  color: var(--ink);
}

.pregnancy-grid {
  grid-template-columns: repeat(3, minmax(0, 1fr));
}

.condition-field {
  margin: 0;
  padding: 18px;
  border: 1px solid var(--line);
  border-radius: 22px;
  background: rgba(255, 248, 247, 0.72);
}

.condition-field legend {
  padding: 0 8px;
  font-weight: 900;
}

.check-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 10px;
}

.check-grid label {
  min-height: 0;
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 12px 14px;
  border-radius: 16px;
  background: #fff;
  color: var(--ink);
  font-size: 0.9rem;
  font-weight: 800;
}

.check-grid input {
  width: 18px;
  height: 18px;
  margin: 0;
  flex: 0 0 auto;
  accent-color: var(--blush);
}

.pregnancy-preview {
  position: sticky;
  top: 104px;
  padding: 24px;
}

.pregnancy-list {
  display: grid;
  gap: 14px;
  margin-top: 18px;
}

.pregnancy-record-card {
  display: grid;
  gap: 12px;
  padding: 18px;
  border: 1px solid rgba(244, 127, 143, 0.18);
  border-radius: 22px;
  background: linear-gradient(145deg, #fff, #fff6f7);
}

.pregnancy-record-card > div:first-child {
  display: flex;
  justify-content: space-between;
  gap: 10px;
  color: var(--rose);
  font-size: 0.82rem;
  font-weight: 900;
}

.pregnancy-record-card h4,
.pregnancy-record-card p,
.pregnancy-record-card dl,
.pregnancy-record-card blockquote {
  margin: 0;
}

.pregnancy-record-card p,
.pregnancy-record-card blockquote {
  color: var(--muted);
  line-height: 1.6;
  word-break: keep-all;
}

.pregnancy-record-card dl {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 8px;
}

.pregnancy-record-card dl div {
  padding: 10px;
  border-radius: 14px;
  background: rgba(255, 255, 255, 0.78);
}

.pregnancy-record-card dt {
  color: var(--muted);
  font-size: 0.74rem;
  font-weight: 800;
}

.pregnancy-record-card dd {
  margin: 3px 0 0;
  font-size: 0.88rem;
  font-weight: 900;
}

.pregnancy-record-card blockquote {
  padding-left: 12px;
  border-left: 3px solid var(--lavender);
}

.pregnancy-product {
  border-color: rgba(244, 127, 143, 0.34);
  background: linear-gradient(160deg, rgba(255,255,255,0.95), rgba(255,238,242,0.94));
}

@media (max-width: 920px) {
  .pregnancy-layout {
    grid-template-columns: 1fr;
  }

  .pregnancy-preview {
    position: static;
  }

  .pregnancy-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .check-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (max-width: 640px) {
  .pregnancy-heading {
    align-items: flex-start;
  }

  .pregnancy-form,
  .pregnancy-preview {
    padding: 18px;
    border-radius: 24px;
  }

  .pregnancy-grid,
  .check-grid,
  .pregnancy-record-card dl {
    grid-template-columns: 1fr;
  }

  .pregnancy-section {
    padding-block: 54px;
  }

  .check-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (max-width: 640px) {
  .check-grid {
    grid-template-columns: 1fr;
    gap: 8px;
  }

  .check-grid label {
    padding: 10px 12px;
    font-size: 0.88rem;
  }
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
html { scroll-padding-top: 96px; }
body {
  margin: 0;
  color: var(--ink);
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", "Noto Sans KR", sans-serif;
  overflow-x: hidden;
  background:
    radial-gradient(circle at 8% 7%, rgba(244, 127, 143, 0.22), transparent 28%),
    radial-gradient(circle at 90% 16%, rgba(154, 138, 246, 0.18), transparent 28%),
    linear-gradient(180deg, var(--cream), #fff 46%, #fff6f8);
}
main {
  padding-top: 78px;
}
a { color: inherit; text-decoration: none; }
button, input, select, textarea { font: inherit; }
h1, h2, h3, p, strong, span, a, button, label {
  overflow-wrap: anywhere;
  word-break: keep-all;
}

.site-header {
  position: fixed;
  inset: 0 0 auto;
  z-index: 30;
  transition: background 0.25s ease, box-shadow 0.25s ease, border-color 0.25s ease;
  border-bottom: 1px solid transparent;
}
.site-header.scrolled {
  background: rgba(255, 250, 246, 0.82);
  border-color: var(--line);
  box-shadow: 0 12px 32px rgba(80, 57, 65, 0.08);
  backdrop-filter: blur(18px);
}
.nav {
  width: min(1180px, calc(100% - 40px));
  height: 74px;
  margin: 0 auto;
  display: flex;
  align-items: center;
  justify-content: space-between;
}
.logo {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 60px;
  height: 60px;
  overflow: hidden;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.86);
  box-shadow: 0 10px 28px rgba(128, 88, 96, 0.12);
}
.logo img {
  width: 92%;
  height: 92%;
  object-fit: contain;
  object-position: center;
  mix-blend-mode: multiply;
}
.nav-menu { display: flex; gap: 28px; color: #534c57; font-weight: 800; }
.nav-menu a { transition: color 0.2s ease, transform 0.2s ease; }
.nav-menu a:hover { color: var(--rose); transform: translateY(-1px); }
[hidden] {
  display: none !important;
}
body:not(.is-logged-in) .auth-only,
body:not(.is-logged-in) .auth-required-link {
  display: none !important;
}

body:not(.is-logged-in) .auth-box {
  display: none !important;
}

body.is-logged-in .public-only {
  display: none !important;
}
.auth-box {
  display: flex;
  gap: 8px;
  align-items: center;
}
.auth-box span {
  max-width: 120px;
  color: var(--muted);
  font-size: 0.82rem;
  font-weight: 900;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.auth-btn {
  min-height: 38px;
  padding: 0 13px;
  border: 0;
  border-radius: 999px;
  color: #fff;
  background: var(--ink);
  cursor: pointer;
  font-size: 0.86rem;
  font-weight: 950;
}
.auth-btn.ghost {
  color: var(--ink);
  background: rgba(255, 255, 255, 0.85);
  border: 1px solid var(--line);
}
.menu-toggle {
  display: none;
  width: 42px;
  height: 42px;
  border: 0;
  border-radius: 50%;
  background: #fff;
  box-shadow: 0 10px 26px rgba(128, 88, 96, 0.12);
}
.menu-toggle span {
  display: block;
  width: 18px;
  height: 2px;
  margin: 4px auto;
  border-radius: 2px;
  background: var(--ink);
}

.section { width: min(1180px, calc(100% - 40px)); margin: 0 auto; }
.hero {
  min-height: 760px;
  padding: 72px 0 76px;
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(340px, 0.72fr);
  gap: 58px;
  align-items: center;
}
.eyebrow {
  display: inline-flex;
  margin-bottom: 15px;
  color: var(--rose);
  font-size: 0.78rem;
  font-weight: 950;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}
h1, h2, p { letter-spacing: 0; }
.hero h1 {
  max-width: 780px;
  margin: 0;
  font-size: clamp(3rem, 7vw, 5.7rem);
  line-height: 1;
  text-wrap: balance;
}
.hero-lead {
  margin: 24px 0 8px;
  font-size: clamp(1.25rem, 2.2vw, 1.85rem);
  font-weight: 900;
}
.hero-sub {
  max-width: 610px;
  margin: 0 0 32px;
  color: var(--muted);
  font-size: 1.08rem;
  line-height: 1.8;
}
.hero-actions, .form-actions { display: flex; flex-wrap: wrap; gap: 12px; }
.btn {
  min-height: 52px;
  padding: 0 22px;
  border: 0;
  border-radius: 999px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  font-weight: 950;
  transition: transform 0.2s ease, box-shadow 0.2s ease, background 0.2s ease;
}
.btn:hover { transform: translateY(-2px); }
.btn:active, .scale-click { transform: scale(0.97); }
.btn-primary {
  color: #fff;
  background: linear-gradient(135deg, var(--blush), var(--lavender));
  box-shadow: 0 16px 38px rgba(244, 127, 143, 0.28);
}
.btn-secondary {
  color: var(--ink);
  background: rgba(255, 255, 255, 0.84);
  border: 1px solid var(--line);
}

.book-hero {
  position: relative;
  min-height: 500px;
  display: grid;
  place-items: center;
}
.book-cover {
  width: min(360px, 86vw);
  aspect-ratio: 0.72;
  padding: 24px 24px 26px;
  border-radius: 18px 32px 32px 18px;
  color: #fff;
  background:
    linear-gradient(135deg, rgba(255,255,255,0.16), transparent 42%),
    linear-gradient(145deg, #f47f8f, #9a8af6);
  box-shadow: var(--shadow);
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  transform: rotate(-3deg);
}
.book-cover span, .book-cover em { font-weight: 900; opacity: 0.92; font-style: normal; }
.book-cover strong { font-size: clamp(1.8rem, 3.6vw, 2.7rem); line-height: 1.14; }
.cover-topline,
.cover-bottomline {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}
.cover-script {
  font-family: "Comic Sans MS", "Segoe Print", cursive;
  font-size: 1rem;
  letter-spacing: 0.01em;
}
.cover-photo-frame {
  position: relative;
  margin: 18px 0;
  border-radius: 26px;
  overflow: hidden;
  background: rgba(255,255,255,0.16);
  box-shadow:
    inset 0 0 0 1px rgba(255,255,255,0.24),
    0 18px 38px rgba(72, 39, 69, 0.22);
}
.cover-photo-frame img {
  width: 100%;
  aspect-ratio: 1 / 1.05;
  display: block;
  object-fit: cover;
  object-position: center;
}
.cover-sticker {
  position: absolute;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 8px 12px;
  border-radius: 999px;
  color: var(--ink);
  background: rgba(255,255,255,0.88);
  box-shadow: 0 14px 28px rgba(72, 39, 69, 0.18);
  font-size: 0.82rem;
  font-weight: 950;
}
.sticker-heart {
  top: 14px;
  right: 14px;
  color: #ef6f96;
  font-family: "Comic Sans MS", "Segoe Print", cursive;
}
.sticker-day {
  left: 14px;
  bottom: 14px;
}
.cover-copy-block p {
  margin: 12px 0 0;
  color: rgba(255,255,255,0.88);
  line-height: 1.65;
  font-size: 0.94rem;
  word-break: keep-all;
}
.cover-chip {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 34px;
  padding: 0 12px;
  border-radius: 999px;
  background: rgba(255,255,255,0.2);
  box-shadow: inset 0 0 0 1px rgba(255,255,255,0.18);
}
.floating-note {
  position: absolute;
  padding: 14px 18px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.88);
  box-shadow: 0 16px 42px rgba(128, 88, 96, 0.16);
  font-weight: 950;
}
.note-one { left: 0; top: 80px; }
.note-two { right: 4px; bottom: 90px; }

.section-heading { margin-bottom: 28px; }
.section-heading h2, .book-copy h2, .bottom-cta h2 {
  margin: 0;
  font-size: clamp(2rem, 4vw, 3rem);
  line-height: 1.15;
}
.section-heading p, .book-copy p {
  color: var(--muted);
  line-height: 1.8;
}
.diary-section, .timeline-section, .ebook-section, .book-section, .sample-diary-section, .sticker-section, .sales-section, .review-section, .bottom-cta { padding: 74px 0; }
.diary-form, .book-section, .dashboard article, .review-grid article, .timeline-item {
  border: 1px solid rgba(255, 255, 255, 0.72);
  background: rgba(255, 255, 255, 0.82);
  box-shadow: 0 18px 54px rgba(128, 88, 96, 0.11);
}
.diary-form {
  padding: clamp(20px, 4vw, 34px);
  border-radius: 30px;
}
.diary-form-shell {
  display: flex;
  justify-content: center;
}
.diary-form-panel {
  display: flex;
  width: min(100%, 720px);
}
.diary-mobile-composer {
  width: 100%;
  padding: 18px;
  border-radius: 34px;
  background: rgba(255,255,255,0.94);
  box-shadow: 0 22px 52px rgba(128, 88, 96, 0.16);
}
.composer-preview-card {
  display: grid;
  gap: 14px;
  margin-bottom: 18px;
}
.composer-photo-frame {
    position: relative;
    border-radius: 22px;
    overflow: hidden;
    background: linear-gradient(145deg, #fff9fa, #fffdf8);
    box-shadow: inset 0 0 0 1px rgba(39,34,43,0.06), 0 16px 34px rgba(128,88,96,0.12);
    min-height: 280px;
  }
.composer-photo-frame img {
    width: 100%;
    aspect-ratio: 1 / 0.8;
    display: block;
    object-fit: cover;
  }
.composer-photo-empty {
    min-height: 280px;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 24px;
    text-align: center;
    color: var(--muted);
    font-weight: 800;
    line-height: 1.7;
  }
.composer-input-card {
  padding: 16px;
  border: 1px solid rgba(39,34,43,0.08);
  border-radius: 22px;
  background: linear-gradient(145deg, rgba(255,255,255,0.98), rgba(255,248,250,0.94));
}
.composer-meta-row {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}
.composer-hashtag {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 28px;
  padding: 0 10px;
  border-radius: 999px;
  color: var(--rose);
  background: rgba(255, 241, 245, 0.92);
  font-size: 0.74rem;
  font-weight: 950;
}
.composer-preview-text {
  margin: 12px 0 10px;
  color: var(--ink);
  line-height: 1.7;
  word-break: keep-all;
}
.composer-counter {
  color: var(--muted);
  font-size: 0.78rem;
  font-weight: 900;
  text-align: right;
}
.form-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 14px;
}
label {
  display: grid;
  gap: 8px;
  color: #514b55;
  font-weight: 900;
}
.story-label-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}
.story-action-group {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 8px;
  justify-content: stretch;
}
.ai-draft-btn {
  min-height: 38px;
  width: 100%;
  padding: 0 14px;
  border-radius: 999px;
  font-size: 0.82rem;
  font-weight: 950;
  white-space: normal;
}
.ai-draft-remove-btn {
  background: rgba(255,255,255,0.82);
}
input, select, textarea {
  width: 100%;
  border: 1px solid var(--line);
  border-radius: 18px;
  background: rgba(255, 253, 249, 0.88);
  outline: 0;
  color: var(--ink);
}
input, select { height: 48px; padding: 0 16px; }
textarea { resize: vertical; padding: 16px; line-height: 1.7; }
.photo-uploader {
  margin: 16px 0;
  min-height: 96px;
  padding: 18px;
  border: 1px dashed rgba(217, 86, 112, 0.35);
  border-radius: 24px;
  display: grid;
  gap: 14px;
  color: var(--rose);
  background: rgba(255, 246, 248, 0.72);
}
.photo-uploader-title {
  font-weight: 900;
}
.photo-uploader-actions {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 10px;
}
.photo-option-btn {
  min-height: 52px;
  padding-inline: 10px;
}
.photo-uploader input { display: none; }
.photo-uploader small { color: var(--muted); font-weight: 700; }
.composer-toolbar {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin: 16px 0 0;
  padding-top: 12px;
  border-top: 1px solid rgba(39,34,43,0.06);
}
.composer-action-btn {
  flex: 1 1 180px;
  min-height: 46px;
  font-size: 0.92rem;
  font-weight: 900;
}
.diary-form .form-actions {
  margin-top: 16px;
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px;
}
.diary-form .form-actions .btn {
  width: 100%;
}

.dashboard {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 16px;
  padding-bottom: 20px;
}
.dashboard article {
  min-height: 130px;
  padding: 24px;
  border-radius: 28px;
}
.dashboard span { color: var(--muted); font-weight: 900; }
.dashboard strong {
  display: block;
  margin-top: 18px;
  color: var(--rose);
  font-size: 2.2rem;
}

.timeline { display: grid; gap: 14px; }
.timeline-item {
  padding: 20px;
  border-radius: 26px;
  display: grid;
  grid-template-columns: 110px 1fr auto;
  gap: 18px;
  align-items: center;
  transition: transform 0.22s ease, box-shadow 0.22s ease;
}
.timeline-item:hover, .review-grid article:hover { transform: translateY(-5px); box-shadow: var(--shadow); }
.timeline-date { color: var(--rose); font-weight: 950; }
.timeline-text h3 { margin: 0 0 6px; }
.timeline-text p { margin: 0; color: var(--muted); line-height: 1.6; }
.timeline-side {
  display: grid;
  gap: 10px;
  justify-items: end;
  align-content: center;
}
.item-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  justify-content: flex-end;
}
.mini-action-btn {
  min-height: 38px;
  padding: 0 14px;
  border: 1px solid rgba(39,34,43,0.1);
  border-radius: 999px;
  background: rgba(255,255,255,0.92);
  color: var(--ink);
  font-size: 0.84rem;
  font-weight: 900;
}
.mini-action-btn.danger {
  color: #c14761;
  border-color: rgba(193, 71, 97, 0.18);
  background: rgba(255, 244, 247, 0.92);
}
.ebook-heading {
  display: flex;
  gap: 18px;
  align-items: end;
  justify-content: space-between;
}
.ebook-search-bar {
  display: flex;
  flex-wrap: wrap;
  gap: 14px;
  align-items: end;
  margin-bottom: 24px;
}
.ebook-search-field {
  min-width: min(100%, 260px);
  display: grid;
  gap: 8px;
  color: var(--ink);
  font-weight: 900;
}
.ebook-search-field span {
  color: var(--muted);
  font-size: 0.86rem;
}
.ebook-search-field input {
  min-height: 54px;
  padding: 0 16px;
  border: 1px solid rgba(39,34,43,0.12);
  border-radius: 18px;
  background: rgba(255,255,255,0.84);
  font: inherit;
}
.ebook-search-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}
.ebook-viewer {
  display: grid;
  grid-template-columns: 56px minmax(0, 1fr) 56px;
  gap: 14px;
  align-items: center;
}
.ebook-nav {
  width: 56px;
  height: 56px;
  border: 1px solid rgba(39,34,43,0.08);
  border-radius: 50%;
  background: rgba(255,255,255,0.92);
  box-shadow: 0 14px 36px rgba(128, 88, 96, 0.12);
  cursor: pointer;
  transition: transform 0.2s ease, opacity 0.2s ease;
}
.ebook-nav:hover:not(:disabled) {
  transform: translateY(-2px);
}
.ebook-nav:disabled {
  opacity: 0.42;
  cursor: default;
}
.ebook-nav::before {
  content: "";
  display: inline-block;
  width: 12px;
  height: 12px;
  border-top: 2px solid var(--ink);
  border-right: 2px solid var(--ink);
}
.ebook-nav.prev::before {
  transform: rotate(-135deg);
  margin-left: 4px;
}
.ebook-nav.next::before {
  transform: rotate(45deg);
  margin-right: 4px;
}
.ebook-page {
  padding: 22px;
  border-radius: 32px;
  border: 1px solid rgba(255,255,255,0.78);
  background:
    radial-gradient(circle at top left, rgba(255,233,236,0.92), transparent 38%),
    linear-gradient(180deg, rgba(255,255,255,0.92), rgba(252,246,241,0.96));
  box-shadow: 0 24px 70px rgba(128, 88, 96, 0.14);
}
.ebook-page-meta {
  display: flex;
  justify-content: space-between;
  gap: 14px;
  margin-bottom: 16px;
  color: var(--rose);
  font-weight: 900;
}
.ebook-page-meta strong {
  color: var(--ink);
}
.ebook-spread {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 18px;
}
.ebook-sheet {
  min-height: 480px;
  padding: 24px;
  border-radius: 24px;
  background:
    linear-gradient(180deg, rgba(255,255,255,0.98), rgba(251,247,241,0.98));
  box-shadow: inset 0 0 0 1px rgba(39,34,43,0.05), 0 14px 30px rgba(128, 88, 96, 0.08);
}
.ebook-left {
  display: flex;
}
.ebook-photo-wrap {
  width: 100%;
  border-radius: 18px;
  overflow: hidden;
  background: rgba(248, 233, 229, 0.56);
}
.ebook-photo {
  width: 100%;
  height: 100%;
  min-height: 432px;
  object-fit: cover;
}
.ebook-photo-placeholder {
  display: grid;
  place-items: center;
  text-align: center;
  gap: 10px;
  color: var(--ink);
}
.ebook-photo-placeholder span {
  color: var(--rose);
  font-weight: 900;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  font-size: 0.8rem;
}
.ebook-photo-placeholder strong {
  font-size: clamp(1.6rem, 3vw, 2.2rem);
  line-height: 1.2;
}
.ebook-right {
  display: grid;
  align-content: start;
  gap: 16px;
}
.ebook-mood {
  width: fit-content;
  padding: 8px 12px;
  border-radius: 999px;
  background: rgba(255, 234, 239, 0.95);
  color: var(--rose);
  font-weight: 950;
}
.ebook-right h3 {
  margin: 0;
  font-size: clamp(1.6rem, 3vw, 2.3rem);
  line-height: 1.22;
}
.ebook-right p {
  margin: 0;
  color: var(--muted);
  line-height: 1.9;
  font-size: 1rem;
}
.ebook-note-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px;
  margin: 0;
}
.ebook-note-grid div {
  padding: 14px;
  border-radius: 18px;
  background: rgba(255,248,244,0.9);
}
.ebook-note-grid dt {
  color: var(--muted);
  font-size: 0.8rem;
  font-weight: 800;
}
.ebook-note-grid dd {
  margin: 6px 0 0;
  color: var(--ink);
  font-weight: 900;
}
.ebook-empty {
  margin-top: 18px;
}
.mood-chip {
  padding: 8px 12px;
  border-radius: 999px;
  color: #fff;
  background: var(--lavender);
  font-weight: 950;
  white-space: nowrap;
}
.empty-message {
  display: none;
  padding: 28px;
  border-radius: 24px;
  color: var(--muted);
  background: rgba(255,255,255,0.78);
  text-align: center;
  font-weight: 900;
}

.book-section {
  border-radius: 36px;
  padding-inline: clamp(22px, 5vw, 58px);
  display: grid;
  grid-template-columns: 0.82fr 1fr;
  gap: 40px;
  align-items: center;
}
.book-builder-summary {
  margin: 18px 0 0;
  padding: 16px 18px;
  border-radius: 22px;
  background: rgba(255,255,255,0.72);
  box-shadow: inset 0 0 0 1px rgba(39,34,43,0.06);
}
.book-builder-summary strong {
  display: block;
  font-size: 1.02rem;
}
.book-builder-summary p {
  margin: 8px 0 0;
  color: var(--muted);
  line-height: 1.7;
}
.book-preview-wrap {
  display: grid;
  gap: 18px;
}

.sales-heading {
  display: flex;
  gap: 20px;
  align-items: end;
  justify-content: space-between;
}
.plans {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 18px;
}
.sample-card {
  grid-column: span 3;
  display: grid;
  grid-template-columns: minmax(0, 1.1fr) minmax(260px, 0.7fr);
  gap: 24px;
  align-items: center;
  padding: 22px;
  border: 1px solid rgba(255, 255, 255, 0.72);
  border-radius: 30px;
  background: rgba(255, 255, 255, 0.84);
  box-shadow: 0 18px 54px rgba(128, 88, 96, 0.11);
}
.sample-card img {
  width: 100%;
  max-height: 420px;
  border-radius: 22px;
  object-fit: cover;
  object-position: top center;
  box-shadow: 0 16px 44px rgba(128, 88, 96, 0.14);
}
.sample-card h3 {
  margin: 18px 0 10px;
  font-size: clamp(1.6rem, 3vw, 2.4rem);
  line-height: 1.2;
}
.sample-card p {
  color: var(--muted);
  line-height: 1.75;
}

.sample-diary-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 16px;
}
.sample-diary-card {
  min-height: 250px;
  padding: 22px;
  border: 1px solid rgba(255, 255, 255, 0.72);
  border-radius: 28px;
  background: rgba(255, 255, 255, 0.84);
  box-shadow: 0 18px 54px rgba(128, 88, 96, 0.1);
}
.sample-diary-photo-wrap {
  position: relative;
  margin-bottom: 16px;
  border-radius: 20px;
  overflow: hidden;
  box-shadow: 0 16px 34px rgba(128, 88, 96, 0.14);
}
.sample-diary-photo {
  width: 100%;
  aspect-ratio: 16 / 10;
  display: block;
  object-fit: cover;
}
.sample-diary-sticker {
  position: absolute;
  right: 12px;
  bottom: 12px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 34px;
  padding: 0 12px;
  border-radius: 999px;
  color: #ef6f96;
  background: rgba(255,255,255,0.92);
  box-shadow: 0 12px 24px rgba(39, 34, 43, 0.16);
  font-family: "Comic Sans MS", "Segoe Print", cursive;
  font-size: 0.84rem;
  font-weight: 900;
}
.sample-diary-card time {
  color: var(--rose);
  font-weight: 950;
}
.sample-diary-card h3 {
  margin: 14px 0 10px;
  font-size: 1.22rem;
  line-height: 1.35;
}
.sample-diary-card p {
  color: var(--muted);
  line-height: 1.75;
}
.sample-book-teaser {
  margin-top: 28px;
  padding: 26px;
  border: 1px solid rgba(255, 255, 255, 0.72);
  border-radius: 32px;
  background: rgba(255, 255, 255, 0.84);
  box-shadow: 0 18px 54px rgba(128, 88, 96, 0.11);
  display: grid;
  grid-template-columns: minmax(260px, 0.86fr) minmax(320px, 1fr);
  gap: 24px;
  align-items: center;
}
.sample-book-copy h3 {
  margin: 0;
  font-size: clamp(1.9rem, 3.6vw, 2.8rem);
  line-height: 1.16;
}
.sample-book-copy p {
  color: var(--muted);
  line-height: 1.8;
}
.sample-book-note {
  margin: 18px 0 22px;
  padding: 16px 18px;
  border-radius: 22px;
  background: rgba(255,255,255,0.78);
  box-shadow: inset 0 0 0 1px rgba(39,34,43,0.06);
}
.sample-book-note strong {
  display: block;
  font-size: 0.98rem;
  line-height: 1.6;
}
.sample-book-note p {
  margin: 8px 0 0;
}
.sample-book-mockup {
  display: grid;
  grid-template-columns: minmax(150px, 0.7fr) minmax(0, 1fr);
  gap: 16px;
  align-items: stretch;
}
.sample-book-sheet {
  border-radius: 24px;
  background: linear-gradient(180deg, rgba(255,255,255,0.96), rgba(255,247,249,0.92));
  box-shadow: 0 18px 40px rgba(128, 88, 96, 0.12);
}
.sample-book-cover {
  padding: 20px 18px;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  color: var(--ink);
}
.sample-book-cover strong {
  font-size: 1.75rem;
  line-height: 1.18;
}
.sample-book-cover em,
.sample-book-cover span {
  font-style: normal;
  font-weight: 900;
}
.sample-book-cover em {
  color: var(--rose);
}
.sample-book-spread {
  padding: 14px;
  display: grid;
  gap: 14px;
}
.sample-book-spread-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px;
}
.sample-book-spread-grid figure {
  margin: 0;
  border-radius: 14px;
  overflow: hidden;
  background: rgba(255,255,255,0.74);
}
.sample-book-spread-grid img {
  width: 100%;
  aspect-ratio: 1 / 1;
  display: block;
  object-fit: cover;
}
.sample-book-caption {
  padding: 14px;
  border-radius: 18px;
  background: rgba(255,255,255,0.92);
  box-shadow: inset 0 0 0 1px rgba(39,34,43,0.06);
}
.sample-book-caption span {
  color: var(--rose);
  font-size: 0.76rem;
  font-weight: 950;
  text-transform: uppercase;
  letter-spacing: 0.08em;
}
.sample-book-caption strong {
  display: block;
  margin-top: 8px;
  color: var(--ink);
  font-size: 1.02rem;
  line-height: 1.5;
}
.sample-book-caption p {
  margin: 8px 0 0;
  color: var(--muted);
  line-height: 1.7;
}

.sticker-section {
  border-radius: 36px;
  padding-inline: clamp(22px, 5vw, 58px);
  background: rgba(255, 255, 255, 0.68);
  box-shadow: var(--shadow);
}
.sticker-heading {
  display: flex;
  gap: 18px;
  align-items: end;
  justify-content: space-between;
}
.credit-pill {
  padding: 10px 14px;
  border-radius: 999px;
  color: #fff;
  background: var(--ink);
  font-weight: 950;
  white-space: nowrap;
}
.sticker-shop {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 12px;
}
.sticker-more-btn {
  margin-top: 14px;
}
.sticker-trial-note {
  margin: 14px 0 0;
  padding: 14px 16px;
  border-radius: 18px;
  background: rgba(255, 245, 224, 0.92);
  color: #8c5a00;
  line-height: 1.7;
  font-weight: 900;
}
.sticker-item {
  min-height: 118px;
  border: 1px solid rgba(255, 255, 255, 0.72);
  border-radius: 26px;
  background: linear-gradient(180deg, rgba(255, 255, 255, 0.94), rgba(255, 248, 250, 0.9));
  box-shadow: 0 14px 40px rgba(128, 88, 96, 0.1);
  cursor: pointer;
  font-size: 2.3rem;
  word-break: keep-all;
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}
.sticker-item.font-serif { font-family: Georgia, "Times New Roman", serif; }
.sticker-item.font-round { font-family: "Arial Rounded MT Bold", "Trebuchet MS", sans-serif; }
.sticker-item.font-hand { font-family: "Comic Sans MS", "Segoe Print", cursive; }
.sticker-item:hover,
.sticker-item.active {
  transform: translateY(-4px);
  box-shadow: var(--shadow);
}
.sticker-item span {
  display: block;
  margin-top: 8px;
  color: var(--ink);
  font-size: 0.84rem;
  line-height: 1.45;
  font-weight: 950;
}
.sticker-help {
  margin: 16px 0 0;
  color: var(--muted);
  font-weight: 850;
}
.placed-frame {
  position: absolute;
  inset: 14px;
  border-radius: 26px;
  pointer-events: none;
}
.placed-frame.frame-soft {
  border: 10px solid rgba(255, 207, 218, 0.92);
  box-shadow: inset 0 0 0 2px rgba(255, 255, 255, 0.82);
}
.placed-frame.frame-ribbon {
  border: 8px solid rgba(246, 173, 192, 0.95);
  box-shadow:
    inset 0 0 0 2px rgba(255, 255, 255, 0.88),
    inset 0 0 0 14px rgba(255, 244, 247, 0.56);
}
.placed-frame.frame-gold {
  border: 8px solid rgba(214, 177, 101, 0.94);
  box-shadow:
    inset 0 0 0 2px rgba(255, 248, 231, 0.9),
    0 0 0 3px rgba(255, 230, 181, 0.36);
}
.extra-sticker[hidden] {
  display: none !important;
}
.plan-card {
  min-height: 420px;
  padding: 24px;
  border: 1px solid rgba(255, 255, 255, 0.72);
  border-radius: 30px;
  background: rgba(255, 255, 255, 0.84);
  box-shadow: 0 18px 54px rgba(128, 88, 96, 0.11);
  display: flex;
  flex-direction: column;
  transition: transform 0.22s ease, box-shadow 0.22s ease;
}
.plan-image {
  width: 100%;
  aspect-ratio: 16 / 10;
  border-radius: 20px;
  object-fit: cover;
  box-shadow: inset 0 0 0 1px rgba(39,34,43,0.08), 0 18px 40px rgba(128,88,96,0.16);
}
.plan-card:hover {
  transform: translateY(-6px);
  box-shadow: var(--shadow);
}
.plan-card.featured {
  color: #fff;
  background: linear-gradient(145deg, var(--blush), var(--lavender));
}
.budget-plan {
  background: linear-gradient(160deg, rgba(255,255,255,0.98), rgba(255,249,242,0.96));
}
.prestige-plan {
  color: #fff;
  background: linear-gradient(150deg, #2f2434, #775067 58%, #b67d8f);
}
.prestige-plan p,
.prestige-plan li {
  color: rgba(255,255,255,0.82);
}
.prestige-plan .price-box del {
  color: rgba(255,255,255,0.64);
}
.prestige-plan .discount-badge {
  color: var(--ink);
  background: rgba(255,255,255,0.92);
}
.prestige-plan .order-btn {
  background: #fff;
  color: var(--ink);
  box-shadow: 0 18px 34px rgba(39, 34, 43, 0.2);
}
.plan-label {
  width: fit-content;
  padding: 7px 11px;
  border-radius: 999px;
  color: var(--rose);
  background: rgba(255, 246, 248, 0.92);
  font-size: 0.78rem;
  font-weight: 950;
}
.plan-card h3 {
  margin: 22px 0 8px;
  font-size: 1.5rem;
  line-height: 1.25;
}
.plan-card p {
  min-height: 50px;
  margin: 0;
  color: var(--muted);
  line-height: 1.65;
}
.plan-card.featured p,
.plan-card.featured li {
  color: rgba(255, 255, 255, 0.86);
}
.price-box {
  display: grid;
  gap: 6px;
  margin: 18px 0;
}
.discount-badge {
  width: fit-content;
  padding: 6px 10px;
  border-radius: 999px;
  color: #fff;
  background: var(--rose);
  font-size: 0.82rem;
  font-weight: 950;
}
.plan-card.featured .discount-badge {
  color: var(--rose);
  background: rgba(255, 255, 255, 0.92);
}
.price-box del {
  color: #aaa1aa;
  font-size: 1rem;
  font-weight: 850;
}
.plan-card.featured .price-box del {
  color: rgba(255, 255, 255, 0.74);
}
.price-box strong {
  display: block;
  font-size: 2rem;
}
.plan-card ul {
  margin: 0 0 24px;
  padding-left: 18px;
  color: var(--muted);
  line-height: 1.9;
}
.plan-card .btn {
  width: 100%;
  margin-top: auto;
}
.order-btn {
  min-height: 58px;
  border: 0;
  border-radius: 20px;
  color: #fff;
  background: linear-gradient(135deg, #f36f85, #f29f7f);
  box-shadow: 0 18px 36px rgba(243, 111, 133, 0.28);
  font-size: 1rem;
  font-weight: 950;
  letter-spacing: 0.01em;
}
.order-btn:hover {
  transform: translateY(-2px);
  box-shadow: 0 22px 40px rgba(243, 111, 133, 0.34);
}
.plan-card.featured .order-btn {
  background: #fff;
  color: var(--ink);
  box-shadow: 0 18px 34px rgba(39, 34, 43, 0.16);
}
.book-copy p { margin-bottom: 24px; }
.book-preview {
  min-height: 390px;
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 12px;
  perspective: 1000px;
}
.preview-page {
  padding: 28px;
  border-radius: 18px;
  background: var(--paper);
  box-shadow: inset 0 0 0 1px rgba(39,34,43,0.08), 0 20px 50px rgba(128,88,96,0.12);
}
.cover-page {
  color: var(--ink);
  background:
    linear-gradient(145deg, rgba(255,255,255,0.88), rgba(255,239,242,0.9)),
    radial-gradient(circle at 20% 20%, rgba(244,127,143,0.2), transparent 36%),
    var(--paper);
  display: flex;
  flex-direction: column;
  justify-content: space-between;
}
.cover-page strong { font-size: 2rem; line-height: 1.2; }
.cover-page em {
  display: block;
  margin-top: 10px;
  color: var(--muted);
  font-style: normal;
  line-height: 1.7;
}
.cover-summary {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-top: 18px;
}
.cover-summary span {
  padding: 8px 12px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.82);
  box-shadow: inset 0 0 0 1px rgba(39,34,43,0.06);
  font-size: 0.88rem;
  font-weight: 900;
}
.inside-page {
  color: #4e4751;
  background: rgba(255,255,255,0.92);
}
.book-spread-preview {
  display: grid;
  gap: 16px;
}
.book-photo-grid {
  display: grid;
  gap: 12px;
  min-height: 310px;
}
.book-photo-grid[data-count="1"] {
  grid-template-columns: 1fr;
}
.book-photo-grid[data-count="2"] {
  grid-template-columns: repeat(2, minmax(0, 1fr));
}
.book-photo-grid[data-count="3"] {
  grid-template-columns: 1.25fr 0.95fr;
  grid-template-rows: repeat(2, minmax(0, 1fr));
}
.book-photo-grid[data-count="3"] .book-photo-tile:first-child {
  grid-row: 1 / span 2;
}
.book-photo-grid[data-count="4"] {
  grid-template-columns: repeat(2, minmax(0, 1fr));
  grid-template-rows: repeat(2, minmax(0, 1fr));
}
.book-photo-tile {
  margin: 0;
  min-height: 146px;
  border-radius: 18px;
  overflow: hidden;
  background: linear-gradient(145deg, #fff7f8, #fffdf8);
  box-shadow: inset 0 0 0 1px rgba(39,34,43,0.06), 0 14px 36px rgba(128,88,96,0.12);
  display: grid;
  grid-template-rows: minmax(0, 1fr) auto;
}
.book-photo-tile img {
  width: 100%;
  height: 100%;
  min-height: 170px;
  display: block;
  object-fit: contain;
  object-position: center;
  background: #fff;
}
.book-photo-tile figcaption {
  padding: 12px 14px 14px;
  background: rgba(255,255,255,0.96);
}
.book-photo-tile figcaption strong {
  display: block;
  color: var(--ink);
  font-size: 0.92rem;
  line-height: 1.4;
}
.book-photo-tile figcaption span {
  display: block;
  margin-top: 4px;
  color: var(--muted);
  font-size: 0.76rem;
  font-weight: 900;
  line-height: 1.45;
}
.layout-count-tab:disabled {
  opacity: 0.42;
  cursor: not-allowed;
}
.book-story-card {
  padding: 18px;
  border-radius: 22px;
  background: linear-gradient(145deg, rgba(255,249,251,0.98), rgba(255,255,255,0.94));
  box-shadow: inset 0 0 0 1px rgba(39,34,43,0.06);
}
.book-story-kicker {
  display: inline-flex;
  padding: 6px 10px;
  border-radius: 999px;
  color: var(--rose);
  background: rgba(255, 241, 245, 0.96);
  font-size: 0.76rem;
  font-weight: 950;
}
.book-story-card strong {
  display: block;
  margin-top: 12px;
  font-size: 1.28rem;
  line-height: 1.35;
}
.book-story-card p {
  margin: 10px 0 0;
  color: var(--muted);
  line-height: 1.75;
  white-space: pre-line;
  word-break: keep-all;
}

.review-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 18px;
}
.review-grid article {
  min-height: 220px;
  padding: 24px;
  border-radius: 28px;
  transition: transform 0.22s ease, box-shadow 0.22s ease;
}
.review-grid strong { display: block; font-size: 1.08rem; line-height: 1.5; }
.review-grid p { color: var(--muted); line-height: 1.75; }
.review-grid span { color: var(--rose); font-weight: 950; }
.bottom-cta {
  margin-bottom: 70px;
  border-radius: 36px;
  background: rgba(255,255,255,0.72);
  text-align: center;
  box-shadow: var(--shadow);
}
.bottom-cta .btn { margin-top: 24px; }
.footer { padding: 34px 20px 90px; color: var(--muted); text-align: center; }
.footer strong { color: var(--rose); font-size: 1.28rem; }
.mobile-fixed-cta { display: none; }
.toast {
  position: fixed;
  left: 50%;
  bottom: 30px;
  z-index: 50;
  min-width: 250px;
  padding: 14px 18px;
  border-radius: 999px;
  color: #fff;
  background: rgba(39, 34, 43, 0.92);
  text-align: center;
  font-weight: 900;
  opacity: 0;
  transform: translate(-50%, 18px);
  pointer-events: none;
  transition: opacity 0.25s ease, transform 0.25s ease;
}
.toast.show { opacity: 1; transform: translate(-50%, 0); }
.fade-up { opacity: 1; transform: none; transition: opacity 0.65s ease, transform 0.65s ease; }
.fade-up.visible { opacity: 1; transform: none; }

.modal {
  position: fixed;
  inset: 0;
  z-index: 80;
  display: none;
}
.modal.open {
  display: block;
}
.modal-backdrop {
  position: absolute;
  inset: 0;
  background: rgba(39, 34, 43, 0.46);
  backdrop-filter: blur(12px);
}
.modal-panel {
  position: relative;
  width: min(1020px, calc(100vw - 28px));
  max-height: calc(100vh - 36px);
  margin: 18px auto;
  padding: clamp(18px, 3vw, 28px);
  border-radius: 30px;
  background: var(--paper);
  box-shadow: 0 30px 90px rgba(39, 34, 43, 0.28);
  overflow: auto;
}
.modal-close {
  position: absolute;
  top: 14px;
  right: 14px;
  width: 42px;
  height: 42px;
  border: 0;
  border-radius: 50%;
  background: #fff;
  color: var(--ink);
  font-size: 1.5rem;
  cursor: pointer;
}
.modal-copy h2 {
  margin: 0;
  font-size: clamp(1.8rem, 4vw, 3rem);
}
.modal-copy p {
  color: var(--muted);
  line-height: 1.7;
}
.ai-layout-toolbar {
  margin-top: 18px;
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  align-items: center;
  justify-content: space-between;
}
.layout-count-tabs {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 90px));
  gap: 10px;
}
.layout-count-tab {
  min-height: 48px;
  border: 1px solid rgba(39,34,43,0.08);
  border-radius: 16px;
  background: rgba(255,255,255,0.92);
  color: var(--ink);
  font-weight: 950;
}
.layout-count-tab.active {
  color: #fff;
  background: linear-gradient(135deg, #f36f85, #a883f4);
  box-shadow: 0 16px 30px rgba(163, 112, 186, 0.24);
}
.finished-book {
  position: relative;
  overflow: hidden;
  border-radius: 24px;
  background: linear-gradient(145deg, #fffdf8, #fff1f4);
  box-shadow: 0 18px 54px rgba(128, 88, 96, 0.14);
  cursor: crosshair;
}
.finished-book-page {
  position: relative;
  z-index: 1;
  display: grid;
  gap: 18px;
  padding: clamp(16px, 2.8vw, 24px);
  min-height: min(72vh, 760px);
}
.modal-book-grid {
  min-height: min(48vh, 500px);
}
.modal-story-card {
  background: rgba(255, 255, 255, 0.9);
}
.layout-picker-panel {
  margin-top: 18px;
  padding: 20px;
  border-radius: 24px;
  background: linear-gradient(145deg, rgba(255,255,255,0.92), rgba(255,247,250,0.9));
  box-shadow: inset 0 0 0 1px rgba(39,34,43,0.05);
}
.layout-picker-head {
  display: flex;
  gap: 16px;
  align-items: end;
  justify-content: space-between;
}
.layout-picker-head h3 {
  margin: 6px 0 0;
  font-size: 1.22rem;
}
.layout-picker-head p {
  margin: 0;
  color: var(--muted);
  line-height: 1.7;
}
.photo-choice-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 12px;
  margin-top: 16px;
}
.photo-choice-card {
  padding: 10px;
  border: 1px solid rgba(39,34,43,0.08);
  border-radius: 18px;
  background: rgba(255,255,255,0.88);
  text-align: left;
  transition: transform 0.2s ease, box-shadow 0.2s ease, border-color 0.2s ease;
}
.photo-choice-card.active {
  border-color: rgba(243, 111, 133, 0.5);
  box-shadow: 0 18px 32px rgba(243, 111, 133, 0.16);
  transform: translateY(-2px);
}
.photo-choice-card img {
  width: 100%;
  aspect-ratio: 1 / 1;
  border-radius: 14px;
  object-fit: cover;
  display: block;
}
.photo-choice-card strong {
  display: block;
  margin-top: 10px;
  color: var(--ink);
  font-size: 0.92rem;
  line-height: 1.4;
}
.photo-choice-card span {
  display: block;
  margin-top: 4px;
  color: var(--muted);
  font-size: 0.78rem;
  line-height: 1.5;
}
.sticker-layer {
  position: absolute;
  inset: 0;
  pointer-events: none;
  z-index: 2;
}
.placed-sticker-wrap {
  position: absolute;
  pointer-events: auto;
  transform-origin: center center;
}
.placed-sticker {
  font-size: clamp(1.8rem, 5vw, 3.4rem);
  max-width: 46%;
  padding: 0.08em 0.28em;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.48);
  color: var(--ink);
  text-align: center;
  line-height: 1.15;
  word-break: keep-all;
  white-space: pre-wrap;
  filter: drop-shadow(0 8px 12px rgba(39, 34, 43, 0.22));
  user-select: text;
  cursor: grab;
  outline: none;
  min-width: 2ch;
}
.placed-sticker.is-active {
  outline: 2px dashed rgba(243, 111, 133, 0.88);
  box-shadow: 0 18px 42px rgba(243, 111, 133, 0.24);
}
.placed-sticker.is-draft {
  opacity: 0.92;
}
.placed-sticker.is-confirmed {
  cursor: default;
}
.placed-sticker.is-editing {
  cursor: text;
}
.sticker-rotate-handle {
  position: absolute;
  top: -14px;
  right: -14px;
  width: 28px;
  height: 28px;
  border: 0;
  border-radius: 999px;
  background: linear-gradient(135deg, #f36f85, #b184ff);
  color: #fff;
  font-size: 0.9rem;
  font-weight: 900;
  display: grid;
  place-items: center;
  box-shadow: 0 10px 22px rgba(39, 34, 43, 0.18);
  cursor: alias;
}
.placed-sticker.is-confirmed + .sticker-rotate-handle {
  display: none;
}
.placed-sticker.font-serif { font-family: Georgia, "Times New Roman", serif; }
.placed-sticker.font-round { font-family: "Arial Rounded MT Bold", "Trebuchet MS", sans-serif; }
.placed-sticker.font-hand { font-family: "Comic Sans MS", "Segoe Print", cursive; }
.modal-actions {
  margin-top: 18px;
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}
.checkout-panel {
  width: min(620px, calc(100vw - 28px));
}
.payment-result-panel {
  width: min(620px, calc(100vw - 28px));
}
.checkout-summary {
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 12px 18px;
  margin: 22px 0;
  padding: 18px;
  border-radius: 22px;
  background: rgba(255, 245, 247, 0.92);
}
.checkout-summary span {
  color: var(--muted);
  font-weight: 800;
}
.checkout-summary strong {
  color: var(--ink);
  font-size: 1.08rem;
  text-align: right;
}
.checkout-fields {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 12px;
}
.payment-methods {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 10px;
  margin-top: 16px;
}
.payment-method {
  min-height: 54px;
  border: 1px solid rgba(39,34,43,0.08);
  border-radius: 18px;
  background: rgba(255,255,255,0.84);
  color: var(--ink);
  font: inherit;
  font-weight: 900;
  cursor: pointer;
  transition: transform 0.2s ease, box-shadow 0.2s ease, border-color 0.2s ease;
}
.payment-method.active,
.payment-method:hover {
  transform: translateY(-2px);
  border-color: rgba(244, 127, 143, 0.4);
  box-shadow: 0 14px 34px rgba(128, 88, 96, 0.1);
}
.checkout-agree {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-top: 16px;
  color: var(--ink);
  font-weight: 850;
}
.checkout-agree input {
  width: 18px;
  height: 18px;
}
.checkout-status {
  margin: 14px 0 0;
  padding: 14px 16px;
  border-radius: 18px;
  background: rgba(255, 246, 248, 0.88);
  color: var(--muted);
  line-height: 1.65;
  word-break: keep-all;
}
.checkout-status[data-tone="warning"] {
  color: #8f5d00;
  background: rgba(255, 243, 212, 0.96);
}
.checkout-status[data-tone="error"] {
  color: #a13b4d;
  background: rgba(255, 232, 237, 0.96);
}
.checkout-note {
  margin-top: 14px;
  padding: 16px 18px;
  border-radius: 20px;
  background: rgba(255,255,255,0.78);
  border: 1px solid rgba(39,34,43,0.06);
}
.checkout-note strong {
  display: block;
  margin-bottom: 6px;
}
.checkout-note p {
  margin: 0;
  color: var(--muted);
  line-height: 1.7;
}
.payment-result-summary {
  margin-top: 20px;
}

@media (max-width: 960px) {
  .form-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .hero, .book-section { grid-template-columns: 1fr; }
  .form-grid, .review-grid, .plans, .sample-diary-grid { grid-template-columns: repeat(2, 1fr); }
  .sample-book-teaser,
  .sample-book-mockup { grid-template-columns: 1fr; }
  .sample-card { grid-column: span 2; grid-template-columns: 1fr; }
  .sticker-shop { grid-template-columns: repeat(2, 1fr); }
  .sticker-heading { align-items: stretch; flex-direction: column; }
  .sales-heading { align-items: stretch; flex-direction: column; }
  .ebook-spread { grid-template-columns: 1fr; }
  .ebook-sheet { min-height: auto; }
  .timeline-item { grid-template-columns: 1fr; }
  .photo-choice-grid { grid-template-columns: repeat(3, 1fr); }
  .layout-picker-head { align-items: stretch; flex-direction: column; }
}
@media (max-width: 680px) {
  html { scroll-padding-top: 84px; }
  main { padding-top: 0; }
  .site-header {
    position: static;
    inset: auto;
    border-bottom: 0;
    background: transparent;
    box-shadow: none;
    backdrop-filter: none;
  }
  .site-header.scrolled {
    background: transparent;
    border-color: transparent;
    box-shadow: none;
    backdrop-filter: none;
  }
  .nav, .section {
    width: calc(100vw - 36px);
    max-width: 1180px;
  }
  .nav {
    height: auto;
    padding-top: 14px;
    justify-content: flex-start;
  }
  .logo {
    width: 76px;
    height: 76px;
  }
  .logo img {
    width: 96%;
    height: 96%;
  }
  .menu-toggle { display: block; }
  .nav-menu {
    position: fixed;
    top: 72px;
    left: 14px;
    right: 14px;
    display: none;
    padding: 18px;
    border: 1px solid var(--line);
    border-radius: 24px;
    background: rgba(255,255,255,0.94);
    box-shadow: var(--shadow);
    backdrop-filter: blur(18px);
    flex-direction: column;
    gap: 14px;
  }
  .nav-menu.open { display: flex; }
  .auth-box {
    position: fixed;
    top: 132px;
    left: 14px;
    right: 14px;
    display: none;
    padding: 14px;
    border: 1px solid var(--line);
    border-radius: 22px;
    background: rgba(255,255,255,0.94);
    box-shadow: var(--shadow);
    backdrop-filter: blur(18px);
    flex-wrap: wrap;
  }
  .nav-menu.open + .auth-box {
    display: flex;
  }
  .auth-box span {
    max-width: 100%;
    flex: 1 0 100%;
  }
  .auth-btn {
    flex: 1;
  }
  .hero { min-height: auto; padding-top: 28px; gap: 22px; }
  .hero-copy {
    padding-right: 4px;
  }
  .hero-actions {
    margin-top: 8px;
    padding-right: 14px;
  }
  .hero h1 {
    max-width: 8.6em;
    font-size: clamp(1.88rem, 8vw, 2.48rem);
    line-height: 1.12;
    overflow-wrap: normal;
    word-break: keep-all;
  }
  .hero-lead {
    margin: 18px 0 10px;
    font-size: 1.04rem;
    line-height: 1.42;
  }
  .hero-sub {
    max-width: 31ch;
    margin-bottom: 22px;
    font-size: 0.92rem;
    line-height: 1.62;
  }
  .section-heading p,
  .book-copy p,
  .sample-card p,
  .plan-card p {
    max-width: 31ch;
  }
  .section-heading h2, .book-copy h2, .bottom-cta h2 {
    font-size: clamp(1.42rem, 6.6vw, 2rem);
    line-height: 1.2;
  }
  .hero-actions .btn, .form-actions .btn {
      width: calc(100% - 10px);
      max-width: 100%;
    }
    .diary-form .form-actions {
      grid-template-columns: 1fr;
    }
  .photo-uploader-actions {
    grid-template-columns: 1fr;
  }
  .book-hero {
      min-height: 520px;
      overflow: visible;
    }
  .book-cover {
      width: min(292px, 76vw);
      padding: 20px 18px 22px;
      border-radius: 18px 28px 28px 18px;
    }
    .book-cover strong {
      font-size: clamp(1.45rem, 6vw, 2rem);
      line-height: 1.16;
    }
    .cover-script {
      font-size: 0.9rem;
    }
    .cover-photo-frame {
      margin: 14px 0;
      border-radius: 22px;
    }
    .cover-photo-frame img {
      aspect-ratio: 1 / 0.92;
    }
    .cover-copy-block p {
      margin-top: 10px;
      font-size: 0.88rem;
      line-height: 1.58;
    }
    .cover-chip {
      min-height: 30px;
      padding: 0 10px;
      font-size: 0.82rem;
    }
    .cover-sticker {
      padding: 7px 10px;
      font-size: 0.76rem;
    }
    .note-one { left: 4px; top: 44px; }
    .note-two { display: none; }
  .form-grid, .dashboard, .review-grid, .book-preview, .plans, .sample-diary-grid { grid-template-columns: 1fr; }
  .sample-diary-card {
    min-height: auto;
    padding: 18px;
  }
  .sample-diary-card h3 {
    margin: 12px 0 8px;
    font-size: 1.08rem;
    line-height: 1.32;
  }
  .sample-diary-card p {
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
    line-height: 1.62;
    min-height: calc(1em * 1.62 * 2);
  }
  .sample-book-teaser { padding: 18px; border-radius: 24px; }
  .diary-mobile-composer { padding: 16px; border-radius: 26px; }
  .form-grid { grid-template-columns: 1fr; }
  .story-label-row { align-items: stretch; flex-direction: column; }
  .story-action-group { grid-template-columns: 1fr 1fr; width: 100%; }
  .story-action-group .ai-draft-btn { min-height: 42px; }
  .checkout-fields,
  .payment-methods { grid-template-columns: 1fr; }
  .photo-choice-grid { grid-template-columns: repeat(2, 1fr); }
  .layout-count-tabs { grid-template-columns: repeat(2, minmax(0, 1fr)); width: 100%; }
  .book-photo-grid[data-count="2"],
  .book-photo-grid[data-count="3"],
  .book-photo-grid[data-count="4"] { grid-template-columns: 1fr; grid-template-rows: none; }
  .book-photo-grid[data-count="3"] .book-photo-tile:first-child { grid-row: auto; }
  .sample-card { grid-column: span 1; padding: 16px; }
  .sample-card img { max-height: 320px; }
  .diary-section, .timeline-section, .ebook-section, .book-section, .sample-diary-section, .sticker-section, .sales-section, .review-section, .bottom-cta { padding-block: 54px; }
  .sticker-shop { grid-template-columns: repeat(2, 1fr); }
  .sticker-item { min-height: 104px; }
  .sticker-rotate-handle {
    width: 24px;
    height: 24px;
    top: -10px;
    right: -10px;
    font-size: 0.8rem;
  }
  .modal-panel { margin: 10px auto; max-height: calc(100vh - 20px); border-radius: 24px; }
  .modal-actions .btn { width: 100%; }
  .diary-form {
    margin-bottom: 70px;
  }
  .ebook-heading {
    align-items: stretch;
    flex-direction: column;
  }
  .ebook-search-bar,
  .ebook-search-actions {
    display: grid;
    grid-template-columns: 1fr;
  }
  .ebook-viewer {
    grid-template-columns: 1fr;
  }
  .ebook-nav {
    width: 100%;
    height: 48px;
    border-radius: 16px;
  }
  .ebook-page {
    padding: 16px;
    order: -1;
  }
  .ebook-page-meta {
    flex-direction: column;
  }
  .ebook-sheet {
    padding: 18px;
  }
  .ebook-photo {
    min-height: 280px;
  }
  .ebook-note-grid {
    grid-template-columns: 1fr;
  }
  .timeline-item {
    gap: 14px;
  }
  .timeline-side {
    justify-items: start;
  }
  .item-actions {
    justify-content: flex-start;
  }
  .plan-card { min-height: auto; }
  .plan-card p { min-height: 0; }
  .mobile-fixed-cta {
    position: fixed;
    left: 14px;
    right: 14px;
    bottom: 14px;
    z-index: 35;
    min-height: 54px;
    border-radius: 999px;
    color: #fff;
    background: linear-gradient(135deg, var(--blush), var(--lavender));
    display: none;
    align-items: center;
    justify-content: center;
    font-weight: 950;
    box-shadow: 0 16px 40px rgba(244, 127, 143, 0.32);
  }
  body.show-book-cta .mobile-fixed-cta {
    display: flex;
  }
}
