:root {
  --brand-red: #c1121f;
  --brand-red-dark: #8f0f18;
  --brand-blue: #1d3557;
  --brand-light: #f8f9fb;
  --brand-white: #ffffff;
  --text: #1f2937;
  --muted: #6b7280;
  --border: #e5e7eb;
  --shadow: 0 10px 30px rgba(0, 0, 0, 0.08);
  --radius: 18px;
  --max-width: 1120px;
  --header-height: 88px;
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  font-family: Arial, Helvetica, sans-serif;
  color: var(--text);
  background: linear-gradient(180deg, #f7f8fb 0%, #eef2f7 100%);
  min-height: 100vh;
}

body.menu-open {
  overflow: hidden;
}

a {
  color: inherit;
  text-decoration: none;
}

html,
body {
  height: 100%;
}

body {
  display: flex;
  flex-direction: column;
}

.site-header,
.page-hero,
.site-footer {
  flex-shrink: 0;
}

.page-hero.compact {
  padding: 1.25rem 0 0.75rem;
}


.form-shell.form-shell-map {
  flex: 1;
  display: flex;
  min-height: 0;
  padding-bottom: 2rem;
}

.form-frame-wrap.map-frame-wrap {
  position: relative;
  flex: 1;
  display: flex;
  min-height: calc(100vh - var(--header-height) - 190px);
}

.map-frame {
  width: 100%;
  height: 100%;
  min-height: 500px;
  border: 0;
  display: block;
  background: white;
}

.map-fullscreen-link {
  position: absolute;
  right: 1rem;
  bottom: 1rem;
  z-index: 2;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0.75rem 1rem;
  border-radius: 12px;
  background: rgba(255, 255, 255, 0.95);
  color: var(--brand-blue);
  font-weight: 700;
  box-shadow: 0 8px 20px rgba(0, 0, 0, 0.12);
}

.map-fullscreen-link:hover {
  transform: translateY(-1px);
}

@media (max-width: 640px) {
  .form-frame-wrap.map-frame-wrap {
    min-height: calc(100vh - var(--header-height) - 150px);
  }

  .map-fullscreen-link {
    right: 0.75rem;
    bottom: 0.75rem;
    padding: 0.7rem 0.9rem;
    font-size: 0.9rem;
  }
}


img {
  max-width: 100%;
  display: block;
}

.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  background: rgba(255, 255, 255, 0.96);
  backdrop-filter: blur(8px);
  border-bottom: 1px solid rgba(229, 231, 235, 0.9);
  transform: translateY(0);
  transition: transform 0.28s ease, box-shadow 0.2s ease;
}

.site-header.header-hidden {
  transform: translateY(calc(-100% - 6px));
}

.site-header.header-scrolled {
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.08);
}

.header-inner,
.footer-inner,
.main-content,
.hero-inner,
.cards-grid,
.form-shell {
  width: min(calc(100% - 2rem), var(--max-width));
  margin: 0 auto;
}

.header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  padding: 1rem 0;
  min-height: var(--header-height);
}

.brand {
  display: flex;
  align-items: center;
  gap: 0.9rem;
  min-width: 0;
}

.brand-badge {
  width: 48px;
  height: 48px;
  border-radius: 14px;
  display: grid;
  place-items: center;
  background: linear-gradient(135deg, var(--brand-red), var(--brand-red-dark));
  color: white;
  font-weight: 700;
  font-size: 1rem;
  box-shadow: var(--shadow);
  flex-shrink: 0;
}

.brand-text strong {
  display: block;
  font-size: 1rem;
  line-height: 1.2;
}

.brand-text span {
  display: block;
  font-size: 0.9rem;
  color: var(--muted);
  margin-top: 0.15rem;
}

.nav-toggle {
  display: none;
  width: 48px;
  height: 48px;
  border: 1px solid var(--border);
  border-radius: 12px;
  background: white;
  cursor: pointer;
  padding: 0;
  align-items: center;
  justify-content: center;
  flex-direction: column;
  gap: 5px;
  box-shadow: var(--shadow);
}

.nav-toggle span {
  width: 20px;
  height: 2px;
  background: var(--brand-blue);
  border-radius: 2px;
  transition: transform 0.2s ease, opacity 0.2s ease;
}

.nav-toggle[aria-expanded="true"] span:nth-child(1) {
  transform: translateY(7px) rotate(45deg);
}

.nav-toggle[aria-expanded="true"] span:nth-child(2) {
  opacity: 0;
}

.nav-toggle[aria-expanded="true"] span:nth-child(3) {
  transform: translateY(-7px) rotate(-45deg);
}

.main-nav {
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem;
}

.main-nav a {
  padding: 0.75rem 1rem;
  border-radius: 999px;
  font-weight: 600;
  color: var(--brand-blue);
  transition: all 0.2s ease;
}

.main-nav a:hover,
.main-nav a.active {
  background: rgba(193, 18, 31, 0.08);
  color: var(--brand-red);
}

.hero {
  padding: 4.5rem 0 2rem;
}

