:root {
  --brand-navy: #1c3f60;
  --brand-coral: #d66a57;
  --brand-sage: #8aa897;
  --brand-cream: #f9f5ef;
  --brand-sand: #f1e6d6;
  --brand-light: #ffffff;
  --text-body: #2a2a2a;
  --text-muted: #5a5a5a;
  --shadow-soft: 0 18px 45px rgba(24, 32, 56, 0.12);
  --radius-lg: 20px;
  --radius-md: 14px;
  --radius-sm: 8px;
}

* {
  box-sizing: border-box;
}

body {
  margin: 0;
  font-family: "Work Sans", "Segoe UI", sans-serif;
  background: var(--brand-cream);
  color: var(--text-body);
  line-height: 1.7;
}

main {
  max-width: 1180px;
  margin: 0 auto;
  padding: 0 1.5rem 5rem;
}

img {
  max-width: 100%;
  display: block;
  border-radius: var(--radius-md);
}

a {
  color: var(--brand-navy);
  text-decoration: none;
}

a:hover {
  text-decoration: underline;
}

code {
  background: rgba(28, 63, 96, 0.08);
  padding: 0.25rem 0.4rem;
  border-radius: var(--radius-sm);
  font-size: 0.9rem;
  word-break: break-word;
}

button {
  font-family: inherit;
}

header.hero {
  background: linear-gradient(135deg, var(--brand-cream) 0%, #ffffff 60%);
  padding: 3.5rem 1.5rem 3rem;
  border-bottom: 1px solid rgba(28, 63, 96, 0.08);
  position: relative;
  z-index: 1;
}

.hero-inner {
  max-width: 1180px;
  margin: 0 auto;
  display: flex;
  gap: 2.5rem;
  align-items: center;
  flex-wrap: wrap;
}

.hero-copy {
  flex: 1 1 380px;
}

.hero-copy h1 {
  font-family: "Playfair Display", "Times New Roman", serif;
  font-size: clamp(2.2rem, 4vw, 3.1rem);
  line-height: 1.2;
  margin: 1rem 0 1.25rem;
  color: var(--brand-navy);
}

.hero-copy p {
  font-size: 1.05rem;
  color: var(--text-muted);
  margin-bottom: 1.75rem;
}

.eyebrow {
  text-transform: uppercase;
  letter-spacing: 0.2em;
  font-size: 0.75rem;
  color: var(--brand-coral);
  font-weight: 600;
}

.hero-actions {
  display: flex;
  gap: 0.75rem;
  flex-wrap: wrap;
}

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.35rem;
  padding: 0.85rem 1.45rem;
  border-radius: 999px;
  font-weight: 600;
  font-size: 0.95rem;
  cursor: pointer;
  border: none;
  transition: transform 0.2s ease, box-shadow 0.2s ease, background 0.2s ease;
}

.btn:hover,
.btn:focus {
  transform: translateY(-1px);
  text-decoration: none;
}

.btn-primary {
  background: var(--brand-navy);
  color: #ffffff;
  box-shadow: var(--shadow-soft);
}

.btn-primary:hover,
.btn-primary:focus {
  background: #c45c47;
}

.btn-outline {
  background: var(--brand-light);
  color: var(--brand-navy);
  border: 1px solid rgba(28, 63, 96, 0.18);
}
.btn-reset {
  background: var(--brand-coral);
  color: var(--brand-light);
  border: 1px solid rgba(28, 63, 96, 0.18);
}

.btn-outline:hover,
.btn-outline:focus {
  background: rgba(28, 63, 96, 0.06);
}

.btn-small {
  padding: 0.55rem 1.05rem;
  font-size: 0.85rem;
}

.hero-gallery {
  flex: 1 1 320px;
  position: relative;
  min-width: 280px;
}

.hero-gallery img:first-child {
  box-shadow: var(--shadow-soft);
}

.hero-card {
  position: absolute;
  left: -12%;
  bottom: -14%;
  background: var(--brand-light);
  border-radius: var(--radius-lg);
  padding: 1.3rem 1.5rem;
  width: min(280px, 70%);
  box-shadow: 0 16px 40px rgba(28, 63, 96, 0.15);
}

