:root{
  --ink: #0E1620;
  --paper: #16212C;
  --paper-2: #1C2A38;
  --line: #23374A;
  --cyan: #5ECCE0;
  --orange: #FF5D1F;
  --white: #EDEFF2;
  --steel: #8FA3B3;
}

*{ box-sizing: border-box; margin:0; padding:0; }
html{ scroll-behavior: smooth; }
body{
  background: var(--ink);
  color: var(--white);
  font-family: 'IBM Plex Sans', sans-serif;
  line-height: 1.5;
  overflow-x: hidden;
}
h1,h2,h3{ font-family: 'Space Grotesk', sans-serif; font-weight: 600; letter-spacing: -0.02em; }
.mono{ font-family: 'IBM Plex Mono', monospace; }
a{ color: inherit; text-decoration: none; }
.wrap{ max-width: 1180px; margin: 0 auto; padding: 0 28px; }

/* blueprint grid backdrop */
.grid-bg{
  position: fixed; inset: 0; z-index: 0; pointer-events: none;
  background-image:
    linear-gradient(var(--line) 1px, transparent 1px),
    linear-gradient(90deg, var(--line) 1px, transparent 1px);
  background-size: 42px 42px;
  opacity: 0.22;
  mask-image: radial-gradient(ellipse 80% 60% at 50% 0%, black 40%, transparent 90%);
}

section{ position: relative; z-index: 1; }

/* ---------- NAV ---------- */
header{
  position: sticky; top:0; z-index: 50;
  background: rgba(14,22,32,0.82);
  backdrop-filter: blur(10px);
  border-bottom: 1px solid var(--line);
}
.nav{
  display:flex; align-items:center; justify-content:space-between;
  padding: 16px 28px; max-width: 1180px; margin:0 auto;
}
.logo{
  font-family:'Space Grotesk', sans-serif; font-weight:700; font-size:1.15rem;
  letter-spacing: 0.06em;
}
.logo span{ color: var(--orange); }
.nav-links{ display:flex; gap: 28px; font-size: 0.92rem; color: var(--steel); }
.nav-links a:hover{ color: var(--white); }
.nav-cta{
  font-family:'IBM Plex Mono', monospace; font-size:0.82rem;
  border:1px solid var(--orange); color: var(--orange);
  padding: 8px 16px; border-radius: 2px;
  transition: background 0.2s ease, color 0.2s ease;
  white-space: nowrap;
}
.nav-cta:hover{ background: var(--orange); color: var(--ink); }
@media (max-width: 720px){ .nav-links{ display:none; } }

/* ---------- HERO ---------- */
.hero{
  padding: 96px 0 60px;
  display:grid; grid-template-columns: 1.05fr 0.95fr; gap: 48px; align-items:center;
}
@media (max-width: 900px){ .hero{ grid-template-columns: 1fr; padding-top: 56px; } }

.eyebrow{
  display:inline-flex; align-items:center; gap:8px;
  font-family:'IBM Plex Mono', monospace; font-size: 0.78rem; letter-spacing: 0.08em;
  color: var(--cyan); text-transform: uppercase;
  border:1px solid var(--line); padding: 6px 12px; border-radius: 2px;
  margin-bottom: 22px;
}
.eyebrow::before{ content:''; width:6px; height:6px; background: var(--orange); border-radius:50%; }

.hero h1{
  font-size: clamp(2.1rem, 4.2vw, 3.4rem);
  line-height: 1.08;
  margin-bottom: 22px;
}
.hero h1 em{ font-style:normal; color: var(--orange); }
.hero p.lead{
  color: var(--steel); font-size: 1.05rem; max-width: 46ch; margin-bottom: 32px;
}
.btn-row{ display:flex; gap:14px; flex-wrap:wrap; }
.btn{
  font-family:'IBM Plex Mono', monospace; font-size:0.88rem;
  padding: 13px 22px; border-radius: 2px; display:inline-flex; align-items:center; gap:8px;
  transition: transform 0.15s ease, box-shadow 0.15s ease;
}
.btn-primary{ background: var(--orange); color: var(--ink); font-weight:500; }
.btn-primary:hover{ transform: translateY(-2px); box-shadow: 0 8px 20px rgba(255,93,31,0.25); }
.btn-ghost{ border:1px solid var(--line); color: var(--white); }
.btn-ghost:hover{ border-color: var(--cyan); color: var(--cyan); }

