:root {
  --ink: #1d1d1f;
  --muted: #6e6e73;
  --line: rgba(29, 29, 31, 0.1);
  --paper: #f5f5f7;
  --panel: #ffffff;
  --green: #2b6652;
  --green-2: #59b98c;
  --gold: #f0a400;
  --soft: #f7faf8;
  --danger: #a43c2d;
  --shadow: 0 18px 55px rgba(29, 29, 31, 0.1);
  --soft-shadow: 0 8px 30px rgba(29, 29, 31, 0.08);
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", "PingFang SC", "Microsoft YaHei", sans-serif;
}

.survey-tool-page {
  max-width: 960px;
}

.tool-nav {
  position: sticky;
  top: 12px;
  z-index: 10;
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 6px;
  width: min(100%, 420px);
  margin: 0 auto 18px;
  padding: 6px;
  border: 1px solid rgba(29, 29, 31, 0.08);
  border-radius: 14px;
  background: rgba(255, 255, 255, 0.78);
  box-shadow: var(--soft-shadow);
  backdrop-filter: blur(20px);
}

.tool-nav a {
  min-height: 42px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 10px;
  color: #eb7d00;
  text-decoration: none;
  font-size: 15px;
  font-weight: 750;
}

.tool-nav a.active {
  color: #fff;
  background: #f57029;
  box-shadow: 0 8px 18px rgba(245, 112, 41, 0.2);
}

.survey-tool-page .survey-hero {
  display: grid;
  grid-template-columns: minmax(0, 1.16fr) minmax(240px, 0.84fr);
  gap: 24px;
  margin-bottom: 18px;
  padding: 18px;
  border: 1px solid rgba(255, 255, 255, 0.76);
  border-radius: 18px;
  background: rgba(255, 255, 255, 0.86);
  box-shadow: var(--shadow);
  backdrop-filter: blur(20px);
}

.survey-tool-page .survey-hero-copy {
  display: grid;
  align-content: center;
  padding: 10px 0 10px 6px;
}

.survey-tool-page .logo-card {
  display: flex;
  align-items: center;
  width: min(100%, 350px);
  min-height: 74px;
  padding: 10px 14px;
  margin-bottom: 18px;
  background: rgba(255, 255, 255, 0.92);
  border: 1px solid rgba(29, 29, 31, 0.08);
  border-radius: 12px;
  box-shadow: var(--soft-shadow);
}

.survey-tool-page .logo-card img {
  display: block;
  width: 100%;
  height: auto;
}

.survey-tool-page .survey-hero h1 {
  max-width: 560px;
  margin: 0 0 14px;
  font-size: clamp(34px, 5vw, 54px);
  line-height: 1.05;
  letter-spacing: 0;
}

.survey-tool-page #activity-title {
  color: #6a0106;
  font-size: 21px;
  line-height: 1.2;
  font-weight: 850;
}

.survey-tool-page .survey-hero p {
  max-width: 560px;
  margin-bottom: 20px;
  color: var(--muted);
  line-height: 1.7;
}

.survey-tool-page .survey-mascot {
  display: flex;
  align-items: flex-end;
  justify-content: center;
  overflow: hidden;
  min-height: 330px;
  padding: 28px 16px 0;
  border: 1px solid rgba(29, 29, 31, 0.06);
  border-radius: 18px;
  background:
    radial-gradient(circle at 50% 72%, rgba(89, 185, 140, 0.22), transparent 45%),
    linear-gradient(180deg, rgba(255, 255, 255, 0.92), rgba(247, 250, 248, 0.74));
}

.survey-tool-page .survey-mascot img {
  display: block;
  width: min(72%, 290px);
  height: auto;
  filter: drop-shadow(0 20px 24px rgba(29, 29, 31, 0.14));
}

.member-tool-page .member-hero h1 {
  font-size: clamp(42px, 7vw, 72px);
}

.pre-h5-page {
  max-width: 760px;
}

.pre-h5-page .survey-hero {
  grid-template-columns: minmax(0, 1fr) 210px;
  gap: 16px;
  padding: 16px;
  border-radius: 22px;
  background:
    linear-gradient(135deg, rgba(255, 255, 255, 0.96), rgba(250, 247, 239, 0.9)),
    radial-gradient(circle at 85% 15%, rgba(245, 112, 41, 0.14), transparent 34%);
}

.pre-h5-page .survey-hero-copy {
  padding: 8px 0 8px 4px;
}

.pre-h5-page .survey-hero .eyebrow {
  font-size: 12px;
}

.pre-topline {
  display: grid;
  grid-template-columns: minmax(0, 220px) auto;
  align-items: center;
  gap: 12px;
  margin-bottom: 14px;
}

.pre-topline .logo-card {
  min-height: 54px;
  margin: 0;
  padding: 8px 10px;
}

.pre-topline span {
  display: inline-flex;
  justify-self: start;
  min-height: 30px;
  align-items: center;
  padding: 0 10px;
  border: 1px solid rgba(245, 112, 41, 0.2);
  border-radius: 999px;
  color: #d66000;
  background: rgba(255, 247, 237, 0.88);
  font-size: 13px;
  font-weight: 800;
  white-space: nowrap;
}

.pre-h5-page #activity-title {
  margin-bottom: 12px;
  color: #6a0106;
  font-size: 36px;
  line-height: 1.08;
}

.pre-h5-page #activity-intro {
  margin-bottom: 14px;
  font-size: 12px;
}

.pre-h5-page .pre-meta div {
  display: grid;
  grid-template-columns: auto minmax(0, 1fr);
  gap: 8px;
  align-items: start;
}

.pre-h5-page .pre-meta dt {
  font-size: 12px;
}

.pre-h5-page #activity-theme {
  color: #e80219;
  font-size: clamp(22px, 6vw, 34px);
  line-height: 1.12;
}

.pre-h5-page .survey-mascot {
  min-height: 230px;
  border-radius: 20px;
}

.pre-h5-page .survey-mascot img {
  width: min(88%, 210px);
}

