/*
Theme Name: Khanda Group
Theme URI: https://khandaservices.co.za
Author: Khanda Group
Author URI: https://khandaservices.co.za
Description: Custom marketing theme for Khanda Group - turnkey RF communication, PTT radio, two-way radio and Leaky Feeder security & mining communication solutions. Engineering Intelligent Connections.
Version: 1.1
License: GNU General Public License v2 or later
License URI: http://www.gnu.org/licenses/gpl-2.0.html
Text Domain: khanda-group
*/

@import url("https://fonts.googleapis.com/css2?family=Barlow:wght@400;500;600;700;800&display=swap");

:root {
  --navy: #022457;
  --navy-dark: #011737;
  --blue: #0040b0;
  --gold: #c8931e;
  --amber: #ffb32f;
  --amber-dark: #fa8501;
  --text: #0f3045;
  --white: #ffffff;
  --grey: #f4f4f4;
  --line: rgba(9, 33, 67, 0.1);
  --shadow: 0 20px 50px rgba(9, 33, 67, 0.12);
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  font-family: "Barlow", "Segoe UI", Arial, sans-serif;
  background: var(--white);
  color: var(--text);
  line-height: 1.6;
}

body.nav-open {
  overflow: hidden;
}

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

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

button,
input,
select,
textarea {
  font: inherit;
}

h1,
h2,
h3,
h4,
h5,
h6 {
  margin: 0;
  color: var(--navy);
  font-family: "Barlow", "Segoe UI", Arial, sans-serif;
}

h1,
h2 {
  font-size: 52px;
  font-weight: 900;
  line-height: 1.1;
}

h2 {
  font-weight: 800;
}

h3 {
  font-size: 26px;
  font-weight: 500;
  line-height: 1.2;
}

h4.eyebrow,
.eyebrow {
  display: block;
  margin: 0 0 14px;
  color: var(--blue);
  font-size: 15px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 1.5px;
}

p {
  margin: 0 0 16px;
  color: var(--text);
  opacity: 0.85;
}

.container {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 28px;
}

@media (max-width: 1024px) {
  h1,
  h2 {
    font-size: 40px;
  }
}

@media (max-width: 767px) {
  h1,
  h2 {
    font-size: 32px;
  }
}

/* ---------- Buttons ---------- */

.btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 1em 2.3em;
  border: 0;
  border-radius: 10px;
  background: var(--amber);
  color: var(--navy);
  font-weight: 700;
  font-size: 14px;
  text-transform: uppercase;
  letter-spacing: 0.6px;
  cursor: pointer;
  transition: background 0.2s ease, transform 0.2s ease;
}

.btn:hover {
  background: var(--amber-dark);
  color: var(--white);
  transform: translateY(-1px);
}

.btn.ghost {
  background: transparent;
  border: 2px solid var(--white);
  color: var(--white);
}

.btn.ghost:hover {
  background: var(--white);
  color: var(--navy);
}

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

.btn.navy:hover {
  background: var(--amber);
  color: var(--navy);
}

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

.site-header {
  position: sticky;
  top: 0;
  z-index: 60;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  padding: 10px 28px;
  background: var(--white);
  border-bottom: 1px solid rgba(2, 36, 87, 0.08);
  box-shadow: 0 6px 24px rgba(2, 36, 87, 0.08);
}

.brand {
  display: flex;
  align-items: center;
  color: var(--navy);
}

.brand img {
  display: block;
  height: 58px;
  width: auto;
}

.main-nav {
  display: flex;
  align-items: center;
  gap: 6px;
}

.main-nav a {
  padding: 10px 15px;
  color: var(--navy);
  font-size: 13px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  border-radius: 6px;
}

.main-nav a:hover,
.main-nav a.active {
  color: var(--gold);
}

.header-actions {
  display: flex;
  align-items: center;
  gap: 14px;
}

.nav-toggle {
  display: none;
  flex-direction: column;
  gap: 5px;
  width: 40px;
  height: 40px;
  align-items: center;
  justify-content: center;
  border: 0;
  background: transparent;
  cursor: pointer;
}

.nav-toggle span {
  width: 22px;
  height: 2px;
  background: var(--navy);
}