.hero-card h3 {
  margin: 0 0 0.4rem;
  font-size: 1.15rem;
  color: var(--brand-navy);
}

.hero-card ul {
  list-style: none;
  padding: 0;
  margin: 0;
  font-size: 0.95rem;
  color: var(--text-muted);
}

.hero-card li + li {
  margin-top: 0.35rem;
}

.section {
  margin-top: 1.5rem;
}

.section--compact {
  margin-top: 0;
}

#further-form-element:empty {
  margin: 0;
}

.prelude {
  background: var(--brand-cream);
  padding: 0 0 1rem;
}

.prelude-inner {
  max-width: 1180px;
  margin: 0 auto;
  padding: 0 1.5rem;
  display: grid;
  gap: 2.5rem;
}

.section-heading {
  max-width: 720px;
  margin-bottom: 2.25rem;
}

.section-heading h2 {
  font-family: "Playfair Display", "Times New Roman", serif;
  font-size: clamp(1.9rem, 3.2vw, 2.5rem);
  margin: 0 0 0.8rem;
  color: var(--brand-navy);
}

.section-heading p {
  margin: 0;
  color: var(--text-muted);
  font-size: 1.05rem;
}

.config-card {
  background: var(--brand-light);
  border-radius: var(--radius-lg);
  padding: 2.25rem;
  box-shadow: var(--shadow-soft);
}

#community-config {
  display: block;
}

.config-grid {
  display: grid;
  gap: 2.5rem;
  grid-template-columns: 1fr 1fr 75px;
}

.config-field {
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
}

.config-field label {
  display: block;
  font-weight: 600;
  margin-bottom: 0.6rem;
  color: var(--brand-navy);
}

.field-help {
  margin: 0 0 1rem;
  color: var(--text-muted);
  font-size: 0.95rem;
}

.field-input {
  display: flex;
  gap: 0.75rem;
  flex-wrap: wrap;
  align-items: center;
}

.field-input input {
  flex: 1 1 auto;
  border: 1px solid rgba(28, 63, 96, 0.18);
  border-radius: 999px;
  padding: 0.7rem 1.15rem;
  font-size: 0.95rem;
  background: var(--brand-cream);
}

.field-input input:focus {
  outline: 2px solid rgba(214, 106, 87, 0.45);
  background: #ffffff;
}

.config-actions {
  display: flex;
  justify-content: flex-end;
  margin-top: 1.5rem;
}

.highlight-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
  gap: 1.75rem;
}

.highlight-card {
  background: var(--brand-light);
  border-radius: var(--radius-lg);
  padding: 1.8rem;
  box-shadow: 0 12px 30px rgba(28, 63, 96, 0.08);
  border: 1px solid rgba(28, 63, 96, 0.07);
}

.highlight-icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 46px;
  height: 46px;
  border-radius: 50%;
  background: var(--brand-sand);
  color: var(--brand-navy);
  font-size: 1.2rem;
  font-weight: 600;
  margin-bottom: 1rem;
}

.highlight-card h3 {
  margin: 0 0 0.7rem;
  color: var(--brand-navy);
  font-size: 1.15rem;
}

.flag-card {
  background: var(--brand-light);
  border-radius: var(--radius-lg);
  padding: 1.9rem;
  box-shadow: 0 14px 30px rgba(28, 63, 96, 0.08);
  border: 1px solid rgba(28, 63, 96, 0.06);
}

.flag-list {
  list-style: none;
  padding: 0;
  margin: 0;
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
}

.flag-item {
  display: flex;
  justify-content: space-between;
  gap: 1.25rem;
  align-items: center;
  border: 1px solid rgba(28, 63, 96, 0.12);
  border-radius: var(--radius-md);
  padding: 0.85rem 1rem;
  background: rgba(241, 230, 214, 0.45);
}