.pre-form-shell {
  overflow: hidden;
  border-radius: 22px;
  box-shadow: 0 20px 60px rgba(29, 29, 31, 0.08);
}

.pre-h5-page .form-section {
  padding: 24px;
}

.pre-h5-page .section-heading {
  align-items: start;
}

.pre-h5-page .section-heading h2 {
  font-size: 22px;
}

.pre-h5-page .section-heading .survey-warning {
  color: #b98b3c;
  font-size: 14px;
}

.pre-h5-page .fields {
  gap: 18px;
}

.pre-h5-page input,
.pre-h5-page textarea,
.pre-h5-page select {
  border-radius: 12px;
  background: rgba(255, 255, 255, 0.96);
}

.pre-submit-bar {
  padding: 18px 24px 24px;
}

.pre-submit-actions {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 10px;
  max-width: 320px;
  align-items: start;
}

.pre-submit-bar #submit-button,
.pre-admin-page #save-activity-button {
  background: #f4680b;
}

.pre-cbo-action {
  display: grid;
  gap: 8px;
}

.pre-submit-bar .pre-cbo-button {
  background: var(--green);
}

.pre-submit-bar .pre-cbo-button:hover {
  background: #1e4238;
}

.pre-cbo-note {
  margin: 0;
  color: #b98b3c;
  font-size: 12px;
  line-height: 1.5;
  text-align: center;
}

.pre-success-panel {
  border-radius: 22px;
}

.pre-success-card {
  display: grid;
  gap: 8px;
  padding: 18px;
  border: 1px solid rgba(43, 102, 82, 0.14);
  border-radius: 16px;
  background: linear-gradient(180deg, #fff, #f7faf8);
}

.pre-success-card strong {
  color: var(--green);
  font-size: 18px;
}

.admin-portal-page {
  max-width: 980px;
}

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

.admin-branch-card {
  display: grid;
  gap: 14px;
  min-height: 260px;
  padding: 28px;
  border: 1px solid rgba(29, 29, 31, 0.08);
  border-radius: 18px;
  background: rgba(255, 255, 255, 0.9);
  box-shadow: var(--soft-shadow);
}

.admin-branch-card span {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 42px;
  height: 42px;
  border-radius: 50%;
  color: #fff;
  background: linear-gradient(145deg, var(--green), #1e4238);
  font-weight: 800;
}

.admin-branch-card h2 {
  margin: 0;
  font-size: 26px;
}

.admin-branch-card p {
  margin: 0;
  color: var(--muted);
  line-height: 1.7;
}

.admin-branch-card .link-button {
  align-self: end;
  width: fit-content;
  background: #f4680b;
}

.branch-links {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  align-items: center;
}

.pre-success-card p {
  margin: 0;
  color: var(--muted);
  line-height: 1.65;
}

.pre-admin-page .admin-header {
  border-color: rgba(245, 112, 41, 0.16);
}

.member-tool-page .member-mascot {
  min-height: 360px;
  background:
    radial-gradient(circle at 50% 75%, rgba(240, 164, 0, 0.22), transparent 44%),
    linear-gradient(180deg, rgba(255, 255, 255, 0.94), rgba(247, 250, 248, 0.8));
}

.member-tool-page .member-mascot img {
  width: min(88%, 360px);
  transform: translateY(18px);
}

@media (max-width: 760px) {
  .survey-tool-page {
    padding: 10px 10px 28px;
  }

  .survey-tool-page .survey-hero {
    grid-template-columns: 1fr;
    gap: 14px;
    padding: 16px;
  }

  .survey-tool-page .survey-hero-copy {
    padding: 0;
  }

  .survey-tool-page .logo-card {
    width: 100%;
    min-height: 58px;
    margin-bottom: 14px;
  }

  .survey-tool-page .survey-hero h1 {
    font-size: 34px;
  }

  .survey-tool-page .survey-mascot {
    min-height: 230px;
    padding: 16px 12px 0;
  }

  .survey-tool-page .survey-mascot img {
    width: min(64%, 220px);
  }

  .tool-nav {
    top: 8px;
    margin-bottom: 12px;
  }

  .member-tool-page .member-mascot img {
    width: min(72%, 260px);
  }
}

* {
  box-sizing: border-box;
}

body {
  margin: 0;
  color: var(--ink);
  background:
    linear-gradient(180deg, #ffffff 0%, #f5f5f7 44%, #f5f5f7 100%);
}

html {
  scroll-behavior: smooth;
}

.site-header {
  position: sticky;
  top: 0;
  z-index: 10;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 18px;
  max-width: 1240px;
  min-height: 70px;
  margin: 0 auto;
  padding: 10px 18px;
  background: rgba(255, 255, 255, 0.78);
  border-bottom: 1px solid var(--line);
  backdrop-filter: blur(18px);
}

.site-logo {
  display: flex;
  align-items: center;
  width: min(45vw, 265px);
}

.site-logo img {
  display: block;
  width: 100%;
  height: auto;
}

.site-nav {
  display: flex;
  align-items: center;
  gap: 2px;
}

.site-nav a {
  min-height: 38px;
  padding: 9px 10px;
  border-radius: 6px;
  color: var(--ink);
  font-size: 13px;
  font-weight: 650;
  text-decoration: none;
}

.site-nav a:hover {
  background: rgba(43, 102, 82, 0.08);
  color: var(--green);
}

.page {
  max-width: 1240px;
  margin: 0 auto;
  padding: 18px 18px 48px;
}

.hero {
  position: relative;
  display: grid;
  grid-template-columns: minmax(0, 1.1fr) minmax(360px, 0.9fr);
  gap: 32px;
  overflow: hidden;
  color: var(--ink);
  background: #ffffff;
  border: 1px solid rgba(29, 29, 31, 0.06);
  border-radius: 18px;
  min-height: 560px;
  padding: 56px;
  margin-bottom: 24px;
  box-shadow: none;
}

.poster-hero {
  grid-template-columns: minmax(0, 0.96fr) minmax(320px, 0.78fr);
  gap: 44px;
  min-height: 620px;
  background:
    radial-gradient(circle at 80% 18%, rgba(255, 195, 0, 0.2), transparent 28%),
    linear-gradient(135deg, #ffffff 0%, #f5f5f7 100%);
}

.hero-copy {
  position: relative;
  z-index: 1;
  display: grid;
  align-content: center;
  padding: 20px 0 20px 4px;
}

.eyebrow {
  margin-bottom: 10px;
  color: #86868b;
  font-size: 14px;
  font-weight: 700;
}

.hero-visual {
  position: relative;
  z-index: 1;
  overflow: hidden;
  min-height: 460px;
  border-radius: 18px;
  background: linear-gradient(135deg, #bcffd0, #f9fff9);
  box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.68);
}

.poster-frame {
  display: flex;
  align-items: center;
  justify-content: center;
  min-height: 640px;
  padding: 18px;
  border: 1px solid rgba(29, 29, 31, 0.08);
  background: #fff;
  box-shadow: 0 28px 70px rgba(0, 0, 0, 0.12);
}

.hero-visual.poster-frame img {
  width: 100%;
  height: 100%;
  object-fit: contain;
  object-position: center;
}

.hero-visual img {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center 42%;
}

.mascot-frame {
  display: flex;
  align-items: flex-end;
  justify-content: center;
  min-height: 480px;
  padding: 34px 22px 0;
  border: 1px solid rgba(29, 29, 31, 0.06);
  background:
    radial-gradient(circle at 50% 72%, rgba(89, 185, 140, 0.26), transparent 45%),
    linear-gradient(180deg, rgba(255, 255, 255, 0.9), rgba(247, 250, 248, 0.72));
  box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.7);
}

.hero-visual.mascot-frame img {
  width: min(76%, 330px);
  height: auto;
  object-fit: contain;
  object-position: center bottom;
  filter: drop-shadow(0 22px 28px rgba(29, 29, 31, 0.14));
}

.brand-mark {
  display: inline-flex;
  align-items: center;
  min-height: 28px;
  padding: 4px 10px;
  border: 1px solid rgba(255, 255, 255, 0.46);
  border-radius: 999px;
  font-size: 13px;
  font-weight: 700;
  letter-spacing: 0;
}

.admin-header .brand-mark,
.panel .brand-mark {
  color: var(--green);
  border-color: var(--line);
}

h1,
h2,
h3,
p {
  margin-top: 0;
}

.hero h1 {
  max-width: 620px;
  margin: 0 0 14px;
  font-size: clamp(52px, 5.6vw, 84px);
  line-height: 1.05;
  letter-spacing: 0;
}

.hero p {
  max-width: 620px;
  margin-bottom: 20px;
  color: var(--muted);
  line-height: 1.7;
}

.hero-lead {
  max-width: 660px;
  color: #6e6e73;
  font-size: 21px;
  line-height: 1.48;
}

.hero-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-bottom: 18px;
}

.ghost-button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 46px;
  border: 1px solid rgba(29, 29, 31, 0.16);
  border-radius: 6px;
  padding: 0 18px;
  color: var(--ink);
  background: #fff;
  font: inherit;
  font-weight: 750;
  text-decoration: none;
}

.ghost-button:hover {
  background: #f5f5f7;
}

.hero-quote {
  max-width: 500px;
  margin: 0;
  padding: 0;
  border-left: 0;
  color: var(--ink) !important;
  background: transparent;
  font-size: 21px;
  font-weight: 800;
}

.hero-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 2px;
}

