* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
  font-family: "Segoe UI", system-ui, -apple-system, Arial, sans-serif;
}

:root{
  --bg: #0f1115;
  --panel: rgba(21,24,31,0.82);
  --text: #f1f1f1;
  --muted: #b8bcc6;
  --accent: #2e7dff;
  --border: rgba(255,255,255,0.08);
}

body {
  background-color: var(--bg);
  color: var(--text);
  line-height: 1.6;
  overflow-x: hidden;
}

/* ===== Animated background grid ===== */
.bg-grid{
  position: fixed;
  inset: 0;
  z-index: -2;
  pointer-events: none;
  opacity: 0.45;

  background-image:
    linear-gradient(to right, rgba(255,255,255,0.04) 1px, transparent 1px),
    linear-gradient(to bottom, rgba(255,255,255,0.04) 1px, transparent 1px),
    radial-gradient(circle at 20% 30%, rgba(46,125,255,0.20), transparent 45%),
    radial-gradient(circle at 80% 70%, rgba(46,125,255,0.10), transparent 50%);

  background-size:
    70px 70px,
    70px 70px,
    100% 100%,
    100% 100%;

  animation: gridDrift 24s linear infinite;
}

@keyframes gridDrift{
  0% {background-position:0 0,0 0,0 0,0 0;}
  100% {background-position:200px 150px,150px 200px,0 0,0 0;}
}

@media (prefers-reduced-motion: reduce){
  .bg-grid{ animation: none; }
}

/* ===== Header ===== */
.site-header {
  display:flex;
  justify-content:space-between;
  align-items:center;
  padding:18px 10%;
  position:sticky;
  top:0;
  z-index:10;
  background:rgba(17,20,24,0.75);
  backdrop-filter:blur(10px);
  border-bottom:1px solid rgba(255,255,255,0.06);
  transition: padding .22s ease, background-color .22s ease, box-shadow .22s ease, border-color .22s ease;
}

.site-header.scrolled{
  padding:10px 10%;
  background:rgba(10,12,15,0.90);
  border-bottom-color: rgba(255,255,255,0.08);
  box-shadow:0 10px 30px rgba(0,0,0,.35);
}

.brand{
  display:inline-flex;
  align-items:center;
  line-height: 0;
  text-decoration:none;
}

.brand-logo{
  width:52px;
  height:52px;
  transition: transform .2s ease, filter .22s ease, width .22s ease, height .22s ease;
}

.site-header.scrolled .brand-logo{
  width:44px;
  height:44px;
}

.brand:hover .brand-logo{
  filter:
    drop-shadow(0 0 14px rgba(46,125,255,0.35))
    drop-shadow(0 0 30px rgba(46,125,255,0.22));
  transform:scale(1.05);
}

/* Nav + Active highlight */
.site-nav{
  display:flex;
  align-items:center;
}

.site-nav a{
  color:var(--muted);
  margin-left:18px;
  text-decoration:none;
  transition: color .2s ease, opacity .2s ease;
  position: relative;
  padding: 10px 2px;
  opacity: 0.92;
}

.site-nav a:hover{
  color:white;
  opacity: 1;
}

.site-nav a.active{
  color: white;
  opacity: 1;
}

.site-nav a.active::after{
  content:"";
  position:absolute;
  left:0;
  right:0;
  bottom: 3px;
  height:2px;
  border-radius: 2px;
  background: linear-gradient(90deg, rgba(46,125,255,0.95), rgba(46,125,255,0.35));
  box-shadow: 0 0 14px rgba(46,125,255,0.18);
}

/* ===== Hero ===== */
.hero{
  padding:110px 10% 80px;
  text-align:center;
  position:relative;
  overflow: hidden;
}

/* network topology SVG layer */
.hero-net{
  position:absolute;
  left:50%;
  top:70px;
  width: 1200px;
  height: 520px;
  transform: translate(-50%, 0);
  opacity: 0.18;
  z-index: 0;
  pointer-events: none;
  filter: drop-shadow(0 0 20px rgba(46,125,255,0.12));
}

.hero-net .net-lines line{
  stroke: rgba(46,125,255,0.40);
  stroke-width: 1.4;
  stroke-linecap: round;
  stroke-dasharray: 6 10;
  animation: dashMove 10s linear infinite;
}

@keyframes dashMove{
  0%{ stroke-dashoffset: 0; }
  100%{ stroke-dashoffset: -160; }
}

.hero-net .net-nodes circle{
  fill: rgba(46,125,255,0.85);
  opacity: 0.9;
  transform-origin: center;
  animation: nodePulse 4.5s ease-in-out infinite;
}

.hero-net .net-nodes circle:nth-child(2n){
  animation-duration: 5.6s;
  opacity: 0.75;
}
.hero-net .net-nodes circle:nth-child(3n){
  animation-duration: 6.8s;
  opacity: 0.65;
}

@keyframes nodePulse{
  0%, 100%{ transform: scale(1); filter: blur(0px); }
  50%{ transform: scale(1.25); filter: blur(0.2px); }
}

