/* =========================================
   KEYNES ROOFING CENTRE
   NEW WEBSITE
   ========================================= */

:root {
  --red: #df171f;
  --red-dark: #bd1017;
  --navy: #142832;
  --navy-dark: #0d202a;
  --text: #1d2830;
  --grey: #65717a;
  --light: #f2f4f5;
  --border: #e1e5e7;
  --white: #ffffff;
  --max-width: 1280px;
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  color: var(--text);
  background: var(--white);
  font-family:
    -apple-system,
    BlinkMacSystemFont,
    "Segoe UI",
    Arial,
    Helvetica,
    sans-serif;
  line-height: 1.5;
}

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

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

.container {
  width: min(92%, var(--max-width));
  margin-inline: auto;
}


/* HEADER */

.site-header {
  background: white;
}

.header-inner {
  min-height: 105px;
  display: flex;
  align-items: center;
  gap: 30px;
}

.site-logo {
  width: 320px;
  max-height: 82px;
  object-fit: contain;
}

.logo-link {
  flex-shrink: 0;
}

.established {
  border-left: 1px solid #c9cdd0;
  padding-left: 25px;
  margin-right: auto;
  font-size: 14px;
}

.established strong,
.established span {
  display: block;
}

.header-contact {
  text-align: right;
  font-size: 14px;
}

.header-contact a {
  display: block;
}

.header-phone {
  color: var(--red);
  font-size: 22px;
  font-weight: 900;
}

.menu-button {
  display: none;
}


/* NAVIGATION */

.main-nav {
  background: var(--navy);
  color: white;
}

.nav-inner {
  display: flex;
  align-items: center;
}

.nav-inner > a {
  padding: 18px 14px;
  font-size: 13px;
  font-weight: 800;
  transition: 0.2s;
}

.nav-inner > a:hover,
.nav-inner > a.active {
  background: rgba(255, 255, 255, 0.08);
}

.nav-inner .nav-quote {
  background: var(--red);
  margin-left: auto;
  padding-inline: 24px;
}

.nav-inner .nav-quote:hover {
  background: var(--red-dark);
}


/* HERO */

.hero {
  position: relative;
  min-height: 545px;
  display: flex;
  align-items: center;
  color: white;

  background-image:
  linear-gradient(
    90deg,
    rgba(7, 21, 29, 0.88) 0%,
    rgba(7, 21, 29, 0.70) 38%,
    rgba(7, 21, 29, 0.20) 72%,
    rgba(7, 21, 29, 0.05) 100%
  ),
  url("../images/keynes-lorries.png");

background-size: cover;
background-position: center;
background-repeat: no-repeat;
}

.hero-overlay {
  position: absolute;
  inset: 0;

  background:
    linear-gradient(
      90deg,
      rgba(7, 21, 29, 0.88) 0%,
      rgba(7, 21, 29, 0.70) 38%,
      rgba(7, 21, 29, 0.20) 72%,
      rgba(7, 21, 29, 0.05) 100%
    );
}

.hero-content {
  position: relative;
  z-index: 2;
  padding-block: 70px;
}

.hero-kicker {
  margin: 0 0 12px;
  font-size: 13px;
  font-weight: 900;
  letter-spacing: 2px;
}

.hero h1 {
  max-width: 800px;
  margin: 0;
  font-size: clamp(48px, 6vw, 78px);
  line-height: 0.95;
  letter-spacing: -3px;
  font-weight: 950;
}

.hero h1 span {
  display: block;
  color: #ff252d;
}

.hero-description {
  max-width: 650px;
  margin: 24px 0 15px;
  font-size: 22px;
  font-weight: 700;
}

.hero-products {
  font-size: 13px;
  font-weight: 800;
  letter-spacing: 0.4px;
}

.hero-products b {
  color: var(--red);
  padding-inline: 5px;
}

.hero-buttons,
.visit-buttons {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  margin-top: 30px;
}


/* BUTTONS */

.button {
  display: inline-flex;
  padding: 14px 25px;
  border-radius: 3px;
  font-size: 13px;
  font-weight: 900;
  transition:
    transform 0.15s,
    background 0.15s;
}

.button:hover {
  transform: translateY(-2px);
}