@media (max-width: 1024px) {
  .main-nav {
    position: fixed;
    inset: 0 0 0 auto;
    width: min(320px, 84vw);
    flex-direction: column;
    align-items: flex-start;
    gap: 2px;
    padding: 100px 24px 24px;
    background: var(--white);
    box-shadow: -12px 0 40px rgba(2, 36, 87, 0.16);
    transform: translateX(100%);
    transition: transform 0.28s ease;
    overflow-y: auto;
  }

  .main-nav.is-open {
    transform: translateX(0);
  }

  .main-nav a {
    width: 100%;
    padding: 14px 4px;
    border-bottom: 1px solid rgba(2, 36, 87, 0.08);
  }

  .nav-toggle {
    display: flex;
  }
}

/* ---------- Hero slider (home) ---------- */

.hero-slider {
  position: relative;
  min-height: 560px;
  display: grid;
  background: var(--navy);
  overflow: hidden;
}

.hero-slide {
  grid-area: 1 / 1;
  display: none;
  align-items: center;
  min-height: 560px;
  padding: 60px 28px;
  background:
    linear-gradient(105deg, rgba(5, 24, 51, 0.88) 0%, rgba(9, 33, 67, 0.62) 55%, rgba(9, 33, 67, 0.3) 100%),
    var(--navy) center / cover no-repeat;
}

.hero-slide[data-bg] {
  background-image:
    linear-gradient(105deg, rgba(5, 24, 51, 0.88) 0%, rgba(9, 33, 67, 0.62) 55%, rgba(9, 33, 67, 0.3) 100%),
    var(--slide-image);
  background-size: cover;
  background-position: center;
}

.hero-slide.active {
  display: flex;
}

.hero-slide .container {
  width: 100%;
}

.hero-slide h1 {
  max-width: 720px;
  color: var(--white);
  text-transform: uppercase;
}

.hero-slide h1 em {
  display: block;
  color: var(--amber);
  font-style: normal;
}

.hero-dots {
  position: absolute;
  left: 50%;
  bottom: 26px;
  z-index: 5;
  display: flex;
  gap: 10px;
  transform: translateX(-50%);
}

.hero-dots button {
  width: 10px;
  height: 10px;
  padding: 0;
  border: 0;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.35);
  cursor: pointer;
}

.hero-dots button.active {
  background: var(--amber);
}

/* ---------- Page hero (inner pages) ---------- */

.page-hero {
  display: flex;
  align-items: center;
  min-height: 380px;
  padding: 70px 28px;
  background:
    linear-gradient(120deg, rgba(5, 24, 51, 0.9), rgba(9, 33, 67, 0.66)),
    var(--navy) center / cover no-repeat;
  text-align: center;
}

.page-hero[data-bg] {
  background-image:
    linear-gradient(120deg, rgba(5, 24, 51, 0.9), rgba(9, 33, 67, 0.66)),
    var(--hero-image);
  background-size: cover;
  background-position: center;
}

.page-hero .container {
  width: 100%;
}

.page-hero h1 {
  color: var(--white);
  text-transform: uppercase;
}

.page-hero p {
  max-width: 620px;
  margin: 14px auto 0;
  color: rgba(255, 255, 255, 0.78);
}

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

.section {
  padding: 84px 28px;
}

.section.grey {
  background: var(--grey);
}

.section-heading {
  max-width: 760px;
  margin: 0 auto 48px;
  text-align: center;
}

.section-heading.left {
  margin: 0 0 48px;
  text-align: left;
}

/* ---------- Feature grid ---------- */

.feature-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 22px;
}

.feature-card {
  padding: 28px 24px;
  border-radius: 16px;
  background: var(--white);
  box-shadow: var(--shadow);
}

.feature-card .icon {
  display: grid;
  place-items: center;
  width: 48px;
  height: 48px;
  margin-bottom: 16px;
  border-radius: 12px;
  background: rgba(0, 64, 176, 0.08);
  color: var(--blue);
  font-weight: 800;
}

.feature-card h3 {
  margin-bottom: 8px;
  font-size: 18px;
}

.feature-card p {
  margin: 0;
  font-size: 14px;
}

/* ---------- Product grid ---------- */

.product-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 22px;
}

