/* =========================================================
   JD and Co. — Mining Services Site Stylesheet
   ========================================================= */

/* ----- Reset & base ----- */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

:root {
  --gold:    #d4a017;
  --gold-dk: #b8860b;
  --amber:   #f5a623;
  --dark:    #111418;
  --dark-2:  #1a1f26;
  --dark-3:  #232a33;
  --slate:   #2c3540;
  --text:    #e8eaed;
  --text-2:  #a8b0bb;
  --white:   #ffffff;
  --radius:  10px;
  --shadow:  0 4px 24px rgba(0,0,0,.35);
  --trans:   .25s ease;
  --max-w:   1200px;
}

html { scroll-behavior: smooth; }

body {
  font-family: 'Inter', sans-serif;
  background: var(--dark);
  color: var(--text);
  line-height: 1.65;
  font-size: 16px;
}

a { color: inherit; text-decoration: none; }
img { max-width: 100%; display: block; }
ul { list-style: none; }

/* ----- Container ----- */
.container {
  width: 100%;
  max-width: var(--max-w);
  margin: 0 auto;
  padding: 0 1.5rem;
}

/* ----- Topbar ----- */
.topbar {
  background: var(--dark-2);
  border-bottom: 1px solid rgba(212,160,23,.15);
  font-size: .82rem;
  padding: .45rem 0;
}
.topbar__inner {
  display: flex;
  gap: 1.5rem;
  flex-wrap: wrap;
  align-items: center;
}
.topbar__item { display: flex; align-items: center; gap: .4rem; color: var(--text-2); }
.topbar__item a { color: var(--gold); }
.topbar__item a:hover { color: var(--amber); }
.topbar__hours { margin-left: auto; }

/* ----- Header ----- */
.header {
  position: sticky;
  top: 0;
  z-index: 100;
  background: rgba(17,20,24,.95);
  backdrop-filter: blur(12px);
  border-bottom: 1px solid rgba(212,160,23,.12);
  transition: box-shadow var(--trans);
}
.header.scrolled { box-shadow: 0 2px 20px rgba(0,0,0,.5); }

.header__inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding-top: .85rem;
  padding-bottom: .85rem;
  gap: 1rem;
}

/* Brand */
.brand { display: flex; align-items: center; gap: .75rem; text-decoration: none; }
.brand__mark {
  width: 44px; height: 44px;
  background: linear-gradient(135deg, var(--gold), var(--amber));
  color: var(--dark);
  font-family: 'Poppins', sans-serif;
  font-weight: 800;
  font-size: 1.1rem;
  border-radius: 8px;
  display: grid;
  place-items: center;
  flex-shrink: 0;
}
.brand__text {
  font-weight: 700;
  font-size: 1.05rem;
  color: var(--white);
  display: flex;
  flex-direction: column;
  line-height: 1.15;
}
.brand__text small {
  font-size: .65rem;
  font-weight: 400;
  color: var(--text-2);
  letter-spacing: .04em;
  text-transform: uppercase;
}
.brand--footer { text-decoration: none; display: flex; align-items: center; gap: .6rem; }

/* Nav */
.nav { display: flex; align-items: center; gap: 1.75rem; }
.nav a {
  font-size: .9rem;
  font-weight: 500;
  color: var(--text-2);
  transition: color var(--trans);
  white-space: nowrap;
}
.nav a:hover { color: var(--gold); }
.nav__cta {
  background: linear-gradient(135deg, var(--gold), var(--amber)) !important;
  color: var(--dark) !important;
  padding: .5rem 1.2rem;
  border-radius: 6px;
  font-weight: 600 !important;
  font-size: .85rem !important;
  transition: opacity var(--trans) !important;
}
.nav__cta:hover { opacity: .88; }

/* Hamburger */
.nav__toggle {
  display: none;
  flex-direction: column;
  gap: 5px;
  background: none;
  border: none;
  cursor: pointer;
  padding: 4px;
}
.nav__toggle span {
  display: block;
  width: 24px; height: 2px;
  background: var(--text);
  border-radius: 2px;
  transition: transform var(--trans), opacity var(--trans);
}
.nav__toggle.open span:nth-child(1) { transform: translateY(7px) rotate(45deg); }
.nav__toggle.open span:nth-child(2) { opacity: 0; }
.nav__toggle.open span:nth-child(3) { transform: translateY(-7px) rotate(-45deg); }

