:root {
  color-scheme: light;
  --ink: #392f34;
  --muted: #82777b;
  --line: #eee2e1;
  --paper: #fffdfb;
  --cream: #fbf5f1;
  --rose: #b96878;
  --rose-dark: #8f4859;
  --blue: #567b8f;
  --shadow: 0 14px 38px rgb(72 49 55 / 8%);
  font-family: "Microsoft YaHei UI", "Microsoft YaHei", "PingFang SC", system-ui, sans-serif;
  font-synthesis: none;
  text-rendering: optimizeLegibility;
  -webkit-font-smoothing: antialiased;
}

* { box-sizing: border-box; }
html { min-width: 320px; min-height: 100%; background: var(--cream); scroll-behavior: smooth; }
body { margin: 0; min-height: 100vh; color: var(--ink); background: linear-gradient(180deg, #fffaf7 0, var(--cream) 460px, #fff 100%); font-size: 16px; line-height: 1.7; }
.home-document { min-width: 0; min-height: 100vh; display: grid; place-items: center; margin: 0; padding: 14px; color: #000; background: #faf5f1; font-family: "Microsoft YaHei UI", "Microsoft YaHei", Arial, sans-serif; font-size: 16px; line-height: normal; }
.home-document__content { width: min(540px, 100%); margin: 0; padding: 10px; overflow: hidden; border: 1px solid #eee3df; border-radius: 14px; background: #fff; box-shadow: 0 8px 24px rgb(72 49 55 / 7%); text-align: center; }
a { color: var(--rose-dark); text-decoration-thickness: 1px; text-underline-offset: 3px; }
a:hover { color: #743647; }
a:focus-visible, button:focus-visible, input:focus-visible, textarea:focus-visible, select:focus-visible { outline: 3px solid #6b99ab; outline-offset: 3px; }
button, input, textarea, select { font: inherit; }
img { max-width: 100%; }
.visually-hidden { position: absolute !important; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip: rect(0, 0, 0, 0); white-space: nowrap; border: 0; }

.site-header { position: relative; z-index: 2; background: rgb(255 253 251 / 92%); border-bottom: 1px solid rgb(238 226 225 / 85%); }
.site-header__inner { width: min(1140px, calc(100% - 40px)); min-height: 78px; margin: 0 auto; display: flex; align-items: center; justify-content: space-between; gap: 30px; }
.brand { display: inline-flex; flex: 0 0 auto; align-items: center; gap: 11px; color: var(--ink); text-decoration: none; }
.brand__mark { display: grid; width: 42px; height: 42px; place-items: center; border: 1px solid #dcaab2; border-radius: 50%; color: var(--rose-dark); font-family: Georgia, serif; font-size: 13px; letter-spacing: -.04em; }
.brand__name { font-family: Georgia, "Times New Roman", serif; font-size: 18px; letter-spacing: .025em; }
.site-nav { display: flex; align-items: center; justify-content: flex-end; flex-wrap: wrap; gap: 8px 22px; }
.site-nav a { color: #675b60; font-size: 14px; text-decoration: none; }
.site-nav a:hover { color: var(--rose-dark); }
.page-shell { width: min(1080px, calc(100% - 40px)); min-height: calc(100vh - 158px); margin: 0 auto; padding: 48px 0 72px; }
.site-footer { display: flex; align-items: center; justify-content: center; flex-wrap: wrap; gap: 8px 24px; min-height: 80px; padding: 20px; color: var(--muted); border-top: 1px solid var(--line); font-size: 13px; }
.site-footer p { margin: 0; }
.site-footer a { color: var(--muted); }

.home-splash { display: block; text-align: center; }
.home-splash__image { display: block; width: min(500px, 100%); height: auto; }
.home-splash__image { margin: 0 auto; }
.home-splash__copyright { margin: 0; color: #000; font-size: 16px; }

.eyebrow { margin: 0 0 9px; color: var(--rose); font-size: 11px; font-weight: 700; letter-spacing: .16em; line-height: 1.4; text-transform: uppercase; }
.page-heading { max-width: 760px; margin: 0 auto 35px; text-align: center; }
.page-heading h1, .post-detail__header h1, .form-card h1 { margin: 0; font-family: Georgia, "Noto Serif SC", "Songti SC", serif; font-size: clamp(30px, 5vw, 45px); font-weight: 500; letter-spacing: .03em; line-height: 1.25; }
.page-heading > p:last-child { margin: 14px 0 0; color: var(--muted); }
.page-heading--compact { margin-bottom: 25px; }
.page-heading--compact h1 { font-size: clamp(28px, 4vw, 38px); }
.section-block, .blessing-section { margin-top: 52px; }
.section-heading { display: flex; align-items: end; justify-content: space-between; gap: 20px; margin-bottom: 18px; }
.section-heading h2 { margin: 0; font-family: Georgia, "Noto Serif SC", "Songti SC", serif; font-size: 27px; font-weight: 500; }
.breadcrumbs { display: flex; flex-wrap: wrap; align-items: center; gap: 9px; margin: 0 0 25px; color: var(--muted); font-size: 13px; }
.breadcrumbs a { color: var(--muted); }

.wedding-cover { position: relative; overflow: hidden; border: 1px solid #f0dfdb; border-radius: 18px; background: #f9eeea; box-shadow: var(--shadow); }
.wedding-cover__art { display: flex; justify-content: center; background: #fff; }
.wedding-cover__art img { display: block; width: min(100%, 1002px); height: auto; }
.wedding-cover__intro { padding: 28px 34px 32px; text-align: center; background: linear-gradient(135deg, #fff9f6, #f9ece8); }
.wedding-cover__intro h1 { margin: 0; font-family: Georgia, "Noto Serif SC", "Songti SC", serif; font-size: clamp(27px, 5vw, 42px); font-weight: 500; }
.wedding-cover__intro > p:last-child { margin: 8px 0 0; color: var(--muted); }
.memory-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 14px; }
.memory-card { display: grid; grid-template-columns: 52px minmax(0, 1fr) 18px; align-items: center; gap: 16px; min-height: 112px; padding: 18px 22px; border: 1px solid transparent; border-radius: 14px; color: var(--ink); text-decoration: none; transition: transform .18s ease, box-shadow .18s ease; }
.memory-card:hover { color: var(--ink); transform: translateY(-2px); box-shadow: var(--shadow); }
.memory-card strong, .memory-card small { display: block; }
.memory-card strong { font-family: "Noto Serif SC", "Songti SC", serif; font-size: 18px; font-weight: 600; }
.memory-card small { margin-top: 3px; color: #796f72; font-size: 13px; }
.memory-card__number { color: var(--rose-dark); font-family: Georgia, serif; font-size: 24px; }
.memory-card--rose { background: #f9eaec; border-color: #f0d8dc; }
.memory-card--gold { background: #faf1dd; border-color: #f0e4c6; }
.memory-card--green { background: #edf3e7; border-color: #dce8d5; }
.memory-card--blue { background: #eaf1f3; border-color: #d8e6ea; }
.memory-card--lavender { background: #f1edf5; border-color: #e5ddea; }
.memory-card--peach { background: #f8ede6; border-color: #f0ded4; }

.album-groups { display: grid; gap: 36px; }
.album-card-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 14px; }
.album-card { position: relative; display: flex; min-height: 155px; flex-direction: column; justify-content: space-between; padding: 22px; overflow: hidden; border: 1px solid var(--line); border-radius: 14px; color: var(--ink); background: linear-gradient(145deg, #fff, #f9efed); text-decoration: none; box-shadow: 0 7px 20px rgb(72 49 55 / 4%); }
.album-card::after { position: absolute; right: -25px; bottom: -48px; width: 135px; height: 135px; border: 1px solid rgb(185 104 120 / 16%); border-radius: 50%; content: ""; }
.album-card__label { font-family: Georgia, "Noto Serif SC", "Songti SC", serif; font-size: 21px; }
.album-card__meta { color: var(--muted); font-size: 13px; }
.album-card:hover { color: var(--rose-dark); border-color: #dcb2ba; }
.photo-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(min(100%, 218px), 1fr)); gap: 13px; }
.photo-tile { display: block; overflow: hidden; aspect-ratio: 4 / 3; border: 1px solid #eadedb; border-radius: 11px; background: #f4eae7; box-shadow: 0 5px 16px rgb(72 49 55 / 6%); }
.photo-tile img { display: block; width: 100%; height: 100%; object-fit: cover; transition: transform .25s ease; }
.photo-tile:hover img { transform: scale(1.035); }
.muted-note { margin: 18px 0; color: var(--muted); font-size: 13px; }
.lightbox { position: fixed; width: min(96vw, 1180px); max-width: none; max-height: 94vh; padding: 48px 60px 24px; overflow: visible; border: 1px solid rgb(255 255 255 / 25%); border-radius: 16px; color: #fff; background: #201a1b; box-shadow: 0 24px 80px rgb(0 0 0 / 44%); }
.lightbox::backdrop { background: rgb(22 18 19 / 82%); }
.lightbox figure { display: grid; max-height: calc(94vh - 100px); place-items: center; gap: 10px; margin: 0; }
.lightbox figure img { display: block; max-width: 100%; max-height: calc(94vh - 145px); object-fit: contain; }
.lightbox figcaption { color: #eee3e4; font-size: 14px; }
.lightbox button { position: absolute; display: grid; width: 44px; height: 44px; place-items: center; border: 1px solid rgb(255 255 255 / 25%); border-radius: 50%; color: white; background: rgb(255 255 255 / 10%); font-size: 26px; cursor: pointer; }
.lightbox__close { top: 10px; right: 12px; }
.lightbox__previous { top: 50%; left: 10px; transform: translateY(-50%); }
.lightbox__next { top: 50%; right: 10px; transform: translateY(-50%); }

.diary-list { display: grid; gap: 15px; }
.diary-card { display: grid; grid-template-columns: 130px minmax(0, 1fr); gap: 22px; padding: 24px 28px; border: 1px solid var(--line); border-radius: 14px; background: var(--paper); box-shadow: 0 6px 20px rgb(72 49 55 / 4%); }
.diary-card__date { padding-top: 3px; color: var(--rose-dark); font-family: Georgia, serif; font-size: 16px; }
.diary-card__body h2 { margin: 0; font-family: Georgia, "Noto Serif SC", "Songti SC", serif; font-size: 23px; font-weight: 500; line-height: 1.35; }
.diary-card__body h2 a { color: var(--ink); text-decoration: none; }
.diary-card__body h2 a:hover { color: var(--rose-dark); }
.diary-card__excerpt { margin: 11px 0; color: #61575a; white-space: pre-line; overflow-wrap: anywhere; }
.diary-card__meta, .post-detail__meta { margin: 0; color: var(--muted); font-size: 13px; }
.post-detail { max-width: 830px; margin: 0 auto; }
.post-detail__header { padding: 26px 0 22px; border-bottom: 1px solid var(--line); }
.post-detail__header h1 { font-size: clamp(30px, 4.5vw, 42px); }
.post-detail__meta { margin-top: 12px; }
.post-content { min-height: 190px; padding: 30px 0 48px; color: #41383b; font-size: 17px; line-height: 2; white-space: pre-wrap; overflow-wrap: anywhere; }

.form-card, .blessing-form-card { padding: 28px; border: 1px solid var(--line); border-radius: 16px; background: var(--paper); box-shadow: var(--shadow); }
.form-card--narrow { width: min(100%, 540px); margin: 30px auto; }
.form-card h1, .form-card h2, .blessing-form-card h2 { margin: 0 0 12px; font-family: Georgia, "Noto Serif SC", "Songti SC", serif; font-weight: 500; }
.form-card h2, .blessing-form-card h2 { font-size: 24px; }
.form-card > p, .blessing-form-card > p { color: var(--muted); }
.stacked-form { display: grid; gap: 9px; margin-top: 18px; }
.stacked-form label { margin-top: 8px; color: #52494c; font-size: 14px; font-weight: 650; }
.stacked-form input, .stacked-form textarea, .stacked-form select { width: 100%; min-width: 0; padding: 11px 13px; border: 1px solid #dcd0d0; border-radius: 8px; color: var(--ink); background: #fff; }
.stacked-form textarea { resize: vertical; }
.stacked-form input:focus, .stacked-form textarea:focus, .stacked-form select:focus { border-color: #a56a78; }
.button { display: inline-flex; min-height: 43px; align-items: center; justify-content: center; gap: 8px; padding: 9px 18px; border: 1px solid transparent; border-radius: 999px; font-size: 14px; font-weight: 650; text-align: center; text-decoration: none; cursor: pointer; }
.button--primary { color: #fff; background: var(--rose-dark); }
.button--primary:hover { color: #fff; background: #783b4a; }
.button--secondary { color: #624f54; border-color: #dfd1d1; background: #fff; }
.button--plain { color: var(--rose-dark); background: transparent; }
.button:disabled { opacity: .55; cursor: not-allowed; }
.text-link { display: inline-block; margin-top: 15px; }
.field-error, .validation-summary { color: #9c3e4b; font-size: 13px; }
.validation-summary:empty { display: none; }
.validation-summary { padding: 10px 12px; border: 1px solid #f0c7c9; border-radius: 8px; background: #fff5f5; }
.notice { margin: 22px 0; padding: 16px 18px; border: 1px solid #eadfda; border-radius: 11px; color: #5f5357; background: #fff; }
.notice p { margin: 0; }
.notice--warm { border-color: #edddc9; background: #fff9ef; }
.notice--success { border-color: #d6e9d8; color: #315e3d; background: #f2faf2; }
.notice .button { margin-top: 12px; }
.captcha-field { display: grid; gap: 8px; }
.captcha-image { display: block; width: min(100%, 310px); height: auto; border: 1px solid var(--line); border-radius: 8px; background: #fff7f2; }
.captcha-field__row { display: flex; align-items: center; flex-wrap: wrap; gap: 12px; }
.captcha-field__row input { width: 190px; letter-spacing: .16em; }
.captcha-field__row .text-link { margin: 0; }

.blessing-form-card { margin: 0 auto 50px; }
.blessing-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(min(100%, 260px), 1fr)); gap: 14px; }
.blessing-card { display: flex; min-height: 170px; flex-direction: column; justify-content: space-between; padding: 20px; border: 1px solid rgb(93 73 66 / 13%); border-radius: 6px 16px 16px 16px; box-shadow: 0 8px 22px rgb(72 49 55 / 7%); }
.blessing-card__message { margin: 0; color: #403638; white-space: pre-wrap; overflow-wrap: anywhere; }
.blessing-card footer { display: flex; justify-content: space-between; gap: 10px; margin-top: 22px; color: #76696e; font-size: 12px; }
.blessing-card footer strong { color: #5b454b; font-weight: 650; }
.blessing-card--warm { background: #fffdf8; }
.blessing-card--yellow { background: #fff7d6; }
.blessing-card--gold { background: #fff1c2; }
.blessing-card--green { background: #e9f6da; }
.blessing-card--sage { background: #eef0e5; }
.blessing-card--pink { background: #fbe3e5; }
.blessing-card--coral { background: #f8d9d7; }
.blessing-card--mint { background: #dff3e8; }
.blessing-card--blue { background: #ddeeed; }
.count-pill { display: inline-grid; min-width: 32px; height: 32px; place-items: center; padding: 0 9px; border-radius: 999px; color: var(--rose-dark); background: #f8e8eb; font: 15px Georgia, serif; vertical-align: 3px; }

.admin-toolbar { display: flex; align-items: center; flex-wrap: wrap; gap: 10px; margin: 18px 0 26px; }
.admin-toolbar form { margin: 0; }
.admin-stat-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 14px; margin: 22px 0; }
.admin-stat { display: grid; gap: 4px; padding: 20px; border: 1px solid var(--line); border-radius: 12px; background: #fff; }
.admin-stat span { color: var(--muted); font-size: 13px; }
.admin-stat strong { color: var(--rose-dark); font: 28px Georgia, serif; }
.admin-table-wrap { overflow-x: auto; border: 1px solid var(--line); border-radius: 12px; background: #fff; }
.admin-table { width: 100%; border-collapse: collapse; text-align: left; }
.admin-table th, .admin-table td { padding: 12px 16px; border-bottom: 1px solid var(--line); vertical-align: top; }
.admin-table th { color: #55484d; background: #fbf4f2; font-size: 13px; }
.admin-table tr:last-child td { border-bottom: 0; }
.security-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); align-items: start; gap: 18px; margin: 20px 0; }
.admin-login { margin-top: 5vh; }

@media (max-width: 720px) {
  .site-header__inner { width: min(100% - 28px, 600px); min-height: 0; align-items: flex-start; flex-direction: column; gap: 10px; padding: 15px 0 13px; }
  .site-nav { justify-content: flex-start; gap: 7px 17px; }
  .site-nav a { font-size: 13px; }
  .page-shell { width: calc(100% - 28px); padding: 32px 0 50px; }
  .memory-grid, .security-grid { grid-template-columns: 1fr; }
  .memory-card { min-height: 92px; padding: 14px 16px; }
  .diary-card { grid-template-columns: 1fr; gap: 5px; padding: 19px; }
  .diary-card__date { font-size: 14px; }
  .album-card-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .wedding-cover__intro { padding: 22px 18px 24px; }
  .form-card, .blessing-form-card { padding: 21px 18px; }
  .admin-stat-grid { grid-template-columns: 1fr; }
  .lightbox { width: 100vw; max-width: none; padding: 48px 42px 20px; border-radius: 0; }
  .lightbox__previous { left: 3px; }
  .lightbox__next { right: 3px; }
}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { scroll-behavior: auto !important; transition-duration: .01ms !important; }
}

@media (max-width: 500px) {
  .album-card-grid { grid-template-columns: minmax(0, 1fr); }
}

/* The wedding archive keeps its original image menu and left-side navigation. */
.wedding-home-document {
  min-width: 0;
  min-height: 100vh;
  display: grid;
  place-items: center;
  padding: 12px;
  background: #faf5f1;
}
.wedding-home-page {
  width: min(1002px, 100%);
  margin: 0;
}
.wedding-surface {
  position: relative;
  width: 100%;
  overflow: hidden;
  border: 1px solid #eee3df;
  border-radius: 14px;
  background: #fff;
  box-shadow: 0 8px 24px rgb(72 49 55 / 7%);
}
.wedding-surface--home { width: min(1002px, 100%); }
.wedding-home-original {
  display: block;
  width: 100%;
  height: auto;
}
.wedding-home-hotspots {
  position: absolute;
  z-index: 2;
  inset: 0;
}
.wedding-home-hotspot {
  position: absolute;
  z-index: 1;
  display: block;
  border-radius: 3px;
  background: transparent;
}
.wedding-home-hotspot:hover { background: rgb(255 255 255 / 12%); }
.wedding-home-hotspot:focus-visible {
  outline: 2px solid #9a5663;
  outline-offset: 1px;
  background: rgb(255 255 255 / 18%);
}
.wedding-home-hotspot--home { left: 14.97%; top: 16.61%; width: 14.87%; height: 4.35%; }
.wedding-home-hotspot--photos { left: 14.87%; top: 21.94%; width: 15.77%; height: 4.03%; }
.wedding-home-hotspot--ceremony { left: 14.57%; top: 26.45%; width: 18.26%; height: 4.84%; }
.wedding-home-hotspot--honeymoon { left: 14.77%; top: 31.61%; width: 19.96%; height: 4.84%; }
.wedding-home-hotspot--diary { left: 14.77%; top: 36.77%; width: 19.36%; height: 5.32%; }
.wedding-home-hotspot--blessing { left: 14.57%; top: 42.42%; width: 21.06%; height: 4.84%; }
.wedding-page-footer {
  min-height: 20px;
  padding: 2px 7px;
  color: #111;
  background: #c9c9c9;
  font-family: Arial, "Microsoft YaHei UI", sans-serif;
  font-size: 12px;
  line-height: 16px;
}
.wedding-page-footer--home { min-height: 24px; }

.wedding-document {
  min-width: 0;
  color: #332d2d;
  background: #fff;
  font-family: "Microsoft YaHei UI", "Microsoft YaHei", "PingFang SC", "Songti SC", serif;
}
.wedding-shell {
  display: grid;
  width: min(1000px, calc(100% - 24px));
  grid-template-columns: 150px minmax(0, 850px);
  align-items: stretch;
  gap: 0;
  margin: auto;
}
.wedding-sidebar {
  min-width: 0;
  padding: 0;
}
.wedding-sidebar-image {
  display: block;
  width: 150px;
  height: 600px;
}
.wedding-content {
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  grid-template-rows: 1fr auto;
  min-width: 0;
  padding: 18px 18px 0;
  border-left: 1px solid #eee3df;
}
.wedding-page-body,
.wedding-page-height-guide {
  grid-column: 1;
  grid-row: 1;
  min-width: 0;
}
.wedding-page-body,
.wedding-page-height-guide { display: flex; flex-direction: column; }
.wedding-page-height-guide {
  visibility: hidden;
  pointer-events: none;
  user-select: none;
}
.wedding-content > .wedding-page-footer { grid-column: 1; grid-row: 2; }
.wedding-document {
  min-height: 100vh;
  display: grid;
  place-items: safe center;
  padding: 20px 12px;
  background: #faf5f1;
}
.wedding-page-footer:not(.wedding-page-footer--home) {
  margin: 0 -18px 0;
  border: 0;
  color: #111;
  background: transparent;
}
.wedding-shell--curved { min-height: 740px; align-items: stretch; overflow: hidden; }
.wedding-shell--curved .wedding-content { min-height: 600px; height: auto; overflow: visible; }
.wedding-page-body > .page-heading,
.wedding-page-body > .form-card--narrow,
.wedding-page-height-guide > .page-heading {
  max-width: none;
  margin: 0 0 22px;
  text-align: left;
}
.wedding-content .page-heading > .eyebrow,
.wedding-page-body > .form-card--narrow > .eyebrow,
.wedding-content .album-group .section-heading .eyebrow,
.wedding-content .blessing-section > .section-heading .eyebrow,
.wedding-content .post-detail__header > .eyebrow { display: none; }
.wedding-content .page-heading h1,
.wedding-content .post-detail__header h1,
.wedding-content .form-card h1 {
  font-size: clamp(25px, 3vw, 35px);
}
.wedding-page-height-guide__heading {
  margin: 0;
  font-family: Georgia, "Noto Serif SC", "Songti SC", serif;
  font-size: clamp(25px, 3vw, 35px);
  font-weight: 500;
  letter-spacing: .03em;
  line-height: 1.25;
}
.wedding-page-body > .page-heading > p:last-child { margin-top: 7px; }
.wedding-content .section-block,
.wedding-content .blessing-section { margin-top: 28px; }
.wedding-content .album-groups { gap: 24px; }
.wedding-content .album-card-grid {
  grid-template-columns: repeat(auto-fit, minmax(min(100%, 175px), 1fr));
  gap: 11px;
}
.wedding-content .album-card {
  min-height: 92px;
  padding: 15px 17px;
  border-radius: 10px;
  box-shadow: none;
}
.wedding-content .album-card__label { font-size: 18px; }
.wedding-content .photo-grid {
  grid-template-columns: repeat(auto-fill, minmax(min(100%, 178px), 1fr));
  align-items: start;
  gap: 12px;
}
.wedding-content .photo-tile {
  display: flex;
  aspect-ratio: 4 / 3;
  align-items: center;
  justify-content: center;
  min-width: 0;
  min-height: 0;
  border-radius: 8px;
  background: #f6f1ee;
  position: relative;
  overflow: hidden;
}
.wedding-content .photo-tile--placeholder {
  visibility: hidden;
  pointer-events: none;
  user-select: none;
}
.wedding-content .photo-tile img {
  display: block;
  width: auto;
  height: auto;
  max-width: 100%;
  max-height: 100%;
  object-fit: contain;
  flex: 0 0 auto;
}
.gallery-preview-notice {
  min-height: 19px;
  margin: 2px 0 8px;
  padding: 0;
  border: 0;
  color: #71686a;
  background: transparent;
  font-size: 11px;
}
.photo-group-navigation {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin: -8px 0 15px;
  padding-bottom: 10px;
  border-bottom: 1px solid #eee2e1;
}
.photo-group-link {
  display: inline-flex;
  min-height: 31px;
  align-items: center;
  padding: 4px 10px;
  border: 1px solid #e5dcda;
  border-radius: 3px;
  color: #665b5f;
  background: #fff;
  font-size: 13px;
  text-decoration: none;
}
.photo-group-link:hover,
.photo-group-link.is-active {
  border-color: #8f4859;
  color: #8f4859;
  background: #faf1f2;
}
.photo-group-link.is-active { font-weight: 700; }
.photo-part-navigation {
  display: flex;
  flex-wrap: wrap;
  gap: 7px;
  margin: -10px 0 17px;
}
.photo-part-link {
  display: inline-flex;
  min-height: 32px;
  align-items: center;
  padding: 4px 12px;
  border: 1px solid #d9ccc8;
  border-radius: 2px;
  color: #51464a;
  background: #fff;
  font-size: 13px;
  text-decoration: none;
}
.photo-part-link.is-active,
.photo-part-link:hover {
  border-color: #8f4859;
  color: #fff;
  background: #8f4859;
}
.gallery-pagination {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 9px;
  margin: 20px 0 4px;
  font-size: 13px;
}
.gallery-pagination__numbers { display: inline-flex; align-items: center; gap: 5px; }
.gallery-pagination__numbers a,
.gallery-pagination__numbers span,
.gallery-pagination__step {
  display: inline-grid;
  min-width: 34px;
  min-height: 34px;
  place-items: center;
  padding: 3px 8px;
  border: 1px solid #ded3d0;
  border-radius: 4px;
  color: #57464b;
  background: #fff;
  text-decoration: none;
}
.gallery-pagination__numbers .is-current { border-color: #8f4859; color: #fff; background: #8f4859; }
.gallery-pagination .is-disabled { color: #aaa; background: #faf8f7; }
.wedding-content .diary-list { gap: 11px; }
.wedding-content .diary-card {
  padding: 12px 16px;
  border-radius: 9px;
  box-shadow: none;
}
.wedding-content .diary-card__body > .eyebrow { display: none; }
.wedding-content .diary-card__body h2 { font-size: 21px; }
.wedding-content .post-detail {
  max-width: none;
  margin: 0;
}
.wedding-content .post-detail__header { padding: 4px 0 18px; }
.wedding-content .post-detail__meta { margin-top: 9px; }
.wedding-content .post-content {
  min-height: 0;
  padding: 20px 0 28px;
}
.wedding-content .form-card,
.wedding-content .form-card--narrow {
  padding: 22px;
  border-radius: 12px;
  box-shadow: none;
}
.wedding-content .blessing-section { margin-top: 24px; }
.wedding-content .blessing-section .section-heading { margin-bottom: 14px; }
.wedding-content .blessing-section .section-heading h2 { font-size: 23px; }
.blessing-board { width: 100%; }
.wedding-page-body:has(> .blessing-board--fill) {
  display: grid;
  grid-template-rows: minmax(0, 1fr);
}
.wedding-page-body > .blessing-board--fill {
  display: grid;
  height: 100%;
  min-height: 0;
  grid-template-rows: auto minmax(0, 1fr);
}
.blessing-board--fill .blessing-paper {
  width: min(100%, 900px);
  height: 100%;
  min-height: 0;
  justify-self: center;
}
.blessing-board--fill .blessing-note-board {
  height: 100%;
  min-height: 0;
}
.blessing-board__header {
  display: flex;
  min-height: 30px;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 0 8px 7px;
  color: #51464a;
  font-family: Arial, "Microsoft YaHei UI", sans-serif;
  font-size: 12px;
  line-height: 20px;
}
.blessing-board__header a { color: #51464a; font-weight: 700; text-decoration: none; }
.blessing-board__header a:hover { text-decoration: underline; }
.blessing-board__header span { flex: 0 0 auto; white-space: nowrap; }
.blessing-paper {
  min-height: 570px;
  background: #fff url("/wedding/images/blessing-paper.gif") repeat;
}
.blessing-note-board {
  position: relative;
  display: block;
  width: 100%;
  min-height: 570px;
  height: 570px;
  overflow: hidden;
  padding: 0;
}
.blessing-note {
  position: absolute;
  top: 80px;
  left: 10px;
  z-index: 1;
  display: flex;
  min-width: 0;
  min-height: 130px;
  flex-direction: column;
  padding: 5px 7px 8px;
  border: 1px ridge #c6a52d;
  border-radius: 0;
  color: #111;
  box-shadow: 1px 2px 3px rgb(0 0 0 / 14%);
  font-family: Arial, "Microsoft YaHei UI", sans-serif;
  font-size: 12px;
  line-height: 1.35;
  transform: rotate(-.35deg);
  transition: box-shadow .12s ease, transform .12s ease;
}
.blessing-note:nth-child(3n) { transform: rotate(.55deg); }
.blessing-note:nth-child(4n) { transform: rotate(-.8deg); }
.blessing-note:nth-child(5n) { transform: rotate(.8deg); }
.blessing-note__handle {
  display: flex;
  min-height: 25px;
  align-items: flex-start;
  justify-content: space-between;
  gap: 4px;
  overflow-wrap: anywhere;
  cursor: move;
  touch-action: none;
}
.blessing-note__handle span { min-width: 0; }
.blessing-note__handle button {
  display: grid;
  width: 21px;
  height: 21px;
  flex: 0 0 21px;
  place-items: center;
  margin: -2px -4px 0 0;
  padding: 0;
  border: 0;
  color: #111;
  background: transparent;
  font: 16px/1 Arial, sans-serif;
  cursor: pointer;
}
.blessing-note__handle button:hover { color: #b21f43; }
.blessing-note__message {
  min-width: 0;
  margin: 2px 0 8px;
  font-size: 13px;
  line-height: 1.45;
  overflow-wrap: anywhere;
  white-space: pre-wrap;
}
.blessing-note footer { display: flex; justify-content: flex-end; gap: 8px; margin-top: auto; text-align: right; }
.blessing-note footer strong { font-weight: 400; }
.blessing-note.is-dragging {
  z-index: 1000 !important;
  cursor: grabbing;
  box-shadow: 4px 8px 18px rgb(0 0 0 / 28%);
}
.blessing-note--legacy-random:nth-child(9n + 1) { background-color: #ffd616; }
.blessing-note--legacy-random:nth-child(9n + 2) { background-color: #ffcc33; }
.blessing-note--legacy-random:nth-child(9n + 3) { background-color: #fff044; }
.blessing-note--legacy-random:nth-child(9n + 4) { background-color: #ccff99; }
.blessing-note--legacy-random:nth-child(9n + 5) { background-color: #ffffcc; }
.blessing-note--legacy-random:nth-child(9n + 6) { background-color: #fff1c2; }
.blessing-note--legacy-random:nth-child(9n + 7) { background-color: #e8ffff; }
.blessing-note--legacy-random:nth-child(9n + 8) { background-color: #ffeaf8; }
.blessing-note--legacy-random:nth-child(9n) { background-color: #e1f5fd; }
.blessing-note--warm { background-color: #fff4a8; }
.blessing-note--default { background-color: #ffd616; }
.blessing-note--white { background-color: #fff; }
.blessing-note--yellow { background-color: #ffffcc; }
.blessing-note--gold { background-color: #ffcc33; }
.blessing-note--green { background-color: #ccff99; }
.blessing-note--sage { background-color: #cccc99; }
.blessing-note--pink { background-color: #ffcccc; }
.blessing-note--coral { background-color: #ff9999; }
.blessing-note--mint { background-color: #66ff99; }
.blessing-note--blue { background-color: #669999; }
.blessing-note--lavender { background-color: #e8ffff; }
.blessing-note--peach { background-color: #ffeaf8; }
.blessing-note--sky { background-color: #e1f5fd; }
.blessing-note--gray { background-color: #fff1c2; }
.blessing-note-board.is-randomized .blessing-note { transform: none; }

.blessing-dialog {
  position: fixed;
  z-index: 21;
  top: 50%;
  left: 50%;
  width: min(590px, calc(100vw - 24px));
  max-width: none;
  max-height: min(90vh, 820px);
  margin: 0;
  padding: 0;
  overflow: hidden;
  border: 1px solid #e9dcda;
  border-radius: 13px;
  color: var(--ink);
  background: #fffdfb;
  box-shadow: 0 22px 70px rgb(0 0 0 / 25%);
  transform: translate(-50%, -50%);
}
.blessing-dialog::backdrop { background: rgb(28 22 24 / 48%); }
.blessing-dialog__header {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 18px;
  padding: 17px 20px 13px;
  border-bottom: 1px solid var(--line);
  background: #fffaf7;
}
.blessing-dialog__header h2 {
  margin: 0;
  font-family: Georgia, "Noto Serif SC", "Songti SC", serif;
  font-size: 23px;
  font-weight: 500;
}
.blessing-dialog__header p { margin: 5px 0 0; color: var(--muted); font-size: 13px; }
.blessing-dialog__header form { flex: 0 0 auto; margin: -5px -8px 0 0; }
.blessing-dialog__close {
  display: grid;
  width: 40px;
  height: 40px;
  place-items: center;
  border: 0;
  border-radius: 50%;
  color: #66595d;
  background: transparent;
  font-size: 28px;
  cursor: pointer;
}
.blessing-dialog__close:hover { background: #f3e9e6; }
.blessing-dialog__body { max-height: calc(min(90vh, 820px) - 82px); padding: 17px 20px 22px; overflow: auto; }
.blessing-dialog__body .stacked-form { gap: 7px; margin-top: 0; }
.blessing-dialog__body .stacked-form label { margin-top: 6px; }
.blessing-dialog__body .captcha-image { width: min(100%, 310px); }
.blessing-color-palette {
  display: grid;
  grid-template-columns: repeat(7, minmax(34px, 1fr));
  gap: 6px 4px;
  margin: 2px 0 5px;
}
.blessing-color-choice {
  position: relative;
  display: grid;
  justify-items: center;
  gap: 2px;
  margin: 0 !important;
  padding: 2px;
  color: #51484a;
  cursor: pointer;
}
.blessing-color-choice input {
  position: absolute;
  width: 1px;
  height: 1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  clip-path: inset(50%);
  white-space: nowrap;
}
.blessing-color-swatch {
  display: block;
  width: 27px;
  height: 23px;
  border: 1px solid #847d75;
  box-shadow: inset 0 0 0 1px rgb(255 255 255 / 35%);
}
.blessing-color-swatch--default { background: #ffd616; }
.blessing-color-swatch--white { background: #fff; }
.blessing-color-swatch--yellow { background: #ffffcc; }
.blessing-color-swatch--gold { background: #ffcc33; }
.blessing-color-swatch--green { background: #ccff99; }
.blessing-color-swatch--sage { background: #cccc99; }
.blessing-color-swatch--pink { background: #ffcccc; }
.blessing-color-swatch--coral { background: #ff9999; }
.blessing-color-swatch--mint { background: #66ff99; }
.blessing-color-swatch--blue { background: #669999; }
.blessing-color-swatch--lavender { background: #cc99cc; }
.blessing-color-swatch--peach { background: #cc9966; }
.blessing-color-swatch--sky { background: #33ccff; }
.blessing-color-swatch--gray { background: #eee; }
.blessing-color-choice input:checked + .blessing-color-swatch { outline: 2px solid #574348; outline-offset: 2px; }
.blessing-color-choice input:focus-visible + .blessing-color-swatch { outline: 3px solid #436f98; outline-offset: 2px; }
.blessing-color-choice small { font-size: 10px; font-weight: 400; line-height: 1.2; white-space: nowrap; }

@media (max-width: 760px) {
  .wedding-home-document { padding: 8px; }
  .wedding-home-page { width: min(1002px, 100%); }
  .wedding-document { display: block; padding: 8px; }
  .wedding-shell {
    width: min(100%, 720px);
    grid-template-columns: minmax(0, 1fr);
    gap: 8px;
    margin: 0 auto 22px;
  }
  .wedding-shell--curved { min-height: 0; }
  .wedding-shell--curved .wedding-content { height: auto; min-height: 0; overflow: visible; }
  .wedding-sidebar { width: 150px; margin-bottom: 0; }
  .wedding-content { padding: 14px 12px 0; border-radius: 12px; }
  .wedding-page-footer:not(.wedding-page-footer--home) { margin: 12px -12px 0; }
  .wedding-page-body:has(> .blessing-board--fill) {
    display: grid;
    grid-template-rows: minmax(0, 1fr);
  }
  .wedding-page-body > .blessing-board--fill {
    display: grid;
    height: 100%;
    min-height: 0;
    grid-template-rows: auto minmax(0, 1fr);
  }
  .blessing-board--fill .blessing-paper { height: 100%; min-height: 600px; }
  .blessing-board--fill .blessing-note-board { height: 100%; min-height: 600px; }
  .gallery-pagination { gap: 4px; }
  .gallery-pagination__numbers { gap: 2px; }
  .gallery-pagination__numbers a,
  .gallery-pagination__numbers span,
  .gallery-pagination__step { min-width: 30px; min-height: 32px; padding-inline: 6px; }
}

@media (max-width: 500px) {
  .wedding-content .diary-card { grid-template-columns: 1fr; gap: 5px; padding: 15px; }
  .wedding-content .form-card,
  .wedding-content .form-card--narrow { padding: 18px 15px; }
  .blessing-board__header { align-items: flex-start; flex-direction: column; gap: 1px; padding: 4px 7px; }
  .blessing-paper { min-height: 600px; }
  .blessing-note-board { height: 600px; min-height: 600px; }
  .blessing-board--fill .blessing-note-board { height: 600px; min-height: 600px; }
  .blessing-note { min-height: 120px; }
  .blessing-dialog { width: calc(100vw - 16px); max-height: 94vh; border-radius: 10px; }
  .blessing-dialog__header { padding: 15px 16px 12px; }
  .blessing-dialog__body { max-height: calc(94vh - 76px); padding: 15px 16px 18px; }
}