.flag-key {
  font-weight: 600;
  color: var(--brand-navy);
  word-break: break-word;
  margin-right: auto;
}

.flag-value {
  font-family: "Work Sans", "Segoe UI", sans-serif;
  font-size: 0.95rem;
  color: var(--text-muted);
  background: #ffffff;
  padding: 0.35rem 0.6rem;
  border-radius: var(--radius-sm);
  border: 1px solid rgba(214, 106, 87, 0.3);
  word-break: break-all;
  max-width: 60%;
  text-align: right;
}

.flag-remove {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 30px;
  height: 30px;
  border-radius: 50%;
  border: 1px solid rgba(214, 106, 87, 0.4);
  background: rgba(214, 106, 87, 0.1);
  color: var(--brand-coral);
  font-size: 1rem;
  line-height: 1;
  cursor: pointer;
  transition: background 0.2s ease, transform 0.2s ease;
}

.flag-remove:hover,
.flag-remove:focus {
  background: rgba(214, 106, 87, 0.25);
  transform: scale(1.05);
}

.no-flags {
  margin: 0;
  color: var(--text-muted);
}

.flag-note {
  margin-top: 1rem;
  font-size: 0.9rem;
  color: var(--text-muted);
}

.flag-presets {
  margin-top: 1.5rem;
  border-radius: var(--radius-lg);
  background: #ffffff;
  border: 1px solid rgba(28, 63, 96, 0.08);
  box-shadow: 0 8px 20px rgba(28, 63, 96, 0.06);
  padding: 1.1rem 1.4rem;
}

.flag-presets summary {
  cursor: pointer;
  font-weight: 600;
  color: var(--brand-navy);
  font-size: 0.95rem;
  list-style: none;
}

.flag-presets[open] summary {
  margin-bottom: 1rem;
}

.flag-presets summary::-webkit-details-marker {
  display: none;
}

.flag-presets summary::after {
  content: "▶";
  font-size: 0.75rem;
  margin-left: 0.6rem;
  transition: transform 0.2s ease;
  display: inline-block;
}

.flag-presets[open] summary::after {
  transform: rotate(90deg);
}

.flag-preset-list {
  list-style: none;
  padding: 0;
  margin: 0;
  display: flex;
  flex-direction: column;
  gap: 0.9rem;
}

.flag-preset-item {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  border: 1px solid rgba(28, 63, 96, 0.1);
  border-radius: var(--radius-md);
  padding: 0.9rem 1rem;
  background: rgba(241, 230, 214, 0.35);
}

.flag-preset-info {
  display: flex;
  flex-direction: column;
  gap: 0.35rem;
}

.flag-preset-label {
  font-weight: 600;
  color: var(--brand-navy);
  font-size: 0.95rem;
}

.flag-preset-code {
  font-size: 0.85rem;
  color: var(--text-muted);
  background: rgba(28, 63, 96, 0.05);
  border-radius: var(--radius-sm);
  padding: 0.35rem 0.5rem;
  word-break: break-all;
}

.flag-preset-actions {
  display: flex;
  gap: 0.6rem;
}

.flag-copy {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0.35rem;
  border-radius: 50%;
  border: 1px solid rgba(28, 63, 96, 0.18);
  background: #ffffff;
  cursor: pointer;
  transition: background 0.2s ease;
  width: 36px;
  height: 36px;
}

.flag-copy:hover,
.flag-copy:focus {
  background: rgba(28, 63, 96, 0.08);
}

.flag-copy.copied {
  background: rgba(214, 106, 87, 0.12);
  border-color: rgba(214, 106, 87, 0.45);
}

.card-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  gap: 2rem;
}

.community-card {
  background: var(--brand-light);
  border-radius: var(--radius-lg);
  overflow: hidden;
  box-shadow: 0 20px 45px rgba(28, 63, 96, 0.12);
  display: flex;
  flex-direction: column;
}

.community-card-image {
  width: 100%;
  padding-top: 60%;
  background-size: cover;
  background-position: center;
  background-repeat: no-repeat;
}