/* ---------- EXPLODED ASSEMBLY VISUAL ---------- */
.assembly{
  position: relative; height: 380px;
}
.mockup-window{
  position:absolute; left:50%; top:50%;
  width: 340px; max-width: 92%;
  transform: translate(-50%,-50%);
}
.part{
  position:absolute; opacity:0;
  animation: settle 1s cubic-bezier(.2,.8,.2,1) forwards;
}
@keyframes settle{ to{ opacity:1; transform: translate(0,0) rotate(0deg) !important; } }

.p-frame{
  width: 340px; height: 220px; left:0; top:0;
  background: var(--paper);
  border: 1px solid var(--line);
  border-radius: 4px;
  transform: translate(-60px,-40px) rotate(-8deg);
  animation-delay: 0.1s;
  box-shadow: 0 30px 60px rgba(0,0,0,0.35);
}
.p-topbar{
  width: 340px; height: 30px; left:0; top:0;
  background: var(--paper-2);
  border-bottom: 1px solid var(--line);
  border-radius: 4px 4px 0 0;
  transform: translate(80px,-70px) rotate(6deg);
  animation-delay: 0.35s;
  display:flex; align-items:center; gap:6px; padding-left:10px;
}
.dot{ width:6px; height:6px; border-radius:50%; background: var(--line); }
.p-nav{
  width: 90px; height: 150px; left:0; top:30px;
  background: rgba(94,204,224,0.06);
  border-right: 1px solid var(--line);
  transform: translate(-140px,20px) rotate(-12deg);
  animation-delay: 0.55s;
  padding: 14px 10px;
}
.p-nav .stub{ height:6px; background: var(--line); border-radius:2px; margin-bottom:10px; }
.p-nav .stub:nth-child(1){ width:70%; }
.p-nav .stub:nth-child(2){ width:50%; }
.p-nav .stub:nth-child(3){ width:60%; }
.p-hero{
  width: 200px; height: 96px; left:100px; top:44px;
  background: linear-gradient(135deg, rgba(94,204,224,0.14), rgba(255,93,31,0.10));
  border: 1px solid var(--line); border-radius: 3px;
  transform: translate(120px,-10px) rotate(10deg);
  animation-delay: 0.75s;
}
.p-line{
  height:7px; background: var(--line); border-radius:2px;
  position:absolute; left:100px;
}
.p-line1{ width:150px; top:150px; transform: translate(-90px,50px) rotate(4deg); animation-delay:0.95s; }
.p-line2{ width:110px; top:164px; transform: translate(90px,60px) rotate(-6deg); animation-delay:1.05s; }
.p-btn{
  width: 78px; height: 26px; left:100px; top:184px;
  background: var(--orange); border-radius: 2px;
  transform: translate(-100px,80px) rotate(-16deg);
  animation-delay: 1.2s;
}
.dim-label{
  position:absolute; font-family:'IBM Plex Mono',monospace; font-size:0.68rem;
  color: var(--cyan); opacity:0; animation: fadein 0.6s ease forwards; animation-delay: 1.5s;
  white-space:nowrap;
}
@keyframes fadein{ to{ opacity:0.65; } }
.dl1{ top:-24px; left:0; }
.dl2{ bottom:-26px; right:10px; }

@media (max-width: 900px){ .assembly{ height: 300px; } .mockup-window{ transform: translate(-50%,-50%) scale(0.82); } }
@media (prefers-reduced-motion: reduce){
  .part{ animation: none !important; opacity:1 !important; transform:none !important; }
  .dim-label{ animation:none !important; opacity:0.65 !important; }
}

