/* ============================
   Jack and George Exterior Solutions
   Styles
   ============================ */

:root {
  --color-primary: #0b4f8a;
  --color-primary-dark: #073b6a;
  --color-primary-light: #e8f1fb;
  --color-accent: #1683d8;
  --color-text: #1b2733;
  --color-text-muted: #4d5b68;
  --color-white: #ffffff;
  --color-border: #d9e4f0;
  --radius: 10px;
  --max-width: 1120px;
  --font-base: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  font-family: var(--font-base);
  color: var(--color-text);
  background: var(--color-white);
  line-height: 1.5;
  -webkit-font-smoothing: antialiased;
}

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

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

ul {
  margin: 0;
  padding: 0;
  list-style: none;
}

h1, h2, h3 {
  line-height: 1.2;
  margin: 0 0 0.5em;
  font-weight: 700;
}

p {
  margin: 0 0 1em;
}

.container {
  max-width: var(--max-width);
  margin: 0 auto;
  padding: 0 20px;
}

.skip-link {
  position: absolute;
  left: -999px;
  top: 0;
  background: var(--color-primary-dark);
  color: #fff;
  padding: 10px 16px;
  z-index: 1000;
}
.skip-link:focus {
  left: 10px;
  top: 10px;
}

/* Sections give scroll offset so sticky header doesn't cover the heading */
section[id], .site-header {
  scroll-margin-top: 76px;
}

.section {
  padding: 64px 0;
}
.section-alt {
  background: var(--color-primary-light);
}
.section-title {
  font-size: 1.9rem;
  color: var(--color-primary-dark);
}
.section-lead {
  max-width: 640px;
  color: var(--color-text-muted);
  margin-bottom: 2rem;
  font-size: 1.05rem;
}

/* ---------- Buttons ---------- */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 12px 22px;
  border-radius: 999px;
  font-weight: 600;
  font-size: 1rem;
  border: 2px solid transparent;
  cursor: pointer;
  transition: transform 0.15s ease, box-shadow 0.15s ease, background 0.15s ease;
  white-space: nowrap;
}
.btn:hover {
  transform: translateY(-1px);
}
.btn-icon {
  width: 18px;
  height: 18px;
  fill: currentColor;
  flex-shrink: 0;
}
.btn-primary {
  background: var(--color-primary);
  color: #fff;
  box-shadow: 0 4px 14px rgba(11, 79, 138, 0.35);
}
.btn-primary:hover {
  background: var(--color-primary-dark);
}
.btn-outline {
  background: transparent;
  color: var(--color-primary-dark);
  border-color: var(--color-primary);
}
.btn-outline:hover {
  background: var(--color-primary-light);
}
.btn-lg {
  padding: 15px 28px;
  font-size: 1.05rem;
}
.btn-nav-cta {
  padding: 8px 18px;
  font-size: 0.92rem;
}

/* ---------- Header / Nav ---------- */
.site-header {
  position: sticky;
  top: 0;
  z-index: 500;
  background: var(--color-white);
  border-bottom: 1px solid var(--color-border);
}
.nav-inner {
  max-width: var(--max-width);
  margin: 0 auto;
  padding: 12px 20px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
}
.logo {
  display: flex;
  flex-direction: column;
  line-height: 1.1;
}
.logo-line1 {
  font-weight: 800;
  font-size: 1.15rem;
  color: var(--color-primary-dark);
  letter-spacing: 0.02em;
}
.logo-line2 {
  font-weight: 600;
  font-size: 0.65rem;
  letter-spacing: 0.18em;
  color: var(--color-accent);
}

.nav-toggle {
  display: flex;
  flex-direction: column;
  justify-content: center;
  gap: 5px;
  width: 40px;
  height: 40px;
  background: transparent;
  border: 1px solid var(--color-border);
  border-radius: 8px;
  cursor: pointer;
}
.nav-toggle span {
  display: block;
  height: 2px;
  width: 20px;
  margin: 0 auto;
  background: var(--color-primary-dark);
  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);
}

.primary-nav {
  position: absolute;
  top: 100%;
  left: 0;
  right: 0;
  background: var(--color-white);
  border-bottom: 1px solid var(--color-border);
  display: none;
  flex-direction: column;
  padding: 16px 20px 24px;
  gap: 16px;
}
.primary-nav.is-open {
  display: flex;
}
.primary-nav ul {
  display: flex;
  flex-direction: column;
  gap: 14px;
}
.nav-link {
  display: block;
  font-weight: 600;
  color: var(--color-text);
  padding: 6px 0;
}
.nav-link:hover {
  color: var(--color-primary);
}
.btn-nav-cta {
  align-self: flex-start;
}

