:root {
  --bg: #f4efe8;
  --bg-alt: #e8efe9;
  --surface: rgba(255, 250, 244, 0.92);
  --ink: #10252d;
  --muted: #55656b;
  --line: rgba(16, 37, 45, 0.12);
  --accent: #d1652f;
  --accent-deep: #8d3813;
  --shadow: 0 18px 50px rgba(16, 37, 45, 0.08);
  --radius: 24px;
  --shell: min(1180px, calc(100% - 2rem));
}

* { box-sizing: border-box; }
[hidden] { display: none !important; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  font-family: "Barlow", sans-serif;
  color: var(--ink);
  background:
    radial-gradient(circle at top left, rgba(209, 101, 47, 0.18), transparent 32%),
    linear-gradient(135deg, var(--bg) 0%, var(--bg-alt) 100%);
}

a { color: inherit; text-decoration: none; }
img { max-width: 100%; display: block; }
button, input, textarea, select { font: inherit; }

.skip-link {
  position: absolute;
  left: 1rem;
  top: -3rem;
  padding: 0.75rem 1rem;
  border-radius: 999px;
  background: var(--accent);
  color: #fff;
  z-index: 10;
}

.skip-link:focus { top: 1rem; }

:focus-visible {
  outline: 3px solid var(--accent);
  outline-offset: 3px;
}

.site-shell { width: var(--shell); margin: 0 auto; }

.site-header {
  position: sticky;
  top: 0;
  z-index: 5;
  backdrop-filter: blur(12px);
  background: rgba(244, 239, 232, 0.78);
  border-bottom: 1px solid var(--line);
}

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

.brand {
  display: inline-flex;
  gap: 0.9rem;
  align-items: center;
}

.brand-mark {
  display: grid;
  place-items: center;
  width: 2.75rem;
  height: 2.75rem;
  border-radius: 18px;
  background: var(--ink);
  color: #fff;
  font-family: "Sora", sans-serif;
  font-weight: 800;
}

.brand-copy {
  display: grid;
  gap: 0.1rem;
}

.brand-copy strong {
  font-family: "Sora", sans-serif;
  font-size: 1rem;
}

.brand-copy span:last-child {
  color: var(--muted);
  font-size: 0.92rem;
}

.menu-button {
  display: none;
  border: 1px solid var(--line);
  background: #fff;
  border-radius: 999px;
  padding: 0.7rem 1rem;
}

.primary-nav {
  display: flex;
  align-items: center;
  gap: 0.9rem;
}

.primary-nav a,
.button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 999px;
  padding: 0.85rem 1.15rem;
}

.primary-nav a { color: var(--muted); }
.primary-nav a[aria-current="page"] { color: var(--ink); font-weight: 700; }