/* ----- Buttons ----- */
.btn {
  display: inline-flex;
  align-items: center;
  gap: .5rem;
  padding: .75rem 1.75rem;
  border-radius: 8px;
  font-weight: 600;
  font-size: .95rem;
  cursor: pointer;
  border: none;
  transition: all var(--trans);
  text-decoration: none;
  white-space: nowrap;
}
.btn--primary {
  background: linear-gradient(135deg, var(--gold), var(--amber));
  color: var(--dark);
}
.btn--primary:hover { opacity: .88; transform: translateY(-1px); box-shadow: 0 6px 20px rgba(212,160,23,.35); }
.btn--ghost {
  background: transparent;
  color: var(--text);
  border: 1.5px solid rgba(255,255,255,.2);
}
.btn--ghost:hover { border-color: var(--gold); color: var(--gold); }
.btn--block { display: flex; width: 100%; justify-content: center; }

/* ----- Hero ----- */
.hero {
  min-height: calc(100vh - 120px);
  display: flex;
  align-items: center;
  background:
    linear-gradient(135deg, rgba(17,20,24,.97) 0%, rgba(26,31,38,.92) 100%),
    repeating-linear-gradient(
      45deg,
      transparent,
      transparent 40px,
      rgba(212,160,23,.025) 40px,
      rgba(212,160,23,.025) 41px
    );
  padding: 5rem 0 4rem;
  position: relative;
  overflow: hidden;
}

.hero::before {
  content: '';
  position: absolute;
  top: -200px; right: -200px;
  width: 600px; height: 600px;
  background: radial-gradient(circle, rgba(212,160,23,.12) 0%, transparent 70%);
  pointer-events: none;
}

.hero__inner {
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 3rem;
  align-items: center;
}

.hero__eyebrow {
  font-size: .82rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: .12em;
  color: var(--gold);
  margin-bottom: 1rem;
}
.hero__title {
  font-family: 'Poppins', sans-serif;
  font-size: clamp(2.2rem, 5vw, 3.6rem);
  font-weight: 800;
  line-height: 1.1;
  margin-bottom: 1.25rem;
  color: var(--white);
}
.hero__title span {
  background: linear-gradient(90deg, var(--gold), var(--amber));
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}
.hero__lead { font-size: 1.05rem; color: var(--text-2); max-width: 560px; margin-bottom: 2rem; }
.hero__actions { display: flex; gap: 1rem; flex-wrap: wrap; margin-bottom: 2.5rem; }

.hero__stats { display: flex; gap: 2rem; flex-wrap: wrap; }
.stat strong { display: block; font-size: 1.8rem; font-weight: 800; color: var(--gold); line-height: 1; }
.stat span { font-size: .8rem; color: var(--text-2); }

/* Hero card */
.hero__card {
  background: var(--dark-2);
  border: 1px solid rgba(212,160,23,.18);
  border-radius: var(--radius);
  padding: 2rem 1.75rem;
  min-width: 280px;
  max-width: 320px;
  box-shadow: var(--shadow);
}
.hero__badge {
  font-size: .78rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: .08em;
  color: var(--gold);
  background: rgba(212,160,23,.12);
  border-radius: 4px;
  padding: .35rem .75rem;
  display: inline-block;
  margin-bottom: 1.25rem;
}
.hero__points { display: flex; flex-direction: column; gap: .85rem; }
.hero__points li { font-size: .95rem; color: var(--text); display: flex; gap: .6rem; align-items: flex-start; }

/* ----- Sections ----- */
.section { padding: 5rem 0; }
.section--alt { background: var(--dark-2); }

.section__head { text-align: center; margin-bottom: 3rem; }
.section__eyebrow {
  font-size: .8rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: .12em;
  color: var(--gold);
  margin-bottom: .5rem;
}
.section__title {
  font-family: 'Poppins', sans-serif;
  font-size: clamp(1.7rem, 3.5vw, 2.5rem);
  font-weight: 700;
  color: var(--white);
  margin-bottom: .75rem;
}
.section__sub { font-size: 1rem; color: var(--text-2); max-width: 560px; margin: 0 auto; }

/* ----- Grid ----- */
.grid { display: grid; gap: 1.5rem; }
.grid--3 { grid-template-columns: repeat(3, 1fr); }