/* ---------- Hero ---------- */
.hero {
  background: linear-gradient(180deg, var(--color-primary-light) 0%, #ffffff 100%);
  padding: 56px 0 48px;
  text-align: center;
}
.hero-inner h1 {
  font-size: 2rem;
  color: var(--color-primary-dark);
}
.hero-tagline {
  font-size: 1.15rem;
  font-weight: 600;
  color: var(--color-primary);
  margin-bottom: 0.75em;
}
.hero-sub {
  color: var(--color-text-muted);
  max-width: 560px;
  margin-left: auto;
  margin-right: auto;
  font-size: 1.02rem;
}
.hero-actions {
  display: flex;
  flex-direction: column;
  gap: 14px;
  align-items: center;
  margin: 28px 0 14px;
}
.hero-email {
  font-size: 0.95rem;
  color: var(--color-text-muted);
}
.hero-email a {
  color: var(--color-primary);
  font-weight: 600;
  text-decoration: underline;
}

/* ---------- Services ---------- */
.services-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 24px;
}
.service-card {
  background: var(--color-white);
  border: 1px solid var(--color-border);
  border-radius: var(--radius);
  padding: 28px 24px;
  box-shadow: 0 2px 10px rgba(11, 79, 138, 0.06);
}
.service-icon {
  width: 52px;
  height: 52px;
  border-radius: 12px;
  background: var(--color-primary);
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 16px;
}
.service-icon svg {
  width: 28px;
  height: 28px;
  fill: #fff;
}
.service-card h3 {
  font-size: 1.15rem;
  color: var(--color-primary-dark);
}
.service-card p {
  color: var(--color-text-muted);
  margin-bottom: 0;
  font-size: 0.98rem;
}

/* ---------- Service Area ---------- */
.area-list {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 12px 20px;
  max-width: 640px;
  margin-bottom: 20px;
}
.area-list li {
  font-weight: 600;
  color: var(--color-primary-dark);
  padding-left: 22px;
  position: relative;
}
.area-list li::before {
  content: "";
  position: absolute;
  left: 0;
  top: 0.55em;
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--color-accent);
}
.area-note {
  color: var(--color-text-muted);
  font-style: italic;
}

/* ---------- Contact CTA ---------- */
.contact-inner {
  text-align: center;
}
.contact-inner .section-lead {
  margin-left: auto;
  margin-right: auto;
}
.contact-cta .hero-actions {
  flex-direction: column;
}

/* ---------- Footer ---------- */
.site-footer {
  background: var(--color-primary-dark);
  color: #fff;
  padding: 40px 0 24px;
}
.footer-inner {
  display: flex;
  flex-direction: column;
  gap: 18px;
  align-items: flex-start;
}
.footer-brand .logo-line1 {
  color: #fff;
}
.footer-brand .logo-line2 {
  color: #9cc7ec;
}
.footer-contact {
  display: flex;
  flex-direction: column;
  gap: 6px;
  font-size: 0.95rem;
}
.footer-contact a {
  font-weight: 600;
}
.footer-contact a:hover {
  text-decoration: underline;
}
.footer-contact span {
  color: #c3d8ec;
}
.footer-copy {
  font-size: 0.8rem;
  color: #9db9d3;
  margin: 12px 0 0;
}

/* ============================
   Tablet and up
   ============================ */
@media (min-width: 640px) {
  .services-grid {
    grid-template-columns: repeat(2, 1fr);
  }
  .hero-actions {
    flex-direction: row;
    justify-content: center;
  }
  .contact-cta .hero-actions {
    flex-direction: row;
  }
}

/* ============================
   Desktop
   ============================ */
@media (min-width: 900px) {
  .nav-toggle {
    display: none;
  }
  .primary-nav {
    position: static;
    display: flex !important;
    flex-direction: row;
    align-items: center;
    border: none;
    padding: 0;
    gap: 28px;
    width: auto;
  }
  .primary-nav ul {
    flex-direction: row;
    gap: 28px;
  }
  .hero-inner h1 {
    font-size: 2.6rem;
  }
  .hero-tagline {
    font-size: 1.35rem;
  }
  .section-title {
    font-size: 2.3rem;
  }
  .services-grid {
    grid-template-columns: repeat(4, 1fr);
  }
  .footer-inner {
    flex-direction: row;
    justify-content: space-between;
    align-items: center;
  }
  .footer-contact {
    flex-direction: row;
    gap: 24px;
  }
  .footer-copy {
    width: 100%;
    text-align: center;
  }
}