.product-card {
  display: flex;
  flex-direction: column;
  padding: 24px;
  border-radius: 16px;
  background: var(--white);
  box-shadow: var(--shadow);
  text-align: center;
}

.product-card .product-image {
  display: grid;
  place-items: center;
  height: 200px;
  margin-bottom: 18px;
  border-radius: 12px;
  background: var(--grey);
  overflow: hidden;
}

.product-card .product-image img {
  width: 100%;
  height: 100%;
  object-fit: contain;
  padding: 14px;
}

.product-card h3 {
  margin-bottom: 6px;
  font-size: 18px;
}

.product-card p {
  flex: 1;
  margin: 0 0 18px;
  font-size: 13px;
}

.product-card .btn {
  align-self: center;
  padding: 0.8em 1.8em;
  font-size: 12px;
}

/* ---------- How it works (mining component grid) ---------- */

.component-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 18px;
}

.component-card {
  padding: 20px;
  border-radius: 14px;
  background: var(--white);
  box-shadow: var(--shadow);
  text-align: center;
}

.component-card .product-image {
  display: grid;
  place-items: center;
  height: 150px;
  margin-bottom: 14px;
  border-radius: 10px;
  background: var(--grey);
}

.component-card .product-image img {
  width: 100%;
  height: 100%;
  object-fit: contain;
  padding: 12px;
}

.component-card strong {
  display: block;
  color: var(--navy);
  font-size: 15px;
}

.component-card span {
  display: block;
  margin: 2px 0 8px;
  color: var(--blue);
  font-size: 11px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

.component-card p {
  margin: 0 0 12px;
  font-size: 13px;
}

.component-card .btn {
  padding: 0.65em 1.4em;
  font-size: 11px;
}

/* ---------- Industry photo cards ---------- */

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

.photo-card {
  position: relative;
  display: block;
  height: 280px;
  border-radius: 18px;
  overflow: hidden;
  box-shadow: var(--shadow);
}

.photo-card img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.45s ease;
}

.photo-card:hover img {
  transform: scale(1.06);
}

.photo-card .photo-caption {
  position: absolute;
  inset: auto 0 0;
  padding: 44px 22px 20px;
  background: linear-gradient(to top, rgba(5, 24, 51, 0.92), rgba(5, 24, 51, 0));
  color: var(--white);
}

.photo-card .photo-caption strong {
  display: block;
  font-size: 19px;
  font-weight: 800;
}

.photo-card .photo-caption span {
  display: block;
  margin-top: 3px;
  color: rgba(255, 255, 255, 0.75);
  font-size: 13px;
}

@media (max-width: 1024px) {
  .photo-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (max-width: 640px) {
  .photo-grid {
    grid-template-columns: 1fr;
  }
}

/* ---------- Two column layout ---------- */

.split {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 56px;
  align-items: center;
}

.split img {
  border-radius: 20px;
  box-shadow: var(--shadow);
}

/* ---------- Lists ---------- */

.check-list {
  display: grid;
  gap: 12px;
  margin: 20px 0;
  padding: 0;
  list-style: none;
}

.check-list li {
  position: relative;
  padding-left: 30px;
  font-weight: 500;
}

.check-list li::before {
  content: "\2713";
  position: absolute;
  left: 0;
  top: 0;
  display: grid;
  place-items: center;
  width: 20px;
  height: 20px;
  border-radius: 50%;
  background: var(--amber);
  color: var(--navy);
  font-size: 12px;
  font-weight: 900;
}

/* ---------- Gallery ---------- */

.gallery-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 18px;
}

.gallery-grid img {
  height: 220px;
  width: 100%;
  object-fit: cover;
  border-radius: 16px;
}

/* ---------- Contact / info blocks ---------- */

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

.info-card {
  padding: 28px;
  border-radius: 16px;
  background: var(--grey);
}

.info-card .eyebrow {
  margin-bottom: 10px;
}

.info-card p {
  margin: 0;
  font-size: 14px;
}

/* ---------- Forms ---------- */

.form-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 16px;
  padding: 32px;
  border-radius: 20px;
  background: var(--grey);
}

