:root {
  color-scheme: light;
  --ink: #27211f;
  --muted: #716864;
  --line: #e6ded7;
  --paper: #fffaf6;
  --coral: #d95f4c;
  --coral-dark: #a83d31;
  --teal: #176d72;
  --gold: #c5934f;
}

* {
  box-sizing: border-box;
}

body {
  margin: 0;
  color: var(--ink);
  background: var(--paper);
  font-family:
    -apple-system, BlinkMacSystemFont, "Segoe UI", "PingFang SC", "Hiragino Sans GB",
    "Microsoft YaHei", sans-serif;
}

main {
  overflow: hidden;
}

.hero {
  position: relative;
  min-height: 88vh;
  display: grid;
  align-items: end;
  isolation: isolate;
}

.hero__image,
.hero__shade {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
}

.hero__image {
  object-fit: cover;
  object-position: center;
  z-index: -2;
}

.hero__shade {
  z-index: -1;
  background:
    linear-gradient(180deg, rgba(39, 33, 31, 0.18), rgba(39, 33, 31, 0.74)),
    linear-gradient(90deg, rgba(39, 33, 31, 0.68), rgba(39, 33, 31, 0.08));
}

.hero__content {
  width: min(100%, 980px);
  padding: 0 22px 54px;
  color: #fffaf6;
}

.eyebrow,
.section-kicker {
  margin: 0 0 12px;
  color: var(--gold);
  font-size: 13px;
  font-weight: 700;
  letter-spacing: 0;
}

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

h1 {
  max-width: 760px;
  margin-bottom: 16px;
  font-size: clamp(42px, 12vw, 82px);
  line-height: 0.96;
  letter-spacing: 0;
}

h2 {
  margin-bottom: 14px;
  font-size: clamp(28px, 8vw, 44px);
  line-height: 1.08;
  letter-spacing: 0;
}

.lead {
  max-width: 560px;
  color: rgba(255, 250, 246, 0.9);
  font-size: 19px;
  line-height: 1.7;
}

.hero__facts {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-top: 26px;
}

.hero__facts span {
  border: 1px solid rgba(255, 250, 246, 0.45);
  background: rgba(255, 250, 246, 0.12);
  padding: 10px 13px;
  border-radius: 6px;
  backdrop-filter: blur(10px);
}

.intro,
.schedule,
.signup,
.admin-shell {
  width: min(100% - 36px, 980px);
  margin: 0 auto;
}

.intro {
  display: grid;
  grid-template-columns: 0.85fr 1.15fr;
  gap: 36px;
  padding: 64px 0 34px;
}

.intro p,
.signup__copy p {
  color: var(--muted);
  font-size: 17px;
  line-height: 1.9;
}

.details {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1px;
  width: min(100% - 36px, 980px);
  margin: 0 auto;
  border: 1px solid var(--line);
  background: var(--line);
}

.detail {
  min-height: 118px;
  padding: 24px;
  background: #fff;
}

.detail strong,
.detail span {
  display: block;
}

.detail strong {
  margin-bottom: 14px;
  color: var(--teal);
}

.detail span {
  color: var(--muted);
  line-height: 1.55;
}

.schedule {
  padding: 66px 0 38px;
}

.timeline {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 14px;
  margin-top: 24px;
}

.timeline div {
  min-height: 150px;
  padding: 22px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fff;
}

.timeline span {
  display: block;
  margin-bottom: 22px;
  color: var(--coral);
  font-weight: 800;
}

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

.signup {
  display: grid;
  grid-template-columns: 0.95fr 1.05fr;
  gap: 38px;
  padding: 48px 0 78px;
}

.form {
  display: grid;
  gap: 18px;
  padding: 26px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fff;
  box-shadow: 0 18px 42px rgba(39, 33, 31, 0.08);
}

label,
fieldset {
  display: grid;
  gap: 10px;
  margin: 0;
  padding: 0;
  border: 0;
}

label span,
legend {
  color: var(--ink);
  font-size: 14px;
  font-weight: 700;
}

input[type="text"],
input[type="tel"] {
  width: 100%;
  min-height: 48px;
  border: 1px solid var(--line);
  border-radius: 6px;
  padding: 0 14px;
  color: var(--ink);
  font: inherit;
  background: #fffaf6;
}

input:focus {
  outline: 2px solid rgba(23, 109, 114, 0.22);
  border-color: var(--teal);
}

