/* 喜事将近 · 照片中的喜红、木色与树影。 */
:root {
  --wine: #722f3b;
  --wine-dark: #55232d;
  --rose: #f3e8e6;
  --paper: #faf8f4;
  --white: #fff;
  --ink: #382e2c;
  --muted: #81736c;
  --line: #e9e1d9;
  --green: #466454;
  --gold: #aa8050;
  --home-column-gap: 20px;
  --serif: "Songti SC", "STSong", "Noto Serif CJK SC", serif;
  --sans:
    -apple-system, BlinkMacSystemFont, "PingFang SC", "Microsoft YaHei",
    sans-serif;
}
* {
  box-sizing: border-box;
}
body {
  margin: 0;
  background: var(--paper);
  color: var(--ink);
  font: 16px/1.65 var(--sans);
}
button,
input,
select,
textarea {
  font: inherit;
}
button,
a,
input,
select,
textarea {
  -webkit-tap-highlight-color: transparent;
}
button {
  cursor: pointer;
  color: inherit;
  border: 0;
  background: none;
  min-height: 40px;
}
a {
  color: inherit;
  text-decoration: none;
}
button:disabled {
  opacity: 0.45;
  cursor: not-allowed;
}
button:focus-visible,
a:focus-visible,
input:focus-visible,
select:focus-visible,
textarea:focus-visible,
summary:focus-visible {
  outline: 3px solid #ac7544;
  outline-offset: 4px;
}
h1,
h2,
h3,
p {
  margin: 0;
}
h1,
h2,
h3 {
  font-weight: 500;
}
svg.icon {
  width: 20px;
  height: 20px;
  fill: none;
  stroke: currentColor;
  stroke-width: 1.65;
  stroke-linecap: round;
  stroke-linejoin: round;
  flex-shrink: 0;
}
button svg {
  pointer-events: none;
}
input,
select,
textarea {
  min-width: 0;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fff;
  color: var(--ink);
  padding: 10px 12px;
}
input[type="checkbox"] {
  accent-color: var(--wine);
  width: 20px;
  height: 20px;
  cursor: pointer;
}
small {
  font-size: 13px;
}
::selection {
  background: #edd7d4;
}
[hidden] {
  display: none !important;
}
.skip-link {
  position: fixed;
  left: 250px;
  top: -80px;
  z-index: 100;
  background: #fff;
  padding: 10px;
}
.skip-link:focus {
  top: 5px;
}
.sidebar {
  position: fixed;
  inset: 0 auto 0 0;
  width: 228px;
  background: var(--wine-dark);
  color: #f9f0e7;
  padding: 37px 22px 24px;
  display: flex;
  flex-direction: column;
  z-index: 20;
  overflow-y: auto;
}
.brand {
  display: flex;
  align-items: center;
  gap: 12px;
  font: 26px var(--serif);
  letter-spacing: 3px;
}
.brand small {
  display: block;
  font: 8px/2.8 var(--sans);
  letter-spacing: 1.4px;
  white-space: nowrap;
  color: #dec3bd;
}
.seal {
  font-size: 29px;
  width: 44px;
  height: 48px;
  display: grid;
  place-items: center;
  border: 1px solid #bc8e80;
  border-radius: 7px 7px 14px 14px;
  color: #edc6b6;
  letter-spacing: 0;
}
.nav-caption {
  font-size: 13px;
  color: #c5a4a0;
  margin: 44px 12px 14px;
  letter-spacing: 2px;
}
#navigation {
  display: flex;
  flex-direction: column;
  gap: 6px;
  flex-shrink: 0;
}
.nav-item {
  display: flex;
  align-items: center;
  gap: 12px;
  min-height: 48px;
  padding: 11px 15px;
  border-radius: 9px;
  color: #e2c9c4;
  font-size: 15px;
  transition:
    background 0.2s,
    color 0.2s;
}
.nav-item:hover {
  background: #ffffff0b;
  color: #fff;
}
.nav-item.active {
  background: #fbf6ed;
  color: var(--wine-dark);
}
.nav-item .nav-count {
  font-size: 12px;
  margin-left: auto;
  opacity: 0.65;
}
.nav-divider {
  height: 1px;
  background: #ffffff1c;
  margin: 13px 10px;
}
.sidebar-bottom {
  margin-top: auto;
  padding: 22px 12px 0;
}
.side-quote {
  font: 23px/1.8 var(--serif);
  letter-spacing: 6px;
  color: #d7b4a4;
  margin-bottom: 25px;
}
.side-progress-label {
  font-size: 13px;
  display: flex;
  justify-content: space-between;
  margin-bottom: 7px;
  color: #e2c9c4;
}
.progress-track {
  height: 4px;
  background: #e8e1d9;
  border-radius: 4px;
  overflow: hidden;
}
.progress-fill {
  height: 100%;
  background: var(--wine);
  transition: width 0.4s;
}
.sidebar .progress-track {
  background: #ffffff20;
}
.sidebar .progress-fill {
  background: #d9b6a0;
}
.side-settings {
  font-size: 14px;
  padding: 20px 0 0;
  color: #f2e1d7;
}
.local-note {
  font-size: 12px;
  color: #ccb2aa;
  margin-top: 5px;
}
.app-shell {
  margin-left: 228px;
}
.topbar {
  height: 82px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 42px;
  border-bottom: 1px solid var(--line);
  gap: 20px;
}
.breadcrumb {
  font-size: 14px;
  color: var(--muted);
}
.breadcrumb span {
  margin: 0 13px;
  color: #c7b8ad;
}
.breadcrumb strong {
  font-weight: 500;
  color: var(--ink);
}
.top-actions {
  display: flex;
  align-items: center;
  gap: 20px;
}
.search-box {
  display: flex;
  align-items: center;
  gap: 9px;
  color: #93847b;
}
.search-box input {
  background: transparent;
  border: 0;
  width: 193px;
  font-size: 14px;
  padding: 8px 0;
  outline-offset: 0;
}
.search-box kbd {
  border: 1px solid #ded3c8;
  border-radius: 4px;
  padding: 0 6px;
  font-size: 12px;
}
.couple-badge {
  display: flex;
  align-items: center;
  flex-shrink: 0;
  min-height: 48px;
  padding: 0 0 0 5px;
}
.couple-badge span {
  position: relative;
  overflow: hidden;
  width: 40px;
  height: 40px;
  border: 2px solid var(--paper);
  border-radius: 50%;
  background: #e9d1c6;
  margin-left: -5px;
}
.couple-avatar img {
  position: absolute;
  width: 168px;
  height: 252px;
  max-width: none;
}
/* 原合照中的两张脸各自取景；仅改变头像显示，保留照片原件。 */
.couple-avatar-groom img {
  left: -49px;
  top: -53px;
}
.couple-avatar-bride img {
  left: -87px;
  top: -62px;
}
#main {
  max-width: 1450px;
  min-height: calc(100vh - 160px);
  margin: auto;
  padding: 32px 42px 50px;
  outline: none;
}
.eyebrow {
  font-size: 12px;
  letter-spacing: 2.5px;
  color: var(--muted);
  text-transform: uppercase;
}
.page-heading {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 20px;
  margin-bottom: 23px;
}
.page-heading h1 {
  font: 32px/1.4 var(--serif);
  letter-spacing: 2px;
  margin-top: 5px;
}
.page-heading p {
  color: var(--muted);
  font-size: 14px;
  margin-top: 7px;
}
.primary-button {
  background: var(--wine);
  color: #fffaf5;
  border: 1px solid var(--wine);
  border-radius: 7px;
  min-height: 42px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 8px 17px;
  font-size: 14px;
  white-space: nowrap;
}
.primary-button:hover {
  background: var(--wine-dark);
}
.secondary-button {
  border: 1px solid var(--line);
  border-radius: 7px;
  padding: 7px 14px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  background: #fff;
  font-size: 14px;
}
.text-button {
  white-space: nowrap;
  flex-shrink: 0;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-size: 14px;
  color: var(--wine);
  padding: 4px 0;
}
.text-button:hover {
  text-decoration: underline;
}
.icon-button {
  display: inline-grid;
  place-items: center;
  width: 40px;
  height: 40px;
  border-radius: 50%;
  flex-shrink: 0;
}
.icon-button:hover {
  background: var(--rose);
}
.hero {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  column-gap: var(--home-column-gap);
  height: 284px;
  border-radius: 12px;
  background: #eee4d7;
  overflow: hidden;
  position: relative;
}
.hero-copy {
  padding: 28px 34px;
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  justify-content: center;
  position: relative;
  z-index: 1;
}
.hero-copy .eyebrow {
  font-size: 11px;
  color: #967353;
  letter-spacing: 2.8px;
}
.hero h2 {
  font: 36px/1.6 var(--serif);
  letter-spacing: 3px;
  color: var(--wine-dark);
  margin: 11px 0;
}
.hero-copy p {
  font-size: 14px;
  color: #866e61;
  line-height: 1.9;
}
.hero-copy .hero-sign {
  font:
    italic 22px Georgia,
    serif;
  color: var(--gold);
  margin-top: 15px;
}
.hero-images {
  display: grid;
  grid-template-columns: 1.05fr 1fr;
  gap: 5px;
  padding: 0;
  border: 0;
  overflow: hidden;
  position: relative;
  min-height: 0;
}
.hero-images img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  min-height: 0;
}
.hero-images img:first-child {
  object-position: center 44%;
}
.hero-images img:last-child {
  object-position: center 38%;
}
.hero-photo-label {
  position: absolute;
  bottom: 13px;
  right: 15px;
  color: white;
  font-size: 12px;
  background: #29221b80;
  border-radius: 20px;
  padding: 3px 11px;
  backdrop-filter: blur(8px);
}
.event-grid {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
  gap: var(--home-column-gap);
  margin: 22px 0 28px;
}
.event-card {
  min-width: 0;
  background: #fff;
  border: 1px solid var(--line);
  border-radius: 10px;
  display: flex;
  align-items: center;
  gap: 19px;
  padding: 19px 22px;
  text-align: left;
  width: 100%;
  transition:
    transform 0.2s,
    border-color 0.2s;
}
.event-card:hover {
  border-color: #b48b78;
  transform: translateY(-2px);
}
.event-stamp {
  width: 47px;
  border-right: 1px solid var(--line);
  padding-right: 17px;
  font: 25px var(--serif);
  line-height: 1.25;
  color: var(--wine);
}
.event-info {
  flex: 1;
}
.event-info h3 {
  font-size: 16px;
  margin-bottom: 3px;
}
.event-info p {
  font-size: 12px;
  color: var(--muted);
}
.event-info .event-date {
  font-size: 14px;
  color: #67574e;
  letter-spacing: 0.7px;
}
.countdown {
  text-align: right;
  color: var(--wine);
  font-size: 13px;
  white-space: nowrap;
}
.countdown strong {
  font:
    38px/1.2 Georgia,
    serif;
  margin-right: 5px;
}
.countdown small {
  display: block;
  font-size: 11px;
  color: var(--muted);
  margin-bottom: 3px;
}
.dashboard-columns {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 290px;
  gap: 26px;
}
.dashboard-tasks {
  min-width: 0;
  display: grid;
}
.dashboard-tasks > .task-collection {
  display: flex;
  flex-direction: column;
}
.dashboard-tasks .task-list {
  flex: 1;
  grid-template-columns: repeat(2, minmax(0, 1fr));
}
.dashboard-tasks > .empty {
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
}
.dashboard-aside {
  display: flex;
  flex-direction: column;
  gap: 17px;
}
.section-top {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 14px;
  gap: 12px;
}
.section-top h2 {
  font: 23px var(--serif);
}
.section-top p {
  font-size: 13px;
  color: var(--muted);
  margin-top: 4px;
}
.task-list {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  align-items: stretch;
  gap: 18px;
  scroll-margin-top: 100px;
}
.task-row {
  container-type: inline-size;
  display: grid;
  grid-template-columns: auto minmax(0, 1fr) auto;
  grid-template-rows: minmax(0, 1fr) auto;
  gap: 0 10px;
  padding: 0;
  min-width: 0;
  border: 1px solid var(--line);
  border-radius: 12px;
  background: #fff;
  overflow: hidden;
  transition:
    border-color 0.2s,
    box-shadow 0.2s;
}
.task-row:hover {
  border-color: #c4a197;
  box-shadow: 0 5px 18px #71333b0d;
}
.task-check {
  display: inline-flex;
  align-items: center;
  align-self: center;
  gap: 7px;
  min-height: 48px;
  padding: 8px 0 8px 16px;
  color: var(--muted);
  font-size: 13px;
}
.task-check input {
  margin: 0;
}
.task-content {
  grid-column: 1 / -1;
  width: 100%;
  min-width: 0;
  padding: 22px;
  text-align: left;
  display: flex;
  flex-direction: column;
  min-height: 170px;
  border-bottom: 1px solid var(--line);
  background: linear-gradient(135deg, #fbf7f1, #fff 80%);
}
.task-card-note {
  min-height: 50px;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
  color: var(--muted);
  font-size: 14px;
  line-height: 1.8;
  margin-top: 8px;
}
.task-row > .owner-tag {
  align-self: center;
  justify-self: end;
  max-width: 100%;
}
.task-row > .task-more {
  align-self: center;
  margin-right: 10px;
}
.task-pagination {
  display: flex;
  justify-content: center;
  align-items: center;
  gap: 20px;
  margin-top: 22px;
}
.task-pagination span {
  color: var(--muted);
  font-size: 14px;
}
.section-body > .task-collection {
  padding: 18px;
}
.shared-modules {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 22px;
}
.shared-module {
  padding: 0;
  min-width: 0;
  text-align: left;
  border: 1px solid var(--line);
  border-radius: 12px;
  overflow: hidden;
  background: white;
}
.shared-module > img {
  display: block;
  width: 100%;
  height: auto;
  aspect-ratio: 16 / 9;
  object-fit: cover;
  background: #eee5d9;
}
.shared-module-copy {
  display: flex;
  flex-direction: column;
  padding: 22px;
  gap: 12px;
}
.shared-module-copy strong {
  font: 24px/1.5 var(--serif);
  color: var(--wine);
}
.shared-module-copy > span {
  font-size: 14px;
  line-height: 1.8;
  color: var(--muted);
  min-height: 50px;
}
.shared-module-copy small {
  font-size: 13px;
  color: var(--wine);
  border-top: 1px solid var(--line);
  padding-top: 14px;
}
.task-title {
  display: -webkit-box;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 2;
  overflow: hidden;
  font-weight: 600;
  font-size: 16px;
  line-height: 1.7;
  overflow-wrap: anywhere;
}
.task-sub {
  display: flex;
  flex-wrap: wrap;
  gap: 7px 11px;
  align-items: center;
  font-size: 13px;
  color: var(--muted);
  margin-top: 4px;
}
.task-sub .due {
  color: var(--wine);
}
.task-row.checked .task-title {
  color: #8b857d;
  text-decoration: line-through;
  text-decoration-color: #c0b6ac;
}
.task-row.checked {
  background: #fcfbf8;
}
.owner-tag {
  border-radius: 5px;
  padding: 2px 8px;
  background: #f1eee7;
  color: #7c6e62;
  font-size: 13px;
  white-space: nowrap;
}
.owner-tag[data-owner="我"] {
  background: #f4e8e6;
  color: var(--wine);
}
.owner-tag[data-owner="爱人"] {
  background: #eaf0e8;
  color: var(--green);
}
.task-more {
  color: #a5968b;
  min-width: 30px;
  min-height: 36px;
  font-size: 19px;
  padding: 0;
}
.task-more:hover {
  color: var(--wine);
}
.task-pin {
  color: var(--gold);
  font-size: 13px;
}
.note-card {
  flex: 1;
  background: #f1e9dc;
  border: 1px solid #e6dac7;
  padding: 22px 23px;
  border-radius: 9px;
  position: relative;
}
.note-card .eyebrow {
  font-size: 10px;
  color: #96784e;
}
.note-card h3 {
  font: 22px var(--serif);
  margin: 8px 0 11px;
}
.note-card p {
  font: 17px/1.9 var(--serif);
  color: #7a6651;
  white-space: pre-wrap;
  overflow-wrap: anywhere;
}
.note-card .text-button {
  font-size: 13px;
  margin-top: 16px;
}
.progress-card {
  border: 1px solid var(--line);
  padding: 20px;
  border-radius: 9px;
  background: #fff;
}
.progress-card h3 {
  font-size: 14px;
}
.progress-numbers {
  display: flex;
  align-items: baseline;
  gap: 8px;
  margin: 10px 0;
  color: var(--muted);
  font-size: 13px;
}
.progress-numbers strong {
  font:
    31px Georgia,
    serif;
  color: var(--wine);
}
.progress-card p {
  font-size: 13px;
  color: var(--muted);
  margin-top: 12px;
}
.milestones {
  margin-top: 24px;
  padding-top: 20px;
  border-top: 1px solid var(--line);
}
.milestone-list {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
  margin-top: 12px;
}
.milestone {
  display: flex;
  align-items: center;
  gap: 6px;
  font-size: 12px;
  color: var(--green);
  background: #ebeee6;
  border-radius: 5px;
  padding: 4px 9px;
}
.milestone svg.icon {
  width: 14px;
  height: 14px;
}
.footer {
  max-width: 1450px;
  margin: 0 auto;
  padding: 18px 42px 25px;
  display: flex;
  justify-content: space-between;
  gap: 15px;
  border-top: 1px solid var(--line);
  font-size: 12px;
  color: #9b8b80;
}
.footer span:last-child {
  font-size: 10px;
  letter-spacing: 1.5px;
}
.filterbar {
  display: flex;
  gap: 12px;
  align-items: center;
  flex-wrap: wrap;
  margin: 18px 0 23px;
}
.segmented {
  display: flex;
  background: #eee8e1;
  padding: 3px;
  border-radius: 7px;
  gap: 3px;
}
.segmented button {
  font-size: 14px;
  padding: 5px 13px;
  min-height: 34px;
  border-radius: 5px;
  color: #7c6e63;
}
.segmented button.active {
  background: #fff;
  color: var(--wine);
  box-shadow: 0 1px 3px #42240f0b;
}
.filterbar select {
  font-size: 14px;
  padding: 7px 10px;
  background: transparent;
}
.filter-spacer {
  flex: 1;
}
.list-summary {
  color: var(--muted);
  font-size: 13px;
  margin-bottom: 13px;
}
.empty {
  padding: 40px 24px;
  text-align: center;
  color: var(--muted);
  background: #fff;
  border: 1px dashed var(--line);
  border-radius: 9px;
}
.empty h3 {
  font: 24px var(--serif);
  color: var(--wine);
  margin: 10px;
}
.empty p {
  font-size: 14px;
}
.empty .text-button {
  margin-top: 12px;
}
.event-banner {
  display: flex;
  align-items: center;
  gap: 25px;
  padding: 20px 27px;
  background: var(--rose);
  border-radius: 9px;
  margin-bottom: 23px;
}
.event-banner .date-large {
  font:
    31px Georgia,
    serif;
  color: var(--wine);
  letter-spacing: 1px;
}
.event-banner .event-banner-copy {
  flex: 1;
  font-size: 14px;
  color: #856964;
}
.event-banner .event-banner-copy strong {
  display: block;
  color: var(--wine);
  font-weight: 500;
  font-size: 16px;
}
.phase-nav {
  display: flex;
  flex-wrap: wrap;
  gap: 7px;
  padding: 0 0 11px;
  margin: 0 0 16px;
  scrollbar-width: thin;
}
.phase-select {
  display: none;
}
.planning-note {
  font-size: 13px;
  color: var(--muted);
  margin: 16px 0;
  line-height: 1.8;
}
.family-board {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 18px;
  margin-bottom: 18px;
}
.family-card {
  background: #fff;
  border: 1px solid var(--line);
  border-radius: 12px;
  padding: 0;
  min-width: 0;
  overflow: hidden;
  text-align: left;
  transition:
    border-color 0.2s,
    transform 0.2s;
}
.family-card:hover {
  border-color: var(--wine);
  transform: translateY(-3px);
}
.family-picture {
  display: block;
  width: 100%;
  height: auto;
  aspect-ratio: 16 / 9;
  object-fit: cover;
}
.family-copy {
  display: block;
  padding: 20px;
}
.family-title {
  display: block;
  font: 23px/1.4 var(--serif);
  color: var(--wine);
}
.family-note {
  display: block;
  font-size: 14px;
  line-height: 1.8;
  color: var(--muted);
  min-height: 50px;
  margin-top: 8px;
}
.family-action {
  display: flex;
  align-items: center;
  gap: 8px;
  border-top: 1px solid var(--line);
  margin-top: 15px;
  padding-top: 13px;
  color: var(--wine);
  font-size: 14px;
}
.family-action small {
  margin-left: auto;
  color: var(--muted);
  font-size: 13px;
}
.family-action svg {
  width: 16px;
  height: 16px;
}
.family-back {
  margin-bottom: 22px;
}
.family-toolbar {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 12px;
  margin-bottom: 18px;
}
.family-toolbar select {
  min-height: 44px;
  font-size: 14px;
}
.family-result-count {
  margin-left: auto;
  font-size: 14px;
  color: var(--muted);
}
.family-task-pane {
  scroll-margin-top: 100px;
}
.family-task-pane .task-row {
  min-height: 96px;
}
.family-pagination {
  display: flex;
  justify-content: center;
  align-items: center;
  gap: 20px;
  margin: 20px 0;
}
.family-pagination span {
  font-size: 14px;
  color: var(--muted);
}
.nav-item.nav-secondary {
  font-size: 13px;
  color: #d3b7b5;
}
.task-content.task-illustrated {
  display: grid;
  grid-template-columns: minmax(128px, 36%) minmax(0, 1fr);
  align-items: start;
  padding: 18px;
  gap: 18px;
  background: #fff;
}
.task-copy {
  display: flex;
  flex-direction: column;
  min-width: 0;
  gap: 6px;
}
.task-picture {
  display: block;
  width: 100%;
  height: auto;
  aspect-ratio: 3 / 2;
  object-fit: cover;
  border-radius: 8px;
  background: #f5f0e9;
}
.task-image-choice {
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 16px;
  font-size: 14px;
  line-height: 1.6;
  color: var(--muted);
}
.task-reference {
  margin: 0 0 18px;
  border-radius: 9px;
  overflow: hidden;
  background: #f5f0e9;
}
.task-detail-picture {
  display: block;
  width: 100%;
  height: 230px;
  object-fit: contain;
}
.task-reference figcaption {
  font-size: 12px;
  color: var(--muted);
  text-align: center;
  padding: 9px;
}
.task-reference-gallery {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
  padding: 10px 12px;
}
.task-reference-tab {
  padding: 8px 10px;
  font-size: 14px;
  color: var(--wine);
  border: 1px solid var(--line);
  border-radius: 6px;
  background: white;
}
.task-reference-tab[aria-pressed="true"] {
  color: white;
  background: var(--wine);
}
@container (max-width: 399px) {
  .task-content.task-illustrated {
    grid-template-columns: 1fr;
    padding: 0;
    gap: 0;
  }
  .task-copy { padding: 18px; }
  .task-picture { border-radius: 0; }
}
@media (max-width: 1200px) {
  .family-board { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}
.phase-nav button {
  flex-shrink: 0;
  border: 1px solid var(--line);
  padding: 6px 12px;
  border-radius: 6px;
  font-size: 13px;
  background: #fff;
}
.phase-nav .active {
  background: var(--wine);
  color: white;
  border-color: var(--wine);
}
.section-card {
  border: 1px solid var(--line);
  border-radius: 9px;
  margin-bottom: 15px;
  background: #fff;
  overflow: hidden;
  scroll-margin-top: 20px;
}
.section-card.current {
  border-color: #ba9186;
}
.section-head {
  display: flex;
  align-items: center;
  gap: 14px;
  width: 100%;
  padding: 19px 22px;
  text-align: left;
}
.phase-number {
  font:
    26px Georgia,
    serif;
  color: #bea58e;
  min-width: 30px;
}
.section-head-copy {
  flex: 1;
  min-width: 0;
}
.section-head-copy h2 {
  font-size: 17px;
  line-height: 1.6;
}
.section-head-copy p {
  font-size: 13px;
  color: var(--muted);
}
.section-head-count {
  font-size: 13px;
  color: var(--muted);
  white-space: nowrap;
}
.section-head .chevron {
  transition: transform 0.2s;
}
.section-card.collapsed .section-body {
  display: none;
}
.section-card.collapsed .chevron {
  transform: rotate(-90deg);
}
.section-body {
  border-top: 1px solid var(--line);
}
.section-body .task-list {
  border: 0;
  border-radius: 0;
}
.section-add {
  width: 100%;
  text-align: left;
  color: var(--muted);
  padding: 12px 24px;
  font-size: 14px;
  border-top: 1px solid var(--line);
}
.section-add:hover {
  color: var(--wine);
  background: var(--paper);
}
.current-tag {
  display: inline-block;
  font-size: 12px;
  background: var(--rose);
  color: var(--wine);
  padding: 1px 7px;
  border-radius: 4px;
  margin-left: 9px;
  vertical-align: middle;
}
.customs-shortcut {
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 10px 24px;
  background: var(--paper);
  border: 1px solid var(--line);
  border-radius: 8px;
  padding: 18px 22px;
  margin: 16px 0;
}
.customs-shortcut strong {
  font: 20px var(--serif);
}
.customs-shortcut p {
  font-size: 13px;
  color: var(--muted);
  margin-top: 5px;
}
.customs-choices {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
}
.customs-choice {
  min-height: 44px;
  padding: 12px 20px;
  border: 1px solid var(--line);
  border-radius: 8px;
  color: var(--wine);
  background: #fff;
}
.customs-choice[aria-pressed="true"] {
  background: var(--wine);
  color: #fff;
  border-color: var(--wine);
}
.customs {
  border-top: 1px solid var(--line);
  margin-top: 28px;
  padding-top: 20px;
}
.customs > h2 {
  font: 22px var(--serif);
  padding: 8px 0;
}
.customs > p {
  font-size: 14px;
  color: var(--muted);
  margin: 10px 0 15px;
}
.customs-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 16px;
}
.custom-item {
  background: #fff;
  border: 1px solid var(--line);
  padding: 16px 20px 20px;
  border-radius: 8px;
  display: flex;
  flex-direction: column;
  min-width: 0;
}
.custom-item-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 12px;
}
.custom-item:only-child {
  grid-column: 1 / -1;
}
.custom-item h4 {
  font: 21px/1.5 var(--serif);
  margin-top: 6px;
}
.custom-summary {
  font-size: 15px;
  line-height: 1.9;
  margin: 8px 0 18px;
  color: #74675e;
}
.custom-who {
  border-top: 1px solid var(--line);
  padding-top: 12px;
  margin-top: auto;
  font-size: 13px;
  color: var(--green);
}
.custom-help {
  flex: 0 0 44px;
  width: 44px;
  height: 44px;
  border-radius: 50%;
  color: var(--wine);
  background: radial-gradient(
    circle,
    var(--paper) 13px,
    #d4c2b0 13px,
    #d4c2b0 14px,
    transparent 14px
  );
  font:
    18px Georgia,
    serif;
}
.custom-help:hover {
  background-color: var(--rose);
}
.customs-phases {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin: 22px 0 12px;
}
.customs-phase {
  padding: 10px 15px;
  min-height: 44px;
  border-radius: 6px;
  border: 1px solid var(--line);
  background: #fff;
  color: var(--muted);
  font-size: 14px;
}
.customs-phase[aria-pressed="true"] {
  background: var(--rose);
  border-color: var(--wine);
  color: var(--wine);
}
.customs > .customs-status {
  margin: 12px 0 24px;
  font-size: 13px;
}
.customs-phase-group {
  margin-bottom: 28px;
}
.customs-phase-title {
  display: flex;
  align-items: center;
  gap: 12px;
  font-size: 16px;
  margin-bottom: 14px;
}
.customs-phase-title span {
  font:
    23px Georgia,
    serif;
  color: var(--gold);
}
.custom-detail {
  font-size: 15px;
  line-height: 1.9;
}
.custom-detail-place {
  font-size: 13px;
  color: var(--muted);
  margin-bottom: 18px;
}
.custom-detail section + section {
  margin-top: 22px;
}
.custom-detail h3 {
  font-size: 16px;
  margin-bottom: 8px;
}
.custom-meaning {
  background: var(--rose);
  border-radius: 8px;
  padding: 16px 18px;
}
.custom-detail li {
  margin: 5px 0 5px 22px;
  padding-left: 3px;
}
.custom-adaptation {
  color: var(--green);
}
.custom-references {
  margin-top: 22px;
  border-top: 1px solid var(--line);
  padding-top: 15px;
  font-size: 13px;
}
.custom-references summary {
  cursor: pointer;
  min-height: 32px;
}
.custom-sources {
  display: grid;
  gap: 5px;
  margin-top: 14px;
  font-size: 12px;
}
.custom-sources a {
  color: var(--wine);
  text-underline-offset: 3px;
  text-decoration: underline;
  overflow-wrap: anywhere;
}
.album-intro {
  display: flex;
  justify-content: space-between;
  align-items: end;
  margin: 0 0 24px;
}
.album-intro p {
  font: 20px/1.9 var(--serif);
  color: #897564;
}
.album-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 22px;
}
.photo-card {
  background: #fff;
  padding: 9px 9px 14px;
  box-shadow: 0 3px 15px #432b1410;
  border: 1px solid #eee5dc;
  border-radius: 3px;
  text-align: left;
  transition: transform 0.2s;
  min-width: 0;
}
.photo-card:hover {
  transform: translateY(-5px) rotate(-1deg);
}
.photo-card img {
  width: 100%;
  height: auto;
  aspect-ratio: 2/3;
  object-fit: cover;
  display: block;
}
.photo-caption {
  display: flex;
  justify-content: space-between;
  font: 16px var(--serif);
  color: #7d6757;
  padding: 14px 5px 2px;
}
.photo-caption small {
  font:
    11px Georgia,
    serif;
  color: #b39986;
}
.album-bottom {
  text-align: center;
  font: 28px/1.8 var(--serif);
  letter-spacing: 3px;
  color: var(--wine);
  margin: 43px 0 15px;
}
.album-bottom small {
  display: block;
  font:
    italic 18px Georgia,
    serif;
  color: var(--gold);
  letter-spacing: 1px;
  margin-top: 9px;
}
dialog {
  border: 1px solid var(--line);
  border-radius: 13px;
  background: var(--paper);
  padding: 0;
  width: min(570px, calc(100vw - 28px));
  max-height: calc(100dvh - 40px);
  color: var(--ink);
  box-shadow: 0 20px 100px #28140b30;
}
dialog::backdrop {
  background: #26181480;
  backdrop-filter: blur(4px);
}
.dialog-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 22px 25px;
  border-bottom: 1px solid var(--line);
  gap: 20px;
}
.dialog-head h2 {
  font: 25px var(--serif);
}
.dialog-body {
  padding: 23px 25px;
}
.dialog-body label {
  display: block;
  font-size: 14px;
  color: #75645a;
  margin-bottom: 17px;
}
.dialog-body input:not([type="checkbox"]),
.dialog-body select,
.dialog-body textarea {
  display: block;
  width: 100%;
  margin-top: 6px;
  background: #fff;
  font-size: 15px;
}
.dialog-body textarea {
  resize: vertical;
  min-height: 105px;
}
.form-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 15px;
}
.form-check {
  display: flex !important;
  align-items: center;
  gap: 9px;
}
.dialog-actions {
  display: flex;
  justify-content: flex-end;
  align-items: center;
  gap: 10px;
  padding: 17px 25px;
  border-top: 1px solid var(--line);
}
.dialog-actions .danger {
  margin-right: auto;
  color: var(--wine);
  font-size: 14px;
}
.dialog-hint {
  font-size: 13px;
  color: var(--muted);
  line-height: 1.9;
  margin-top: 12px;
  white-space: pre-wrap;
}
.source-note {
  font-size: 14px;
  background: #eee7df;
  padding: 13px;
  border-radius: 7px;
  margin: 0 0 20px;
  color: #7b685a;
  white-space: pre-wrap;
}
.settings-section {
  padding-top: 22px;
  margin-top: 22px;
  border-top: 1px solid var(--line);
}
.settings-section h3 {
  font: 21px var(--serif);
  margin-bottom: 12px;
}
.settings-buttons {
  display: flex;
  gap: 10px;
  flex-wrap: wrap;
}
.form-error {
  color: var(--wine);
  font-size: 14px;
  margin: 10px 0;
}
.toast {
  position: fixed;
  bottom: 28px;
  left: calc(50% + 100px);
  transform: translateX(-50%);
  z-index: 100;
  background: #392e2a;
  color: #fffaf0;
  padding: 11px 17px;
  border-radius: 9px;
  box-shadow: 0 6px 30px #24180e20;
  display: flex;
  align-items: center;
  gap: 20px;
  font-size: 14px;
  max-width: calc(100vw - 30px);
}
.toast button {
  color: #f4cba4;
  white-space: nowrap;
  min-height: 25px;
  font-size: 14px;
}
#storageWarning {
  background: #fbe2d9;
  color: #85291e;
  padding: 12px 40px;
  font-size: 14px;
}
#lightbox {
  width: 100vw;
  max-width: none;
  height: 100dvh;
  max-height: none;
  background: #211c18f5;
  border: 0;
  border-radius: 0;
  color: #faf3e7;
  box-shadow: none;
}
#lightbox .lightbox-inner {
  height: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 65px 65px 80px;
}
#lightbox img {
  max-width: 100%;
  max-height: 100%;
  object-fit: contain;
}
#lightbox .close-photo {
  position: absolute;
  right: 20px;
  top: 15px;
}
#lightbox .photo-prev,
#lightbox .photo-next {
  position: absolute;
  top: 50%;
  background: #ffffff15;
}
#lightbox .photo-prev {
  left: 15px;
}
#lightbox .photo-next {
  right: 15px;
}
#lightbox .photo-description {
  position: absolute;
  bottom: 19px;
  left: 0;
  width: 100%;
  text-align: center;
  font: 18px var(--serif);
}
#lightbox .photo-description small {
  display: block;
  font: 12px var(--sans);
  color: #baaa98;
  margin-top: 6px;
}
.trash-row {
  display: flex;
  align-items: center;
  gap: 20px;
  padding: 18px;
  background: #fff;
  border-bottom: 1px solid var(--line);
}
.trash-row > div {
  flex: 1;
}
.trash-row p {
  font-size: 13px;
  color: var(--muted);
}
@media (min-width: 1600px) {
  .hero {
    height: 322px;
  }
  .hero h2 {
    font-size: 42px;
  }
  .hero-copy {
    padding-left: 43px;
  }
  .dashboard-columns {
    grid-template-columns: minmax(0, 1fr) 330px;
  }
}
@media (max-width: 1150px) {
  .sidebar {
    width: 198px;
    padding: 30px 14px;
  }
  .brand {
    font-size: 23px;
    gap: 10px;
  }
  .brand small {
    font-size: 7px;
  }
  .app-shell {
    margin-left: 198px;
  }
  .topbar {
    padding: 0 26px;
  }
  .breadcrumb {
    font-size: 13px;
  }
  #main {
    padding: 26px;
  }
  .hero-copy {
    padding: 22px;
  }
  .hero h2 {
    font-size: 29px;
    letter-spacing: 1px;
  }
  .hero-copy p {
    font-size: 13px;
  }
  .dashboard-columns {
    grid-template-columns: minmax(0, 1fr) 250px;
    gap: 18px;
  }
  .event-card {
    padding: 16px;
    gap: 13px;
  }
  .event-stamp {
    width: 35px;
    padding-right: 12px;
    font-size: 22px;
  }
  .countdown strong {
    font-size: 32px;
  }
  .album-grid {
    grid-template-columns: repeat(3, 1fr);
  }
  .footer {
    padding-left: 26px;
    padding-right: 26px;
  }
}
@media (max-width: 1500px) {
  .dashboard-columns {
    grid-template-columns: 1fr;
  }
  .dashboard-aside {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 18px;
  }
}
@media (max-width: 900px) {
  .hero {
    height: auto;
    min-height: 280px;
  }
  .hero-copy {
    padding: 18px;
  }
  .hero h2 {
    font-size: 22px;
    letter-spacing: 0;
  }
  .hero-copy .eyebrow {
    font-size: 9px;
    letter-spacing: 1px;
  }
  .hero-copy p {
    font-size: 12px;
  }
  .hero-images {
    grid-template-columns: 1fr;
  }
  .hero-images img:last-of-type {
    display: none;
  }
  .breadcrumb {
    display: none;
  }
  .topbar {
    justify-content: flex-end;
  }
  .event-stamp {
    display: none;
  }
  .event-card {
    gap: 10px;
  }
  .event-info .event-date {
    font-size: 13px;
  }
  .countdown strong {
    font-size: 30px;
  }
}
@media (max-width: 700px) {
  .sidebar {
    position: static;
    width: 100%;
    padding: 17px 18px 0;
    background: var(--wine-dark);
  }
  .brand {
    font-size: 22px;
    gap: 10px;
  }
  .seal {
    width: 35px;
    height: 39px;
    font-size: 25px;
  }
  .brand small {
    font-size: 7px;
    line-height: 2;
  }
  .nav-caption,
  .sidebar-bottom {
    display: none;
  }
  #navigation {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 5px;
    overflow: visible;
    margin: 18px -18px 0;
    padding: 0 12px 11px;
    scrollbar-width: none;
  }
  .nav-item {
    white-space: normal;
    min-height: 37px;
    padding: 8px;
    font-size: 12px;
    min-width: 0;
    justify-content: center;
    border-radius: 6px;
    gap: 6px;
  }
  .nav-item svg.icon {
    display: none;
  }
  .nav-divider,
  .nav-count {
    display: none;
  }
  .app-shell {
    margin: 0;
  }
  .topbar {
    height: 57px;
    padding: 0 20px;
  }
  .top-actions {
    width: 100%;
    justify-content: space-between;
    gap: 12px;
  }
  .search-box {
    flex: 1;
  }
  .search-box input {
    width: 100%;
    font-size: 14px;
  }
  .search-box kbd {
    display: none;
  }
  #main {
    padding: 23px 18px 32px;
    min-height: 60vh;
  }
  .page-heading {
    gap: 12px;
    margin-bottom: 20px;
  }
  .page-heading h1 {
    font-size: 26px;
    letter-spacing: 1px;
  }
  .page-heading .eyebrow {
    font-size: 10px;
    letter-spacing: 1.7px;
  }
  .page-heading p {
    font-size: 13px;
  }
  .primary-button {
    padding: 7px 12px;
    min-height: 40px;
    font-size: 14px;
  }
  .hero {
    grid-template-columns: 60% 40%;
    column-gap: 0;
    height: 235px;
    min-height: 0;
    border-radius: 9px;
  }
  .hero-copy {
    padding: 14px;
  }
  .hero h2 {
    font-size: clamp(17px, 5.3vw, 22px);
    letter-spacing: 0;
    line-height: 1.65;
    margin: 12px 0;
  }
  .hero-copy .eyebrow {
    display: none;
  }
  .hero-copy p {
    font-size: 12px;
    line-height: 1.85;
  }
  .hero-copy .hero-sign {
    display: none;
  }
  .hero-photo-label {
    font-size: 10px;
    right: 8px;
    padding: 2px 7px;
    bottom: 10px;
  }
  .hero-images img:first-child {
    object-position: 51% 45%;
  }
  .event-grid {
    gap: 10px;
    margin: 14px 0 27px;
  }
  .event-card {
    padding: 13px 12px;
    display: block;
    position: relative;
  }
  .event-info h3 {
    font-size: 15px;
    margin-bottom: 0;
  }
  .event-info p {
    font-size: 12px;
  }
  .event-info .event-date {
    font-size: 13px;
  }
  .countdown {
    text-align: left;
    margin-top: 6px;
    display: flex;
    flex-wrap: wrap;
    align-items: baseline;
    font-size: 12px;
    gap: 2px;
  }
  .countdown strong {
    font-size: 29px;
    margin-right: 1px;
  }
  .countdown small {
    font-size: 11px;
    order: 2;
    margin-left: 5px;
  }
  .section-top h2 {
    font-size: 22px;
  }
  .section-top .text-button {
    font-size: 13px;
  }
  .dashboard-columns {
    gap: 23px;
  }
  .task-list,
  .shared-modules,
  .dashboard-tasks .task-list {
    grid-template-columns: 1fr;
    gap: 12px;
  }

  .task-check {
    padding-left: 10px;
    font-size: 12px;
    gap: 5px;
  }
  .task-row {
    column-gap: 4px;
  }
  .task-row > .owner-tag {
    max-width: 62px;
    white-space: normal;
  }
  .task-row > .task-more {
    margin-right: 5px;
  }

  .shared-module-copy {
    padding: 15px;
    gap: 8px;
  }
  .shared-module-copy strong {
    font-size: 21px;
  }

  .task-title {
    font-size: 16px;
  }
  .task-sub {
    font-size: 12px;
    gap: 5px 8px;
  }
  .owner-tag {
    font-size: 12px;
    padding: 1px 6px;
  }
  .task-more {
    min-width: 23px;
  }
  .dashboard-aside {
    gap: 12px;
    grid-template-columns: 1fr;
  }
  .note-card {
    padding: 17px 15px;
  }
  .note-card h3 {
    font-size: 20px;
  }
  .note-card p {
    font-size: 16px;
  }
  .progress-card {
    padding: 17px 15px;
  }
  .progress-card p {
    font-size: 13px;
  }
  .milestones {
    margin-top: 21px;
  }
  .footer {
    padding: 18px;
    display: block;
    font-size: 12px;
  }
  .footer span:last-child {
    display: block;
    margin-top: 6px;
    font-size: 10px;
  }
  .filterbar {
    gap: 9px;
  }
  .segmented button {
    padding: 4px 9px;
    font-size: 14px;
  }
  .filterbar select {
    font-size: 14px;
    max-width: 135px;
  }
  .filter-spacer {
    display: none;
  }
  .filterbar > .text-button {
    margin-left: auto;
  }
  .event-banner {
    padding: 16px;
    gap: 12px;
    flex-wrap: wrap;
  }
  .event-banner .date-large {
    font-size: 25px;
  }
  .event-banner .event-banner-copy {
    font-size: 13px;
  }
  .event-banner .event-banner-copy strong {
    font-size: 14px;
  }
  .section-head {
    padding: 16px 14px;
    gap: 10px;
  }
  .section-head-copy h2 {
    font-size: 16px;
  }
  .phase-number {
    font-size: 22px;
    min-width: 25px;
  }
  .section-head-count {
    font-size: 12px;
  }
  .current-tag {
    font-size: 12px;
    margin-left: 4px;
  }
  .customs-grid {
    grid-template-columns: 1fr;
  }
  .family-board {
    gap: 12px;
  }

  .family-copy {
    padding: 13px;
  }
  .family-title {
    font-size: 21px;
  }
  .family-note {
    min-height: 76px;
  }
  .family-action {
    flex-wrap: wrap;
    font-size: 13px;
    gap: 4px;
  }
  .family-action small {
    margin-left: 0;
  }
  .family-result-count {
    width: 100%;
    margin-left: 0;
  }


  .phase-nav {
    display: none;
  }
  .phase-select {
    display: block;
    width: 100%;
    min-height: 44px;
    padding: 10px 12px;
    margin-bottom: 16px;
    color: var(--wine);
    border: 1px solid var(--line);
    border-radius: 7px;
    background: #fff;
  }
  .album-grid {
    grid-template-columns: 1fr 1fr;
    gap: 15px;
  }
  .album-intro p {
    font-size: 17px;
  }
  .photo-card {
    padding: 6px 6px 10px;
  }
  .photo-caption {
    font-size: 14px;
    padding: 12px 3px 2px;
  }
  .album-bottom {
    font-size: 24px;
    margin-top: 30px;
  }
  .dialog-head {
    padding: 17px 20px;
  }
  .dialog-body {
    padding: 20px;
  }
  .dialog-actions {
    padding: 15px 20px;
  }
  .toast {
    left: 50%;
    bottom: 20px;
    max-width: calc(100vw - 28px);
    gap: 12px;
    font-size: 14px;
  }
  #lightbox .lightbox-inner {
    padding: 70px 14px 90px;
  }
  #lightbox .photo-prev,
  #lightbox .photo-next {
    top: auto;
    bottom: 16px;
    z-index: 1;
  }
  #lightbox .photo-description {
    padding: 0 60px;
  }
  .skip-link {
    left: 10px;
  }
}
@media (max-width: 370px) {
  .hero h2 {
    font-size: 17px;
  }
  .hero-copy {
    padding: 12px;
  }
  .hero-copy p {
    font-size: 12px;
  }
  .page-heading {
    gap: 8px;
  }
  .page-heading h1 {
    font-size: 22px;
  }
  .form-grid {
    grid-template-columns: 1fr;
  }
}
@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    scroll-behavior: auto !important;
    transition: none !important;
    animation: none !important;
  }
}
