/* ===========================================================
   MARK-TECH DEVICE LIMITED — Design System
   Palette:  #F7B500 solar yellow · #0A1F3D deep-grid navy
             #12141A ink · #FFFFFF white · #FBFBF9 paper
   Type:     Space Grotesk (display) / Inter (body) / IBM Plex Mono (utility)
   Signature: the "charge line" — a vertical LED/current indicator that
   runs the nav, and a hand-drawn sun-rig behind the hero headline.
   =========================================================== */

@import url('https://fonts.googleapis.com/css2?family=Space+Grotesk:wght@500;600;700&family=Inter:wght@400;500;600;700&family=IBM+Plex+Mono:wght@500&display=swap');

:root{
  --yellow: #F7B500;
  --yellow-dark: #D89A00;
  --yellow-soft: #FFF3D2;
  --navy: #0A1F3D;
  --navy-light: #123059;
  --navy-line: #1D3E68;
  --ink: #12141A;
  --white: #FFFFFF;
  --paper: #FBFBF9;
  --line: #E8E6DF;
  --muted: #5B6472;

  --sidebar-w: 248px;
  --sidebar-w-collapsed: 74px;
  --topbar-h: 68px;

  --font-display: 'Space Grotesk', sans-serif;
  --font-body: 'Inter', sans-serif;
  --font-mono: 'IBM Plex Mono', monospace;

  --ease: cubic-bezier(.4,0,.2,1);
}

*,*::before,*::after{ box-sizing:border-box; }
html{ scroll-behavior:smooth; }
body{
  margin:0;
  background:var(--white);
  color:var(--ink);
  font-family:var(--font-body);
  -webkit-font-smoothing:antialiased;
  line-height:1.5;
}
img{ max-width:100%; display:block; }
a{ color:inherit; text-decoration:none; }
ul{ margin:0; padding:0; list-style:none; }
h1,h2,h3,h4{ font-family:var(--font-display); margin:0; line-height:1.08; letter-spacing:-0.01em; }
p{ margin:0; }
button{ font-family:inherit; cursor:pointer; }

:focus-visible{
  outline:2px solid var(--yellow-dark);
  outline-offset:3px;
  border-radius:4px;
}

.eyebrow{
  font-family:var(--font-mono);
  font-size:.72rem;
  letter-spacing:.14em;
  text-transform:uppercase;
  color:var(--yellow-dark);
  display:inline-flex;
  align-items:center;
  gap:.5rem;
}
.eyebrow::before{
  content:'';
  width:7px; height:7px;
  border-radius:50%;
  background:var(--yellow);
  box-shadow:0 0 0 3px var(--yellow-soft);
}

/* ===================== SIDEBAR (desktop) =====================
   Collapsed by default (a bare LED/charge rail — fits the inverter-panel
   idea). Hovering expands it into the full labelled nav, overlaying the
   page rather than pushing it, so nothing reflows underneath. */
.sidebar{
  position:fixed;
  top:0; left:0; bottom:0;
  width:var(--sidebar-w-collapsed);
  background:var(--navy);
  color:var(--white);
  display:flex;
  flex-direction:column;
  z-index:100;
  padding:28px 16px;
  overflow:hidden;
  white-space:nowrap;
  transition:width .32s var(--ease), box-shadow .32s var(--ease);
}
.sidebar:hover,
.sidebar:focus-within{
  width:var(--sidebar-w);
  box-shadow:24px 0 48px rgba(0,0,0,.18);
}
.sidebar__fade{
  opacity:0;
  transform:translateX(-4px);
  transition:opacity .22s var(--ease) .02s, transform .22s var(--ease) .02s;
}
.sidebar:hover .sidebar__fade,
.sidebar:focus-within .sidebar__fade{
  opacity:1;
  transform:none;
}