/* Full hero logo */
.hero-logo{
  width:300px;
  max-width:85%;
  margin-bottom:28px;
  position:relative;
  z-index:2;
  opacity:0;
  animation:logoFade 1.2s ease forwards;
}

/* Subtle animated glow behind hero logo */
.hero::before{
  content:"";
  position:absolute;
  top:110px;
  left:50%;
  transform:translateX(-50%);
  width:420px;
  height:420px;
  background:radial-gradient(circle,
    rgba(46,125,255,0.35) 0%,
    rgba(46,125,255,0.15) 35%,
    transparent 65%);
  filter:blur(40px);
  animation:glowPulse 6s ease-in-out infinite;
  z-index:1;
}

@keyframes glowPulse{
  0%{opacity:.6; transform:translateX(-50%) scale(.95);}
  50%{opacity:1; transform:translateX(-50%) scale(1.05);}
  100%{opacity:.6; transform:translateX(-50%) scale(.95);}
}

@keyframes logoFade{
  from{ opacity:0; transform:translateY(18px); }
  to{ opacity:1; transform:translateY(0); }
}

/* Hero text */
.hero h1{
  font-size:clamp(2.2rem,3.6vw,3.1rem);
  margin-bottom:16px;
  position: relative;
  z-index: 2;
}

.hero p{
  color:var(--muted);
  max-width:820px;
  margin:0 auto 28px;
  position: relative;
  z-index: 2;
}

/* Buttons */
.hero-actions{
  display:flex;
  gap:14px;
  justify-content:center;
  flex-wrap:wrap;
  position: relative;
  z-index: 2;
}

.btn{
  background:var(--accent);
  padding:12px 18px;
  border-radius:12px;
  color:white;
  text-decoration:none;
  font-weight:700;
  border:1px solid rgba(255,255,255,0.08);
  transition: transform .2s ease, background .2s ease;
  cursor: pointer;
}

.btn:hover{ transform:translateY(-1px); }

.btn-ghost{
  background:rgba(255,255,255,0.06);
}

/* ===== Sections ===== */
.section{
  padding:70px 10%;
  text-align:center;
}

.section h2{
  font-size:1.6rem;
  margin-bottom:10px;
}

.section-text{
  color:var(--muted);
  max-width:820px;
  margin:0 auto;
}

/* ===== Cards + Premium hover glow + reveal ===== */
.cards{
  display:flex;
  gap:18px;
  margin-top:34px;
  justify-content:center;
  flex-wrap:wrap;
}

.card{
  position: relative;
  background:var(--panel);
  backdrop-filter:blur(8px);
  padding:28px;
  border-radius:16px;
  width:290px;
  border:1px solid rgba(255,255,255,0.06);
  overflow: hidden;

  transition: transform .25s ease, border-color .25s ease, box-shadow .25s ease, opacity .45s ease;
}

/* reveal animation state */
.card.reveal{
  opacity: 0;
  transform: translateY(22px);
}

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

/* mouse-follow glow layer */
.card::before{
  content:"";
  position:absolute;
  inset:-2px;
  background: radial-gradient(
    600px circle at var(--mx, 50%) var(--my, 50%),
    rgba(46,125,255,0.22),
    transparent 45%
  );
  opacity: 0;
  transition: opacity .25s ease;
  pointer-events: none;
}

.card:hover::before{
  opacity: 1;
}

.card:hover{
  transform:translateY(-8px);
  border-color:rgba(46,125,255,0.35);
  box-shadow: 0 18px 45px rgba(0,0,0,0.35);
}

.card h3{ margin-bottom:8px; position: relative; }
.card p{ color:var(--muted); position: relative; }

/* ===== Estimate Tool ===== */
.estimate-wrap{
  max-width: 1100px;
  margin: 30px auto 0;
}

.estimate-grid{
  display: grid;
  grid-template-columns: 1.1fr 0.9fr;
  gap: 18px;
  align-items: start;
  margin-top: 18px;
}

.estimate-card{
  text-align: left;
  background: rgba(17,20,24,0.55);
  border: 1px solid rgba(255,255,255,0.06);
  border-radius: 18px;
  backdrop-filter: blur(10px);
  padding: 22px;
}

.estimate-card h3{
  font-size: 1.05rem;
  margin-bottom: 10px;
}

.estimate-card h4{
  font-size: 0.98rem;
  margin: 10px 0;
}

.estimate-card .row{
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 14px;
}

