:root {
  color-scheme: light;
  --bg: #f6f7f8;
  --surface: #ffffff;
  --surface-soft: #fbfbfa;
  --ink: #111214;
  --muted: #73777f;
  --border: #e8e8e4;
  --coral: #ff5c48;
  --coral-dark: #de3f30;
  --coral-soft: #fff0ed;
  --green: #3f8f5f;
  --green-soft: #ecf7ef;
  --amber: #b7791f;
  --shadow: 0 18px 50px rgba(20, 20, 20, 0.08);
  --radius: 8px;
  font-family: -apple-system, BlinkMacSystemFont, "PingFang SC", "Noto Sans SC", "Microsoft YaHei", sans-serif;
}

* {
  box-sizing: border-box;
}

body {
  margin: 0;
  background: var(--bg);
  color: var(--ink);
  line-height: 1.6;
  overflow-x: hidden;
}

a {
  color: inherit;
  text-decoration: none;
}

button,
input,
select {
  font: inherit;
}

button {
  cursor: pointer;
}

.site-header {
  position: sticky;
  top: 0;
  z-index: 10;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  padding: 18px 32px;
  background: rgba(255, 255, 255, 0.92);
  border-bottom: 1px solid var(--border);
  backdrop-filter: blur(18px);
}

.brand {
  display: flex;
  align-items: center;
  gap: 12px;
}

.brand strong {
  display: block;
  font-size: 22px;
  letter-spacing: 0;
}

.brand small {
  display: block;
  color: var(--muted);
  line-height: 1.1;
}

.top-nav {
  display: flex;
  align-items: center;
  gap: 28px;
  color: #2c2d30;
  font-weight: 700;
}

.header-actions {
  display: flex;
  align-items: center;
  gap: 14px;
  margin-left: auto;
}

.language-switch {
  display: inline-flex;
  align-items: center;
  min-height: 36px;
  padding: 0 12px;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  background: var(--surface-soft);
  color: #2c2d30;
  font-size: 14px;
  font-weight: 800;
}

.top-nav a:hover,
.ghost-link:hover,
.quick-guides a:hover,
.language-switch:hover {
  color: var(--coral-dark);
}

.ghost-link,
.quick-guides a,
.section-title a {
  color: var(--muted);
  font-weight: 700;
}

main {
  width: min(1440px, calc(100% - 48px));
  margin: 24px auto 0;
}

.app-grid {
  display: grid;
  grid-template-columns: 320px minmax(0, 1fr) 300px;
  gap: 18px;
  align-items: start;
  min-width: 0;
}

.panel,
.hero-card,
.guide-section {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
}

.panel {
  padding: 22px;
  min-width: 0;
}

.people-panel {
  position: sticky;
  top: 96px;
}

.panel-head h1 {
  margin: 0;
  font-size: 32px;
  line-height: 1.12;
}

.panel-head p {
  margin: 10px 0 18px;
  color: var(--muted);
}

.primary-button,
.ghost-button,
.mini-tabs button {
  border: 1px solid var(--border);
  border-radius: var(--radius);
  min-height: 44px;
  padding: 0 16px;
  font-weight: 800;
}

.primary-button {
  border-color: var(--coral);
  background: var(--coral);
  color: white;
}

.primary-button:hover {
  background: var(--coral-dark);
}

.full {
  width: 100%;
}

.ghost-button {
  background: var(--surface-soft);
  color: var(--ink);
}

.mini-tabs {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 8px;
  margin: 16px 0;
}

.mini-tabs button {
  background: var(--surface-soft);
  color: var(--muted);
  min-width: 0;
}

.mini-tabs button.active {
  background: var(--coral-soft);
  border-color: #ffd3ca;
  color: var(--coral-dark);
}

.relationship-list {
  display: grid;
  gap: 10px;
}

.person-row {
  display: grid;
  grid-template-columns: 44px minmax(0, 1fr) auto;
  gap: 12px;
  align-items: center;
  padding: 12px;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  background: var(--surface-soft);
}

.person-row.active {
  background: var(--coral-soft);
  border-color: #ffd0c6;
}

.avatar {
  display: grid;
  place-items: center;
  width: 44px;
  height: 44px;
  border-radius: 50%;
  background: white;
  color: var(--coral-dark);
  font-weight: 900;
}

.person-row strong,
.idea-card strong,
.guide-card strong {
  display: block;
  overflow-wrap: anywhere;
}

.person-row span {
  display: block;
  color: var(--muted);
  font-size: 13px;
}

.pill {
  padding: 4px 8px;
  border-radius: 999px;
  background: white;
  color: var(--coral-dark);
  font-size: 12px;
  font-weight: 900;
}

.relationship-form {
  display: grid;
  gap: 10px;
  margin-top: 18px;
  padding-top: 18px;
  border-top: 1px solid var(--border);
}

.relationship-form h2 {
  margin: 0 0 4px;
  font-size: 18px;
}

.relationship-form label {
  display: grid;
  gap: 6px;
  color: var(--muted);
  font-size: 13px;
  font-weight: 800;
}

.relationship-form input,
.relationship-form select {
  width: 100%;
  min-height: 42px;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 8px 10px;
  color: var(--ink);
  background: white;
}

.workspace {
  display: grid;
  gap: 18px;
  min-width: 0;
}

.hero-card {
  display: grid;
  grid-template-columns: minmax(0, 1.22fr) minmax(260px, 0.78fr);
  gap: 24px;
  align-items: center;
  padding: 28px;
  min-width: 0;
}

.hero-card h2 {
  margin: 4px 0;
  font-size: clamp(30px, 3vw, 40px);
  line-height: 1.12;
}

