:root {
  --ypc-cream: #f7f3ee;
  --ypc-white: #fffdf9;
  --ypc-ink: #1c1a17;
  --ypc-muted: #6f685f;
  --ypc-line: #e6ddd2;
  --ypc-gold: #b9985a;
  --ypc-gold-dark: #9f8149;
  --ypc-shadow: 0 24px 60px rgba(28, 26, 23, 0.08);
  --ypc-radius-lg: 24px;
  --ypc-radius-md: 14px;
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body.forms-page {
  margin: 0;
  font-family: 'Inter', sans-serif;
  color: var(--ypc-ink);
  background: linear-gradient(to bottom, #f3eee7 0%, #f8f5f1 30%, #fcfaf7 100%);
}

.form-hero {
  position: relative;
  min-height: 42vh;
  display: flex;
  align-items: end;
  padding: 4.5rem 1.5rem 2.5rem;
  background:
    linear-gradient(rgba(25, 20, 14, 0.42), rgba(25, 20, 14, 0.52)),
    url('../assets/images/band-liability-waiver-landscape.jpg') center center / cover no-repeat;
}

.form-hero__content {
  position: relative;
  width: 100%;
  max-width: 1100px;
  margin: 0 auto;
  color: #fffaf2;
}

.form-eyebrow {
  margin: 0 0 0.95rem;
  font-size: 0.76rem;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  opacity: 0.85;
}

.form-hero h1 {
  margin: 0;
  font-family: 'Playfair Display', serif;
  font-size: clamp(2.3rem, 5vw, 4rem);
  line-height: 1;
  font-weight: 400;
}

.form-intro {
  max-width: 580px;
  margin-top: 0.85rem;
  font-size: 0.98rem;
  line-height: 1.7;
  color: rgba(255, 250, 242, 0.94);
}

.form-contact-details {
  margin-top: 1rem;
}

.form-contact-details p {
  margin: 0;
  font-size: 0.94rem;
  line-height: 1.7;
  color: rgba(255, 250, 242, 0.88);
}

.form-contact-details p + p {
  margin-top: 0.15rem;
}

.form-contact-details a {
  color: #fffaf2;
}

.form-contact-details a:hover {
  color: rgba(255, 250, 242, 0.82);
}

.waiver-shell {
  padding: 0 1.5rem 5rem;
  margin-top: -2rem;
}

.waiver-context {
  max-width: 1000px;
  margin: 0 auto 1rem;
  padding: 1.2rem 1.25rem;
  border-radius: 18px;
  border: 1px solid rgba(185, 152, 90, 0.24);
  background: rgba(255, 253, 249, 0.9);
  box-shadow: 0 14px 34px rgba(28, 26, 23, 0.06);
}

.waiver-context__eyebrow {
  margin: 0 0 0.6rem;
  font-size: 0.72rem;
  font-weight: 600;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  color: var(--ypc-gold-dark);
}

.waiver-context__title {
  margin: 0;
  font-family: 'Playfair Display', serif;
  font-size: clamp(1.5rem, 2.8vw, 2rem);
  line-height: 1.08;
  font-weight: 400;
  color: #29231d;
}

.waiver-context__text {
  margin: 0.75rem 0 0;
  max-width: 780px;
  font-size: 0.95rem;
  line-height: 1.72;
  color: #5f574e;
}

.waiver-context__actions {
  margin-top: 1rem;
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}

.waiver-card {
  max-width: 1000px;
  margin: 0 auto;
  background: rgba(255, 253, 249, 0.97);
  border: 1px solid rgba(185, 152, 90, 0.14);
  border-radius: var(--ypc-radius-lg);
  box-shadow: var(--ypc-shadow);
  overflow: hidden;
}

.form-card + .form-card {
  margin-top: 1.4rem;
}

.waiver-form {
  padding: 2.2rem 2.4rem 3rem;
}

.form-section {
  padding: 2rem 0;
  border-bottom: 1px solid var(--ypc-line);
}

.form-section:last-child {
  border-bottom: 0;
  padding-bottom: 0;
}

.section-heading {
  display: grid;
  grid-template-columns: 56px 1fr;
  gap: 0.9rem;
  align-items: start;
  margin-bottom: 1.6rem;
}

.section-number {
  width: 44px;
  height: 44px;
  border-radius: 999px;
  border: 1px solid rgba(185, 152, 90, 0.32);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  color: var(--ypc-gold-dark);
  font-size: 0.78rem;
  letter-spacing: 0.08em;
  background: rgba(185, 152, 90, 0.04);
}

.section-heading h3 {
  margin: 0 0 0.35rem;
  font-family: 'Playfair Display', serif;
  font-size: 1.25rem;
  font-weight: 400;
}

.section-heading p {
  margin: 0;
  color: var(--ypc-muted);
  line-height: 1.6;
  font-size: 0.95rem;
}

.form-grid {
  display: grid;
  gap: 1.1rem;
}

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

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

.field {
  display: flex;
  flex-direction: column;
}

.field.full {
  grid-column: 1 / -1;
}

.field label {
  margin-bottom: 0.5rem;
  font-size: 0.9rem;
  font-weight: 600;
}

.field small {
  margin-top: 0.45rem;
  color: var(--ypc-muted);
  font-size: 0.82rem;
  line-height: 1.5;
}

.field input,
.field select,
.field textarea {
  width: 100%;
  border: 1px solid var(--ypc-line);
  background: #fffdfa;
  border-radius: var(--ypc-radius-md);
  padding: 0.88rem 0.95rem;
  font: inherit;
  font-size: 0.96rem;
  color: var(--ypc-ink);
  transition: border-color 0.2s ease, box-shadow 0.2s ease, background 0.2s ease;
}

.field input::placeholder,
.field textarea::placeholder {
  color: #9a9085;
}

.field input:focus,
.field select:focus,
.field textarea:focus {
  outline: none;
  border-color: rgba(185, 152, 90, 0.85);
  box-shadow: 0 0 0 4px rgba(185, 152, 90, 0.12);
  background: #fff;
}

.legal-section .legal-copy {
  background: linear-gradient(180deg, rgba(247, 243, 238, 0.76), rgba(255, 253, 249, 0.98));
  border: 1px solid var(--ypc-line);
  border-radius: 18px;
  padding: 1.25rem;
  margin-bottom: 1.2rem;
}

.legal-copy p {
  margin: 0 0 0.9rem;
  line-height: 1.72;
  color: #332d27;
  font-size: 0.93rem;
}

.legal-copy p:last-child {
  margin-bottom: 0;
}

.initial-field {
  max-width: 200px;
}

.final-consent {
  padding-top: 1.6rem;
}

.checkbox-field {
  display: flex;
  gap: 0.8rem;
  align-items: start;
  margin-bottom: 1.25rem;
  line-height: 1.6;
  font-size: 0.94rem;
}

.checkbox-field input {
  margin-top: 0.28rem;
}

.choice-stack {
  display: grid;
  gap: 0.35rem;
}

.form-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 0.85rem;
  align-items: center;
}

.submit-btn {
  appearance: none;
  border: 1px solid var(--ypc-gold);
  border-radius: 999px;
  background: rgba(185, 152, 90, 0.04);
  color: var(--ypc-gold-dark);
  font: inherit;
  font-weight: 600;
  padding: 0.95rem 1.75rem;
  min-width: 220px;
  cursor: pointer;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  transition:
    transform 0.25s ease,
    box-shadow 0.25s ease,
    background-color 0.25s ease,
    border-color 0.25s ease,
    color 0.25s ease,
    opacity 0.25s ease;
  box-shadow: none;
}

.submit-btn:hover {
  transform: translateY(-1px);
  background: var(--ypc-gold);
  border-color: var(--ypc-gold);
  color: #fffaf2;
  box-shadow: 0 6px 18px rgba(0, 0, 0, 0.08);
}

.form-success {
  display: none;
  margin-top: 1.1rem;
  padding: 0.95rem 1rem;
  border-radius: 14px;
  border: 1px solid rgba(185, 152, 90, 0.2);
  background: rgba(185, 152, 90, 0.08);
  color: #4a3d28;
  line-height: 1.6;
  font-size: 0.93rem;
}

.form-success.is-visible {
  display: block;
}

a {
  color: var(--ypc-gold-dark);
  text-decoration: none;
}

a:hover {
  text-decoration: underline;
}

@media (max-width: 820px) {
  .waiver-context {
    padding: 1rem;
  }

  .waiver-context__text {
    font-size: 0.92rem;
  }

  .waiver-form {
    padding: 1.5rem 1.2rem 2.25rem;
  }

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

  .section-heading {
    grid-template-columns: 1fr;
  }

  .section-number {
    margin-bottom: 0.35rem;
  }

  .form-hero {
    min-height: 34vh;
    padding-top: 3.5rem;
  }

  .initial-field {
    max-width: 100%;
  }
}

@media print {
  @page {
    size: letter;
    margin: 0.22in;
  }

  body.forms-page {
    background: #fff;
    color: #111;
  }

  .site-header,
  .form-hero,
  .waiver-context,
  .page-utility,
  .page-footer,
  .page-footer *,
  .page-resource-grid,
  [data-site-footer],
  .form-actions {
    display: none !important;
  }

  .waiver-shell {
    margin: 0;
    padding: 0;
  }

  .form-card + .form-card {
    margin-top: 0;
  }

  .waiver-card {
    max-width: none;
    margin: 0;
    border: 0;
    border-radius: 0;
    box-shadow: none;
    background: #fff;
    overflow: visible;
  }

  body[data-print-target] .waiver-card {
    display: none;
  }

  body[data-print-target="grand-opening-waiver"] #grand-opening-waiver,
  body[data-print-target="polo-school-registration"] #polo-school-registration {
    display: block;
  }

  .waiver-form {
    padding: 0;
  }

  #grand-opening-waiver::before,
  #polo-school-registration::before {
    display: block;
    margin: 0 0 0.04in;
    padding-bottom: 0.03in;
    border-bottom: 1px solid #111;
    font-family: Georgia, "Times New Roman", serif;
    font-size: 12pt;
    line-height: 1;
    color: #111;
  }

  #grand-opening-waiver::before {
    content: "Grand Opening Visitor Waiver";
  }

  #polo-school-registration::before {
    content: "Polo School Registration & Waiver";
  }

  .form-section {
    break-inside: avoid;
    padding: 0.025in 0;
    border-bottom: 0;
  }

  .section-heading {
    display: block;
    margin-bottom: 0.035in;
  }

  .section-number {
    display: none;
  }

  .section-heading h3 {
    margin: 0;
    font-family: Georgia, "Times New Roman", serif;
    font-size: 8.2pt;
    line-height: 1.05;
    font-weight: 700;
    color: #111;
  }

  .section-heading p {
    display: none;
  }

  .section-heading p,
  .legal-copy p,
  .checkbox-field,
  .field label,
  .field input,
  .field select,
  .field textarea {
    font-size: 7.8pt;
    line-height: 1.04;
  }

  .form-grid,
  .two-col,
  .single-col {
    gap: 0.018in 0.08in;
  }

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

  .field,
  .field[hidden] {
    display: flex !important;
  }

  .field label {
    margin-bottom: 0;
    font-weight: 600;
  }

  .field input,
  .field select,
  .field textarea {
    min-height: 0.15in;
    padding: 0;
    border: 0;
    border-bottom: 1px solid #555;
    border-radius: 0;
    background: #fff;
    box-shadow: none;
  }

  .field textarea {
    min-height: 0.24in;
    resize: none;
    background:
      repeating-linear-gradient(
        to bottom,
        transparent 0,
        transparent 0.11in,
        #777 0.115in,
        #777 0.12in
      );
    border-bottom: 0;
  }

  .checkbox-field {
    gap: 0.04in;
    margin-bottom: 0.01in;
    line-height: 1.02;
  }

  .checkbox-field input {
    width: 0.08in;
    height: 0.08in;
    margin-top: 0;
  }

  .choice-stack {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 0.015in 0.06in;
  }

  .legal-section .legal-copy {
    padding: 0;
    border: 0;
    border-radius: 0;
    background: #fff;
  }

  .legal-copy p {
    margin: 0 0 0.012in;
    font-size: 5.2pt;
    line-height: 1.08;
  }

  #polo-school-registration .waiver-form,
  #grand-opening-waiver .waiver-form {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 0.01in 0.1in;
  }

  #polo-school-registration .waiver-form {
    min-height: 10.18in;
    align-content: space-between;
  }

  #polo-school-registration .form-section:nth-of-type(5),
  #polo-school-registration .form-section:nth-of-type(6),
  #polo-school-registration .form-section:nth-of-type(7),
  #polo-school-registration .form-section:nth-of-type(8),
  #polo-school-registration .form-section:nth-of-type(9),
  #polo-school-registration .form-section:nth-of-type(10),
  #grand-opening-waiver .form-section:nth-of-type(3),
  #grand-opening-waiver .form-section:nth-of-type(4),
  #grand-opening-waiver .form-section:nth-of-type(5),
  #grand-opening-waiver .form-section:nth-of-type(6) {
    grid-column: 1 / -1;
  }

  #polo-school-registration .form-section:nth-of-type(5) .single-col {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }

  #polo-school-registration .form-section:nth-of-type(5) .field:first-child textarea {
    min-height: 0.34in;
  }

  #polo-school-registration .form-section:nth-of-type(5) .field:nth-child(2) textarea,
  #polo-school-registration .form-section:nth-of-type(5) .field:nth-child(3) textarea {
    min-height: 0.2in;
  }

  #polo-school-registration .form-section:nth-of-type(7) {
    display: grid;
    grid-template-columns: 1.25in 1fr;
    column-gap: 0.1in;
    align-items: start;
  }

  #polo-school-registration .form-section:nth-of-type(7) .section-heading {
    margin-bottom: 0;
  }

  #polo-school-registration .form-section:nth-of-type(9) .two-col,
  #grand-opening-waiver .form-section:nth-of-type(5) .two-col {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }

  #polo-school-registration .form-section:nth-of-type(9) .field.full,
  #grand-opening-waiver .form-section:nth-of-type(5) .field.full {
    grid-column: auto;
  }

  .final-consent {
    padding-top: 0.03in;
  }
}