/* ----- Cards ----- */
.card {
  background: var(--dark-3);
  border: 1px solid rgba(255,255,255,.07);
  border-radius: var(--radius);
  padding: 1.75rem;
  transition: transform var(--trans), border-color var(--trans), box-shadow var(--trans);
}
.card:hover {
  transform: translateY(-4px);
  border-color: rgba(212,160,23,.3);
  box-shadow: 0 8px 32px rgba(0,0,0,.4);
}

/* Service card */
.service__icon { font-size: 2.2rem; margin-bottom: 1rem; }
.service h3 { font-size: 1.05rem; font-weight: 600; color: var(--white); margin-bottom: .5rem; }
.service p { font-size: .9rem; color: var(--text-2); line-height: 1.6; }

/* Project card */
.project { position: relative; }
.project__status {
  display: inline-block;
  font-size: .72rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: .06em;
  padding: .25rem .65rem;
  border-radius: 4px;
  margin-bottom: 1rem;
}
.project__status--active { background: rgba(52,199,89,.15); color: #34c759; }
.project__status--planning { background: rgba(245,166,35,.15); color: var(--amber); }
.project h3 { font-size: 1rem; font-weight: 600; color: var(--white); margin-bottom: .35rem; }
.project__meta { font-size: .78rem; color: var(--gold); margin-bottom: .6rem; }
.project p { font-size: .88rem; color: var(--text-2); margin-bottom: 1rem; }
.project__bar {
  background: rgba(255,255,255,.08);
  height: 6px;
  border-radius: 3px;
  overflow: hidden;
  margin-bottom: .4rem;
}
.project__bar span {
  display: block;
  height: 100%;
  background: linear-gradient(90deg, var(--gold), var(--amber));
  border-radius: 3px;
}
.project small { font-size: .78rem; color: var(--text-2); }

/* Mini card (about) */
.card.mini { padding: 1.25rem 1.5rem; }
.card.mini strong { display: block; font-size: .95rem; color: var(--white); margin-bottom: .4rem; }
.card.mini p { font-size: .88rem; color: var(--text-2); }

/* ----- Equipment grid ----- */
.equip-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 1.25rem;
}
.equip {
  background: var(--dark-3);
  border: 1px solid rgba(255,255,255,.07);
  border-radius: var(--radius);
  padding: 1.5rem 1.25rem;
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  gap: .6rem;
  transition: border-color var(--trans), transform var(--trans);
}
.equip:hover { border-color: rgba(212,160,23,.3); transform: translateY(-3px); }
.equip span { font-size: 2rem; }
.equip strong { font-size: .95rem; color: var(--white); font-weight: 600; }
.equip small { font-size: .78rem; color: var(--text-2); }

/* ----- About ----- */
.about {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 4rem;
  align-items: start;
}
.about__text p { color: var(--text-2); margin-bottom: 1rem; }
.about__text .section__title { text-align: left; margin-bottom: 1rem; }
.about__text .section__eyebrow { display: block; margin-bottom: .4rem; }

.checklist { margin-top: 1.5rem; display: flex; flex-direction: column; gap: .6rem; }
.checklist li { font-size: .95rem; color: var(--text); display: flex; gap: .6rem; }

.about__cards { display: flex; flex-direction: column; gap: 1rem; padding-top: 3.5rem; }

/* ----- Contact ----- */
.contact {
  display: grid;
  grid-template-columns: 1fr 1.6fr;
  gap: 3rem;
  align-items: start;
}
.contact__info { display: flex; flex-direction: column; gap: 1.5rem; }
.contact__row { display: flex; gap: 1rem; align-items: flex-start; }
.contact__row > span { font-size: 1.4rem; flex-shrink: 0; margin-top: .1rem; }
.contact__row strong { display: block; font-size: .9rem; color: var(--white); margin-bottom: .2rem; }
.contact__row p, .contact__row a { font-size: .88rem; color: var(--text-2); }
.contact__row a:hover { color: var(--gold); }

