/* Northern Range Exteriors — brand stylesheet
   Brand pulled from logo:
   - Orange  #EA6A1F  (primary accent)
   - Charcoal #1F1F1F (primary text / dark sections)
   - White   #FFFFFF
   - Off-white #F7F4F0 (warm neutral background)
   - Gray    #6B6B6B (secondary text) */

:root {
  --orange: #EA6A1F;
  --orange-dark: #C7551A;
  --charcoal: #1F1F1F;
  --gray: #6B6B6B;
  --offwhite: #F7F4F0;
  --white: #FFFFFF;
  --maxw: 1140px;
  --radius: 6px;
}

* { box-sizing: border-box; }

html { scroll-behavior: smooth; }

body {
  margin: 0;
  font-family: "Inter", "Helvetica Neue", Arial, sans-serif;
  color: var(--charcoal);
  background: var(--white);
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}

h1, h2, h3 {
  font-family: "Oswald", "Arial Black", Impact, sans-serif;
  letter-spacing: 0.5px;
  line-height: 1.15;
  margin: 0 0 0.5em;
  text-transform: uppercase;
}

h1 { font-size: clamp(2.2rem, 5vw, 3.6rem); }
h2 { font-size: clamp(1.8rem, 3.5vw, 2.4rem); }
h3 { font-size: 1.25rem; }

p { margin: 0 0 1em; }

a { color: var(--orange); text-decoration: none; }
a:hover { color: var(--orange-dark); }

.container {
  max-width: var(--maxw);
  margin: 0 auto;
  padding: 0 1.25rem;
}

/* ---------- Header / Nav ---------- */
.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  background: var(--white);
  border-bottom: 1px solid #eee;
}
.nav {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0.75rem 1.25rem;
  max-width: var(--maxw);
  margin: 0 auto;
}
.nav-logo {
  display: flex;
  align-items: center;
  gap: 0.6rem;
  font-family: "Oswald", sans-serif;
  font-weight: 700;
  text-transform: uppercase;
  color: var(--charcoal);
  font-size: 1.6rem;
  letter-spacing: 0.5px;
}
.nav-logo img { height: 168px; width: auto; display: block; }
.sr-only { position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip: rect(0,0,0,0); white-space: nowrap; border: 0; }
.nav ul {
  list-style: none;
  display: flex;
  gap: 1.5rem;
  margin: 0; padding: 0;
}
.nav ul a {
  color: var(--charcoal);
  font-weight: 600;
  font-size: 0.95rem;
}
.nav ul a:hover { color: var(--orange); }
.nav-cta {
  background: var(--orange);
  color: var(--white) !important;
  padding: 0.55rem 1rem;
  border-radius: var(--radius);
  font-weight: 700;
}
.nav-cta:hover { background: var(--orange-dark); color: var(--white) !important; }

/* ---------- Buttons ---------- */
.btn {
  display: inline-block;
  padding: 0.85rem 1.5rem;
  border-radius: var(--radius);
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  font-size: 0.95rem;
  border: 2px solid transparent;
  transition: transform 0.15s ease, background 0.15s ease;
}
.btn:hover { transform: translateY(-1px); }
.btn-primary { background: var(--orange); color: var(--white); }
.btn-primary:hover { background: var(--orange-dark); color: var(--white); }
.btn-outline {
  background: transparent;
  color: var(--white);
  border-color: var(--white);
}
.btn-outline:hover { background: var(--white); color: var(--charcoal); }

/* ---------- Hero ---------- */
.hero {
  background: var(--charcoal);
  color: var(--white);
  padding: 5rem 1.25rem 5.5rem;
  text-align: center;
  position: relative;
  overflow: hidden;
}
.hero::after {
  /* subtle orange accent bar */
  content: "";
  position: absolute;
  left: 0; right: 0; bottom: 0;
  height: 6px;
  background: var(--orange);
}
.hero h1 { color: var(--white); }
.hero .tagline {
  color: var(--orange);
  font-family: "Oswald", sans-serif;
  text-transform: uppercase;
  letter-spacing: 2px;
  font-size: 1rem;
  margin-bottom: 0.5rem;
}
.hero .sub {
  max-width: 640px;
  margin: 0 auto 2rem;
  color: #d8d8d8;
  font-size: 1.1rem;
}
.hero .cta-row {
  display: flex;
  gap: 1rem;
  justify-content: center;
  flex-wrap: wrap;
}

