:root {
  color-scheme: light;
  --ink: #1d2520;
  --muted: #5d6a62;
  --line: #d8ded8;
  --paper: #fbfcf9;
  --surface: #ffffff;
  --green: #2f6846;
  --green-dark: #214b32;
  --red: #d94141;
  --red-dark: #b72f2f;
  --gold: #b0852e;
  --sky: #d8e9ee;
  --shadow: 0 18px 45px rgba(29, 37, 32, 0.08);
}

* {
  box-sizing: border-box;
}

body {
  margin: 0;
  font-family: "Segoe UI", Arial, sans-serif;
  color: var(--ink);
  background: var(--paper);
  line-height: 1.6;
  overflow-x: hidden;
}

a {
  color: inherit;
}

.site-header {
  position: sticky;
  top: 0;
  z-index: 10;
  border-bottom: 1px solid var(--line);
  background: rgba(251, 252, 249, 0.96);
  backdrop-filter: blur(12px);
}

.nav {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  max-width: 1120px;
  margin: 0 auto;
  padding: 14px 24px;
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  min-width: 240px;
  max-width: 100%;
  text-decoration: none;
}

.brand-mark {
  display: grid;
  place-items: center;
  flex: 0 0 44px;
  width: 44px;
  height: 44px;
  border-radius: 8px;
  color: #ffffff;
  background: var(--green);
  font-weight: 800;
  letter-spacing: 0;
}

.brand strong,
.brand small {
  display: block;
  overflow-wrap: anywhere;
}

.brand strong {
  font-size: 0.98rem;
  line-height: 1.2;
}

.brand small {
  color: var(--muted);
  font-size: 0.78rem;
  line-height: 1.3;
}

.nav-links {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-wrap: wrap;
}

.nav-links a {
  border-radius: 8px;
  padding: 9px 12px;
  color: var(--muted);
  font-size: 0.95rem;
  font-weight: 650;
  text-decoration: none;
}

.nav-links a:hover,
.nav-links a[aria-current="page"] {
  color: var(--green-dark);
  background: #edf4ee;
}

.hero {
  min-height: 56vh;
  display: flex;
  align-items: end;
  background:
    linear-gradient(90deg, rgba(18, 44, 29, 0.9), rgba(18, 44, 29, 0.5)),
    url("https://images.unsplash.com/photo-1500382017468-9049fed747ef?auto=format&fit=crop&w=1800&q=80");
  background-position: center;
  background-size: cover;
}

.hero-content,
.page-title {
  width: min(1120px, calc(100% - 48px));
  margin: 0 auto;
}

.hero-content {
  max-width: 900px;
  margin-bottom: 56px;
  color: #ffffff;
}

.eyebrow {
  margin: 0 0 12px;
  color: var(--gold);
  font-size: 0.82rem;
  font-weight: 800;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.hero .eyebrow {
  color: #f2c66a;
}

h1,
h2 {
  margin: 0;
  line-height: 1.15;
}

h1 {
  max-width: 980px;
  font-size: clamp(2.1rem, 5vw, 4.7rem);
  letter-spacing: 0;
  overflow-wrap: anywhere;
}

h2 {
  font-size: 1.45rem;
}

.hero p:last-child,
.page-title p {
  max-width: 740px;
  margin: 20px 0 0;
  font-size: 1.12rem;
}

.page-title {
  padding: 58px 0 28px;
}

.page-title h1 {
  font-size: clamp(2rem, 4vw, 3.4rem);
}

.page-toc {
  max-width: 740px;
  margin-top: 28px;
  padding: 20px 22px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--surface);
}

.page-toc h2 {
  font-size: 1.15rem;
}

.page-toc ul {
  margin: 14px 0 0;
  padding-left: 22px;
}

.page-toc li + li {
  margin-top: 8px;
}

.page-toc a {
  color: var(--green-dark);
  font-weight: 750;
}

.document-comment {
  max-width: 860px;
  margin: 24px 0px 6px 30px;
  
  border: 1px solid #c9d8cd;
  border-left: 5px solid var(--green);
  border-radius: 8px;
  padding: 20px 22px;
  background: #f1f7f2;
}

.document-comment h4 {
  margin: 0 0 10px;
  color: var(--green-dark);
  font-size: 1rem;
  line-height: 1.25;
}

.document-comment p {
  margin: 0;
  color: #314137;
}

.activity-list {
  display: grid;
  grid-template-columns: minmax(140px, 190px) minmax(0, 1fr);
  gap: 12px 18px;
  max-width: 900px;
  margin: 24px 0 0;
}