.hero-tags span {
  display: inline-flex;
  align-items: center;
  min-height: 34px;
  padding: 0 12px;
  border: 1px solid rgba(29, 29, 31, 0.12);
  border-radius: 999px;
  color: #1d1d1f;
  background: rgba(255, 255, 255, 0.68);
  font-size: 13px;
  font-weight: 750;
}

.meta {
  display: grid;
  gap: 10px;
  margin: 0;
}

.meta div {
  display: grid;
  grid-template-columns: 74px 1fr;
  gap: 10px;
  align-items: center;
  min-height: 36px;
  padding: 8px 10px;
  background: rgba(255, 255, 255, 0.72);
  border: 1px solid rgba(29, 29, 31, 0.07);
  border-radius: 8px;
}

.meta dt {
  color: var(--muted);
}

.meta dd {
  margin: 0;
  color: var(--ink);
  font-weight: 650;
}

.survey-tool-page .meta div {
  grid-template-columns: 1fr;
  gap: 2px;
  align-items: start;
}

.survey-tool-page #activity-theme {
  color: #e80219;
  font-size: 28px;
  line-height: 1.08;
  font-weight: 850;
}

.form-shell,
.panel,
.content-section,
.activity-card {
  background: #fff;
  border: 1px solid rgba(29, 29, 31, 0.06);
  border-radius: 18px;
  box-shadow: none;
  backdrop-filter: none;
}

.content-section,
.activity-card {
  margin-bottom: 24px;
  padding: 56px;
}

.section-kicker {
  margin-bottom: 14px;
  color: #86868b;
  font-size: 14px;
  font-weight: 800;
}

.content-section h2,
.activity-card h2 {
  margin-bottom: 12px;
  font-size: 34px;
  line-height: 1.25;
}

.display-title {
  max-width: 980px;
  margin-bottom: 28px !important;
  font-size: clamp(42px, 5vw, 72px) !important;
  line-height: 1.06 !important;
  letter-spacing: 0;
}

.intro-copy {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
  gap: 28px;
  max-width: 1060px;
  margin-bottom: 34px;
}

.intro-copy p {
  margin: 0;
  color: #6e6e73;
  font-size: 20px;
  line-height: 1.55;
}

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

.principle-grid article {
  min-height: 180px;
  padding: 26px;
  border-radius: 18px;
  background: #f5f5f7;
}

.principle-grid strong {
  display: block;
  margin-bottom: 48px;
  font-size: 22px;
}

.principle-grid p {
  margin: 0;
  color: #6e6e73;
}