.sidebar__logo{
  display:flex;
  align-items:center;
  gap:10px;
  margin-bottom:34px;
}
.brand-mark{
  position:relative;
  display:inline-block;
  flex:none;
  border-radius:50%;
  overflow:hidden;
}
.sidebar__logo .brand-mark{ width:30px; height:30px; }
.brand-mark__icon{ position:absolute; inset:0; width:100%; height:100%; }
.brand-mark__photo{
  position:absolute; inset:0;
  width:100%; height:100%;
  object-fit:cover;
}
.sidebar__wordmark{
  font-family:var(--font-display);
  font-weight:700;
  font-size:1rem;
  letter-spacing:.01em;
  line-height:1.1;
}
.sidebar__wordmark span{
  display:block;
  font-family:var(--font-mono);
  font-weight:500;
  font-size:.62rem;
  letter-spacing:.12em;
  color:var(--yellow);
  margin-top:2px;
}

.charge-rail{
  position:relative;
  display:flex;
  flex-direction:column;
  gap:0;
  padding-left:22px;
  margin-top:6px;
}
.charge-rail::before{
  content:'';
  position:absolute;
  left:5px; top:10px; bottom:10px;
  width:1px;
  background:linear-gradient(var(--navy-line), var(--navy-line));
}
.charge-rail__fill{
  position:absolute;
  left:5px; top:10px;
  width:1px;
  background:var(--yellow);
  transition:height .5s var(--ease);
}
.nav-link{
  position:relative;
  display:flex;
  align-items:center;
  gap:12px;
  padding:13px 0;
  font-family:var(--font-mono);
  font-size:.82rem;
  letter-spacing:.04em;
  color:#9FB0C6;
  transition:color .2s var(--ease);
}
.nav-link::before{
  content:'';
  position:absolute;
  left:-22px;
  width:11px; height:11px;
  border-radius:50%;
  background:var(--navy);
  border:1px solid var(--navy-line);
  transition:all .25s var(--ease);
}
.nav-link:hover{ color:var(--white); }
.nav-link.is-active{ color:var(--white); }
.nav-link.is-active::before{
  background:var(--yellow);
  border-color:var(--yellow);
  box-shadow:0 0 0 4px rgba(247,181,0,.22), 0 0 10px rgba(247,181,0,.7);
}
.nav-link__num{ color:var(--navy-line); font-size:.7rem; }
.nav-link.is-active .nav-link__num{ color:var(--yellow); }

.sidebar__spacer{ flex:1; }

.sidebar__contact{
  border-top:1px solid var(--navy-line);
  padding-top:18px;
  display:flex;
  flex-direction:column;
  gap:10px;
}
.sidebar__contact a{
  display:flex;
  align-items:center;
  gap:9px;
  font-family:var(--font-mono);
  font-size:.74rem;
  color:#C9D5E4;
  transition:color .2s var(--ease);
}
.sidebar__contact a:hover{ color:var(--yellow); }
.sidebar__contact svg{ flex:none; opacity:.85; }
.sidebar__tagline{
  margin-top:16px;
  font-size:.68rem;
  color:#5E7191;
  letter-spacing:.03em;
  line-height:1.5;
}

/* ===================== MOBILE TOPBAR ===================== */
.topbar{
  display:none;
  position:fixed;
  top:0; left:0; right:0;
  height:var(--topbar-h);
  background:var(--navy);
  color:var(--white);
  align-items:center;
  justify-content:space-between;
  padding:0 18px;
  z-index:200;
}
.topbar__logo{ display:flex; align-items:center; gap:9px; }
.topbar__logo .brand-mark{ width:26px; height:26px; }
.topbar__logo b{ font-family:var(--font-display); font-size:.95rem; }
.menu-btn{
  width:40px; height:40px;
  border:none; background:transparent;
  display:flex; align-items:center; justify-content:center;
  color:var(--white);
}
.menu-btn span, .menu-btn span::before, .menu-btn span::after{
  content:'';
  display:block;
  width:20px; height:2px;
  background:var(--white);
  position:relative;
  transition:all .25s var(--ease);
}
.menu-btn span::before{ position:absolute; top:-6px; }
.menu-btn span::after{ position:absolute; top:6px; }
.menu-btn.is-open span{ background:transparent; }
.menu-btn.is-open span::before{ top:0; transform:rotate(45deg); background:var(--yellow); }
.menu-btn.is-open span::after{ top:0; transform:rotate(-45deg); background:var(--yellow); }

