/* =========================================================
   Innova Construction Chemicals — main stylesheet
   ---------------------------------------------------------
   1. Design tokens (colors, fonts, spacing)
   2. Base / reset
   3. Layout helpers (container, section, grid)
   4. Buttons
   5. Header + navigation (incl. mobile menu)
   6. Page hero (inner pages) + home hero
   7. Home sections
   8. About page
   9. Products page
   10. Contact page
   11. CTA band + newsletter
   12. Footer
   13. Scroll reveal animation
   14. Responsive breakpoints
   ========================================================= */

/* ---------- 1. Design tokens ---------- */
:root {
  --yellow: #ffcc00;          /* brand yellow (active nav, consultant band) */
  --yellow-dark: #e6b800;
  --black: #0b0505;           /* buttons, dark bands */
  --text: #2b2b2b;
  --muted: #555555;           /* body copy grey (passes 4.5:1 on white) */
  --on-yellow: #4d3b00;       /* body text on yellow (passes 4.5:1) */
  --bg: #ffffff;
  --bg-alt: #f5f5f5;          /* footer, form fields */
  --border: #e3e3e3;
  --white: #ffffff;

  --font-heading: "Lexend", "Segoe UI", Arial, sans-serif;
  --font-body: "Noto Sans", "Segoe UI", Arial, sans-serif;

  /* spacing scale */
  --space-1: 0.5rem;
  --space-2: 1rem;
  --space-3: 1.5rem;
  --space-4: 2rem;
  --space-5: 3rem;
  --space-6: 4.5rem;
  --space-7: 6rem;

  --container: 1170px;
  --radius: 8px;
  --transition: 0.25s ease;
}

/* ---------- 2. Base / reset ---------- */
*,
*::before,
*::after { box-sizing: border-box; }

html { scroll-behavior: smooth; }

body {
  margin: 0;
  font-family: var(--font-body);
  font-size: 15px;
  line-height: 1.7;
  color: var(--text);
  background: var(--bg);
  -webkit-font-smoothing: antialiased;
}

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

h1, h2, h3, h4 {
  overflow-wrap: break-word;
  font-family: var(--font-heading);
  color: var(--black);
  line-height: 1.25;
  margin: 0 0 var(--space-2);
  font-weight: 600;
}

p { margin: 0 0 var(--space-2); }

a { color: inherit; text-decoration: none; transition: color var(--transition); }
a:hover { color: var(--yellow-dark); }

ul { margin: 0; padding: 0; }

/* Visible keyboard focus everywhere */
:focus-visible { outline: 3px solid var(--yellow); outline-offset: 2px; }

.visually-hidden {
  position: absolute !important;
  width: 1px; height: 1px;
  overflow: hidden; clip: rect(0 0 0 0);
  white-space: nowrap;
}

/* Skip link for keyboard users */
.skip-link {
  position: absolute; left: 1rem; top: -100px; z-index: 1000;
  background: var(--black); color: var(--white);
  padding: 0.6rem 1rem;
}
.skip-link:focus { top: 1rem; color: var(--white); }

/* ---------- 3. Layout helpers ---------- */
.container {
  width: 100%;
  max-width: var(--container);
  margin: 0 auto;
  padding: 0 20px;
}