.button-red {
  color: white;
  background: var(--red);
}

.button-red:hover {
  background: var(--red-dark);
}

.button-white {
  color: var(--navy);
  background: white;
}

.button-dark {
  color: white;
  background: var(--navy);
}


/* BENEFITS */

.benefits {
  color: white;
  background: var(--navy);
}

.benefits-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
}

.benefit {
  min-height: 84px;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 13px;
  padding: 15px;
  border-right: 1px solid #41515a;
}

.benefit:last-child {
  border-right: 0;
}

.benefit-icon {
  color: var(--red);
  font-size: 26px;
  font-weight: 900;
}

.benefit strong,
.benefit span {
  display: block;
}

.benefit strong {
  font-size: 15px;
}

.benefit span {
  margin-top: 2px;
  color: #d0d7db;
  font-size: 12px;
}


/* GENERIC SECTIONS */

.section {
  padding: 65px 0;
}

.section-label {
  margin: 0 0 6px;
  color: var(--red);
  font-size: 12px;
  font-weight: 900;
  letter-spacing: 1.8px;
}

section h2 {
  margin: 0 0 32px;
  font-size: clamp(34px, 4vw, 46px);
  line-height: 1;
  letter-spacing: -1.5px;
}

section h2 span {
  color: var(--red);
}


/* CATEGORY GRID */

.category-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 14px;
}

.category-card {
  position: relative;
  height: 275px;
  overflow: hidden;
  background: #222;
}

.category-card img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition:
    transform 0.35s,
    opacity 0.35s;
}

.category-card:hover img {
  transform: scale(1.045);
}

.category-overlay {
  position: absolute;
  inset: auto 0 0 0;
  padding: 60px 20px 20px;

  color: white;

  background:
    linear-gradient(
      transparent,
      rgba(0,0,0,0.88)
    );
}

.category-overlay h3 {
  margin: 0;
  font-size: 25px;
}

.category-overlay p {
  margin: 3px 0 0;
  font-size: 13px;
}


/* HELP / TRADE */

.split-section {
  display: grid;
  grid-template-columns: 1fr 1fr;
}

.help-panel,
.trade-panel {
  min-height: 390px;
  display: flex;
  align-items: center;
}

.help-panel {
  color: white;
  background: var(--navy-dark);
}

.trade-panel {
  background: #edf0f2;
}

.panel-content {
  width: min(85%, 550px);
  margin-inline: auto;
  padding: 50px 0;
}

.panel-content h2 {
  max-width: 500px;
  margin-bottom: 20px;
}

.panel-content p:not(.section-label) {
  max-width: 520px;
}

.help-panel h2 span {
  color: var(--red);
}


/* WHY */

.why {
  background: white;
}

.why-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 22px;
}

.why-card {
  overflow: hidden;
  border: 1px solid var(--border);
  background: white;
}

.why-card img {
  width: 100%;
  height: 240px;
  object-fit: cover;
}

.why-content {
  padding: 27px;
}

.why-content h3 {
  margin: 0 0 8px;
  font-size: 18px;
}

.why-content p {
  margin: 0;
  color: var(--grey);
  font-size: 14px;
}


/* VISIT */

.visit {
  padding: 65px 0;
  background: var(--light);
}

.visit-grid {
  display: grid;
  grid-template-columns: 1.25fr 0.75fr;
  gap: 55px;
  align-items: center;
}

.visit-image img {
  width: 100%;
  height: 500px;
  object-fit: cover;
  border-radius: 2px;
}

.visit-content h2 {
  margin-bottom: 20px;
}

.visit-intro {
  font-size: 18px;
  font-weight: 700;
}

.contact-details p {
  margin: 13px 0;
}

.contact-details a:hover {
  color: var(--red);
}


/* FOOTER */

.site-footer {
  padding: 50px 0 18px;
  color: white;
  background: var(--navy-dark);
}

.footer-grid {
  display: grid;
  grid-template-columns: 1.5fr 0.8fr 1fr;
  gap: 55px;
}

.footer-logo {
  width: 270px;
  height: auto;
  margin-bottom: 20px;
  padding: 12px 18px;
  background: #ffffff;
  border-radius: 3px;
}