/* Form */
.contact__form { display: flex; flex-direction: column; gap: 1rem; }
.field { display: flex; flex-direction: column; gap: .4rem; }
.field-row { display: grid; grid-template-columns: 1fr 1fr; gap: 1rem; }
.field label { font-size: .82rem; font-weight: 500; color: var(--text-2); }
.field input,
.field textarea,
.field select {
  background: var(--dark-3);
  border: 1.5px solid rgba(255,255,255,.1);
  border-radius: 8px;
  padding: .7rem 1rem;
  color: var(--text);
  font-size: .9rem;
  font-family: inherit;
  transition: border-color var(--trans);
  outline: none;
  resize: vertical;
}
.field input:focus,
.field textarea:focus { border-color: var(--gold); }
.field input::placeholder,
.field textarea::placeholder { color: rgba(168,176,187,.5); }

.form-note { font-size: .8rem; color: var(--text-2); text-align: center; }
.form-note--success { color: #34c759 !important; }
.form-note--error { color: #ff453a !important; }

/* ----- Footer ----- */
.footer { background: var(--dark-2); border-top: 1px solid rgba(255,255,255,.07); padding-top: 3rem; }
.footer__inner {
  display: grid;
  grid-template-columns: 2fr 1fr 1fr;
  gap: 3rem;
  padding-bottom: 3rem;
}
.footer__about { font-size: .88rem; color: var(--text-2); max-width: 300px; margin-top: .75rem; line-height: 1.6; }
.footer__links { display: flex; flex-direction: column; gap: .6rem; }
.footer__links h4 { font-size: .85rem; font-weight: 600; color: var(--white); margin-bottom: .25rem; }
.footer__links a { font-size: .85rem; color: var(--text-2); transition: color var(--trans); }
.footer__links a:hover { color: var(--gold); }
.footer__links .muted { font-size: .82rem; color: var(--text-2); }

.footer__bottom {
  border-top: 1px solid rgba(255,255,255,.07);
  padding: 1.25rem 0;
}
.footer__bottom .container {
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: .5rem;
}
.footer__bottom p { font-size: .82rem; color: var(--text-2); }

/* ----- Utilities ----- */
.muted { color: var(--text-2); }
.center { text-align: center; }

/* ----- Back to top ----- */
.to-top {
  position: fixed;
  bottom: 2rem;
  right: 2rem;
  width: 44px; height: 44px;
  background: linear-gradient(135deg, var(--gold), var(--amber));
  color: var(--dark);
  border-radius: 50%;
  display: grid;
  place-items: center;
  font-size: 1.2rem;
  font-weight: 700;
  opacity: 0;
  pointer-events: none;
  transition: opacity var(--trans), transform var(--trans);
  box-shadow: 0 4px 16px rgba(212,160,23,.35);
  z-index: 200;
}
.to-top.visible { opacity: 1; pointer-events: auto; }
.to-top:hover { transform: translateY(-3px); }

/* ----- Responsive ----- */
@media (max-width: 1024px) {
  .grid--3 { grid-template-columns: repeat(2, 1fr); }
  .equip-grid { grid-template-columns: repeat(2, 1fr); }
  .hero__inner { grid-template-columns: 1fr; }
  .hero__card { max-width: 100%; min-width: 0; }
  .about { grid-template-columns: 1fr; gap: 2rem; }
  .about__cards { padding-top: 0; }
  .footer__inner { grid-template-columns: 1fr 1fr; }
}

@media (max-width: 768px) {
  .topbar__hours { display: none; }

  .nav {
    display: none;
    position: absolute;
    top: 100%;
    left: 0; right: 0;
    background: var(--dark-2);
    flex-direction: column;
    align-items: flex-start;
    gap: 0;
    border-bottom: 1px solid rgba(255,255,255,.07);
    padding: .5rem 0;
  }
  .nav.open { display: flex; }
  .nav a { padding: .85rem 1.5rem; width: 100%; border-bottom: 1px solid rgba(255,255,255,.05); }
  .nav__cta { border-radius: 0 !important; padding: .85rem 1.5rem !important; }
  .nav__toggle { display: flex; }
  .header__inner { position: relative; }

  .hero { min-height: auto; padding: 3rem 0; }
  .hero__stats { gap: 1.5rem; }

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

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

  .footer__inner { grid-template-columns: 1fr; gap: 2rem; }
  .footer__bottom .container { justify-content: center; text-align: center; }
}

@media (max-width: 480px) {
  .equip-grid { grid-template-columns: repeat(2, 1fr); }
  .hero__actions { flex-direction: column; }
  .btn { width: 100%; justify-content: center; }
}