.letter-section {
  display: grid;
  grid-template-columns: minmax(320px, 0.72fr) minmax(0, 1fr);
  gap: 56px;
  margin-bottom: 24px;
  padding: 64px 56px;
  border-radius: 18px;
  color: #f5f5f7;
  background: #1d1d1f;
}

.letter-section .section-kicker {
  color: #a1a1a6;
}

.letter-head {
  position: sticky;
  top: 96px;
  align-self: start;
}

.letter-head h2 {
  margin: 0;
  color: #fff;
  font-size: clamp(36px, 4vw, 60px);
  line-height: 1.08;
}

.letter-body {
  max-width: 680px;
  color: #d2d2d7;
  font-size: 18px;
  line-height: 1.9;
}

.letter-body p {
  margin: 0 0 18px;
}

.letter-sign {
  padding-top: 10px;
  color: #fff;
  font-weight: 750;
}

.letter-teaser {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 24px;
  align-items: center;
  margin-bottom: 24px;
  padding: 36px 56px;
  border-radius: 18px;
  background: #1d1d1f;
}

.letter-teaser h2 {
  margin: 0;
  color: #fff;
  font-size: 34px;
  line-height: 1.18;
}

.letter-teaser .section-kicker {
  color: #a1a1a6;
}

.letter-teaser .ghost-button {
  color: #fff;
  border-color: rgba(255, 255, 255, 0.28);
  background: transparent;
}

.letter-teaser .ghost-button:hover {
  background: rgba(255, 255, 255, 0.12);
}

.letter-page {
  background: #fff;
}

.letter-page-main {
  max-width: 980px;
  margin: 0 auto;
  padding: 72px 24px 88px;
}

.letter-hero {
  margin-bottom: 54px;
  text-align: center;
}

.letter-hero h1 {
  max-width: 820px;
  margin: 0 auto 18px;
  font-size: clamp(48px, 6vw, 82px);
  line-height: 1.04;
}

.letter-hero p {
  max-width: 620px;
  margin: 0 auto;
  color: #6e6e73;
  font-size: 21px;
  line-height: 1.5;
}

.letter-document {
  max-width: 760px;
  margin: 0 auto;
  color: #1d1d1f;
  font-size: 21px;
  line-height: 1.86;
}

.letter-document p {
  margin: 0 0 24px;
}

.letter-document .letter-sign {
  color: #1d1d1f;
}

.letter-actions {
  display: flex;
  justify-content: center;
  gap: 12px;
  margin-top: 54px;
}

.poster-page {
  background: #f5f5f7;
}

.poster-page-main {
  max-width: 1100px;
  margin: 0 auto;
  padding: 68px 24px 88px;
}

.poster-page-hero {
  max-width: 860px;
  margin: 0 auto 34px;
  text-align: center;
}

.poster-page-hero h1 {
  margin: 0 0 16px;
  font-size: clamp(42px, 5vw, 72px);
  line-height: 1.05;
}

.poster-page-hero p {
  max-width: 640px;
  margin: 0 auto;
  color: #6e6e73;
  font-size: 20px;
  line-height: 1.55;
}

.poster-full {
  margin: 0;
  padding: 24px;
  border-radius: 24px;
  background: #fff;
  box-shadow: 0 28px 70px rgba(0, 0, 0, 0.12);
}

.poster-full img {
  display: block;
  width: 100%;
  height: auto;
  border-radius: 16px;
}

.section-title-row {
  display: grid;
  grid-template-columns: minmax(0, 0.95fr) minmax(320px, 0.8fr);
  gap: 24px;
  align-items: start;
  margin-bottom: 18px;
}

.section-title-row h2,
.section-title-row p {
  margin-bottom: 0;
}

.content-section p,
.activity-card p {
  color: var(--muted);
  line-height: 1.8;
}

.split-content {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(340px, 0.86fr);
  gap: 24px;
  align-items: stretch;
}

.quote-panel {
  display: grid;
  align-content: center;
  padding: 28px;
  border: 1px solid rgba(240, 164, 0, 0.28);
  border-radius: 18px;
  background: #fff8e4;
}

.quote-panel p {
  margin: 0;
  color: #4f3b05;
  font-size: 18px;
  font-weight: 750;
}

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

.member-grid article {
  min-height: 170px;
  padding: 22px;
  border: 1px solid var(--line);
  border-radius: 18px;
  background: #fff;
}

.member-grid h3 {
  margin: 0 0 10px;
  font-size: 20px;
}

.member-grid p {
  margin: 0;
}

.program-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 12px;
}

.program-grid article {
  min-height: 190px;
  padding: 20px;
  border: 1px solid var(--line);
  border-radius: 18px;
  background: var(--soft);
}

.program-grid span {
  display: block;
  margin-bottom: 18px;
  color: #86868b;
  font-size: 13px;
  font-weight: 800;
}

.program-grid h3 {
  margin: 0 0 8px;
  font-size: 18px;
}

.program-grid p {
  margin: 0;
  font-size: 14px;
}

.activity-card {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(360px, 0.72fr);
  gap: 28px;
  align-items: center;
}

.activity-card .link-button {
  margin-top: 6px;
}

.survey-entry {
  margin-bottom: 18px;
}

.survey-entry summary {
  display: grid;
  grid-template-columns: 160px 1fr;
  gap: 18px;
  align-items: center;
  min-height: 76px;
  padding: 0 28px;
  border-radius: 18px;
  color: #fff;
  background: #1d1d1f;
  font-weight: 750;
  cursor: pointer;
  box-shadow: var(--soft-shadow);
  list-style: none;
}

.survey-entry summary::-webkit-details-marker {
  display: none;
}

.survey-entry summary::after {
  content: "+";
  justify-self: end;
  font-size: 28px;
  line-height: 1;
}

.survey-entry[open] summary {
  border-radius: 18px 18px 0 0;
}

.survey-entry[open] summary::after {
  content: "-";
}

.survey-entry summary span {
  color: rgba(255, 255, 255, 0.72);
  font-size: 14px;
}