/* ---------- Sections ---------- */
section { padding: 4.5rem 0; }
.section-header { text-align: center; margin-bottom: 2.5rem; }
.section-header .eyebrow {
  color: var(--orange);
  font-family: "Oswald", sans-serif;
  text-transform: uppercase;
  letter-spacing: 2px;
  font-size: 0.85rem;
  font-weight: 700;
}
.section-alt { background: var(--offwhite); }

/* ---------- Services grid ---------- */
.services {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
  gap: 1.25rem;
}
.service-card {
  background: var(--white);
  border: 1px solid #ececec;
  border-radius: var(--radius);
  overflow: hidden;
  transition: transform 0.15s ease, box-shadow 0.15s ease;
  display: flex;
  flex-direction: column;
}
.service-card:hover {
  transform: translateY(-3px);
  box-shadow: 0 10px 30px rgba(0,0,0,0.08);
}
.service-card .photo {
  aspect-ratio: 4 / 3;
  background: linear-gradient(135deg, #2a2a2a 0%, #4a4a4a 100%);
  position: relative;
  overflow: hidden;
  border-bottom: 4px solid var(--orange);
}
.service-card .photo img {
  width: 100%; height: 100%;
  object-fit: cover;
  display: block;
}
.service-card .photo .placeholder {
  position: absolute; inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  color: rgba(255,255,255,0.45);
  font-family: "Oswald", sans-serif;
  text-transform: uppercase;
  letter-spacing: 2px;
  font-size: 0.75rem;
  text-align: center;
  padding: 1rem;
}
.service-card .body {
  padding: 1.5rem;
}
.service-card h3 {
  color: var(--charcoal);
  margin-bottom: 0.5rem;
}
.service-card p {
  color: var(--gray);
  margin: 0;
  font-size: 0.97rem;
}

/* ---------- Gallery / Recent Work ---------- */
.gallery {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
  gap: 1rem;
}
.gallery .tile {
  position: relative;
  aspect-ratio: 1 / 1;
  background: linear-gradient(135deg, #1f1f1f 0%, #3a3a3a 100%);
  border-radius: var(--radius);
  overflow: hidden;
}
.gallery .tile img {
  width: 100%; height: 100%;
  object-fit: cover;
  display: block;
}
.gallery .tile .placeholder {
  position: absolute; inset: 0;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  color: rgba(255,255,255,0.5);
  font-family: "Oswald", sans-serif;
  text-transform: uppercase;
  letter-spacing: 2px;
  font-size: 0.8rem;
  text-align: center;
  padding: 1rem;
  gap: 0.5rem;
}
.gallery .tile .placeholder .label {
  font-size: 0.65rem;
  color: var(--orange);
}
.gallery .tile.before-after::after {
  content: "BEFORE / AFTER";
  position: absolute;
  top: 0.75rem; left: 0.75rem;
  background: var(--orange);
  color: var(--white);
  font-family: "Oswald", sans-serif;
  font-size: 0.65rem;
  letter-spacing: 1px;
  padding: 0.25rem 0.5rem;
  border-radius: 3px;
}

/* ---------- Hero photo support ---------- */
.hero.has-photo {
  background-image:
    linear-gradient(rgba(31,31,31,0.78), rgba(31,31,31,0.78)),
    var(--hero-bg, none);
  background-size: cover;
  background-position: center;
}

/* ---------- About ---------- */
.about-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 1.5rem;
  margin-top: 2rem;
}
.about-item {
  text-align: center;
  padding: 1.5rem 1rem;
}
.about-item .icon {
  display: inline-block;
  width: 56px; height: 56px;
  border-radius: 50%;
  background: var(--orange);
  color: var(--white);
  font-family: "Oswald", sans-serif;
  font-weight: 700;
  font-size: 1.6rem;
  line-height: 56px;
  margin-bottom: 0.75rem;
}
.about-item h3 { margin-bottom: 0.25rem; }
.about-item p { color: var(--gray); font-size: 0.95rem; }

/* ---------- Contact / CTA ---------- */
.cta-band {
  background: var(--orange);
  color: var(--white);
  text-align: center;
  padding: 3.5rem 1.25rem;
}
.cta-band h2 { color: var(--white); }
.cta-band .btn-primary {
  background: var(--charcoal);
}
.cta-band .btn-primary:hover { background: #000; }

.contact-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 1.5rem;
  margin-top: 1rem;
  text-align: center;
}
.contact-item h3 {
  font-size: 1rem;
  color: var(--gray);
  letter-spacing: 1px;
}
.contact-item a, .contact-item span {
  font-family: "Oswald", sans-serif;
  font-size: 1.35rem;
  color: var(--charcoal);
}
.contact-item a:hover { color: var(--orange); }

/* ---------- Estimate Form ---------- */
.estimate-form {
  max-width: 720px;
  margin: 2rem auto 0;
  background: var(--white);
  border: 1px solid #ececec;
  border-top: 4px solid var(--orange);
  border-radius: var(--radius);
  padding: 2rem;
  box-shadow: 0 6px 24px rgba(0,0,0,0.05);
}
.estimate-form .row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 1rem;
}
.estimate-form .field {
  margin-bottom: 1rem;
}
.estimate-form label {
  display: block;
  font-family: "Oswald", sans-serif;
  text-transform: uppercase;
  letter-spacing: 1px;
  font-size: 0.8rem;
  color: var(--charcoal);
  margin-bottom: 0.35rem;
  font-weight: 600;
}
.estimate-form label .req { color: var(--orange); }
.estimate-form input,
.estimate-form select,
.estimate-form textarea {
  width: 100%;
  padding: 0.7rem 0.85rem;
  border: 1px solid #d4d4d4;
  border-radius: var(--radius);
  font-family: inherit;
  font-size: 1rem;
  color: var(--charcoal);
  background: var(--white);
  transition: border-color 0.15s ease, box-shadow 0.15s ease;
}
.estimate-form input:focus,
.estimate-form select:focus,
.estimate-form textarea:focus {
  outline: none;
  border-color: var(--orange);
  box-shadow: 0 0 0 3px rgba(234,106,31,0.15);
}
.estimate-form textarea { resize: vertical; min-height: 110px; }