.hero-inner {
  display: grid;
  grid-template-columns: 1.2fr 0.8fr;
  gap: 2rem;
  align-items: center;
}

.hero-copy h1 {
  margin: 0 0 1rem;
  font-size: clamp(2rem, 5vw, 3.5rem);
  line-height: 1.05;
  letter-spacing: -0.02em;
}

.hero-copy p {
  margin: 0 0 1.5rem;
  font-size: 1.05rem;
  line-height: 1.7;
  color: var(--muted);
  max-width: 62ch;
}

.hero-tag {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.45rem 0.85rem;
  border-radius: 999px;
  background: rgba(29, 53, 87, 0.08);
  color: var(--brand-blue);
  font-size: 0.9rem;
  font-weight: 700;
  margin-bottom: 1rem;
}

.hero-panel {
  background: linear-gradient(160deg, var(--brand-white), #f3f6fb);
  border: 1px solid var(--border);
  border-radius: 24px;
  padding: 1.5rem;
  box-shadow: var(--shadow);
}

.hero-panel h2 {
  margin-top: 0;
  font-size: 1.2rem;
}

.hero-panel ul {
  margin: 1rem 0 0;
  padding-left: 1.1rem;
  color: var(--muted);
  line-height: 1.7;
}

.main-content {
  padding: 1rem 0 4rem;
}

.section-title {
  margin: 0 0 0.5rem;
  font-size: 1.8rem;
}

.section-copy {
  margin: 0 0 2rem;
  color: var(--muted);
  line-height: 1.7;
}

.cards-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 1.25rem;
}

.card {
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  background: var(--brand-white);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 1.4rem;
  box-shadow: var(--shadow);
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.card:hover {
  transform: translateY(-3px);
  box-shadow: 0 16px 35px rgba(0, 0, 0, 0.1);
}

.card-icon {
  width: 52px;
  height: 52px;
  display: grid;
  place-items: center;
  border-radius: 14px;
  background: rgba(193, 18, 31, 0.08);
  color: var(--brand-red);
  font-size: 1.3rem;
  font-weight: 700;
}

.card h3 {
  margin: 1rem 0 0.6rem;
  font-size: 1.2rem;
}

.card p {
  margin: 0 0 1.2rem;
  color: var(--muted);
  line-height: 1.65;
  flex-grow: 1;
}

.button,
.button-secondary {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  min-height: 46px;
  padding: 0.8rem 1.1rem;
  border-radius: 12px;
  font-weight: 700;
  transition: transform 0.2s ease, opacity 0.2s ease, background 0.2s ease;
}

.button {
  background: linear-gradient(135deg, var(--brand-red), var(--brand-red-dark));
  color: white;
}

.button-secondary {
  background: rgba(29, 53, 87, 0.08);
  color: var(--brand-blue);
}

.button:hover,
.button-secondary:hover {
  transform: translateY(-1px);
}

.page-hero {
  padding: 3rem 0 1.25rem;
}

.page-hero h1 {
  margin: 0 0 0.75rem;
  font-size: clamp(1.8rem, 4vw, 2.75rem);
}

.page-hero p {
  margin: 1.7;
  color: var(--muted);
  line-height: 1.7;
}

.form-shell {
  padding-bottom: 4rem;
}

.form-frame-wrap {
  background: var(--brand-white);
  border: 1px solid var(--border);
  border-radius: 24px;
  box-shadow: var(--shadow);
  overflow: hidden;
}

.form-toolbar {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 1rem;
  padding: 1rem 1rem 0;
  flex-wrap: wrap;
}

.form-note {
  font-size: 0.92rem;
  color: var(--muted);
}

.form-frame {
  width: 100%;
  height: 1100px;
  border: 0;
  display: block;
  background: white;
}

.site-footer {
  border-top: 1px solid var(--border);
  background: rgba(255, 255, 255, 0.88);
}

.footer-inner {
  display: flex;
  justify-content: space-between;
  gap: 1rem;
  padding: 1.25rem 0;
  flex-wrap: wrap;
  color: var(--muted);
  font-size: 0.95rem;
}

.footer-inner strong {
  color: var(--brand-blue);
}

@media (max-width: 900px) {
  .hero-inner,
  .cards-grid {
    grid-template-columns: 1fr;
  }

  .header-inner {
    align-items: center;
    flex-wrap: wrap;
  }

  .nav-toggle {
    display: inline-flex;
    margin-left: auto;
  }

  .main-nav {
    display: none;
    width: 100%;
    flex-direction: column;
    gap: 0.5rem;
    padding-top: 0.75rem;
  }

  .main-nav.is-open {
    display: flex;
  }

  .main-nav a {
    width: 100%;
    text-align: center;
    border-radius: 14px;
    background: rgba(29, 53, 87, 0.04);
  }
}

@media (max-width: 640px) {
  .hero {
    padding-top: 3rem;
  }

  .brand-text strong {
    font-size: 0.95rem;
  }

  .brand-text span {
    font-size: 0.82rem;
  }

  .form-frame {
    height: 1200px;
  }

  .footer-inner {
    flex-direction: column;
  }
}