/* ============================================================
   NORTHERN FORGE CONSTRUCTION — Layout: Nav, Header, Footer
   ============================================================ */

/* ── STORM ALERT BANNER ─────────────────────────────────── */
.storm-banner {
  display: none;
  background: var(--orange);
  color: var(--white);
  text-align: center;
  padding: 10px 24px;
  font-size: 14px;
  font-weight: 600;
  position: relative;
  z-index: 1001;
}
.storm-banner.active { display: block; }
.storm-banner a { color: var(--white); text-decoration: underline; }
.storm-banner a:hover { opacity: .85; }

/* ── TOP BAR ────────────────────────────────────────────── */
.top-bar {
  background: var(--black);
  color: rgba(255,255,255,.65);
  font-size: 13px;
  padding: 9px 0;
  border-bottom: 1px solid rgba(255,255,255,.06);
}
.top-bar-inner { display: flex; justify-content: space-between; align-items: center; flex-wrap: wrap; gap: 8px; }
.top-bar-left { display: flex; align-items: center; gap: 8px; }
.top-bar .separator { opacity: .3; }
.top-bar-right { display: flex; align-items: center; gap: 20px; }
.top-bar-right a { color: rgba(255,255,255,.7); }
.top-bar-right a:hover { color: var(--white); }
.top-phone { font-weight: 700; color: var(--green-light) !important; }

/* ── SITE HEADER ────────────────────────────────────────── */
.site-header {
  background: var(--black);
  border-bottom: 1px solid rgba(255,255,255,.07);
  position: sticky;
  top: 0;
  z-index: 1000;
  transition: box-shadow var(--transition);
}
.site-header.scrolled { box-shadow: 0 4px 24px rgba(0,0,0,.5); }
.header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 80px;
}
.logo-link { flex-shrink: 0; }
.logo { height: 64px; width: auto; filter: invert(1); }

/* ── MAIN NAV ───────────────────────────────────────────── */
.main-nav > ul { display: flex; gap: 4px; align-items: center; }
.main-nav a {
  font-weight: 500;
  font-size: 14px;
  color: rgba(255,255,255,.75);
  padding: 8px 12px;
  border-radius: 6px;
  transition: all var(--transition);
  white-space: nowrap;
}
.main-nav a:hover { color: var(--white); background: rgba(255,255,255,.07); }
.main-nav a.active { color: var(--green-light); background: var(--green-bg); }

/* Storm damage nav item gets orange highlight */
.main-nav .nav-storm a { color: var(--orange); font-weight: 700; }
.main-nav .nav-storm a:hover { color: var(--white); background: var(--orange-bg); }

/* ── DROPDOWNS ──────────────────────────────────────────── */
.has-dropdown { position: relative; display: flex; align-items: center; }
.has-dropdown > button {
  background: none;
  border: none;
  cursor: pointer;
  font-weight: 500;
  font-size: 14px;
  color: rgba(255,255,255,.75);
  padding: 8px 12px;
  border-radius: 6px;
  transition: all var(--transition);
  display: flex;
  align-items: center;
  gap: 4px;
  white-space: nowrap;
}
.has-dropdown > button:hover { color: var(--white); background: rgba(255,255,255,.07); }
.has-dropdown > button[aria-expanded="true"] { color: var(--white); background: rgba(255,255,255,.07); }

.dropdown {
  display: none;
  position: absolute;
  top: calc(100% + 8px);
  left: 0;
  background: #111;
  border: 1px solid rgba(255,255,255,.1);
  border-radius: var(--radius);
  min-width: 230px;
  box-shadow: 0 20px 60px rgba(0,0,0,.5);
  z-index: 200;
  padding: 8px 0;
}
.dropdown.open { display: block; }
.dropdown li a {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 10px 16px;
  font-size: 14px;
  color: rgba(255,255,255,.75);
  border-radius: 0;
}
.dropdown li a:hover { background: rgba(255,255,255,.06); color: var(--white); }
.dropdown-heading {
  padding: 8px 16px 4px;
  font-size: 10px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: .1em;
  color: rgba(255,255,255,.3);
}
.dropdown-heading:not(:first-child) { border-top: 1px solid rgba(255,255,255,.07); margin-top: 4px; padding-top: 12px; }