/* Honeypot — visually hidden but reachable to bots */
.estimate-form .hp {
  position: absolute;
  left: -9999px;
  width: 1px; height: 1px;
  overflow: hidden;
}

.estimate-form .submit-row {
  display: flex;
  align-items: center;
  gap: 1rem;
  margin-top: 0.5rem;
  flex-wrap: wrap;
}
.estimate-form button {
  background: var(--orange);
  color: var(--white);
  border: none;
  padding: 0.9rem 1.6rem;
  border-radius: var(--radius);
  font-family: "Oswald", sans-serif;
  text-transform: uppercase;
  letter-spacing: 1px;
  font-weight: 700;
  font-size: 1rem;
  cursor: pointer;
  transition: background 0.15s ease, transform 0.15s ease;
}
.estimate-form button:hover:not(:disabled) {
  background: var(--orange-dark);
  transform: translateY(-1px);
}
.estimate-form button:disabled {
  opacity: 0.6;
  cursor: not-allowed;
}
.estimate-form .status {
  font-size: 0.95rem;
  font-weight: 600;
}
.estimate-form .status.ok    { color: #1f7a3a; }
.estimate-form .status.err   { color: #b32020; }
.estimate-form .form-note {
  margin-top: 0.75rem;
  font-size: 0.85rem;
  color: var(--gray);
}

@media (max-width: 600px) {
  .estimate-form .row { grid-template-columns: 1fr; }
  .estimate-form { padding: 1.5rem; }
}

/* ---------- Footer ---------- */
.site-footer {
  background: var(--charcoal);
  color: #bdbdbd;
  text-align: center;
  padding: 2rem 1.25rem;
  font-size: 0.9rem;
}
.site-footer a { color: var(--orange); }

/* ---------- Mobile ---------- */
@media (max-width: 720px) {
  .nav ul { gap: 0.9rem; }
  .nav ul li:not(:last-child) { display: none; } /* hide all but CTA on small screens */
  .hero { padding: 3.5rem 1.25rem 4rem; }
  section { padding: 3rem 0; }
}
