*, *::before, *::after {
  box-sizing: border-box;
}

:root {
  --bg: #060d0a;
  --bg-alt: #0b1711;
  --surface: rgba(255, 255, 255, .045);
  --surface-strong: rgba(255, 255, 255, .075);
  --border: rgba(255, 255, 255, .1);
  --green: #40916c;
  --green-light: #74c69d;
  --green-pale: #d8f3dc;
  --gold: #f4dda0;
  --white: #f4f7f5;
  --muted: #b4c0b9;
  --warning: #fff3c4;
  --warning-bg: rgba(244, 221, 160, .1);
}

html {
  scroll-behavior: smooth;
  scroll-padding-top: 90px;
}

body {
  min-height: 100vh;
  margin: 0;
  overflow-x: hidden;
  background:
    radial-gradient(circle at 50% -15%, rgba(64, 145, 108, .18), transparent 34rem),
    var(--bg);
  color: var(--white);
  font-family: Arial, Helvetica, sans-serif;
  line-height: 1.7;
}

a {
  color: var(--green-light);
  text-underline-offset: 3px;
}

a:hover {
  color: var(--green-pale);
}

a:focus-visible,
button:focus-visible {
  outline: 3px solid var(--green-light);
  outline-offset: 4px;
}

.skip-link {
  position: fixed;
  z-index: 6000;
  top: 8px;
  left: 8px;
  padding: 10px 14px;
  border-radius: 10px;
  background: #fff;
  color: #07150f;
  transform: translateY(-150%);
}

.skip-link:focus {
  transform: translateY(0);
}

.legal-header {
  position: sticky;
  z-index: 1000;
  top: 0;
  border-bottom: 1px solid var(--border);
  background: rgba(6, 13, 10, .92);
  backdrop-filter: blur(16px);
}

.legal-header-inner {
  display: flex;
  width: min(1080px, calc(100% - 32px));
  min-height: 70px;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  margin: 0 auto;
}

.legal-logo {
  color: var(--green-light);
  font-family: Georgia, "Times New Roman", serif;
  font-size: 22px;
  font-weight: 700;
  text-decoration: none;
}

.back-home {
  display: inline-flex;
  min-height: 46px;
  align-items: center;
  padding: 8px 14px;
  border: 1px solid var(--border);
  border-radius: 13px;
  color: var(--white);
  font-size: 14px;
  font-weight: 800;
  text-decoration: none;
}

.legal-shell {
  width: min(920px, calc(100% - 32px));
  margin: 0 auto;
  padding: 64px 0 76px;
}

.legal-kicker {
  margin: 0 0 10px;
  color: var(--green-light);
  font-size: 12px;
  font-weight: 900;
  letter-spacing: 1.7px;
  text-transform: uppercase;
}

h1,
h2,
h3 {
  color: var(--white);
  font-family: Georgia, "Times New Roman", serif;
  line-height: 1.2;
}

h1 {
  max-width: 780px;
  margin: 0 0 16px;
  font-size: clamp(38px, 7vw, 62px);
  letter-spacing: -.5px;
}

h2 {
  margin: 46px 0 12px;
  font-size: clamp(26px, 4vw, 34px);
}

h3 {
  margin: 27px 0 8px;
  font-size: 20px;
}

p,
li,
td,
th {
  font-size: 16px;
}

.legal-intro {
  max-width: 780px;
  margin: 0;
  color: var(--muted);
  font-size: 18px;
}

.last-updated {
  display: inline-flex;
  margin-top: 18px;
  padding: 7px 11px;
  border: 1px solid var(--border);
  border-radius: 999px;
  background: var(--surface);
  color: var(--muted);
  font-size: 13px;
}

.draft-warning {
  margin: 30px 0;
  padding: 18px 20px;
  border: 1px solid rgba(244, 221, 160, .42);
  border-radius: 17px;
  background: var(--warning-bg);
  color: var(--warning);
}

.draft-warning strong {
  display: block;
  margin-bottom: 5px;
  color: var(--gold);
}

.summary-card,
.content-card,
.contact-card {
  margin-top: 24px;
  padding: 22px;
  border: 1px solid var(--border);
  border-radius: 20px;
  background: var(--surface);
}

.summary-card ul,
.content-card ul,
.content-card ol {
  margin: 10px 0 0;
  padding-left: 22px;
}

.summary-card li + li,
.content-card li + li,
.legal-section li + li {
  margin-top: 7px;
}

.legal-section p,
.legal-section ul,
.legal-section ol {
  color: var(--muted);
}

.legal-section strong {
  color: var(--white);
}

.placeholder {
  display: inline;
  padding: 2px 5px;
  border-radius: 5px;
  background: rgba(244, 221, 160, .14);
  color: var(--gold);
  font-weight: 800;
}

.identity-grid,
.contact-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px;
  margin-top: 18px;
}

.identity-item,
.contact-card {
  min-width: 0;
  padding: 16px;
  border: 1px solid var(--border);
  border-radius: 15px;
  background: rgba(255, 255, 255, .03);
}

.identity-item span,
.contact-card span {
  display: block;
  margin-bottom: 4px;
  color: var(--green-light);
  font-size: 12px;
  font-weight: 900;
  letter-spacing: .8px;
  text-transform: uppercase;
}