.activity-list dt,
.activity-list dd {
  margin: 0;
}

.activity-list dt {
  align-self: start;
  border: 1px solid #c9d8cd;
  border-radius: 8px;
  padding: 8px 12px;
  color: var(--green-dark);
  background: #f1f7f2;
  font-size: 0.92rem;
  font-weight: 800;
}

.activity-list dd {
  position: relative;
  border: 1px solid var(--line);
  border-radius: 8px;
  padding: 12px 16px 12px 36px;
  background: var(--surface);
  box-shadow: 0 8px 22px rgba(29, 37, 32, 0.05);
}

.activity-list dd::before {
  content: "";
  position: absolute;
  left: 16px;
  top: 1.35em;
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--green);
}

.content-band {
  border-top: 1px solid var(--line);
  background: linear-gradient(180deg, #ffffff 0%, var(--paper) 100%);
}

.content-grid {
  display: grid;
  grid-template-columns: minmax(0, 0.9fr) minmax(0, 1.1fr);
  gap: 28px;
  width: min(1120px, calc(100% - 48px));
  margin: 0 auto;
  padding: 42px 0 68px;
}

.document-section,
.placeholder-panel,
.application-form {
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--surface);
  box-shadow: var(--shadow);
}

.document-section,
.placeholder-panel {
  padding: 28px;
}

.document-section ol,
.document-section ul {
  padding-left: 22px;
}

.document-section li + li {
  margin-top: 12px;
}

.purpose-list li::marker {
  color: var(--green);
}

.placeholder-panel,
.application-form {
  width: min(780px, calc(100% - 48px));
  margin: 0 auto;
}

.placeholder-panel {
  margin-top: 42px;
  margin-bottom: 68px;
}

.placeholder-panel p {
  color: var(--muted);
}


.section {
  width: min(1120px, calc(100% - 48px));
  margin: 0 auto;
  padding: 42px 0 68px;
}

.map-section {
  width: min(1120px, calc(100% - 48px));
  margin: 0 auto;
  padding: 42px 0 68px;
}

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

.switch-control {
  display: flex;
  align-items: center;
  gap: 10px;
  color: var(--green-dark);
  font-size: 0.95rem;
  font-weight: 750;
  white-space: nowrap;
  cursor: pointer;
}

.switch-control input {
  position: absolute;
  width: 1px;
  height: 1px;
  opacity: 0;
}

.switch-track {
  position: relative;
  flex: 0 0 46px;
  width: 46px;
  height: 26px;
  border: 1px solid #b9c6bd;
  border-radius: 999px;
  background: #dfe7e2;
  transition: background 160ms ease, border-color 160ms ease;
}

.switch-track::after {
  content: "";
  position: absolute;
  left: 3px;
  top: 3px;
  width: 18px;
  height: 18px;
  border-radius: 50%;
  background: #ffffff;
  box-shadow: 0 1px 4px rgba(29, 37, 32, 0.24);
  transition: transform 160ms ease;
}

.switch-control input:checked + .switch-track {
  border-color: var(--red-dark);
  background: var(--red);
}

.switch-control input:checked + .switch-track::after {
  transform: translateX(20px);
}

.switch-control input:focus-visible + .switch-track {
  outline: 3px solid rgba(47, 104, 70, 0.2);
  outline-offset: 2px;
}

.map-frame {
  position: relative;
  height: min(68vh, 680px);
  min-height: 560px;
  overflow: hidden;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--sky);
  box-shadow: var(--shadow);
}

.route-overlay {
  position: absolute;
  left: 0;
  top: 0;
  max-width: none;
  transform-origin: 0 0;
  user-select: none;
  will-change: transform;
  pointer-events: none;
}

.map-note {
  max-width: 780px;
  margin: 16px 0 0;
  color: var(--muted);
  font-size: 0.95rem;
}

.application-form {
  display: grid;
  gap: 18px;
  padding: 28px;
  margin-top: 42px;
  margin-bottom: 68px;
}

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

.form-row {
  display: grid;
  gap: 7px;
}

.form-extra-field {
  position: absolute;
  left: -10000px;
  width: 1px;
  height: 1px;
  overflow: hidden;
}

label {
  color: var(--green-dark);
  font-weight: 700;
}

input,
textarea {
  width: 100%;
  border: 1px solid #cbd4cc;
  border-radius: 8px;
  padding: 12px 13px;
  color: var(--ink);
  background: #ffffff;
  font: inherit;
}

input:focus,
textarea:focus {
  outline: 3px solid rgba(47, 104, 70, 0.18);
  border-color: var(--green);
}