.footer-company p,
.site-footer p,
.site-footer li {
  color: #c9d0d4;
  font-size: 14px;
}

.site-footer h3 {
  margin-top: 0;
  font-size: 14px;
}

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

.site-footer li {
  margin: 8px 0;
}

.site-footer a:hover {
  color: white;
}

.footer-bottom {
  margin-top: 40px;
  padding-top: 18px;
  border-top: 1px solid #40505a;
}

.footer-bottom p {
  margin: 0;
  font-size: 12px;
}


/* TABLET */

@media (max-width: 650px) {

  .established {
    display: none;
  }

  .header-inner {
    min-height: 90px;
  }

  .site-logo {
    width: 250px;
  }

  .nav-inner {
    overflow-x: auto;
  }

  .nav-inner > a {
    white-space: nowrap;
  }

  .nav-quote {
    display: none;
  }

  .category-grid {
    grid-template-columns: repeat(2, 1fr);
  }

  .benefits-grid {
    grid-template-columns: repeat(2, 1fr);
  }

  .benefit:nth-child(2) {
    border-right: 0;
  }

  .split-section {
    grid-template-columns: 1fr;
  }

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

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

}


/* MOBILE */

@media (max-width: 650px) {

  .header-inner {
    min-height: 78px;
  }

  .site-logo {
    width: 205px;
  }

  .header-contact {
    display: none;
  }

  .menu-button {
    display: block;
    margin-left: auto;
    border: 0;
    color: var(--navy);
    background: transparent;
    font-size: 30px;
    cursor: pointer;
  }

  .main-nav {
    display: none;
  }

  .main-nav.open {
    display: block;
  }

  .nav-inner {
    width: 100%;
    display: block;
  }

  .nav-inner > a {
    display: block;
    padding: 14px 5%;
    border-bottom: 1px solid #35454e;
  }

  .hero {
  position: relative !important;
  min-height: 590px;
  display: flex;
  align-items: center;
  color: white;

  background-image:
    linear-gradient(
      90deg,
      rgba(7, 21, 29, 0.94) 0%,
      rgba(7, 21, 29, 0.82) 38%,
      rgba(7, 21, 29, 0.42) 65%,
      rgba(7, 21, 29, 0.08) 100%
    ),
    url("../images/keynes-lorries.png") center center / cover no-repeat !important;

  background-size: cover;
  background-position: center 62%;
  background-repeat: no-repeat;
}

.hero-overlay {
  display: none !important;
}

.hero-content {
  position: relative;
  z-index: 2;
  padding-block: 60px;
}

.hero-kicker {
  margin: 0 0 14px;
  color: #ffffff;
  font-size: 13px;
  font-weight: 900;
  letter-spacing: 2.2px;
}

.hero h1 {
  max-width: 850px;
  margin: 0;
  font-size: clamp(45px, 5.8vw, 82px);
  line-height: 0.95;
  letter-spacing: -2px;
  font-weight: 950;
}

.hero h1 span {
  display: block;
  color: #ff252d;
}

.hero-description {
  max-width: 660px;
  margin: 28px 0 15px;
  font-size: 22px;
  line-height: 1.35;
  font-weight: 700;
}

.hero-products {
  max-width: 760px;
  font-size: 13px;
  line-height: 1.8;
  font-weight: 800;
  letter-spacing: 0.5px;
}

.hero-products b {
  color: #ff252d;
  padding-inline: 6px;
}

.hero-buttons {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  margin-top: 32px;
}
  .benefits-grid {
    grid-template-columns: 1fr 1fr;
  }

  .benefit {
    min-height: 100px;
    display: block;
    text-align: center;
    border-bottom: 1px solid #41515a;
  }

  .benefit-icon {
    margin-bottom: 5px;
  }

  .section {
    padding: 45px 0;
  }

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

  .category-card {
    height: 220px;
  }

  .panel-content {
    width: 90%;
  }

  .visit {
    padding: 45px 0;
  }

  .visit-image img {
    height: 300px;
  }

  .visit-buttons .button {
    width: 100%;
    text-align: center;
  }

  .footer-grid {
    grid-template-columns: 1fr;
    gap: 25px;
  }

}