.mobile-nav{
  display:none;
  position:fixed;
  inset:0;
  background:var(--navy);
  z-index:150;
  padding:calc(var(--topbar-h) + 30px) 30px 30px;
  opacity:0;
  visibility:hidden;
  transition:opacity .3s var(--ease);
}
.mobile-nav.is-open{ opacity:1; visibility:visible; }
.mobile-nav a{
  display:block;
  font-family:var(--font-display);
  font-size:2rem;
  color:#7C8CA3;
  padding:12px 0;
  border-bottom:1px solid var(--navy-line);
}
.mobile-nav a.is-active{ color:var(--yellow); }
.mobile-nav__contact{
  margin-top:28px;
  font-family:var(--font-mono);
  color:#C9D5E4;
  font-size:.85rem;
  display:flex; flex-direction:column; gap:8px;
}

/* ===================== MAIN LAYOUT ===================== */
.main{
  margin-left:var(--sidebar-w-collapsed);
  min-height:100vh;
}
.section{
  padding:112px 64px;
  max-width:1180px;
}
.section--tight{ padding-top:80px; padding-bottom:64px; }
.section--band{ max-width:none; }

/* ===================== BUTTONS ===================== */
.btn{
  display:inline-flex;
  align-items:center;
  gap:8px;
  padding:14px 26px;
  font-family:var(--font-mono);
  font-size:.8rem;
  letter-spacing:.04em;
  border-radius:3px;
  border:1px solid transparent;
  transition:all .2s var(--ease);
}
.btn--primary{
  background:var(--yellow);
  color:var(--navy);
  font-weight:600;
}
.btn--primary:hover{ background:var(--yellow-dark); transform:translateY(-1px); }
.btn--ghost{
  border-color:var(--ink);
  color:var(--ink);
}
.btn--ghost:hover{ background:var(--ink); color:var(--white); }
.btn--on-dark{ border-color:rgba(255,255,255,.35); color:var(--white); }
.btn--on-dark:hover{ background:var(--white); color:var(--navy); }

/* ===================== POWER DIVIDER (signature rule) ===================== */
.power-rule{
  height:1px;
  width:100%;
  background-image:linear-gradient(90deg, var(--line) 0 6px, transparent 6px 12px);
  background-size:12px 1px;
  position:relative;
  overflow:hidden;
}
.power-rule::after{
  content:'';
  position:absolute; top:0; left:-30%;
  width:30%; height:1px;
  background:linear-gradient(90deg, transparent, var(--yellow), transparent);
  animation:travel 5s linear infinite;
}
@keyframes travel{
  0%{ left:-30%; }
  100%{ left:100%; }
}

/* ===================== REVEAL ===================== */
.reveal{ opacity:0; transform:translateY(16px); transition:opacity .6s var(--ease), transform .6s var(--ease); }
.reveal.is-visible{ opacity:1; transform:none; }

/* ===================== HERO SLIDESHOW =====================
   6 slides cross-fade every ~3s (see script.js). Each slide is an <img>
   pointed at /images/hero-1.jpg … hero-6.jpg; until those exist (or if one
   fails to load) a tinted gradient + line-icon placeholder shows instead,
   so the section never looks broken. */