.survey-entry summary strong {
  font-size: 20px;
}

.survey-entry .form-shell {
  border-top: 0;
  border-radius: 0 0 18px 18px;
}

.form-section {
  padding: 28px;
  border-bottom: 1px solid var(--line);
}

.section-heading {
  display: flex;
  gap: 12px;
  margin-bottom: 18px;
}

.section-heading span {
  flex: 0 0 auto;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 34px;
  height: 34px;
  border-radius: 50%;
  color: #fff;
  background: linear-gradient(145deg, var(--green), #1e4238);
  font-weight: 700;
  box-shadow: 0 8px 18px rgba(43, 102, 82, 0.24);
}

.section-heading h2 {
  margin-bottom: 4px;
  font-size: 20px;
}

.section-heading p,
.panel p,
#form-message,
#admin-message {
  color: var(--muted);
  line-height: 1.6;
}

.section-heading .survey-warning {
  color: #d92d20;
  font-weight: 700;
}

.fields {
  display: grid;
  gap: 16px;
}

.two-col {
  grid-template-columns: 1fr 1fr;
}

label {
  display: grid;
  gap: 7px;
  color: #25302e;
  font-size: 14px;
  font-weight: 650;
}

input,
select,
textarea {
  width: 100%;
  min-height: 48px;
  border: 1px solid rgba(29, 29, 31, 0.11);
  border-radius: 8px;
  padding: 11px 13px;
  color: var(--ink);
  background: rgba(255, 255, 255, 0.9);
  font: inherit;
  font-weight: 400;
  box-shadow: inset 0 1px 2px rgba(29, 29, 31, 0.03);
}

textarea {
  min-height: 96px;
  resize: vertical;
}

input:focus,
select:focus,
textarea:focus {
  outline: 3px solid rgba(89, 185, 140, 0.2);
  border-color: var(--green-2);
  background: #fff;
}

.choice-group {
  display: grid;
  gap: 8px;
}

.support-grid {
  grid-template-columns: repeat(4, minmax(0, 1fr));
  margin-bottom: 16px;
  padding: 0;
  border: 0;
}

.choice {
  display: flex;
  align-items: center;
  gap: 8px;
  min-height: 36px;
  color: var(--ink);
  font-weight: 400;
}

.choice input,
.check-row input {
  width: 18px;
  min-height: 18px;
}

.submit-bar {
  padding: 20px 28px 28px;
}

button,
.link-button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 46px;
  border: 0;
  border-radius: 6px;
  padding: 0 18px;
  color: #fff;
  background: #1d1d1f;
  font: inherit;
  font-weight: 750;
  text-decoration: none;
  cursor: pointer;
  box-shadow: none;
}

button:hover,
.link-button:hover {
  background: #424245;
}

#submit-button {
  background: #d66000;
}

#submit-button:hover {
  background: #b94f00;
}

#member-submit-button {
  background: #f4680b;
}

#member-submit-button:hover {
  background: #d95b05;
}

button:disabled {
  opacity: 0.65;
  cursor: wait;
}

.admin-body {
  background: var(--paper);
}

.admin-page {
  max-width: 1280px;
  margin: 0 auto;
  padding: 24px;
}

.admin-header {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 16px;
  margin-bottom: 18px;
}

.admin-header-actions {
  display: flex;
  flex-wrap: wrap;
  justify-content: flex-end;
  gap: 10px;
}

.ghost-admin-link {
  color: var(--ink);
  border: 1px solid var(--line);
  background: #fff;
}

.ghost-admin-link:hover {
  color: #fff;
  background: #424245;
}

.admin-header h1 {
  margin: 14px 0 8px;
  font-size: 28px;
}

.admin-section-nav {
  position: sticky;
  top: 0;
  z-index: 8;
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 8px;
  margin: 0 0 18px;
  padding: 8px;
  border: 1px solid rgba(29, 29, 31, 0.08);
  border-radius: 16px;
  background: rgba(255, 255, 255, 0.92);
  box-shadow: 0 14px 40px rgba(29, 29, 31, 0.08);
  backdrop-filter: blur(18px);
}

.admin-section-nav a {
  display: flex;
  min-height: 44px;
  align-items: center;
  justify-content: center;
  padding: 0 12px;
  border-radius: 10px;
  color: var(--muted);
  font-weight: 800;
  text-align: center;
}

.admin-section-nav a:hover,
.admin-section-nav a.active {
  color: #fff;
  background: #f4680b;
}

.admin-section-nav .admin-home-link.active {
  background: var(--green);
}

.admin-grid {
  display: grid;
  grid-template-columns: minmax(360px, 0.85fr) minmax(520px, 1.15fr);
  gap: 18px;
  align-items: start;
}

.login-page {
  display: grid;
  place-items: center;
  min-height: 100vh;
  padding: 24px;
}

.login-card {
  width: min(100%, 420px);
  padding: 28px;
  border: 1px solid rgba(255, 255, 255, 0.78);
  border-radius: 18px;
  background: rgba(255, 255, 255, 0.92);
  box-shadow: var(--shadow);
  backdrop-filter: blur(20px);
}

.login-card h1 {
  margin: 16px 0 8px;
  font-size: 34px;
  line-height: 1.1;
}

.login-card p {
  color: var(--muted);
  line-height: 1.6;
}

.panel {
  padding: 20px;
}

.compact-form {
  display: grid;
  gap: 14px;
}

.check-row {
  display: flex;
  align-items: center;
  gap: 8px;
}

.check-row-group {
  display: flex;
  flex-wrap: wrap;
  gap: 14px;
}

.question-builder {
  display: grid;
  gap: 12px;
  padding-top: 4px;
}

.builder-title,
.panel-title-row,
.admin-actions {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}

.field-hint {
  margin: -6px 0 12px;
  color: var(--muted);
  font-size: 13px;
  line-height: 1.55;
}

.upload-field input[type="file"] {
  padding: 12px;
  cursor: pointer;
}

