:root {
  --bg: #f7f8fa;
  --card: #ffffff;
  --text: #1a1a1a;
  --muted: #6b7280;
  --accent: #0f4c81;
  --accent-light: #e6eef6;
  --border: #d1d5db;
  --radius: 12px;
  --gap: 1.25rem;
}

* {
  box-sizing: border-box;
}

body {
  margin: 0;
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
  background: var(--bg);
  color: var(--text);
  line-height: 1.5;
}

.container {
  max-width: 720px;
  margin: 0 auto;
  padding: 1rem;
}

.center {
  text-align: center;
  padding-top: 4rem;
}

.page-header {
  text-align: center;
  margin-bottom: 1.5rem;
}

.logo-title {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 1rem;
  margin-bottom: 0.5rem;
}

.logo {
  height: 60px;
  width: auto;
  flex-shrink: 0;
}

.title-text {
  text-align: left;
}

.page-header h1 {
  font-size: 1.5rem;
  margin: 0 0 0.25rem;
  color: var(--accent);
}

.page-header h2 {
  font-size: 1.25rem;
  margin: 0 0 0.5rem;
  font-weight: 600;
}

.page-header p {
  margin: 0;
  color: var(--muted);
  font-size: 0.95rem;
}

.notice {
  background: var(--accent-light);
  border-left: 4px solid var(--accent);
  padding: 0.75rem 1rem;
  border-radius: var(--radius);
  margin-bottom: 1.5rem;
}

.card-list {
  display: grid;
  gap: var(--gap);
  margin-top: 1.5rem;
}

.card {
  display: block;
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 1.25rem;
  text-decoration: none;
  color: inherit;
  transition: box-shadow 0.15s ease, transform 0.15s ease;
}

.card:hover {
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.08);
  transform: translateY(-2px);
}

.card h2 {
  margin: 0 0 0.25rem;
  color: var(--accent);
  font-size: 1.15rem;
}

.card p {
  margin: 0;
  color: var(--muted);
  font-size: 0.9rem;
}

form {
  display: flex;
  flex-direction: column;
  gap: 1.5rem;
}

fieldset {
  border: none;
  background: var(--card);
  border-radius: var(--radius);
  padding: 1.25rem;
  margin: 0;
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.04);
}

legend,
.block-title {
  display: block;
  width: 100%;
  font-weight: 700;
  font-size: 1.05rem;
  color: var(--accent);
  padding: 0 0 1rem 0;
  margin: 0;
}

.question {
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
  margin-bottom: 1.25rem;
  scroll-margin-top: 120px;
}

.question:last-child {
  margin-bottom: 0;
}

.csi-row {
  scroll-margin-top: 120px;
}

.question-text {
  font-weight: 600;
  margin: 0;
}

.question:has(input[required]) .question-text::after,
.question:has(input[type="checkbox"][name$="[]"]) .question-text::after {
  content: ' *';
  color: #b42318;
  font-weight: 700;
}

.csi-row:has(input[required]) .csi-param::after {
  content: ' *';
  color: #b42318;
  font-weight: 700;
}

.hint,
.hint-inline {
  color: var(--muted);
  font-size: 0.9rem;
}

.hint-inline {
  font-weight: 400;
}

label {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  cursor: pointer;
  font-size: 0.95rem;
}

input[type="text"],
input[type="tel"],
textarea {
  width: 100%;
  padding: 0.65rem 0.75rem;
  border: 1px solid var(--border);
  border-radius: 8px;
  font-size: 1rem;
  font-family: inherit;
}

input[type="text"]:focus,
input[type="tel"]:focus,
textarea:focus {
  outline: none;
  border-color: var(--accent);
  box-shadow: 0 0 0 3px var(--accent-light);
}

.scale {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
}

.scale label {
  flex: 1 1 auto;
  justify-content: center;
  min-width: 2.5rem;
  padding: 0.5rem;
  border: 1px solid var(--border);
  border-radius: 8px;
  background: var(--bg);
  font-weight: 600;
}

.scale input {
  position: absolute;
  opacity: 0;
  pointer-events: none;
}

.scale label:has(input:checked) {
  background: var(--accent);
  color: #fff;
  border-color: var(--accent);
}

.csi-table {
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
}

.csi-row {
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
  padding: 0.75rem 0;
  border-bottom: 1px solid var(--border);
}

.csi-row:last-child {
  border-bottom: none;
}

.csi-param {
  font-size: 0.95rem;
}

.contacts {
  display: grid;
  gap: 1rem;
}

.contacts label {
  flex-direction: column;
  align-items: stretch;
  gap: 0.35rem;
}

.form-status {
  min-height: 1.5rem;
  color: #b42318;
  font-weight: 600;
  opacity: 0;
  transition: opacity 0.2s ease;
}

.form-status.visible {
  opacity: 1;
}

.submit-btn {
  display: inline-block;
  background: var(--accent);
  color: #fff;
  border: none;
  border-radius: var(--radius);
  padding: 0.9rem 1.5rem;
  font-size: 1.05rem;
  font-weight: 600;
  cursor: pointer;
  text-align: center;
  text-decoration: none;
}

.submit-btn:hover {
  background: #0d3d68;
}

@media (min-width: 768px) {
  .container {
    padding: 1.5rem;
  }

  .page-header h1 {
    font-size: 1.75rem;
  }

  .csi-row {
    flex-direction: row;
    align-items: center;
    justify-content: space-between;
  }

  .csi-param {
    flex: 1;
  }

  .contacts {
    grid-template-columns: 1fr 1fr;
  }
}

@media (min-width: 1024px) {
  .container {
    max-width: 800px;
  }

  .card-list {
    grid-template-columns: repeat(3, 1fr);
  }
}