.section { padding: var(--space-7) 0; }
.section--tight { padding: var(--space-6) 0; }
.section--alt { background: var(--bg-alt); }
.section--divider { border-top: 1px solid #cfcfcf; }

.section-heading { text-align: center; margin-bottom: var(--space-5); }
.section-heading .eyebrow {
  display: block;
  font-family: var(--font-body);
  font-weight: 600;
  font-size: 0.95rem;
  color: var(--muted);
  margin-bottom: var(--space-1);
}
.section-heading h2 { font-size: clamp(1.5rem, 2.5vw, 2rem); margin: 0; }

.two-col {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: var(--space-5);
  align-items: center;
}

/* ---------- 4. Buttons ---------- */
.btn {
  display: inline-block;
  font-family: var(--font-body);
  font-size: 0.9rem;
  font-weight: 500;
  padding: 0.75rem 2.2rem;
  border: 1px solid var(--black);
  border-radius: 2px;
  cursor: pointer;
  transition: background var(--transition), color var(--transition),
              border-color var(--transition), transform var(--transition);
  text-align: center;
}
.btn:hover { transform: translateY(-2px); }

.btn--dark { background: var(--black); color: var(--white); }
.btn--dark:hover { background: var(--yellow); border-color: var(--yellow); color: var(--black); }

.btn--outline { background: var(--white); color: var(--black); }
.btn--outline:hover { background: var(--black); color: var(--white); }

.btn--light { background: var(--white); color: var(--black); border-color: var(--white); }
.btn--light:hover { background: var(--yellow); border-color: var(--yellow); color: var(--black); }

.btn-row { display: flex; gap: var(--space-2); justify-content: center; flex-wrap: wrap; }

/* ---------- 5. Header + navigation ---------- */
.site-header {
  position: absolute;
  top: 22px; left: 0; right: 0;
  z-index: 100;
}

.header-bar {
  background: var(--white);
  display: flex;
  align-items: stretch;
  justify-content: space-between;
  min-height: 68px;
  padding: 0 32px;
  position: relative;
  box-shadow: 0 6px 24px rgba(0, 0, 0, 0.08);
}

.logo { display: flex; align-items: center; padding: 8px 0; }
.logo img { height: 48px; width: auto; }

.main-nav { display: flex; align-items: stretch; }
.main-nav ul { list-style: none; display: flex; align-items: stretch; }
.main-nav .nav-call { display: none; }   /* phone link shown inside the mobile menu only */
.main-nav a {
  display: flex; align-items: center;
  height: 100%;
  padding: 0 22px;
  font-size: 0.95rem;
  color: var(--text);
  transition: background var(--transition), color var(--transition);
}
.main-nav a:hover { color: var(--black); background: #fff6cc; }
.main-nav a[aria-current="page"] { background: var(--yellow); color: var(--black); font-weight: 500; }

.header-call { display: flex; align-items: center; font-size: 0.9rem; white-space: nowrap; }
.header-call a { font-weight: 700; margin-left: 4px; }

/* Hamburger button (hidden on desktop) */
.nav-toggle {
  display: none;
  align-self: center;
  width: 44px; height: 44px;
  background: none; border: 0; cursor: pointer;
  padding: 10px;
}
.nav-toggle span {
  display: block; height: 2px; background: var(--black);
  margin: 5px 0; transition: transform var(--transition), opacity var(--transition);
}
.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); }

/* ---------- 6. Heroes ---------- */
/* Inner-page hero: photo + dark overlay + centred title */
.page-hero {
  position: relative;
  min-height: 500px;
  display: flex; align-items: center; justify-content: center;
  text-align: center;
  overflow: hidden;
  background: #333;
}
.page-hero--short { min-height: 400px; }
.hero-bg {
  position: absolute; inset: 0;
  width: 100%; height: 100%;
  object-fit: cover;
}
.page-hero::after,
.home-hero::after {
  content: "";
  position: absolute; inset: 0;
  background: rgba(0, 0, 0, 0.55);
}
.page-hero h1 {
  position: relative; z-index: 1;
  color: var(--white);
  font-size: clamp(2.5rem, 6vw, 4rem);
  margin: 60px 0 0;
}

/* Home hero */
.home-hero {
  position: relative;
  min-height: 760px;
  display: flex; align-items: center; justify-content: center;
  text-align: center;
  overflow: hidden;
  background: #333;
}
.home-hero__content { position: relative; z-index: 1; color: var(--white); padding: 120px 20px 60px; }
.since-badge {
  display: inline-flex; flex-direction: column; align-items: center;
  border: 3px solid var(--white);
  border-radius: 50px;
  padding: 6px 28px 10px;
  margin-bottom: var(--space-1);
}
.since-badge small { font-family: var(--font-heading); font-size: 0.8rem; letter-spacing: 0.15em; font-weight: 600; }
.since-badge span { font-family: "Dancing Script", cursive; font-size: 2.6rem; line-height: 1; font-weight: 700; }
.home-hero__tagline { font-weight: 600; font-size: 1rem; margin-bottom: var(--space-3); }
.home-hero h1 {
  color: var(--white);
  font-size: clamp(2.2rem, 5vw, 3.8rem);
  line-height: 1.35;
  margin: 0;
}

/* ---------- 7. Home sections ---------- */
/* Services band: black strip with white cards overlapping below */
.services-band { background: var(--black); padding: var(--space-3) 0 0; }
.services-band h2 { color: var(--white); text-align: center; font-size: 1.6rem; margin-bottom: var(--space-4); }
.services-wrap { padding-bottom: var(--space-6); background: linear-gradient(var(--black) 0 120px, var(--white) 120px); }