.file-hint,
.file-status {
  color: var(--muted);
  font-size: 13px;
  line-height: 1.5;
  font-weight: 500;
}

.file-status.success {
  color: var(--green);
  font-weight: 700;
}

.file-status.error {
  color: var(--danger);
  font-weight: 700;
}

.prep-cell {
  min-width: 180px;
  color: var(--ink);
  line-height: 1.55;
}

.prep-cell a {
  color: var(--green);
  font-weight: 700;
}

.muted-cell {
  color: var(--muted);
}

.post-submit-panel {
  margin-top: 18px;
  padding: 28px;
  border: 1px solid rgba(255, 255, 255, 0.78);
  border-radius: 18px;
  background: rgba(255, 255, 255, 0.9);
  box-shadow: var(--shadow);
  backdrop-filter: blur(20px);
}

.post-submit-panel[hidden] {
  display: none;
}

.post-submit-head {
  max-width: 720px;
  margin-bottom: 20px;
}

.post-submit-head h2 {
  margin-bottom: 10px;
  font-size: clamp(26px, 4vw, 38px);
  line-height: 1.15;
  letter-spacing: 0;
}

.post-submit-head p {
  color: var(--muted);
  line-height: 1.7;
}

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

.single-payment-grid {
  grid-template-columns: minmax(220px, 320px);
  justify-content: center;
}

.payment-code-section {
  display: grid;
  justify-items: center;
  text-align: center;
}

.payment-qr-image {
  display: block;
  width: min(100%, 260px);
  height: auto;
  margin: 8px auto 0;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fff;
}

.member-group-qr-image {
  display: block;
  width: min(100%, 280px);
  height: auto;
  margin: 8px auto 0;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fff;
}

.qr-tip {
  margin: 6px 0 0 !important;
  color: var(--muted) !important;
  font-size: 13px;
  line-height: 1.4 !important;
  text-align: center;
}

.post-submit-card .payment-qr-image {
  width: min(100%, 180px);
}

.card-action {
  margin-top: auto;
}

.post-submit-card {
  display: grid;
  align-content: start;
  gap: 10px;
  min-height: 280px;
  padding: 16px;
  border: 1px solid rgba(29, 29, 31, 0.08);
  border-radius: 16px;
  background: linear-gradient(180deg, #ffffff, #f8faf9);
  box-shadow: var(--soft-shadow);
}

.post-submit-card h3 {
  margin: 4px 0 0;
  font-size: 18px;
}

.post-submit-card p {
  margin: 0;
  color: var(--muted);
  line-height: 1.55;
}

.post-submit-card strong {
  color: var(--ink);
}

#post-submit-panel .post-submit-card:nth-child(3) {
  color: #fff;
  border-color: rgba(218, 128, 1, 0.3);
  background: #da8001;
}

#post-submit-panel .post-submit-card:nth-child(3) h3,
#post-submit-panel .post-submit-card:nth-child(3) p,
#post-submit-panel .post-submit-card:nth-child(3) strong,
#post-submit-panel .post-submit-card:nth-child(3) .orange-note {
  color: #fff !important;
}

#post-submit-panel .post-submit-card:nth-child(3) .link-button {
  color: #da8001;
  background: #fff;
}

#post-submit-panel .post-submit-card:nth-child(3) .link-button:hover {
  color: #fff;
  background: #1d1d1f;
}

.qr-placeholder {
  position: relative;
  display: grid;
  place-items: center;
  aspect-ratio: 1;
  width: 100%;
  max-width: 180px;
  margin: 0 auto 4px;
  overflow: hidden;
  border: 1px solid rgba(29, 29, 31, 0.16);
  border-radius: 12px;
  background:
    linear-gradient(90deg, rgba(29, 29, 31, 0.08) 10px, transparent 10px) 0 0 / 22px 22px,
    linear-gradient(rgba(29, 29, 31, 0.08) 10px, transparent 10px) 0 0 / 22px 22px,
    #fff;
}

.qr-placeholder::before,
.qr-placeholder::after {
  content: "";
  position: absolute;
  width: 42px;
  height: 42px;
  border: 8px solid var(--ink);
  border-radius: 4px;
  background: #fff;
}

.qr-placeholder::before {
  top: 14px;
  left: 14px;
}

.qr-placeholder::after {
  right: 14px;
  bottom: 14px;
}

.qr-placeholder span {
  position: relative;
  z-index: 1;
  max-width: 92px;
  padding: 6px 8px;
  border-radius: 8px;
  color: var(--ink);
  background: rgba(255, 255, 255, 0.88);
  font-size: 13px;
  font-weight: 750;
  text-align: center;
  line-height: 1.35;
}

.invite-box {
  display: grid;
  align-content: center;
  gap: 12px;
  aspect-ratio: 1;
  width: 100%;
  max-width: 180px;
  margin: 0 auto 4px;
  padding: 18px;
  border: 1px solid rgba(43, 102, 82, 0.18);
  border-radius: 12px;
  background:
    radial-gradient(circle at 50% 20%, rgba(89, 185, 140, 0.22), transparent 48%),
    #fff;
  text-align: center;
}

.invite-box span {
  color: var(--muted);
  font-size: 14px;
  font-weight: 700;
}

.invite-box strong {
  color: var(--green);
  font-size: 18px;
  line-height: 1.35;
}

.red-note {
  color: #d70015 !important;
  font-weight: 800;
}

.orange-note {
  color: #f0a400 !important;
  font-weight: 800;
}

.inline-red-note {
  color: #d70015;
  font-weight: 800;
}

.field-title-line {
  display: flex;
  align-items: baseline;
  gap: 4px;
  white-space: nowrap;
}

.member-required-note {
  margin: 12px 0 0;
  color: #d70015;
  font-weight: 800;
}

.member-confirmation {
  display: grid;
  gap: 18px;
}

.member-confirmation section {
  padding: 18px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: rgba(247, 250, 248, 0.78);
}

.member-confirmation h3 {
  margin: 0 0 10px;
  font-size: 18px;
}