.hero-slideshow{
  position:relative;
  height:82vh;
  min-height:520px;
  max-height:760px;
  width:100%;
  overflow:hidden;
  background:var(--navy);
  margin-top:0;
}
.hero-slide{
  position:absolute;
  inset:0;
  opacity:0;
  transition:opacity 1.6s ease;
}
.hero-slide.is-active{ opacity:1; }
.hero-slide__placeholder{
  position:absolute;
  inset:0;
  display:flex;
  align-items:center;
  justify-content:center;
}
.hero-slide__placeholder svg{ width:15%; min-width:64px; opacity:.5; }
.hero-slide__img{
  position:absolute;
  inset:0;
  width:100%;
  height:100%;
  object-fit:cover;
  object-position:center;
}
.hero-slideshow__overlay{
  position:absolute;
  inset:0;
  background:linear-gradient(180deg, rgba(10,31,61,.55) 0%, rgba(10,31,61,.72) 55%, rgba(10,31,61,.88) 100%);
  z-index:2;
}
.hero-slideshow__content{
  position:relative;
  z-index:3;
  height:100%;
  display:flex;
  flex-direction:column;
  align-items:center;
  justify-content:center;
  text-align:center;
  padding:0 24px;
  color:var(--white);
}
.hero-slideshow__content .eyebrow{ color:var(--yellow); }
.hero-slideshow__content .eyebrow::before{ box-shadow:0 0 0 3px rgba(247,181,0,.28); }
.hero-slideshow__title{
  font-size:clamp(2.4rem, 6vw, 5rem);
  margin:20px 0 18px;
  letter-spacing:.005em;
}
.hero-slideshow__sub{
  max-width:52ch;
  color:#D7E0EC;
  font-size:1.08rem;
  margin-bottom:32px;
}
.hero-slideshow__ctas{ display:flex; gap:14px; flex-wrap:wrap; justify-content:center; }
.hero-slideshow__dots{
  position:absolute;
  z-index:3;
  bottom:26px; left:0; right:0;
  display:flex;
  gap:8px;
  justify-content:center;
}
.hero-slideshow__dots button{
  width:22px; height:3px;
  background:rgba(255,255,255,.35);
  border:none;
  padding:0;
  border-radius:2px;
  transition:background .25s var(--ease);
}
.hero-slideshow__dots button.is-active{ background:var(--yellow); }

@media (max-width:980px){
  .hero-slideshow{ height:72vh; min-height:440px; }
  .hero-slideshow__sub{ font-size:.98rem; }
}

/* ===================== PILLARS ===================== */
.section__title{
  font-size:clamp(1.7rem, 2.6vw, 2.4rem);
  color:var(--navy);
  margin:12px 0 40px;
  max-width:20ch;
}
.pillars{
  display:grid;
  grid-template-columns:repeat(4, 1fr);
  gap:1px;
  background:var(--line);
  border:1px solid var(--line);
  margin-top:36px;
}
.pillar{
  background:var(--white);
  padding:30px 26px;
}
.pillar__num{
  font-family:var(--font-mono);
  font-size:.72rem;
  color:var(--yellow-dark);
}
.pillar h3{ font-size:1.15rem; margin:14px 0 8px; color:var(--navy); }
.pillar p{ font-size:.9rem; color:var(--muted); }

.pillars--three{ grid-template-columns:repeat(3, 1fr); }

@media (max-width:980px){
  .pillars{ grid-template-columns:1fr 1fr; }
  .pillars--three{ grid-template-columns:1fr; }
}
@media (max-width:560px){
  .pillars{ grid-template-columns:1fr; }
}

/* ===================== DARK SECTION / CATEGORY GRID ===================== */
.section--dark{
  background:var(--navy);
  color:var(--white);
  max-width:none;
  padding:112px 64px;
}
.section--dark .section__title{ color:var(--white); }
.eyebrow--dark::before{ box-shadow:0 0 0 3px rgba(247,181,0,.25); }

