html, body {
  margin: 0;
  min-height: 100%;
  background: #E5E7EB;
  color: #333333;
  font-family: "Segoe UI", system-ui, sans-serif;
  overflow-x: clip;
}

body {
  min-height: 100vh;
  display: flex;
  flex-direction: column;
}

header {
  position: sticky;
  top: 0;
  z-index: 2;
  display: flex;
  align-items: center;
  gap: 36px;
  width: 100%;
  box-sizing: border-box;
  padding: 24px 28px;
  background: #E5E7EB;
  overflow: clip;
}

.logo {
  width: 260px;
  height: auto;
  display: block;
}

header nav {
  flex: 1;
  display: flex;
  align-items: stretch;
  flex-wrap: wrap;
  min-width: 0;
  gap: 16px;
}

header nav a {
  flex: 1 1 0;
  display: flex;
  align-items: center;
  justify-content: center;
  min-width: max-content;
  color: #333333;
  background: transparent;
  border: none;
  border-radius: 16px;
  text-decoration: none;
  text-align: center;
  position: relative;
  font-size: 30px;
  font-weight: 600;
  letter-spacing: 0.01em;
  padding: 20px 16px;
  transition: transform 0.15s ease;
}

header nav a:hover,
header nav a:focus-visible {
  background: transparent;
  transform: scale(1.25);
  z-index: 1;
  outline: none;
}

header nav a[aria-current="page"] {
  opacity: 1;
  color: #1155CC;
  font-weight: 700;
  background: transparent;
  box-shadow: none;
}

main {
  flex: 1;
  width: 100%;
  max-width: none;
  box-sizing: border-box;
  padding: 48px 28px;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
}

.site-footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding: 14px 28px;
  border-top: 1px solid #333333;
  font-size: 14px;
}

.site-footer p {
  margin: 0;
  font-size: 14px;
}

.footer-links {
  display: flex;
  align-items: center;
  gap: 20px;
}

.site-footer a,
.site-footer .cookie-reopen {
  position: static;
  color: #333333;
  background: transparent;
  border: none;
  border-radius: 0;
  padding: 0;
  font: inherit;
  font-size: 14px;
  font-weight: 600;
  text-decoration: none;
  cursor: pointer;
}

.site-footer a:hover,
.site-footer a:focus-visible,
.site-footer a[aria-current="page"],
.site-footer .cookie-reopen:hover,
.site-footer .cookie-reopen:focus-visible {
  color: #1155CC;
  border-color: transparent;
  outline: none;
}

h1 {
  margin: 0 0 12px;
  max-width: 18em;
  font-size: 36px;
  font-weight: 700;
}

p {
  margin: 0;
  font-size: 18px;
  line-height: 1.5;
}

main p + p {
  margin-top: 12px;
}

.contact-form {
  position: relative;
  width: min(480px, 100%);
  display: flex;
  flex-direction: column;
  gap: 16px;
  text-align: left;
}

.contact-form label {
  display: flex;
  flex-direction: column;
  gap: 6px;
  font-size: 16px;
  font-weight: 600;
}

.contact-form input,
.contact-form textarea {
  width: 100%;
  box-sizing: border-box;
  padding: 10px 12px;
  border: 1px solid #333333;
  border-radius: 8px;
  background: transparent;
  color: #333333;
  font: inherit;
  font-weight: 400;
  font-size: 16px;
}

.contact-form textarea {
  resize: vertical;
}

.contact-form input:focus-visible,
.contact-form textarea:focus-visible {
  outline: 2px solid #1155CC;
  border-color: #1155CC;
}

.char-count {
  font-size: 14px;
  font-weight: 400;
  text-align: right;
}

.contact-form button {
  font: inherit;
  font-size: 16px;
  font-weight: 600;
  color: #333333;
  background: transparent;
  border: 1px solid #333333;
  border-radius: 8px;
  padding: 10px 16px;
  cursor: pointer;
}

.contact-form button:hover,
.contact-form button:focus-visible {
  color: #1155CC;
  border-color: #1155CC;
  outline: none;
}

.contact-form button:disabled {
  opacity: 0.6;
  cursor: wait;
}

.form-status {
  position: absolute;
  left: 0;
  right: 0;
  top: calc(100% + 16px);
  margin: 0;
  font-size: 16px;
  font-weight: 600;
  line-height: 1.5;
  color: #1155CC;
  text-align: center;
}

.cookie-layer {
  position: fixed;
  z-index: 30;
  inset: 0;
  display: flex;
  align-items: flex-end;
  justify-content: center;
  padding: 16px;
  background: rgba(51, 51, 51, 0.35);
}

.cookie-layer[hidden] {
  display: none;
}

.cookie-banner {
  pointer-events: auto;
  width: min(720px, 100%);
  box-sizing: border-box;
  padding: 20px;
  background: #E5E7EB;
  color: #333333;
  border: 1px solid #333333;
  border-radius: 16px;
}

.cookie-banner h2 {
  margin: 0 0 8px;
  font-size: 22px;
}

.cookie-banner p {
  margin: 0 0 16px;
  font-size: 16px;
}