.language-toggle {
  border: 1px solid var(--line);
  border-radius: 999px;
  padding: 0.68rem 0.9rem;
  background: rgba(255, 255, 255, 0.66);
  color: var(--ink);
  cursor: pointer;
  font-weight: 700;
}
.language-toggle:hover { background: #fff; }
.standalone-language-toggle { margin-bottom: 2rem; }

.button {
  border: 0;
  background: var(--accent);
  color: #fff;
  font-weight: 700;
}
.button:disabled { cursor: not-allowed; opacity: 0.45; }

.button-small { padding: 0.7rem 1rem; }

.button-secondary {
  background: transparent;
  color: var(--ink);
  border: 1px solid var(--line);
}

.hero,
.section { padding: 4rem 0; }
.hero-landscape {
  min-height: min(720px, calc(100vh - 76px));
  display: grid;
  align-items: center;
  background: url("./assets/welsh-landscape-hero-v5.webp") center / cover no-repeat;
}
.section-alt { background: rgba(255,255,255,0.35); border-top: 1px solid var(--line); border-bottom: 1px solid var(--line); }

.hero-grid,
.split-grid,
.footer-grid {
  display: grid;
  gap: 1.5rem;
}

.hero-grid { grid-template-columns: 1.5fr 0.9fr; align-items: start; }
.hero-landscape .hero-grid {
  grid-template-columns: minmax(0, 1fr) minmax(460px, 1.1fr);
  align-items: center;
  gap: clamp(2rem, 5vw, 4.5rem);
}
.hero-copy {
  padding: clamp(1.5rem, 3vw, 2.75rem);
  border: 1px solid rgba(255, 255, 255, 0.62);
  border-radius: var(--radius);
  background: rgba(255, 250, 244, 0.8);
  box-shadow: var(--shadow);
  backdrop-filter: blur(8px);
}
.hero-landscape .hero-copy {
  grid-column: 2;
  width: 100%;
  max-width: 580px;
  justify-self: end;
}
.hero-copy .lead { color: #294149; }
.split-grid { grid-template-columns: 1fr 1fr; }
.services-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.footer-grid { grid-template-columns: repeat(3, minmax(0, 1fr)); align-items: start; }

.eyebrow {
  margin: 0 0 0.8rem;
  text-transform: uppercase;
  letter-spacing: 0.16em;
  color: var(--accent-deep);
  font-weight: 700;
  font-size: 0.78rem;
}

h1, h2, h3 {
  margin: 0;
  font-family: "Sora", sans-serif;
  line-height: 1.05;
}

h1 { font-size: clamp(2.5rem, 5vw, 4.8rem); max-width: 13ch; }
h2 { font-size: clamp(1.8rem, 3vw, 2.6rem); }
h3 { font-size: 1.2rem; }

.lead {
  color: var(--muted);
  max-width: 54ch;
  font-size: 1.08rem;
  line-height: 1.6;
}

.button-row,
.trust-list { display: flex; gap: 1rem; flex-wrap: wrap; }

.trust-list {
  padding: 0;
  margin: 1.25rem 0 0;
  list-style: none;
}

.trust-list li,
.hero-card,
.info-card,
.panel {
  border: 1px solid var(--line);
  background: var(--surface);
  box-shadow: var(--shadow);
}

.trust-list li {
  padding: 0.65rem 0.9rem;
  border-radius: 999px;
}

.hero-card,
.panel,
.info-card {
  border-radius: var(--radius);
}

.hero-card,
.panel { padding: 1.5rem; }

.quote-shell { max-width: 920px; }
.quote-intro { max-width: 720px; margin-bottom: 2rem; }
.quote-form {
  padding: clamp(1.25rem, 4vw, 3rem);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--surface);
  box-shadow: var(--shadow);
}
.quote-progress {
  display: flex;
  gap: 0.75rem;
  padding: 0;
  margin: 0 0 2.5rem;
  list-style: none;
  counter-reset: none;
}
.quote-progress li {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  flex: 1;
  color: var(--muted);
  font-size: 0.82rem;
  font-weight: 700;
}
.quote-progress span {
  display: grid;
  place-items: center;
  flex: 0 0 auto;
  width: 1.8rem;
  height: 1.8rem;
  border: 1px solid var(--line);
  border-radius: 50%;
  background: #fff;
}
.quote-progress .is-current,
.quote-progress .is-complete { color: var(--ink); }
.quote-progress .is-current span,
.quote-progress .is-complete span { border-color: var(--accent); background: var(--accent); color: #fff; }
.quote-step h2 { margin-bottom: 0.65rem; }
.step-count { margin: 0 0 0.6rem; color: var(--accent-deep); font-weight: 700; }
.step-help { margin: 0 0 1.75rem; color: var(--muted); line-height: 1.55; }
.choice-fieldset { margin: 0 0 1.5rem; padding: 0; border: 0; }
.choice-fieldset legend { margin-bottom: 0.8rem; font-weight: 700; }
.choice-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 0.8rem; }
.choice-grid.compact { grid-template-columns: repeat(4, minmax(0, 1fr)); }
.choice-card {
  display: grid;
  gap: 0.35rem;
  min-height: 4.65rem;
  padding: 1rem;
  border: 1px solid var(--line);
  border-radius: 16px;
  background: rgba(255,255,255,0.6);
  cursor: pointer;
  font-weight: 700;
}
.choice-card:has(input:checked) { border-color: var(--accent); background: rgba(209, 101, 47, 0.1); }
.choice-card input { accent-color: var(--accent); }
.choice-card small { color: var(--muted); font-size: 0.82rem; font-weight: 400; line-height: 1.35; }
.quote-fields { display: grid; gap: 1rem; }
.quote-fields-two { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.quote-fields label,
.quote-contact > label { display: grid; gap: 0.45rem; font-weight: 600; }
.quote-fields input,
.quote-fields select,
.quote-contact > label input { width: 100%; padding: 0.9rem 1rem; border: 1px solid var(--line); border-radius: 14px; background: #fff; }
.quote-result { margin-bottom: 1.5rem; padding: 1.5rem; border: 1px solid rgba(209, 101, 47, 0.3); border-radius: 18px; background: rgba(209, 101, 47, 0.08); }
.quote-result p { margin: 0; line-height: 1.55; }
.quote-result .eyebrow { margin-bottom: 0.35rem; }
.quote-result-main { margin-bottom: 0.45rem !important; font-family: "Sora", sans-serif; font-size: clamp(1.35rem, 3vw, 2rem); font-weight: 700; }
.quote-price { display: grid; gap: 0.2rem; margin-top: 1.25rem; padding-top: 1.25rem; border-top: 1px solid rgba(209, 101, 47, 0.28); }
.quote-price span { color: var(--muted); font-size: 0.9rem; font-weight: 700; }
.quote-price strong { font-family: "Sora", sans-serif; font-size: clamp(1.5rem, 3vw, 2.2rem); }
.quote-price small { color: var(--muted); line-height: 1.35; }
.quote-disclaimer { margin-top: 1rem !important; color: var(--muted); font-size: 0.9rem; }
.quote-contact { display: grid; gap: 1rem; }
.quote-contact h3 { margin-top: 0.25rem; }
.quote-contact p { margin: -0.5rem 0 0; color: var(--muted); line-height: 1.5; }
.optional { color: var(--muted); font-weight: 400; }
.quote-actions { display: flex; justify-content: space-between; gap: 1rem; margin-top: 2rem; }
.quote-actions .button:last-child { margin-left: auto; }
.quote-error { min-height: 1.4em; margin: 0.8rem 0 0; color: #8d3813; font-weight: 700; }

.blog-index-hero { padding-bottom: 2rem; }
.blog-heading { max-width: 760px; }
.blog-grid { display: grid; gap: 1.5rem; }
.blog-card {
  display: grid;
  grid-template-columns: minmax(280px, 0.9fr) minmax(0, 1.1fr);
  overflow: hidden;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--surface);
  box-shadow: var(--shadow);
}
.blog-card-image { min-height: 320px; overflow: hidden; }
.blog-card-image img { width: 100%; height: 100%; object-fit: cover; transition: transform 300ms ease; }
.blog-card-image:hover img { transform: scale(1.025); }
.blog-card-copy { display: flex; flex-direction: column; justify-content: center; padding: clamp(1.5rem, 4vw, 3rem); }
.blog-card-copy h3 { margin-top: 0.8rem; font-size: clamp(1.5rem, 3vw, 2.2rem); }
.blog-card-copy p { color: var(--muted); line-height: 1.65; }
.article-meta { display: flex; flex-wrap: wrap; gap: 0.55rem 1rem; color: var(--muted); font-size: 0.9rem; }
.article-meta span + span,
.article-meta time + span { position: relative; }
.article-meta span + span::before,
.article-meta time + span::before { position: absolute; left: -0.62rem; content: "•"; color: var(--accent); }
.article-header { padding-bottom: 2.5rem; }
.article-heading { max-width: 920px; }
.article-heading h1 { max-width: 16ch; }
.article-heading .article-meta { margin-top: 1.5rem; }
.breadcrumbs { display: flex; flex-wrap: wrap; gap: 0.5rem; margin-bottom: 2rem; color: var(--muted); font-size: 0.9rem; }
.breadcrumbs a:hover { color: var(--accent-deep); }
.article-hero { overflow: hidden; max-height: 620px; margin-bottom: 4rem; border-radius: var(--radius); }
.article-hero img { width: 100%; height: clamp(320px, 50vw, 620px); object-fit: cover; }
.article-layout {
  display: grid;
  grid-template-columns: 210px minmax(0, 720px);
  justify-content: center;
  gap: clamp(2rem, 6vw, 5rem);
  align-items: start;
  padding-bottom: 5rem;
}
.article-aside {
  position: sticky;
  top: 7rem;
  display: grid;
  gap: 0.8rem;
  padding-left: 1rem;
  border-left: 1px solid var(--line);
}
.article-aside a { color: var(--muted); line-height: 1.35; }
.article-aside a:hover { color: var(--accent-deep); }
.article-body { min-width: 0; }
.article-body p,
.article-body li { color: var(--muted); font-size: 1.05rem; line-height: 1.75; }
.article-body h2 { margin-top: 2.75rem; scroll-margin-top: 7rem; }
.article-body h3 { margin-top: 1.8rem; font-size: 1.25rem; }
.article-intro { margin-top: 0; color: var(--ink) !important; font-size: 1.22rem !important; }
.article-callout {
  margin: 2rem 0;
  padding: 1.5rem;
  border: 1px solid rgba(209, 101, 47, 0.25);
  border-radius: 18px;
  background: rgba(209, 101, 47, 0.08);
}
.article-callout .eyebrow { margin-bottom: 0.6rem; }
.article-callout ul { margin: 0; padding-left: 1.2rem; }
.article-cta {
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 1.5rem;
  align-items: center;
  margin-top: 3.5rem;
  padding: clamp(1.5rem, 4vw, 2.5rem);
  border-radius: var(--radius);
  background: var(--ink);
  color: #fff;
}
.article-cta h2 { margin-top: 0; }
.article-cta p:not(.eyebrow) { margin-bottom: 0; color: rgba(255,255,255,0.72); }
.article-cta .eyebrow { color: #efaf83; }

.stat-list {
  margin: 1rem 0 0;
  display: grid;
  gap: 1rem;
}

.stat-list div { display: grid; gap: 0.25rem; }
.stat-list dt { color: var(--muted); font-weight: 700; }

.section-heading { margin-bottom: 1.5rem; }
.section-action { display: flex; justify-content: center; margin-top: 1.75rem; }

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

.info-card {
  padding: 1.3rem;
}

.info-card p,
.rich-copy p,
.site-footer p {
  color: var(--muted);
  line-height: 1.7;
}

.text-link {
  display: inline-flex;
  margin-top: 0.8rem;
  color: var(--accent-deep);
  font-weight: 700;
}

.callback-layout { align-items: start; }
.callback-intro { position: sticky; top: 7rem; }
.callback-points { display: grid; gap: 0.75rem; margin: 2rem 0 0; padding: 0; list-style: none; }
.callback-points li { display: flex; gap: 0.65rem; align-items: center; color: var(--muted); font-weight: 700; }
.callback-points li::before { content: "✓"; color: var(--accent-deep); }
.callback-form { padding: clamp(1.5rem, 4vw, 2.5rem); }
.form-note { margin: 0; color: var(--muted); font-size: 0.88rem; line-height: 1.45; }

.prose-shell { max-width: 760px; }

.service-hero { padding-bottom: 2rem; }
.service-contact { scroll-margin-top: 6rem; }
.service-list { padding-left: 1.2rem; color: var(--muted); line-height: 1.8; }
.service-list li + li { margin-top: 0.4rem; }

.stack-form { display: grid; gap: 1rem; }
.stack-form label { display: grid; gap: 0.45rem; font-weight: 600; }
.stack-form input,
.stack-form textarea,
.stack-form select {
  width: 100%;
  padding: 0.9rem 1rem;
  border-radius: 16px;
  border: 1px solid var(--line);
  background: #fff;
}

.form-feedback {
  padding: 1rem 1.1rem;
  border-radius: 18px;
  border: 1px solid var(--line);
}

.is-hidden { display: none; }

.form-feedback p,
.form-feedback ul {
  margin: 0;
}

.form-feedback ul {
  padding-left: 1.1rem;
  margin-top: 0.5rem;
}

.form-feedback-success {
  background: rgba(38, 122, 77, 0.12);
  color: #1f5f3c;
}

.form-feedback-error {
  background: rgba(161, 46, 46, 0.1);
  color: #7a1d1d;
}

.honeypot-field {
  position: absolute;
  left: -9999px;
  width: 1px;
  height: 1px;
  overflow: hidden;
}

.site-footer {
  border-top: 1px solid var(--line);
  padding: 2rem 0 3rem;
}

@media (max-width: 900px) {
  .menu-button { display: inline-flex; }
  .primary-nav {
    position: absolute;
    top: calc(100% + 0.5rem);
    right: 1rem;
    left: 1rem;
    display: none;
    flex-direction: column;
    align-items: stretch;
    padding: 1rem;
    border: 1px solid var(--line);
    border-radius: 20px;
    background: rgba(255, 250, 244, 0.98);
    box-shadow: var(--shadow);
  }
  .primary-nav[data-open="true"] { display: flex; }
  .primary-nav .language-toggle { width: 100%; }
  .hero-grid,
  .split-grid,
  .footer-grid,
  .card-grid { grid-template-columns: 1fr; }
  .hero-landscape { min-height: 680px; }
  .hero-landscape .hero-grid { grid-template-columns: 1fr; }
  .hero-landscape .hero-copy { grid-column: auto; justify-self: stretch; }
  .choice-grid.compact { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .blog-card { grid-template-columns: 1fr; }
  .blog-card-image { min-height: 260px; max-height: 360px; }
  .article-layout { grid-template-columns: 1fr; }
  .article-aside { position: static; grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .article-aside strong { grid-column: 1 / -1; }
  .callback-intro { position: static; }
  h1 { max-width: unset; }
}

@media (max-width: 600px) {
  .quote-form { padding: 1.25rem; }
  .quote-progress { gap: 0.35rem; margin-bottom: 1.75rem; }
  .quote-progress li { justify-content: center; font-size: 0; }
  .quote-progress span { font-size: 0.82rem; }
  .choice-grid,
  .choice-grid.compact,
  .quote-fields-two { grid-template-columns: 1fr; }
  .quote-actions { flex-wrap: wrap; }
  .quote-actions .button { flex: 1; }
  .quote-actions .button:last-child { margin-left: 0; }
  .article-hero { width: 100%; border-radius: 0; }
  .article-cta { grid-template-columns: 1fr; }
  .article-cta .button { justify-self: start; }
}