.community-card-body {
  padding: 1.8rem;
  display: flex;
  flex-direction: column;
  gap: 0.85rem;
}

.community-card h3 {
  margin: 0;
  color: var(--brand-navy);
  font-size: 1.35rem;
}

.community-card .price {
  font-weight: 600;
  color: var(--brand-coral);
}

.community-card .address {
  color: var(--text-muted);
  margin: 0;
}

.care-list {
  list-style: none;
  padding: 0;
  margin: 0;
  color: var(--text-muted);
  font-size: 0.95rem;
}

.care-list li + li {
  margin-top: 0.2rem;
}

.community-actions {
  display: flex;
  gap: 0.75rem;
  flex-wrap: wrap;
  margin-top: 1.1rem;
}

.community-actions .btn {
  padding: 0.65rem 1.15rem;
  font-size: 0.9rem;
}

.testimonial-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
  gap: 1.75rem;
}

.testimonial-card {
  background: var(--brand-light);
  border-radius: var(--radius-lg);
  padding: 1.8rem;
  border: 1px solid rgba(28, 63, 96, 0.08);
  box-shadow: 0 12px 30px rgba(28, 63, 96, 0.08);
}

.testimonial-card blockquote {
  margin: 0 0 1.2rem;
  font-style: italic;
  color: var(--text-muted);
}

.testimonial-card cite {
  font-weight: 600;
  color: var(--brand-navy);
  font-style: normal;
}

.embedded-card {
  background: var(--brand-light);
  border-radius: var(--radius-lg);
  padding: 2rem;
  box-shadow: inset 0 0 0 2px rgba(28, 63, 96, 0.07);
  display: flex;
  align-items: center;
  justify-content: center;
}

#further-embedded-vsa {
  width: 100%;
  min-height: 280px;
}

.tip-card {
  margin-top: 1.5rem;
  background: rgba(214, 106, 87, 0.08);
  border-left: 4px solid var(--brand-coral);
  border-radius: var(--radius-md);
  padding: 1.2rem 1.5rem;
  color: var(--text-body);
}

.tip-card h3 {
  margin: 0 0 0.6rem;
  font-size: 1rem;
  color: var(--brand-navy);
}

.teaser-card {
  background: var(--brand-light);
  border-radius: var(--radius-lg);
  padding: 2rem;
  box-shadow: var(--shadow-soft);
}

further-teaser {
  display: block;
  margin: 1rem auto 0;
  max-width: 420px;
}

.teaser-note {
  margin-top: 1.5rem;
  color: var(--text-muted);
  font-size: 0.95rem;
  text-align: center;
}

.phone-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
  gap: 1.5rem;
}

.phone-card {
  background: var(--brand-light);
  border-radius: var(--radius-lg);
  padding: 1.7rem;
  border: 1px solid rgba(28, 63, 96, 0.07);
  box-shadow: 0 12px 28px rgba(28, 63, 96, 0.06);
}

.phone-card h3 {
  margin-top: 0;
  color: var(--brand-navy);
}

.phone-card .phone-number-class {
  font-weight: 600;
}

.legacy-form-card {
  background: var(--brand-light);
  border-radius: var(--radius-lg);
  padding: 2rem 2.3rem;
  box-shadow: var(--shadow-soft);
}

.legacy-form-note {
  margin-top: 0.35rem;
  margin-bottom: 1.2rem;
  color: var(--text-muted);
  font-size: 0.95rem;
}

.legacy-form-actions {
  display: flex;
  gap: 0.75rem;
  flex-wrap: wrap;
  margin-bottom: 1.5rem;
}

#test-form table {
  width: 100%;
  border-spacing: 0 0.85rem;
}

#test-form td {
  vertical-align: middle;
  color: var(--text-muted);
  font-size: 0.95rem;
}

#test-form label {
  font-weight: 600;
  color: var(--brand-navy);
}

#test-form input,
#test-form button {
  font-size: 0.95rem;
}