.service-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: var(--space-4);
  max-width: 1000px;
  margin: 0 auto var(--space-5);
}
.service-card {
  background: var(--white);
  text-align: center;
  padding: var(--space-5) var(--space-4);
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.08);
  transition: transform var(--transition), box-shadow var(--transition);
}
.service-card:hover { transform: translateY(-6px); box-shadow: 0 16px 40px rgba(0, 0, 0, 0.14); }
.service-card svg { width: 56px; height: 56px; margin: 0 auto var(--space-2); color: var(--black); }
.service-card h3 { font-family: var(--font-body); font-size: 1.05rem; font-weight: 700; }
.service-card p { color: var(--muted); font-size: 0.9rem; margin: 0; }

/* Quality assurance */
.qa h2 { font-size: 1.8rem; text-transform: uppercase; letter-spacing: 0.02em; }
.qa p { color: var(--muted); }
.qa-cert { width: 100%; max-width: 380px; margin: 0 auto; box-shadow: 0 10px 30px rgba(0, 0, 0, 0.15); }

/* Consultant band (home + about) */
.consultant { background: var(--yellow); padding: var(--space-4) 0; }
.consultant .two-col { align-items: center; }
.consultant__photo {
  max-width: 280px; margin: 0 auto;
  border: 2px solid var(--black); border-radius: var(--radius);
  overflow: hidden;
}
.consultant__text { text-align: left; max-width: 480px; }
.consultant__text h2 { text-align: center; font-size: 1.9rem; margin-bottom: 0.25rem; }
.consultant__text .role { text-align: center; font-family: var(--font-heading); font-weight: 600; font-size: 1.3rem; color: var(--black); margin-bottom: var(--space-3); }
.consultant__text p { color: var(--on-yellow); font-size: 0.95rem; }

/* Project lists */
.projects h2 { font-size: 1.8rem; }
.project-list { list-style: disc; padding-left: 1.2rem; color: var(--muted); font-size: 0.92rem; line-height: 1.9; }
.project-collage { width: 100%; max-width: 460px; margin: 0 auto; border-radius: 16px; overflow: hidden; }
.projects .btn { margin-top: var(--space-3); }

/* Category cards (home "Our Products") */
.category-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: var(--space-4); margin-bottom: var(--space-5); }
.category-card {
  border: 1px solid #9a9a9a; border-radius: var(--radius);
  padding: var(--space-4);
  text-align: center;
  transition: transform var(--transition), box-shadow var(--transition);
}
.category-card:hover { transform: translateY(-6px); box-shadow: 0 14px 34px rgba(0, 0, 0, 0.12); }
.category-card img { aspect-ratio: 6 / 7; object-fit: contain; margin: 0 auto var(--space-3); }
.category-card h3 { font-family: var(--font-body); font-size: 1.05rem; font-weight: 600; margin: 0; }

/* ---------- 8. About page ---------- */
.about-intro h2 { font-size: 1.8rem; text-transform: uppercase; margin-bottom: var(--space-1); }
.about-intro p { color: var(--muted); }

.accordion { border: 1px solid var(--border); }
.accordion details + details { border-top: 1px solid var(--border); }
.accordion summary {
  list-style: none;
  display: flex; justify-content: space-between; align-items: center;
  padding: 0.85rem 1rem;
  font-weight: 700; font-size: 0.9rem; text-transform: uppercase;
  cursor: pointer;
  color: var(--black);
}
.accordion summary::-webkit-details-marker { display: none; }
.accordion summary::after { content: "+"; font-size: 1.4rem; line-height: 1; font-weight: 400; }
.accordion details[open] summary { border-bottom: 1px solid var(--border); }
.accordion details[open] summary::after { content: "\2212"; }
.accordion .panel { padding: 1rem 1rem 1.5rem; color: var(--muted); font-size: 0.92rem; }
.accordion .panel p:last-child { margin-bottom: 0; }

/* ---------- 9. Products page ---------- */
.product-grid {
  display: grid;
  grid-template-columns: repeat(6, 1fr);   /* 3 cards on row 1, 2 wider cards on row 2 */
  gap: 22px;
}
.product-card { grid-column: span 2; }
.product-card:nth-child(4),
.product-card:nth-child(5) { grid-column: span 3; }