/* ---------- SCROLL REVEAL ---------- */
.reveal{ opacity:0; transform: translateY(24px); transition: opacity 0.6s ease, transform 0.6s ease; }
.reveal.is-visible{ opacity:1; transform: translateY(0); }
@media (prefers-reduced-motion: reduce){ .reveal{ opacity:1; transform:none; transition:none; } }

/* ---------- SECTION HEADERS ---------- */
.sec{ padding: 90px 0; border-top: 1px solid var(--line); }
.sec-head{ max-width: 620px; margin-bottom: 48px; }
.sec-head h2{ font-size: clamp(1.6rem,2.6vw,2.2rem); margin-bottom: 12px; }
.sec-head p{ color: var(--steel); }

/* ---------- THREE LINES ---------- */
.lines-grid{ display:grid; grid-template-columns: repeat(3,1fr); gap: 22px; }
@media (max-width: 900px){ .lines-grid{ grid-template-columns: 1fr; } }
.line-card{
  background: var(--paper); border: 1px solid var(--line); border-radius: 4px;
  padding: 26px; transition: border-color 0.2s ease, transform 0.2s ease;
}
.line-card:hover{ border-color: var(--cyan); transform: translateY(-4px); }
.line-id{ font-family:'IBM Plex Mono',monospace; font-size:0.75rem; color: var(--orange); margin-bottom:14px; letter-spacing:0.06em; }
.line-card h3{ font-size:1.2rem; margin-bottom:10px; }
.line-card p{ color: var(--steel); font-size:0.92rem; margin-bottom:18px; }
.flow{ display:flex; align-items:center; gap:6px; font-family:'IBM Plex Mono',monospace; font-size:0.72rem; color: var(--cyan); flex-wrap:wrap; }
.flow span.arrow{ color: var(--line); }

/* ---------- PORTFOLIO / SPEC CARDS ---------- */
.case-grid{ display:grid; grid-template-columns: repeat(2,1fr); gap: 20px; }
@media (max-width: 800px){ .case-grid{ grid-template-columns: 1fr; } }
.case-card{
  background: var(--paper); border:1px solid var(--line); border-radius:4px; overflow:hidden;
  transition: border-color 0.2s ease;
}
.case-card:hover{ border-color: var(--orange); }
.case-thumb{
  height: 130px; position:relative; overflow:hidden;
  background:
    repeating-linear-gradient(115deg, rgba(94,204,224,0.08) 0 2px, transparent 2px 26px);
  border-bottom: 1px solid var(--line);
}
.case-thumb .bar{ position:absolute; top:14px; left:14px; right:14px; height:8px; background:var(--line); border-radius:2px; }
.case-thumb .bar2{ position:absolute; top:32px; left:14px; width:60%; height:8px; background:var(--line); border-radius:2px; opacity:0.6; }
.case-thumb .blk{ position:absolute; bottom:14px; left:14px; right:14px; height:44px; border:1px solid var(--cyan); border-radius:2px; opacity:0.5; }
.case-card-empty{ border-style: dashed; }
.case-thumb-empty{ background:none; display:flex; align-items:center; justify-content:center; }
.case-thumb-empty span{ font-size:0.72rem; color: var(--steel); letter-spacing:0.08em; border:1px dashed var(--line); padding:6px 12px; border-radius:2px; }
.case-body{ padding: 18px 20px 20px; }
.case-body h4{ font-family:'Space Grotesk',sans-serif; font-size:1.02rem; margin-bottom:10px; }
.spec-row{ display:flex; justify-content:space-between; font-size:0.8rem; padding: 5px 0; border-top:1px dashed var(--line); gap: 12px; }
.spec-row:first-of-type{ border-top:none; }
.spec-row .k{ color: var(--steel); font-family:'IBM Plex Mono',monospace; white-space:nowrap; }
.spec-row .v{ color: var(--white); text-align:right; }