textarea {
  resize: vertical;
}

.checkbox-row {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  color: var(--ink);
  font-weight: 500;
}

.checkbox-row input {
  width: 18px;
  height: 18px;
  margin-top: 4px;
  accent-color: var(--green);
}

.form-message {
  border-radius: 8px;
  padding: 14px 16px;
}

.form-message ul {
  margin: 8px 0 0;
  padding-left: 20px;
}

.form-message-success {
  border: 1px solid #a9d7b4;
  color: #205b33;
  background: #edf8ef;
}

.form-message-error {
  border: 1px solid #edb7b7;
  color: #8e2727;
  background: #fff0f0;
}

.button {
  justify-self: start;
  border: 0;
  border-radius: 8px;
  padding: 12px 18px;
  color: #ffffff;
  background: var(--green);
  font: inherit;
  font-weight: 800;
  cursor: pointer;
}

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

.button-secondary {
  color: var(--green-dark);
  background: #edf4ee;
}

.button-secondary:hover {
  color: #ffffff;
  background: var(--green-dark);
}

.admin-panel {
  max-width: 760px;
  border: 1px solid var(--line);
  border-radius: 8px;
  padding: 24px;
  background: var(--surface);
  box-shadow: var(--shadow);
}

.admin-panel h2 {
  margin-bottom: 12px;
}

.admin-panel code {
  overflow-wrap: anywhere;
}

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

.admin-header p {
  margin: 8px 0 0;
  color: var(--muted);
}

.requests-table-wrap {
  overflow-x: auto;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--surface);
  box-shadow: var(--shadow);
}

.requests-table {
  width: 100%;
  min-width: 860px;
  border-collapse: collapse;
  font-size: 0.94rem;
}

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

.requests-table th {
  color: var(--green-dark);
  background: #edf4ee;
  font-size: 0.82rem;
  font-weight: 800;
  text-transform: uppercase;
}

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

.requests-table td {
  overflow-wrap: anywhere;
}

.site-footer {
  border-top: 1px solid var(--line);
  padding: 22px 24px;
  color: var(--muted);
  background: #eef5f0;
  text-align: center;
}

.site-footer p {
  margin: 0;
}

@media (max-width: 820px) {
  .nav {
    align-items: flex-start;
    flex-direction: column;
    gap: 12px;
  }

  .nav-links {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    width: 100%;
    gap: 6px;
  }

  .nav-links a {
    display: grid;
    min-height: 42px;
    place-items: center;
    padding: 8px 7px;
    font-size: 0.9rem;
    line-height: 1.2;
    text-align: center;
  }

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

  .map-toolbar {
    align-items: flex-start;
    flex-direction: column;
  }

  .switch-control {
    width: 100%;
    justify-content: space-between;
    white-space: normal;
  }

  .activity-list {
    grid-template-columns: 1fr;
    gap: 8px;
  }

  .activity-list dd {
    margin-bottom: 10px;
  }
}

@media (max-width: 560px) {
  .nav,
  .hero-content,
  .page-title,
  .content-grid,
  .map-section,
  .placeholder-panel,
  .application-form {
    width: calc(100% - 32px);
  }

  .nav {
    padding-inline: 16px;
  }

  .brand {
    min-width: 0;
  }

  .brand-mark {
    flex-basis: 40px;
    width: 40px;
    height: 40px;
  }

  .brand strong {
    font-size: 0.92rem;
  }

  .brand small {
    font-size: 0.72rem;
  }

  .nav-links {
    grid-template-columns: 1fr;
  }

  .hero {
    min-height: auto;
    padding: 80px 0 34px;
  }

  .hero-content {
    margin-bottom: 0;
  }

  h1 {
    font-size: 2rem;
  }

  h2 {
    font-size: 1.25rem;
  }

  .hero p:last-child,
  .page-title p {
    font-size: 1rem;
  }

  .page-title {
    padding: 38px 0 24px;
  }

  .map-frame {
    height: 68vh;
    min-height: 360px;
    border-radius: 0;
  }

  .document-section,
  .placeholder-panel,
  .application-form {
    padding: 22px;
  }

  .application-form {
    margin-top: 28px;
    margin-bottom: 44px;
  }

  .button {
    width: 100%;
  }
}

@media (max-width: 380px) {
  .brand {
    align-items: flex-start;
  }

  .brand-mark {
    flex-basis: 36px;
    width: 36px;
    height: 36px;
    font-size: 0.85rem;
  }

  h1 {
    font-size: 1.75rem;
  }
}