.product-card {
  border: 1px solid #8c8c8c; border-radius: var(--radius);
  padding: var(--space-4) var(--space-3) var(--space-5);
  text-align: center;
  display: flex; flex-direction: column; align-items: center;
  transition: box-shadow var(--transition), border-color var(--transition), transform var(--transition);
}
.product-card:hover { border-color: var(--black); box-shadow: 0 14px 34px rgba(0, 0, 0, 0.12); transform: translateY(-4px); }
.product-card img { width: 100%; max-width: 280px; aspect-ratio: 1 / 1; object-fit: contain; margin-bottom: var(--space-3); }
.product-card h3 { font-size: 1.35rem; letter-spacing: 0.04em; text-transform: uppercase; margin-bottom: var(--space-1); }
.product-card p { color: var(--muted); font-size: 0.9rem; max-width: 34ch; }
.product-card .btn { margin-top: auto; }

/* ---------- 10. Contact page ---------- */
.contact-grid { display: grid; grid-template-columns: 1fr 1.5fr; gap: var(--space-5); align-items: start; }

.contact-info-card { background: var(--black); color: var(--white); padding: var(--space-5) var(--space-5) var(--space-4); }
.contact-info-card h2 { color: var(--white); font-size: 1.5rem; margin-bottom: var(--space-3); }
.contact-info-list { list-style: none; }
.contact-info-list li { display: flex; gap: 1.2rem; align-items: flex-start; font-weight: 700; margin-bottom: 1.2rem; }
.contact-info-list svg { width: 20px; height: 20px; flex-shrink: 0; margin-top: 4px; }
.contact-info-list a:hover { color: var(--yellow); }

