/* Ironwood Plumbing: phone-first styles. No web fonts, no animations. */

:root {
  --ink: #1c2430;
  --muted: #4a5563;
  --line: #d9dee5;
  --bg-alt: #f5f2ee;
  --iron: #16202c;
  --accent: #c2410c;
  --accent-dark: #9a3412;
  --focus: #1d4ed8;
}

*,
*::before,
*::after {
  box-sizing: border-box;
}

/* Dark page color fills any space below the footer on short pages */
html {
  -webkit-text-size-adjust: 100%;
  background: #0f161f;
}

body {
  margin: 0;
  font-family: system-ui, -apple-system, "Segoe UI", Roboto, Arial, sans-serif;
  font-size: 1.0625rem;
  line-height: 1.55;
  color: var(--ink);
  background: #fff;
}

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

a {
  color: var(--accent-dark);
}

h1,
h2,
h3 {
  margin: 0 0 0.5em;
  line-height: 1.15;
}

h1 {
  font-size: 2rem;
}

h2 {
  font-size: 1.5rem;
}

h3 {
  font-size: 1.125rem;
}

p {
  margin: 0 0 1em;
}

/* Keeps link targets from hiding under the sticky header */
[id] {
  scroll-margin-top: 80px;
}

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

.site-header :focus-visible,
.cta :focus-visible,
.site-footer :focus-visible {
  outline-color: #fbbf24;
}

.wrap {
  max-width: 1040px;
  margin: 0 auto;
  padding: 0 16px;
}

.narrow {
  max-width: 560px;
}

.skip-link {
  position: absolute;
  left: -9999px;
}

.skip-link:focus {
  top: 8px;
  left: 8px;
  z-index: 20;
  padding: 8px 12px;
  background: #fff;
}

/* Sticky header: the quote button stays on screen while people scroll */
.site-header {
  position: sticky;
  top: 0;
  z-index: 10;
  background: var(--iron);
}

.header-bar {
  display: flex;
  align-items: center;
  gap: 8px;
  min-height: 64px;
}

.brand {
  flex: 1 1 auto;
  min-width: 0;
  color: #fff;
  font-weight: 800;
  line-height: 1.1;
  text-decoration: none;
}

.brand span {
  display: block;
  color: #f3c9a8;
  font-weight: 600;
}

/* Buttons */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 48px;
  padding: 0 20px;
  border: 2px solid transparent;
  border-radius: 8px;
  font: inherit;
  font-weight: 700;
  text-align: center;
  text-decoration: none;
  cursor: pointer;
}

.btn-primary {
  background: var(--accent);
  color: #fff;
}

.btn-primary:hover {
  background: var(--accent-dark);
}

.btn-outline {
  background: #fff;
  color: var(--ink);
  border-color: var(--ink);
}

.btn-ghost {
  color: #fff;
  border-color: rgba(255, 255, 255, 0.7);
}

/* Header buttons: full thumb size (48px tall) */
.btn-small {
  min-height: 48px;
  padding: 0 14px;
  font-size: 1.0625rem;
  white-space: nowrap;
}

.btn-block {
  width: 100%;
}

.long {
  display: none;
}

.actions {
  display: flex;
  flex-direction: column;
  gap: 12px;
  margin: 20px 0;
}

/* Hero */
.hero {
  padding: 24px 0 32px;
}

.hero h1 span {
  display: block;
  color: var(--accent-dark);
}

.lead {
  font-size: 1.125rem;
  color: var(--muted);
}

.hours {
  color: var(--muted);
}

.hours strong {
  color: var(--ink);
}

.hero-img {
  width: 100%;
  border-radius: 12px;
}

/* Sections */
.section {
  padding: 40px 0;
}

.alt {
  background: var(--bg-alt);
}

/* Reviews */
.reviews {
  display: grid;
  gap: 12px;
}

blockquote {
  margin: 0;
  padding: 16px 18px;
  background: #fff;
  border-left: 4px solid var(--accent);
  border-radius: 8px;
}

blockquote p {
  margin: 0;
}

/* Services */
.services {
  display: grid;
  gap: 12px;
  margin: 0 0 20px;
  padding: 0;
  list-style: none;
}

.services li {
  padding: 16px;
  border: 1px solid var(--line);
  border-radius: 10px;
}

.services h3 {
  margin: 0;
}

.services p {
  margin: 4px 0 0;
  color: var(--muted);
}

