/* ==========================================================================
   Gromitek — shared stylesheet
   ========================================================================== */

:root {
  --color-primary: #1e6fa8;       /* deep azure — links, buttons */
  --color-primary-light: #cdeefd; /* pale azure blue — dominant accent */
  --color-navy: #0b3954;          /* dark navy — headings, header/footer */
  --color-bg: #ffffff;
  --color-bg-alt: #f4fafd;
  --color-text: #22303a;
  --color-text-light: #eaf6fc;
  --max-width: 1140px;
  --radius: 8px;
  --shadow: 0 4px 16px rgba(11, 57, 84, 0.1);
  --shadow-lift: 0 14px 30px rgba(11, 57, 84, 0.2);
  --font-heading: "Barlow Semi Condensed", "Segoe UI", Roboto, Arial, sans-serif;
  --font-body: "Inter", "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
  --transition: 0.25s ease;
  --grid-line: rgba(205, 238, 253, 0.08);
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  font-family: var(--font-body);
  color: var(--color-text);
  background: var(--color-bg);
  line-height: 1.6;
}

h1, h2, h3 {
  font-family: var(--font-heading);
  font-weight: 700;
  letter-spacing: 0.01em;
  color: var(--color-navy);
  line-height: 1.2;
  margin-top: 0;
}

a {
  color: var(--color-primary);
  text-decoration: none;
}

a:hover {
  text-decoration: underline;
}

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

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

/* ---- Scroll-reveal ---- */

.reveal {
  opacity: 0;
  transform: translateY(24px);
  transition: opacity 0.6s ease, transform 0.6s ease;
}

.reveal.is-visible {
  opacity: 1;
  transform: translateY(0);
}

.grid.reveal .card {
  transition: opacity 0.5s ease, transform 0.5s ease;
}

.grid.reveal:not(.is-visible) .card {
  opacity: 0;
  transform: translateY(16px);
}

.grid.reveal .card:nth-child(2) {
  transition-delay: 0.1s;
}

.grid.reveal .card:nth-child(3) {
  transition-delay: 0.2s;
}

/* ---- Header / nav ---- */

.site-header {
  background: var(--color-navy);
  position: sticky;
  top: 0;
  z-index: 100;
  box-shadow: 0 0 0 rgba(0, 0, 0, 0);
  transition: box-shadow var(--transition);
}

.site-header--scrolled {
  box-shadow: 0 4px 16px rgba(0, 0, 0, 0.25);
}

.nav {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 1rem 1.5rem;
  max-width: var(--max-width);
  margin: 0 auto;
}

.nav__brand {
  color: #fff;
  font-family: var(--font-heading);
  font-size: 1.5rem;
  font-weight: 700;
  letter-spacing: 0.04em;
}

.nav__brand:hover {
  text-decoration: none;
}

.nav__toggle {
  display: none;
  background: none;
  border: none;
  color: #fff;
  font-size: 1.6rem;
  cursor: pointer;
}

.nav__links {
  display: flex;
  gap: 1.75rem;
  list-style: none;
  margin: 0;
  padding: 0;
}

.nav__links a {
  display: inline-block;
  color: var(--color-text-light);
  font-weight: 500;
  padding-bottom: 3px;
  border-bottom: 2px solid transparent;
  transition: border-color var(--transition), color var(--transition);
}

.nav__links a:hover,
.nav__links a[aria-current="page"] {
  color: #fff;
  text-decoration: none;
  border-bottom-color: var(--color-primary-light);
}

/* ---- Hero ---- */

.hero {
  position: relative;
  background-image:
    repeating-linear-gradient(0deg, var(--grid-line) 0, var(--grid-line) 1px, transparent 1px, transparent 40px),
    repeating-linear-gradient(90deg, var(--grid-line) 0, var(--grid-line) 1px, transparent 1px, transparent 40px),
    linear-gradient(135deg, var(--color-navy), var(--color-primary)),
    url("../images/hero-plant.jpg");
  background-size: auto, auto, cover, cover;
  background-position: center, center, center, center;
  background-repeat: repeat, repeat, no-repeat, no-repeat;
  background-blend-mode: normal, normal, multiply, normal;
  color: #fff;
  padding: 6rem 1.5rem;
  text-align: center;
}

.hero--page {
  padding: 3.5rem 1.5rem;
}

.hero h1 {
  color: #fff;
  font-size: clamp(1.8rem, 4vw, 2.8rem);
  max-width: 850px;
  margin: 0 auto 1rem;
}

.hero p {
  max-width: 650px;
  margin: 0 auto;
  font-size: 1.15rem;
  color: var(--color-text-light);
}

.btn {
  display: inline-block;
  margin-top: 1.75rem;
  padding: 0.8rem 1.8rem;
  background: var(--color-primary-light);
  color: var(--color-navy);
  font-weight: 600;
  border-radius: var(--radius);
  transition: transform var(--transition), box-shadow var(--transition);
}