.estimate-card .field{
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.estimate-card label{
  font-size: 0.92rem;
  color: rgba(184,188,198,0.92);
}

.estimate-card input,
.estimate-card select{
  padding: 12px 14px;
  border-radius: 12px;
  border: 1px solid rgba(255,255,255,0.08);
  background: rgba(21,24,31,0.75);
  color: white;
}

.hint{
  font-size: 0.86rem;
  color: rgba(184,188,198,0.82);
}

.divider{
  height: 1px;
  background: rgba(255,255,255,0.06);
  margin: 16px 0;
}

.toggles{
  display: grid;
  gap: 10px;
}

.toggle{
  display: flex;
  gap: 10px;
  align-items: center;
  color: rgba(241,241,241,0.92);
  user-select: none;
}

.toggle input{ transform: translateY(1px); }

.actions{
  display: flex;
  gap: 10px;
  flex-wrap: wrap;
  margin-top: 14px;
}

.disclaimer{
  margin-top: 14px;
  color: rgba(184,188,198,0.9);
  font-size: 0.9rem;
  line-height: 1.5;
}

.estimate-out .out-top{
  display: flex;
  justify-content: space-between;
  gap: 12px;
  align-items: baseline;
}

.updated{
  font-size: 0.85rem;
  color: rgba(184,188,198,0.85);
  text-align: right;
}

.total{
  font-size: 2.2rem;
  font-weight: 800;
  margin-top: 10px;
  letter-spacing: -0.02em;
}

.range{
  color: rgba(184,188,198,0.92);
  margin-top: 6px;
}

.breakdown{
  margin-top: 10px;
  display: grid;
  gap: 8px;
  font-size: 0.95rem;
}

.bd-row{
  display: grid;
  grid-template-columns: 1.6fr 0.4fr 0.6fr 0.6fr;
  gap: 10px;
  padding: 10px 12px;
  border: 1px solid rgba(255,255,255,0.06);
  border-radius: 14px;
  background: rgba(21,24,31,0.55);
}

.bd-label{ color: rgba(241,241,241,0.94); }
.bd-qty, .bd-unit, .bd-ext{ color: rgba(184,188,198,0.95); text-align: right; }
.bd-ext{ color: rgba(241,241,241,0.94); font-weight: 700; }

.bd-line{
  height: 1px;
  background: rgba(255,255,255,0.06);
  margin: 6px 0;
}

.bd-sub{
  color: rgba(241,241,241,0.9);
  font-weight: 700;
  margin-top: 6px;
}

.bd-note{
  padding: 10px 12px;
  border: 1px dashed rgba(255,255,255,0.18);
  border-radius: 14px;
  color: rgba(241,241,241,0.9);
  background: rgba(21,24,31,0.35);
}

.next .muted{
  color: rgba(184,188,198,0.92);
  margin: 8px 0 14px;
}

/* ===== Contact ===== */
.contact-wrap{
  max-width:860px;
  margin:28px auto 0;
  padding:22px;
  border-radius:18px;
  border:1px solid rgba(255,255,255,0.06);
  background:rgba(17,20,24,0.55);
  backdrop-filter:blur(10px);
  text-align:left;
}

.contact-form{
  display:grid;
  grid-template-columns:1fr 1fr;
  gap:14px;
}

.field{
  display:flex;
  flex-direction:column;
  gap:6px;
}

.field label{
  font-size: 0.92rem;
  color: rgba(184,188,198,0.92);
}

.field-full{ grid-column:1 / -1; }

.contact-form input,
.contact-form textarea{
  padding:12px 14px;
  border-radius:12px;
  border:1px solid var(--border);
  background:rgba(21,24,31,0.75);
  color:white;
}

.contact-form input:focus,
.contact-form textarea:focus{
  border-color:rgba(46,125,255,0.45);
  outline:none;
}

.turnstile-row{
  display:flex;
  justify-content:center;
}

.actions-row{ display:grid; gap:10px; }

.form-status{
  color: var(--muted);
  min-height: 1.2em;
  font-size: 0.95rem;
}

.contact-alt{
  grid-column:1/-1;
  color:var(--muted);
  margin-top: 6px;
}

.link{
  color:var(--accent);
  text-decoration:none;
  border-bottom:1px solid rgba(46,125,255,0.35);
}

.link:hover{
  border-bottom-color: rgba(46,125,255,0.8);
}

/* Hide honeypot */
#fax{
  position:absolute !important;
  left:-10000px !important;
  top:auto !important;
  width:1px !important;
  height:1px !important;
  overflow:hidden !important;
  opacity:0 !important;
  pointer-events:none !important;
}

/* ===== Footer ===== */
.site-footer{
  padding:18px;
  text-align:center;
  color:#8a909e;
  font-size:.9rem;
  background:rgba(13,15,19,0.7);
  border-top:1px solid rgba(255,255,255,0.06);
}

/* ===== Mobile ===== */
@media(max-width:900px){
  .estimate-grid{
    grid-template-columns: 1fr;
  }
}

@media(max-width:720px){
  .site-header{ padding:16px 6%; }
  .site-header.scrolled{ padding:10px 6%; }
  .site-nav a{ margin-left:14px; }

  .hero{ padding:90px 6% 60px; }
  .section{ padding:60px 6%; }

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

  .hero-logo{ width:220px; }
  .hero::before{ width:320px; height:320px; }

  .hero-net{
    width: 900px;
    height: 420px;
    top: 55px;
    opacity: 0.14;
  }

  .brand-logo{ width:48px; height:48px; }
  .site-header.scrolled .brand-logo{ width:42px; height:42px; }

  .estimate-card .row{
    grid-template-columns: 1fr;
  }

  .bd-row{
    grid-template-columns: 1.4fr 0.4fr 0.6fr 0.6fr;
  }
}