/* Legacy dropdown support (existing pages) */
.nav-dropdown { position: relative; display: flex; align-items: center; }
.nav-dropdown > a { display: flex; align-items: center; gap: 5px; }
.nav-dropdown > a::after { content: '▾'; font-size: 10px; opacity: .5; }
.dropdown-menu {
  display: none;
  position: absolute;
  top: 100%;
  left: 0;
  background: #111;
  border: 1px solid rgba(255,255,255,.1);
  border-radius: var(--radius);
  min-width: 230px;
  box-shadow: 0 20px 60px rgba(0,0,0,.5);
  overflow: visible;
  z-index: 200;
  padding-top: 10px;
}
.dropdown-menu::before { content: ''; position: absolute; top: -14px; left: 0; right: 0; height: 14px; background: transparent; }
.nav-dropdown:hover .dropdown-menu, .nav-dropdown:focus-within .dropdown-menu { display: block; }
.dropdown-menu a { display: flex; align-items: center; gap: 12px; padding: 13px 18px; font-size: 14px; color: rgba(255,255,255,.75); border-radius: 0; }
.dropdown-menu a:hover { background: rgba(255,255,255,.06); color: var(--white); }
.dm-icon { width: 30px; height: 30px; border-radius: 7px; display: flex; align-items: center; justify-content: center; flex-shrink: 0; }
.dm-icon svg { width: 15px; height: 15px; }
.dm-icon.green { background: var(--green-bg); }
.dm-icon.green svg { stroke: var(--green-light); }
.dm-icon.blue { background: rgba(26,79,122,.25); }
.dm-icon.blue svg { stroke: #7fc4ff; }
.dm-icon.red { background: rgba(85,12,24,.3); }
.dm-icon.red svg { stroke: #ff9aab; }

/* ── NAV CTA ────────────────────────────────────────────── */
.nav-cta { display: flex; align-items: center; gap: 16px; }
.nav-phone { color: rgba(255,255,255,.8) !important; font-weight: 600; font-size: 14px; white-space: nowrap; }
.nav-phone:hover { color: var(--white) !important; }
.header-cta { font-size: 14px !important; padding: 10px 20px !important; min-height: 40px; }

/* ── HAMBURGER ──────────────────────────────────────────── */
.mobile-toggle, .hamburger {
  display: none;
  flex-direction: column;
  gap: 5px;
  background: none;
  border: none;
  cursor: pointer;
  padding: 4px;
}
.mobile-toggle span, .hamburger span {
  display: block;
  width: 24px;
  height: 2.5px;
  background: var(--white);
  border-radius: 2px;
  transition: var(--transition);
}
.mobile-toggle.open span:nth-child(1),
.hamburger.open span:nth-child(1) { transform: translateY(7.5px) rotate(45deg); }
.mobile-toggle.open span:nth-child(2),
.hamburger.open span:nth-child(2) { opacity: 0; }
.mobile-toggle.open span:nth-child(3),
.hamburger.open span:nth-child(3) { transform: translateY(-7.5px) rotate(-45deg); }

/* ── MOBILE BOTTOM BAR ──────────────────────────────────── */
.mobile-bottom-bar {
  display: none;
  position: fixed;
  bottom: 0;
  left: 0;
  right: 0;
  z-index: 1000;
  height: 56px;
  background: var(--black);
  border-top: 1px solid rgba(255,255,255,.1);
}
.mobile-bottom-bar a {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 50%;
  height: 100%;
  font-weight: 700;
  font-size: 15px;
  float: left;
}
.mobile-bottom-bar .btn-call { background: var(--orange); color: var(--white); }
.mobile-bottom-bar .btn-call:hover { background: var(--orange-dark); }
.mobile-bottom-bar .btn-estimate { background: var(--green); color: var(--white); }
.mobile-bottom-bar .btn-estimate:hover { background: var(--green-dark); }

/* ── FOOTER ─────────────────────────────────────────────── */
.site-footer {
  background: #080808;
  color: rgba(255,255,255,.58);
  padding: 72px 0 0;
  border-top: 1px solid rgba(255,255,255,.05);
}
/* 3-column footer (new pages) */
.footer-inner {
  display: grid;
  grid-template-columns: 1.5fr 1fr 1fr 1fr;
  gap: 48px;
  padding-bottom: 56px;
  border-bottom: 1px solid rgba(255,255,255,.07);
}
/* 4-column footer (legacy) */
.footer-grid {
  display: grid;
  grid-template-columns: 1.5fr 1fr 1fr 1.5fr;
  gap: 48px;
  padding-bottom: 56px;
  border-bottom: 1px solid rgba(255,255,255,.07);
}
.footer-logo { margin-bottom: 16px; opacity: .85; filter: invert(1) brightness(2); }
.footer-brand p { font-size: 14px; line-height: 1.7; margin-bottom: 8px; }
.footer-tagline { font-size: 13px; color: rgba(255,255,255,.4); line-height: 1.6; margin-top: 12px; }
.footer-license { font-size: 12px; color: rgba(255,255,255,.3); font-weight: 500; }
.site-footer h3, .site-footer h4 {
  color: var(--white);
  font-size: 11px;
  font-weight: 700;
  margin-bottom: 18px;
  text-transform: uppercase;
  letter-spacing: .1em;
}
.site-footer ul li { margin-bottom: 10px; }
.site-footer ul a { color: rgba(255,255,255,.5); font-size: 14px; transition: color var(--transition); }
.site-footer ul a:hover { color: var(--white); }
.footer-contact li { display: flex; align-items: flex-start; gap: 10px; font-size: 14px; margin-bottom: 12px; }
.footer-contact svg { stroke: var(--green-light); flex-shrink: 0; margin-top: 2px; }
.footer-bottom {
  text-align: center;
  padding: 24px 0;
  font-size: 12px;
  color: rgba(255,255,255,.22);
}
.footer-bottom a { color: rgba(255,255,255,.4); }
.footer-bottom a:hover { color: var(--white); }

/* ── BREADCRUMBS ────────────────────────────────────────── */
.breadcrumb {
  display: flex;
  align-items: center;
  gap: 6px;
  flex-wrap: wrap;
  list-style: none;
  padding: 0;
  margin: 0;
  font-size: 13px;
  color: var(--text-muted);
}
.breadcrumb li { display: flex; align-items: center; gap: 6px; }
.breadcrumb li + li::before { content: '›'; color: var(--text-muted); }
.breadcrumb a { color: var(--green); }
.breadcrumb a:hover { color: var(--green-dark); }
.breadcrumb-nav { padding: 14px 0; border-bottom: 1px solid var(--border); margin-bottom: 40px; }

/* ── HERO ───────────────────────────────────────────────── */
.hero {
  position: relative;
  min-height: 660px;
  display: flex;
  align-items: center;
  background: var(--black);
  overflow: hidden;
}
.hero-bg {
  position: absolute;
  inset: 0;
  background-image: url('../images/project-photo-1.jpg');
  background-size: cover;
  background-position: center 30%;
}
.hero-overlay {
  position: absolute;
  inset: 0;
  background: linear-gradient(110deg, rgba(0,0,0,.92) 0%, rgba(0,0,0,.72) 55%, rgba(0,0,0,.45) 100%);
  z-index: 1;
}
.hero-content { position: relative; z-index: 2; color: var(--white); padding: 120px 0 100px; max-width: 700px; }
.hero-badge {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  background: rgba(36,130,50,.18);
  border: 1px solid rgba(36,130,50,.32);
  color: #6fd97c;
  font-size: 11px;
  font-weight: 700;
  padding: 6px 14px;
  border-radius: 50px;
  margin-bottom: 24px;
  letter-spacing: .09em;
  text-transform: uppercase;
}
.hero h1 {
  font-size: clamp(2.6rem, 5vw, 4.2rem);
  font-weight: 900;
  color: var(--white);
  margin-bottom: 20px;
  letter-spacing: -.035em;
  line-height: 1.05;
}
.hero h1 span { color: var(--green-light); }
.hero-sub { font-size: 18px; line-height: 1.75; color: rgba(255,255,255,.75); margin-bottom: 36px; max-width: 520px; }
.hero-actions { display: flex; gap: 14px; flex-wrap: wrap; margin-bottom: 32px; }
.hero-trust { display: flex; gap: 28px; flex-wrap: wrap; padding-top: 28px; border-top: 1px solid rgba(255,255,255,.1); }
.trust-item { display: flex; align-items: center; gap: 10px; font-size: 14px; font-weight: 500; color: rgba(255,255,255,.65); }
.trust-item svg { stroke: var(--green-light); flex-shrink: 0; }

/* ── PAGE HERO ──────────────────────────────────────────── */
.page-hero { position: relative; background: var(--black); padding: 110px 0 72px; text-align: center; }
.page-hero-bg { position: absolute; inset: 0; background-size: cover; background-position: center; }
.page-hero-overlay { position: absolute; inset: 0; background: linear-gradient(180deg, rgba(0,0,0,.88) 0%, rgba(0,0,0,.72) 100%); }
.page-hero .container { position: relative; z-index: 2; }
.page-hero h1, .page-hero .page-hero-title {
  color: var(--white);
  font-size: clamp(2rem, 4.5vw, 3.4rem);
  font-weight: 900;
  margin-bottom: 14px;
  letter-spacing: -.025em;
}
.page-hero p { color: rgba(255,255,255,.7); font-size: 18px; max-width: 560px; margin: 0 auto; }
.page-hero-badge {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-size: 11px;
  font-weight: 700;
  letter-spacing: .1em;
  text-transform: uppercase;
  padding: 6px 14px;
  border-radius: 50px;
  margin-bottom: 18px;
}
.page-hero-badge.green { background: rgba(36,130,50,.18); color: #6fd97c; border: 1px solid rgba(36,130,50,.3); }
.page-hero-badge.blue { background: rgba(26,79,122,.28); color: #7fc4ff; border: 1px solid rgba(26,79,122,.4); }
.page-hero-badge.red { background: rgba(85,12,24,.32); color: #ff9aab; border: 1px solid rgba(85,12,24,.45); }
.page-hero-badge.orange { background: rgba(232,74,12,.18); color: #f77d50; border: 1px solid rgba(232,74,12,.3); }

/* ── SCROLL TO TOP ──────────────────────────────────────── */
.scroll-top {
  position: fixed;
  bottom: 80px;
  right: 24px;
  z-index: 999;
  width: 44px;
  height: 44px;
  background: var(--green);
  color: var(--white);
  border: none;
  border-radius: 50%;
  cursor: pointer;
  font-size: 20px;
  display: none;
  align-items: center;
  justify-content: center;
  box-shadow: var(--shadow-lg);
  transition: all var(--transition);
}
.scroll-top.visible { display: flex; }
.scroll-top:hover { background: var(--green-dark); transform: translateY(-2px); }

/* ── RESPONSIVE ─────────────────────────────────────────── */
@media (max-width: 1200px) {
  .nav-phone { display: none; }
}

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

@media (max-width: 768px) {
  .top-bar-left { display: none; }
  .header-inner { height: 64px; }
  .logo { height: 52px; }
  .main-nav {
    display: none;
    position: absolute;
    top: 64px;
    left: 0;
    right: 0;
    background: #111;
    border-bottom: 1px solid rgba(255,255,255,.1);
    padding: 10px 0 72px;
    z-index: 999;
    max-height: calc(100vh - 64px);
    overflow-y: auto;
  }
  .main-nav.open, .main-nav.nav-open { display: block; }
  .main-nav ul { flex-direction: column; gap: 0; }
  .main-nav > ul > li { width: 100%; }
  .main-nav a { display: block; padding: 13px 20px; font-size: 16px; border-radius: 0; }
  .has-dropdown > button { width: 100%; justify-content: space-between; padding: 13px 20px; font-size: 16px; border-radius: 0; }
  .dropdown {
    position: static;
    border: none;
    background: rgba(255,255,255,.04);
    box-shadow: none;
    border-radius: 0;
    padding: 4px 0;
    display: block;
    display: none;
  }
  .dropdown.open { display: block; }
  .dropdown-heading { padding-left: 28px; }
  .dropdown li a { padding-left: 28px; }
  .nav-dropdown > a { display: block; padding: 13px 20px; font-size: 16px; border-radius: 0; }
  .dropdown-menu { position: static; border: none; background: rgba(255,255,255,.04); box-shadow: none; }
  .mobile-toggle, .hamburger { display: flex; }
  .nav-cta .header-cta { display: none; }
  .nav-phone { display: none; }
  .mobile-bottom-bar { display: flex; padding-bottom: env(safe-area-inset-bottom, 0); }
  .hero { min-height: auto; }
  .hero-content { padding: 80px 0 64px; }
  .hero-trust { flex-direction: column; gap: 12px; }
  .hero-actions { flex-direction: column; }
  .hero-actions .btn { width: 100%; }
  .footer-inner, .footer-grid { grid-template-columns: 1fr; text-align: center; }
  .footer-logo { margin: 0 auto 16px; }
  .footer-contact li { justify-content: center; }
  .breadcrumb-nav { display: none; }
  /* Add bottom padding for mobile bottom bar */
  main { padding-bottom: 56px; }
}

@media (max-width: 480px) {
  .hero h1 { font-size: 2.1rem; }
}