.cookie-actions,
.cookie-settings {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.cookie-settings {
  margin-top: 16px;
}

.cookie-settings[hidden] {
  display: none;
}

.cookie-btn {
  flex: 1 1 160px;
  font: inherit;
  font-size: 16px;
  font-weight: 600;
  color: #333333;
  background: transparent;
  border: 1px solid #333333;
  border-radius: 8px;
  padding: 10px 12px;
  cursor: pointer;
}

.cookie-btn:hover,
.cookie-btn:focus-visible {
  color: #1155CC;
  border-color: #1155CC;
  outline: none;
}

.cookie-switch {
  position: relative;
  flex: 1 1 100%;
  display: flex;
  align-items: center;
  gap: 12px;
  font-size: 16px;
}

.cookie-switch input {
  position: absolute;
  width: 1px;
  height: 1px;
  margin: 0;
  opacity: 0;
}

.cookie-track {
  flex: 0 0 auto;
  width: 48px;
  height: 28px;
  border: 2px solid #333333;
  border-radius: 14px;
  background: transparent;
  position: relative;
  cursor: pointer;
}

.cookie-track::after {
  content: "";
  position: absolute;
  top: 2px;
  left: 2px;
  width: 20px;
  height: 20px;
  border-radius: 50%;
  background: #333333;
}

.cookie-switch input:checked + .cookie-track {
  background: #1155CC;
  border-color: #1155CC;
}

.cookie-switch input:checked + .cookie-track::after {
  left: 22px;
  background: #E5E7EB;
}

.cookie-switch input:disabled + .cookie-track {
  cursor: not-allowed;
}

.cookie-switch input:focus-visible + .cookie-track {
  outline: 2px solid #1155CC;
  outline-offset: 2px;
}

.cookie-switch span {
  display: flex;
  flex-direction: column;
  gap: 2px;
}

.cookie-switch small {
  font-size: 14px;
}

.cookie-reopen {
  position: fixed;
  z-index: 4;
  left: 16px;
  bottom: 16px;
  font: inherit;
  font-size: 14px;
  font-weight: 600;
  color: #333333;
  background: #E5E7EB;
  border: 1px solid #333333;
  border-radius: 8px;
  padding: 8px 12px;
  cursor: pointer;
}

.cookie-reopen:hover,
.cookie-reopen:focus-visible {
  color: #1155CC;
  border-color: #1155CC;
  outline: none;
}

.nav-toggle {
  display: none;
}

html[data-device="mobile"] body {
  padding-left: env(safe-area-inset-left);
  padding-right: env(safe-area-inset-right);
}

html[data-device="mobile"] header {
  flex-wrap: wrap;
  gap: 12px;
  padding: 16px;
  overflow: visible;
}

html[data-device="mobile"] .logo {
  width: min(168px, 46vw);
}

html[data-device="mobile"] .nav-toggle {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  margin-left: auto;
  flex: 0 0 auto;
  font: inherit;
  font-size: 16px;
  font-weight: 600;
  color: #333333;
  background: transparent;
  border: 1px solid #333333;
  border-radius: 8px;
  padding: 12px 16px;
  cursor: pointer;
}

html[data-device="mobile"] .nav-toggle[aria-expanded="true"],
html[data-device="mobile"] .nav-toggle:focus-visible {
  color: #1155CC;
  border-color: #1155CC;
  outline: none;
}

html[data-device="mobile"] header nav {
  display: none;
  position: absolute;
  top: 100%;
  left: 0;
  right: 0;
  flex-direction: column;
  gap: 4px;
  padding: 4px 16px 16px;
  background: #E5E7EB;
  border-bottom: 1px solid #333333;
  z-index: 3;
}

html[data-device="mobile"] header.nav-open nav {
  display: flex;
}

html[data-device="mobile"] header nav a {
  flex: none;
  width: 100%;
  min-width: 0;
  font-size: 18px;
  padding: 14px 12px;
  border-radius: 12px;
}

html[data-device="mobile"] header nav a:hover,
html[data-device="mobile"] header nav a:focus-visible {
  transform: none;
  color: #1155CC;
}

html[data-device="mobile"] main {
  padding: 32px 16px 48px;
}

html[data-device="mobile"] h1 {
  font-size: 28px;
}

html[data-device="mobile"] p {
  font-size: 16px;
}

html[data-device="mobile"] .contact-form {
  margin-bottom: 36px;
}

html[data-device="mobile"] .site-footer {
  flex-wrap: wrap;
  align-items: flex-start;
  gap: 8px 16px;
  padding: 12px 16px calc(12px + env(safe-area-inset-bottom));
}

html[data-device="mobile"] .cookie-layer {
  padding: 12px;
  padding-bottom: calc(12px + env(safe-area-inset-bottom));
}

html[data-device="mobile"] .cookie-banner {
  max-height: calc(100vh - 24px);
  overflow: auto;
  padding: 16px;
}

html[data-device="mobile"] .cookie-banner h2 {
  font-size: 20px;
}

html[data-device="mobile"] .cookie-banner p {
  font-size: 15px;
}

html[data-device="mobile"] .cookie-btn {
  flex-basis: 100%;
}