/* Map placeholder (swap for a Google Maps embed) */
.map-placeholder {
  aspect-ratio: 447 / 360;
  background: repeating-linear-gradient(45deg, #ececec 0 14px, #e2e2e2 14px 28px);
  display: flex; flex-direction: column; align-items: center; justify-content: center;
  text-align: center; color: var(--muted); font-size: 0.9rem; padding: 1rem;
}
.map-placeholder iframe { width: 100%; height: 100%; border: 0; }

.contact-form-card { border: 1px solid #efefef; padding: var(--space-5); }
.contact-form-card h2 { font-size: 1.9rem; margin-bottom: var(--space-4); }

.form-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 1.6rem 1.1rem; }
.form-field--full { grid-column: 1 / -1; }

.form-field input,
.form-field select,
.form-field textarea {
  width: 100%;
  font: inherit; font-size: 0.92rem;
  color: var(--text);
  background: var(--bg-alt);
  border: 1px solid transparent;
  padding: 0.85rem 0.9rem;
  border-radius: 0;
  transition: border-color var(--transition), background var(--transition);
}
.form-field select { appearance: none; background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='8' viewBox='0 0 12 8'%3E%3Cpath d='M1 1l5 5 5-5' stroke='%23333' stroke-width='1.5' fill='none'/%3E%3C/svg%3E"); background-repeat: no-repeat; background-position: right 1rem center; cursor: pointer; }
.form-field textarea { min-height: 200px; resize: vertical; }
.form-field input:focus,
.form-field select:focus,
.form-field textarea:focus { outline: none; border-color: var(--black); background: var(--white); }
.form-field input::placeholder,
.form-field textarea::placeholder { color: #6b6b6b; }

.form-field.has-error input,
.form-field.has-error textarea { border-color: #b3261e; }
.field-error { display: block; color: #b3261e; font-size: 0.8rem; margin-top: 0.3rem; }

.form-status { margin-top: 1rem; font-size: 0.9rem; font-weight: 600; }
.form-status.is-success { color: #1f6f2b; }
.form-status.is-error { color: #b3261e; }

/* ---------- 11. CTA band + newsletter ---------- */
.cta-band,
.newsletter {
  position: relative;
  overflow: hidden;
  color: var(--white);
  background: #333;
}
.cta-band::after,
.newsletter::after { content: ""; position: absolute; inset: 0; background: rgba(0, 0, 0, 0.5); }
.cta-band .container,
.newsletter .container { position: relative; z-index: 1; }

.cta-band { padding: var(--space-7) 0; }
.cta-band__inner { display: flex; align-items: center; justify-content: space-between; gap: var(--space-4); }
.cta-band h2 { color: var(--white); font-family: var(--font-body); font-size: 0.95rem; font-weight: 700; text-transform: uppercase; margin-bottom: var(--space-2); }
.cta-band p { font-weight: 700; max-width: 560px; margin: 0; }

.newsletter { padding: 7.5rem 0; text-align: center; }
.newsletter h2 { color: var(--white); font-size: clamp(1.5rem, 3vw, 2.1rem); margin-bottom: var(--space-3); }
.newsletter-form { display: flex; gap: 18px; max-width: 606px; margin: 0 auto; }
.newsletter-form input {
  flex: 1; font: inherit; padding: 0.85rem 1rem; border: 0; background: var(--bg-alt); color: var(--text);
}
.newsletter-form .btn { border-color: var(--black); text-transform: uppercase; font-weight: 700; }
.newsletter .form-status { color: var(--white); }

/* ---------- 12. Footer ---------- */
.site-footer { background: var(--bg-alt); padding: var(--space-4) 0 var(--space-3); font-size: 0.92rem; }
.footer-grid { display: grid; grid-template-columns: 1fr 1fr 1fr 1fr 1fr; gap: var(--space-4); }
.footer-logo img { max-width: 180px; }
.site-footer h2 { font-size: 1.05rem; margin-bottom: var(--space-2); }
.site-footer ul { list-style: none; }
.site-footer li { margin-bottom: 0.15rem; }
.site-footer a:hover { color: var(--black); text-decoration: underline; }
.footer-label { display: block; font-weight: 700; color: var(--black); }
.footer-block + .footer-block { margin-top: var(--space-3); }
.footer-bottom {
  display: flex; justify-content: space-around; align-items: center;
  margin-top: var(--space-5);
  color: var(--muted); font-size: 0.88rem;
}
.footer-bottom svg { width: 18px; height: 18px; }

/* ---------- 13. Scroll reveal ---------- */
/* Only hidden when JS is running (script.js adds .js to <html>) */
.js .reveal { opacity: 0; transform: translateY(24px); transition: opacity 0.7s ease, transform 0.7s ease; }
.js .reveal.is-visible { opacity: 1; transform: none; }

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .js .reveal { opacity: 1; transform: none; transition: none; }
  .btn, .service-card, .category-card, .product-card { transition: none; }
}

/* ---------- 14. Responsive ---------- */
/* Tablet landscape & below */
@media (max-width: 1024px) {
  .header-bar { padding: 0 20px; }
  .main-nav a { padding: 0 14px; }
  .footer-grid { grid-template-columns: repeat(3, 1fr); }
  .footer-logo { grid-column: 1 / -1; }
}

/* Tablet (≤ 900px): switch to hamburger menu */
@media (max-width: 900px) {
  .nav-toggle { display: block; }
  .header-call { display: none; }
  .main-nav {
    position: absolute; top: 100%; left: 0; right: 0;
    background: var(--white);
    box-shadow: 0 12px 24px rgba(0, 0, 0, 0.12);
    display: none;
  }
  .main-nav.is-open { display: block; }
  .main-nav ul { flex-direction: column; }
  .main-nav a { padding: 0.9rem 20px; border-top: 1px solid var(--border); }
  .main-nav .nav-call { display: block; }
}

@media (max-width: 768px) {
  .section { padding: var(--space-6) 0; }
  .two-col,
  .contact-grid { grid-template-columns: minmax(0, 1fr); gap: var(--space-4); }
  .qa h2, .projects h2, .about-intro h2 { font-size: 1.45rem; }
  .two-col--reverse-mobile > :first-child { order: 2; }
  .service-grid,
  .category-grid { grid-template-columns: 1fr; max-width: 420px; margin-left: auto; margin-right: auto; }
  .services-wrap { background: linear-gradient(var(--black) 0 80px, var(--white) 80px); }
  .product-grid { grid-template-columns: 1fr 1fr; }
  .product-card,
  .product-card:nth-child(4),
  .product-card:nth-child(5) { grid-column: span 1; }
  .product-card:nth-child(5) { grid-column: 1 / -1; }
  .cta-band__inner { flex-direction: column; align-items: flex-start; }
  .page-hero { min-height: 380px; }
  .home-hero { min-height: 600px; }
  .consultant__text h2,
  .consultant__text .role { text-align: left; }
  .contact-info-card,
  .contact-form-card { padding: var(--space-4) var(--space-3); }
}

/* Phone (≤ 480px) */
@media (max-width: 480px) {
  body { font-size: 14.5px; }
  .site-header { top: 12px; }
  .container { padding: 0 16px; }
  .header-bar { padding: 0 12px 0 16px; }
  .logo img { height: 40px; }
  .page-hero { min-height: 320px; }
  .product-grid { grid-template-columns: 1fr; }
  .product-card:nth-child(5) { grid-column: auto; }
  .form-grid { grid-template-columns: 1fr; }
  .newsletter-form { flex-direction: column; }
  .footer-grid { grid-template-columns: 1fr 1fr; }
  .footer-bottom { flex-direction: column; gap: 0.6rem; text-align: center; }
  .btn-row .btn { width: 100%; }
}