/* ---------- CATALOG-SPECIFIC ---------- */
.filter-row{ display:flex; gap:10px; flex-wrap:wrap; margin-bottom: 36px; }
.filter-btn{
  font-family:'IBM Plex Mono',monospace; font-size:0.78rem;
  border:1px solid var(--line); color: var(--steel);
  padding: 8px 14px; border-radius: 2px; cursor:pointer; background:none;
  transition: all 0.15s ease;
}
.filter-btn:hover{ color: var(--white); border-color: var(--cyan); }
.filter-btn.active{ background: var(--orange); border-color: var(--orange); color: var(--ink); }
.catalog-grid{ display:grid; grid-template-columns: repeat(3,1fr); gap: 20px; }
@media (max-width: 980px){ .catalog-grid{ grid-template-columns: repeat(2,1fr); } }
@media (max-width: 640px){ .catalog-grid{ grid-template-columns: 1fr; } }
.tpl-card{ display:flex; flex-direction:column; }
.tpl-tag{
  position:absolute; top:10px; left:10px; font-family:'IBM Plex Mono',monospace;
  font-size:0.65rem; letter-spacing:0.05em; color: var(--cyan);
  border:1px solid var(--line); background: rgba(14,22,32,0.75); padding: 3px 8px; border-radius:2px;
}
.tpl-body{ padding: 18px 20px; display:flex; flex-direction:column; gap:10px; flex:1; }
.tpl-body h4{ font-family:'Space Grotesk',sans-serif; font-size:1.02rem; }
.tpl-desc{ font-size:0.85rem; color: var(--steel); flex:1; }
.tpl-price{ font-family:'Space Grotesk',sans-serif; color: var(--orange); font-size:1.25rem; }
.tpl-price span{ font-size:0.75rem; color: var(--steel); font-family:'IBM Plex Sans',sans-serif; }
.tpl-actions{ display:flex; gap:10px; margin-top:6px; }
.tpl-actions .btn{ flex:1; justify-content:center; padding: 10px 12px; font-size:0.8rem; }

/* ---------- PROCESS ---------- */
.process{ position:relative; }
.conveyor{
  position:relative; display:flex; justify-content:space-between; gap:8px;
  padding-top: 10px;
}
.conveyor::before{
  content:''; position:absolute; top: 21px; left:0; right:0; height:1px;
  background: repeating-linear-gradient(90deg, var(--line) 0 8px, transparent 8px 16px);
}
.station{ position:relative; flex:1; min-width:0; text-align:left; }
.station .num{
  width:42px; height:42px; border-radius:50%; background: var(--ink);
  border:1px solid var(--orange); color:var(--orange);
  display:flex; align-items:center; justify-content:center;
  font-family:'IBM Plex Mono',monospace; font-size:0.85rem; margin-bottom:16px; z-index:1; position:relative;
}
.station h4{ font-size:0.95rem; margin-bottom:6px; }
.station p{ font-size:0.8rem; color: var(--steel); }
@media (max-width: 900px){
  .conveyor{ flex-direction:column; }
  .conveyor::before{ display:none; }
  .station{ padding-left:0; }
}

/* ---------- BOTS ---------- */
.bots-grid{ display:grid; grid-template-columns: 1fr 1fr; gap: 24px; align-items:start; }
@media (max-width: 800px){ .bots-grid{ grid-template-columns: 1fr; } }
.chat{
  background: var(--paper); border:1px solid var(--line); border-radius:6px; padding: 18px;
}
.chat-head{ display:flex; align-items:center; gap:10px; margin-bottom:14px; padding-bottom:12px; border-bottom:1px solid var(--line); }
.chat-avatar{ width:30px; height:30px; border-radius:50%; background: var(--line); display:flex; align-items:center; justify-content:center; font-size:0.7rem; font-family:'IBM Plex Mono',monospace; color:var(--cyan); }
.chat-head b{ font-size:0.9rem; }
.chat-head .tag{ font-family:'IBM Plex Mono',monospace; font-size:0.68rem; color: var(--steel); }
.bubble{ max-width:80%; padding:9px 13px; border-radius: 12px; font-size:0.85rem; margin-bottom:10px; line-height:1.4; }
.bubble.in{ background: var(--paper-2); border-bottom-left-radius:3px; }
.bubble.out{ background: rgba(255,93,31,0.16); margin-left:auto; border-bottom-right-radius:3px; }
.bot-note{ margin-top:18px; font-size:0.78rem; color: var(--steel); border-top:1px dashed var(--line); padding-top:14px; }
.bot-note b{ color: var(--cyan); }