.photo-pair {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 12px;
}

.photo-pair img {
  width: 100%;
  aspect-ratio: 1;
  object-fit: cover;
  border-radius: 10px;
}

/* Service area */
.towns {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin: 0 0 32px;
  padding: 0;
  list-style: none;
}

.towns li {
  padding: 6px 14px;
  background: #fff;
  border: 1px solid var(--line);
  border-radius: 999px;
}

/* Closing call to action */
.cta {
  background: var(--iron);
  color: #fff;
}

.cta p {
  color: #d7dde5;
}

.cta-img {
  width: 100%;
  aspect-ratio: 3 / 2;
  object-fit: cover;
  border-radius: 12px;
}

/* Quote form */
.emergency,
.notice {
  padding: 12px 14px;
  background: #fff4ec;
  border: 1px solid #f3c9a8;
  border-radius: 8px;
}

/* Quote page is kept compact so the send button shows without scrolling */
.section-form {
  padding: 16px 0 32px;
}

.section-form h1 {
  margin-bottom: 0.25em;
}

.section-form .lead {
  margin-bottom: 12px;
}

.after-form {
  margin-top: 20px;
}

.quote-form {
  display: grid;
  gap: 12px;
  margin-top: 8px;
}

.field label {
  display: block;
  margin-bottom: 4px;
  font-weight: 700;
}

.field input,
.field textarea {
  width: 100%;
  padding: 10px 14px;
  font: inherit;
  color: var(--ink);
  background: #fff;
  border: 2px solid #6b7280;
  border-radius: 8px;
}

.field textarea {
  height: 84px;
  resize: vertical;
}

.hint {
  margin: -2px 0 6px;
  font-size: 0.9375rem;
  color: var(--muted);
}

/* Private quote request list */
.requests {
  display: grid;
  gap: 12px;
  margin: 0;
  padding: 0;
  list-style: none;
}

.request {
  padding: 16px;
  border: 1px solid var(--line);
  border-radius: 10px;
}

.request h2 {
  margin: 0 0 4px;
  font-size: 1.25rem;
}

.request-time {
  margin: 0 0 4px;
  font-size: 0.9375rem;
  color: var(--muted);
}

.request dl {
  margin: 0;
}

.request dt {
  margin-top: 8px;
  font-size: 0.8125rem;
  font-weight: 700;
  color: var(--muted);
  text-transform: uppercase;
}

.request dd {
  margin: 0;
  overflow-wrap: anywhere;
}

.request-job {
  white-space: pre-line;
}

/* Footer */
.site-footer {
  padding: 32px 0;
  font-size: 0.9375rem;
  color: #c9d1db;
  background: #0f161f;
}

.site-footer a {
  color: #fff;
}

.footer-name {
  margin-bottom: 4px;
  font-weight: 800;
  color: #fff;
}

.demo-note {
  margin: 20px 0 0;
  padding-top: 16px;
  border-top: 1px solid #2a3542;
  color: #9aa5b4;
}

/* Smaller phones: keep both header buttons on one row */
@media (max-width: 380px) {
  .btn-small {
    padding: 0 12px;
    font-size: 1rem;
  }
}

@media (max-width: 359px) {
  .wrap {
    padding: 0 12px;
  }

  .header-bar {
    gap: 6px;
  }

  .brand {
    font-size: 0.9375rem;
  }

  .btn-small {
    padding: 0 10px;
    font-size: 0.9375rem;
  }
}

/* Larger phones and tablets */
@media (min-width: 640px) {
  .brand {
    font-size: 1.125rem;
  }

  .brand span {
    display: inline;
  }

  .short {
    display: none;
  }

  .long {
    display: inline;
  }

  .actions {
    flex-direction: row;
    flex-wrap: wrap;
  }

  .reviews,
  .services {
    grid-template-columns: 1fr 1fr;
  }
}

/* Laptops and desktops */
@media (min-width: 860px) {
  h1 {
    font-size: 2.75rem;
  }

  .hero {
    padding: 48px 0 56px;
  }

  .hero-grid {
    display: grid;
    grid-template-columns: 1.1fr 1fr;
    gap: 40px;
    align-items: center;
  }

  .section {
    padding: 56px 0;
  }

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

  .cta-grid {
    display: grid;
    grid-template-columns: 1.2fr 1fr;
    gap: 40px;
    align-items: center;
  }
}