#test-form #first_name,
#test-form #last_name,
#test-form input[type="text"],
#test-form input[type="email"],
#test-form input[type="tel"],
#test-form input[type="number"] {
  width: 100%;
  padding: 0.65rem 0.9rem;
  border-radius: var(--radius-sm);
  border: 1px solid rgba(28, 63, 96, 0.2);
  background: var(--brand-cream);
}

#test-form #first_name:focus,
#test-form #last_name:focus,
#test-form input[type="text"]:focus,
#test-form input[type="email"]:focus,
#test-form input[type="tel"]:focus,
#test-form input[type="number"]:focus {
  outline: 2px solid rgba(214, 106, 87, 0.4);
  background: #ffffff;
}

#test-form button[type="submit"] {
  background: var(--brand-navy);
  color: #ffffff;
  border: none;
  border-radius: 999px;
  padding: 0.75rem 1.6rem;
  cursor: pointer;
}

#test-form button[type="submit"]:hover,
#test-form button[type="submit"]:focus {
  background: #15304d;
}

.site-footer {
  background: var(--brand-navy);
  color: #ffffff;
  padding: 2.2rem 1.5rem;
  text-align: center;
  font-size: 0.9rem;
}

@media (max-width: 900px) {
  .hero-gallery img:last-child {
    position: static;
    width: 60%;
    margin: 1rem auto 0;
  }

  .hero-card {
    position: static;
    width: 100%;
    margin-top: 1.5rem;
  }

  .hero-gallery {
    order: -1;
  }

  .hero-inner {
    flex-direction: column;
    text-align: center;
  }

  .hero-actions {
    justify-content: center;
  }

  .hero-gallery {
    width: 100%;
  }

  .prelude-inner {
    padding: 0 1rem;
    gap: 1.5rem;
  }

  .config-card {
    padding: 1.5rem;
  }

  .config-grid {
    grid-template-columns: 1fr;
    gap: 1.25rem;
  }

  .config-actions {
    justify-content: flex-start;
  }

  .flag-preset-item {
    flex-direction: column;
    align-items: flex-start;
  }

  .flag-preset-actions {
    width: 100%;
    justify-content: flex-start;
  }

  .card-grid,
  .testimonial-grid,
  .phone-grid {
    grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
  }

  .community-card-body {
    padding: 1.5rem;
  }
}

@media (max-width: 600px) {
  header.hero {
    padding: 3rem 1rem 2.5rem;
  }

  main {
    padding: 0 1rem 4rem;
  }

  .config-card {
    padding: 1.8rem;
  }

  .global-actions {
    justify-content: center;
  }

  .hero-copy h1 {
    font-size: clamp(2rem, 7vw, 2.4rem);
  }

  .hero-copy p {
    font-size: 0.95rem;
  }

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

  .flag-card {
    padding: 1.5rem;
  }

  .flag-value {
    max-width: 100%;
  }

  .flag-preset-code {
    font-size: 0.8rem;
  }

  .community-card-body {
    gap: 0.65rem;
  }

  .community-card h3 {
    font-size: 1.2rem;
  }

  .prelude {
    padding: 0;
  }

  .teaser-card,
  .embedded-card,
  .legacy-form-card {
    padding: 1.5rem;
  }

  .hero-gallery img:first-child {
    width: 100%;
  }
}

@media (max-width: 480px) {
  .btn,
  .btn-small {
    width: 100%;
    justify-content: center;
  }

  .flag-item,
  .flag-preset-item {
    padding: 0.75rem;
  }

  .field-input {
    flex-direction: column;
    align-items: stretch;
  }

  .field-input input {
    width: 100%;
  }

  .community-card-image {
    padding-top: 56%;
  }

  .hero-actions a {
    width: 100%;
  }
}

@media (max-width: 640px) {
  .flag-item {
    flex-direction: column;
    align-items: flex-start;
    gap: 0.6rem;
  }

  .flag-value {
    max-width: 100%;
    text-align: left;
  }

  .flag-preset-item {
    flex-direction: column;
    align-items: flex-start;
  }

  .flag-preset-actions {
    width: 100%;
    justify-content: flex-start;
  }
}