/* ---------- PRICING ---------- */
.price-grid{ display:grid; grid-template-columns: repeat(3,1fr); gap: 20px; }
@media (max-width: 900px){ .price-grid{ grid-template-columns: 1fr; } }
.price-card{
  background: var(--paper); border:1px solid var(--line); border-radius:4px; padding: 26px;
  position:relative;
}
.price-card .model{ font-family:'IBM Plex Mono',monospace; font-size:0.7rem; color: var(--steel); letter-spacing:0.06em; margin-bottom: 8px; }
.price-card h3{ font-size:1.1rem; margin-bottom:14px; }
.price-card .price{ font-family:'Space Grotesk',sans-serif; font-size:1.7rem; color: var(--orange); margin-bottom: 16px; }
.price-card .price span{ font-size:0.85rem; color: var(--steel); font-family:'IBM Plex Sans',sans-serif; }
.price-card ul{ list-style:none; }
.price-card li{ font-size:0.85rem; color: var(--steel); padding: 6px 0; border-top: 1px dashed var(--line); }
.price-card li:first-child{ border-top:none; }
.price-card li::before{ content:'— '; color: var(--cyan); }

/* ---------- BRIEF FORM ---------- */
.form-card{
  background: var(--paper); border:1px solid var(--line); border-radius:6px;
  padding: 32px; max-width: 640px;
}
.field{ margin-bottom: 20px; }
.field label{
  display:block; font-family:'IBM Plex Mono',monospace; font-size:0.75rem;
  color: var(--cyan); letter-spacing:0.05em; margin-bottom:8px; text-transform:uppercase;
}
.field input, .field select, .field textarea{
  width:100%; background: var(--paper-2); border:1px solid var(--line); color: var(--white);
  padding: 11px 13px; border-radius:3px; font-family:'IBM Plex Sans',sans-serif; font-size:0.92rem;
  transition: border-color 0.15s ease;
}
.field input:focus, .field select:focus, .field textarea:focus{ outline:none; border-color: var(--cyan); }
.field textarea{ resize: vertical; min-height: 110px; }
.field-row{ display:grid; grid-template-columns: 1fr 1fr; gap:16px; }
@media (max-width: 640px){ .field-row{ grid-template-columns: 1fr; } }
.form-note{ font-size:0.78rem; color: var(--steel); margin-top:14px; }
.form-status{
  margin-top:18px; padding: 14px 16px; border-radius:3px; font-size:0.88rem; display:none;
}
.form-status.ok{ display:block; background: rgba(94,204,224,0.1); border:1px solid var(--cyan); color: var(--cyan); }
.form-status.err{ display:block; background: rgba(255,93,31,0.1); border:1px solid var(--orange); color: var(--orange); }
.submit-btn{ border:none; cursor:pointer; font-family:'IBM Plex Mono',monospace; }
.submit-btn:disabled{ opacity:0.6; cursor:not-allowed; transform:none !important; box-shadow:none !important; }
.cta-final{
  text-align:center; padding: 90px 0; border-top: 1px solid var(--line);
}
.cta-final h2{ font-size: clamp(1.6rem,3vw,2.4rem); max-width: 640px; margin: 0 auto 18px; }
.cta-final p{ color: var(--steel); margin-bottom: 30px; }
footer{ border-top:1px solid var(--line); padding: 30px 0; }
.foot-row{ display:flex; justify-content:space-between; flex-wrap:wrap; gap:12px; font-size:0.78rem; color: var(--steel); font-family:'IBM Plex Mono',monospace; }