.gender-options {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 12px;
}

.gender-options label {
  min-height: 48px;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  border: 1px solid var(--line);
  border-radius: 6px;
  background: #fffaf6;
}

button,
.export-link {
  min-height: 50px;
  border: 0;
  border-radius: 6px;
  padding: 0 18px;
  color: #fff;
  background: var(--coral);
  font: inherit;
  font-weight: 800;
  text-decoration: none;
  cursor: pointer;
}

button:hover,
.export-link:hover {
  background: var(--coral-dark);
}

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

.form-message {
  min-height: 22px;
  margin: 0;
  color: var(--muted);
  font-size: 14px;
  line-height: 1.55;
}

.form-message.success {
  color: var(--teal);
}

.form-message.error {
  color: var(--coral-dark);
}

.admin-page {
  background: #f7f3ef;
}

.admin-shell {
  padding: 42px 0;
}

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

.admin-header h1 {
  margin: 0;
  font-size: clamp(30px, 6vw, 48px);
  color: var(--ink);
}

.export-link {
  display: inline-grid;
  align-items: center;
  white-space: nowrap;
}

.admin-stats {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 12px;
  margin-bottom: 20px;
}

.admin-stats div {
  padding: 20px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fff;
}

.admin-stats strong,
.admin-stats span {
  display: block;
}

.admin-stats strong {
  font-size: 32px;
}

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

.admin-panel {
  margin-bottom: 20px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fff;
}

.admin-panel__title {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding: 18px 20px;
  border-bottom: 1px solid var(--line);
}

.admin-panel__title h2 {
  margin: 0;
  font-size: 20px;
}

select {
  min-height: 42px;
  border: 1px solid var(--line);
  border-radius: 6px;
  padding: 0 12px;
  color: var(--ink);
  background: #fffaf6;
  font: inherit;
}

.event-list {
  display: grid;
}

.event-admin-card {
  display: grid;
  grid-template-columns: 1.3fr 0.8fr 1.6fr;
  gap: 16px;
  align-items: center;
  padding: 18px 20px;
  border-bottom: 1px solid var(--line);
}

.event-admin-card:last-child {
  border-bottom: 0;
}

.event-admin-card strong,
.event-admin-card span,
.event-admin-card small {
  display: block;
}

.event-admin-card strong {
  margin-bottom: 6px;
}

.event-admin-card span,
.event-admin-card small,
.event-admin-card__meta {
  color: var(--muted);
}

.event-admin-card small {
  margin-top: 5px;
}

.event-admin-card__meta {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  align-items: center;
}

.event-admin-card__actions {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  justify-content: flex-end;
}

.admin-action {
  min-height: 34px;
  padding: 0 10px;
  border: 1px solid rgba(23, 109, 114, 0.18);
  color: var(--teal);
  background: rgba(23, 109, 114, 0.08);
  font-size: 13px;
}

.admin-action:hover {
  color: #fff;
  background: var(--teal);
}

.admin-action:disabled {
  cursor: default;
  color: #fff;
  background: var(--muted);
  opacity: 1;
}

.table-wrap {
  overflow-x: auto;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fff;
}

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

th,
td {
  padding: 15px 16px;
  border-bottom: 1px solid var(--line);
  text-align: left;
  white-space: nowrap;
}

th {
  color: var(--teal);
  font-size: 13px;
}

.answers-cell {
  min-width: 220px;
  color: var(--muted);
  line-height: 1.6;
  white-space: normal;
}

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

.status {
  display: inline-block;
  border-radius: 6px;
  padding: 6px 9px;
  color: var(--teal);
  background: rgba(23, 109, 114, 0.1);
  font-size: 13px;
  font-weight: 700;
}

@media (max-width: 760px) {
  .hero {
    min-height: 86vh;
  }

  .hero__content {
    padding-bottom: 42px;
  }

  .intro,
  .signup,
  .details,
  .timeline,
  .admin-stats {
    grid-template-columns: 1fr;
  }

  .timeline {
    gap: 10px;
  }

  .signup {
    gap: 22px;
  }

  .form {
    padding: 20px;
  }

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

  .admin-panel__title,
  .event-admin-card {
    align-items: flex-start;
    grid-template-columns: 1fr;
  }

  .admin-panel__title {
    flex-direction: column;
  }

  .event-admin-card__actions {
    justify-content: flex-start;
  }
}