.member-confirmation p {
  margin: 0 0 10px;
  color: #3f4644;
  line-height: 1.75;
}

.member-confirmation p:last-child {
  margin-bottom: 0;
}

.fee-breakdown {
  display: grid;
  gap: 8px;
  margin: 10px 0 12px;
}

.fee-breakdown p {
  padding: 12px 14px;
  border-radius: 8px;
  background: #fff;
}

.invoice-section {
  display: grid;
  gap: 14px;
}

.invoice-needed-field {
  width: min(100%, 220px);
}

.member-closing {
  color: var(--ink) !important;
  font-size: 18px;
  font-weight: 800;
}

.member-signature {
  color: var(--muted) !important;
  font-weight: 750;
}

.secretariat-contact {
  background: #fff !important;
}

.secretariat-contact p {
  margin-bottom: 6px;
}

@media (max-width: 900px) {
  .post-submit-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (max-width: 560px) {
  .post-submit-panel {
    padding: 20px 16px;
  }

  .post-submit-grid {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 560px) {
  body {
    background: #f5f5f7;
    -webkit-text-size-adjust: 100%;
  }

  .survey-tool-page {
    padding: 8px 8px calc(84px + env(safe-area-inset-bottom));
  }

  .tool-nav {
    top: calc(6px + env(safe-area-inset-top));
    width: calc(100% - 8px);
    margin-bottom: 10px;
    border-radius: 12px;
  }

  .tool-nav a {
    min-height: 40px;
    font-size: 14px;
  }

  .survey-tool-page .survey-hero {
    grid-template-columns: minmax(0, 1fr) 112px;
    gap: 10px;
    margin-bottom: 10px;
    padding: 12px;
    border-radius: 16px;
  }

  .survey-tool-page .survey-hero-copy {
    min-width: 0;
  }

  .survey-tool-page .logo-card {
    width: min(100%, 210px);
    min-height: 44px;
    padding: 6px 8px;
    margin-bottom: 10px;
    border-radius: 10px;
  }

  .survey-tool-page .survey-hero h1 {
    max-width: 100%;
    margin-bottom: 8px;
    font-size: 28px;
    line-height: 1.08;
  }

  .member-tool-page .member-hero h1 {
    font-size: 36px;
  }

  .survey-tool-page .survey-hero p {
    margin-bottom: 10px;
    font-size: 14px;
    line-height: 1.55;
  }

  .survey-tool-page .survey-mascot {
    align-self: stretch;
    min-height: 168px;
    padding: 12px 4px 0;
    border-radius: 14px;
  }

  .survey-tool-page .survey-mascot img {
    width: min(100%, 112px);
  }

  .member-tool-page .member-mascot img {
    width: min(100%, 124px);
    transform: translateY(8px);
  }

  .meta {
    gap: 8px;
  }

  .meta div {
    grid-template-columns: 68px 1fr;
    min-height: 38px;
    padding: 8px 10px;
    font-size: 13px;
  }

  .form-shell,
  .post-submit-panel {
    border-radius: 16px;
  }

  .form-section {
    padding: 18px 14px;
  }

  .section-heading {
    gap: 10px;
    margin-bottom: 14px;
  }

  .section-heading span {
    width: 30px;
    height: 30px;
    font-size: 13px;
  }

  .section-heading h2 {
    font-size: 18px;
  }

  .section-heading p {
    font-size: 14px;
    line-height: 1.45;
  }

  .fields {
    gap: 12px;
  }

  label {
    gap: 6px;
    font-size: 14px;
  }

  input,
  select,
  textarea {
    min-height: 50px;
    border-radius: 9px;
    padding: 12px 13px;
    font-size: 16px;
  }

  textarea {
    min-height: 104px;
  }

  .field-title-line {
    flex-wrap: wrap;
    white-space: normal;
  }

  .support-grid {
    grid-template-columns: 1fr 1fr;
    gap: 10px 8px;
  }

  .choice {
    min-height: 42px;
    padding: 4px 0;
  }

  .choice input,
  .check-row input {
    width: 20px;
    min-height: 20px;
  }

  .submit-bar {
    position: sticky;
    bottom: 0;
    z-index: 9;
    display: grid;
    gap: 8px;
    padding: 10px 14px calc(10px + env(safe-area-inset-bottom));
    border-top: 1px solid var(--line);
    background: rgba(255, 255, 255, 0.92);
    backdrop-filter: blur(18px);
  }

  button,
  .link-button {
    width: 100%;
    min-height: 48px;
    border-radius: 9px;
    font-size: 16px;
  }

  #form-message,
  #member-message {
    margin: 0;
    font-size: 14px;
    line-height: 1.45;
  }

  .post-submit-panel {
    margin-top: 10px;
    padding: 18px 14px;
  }

  .post-submit-head {
    margin-bottom: 14px;
  }

  .post-submit-head h2 {
    font-size: 28px;
  }

  .post-submit-card {
    min-height: auto;
    border-radius: 14px;
  }

  .post-submit-card .payment-qr-image,
  .payment-qr-image {
    width: min(100%, 240px);
  }

  .member-group-qr-image {
    width: min(100%, 260px);
  }

  .member-confirmation {
    gap: 12px;
  }

  .member-confirmation section {
    padding: 14px;
  }

  .fee-breakdown p {
    padding: 10px 12px;
  }

  .invoice-needed-field {
    width: min(100%, 180px);
  }
}

.question-card {
  display: grid;
  gap: 10px;
  padding: 12px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: rgba(247, 250, 248, 0.9);
}

.question-card .row {
  display: grid;
  grid-template-columns: 1fr 130px;
  gap: 10px;
}

.stats {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 10px;
  margin: 16px 0;
}

.stats div {
  padding: 14px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: rgba(247, 250, 248, 0.9);
}

.stats strong {
  display: block;
  margin-bottom: 4px;
  font-size: 28px;
  color: var(--green);
}

.stats span {
  color: var(--muted);
}

.table-wrap {
  overflow: auto;
  margin-top: 16px;
  border: 1px solid var(--line);
  border-radius: 8px;
}

table {
  width: 100%;
  min-width: 760px;
  border-collapse: collapse;
  background: #fff;
}

th,
td {
  padding: 12px;
  border-bottom: 1px solid var(--line);
  text-align: left;
  vertical-align: top;
  font-size: 14px;
}

th {
  color: var(--muted);
  background: #f8faf9;
  font-weight: 750;
}

.empty {
  color: var(--muted);
  text-align: center;
}

.error {
  color: var(--danger) !important;
}

.success {
  color: var(--green) !important;
}

.site-footer {
  padding: 26px 10px 6px;
  color: var(--muted);
  text-align: center;
  font-size: 14px;
}

@media (max-width: 760px) {
  .site-header {
    position: static;
    align-items: flex-start;
    flex-direction: column;
    padding: 10px;
  }

  .site-logo {
    width: min(100%, 300px);
  }

  .site-nav {
    width: 100%;
    justify-content: space-between;
  }

  .site-nav a {
    padding: 8px 6px;
    font-size: 13px;
  }

  .page {
    padding: 10px 10px 28px;
  }

  .hero,
  .form-section,
  .content-section,
  .letter-section,
  .letter-teaser,
  .activity-card,
  .submit-bar {
    padding: 20px 16px;
  }

  .hero {
    grid-template-columns: 1fr;
    gap: 14px;
  }

  .poster-hero {
    min-height: auto;
  }

  .hero-copy {
    padding: 0;
  }

  .hero h1 {
    font-size: 34px;
  }

  .logo-card {
    width: 100%;
    min-height: 58px;
    margin-bottom: 14px;
  }

  .hero-visual {
    min-height: 260px;
  }

  .mascot-frame {
    min-height: 280px;
    padding: 18px 12px 0;
  }

  .hero-visual.mascot-frame img {
    width: min(68%, 230px);
  }

  .poster-frame {
    min-height: 420px;
    padding: 10px;
  }

  .meta div {
    grid-template-columns: 70px 1fr;
  }

  .two-col,
  .admin-grid,
  .split-content,
  .section-title-row,
  .intro-copy,
  .principle-grid,
  .member-grid,
  .letter-section,
  .letter-teaser,
  .activity-card {
    grid-template-columns: 1fr;
  }

  .letter-page-main {
    padding: 36px 16px 58px;
  }

  .poster-page-main {
    padding: 36px 16px 58px;
  }

  .poster-full {
    padding: 10px;
  }

  .letter-hero h1 {
    font-size: 38px;
  }

  .letter-document {
    font-size: 17px;
  }

  .letter-actions {
    flex-direction: column;
  }

  .display-title {
    font-size: 36px !important;
  }

  .intro-copy p,
  .letter-body {
    font-size: 16px;
  }

  .letter-head {
    position: static;
  }

  .principle-grid strong {
    margin-bottom: 18px;
  }

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

  .survey-entry summary {
    grid-template-columns: 1fr auto;
    padding: 16px;
  }

  .survey-entry summary span {
    grid-column: 1 / -1;
  }

  .admin-page {
    padding: 14px;
  }

  .admin-header {
    align-items: stretch;
    flex-direction: column;
  }

  .admin-section-nav,
  .admin-branch-grid {
    grid-template-columns: 1fr;
  }

  .admin-section-nav {
    position: static;
  }

  .question-card .row,
  .stats {
    grid-template-columns: 1fr;
  }

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

@media (max-width: 420px) {
  .support-grid {
    grid-template-columns: 1fr 1fr;
  }
}

@media (max-width: 560px) {
  .survey-tool-page {
    padding: 8px 8px calc(84px + env(safe-area-inset-bottom));
  }

  .pre-h5-page {
    padding: 12px 12px calc(88px + env(safe-area-inset-bottom));
  }

  .survey-tool-page .survey-hero {
    grid-template-columns: minmax(0, 1fr) 112px;
    gap: 10px;
    padding: 12px;
  }

  .pre-h5-page .survey-hero {
    grid-template-columns: 1fr;
    gap: 12px;
    padding: 14px;
  }

  .pre-topline {
    grid-template-columns: 1fr;
    gap: 8px;
  }

  .pre-topline .logo-card {
    width: min(100%, 230px);
    margin-bottom: 0;
  }

  .pre-topline span {
    justify-self: start;
  }

  .survey-tool-page .logo-card {
    width: min(100%, 210px);
    min-height: 44px;
    padding: 6px 8px;
    margin-bottom: 10px;
  }

  .survey-tool-page .survey-hero h1 {
    font-size: 28px;
  }

  .pre-h5-page #activity-title {
    font-size: 34px;
  }

  .member-tool-page .member-hero h1 {
    font-size: 36px;
  }

  .survey-tool-page .survey-mascot {
    min-height: 168px;
    padding: 12px 4px 0;
  }

  .pre-h5-page .survey-mascot {
    min-height: 150px;
    padding-top: 12px;
  }

  .survey-tool-page .survey-mascot img {
    width: min(100%, 112px);
  }

  .pre-h5-page .survey-mascot img {
    width: min(66%, 190px);
  }

  .member-tool-page .member-mascot img {
    width: min(100%, 124px);
  }

  .form-section,
  .submit-bar {
    padding: 18px 14px;
  }

  .submit-bar {
    position: sticky;
    bottom: 0;
    z-index: 9;
    padding: 10px 14px calc(10px + env(safe-area-inset-bottom));
    border-top: 1px solid var(--line);
    background: rgba(255, 255, 255, 0.92);
    backdrop-filter: blur(18px);
  }

  button,
  .link-button {
    width: 100%;
    min-height: 48px;
    font-size: 16px;
  }

  input,
  select,
  textarea {
    min-height: 50px;
    font-size: 16px;
  }

  .post-submit-card .payment-qr-image,
  .payment-qr-image {
    width: min(100%, 240px);
  }

  .member-group-qr-image {
    width: min(100%, 260px);
  }
}