.btn:hover {
  text-decoration: none;
  transform: translateY(-2px);
  box-shadow: var(--shadow);
}

/* ---- Sections ---- */

.section {
  padding: 4.5rem 1.5rem;
}

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

.section-title {
  text-align: center;
  margin-bottom: 2.5rem;
}

.section-title p {
  color: #56707f;
  max-width: 650px;
  margin: 0.5rem auto 0;
}

/* ---- Cards / grid ---- */

.grid {
  display: grid;
  gap: 1.75rem;
  grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
  max-width: var(--max-width);
  margin: 0 auto;
}

.card {
  background: #fff;
  border: 1px solid #e1eef5;
  border-radius: var(--radius);
  padding: 1.75rem;
  box-shadow: var(--shadow);
  transition: transform var(--transition), box-shadow var(--transition), border-color var(--transition);
}

.card:hover {
  transform: translateY(-6px);
  box-shadow: var(--shadow-lift);
  border-color: var(--color-primary-light);
}

.card-icon {
  width: 40px;
  height: 40px;
  margin-bottom: 1rem;
  color: var(--color-primary);
}

.card-icon svg {
  width: 100%;
  height: 100%;
}

.card h3 {
  margin-bottom: 0.5rem;
}

/* ---- Image-backed feature block (about / services) ---- */

.feature {
  position: relative;
  border-radius: var(--radius);
  overflow: hidden;
  color: #fff;
  padding: 2.5rem;
  background-image:
    repeating-linear-gradient(0deg, var(--grid-line) 0, var(--grid-line) 1px, transparent 1px, transparent 32px),
    repeating-linear-gradient(90deg, var(--grid-line) 0, var(--grid-line) 1px, transparent 1px, transparent 32px),
    linear-gradient(rgba(11, 57, 84, 0.72), rgba(11, 57, 84, 0.72)),
    var(--bg-image, none);
  background-size: auto, auto, cover, cover;
  background-position: center, center, center, center;
  background-repeat: repeat, repeat, no-repeat, no-repeat;
  background-color: var(--color-navy);
  transition: filter var(--transition), transform var(--transition);
}

a.feature:hover {
  filter: brightness(1.08);
  transform: translateY(-3px);
}

.feature h2,
.feature h3 {
  color: #fff;
}

.feature--pulpit {
  --bg-image: url("../images/pulpit-bg.jpg");
}

.feature--cabin {
  --bg-image: url("../images/electrical-cabin.jpg");
}

.feature--product {
  --bg-image: url("../images/steel-bundles.jpg");
}

.feature--coils {
  --bg-image: url("../images/steel-coils.jpg");
}

/* ---- Contact ---- */

.contact-grid {
  display: grid;
  gap: 2.5rem;
  grid-template-columns: 1fr 1fr;
  max-width: var(--max-width);
  margin: 0 auto;
}

.contact-info dt {
  font-weight: 600;
  color: var(--color-navy);
  margin-top: 1rem;
}

form {
  display: grid;
  gap: 1rem;
}

label {
  font-weight: 600;
  font-size: 0.9rem;
}

input,
textarea {
  width: 100%;
  padding: 0.7rem;
  border: 1px solid #c7dbe6;
  border-radius: var(--radius);
  font-family: inherit;
  font-size: 1rem;
  transition: border-color var(--transition), box-shadow var(--transition);
}

input:focus,
textarea:focus {
  outline: none;
  border-color: var(--color-primary);
  box-shadow: 0 0 0 3px rgba(30, 111, 168, 0.15);
}

textarea {
  resize: vertical;
  min-height: 140px;
}

/* ---- Footer ---- */

.site-footer {
  background: var(--color-navy);
  color: var(--color-text-light);
  padding: 2.5rem 1.5rem 1.5rem;
  font-size: 0.9rem;
}

.site-footer .container {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  gap: 1.5rem;
}

.site-footer a {
  color: var(--color-text-light);
  transition: color var(--transition);
}

.site-footer a:hover {
  color: var(--color-primary-light);
}

.site-footer .legal {
  width: 100%;
  border-top: 1px solid rgba(255, 255, 255, 0.15);
  margin-top: 1.5rem;
  padding-top: 1rem;
  text-align: center;
  color: #9fc3d6;
  font-size: 0.85rem;
}

/* ---- Responsive nav ---- */

@media (max-width: 720px) {
  .nav__toggle {
    display: block;
  }

  .nav__links {
    display: none;
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    background: var(--color-navy);
    flex-direction: column;
    padding: 1rem 1.5rem;
    gap: 1rem;
  }

  .nav__links.is-open {
    display: flex;
  }

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

/* ---- Reduced motion ---- */

@media (prefers-reduced-motion: reduce) {
  html {
    scroll-behavior: auto;
  }

  .reveal,
  .grid.reveal .card,
  .card,
  .btn,
  a.feature,
  .site-header {
    transition: none !important;
    opacity: 1 !important;
    transform: none !important;
  }
}