.cat-grid{
  display:grid;
  grid-template-columns:repeat(4, 1fr);
  gap:18px;
  margin-top:36px;
}
.cat-card{
  border:1px solid var(--navy-line);
  padding:26px 22px;
  transition:border-color .2s var(--ease), transform .2s var(--ease);
}
.cat-card:hover{ border-color:var(--yellow); transform:translateY(-3px); }
.cat-card svg{ width:34px; height:34px; margin-bottom:20px; }
.cat-card h4{ font-size:1.02rem; margin-bottom:8px; }
.cat-card p{ font-size:.85rem; color:#93A5BE; }

.cat-grid--three{ grid-template-columns:repeat(3, 1fr); }

@media (max-width:980px){
  .section--dark{ padding:56px 22px; }
  .cat-grid{ grid-template-columns:1fr 1fr; }
  .cat-grid--three{ grid-template-columns:1fr; }
}
@media (max-width:560px){
  .cat-grid{ grid-template-columns:1fr; }
}

/* ===================== SPLIT (narrative) ===================== */
.split{
  display:grid;
  grid-template-columns:.9fr 1.4fr;
  gap:48px;
}
.split__body p{ color:var(--muted); margin-bottom:16px; max-width:60ch; }
.link-arrow{
  display:inline-block;
  margin-top:6px;
  font-family:var(--font-mono);
  font-size:.82rem;
  color:var(--navy);
  border-bottom:1px solid var(--navy);
  padding-bottom:2px;
}
@media (max-width:980px){
  .split{ grid-template-columns:1fr; gap:20px; }
}

/* ===================== VISIT CTA ===================== */
.visit-cta{
  display:grid;
  grid-template-columns:1.3fr .7fr;
  gap:32px;
  align-items:center;
}
.visit-cta__text p{ color:var(--muted); margin-top:14px; max-width:50ch; }
.visit-cta__actions{ display:flex; justify-content:flex-end; }
@media (max-width:980px){
  .visit-cta{ grid-template-columns:1fr; }
  .visit-cta__actions{ justify-content:flex-start; }
}

/* ===================== FOOTER ===================== */
.footer{
  background:var(--navy);
  color:#C9D5E4;
  padding:56px 64px 28px;
  margin-left:var(--sidebar-w-collapsed);
}
.footer__grid{
  display:grid;
  grid-template-columns:1.4fr 1fr 1fr;
  gap:40px;
  max-width:1180px;
}
.footer h4{
  font-family:var(--font-mono);
  font-size:.72rem;
  letter-spacing:.12em;
  text-transform:uppercase;
  color:var(--yellow);
  margin-bottom:14px;
}
.footer a{ display:block; color:#C9D5E4; font-size:.9rem; padding:5px 0; transition:color .2s; }
.footer a:hover{ color:var(--yellow); }
.footer__bottom{
  max-width:1180px;
  margin-top:36px;
  padding-top:20px;
  border-top:1px solid var(--navy-line);
  font-family:var(--font-mono);
  font-size:.72rem;
  color:#5E7191;
  display:flex;
  justify-content:space-between;
  flex-wrap:wrap;
  gap:8px;
}

/* ===================== PAGE HEAD (products / about / support) ===================== */
.page-head__title{
  font-size:clamp(2.1rem, 3.6vw, 3.1rem);
  color:var(--navy);
  margin:14px 0 16px;
}
.page-head__sub{ color:var(--muted); max-width:56ch; font-size:1.02rem; }

/* ===================== FILTER ROW ===================== */
.filter-row{
  display:flex;
  gap:10px;
  flex-wrap:wrap;
  margin-top:34px;
}
.filter-btn{
  border:1px solid var(--line);
  background:var(--white);
  color:var(--muted);
  padding:9px 18px;
  font-family:var(--font-mono);
  font-size:.78rem;
  letter-spacing:.03em;
  border-radius:20px;
  transition:all .2s var(--ease);
}
.filter-btn:hover{ border-color:var(--navy); color:var(--navy); }
.filter-btn.is-active{ background:var(--navy); border-color:var(--navy); color:var(--white); }

/* ===================== PRODUCT GRID ===================== */
.product-grid{
  display:grid;
  grid-template-columns:repeat(3, 1fr);
  gap:22px;
  margin-top:26px;
}
.product-card{
  border:1px solid var(--line);
  background:var(--paper);
  transition:border-color .2s var(--ease), transform .2s var(--ease);
}
.product-card:hover{ border-color:var(--yellow-dark); transform:translateY(-3px); }
.product-card__img{
  position:relative;
  aspect-ratio:4/3;
  display:flex;
  align-items:center;
  justify-content:center;
  background:
    linear-gradient(var(--white) 1px, transparent 1px),
    linear-gradient(90deg, var(--white) 1px, transparent 1px),
    var(--yellow-soft);
  background-size:14px 14px, 14px 14px, auto;
  border-bottom:1px solid var(--line);
  overflow:hidden;
}
.product-card__img svg{ width:56%; height:56%; }
.product-card__photo{
  position:absolute;
  inset:0;
  width:100%;
  height:100%;
  object-fit:cover;
}
.product-card__tag{
  display:inline-block;
  margin:16px 20px 0;
  font-family:var(--font-mono);
  font-size:.68rem;
  letter-spacing:.06em;
  text-transform:uppercase;
  color:var(--yellow-dark);
}
.product-card h3{ margin:8px 20px 6px; font-size:1.05rem; color:var(--navy); }
.product-card p{ margin:0 20px 20px; font-size:.85rem; color:var(--muted); }

.products-note{ padding-top:0; }
.products-note p{ color:var(--muted); font-size:.92rem; max-width:60ch; }

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

/* ===================== CONTACT GRID ===================== */
.contact-grid{
  display:grid;
  grid-template-columns:repeat(4, 1fr);
  gap:18px;
}
.contact-card{
  border:1px solid var(--line);
  padding:26px 22px;
  transition:border-color .2s var(--ease), transform .2s var(--ease);
}
a.contact-card:hover{ border-color:var(--yellow-dark); transform:translateY(-3px); }
.contact-card svg{ width:26px; height:26px; margin-bottom:18px; }
.contact-card h3{ font-size:1rem; color:var(--navy); margin-bottom:8px; }
.contact-card p{ font-size:.85rem; color:var(--muted); }

@media (max-width:980px){
  .contact-grid{ grid-template-columns:1fr 1fr; }
}
@media (max-width:560px){
  .contact-grid{ grid-template-columns:1fr; }
}

/* ===================== CONTACT FORM ===================== */
.contact-form{ max-width:640px; margin-top:8px; }
.form-row{ display:grid; grid-template-columns:1fr 1fr; gap:18px; }
.form-field{ margin-bottom:18px; display:flex; flex-direction:column; gap:8px; }
.form-field label{
  font-family:var(--font-mono);
  font-size:.72rem;
  letter-spacing:.06em;
  text-transform:uppercase;
  color:var(--muted);
}
.form-field input, .form-field select, .form-field textarea{
  border:1px solid var(--line);
  background:var(--paper);
  padding:12px 14px;
  font-family:var(--font-body);
  font-size:.95rem;
  color:var(--ink);
  border-radius:2px;
  resize:vertical;
}
.form-field input:focus, .form-field select:focus, .form-field textarea:focus{
  outline:2px solid var(--yellow-dark);
  outline-offset:1px;
  border-color:var(--yellow-dark);
}
.form-status{
  margin-top:14px;
  font-family:var(--font-mono);
  font-size:.8rem;
  color:var(--navy);
}
.form-status.is-error{ color:#B3261E; }

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

/* ===================== FAQ ===================== */
.faq-list{ max-width:760px; border-top:1px solid var(--line); }
.faq-item{ border-bottom:1px solid var(--line); }
.faq-item__q{
  width:100%;
  display:flex;
  align-items:center;
  justify-content:space-between;
  gap:16px;
  background:none;
  border:none;
  text-align:left;
  padding:20px 4px;
  font-family:var(--font-display);
  font-weight:600;
  font-size:1.02rem;
  color:var(--navy);
}
.faq-item__icon{
  font-family:var(--font-mono);
  font-size:1.2rem;
  color:var(--yellow-dark);
  transition:transform .25s var(--ease);
  flex:none;
}
.faq-item.is-open .faq-item__icon{ transform:rotate(45deg); }
.faq-item__a{
  max-height:0;
  overflow:hidden;
  transition:max-height .3s var(--ease);
}
.faq-item.is-open .faq-item__a{ max-height:200px; }
.faq-item__a p{ padding:0 4px 20px; color:var(--muted); max-width:60ch; font-size:.92rem; }

/* ===================== RESPONSIVE ===================== */
@media (max-width: 980px){
  .sidebar{ display:none; }
  .topbar{ display:flex; }
  .mobile-nav{ display:block; }
  .main{ margin-left:0; padding-top:var(--topbar-h); }
  .section{ padding:64px 22px; }
  .section--tight{ padding-top:48px; padding-bottom:48px; }
  .footer{ padding:44px 22px 24px; margin-left:0; }
  .footer__grid{ grid-template-columns:1fr; gap:28px; }
}

@media (prefers-reduced-motion: reduce){
  *{ animation-duration:0.001ms !important; animation-iteration-count:1 !important; transition-duration:0.001ms !important; }
  .reveal{ opacity:1; transform:none; }
}