.responsive-table {
  margin-top: 18px;
  overflow-x: auto;
  border: 1px solid var(--border);
  border-radius: 16px;
}

table {
  width: 100%;
  min-width: 680px;
  border-collapse: collapse;
  background: rgba(255, 255, 255, .025);
}

th,
td {
  padding: 14px 15px;
  border-bottom: 1px solid var(--border);
  color: var(--muted);
  text-align: left;
  vertical-align: top;
}

th {
  background: rgba(64, 145, 108, .11);
  color: var(--white);
  font-size: 14px;
}

tr:last-child td {
  border-bottom: 0;
}

.note {
  margin-top: 20px;
  padding: 16px 18px;
  border-left: 4px solid var(--green);
  border-radius: 0 13px 13px 0;
  background: rgba(64, 145, 108, .08);
  color: var(--muted);
}

.danger-note {
  border-left-color: #d88d62;
  background: rgba(216, 141, 98, .08);
}

.legal-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-top: 24px;
}

.legal-button {
  display: inline-flex;
  min-height: 50px;
  align-items: center;
  justify-content: center;
  padding: 11px 18px;
  border: 1px solid var(--border);
  border-radius: 14px;
  background: var(--surface-strong);
  color: var(--white);
  cursor: pointer;
  font: inherit;
  font-weight: 900;
  text-decoration: none;
}

.legal-button-primary {
  border-color: transparent;
  background: linear-gradient(135deg, #2d6a4f, #40916c);
}

.contact-form {
  position: relative;
  margin-top: 22px;
  padding: clamp(20px, 4vw, 30px);
  border: 1px solid var(--border);
  border-radius: 22px;
  background: var(--surface);
}

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

.form-field {
  display: grid;
  gap: 7px;
  margin-bottom: 18px;
}

.form-field label {
  color: var(--white);
  font-size: 15px;
  font-weight: 800;
}

.form-field input,
.form-field select,
.form-field textarea {
  width: 100%;
  min-height: 50px;
  padding: 12px 13px;
  border: 1px solid rgba(255, 255, 255, .18);
  border-radius: 12px;
  background: #0b1711;
  color: var(--white);
  font: inherit;
  line-height: 1.4;
  color-scheme: dark;
}

.form-field textarea {
  min-height: 180px;
  resize: vertical;
}

.form-field input:focus,
.form-field select:focus,
.form-field textarea:focus {
  border-color: var(--green-light);
  outline: 3px solid rgba(116, 198, 157, .2);
  outline-offset: 1px;
}

.form-field small,
.field-optional,
.form-note {
  color: var(--muted);
  font-size: 13px;
}

.field-optional {
  font-weight: 400;
}

.form-consent {
  display: flex;
  align-items: flex-start;
  gap: 11px;
  margin: 4px 0 22px;
  color: var(--muted);
  cursor: pointer;
  font-size: 14px;
}

.form-consent input {
  width: 20px;
  height: 20px;
  flex: 0 0 auto;
  margin-top: 3px;
  accent-color: var(--green);
}

.form-submit {
  width: 100%;
}

.form-note {
  margin: 12px 0 0;
  text-align: center;
}

.form-status {
  margin: 28px 0;
  padding: 18px 20px;
  border: 1px solid var(--border);
  border-radius: 17px;
}

.form-status strong,
.form-status span {
  display: block;
}

.form-status ul {
  margin: 10px 0 0;
  padding-left: 20px;
}

.form-status-success {
  border-color: rgba(116, 198, 157, .45);
  background: rgba(64, 145, 108, .12);
  color: var(--green-pale);
}

.form-status-error {
  border-color: rgba(216, 141, 98, .48);
  background: rgba(216, 141, 98, .1);
  color: #ffd7c2;
}

.form-honeypot {
  position: absolute !important;
  width: 1px !important;
  height: 1px !important;
  overflow: hidden !important;
  clip: rect(0 0 0 0) !important;
  clip-path: inset(50%) !important;
  white-space: nowrap !important;
}

.legal-footer {
  padding: 32px 20px 42px;
  border-top: 1px solid var(--border);
  background: #04110d;
  color: var(--muted);
  font-size: 13px;
  text-align: center;
}

.legal-footer-links {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 8px 18px;
  width: min(980px, 100%);
  margin: 0 auto 15px;
}

.legal-footer-links a,
.legal-footer-links button {
  color: var(--green-light);
  font: inherit;
  text-decoration: underline;
  text-underline-offset: 3px;
}

.legal-footer p {
  max-width: 900px;
  margin: 0 auto;
}

@media (max-width: 700px) {
  .legal-header-inner,
  .legal-shell {
    width: min(100% - 24px, 920px);
  }

  .legal-header-inner {
    min-height: 64px;
  }

  .legal-logo {
    font-size: 19px;
  }

  .back-home {
    min-height: 44px;
    padding: 7px 11px;
    font-size: 13px;
  }

  .legal-shell {
    padding-top: 43px;
  }

  .identity-grid,
  .contact-grid,
  .form-grid {
    grid-template-columns: 1fr;
  }

  .summary-card,
  .content-card {
    padding: 18px;
  }
}

@media (prefers-reduced-motion: reduce) {
  html {
    scroll-behavior: auto;
  }
}