.form-grid label {
  display: grid;
  gap: 6px;
  font-size: 13px;
  font-weight: 700;
  color: var(--navy);
  text-transform: uppercase;
  letter-spacing: 0.4px;
}

.form-grid label.full {
  grid-column: 1 / -1;
}

.form-grid input,
.form-grid select,
.form-grid textarea {
  padding: 13px 16px;
  border: 1px solid var(--line);
  border-radius: 10px;
  background: var(--white);
  color: var(--text);
}

.form-grid textarea {
  resize: vertical;
}

.form-grid .btn {
  justify-self: start;
}

.form-status {
  grid-column: 1 / -1;
  margin: 0;
  color: var(--navy);
  font-weight: 700;
}

/* ---------- Downloads list ---------- */

.downloads-list {
  display: grid;
  gap: 14px;
}

.downloads-list a {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 18px 24px;
  border-radius: 14px;
  background: var(--grey);
  font-weight: 700;
  color: var(--navy);
}

.downloads-list a:hover {
  background: var(--amber);
}

.downloads-list small {
  color: var(--blue);
  font-weight: 700;
}

.downloads-list a:hover small {
  color: var(--navy);
}

/* ---------- Newsletter band ---------- */

.newsletter-band {
  padding: 40px 28px;
  background: var(--amber);
  text-align: center;
}

.newsletter-band h3 {
  margin-bottom: 18px;
  color: var(--navy);
}

.newsletter-form {
  display: flex;
  max-width: 460px;
  margin: 0 auto;
  gap: 10px;
}

.newsletter-form input {
  flex: 1;
  padding: 13px 18px;
  border: 0;
  border-radius: 10px;
  background: var(--white);
}

.newsletter-form button {
  padding: 13px 28px;
  border: 0;
  border-radius: 10px;
  background: var(--navy);
  color: var(--white);
  font-weight: 700;
  text-transform: uppercase;
  font-size: 13px;
  cursor: pointer;
}

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

.site-footer {
  padding: 64px 28px 28px;
  background: var(--navy);
  border-top: 1px solid rgba(255, 255, 255, 0.08);
  color: rgba(255, 255, 255, 0.7);
}

.footer-brand .brand img {
  height: 74px;
  margin-bottom: 14px;
}

.footer-grid {
  display: grid;
  grid-template-columns: 1.4fr 1fr 1fr;
  gap: 40px;
  padding-bottom: 40px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}

.footer-grid h4 {
  margin-bottom: 16px;
  color: var(--white);
  font-size: 13px;
  text-transform: uppercase;
  letter-spacing: 1px;
}

.footer-brand p {
  max-width: 320px;
  color: rgba(255, 255, 255, 0.6);
  font-size: 14px;
}

.footer-grid nav {
  display: grid;
  gap: 10px;
}

.footer-grid a {
  color: rgba(255, 255, 255, 0.7);
  font-size: 14px;
}

.footer-grid a:hover {
  color: var(--amber);
}

.footer-bottom {
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 12px;
  padding-top: 24px;
  font-size: 13px;
}

.footer-social {
  display: flex;
  gap: 12px;
}

.footer-social a {
  display: grid;
  place-items: center;
  width: 34px;
  height: 34px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.08);
  color: var(--white);
}

.footer-social a:hover {
  background: var(--amber);
  color: var(--navy);
}

/* ---------- Quick contact ---------- */

.quick-contact {
  position: fixed;
  right: 18px;
  bottom: 18px;
  z-index: 55;
  display: grid;
  gap: 10px;
}

.quick-contact a {
  display: grid;
  place-items: center;
  width: 52px;
  height: 52px;
  border-radius: 50%;
  background: var(--navy);
  color: var(--white);
  font-size: 11px;
  font-weight: 800;
  box-shadow: var(--shadow);
}

.quick-contact a:hover {
  background: var(--amber);
  color: var(--navy);
}

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

@media (max-width: 1024px) {
  .feature-grid,
  .product-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .component-grid {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }

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

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

@media (max-width: 640px) {
  .feature-grid,
  .product-grid,
  .gallery-grid,
  .info-grid {
    grid-template-columns: 1fr;
  }

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

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

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

  .newsletter-form {
    flex-direction: column;
  }
}

/* ---------- Reveal animation ---------- */

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

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