.event-meta {
  margin: 0 0 16px;
  color: var(--muted);
  font-size: 18px;
  font-weight: 700;
}

.warm-note {
  display: inline-block;
  margin: 0;
  padding: 10px 12px;
  border: 1px solid #f5d9b4;
  border-radius: var(--radius);
  background: #fff8ed;
  color: var(--amber);
  font-weight: 800;
}

.hero-card img {
  width: 100%;
  aspect-ratio: 16 / 10;
  object-fit: cover;
  border-radius: var(--radius);
}

.soft-label {
  margin: 0 0 6px;
  color: var(--coral-dark);
  font-size: 13px;
  font-weight: 900;
}

.section-title {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 18px;
  margin-bottom: 18px;
}

.section-title h2 {
  margin: 0;
  font-size: 24px;
  line-height: 1.22;
}

.section-title.compact {
  margin-bottom: 12px;
}

.idea-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 14px;
}

.idea-card {
  display: grid;
  gap: 10px;
  padding: 16px;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  background: var(--surface-soft);
}

.idea-card span {
  color: var(--muted);
  font-size: 14px;
}

.tag-row {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}

.tag {
  padding: 3px 7px;
  border-radius: 999px;
  background: var(--coral-soft);
  color: var(--coral-dark);
  font-size: 12px;
  font-weight: 800;
}

.price {
  color: var(--coral-dark);
  font-weight: 900;
}

.blessing-text {
  min-height: 112px;
  margin: 0;
  padding: 18px;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  background: var(--surface-soft);
  font-size: 18px;
}

.side-column {
  display: grid;
  gap: 18px;
  position: sticky;
  top: 96px;
  min-width: 0;
}

.privacy-card {
  background: var(--green-soft);
  border-color: #d5ebda;
}

.privacy-card h2 {
  margin: 0 0 8px;
}

.privacy-card a {
  color: var(--green);
  font-weight: 900;
}

.quick-guides {
  display: grid;
  gap: 10px;
}

.quick-guides a {
  display: block;
  padding: 12px;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  background: var(--surface-soft);
}

.guide-section {
  margin: 18px 0 28px;
  padding: 28px;
}

.guide-card-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 16px;
  min-width: 0;
}

.guide-card {
  display: grid;
  grid-template-columns: 132px minmax(0, 1fr);
  grid-template-rows: auto 1fr;
  gap: 6px 14px;
  padding: 12px;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  background: var(--surface-soft);
}

.guide-card img {
  grid-row: 1 / span 2;
  width: 132px;
  height: 92px;
  object-fit: cover;
  border-radius: var(--radius);
}

.guide-card span {
  color: var(--muted);
  font-size: 14px;
}

.site-footer {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 18px;
  padding: 28px;
  color: var(--muted);
}

.article-layout {
  display: grid;
  grid-template-columns: minmax(0, 760px) 300px;
  gap: 24px;
  align-items: start;
  width: min(1120px, calc(100% - 40px));
  margin: 28px auto;
}

.article {
  padding: 32px;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
}

.article h1 {
  margin: 0 0 12px;
  font-size: clamp(30px, 4vw, 46px);
  line-height: 1.14;
}

.article h2 {
  margin-top: 32px;
  font-size: 24px;
}

.article p,
.article li {
  color: #44484f;
  font-size: 17px;
}

.article img {
  width: 100%;
  max-height: 360px;
  object-fit: cover;
  border-radius: var(--radius);
  margin: 18px 0;
}

.article ul {
  padding-left: 1.3em;
}

.article-cta,
.directory-card {
  padding: 18px;
  border: 1px solid #ffd0c6;
  border-radius: var(--radius);
  background: var(--coral-soft);
}

.article-cta a,
.directory-card a {
  color: var(--coral-dark);
  font-weight: 900;
}

.directory-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 14px;
}

.directory-card {
  background: white;
}

.article-sidebar {
  position: sticky;
  top: 96px;
}

@media (max-width: 1120px) {
  main {
    width: min(100% - 28px, 920px);
  }

  .app-grid {
    grid-template-columns: 1fr;
  }

  .people-panel,
  .side-column {
    position: static;
  }

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

@media (max-width: 760px) {
  body {
    min-width: 0;
  }

  .site-header {
    position: static;
    align-items: flex-start;
    flex-direction: column;
    gap: 14px;
    padding: 16px 18px;
  }

  .top-nav {
    width: 100%;
    flex-wrap: wrap;
    justify-content: flex-start;
    gap: 12px 28px;
  }

  .header-actions {
    width: 100%;
    justify-content: space-between;
    margin-left: 0;
  }

  main {
    width: 100%;
    margin-top: 10px;
    padding: 0 10px;
  }

  .hero-card,
  .guide-card,
  .article-layout {
    grid-template-columns: 1fr;
  }

  .idea-grid,
  .guide-card-grid,
  .side-column,
  .directory-grid {
    grid-template-columns: 1fr;
  }

  .guide-card img {
    width: 100%;
    height: 150px;
  }

  .panel,
  .hero-card,
  .guide-section,
  .article {
    padding: 18px;
  }

  .mini-tabs {
    display: flex;
    width: 100%;
    min-width: 0;
  }

  .mini-tabs button,
  .primary-button,
  .ghost-button {
    flex: 1 1 0;
    min-width: 0;
    padding-left: 10px;
    padding-right: 10px;
    white-space: nowrap;
  }

  .person-row {
    grid-template-columns: 44px minmax(0, 1fr);
    width: 100%;
    text-align: left;
  }

  .person-row .pill {
    grid-column: 2;
    justify-self: start;
  }

  .hero-card h2 {
    font-size: 32px;
  }
}
