/* ==========================================================================
   Maintronik — production stylesheet
   Design system: "Modernist" (extracted from the Claude Design canvas that
   produced the site's handoff prototypes) + Maintronik-specific components.
   Flat, architectural, Archivo typeface, near-mono red-on-white, zero
   border-radius, strong 2px dividers.
   ========================================================================== */

@font-face {
  font-family: 'Archivo';
  font-style: normal;
  font-weight: 400 800;
  font-display: swap;
  src: url("../fonts/archivo-vietnamese.woff2") format('woff2');
  unicode-range: U+0102-0103, U+0110-0111, U+0128-0129, U+0168-0169, U+01A0-01A1, U+01AF-01B0, U+0300-0301, U+0303-0304, U+0308-0309, U+0323, U+0329, U+1EA0-1EF9, U+20AB;
}
@font-face {
  font-family: 'Archivo';
  font-style: normal;
  font-weight: 400 800;
  font-display: swap;
  src: url("../fonts/archivo-latin-ext.woff2") format('woff2');
  unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C0, U+2113, U+2C60-2C7F, U+A720-A7FF;
}
@font-face {
  font-family: 'Archivo';
  font-style: normal;
  font-weight: 400 800;
  font-display: swap;
  src: url("../fonts/archivo-latin.woff2") format('woff2');
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}

:root {
  --color-bg: #f3f2f2;
  --color-surface: #eae9e9;
  --color-text: #201e1d;
  --color-accent: #ec3013;
  --color-accent-2: #e15b47;
  --color-divider: color-mix(in srgb, #201e1d 40%, transparent);

  --color-neutral-100: #f8f4f4;
  --color-neutral-200: #eae7e7;
  --color-neutral-300: #d7d3d3;
  --color-neutral-400: #bab6b6;
  --color-neutral-500: #9b9797;
  --color-neutral-600: #7d7979;
  --color-neutral-700: #605d5d;
  --color-neutral-800: #444141;
  --color-neutral-900: #2d2b2b;

  --color-accent-100: #fff2ef;
  --color-accent-200: #ffe0d9;
  --color-accent-300: #ffc4b8;
  --color-accent-400: #ff9783;
  --color-accent-500: #ff563c;
  --color-accent-600: #dd2b0f;
  --color-accent-700: #ae1800;
  --color-accent-800: #7c1405;
  --color-accent-900: #4d170e;

  --font-heading: "Archivo", system-ui, sans-serif;
  --font-heading-weight: 800;
  --font-body: "Archivo", system-ui, sans-serif;

  --space-1: 4px;
  --space-2: 8px;
  --space-3: 12px;
  --space-4: 16px;
  --space-6: 24px;
  --space-8: 32px;

  --radius-sm: 0px;
  --radius-md: 0px;
  --radius-lg: 0px;

  --shadow-sm: 0 1px 2px color-mix(in srgb, #2d2b2b 14%, transparent);
  --shadow-md: 0 3px 10px color-mix(in srgb, #2d2b2b 16%, transparent);
  --shadow-lg: 0 12px 32px color-mix(in srgb, #2d2b2b 22%, transparent);
}

*, *::before, *::after { box-sizing: border-box; }
html { color-scheme: light; }
body {
  margin: 0; background: var(--color-bg); color: var(--color-text);
  font-family: var(--font-body); font-size: 15px; line-height: 1.55; font-weight: 400;
}
h1, h2, h3, h4, h5, h6 {
  font-family: var(--font-heading); font-weight: var(--font-heading-weight);
  line-height: 1.12; letter-spacing: -0.015em; margin: 0 0 var(--space-2);
}
h1 { font-size: clamp(30px, 5vw, 48px); }
h2 { font-size: 32px; }
h3 { font-size: 25px; }
h4 { font-size: 20px; }
p { margin: 0 0 var(--space-3); }
a { color: var(--color-accent-700); text-underline-offset: 3px; }
a:hover { color: var(--color-accent); }
img { display: block; max-width: 100%; }
:focus { outline: none; }
:focus-visible { outline: 2px solid var(--color-accent); outline-offset: 2px; }
::selection { background: color-mix(in srgb, var(--color-accent) 30%, transparent); }

.wrap { max-width: 1200px; margin: 0 auto; padding: 0 28px; }
.grayscale, .gs { filter: grayscale(1) contrast(1.08); }

/* — rules — */
.hr { height: 2px; border: 0; margin: var(--space-4) 0; background: var(--color-divider); max-width: 1200px; margin-left: auto; margin-right: auto; }

/* — buttons — */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 6px;
  cursor: pointer; text-decoration: none;
  font-family: var(--font-heading); font-weight: var(--font-heading-weight);
  font-size: 14px; line-height: 1.2; color: var(--color-text);
  background: transparent; border: 1px solid transparent;
  padding: var(--space-2) calc(var(--space-3) * 1.2);
  border-radius: var(--radius-md);
}
.btn svg { display: block; }
.btn-primary { background: var(--color-accent); color: var(--color-bg); }
.btn-primary:hover { background: var(--color-accent-600); color: var(--color-bg); }
.btn-primary:active { background: var(--color-accent-700); }
.btn-secondary { border-color: var(--color-divider); }
.btn-secondary:hover { background: color-mix(in srgb, var(--color-text) 7%, transparent); }
.btn-icon { width: 44px; height: 44px; padding: 0; }
.btn-block { width: 100%; margin-top: var(--space-2); justify-content: flex-start; text-align: left; }

/* — forms — */
.field > label {
  display: block; font-size: 12px; margin-bottom: 5px;
  color: color-mix(in srgb, var(--color-text) 70%, transparent);
}
.input {
  width: 100%; min-height: 36px; padding: 6px 10px; font: inherit;
  font-size: 14px; color: var(--color-text); caret-color: var(--color-accent);
  background: var(--color-surface);
  border: 1px solid var(--color-divider); border-radius: var(--radius-md);
}
.input:hover { border-color: color-mix(in srgb, var(--color-text) 45%, transparent); }
.input:focus-visible { border-color: var(--color-accent); outline-offset: 0; }
textarea.input { min-height: 90px; resize: vertical; }

/* — cards — */
.card {
  display: flex; flex-direction: column; gap: var(--space-2);
  padding: var(--space-3); border-radius: var(--radius-md); background: var(--color-surface);
}
.card-kicker { font-size: 10px; letter-spacing: 0.1em; text-transform: uppercase; color: var(--color-accent); }
.card-title { font-family: var(--font-heading); font-weight: var(--font-heading-weight); font-size: 17px; line-height: 1.2; }
.card-body { margin: 0; font-size: 13px; opacity: 0.8; }
.card-meta { display: flex; align-items: center; gap: 6px; font-size: 11px; color: color-mix(in srgb, var(--color-text) 50%, transparent); }
.card-img { width: 100%; height: 140px; object-fit: cover; filter: grayscale(1) contrast(1.05); }
.card-img.card-img-lg { height: 160px; }
.elev-sm { box-shadow: var(--shadow-sm); }
.elev-md { box-shadow: var(--shadow-md); }
.elev-lg { box-shadow: var(--shadow-lg); }

/* — tags — */
.tag { display: inline-flex; align-items: center; font-size: 11px; letter-spacing: 0.02em; padding: 3px 10px; border-radius: calc(var(--radius-md) * 0.75); }
.tag-accent { background: var(--color-accent-100); color: var(--color-accent-800); }

/* — navigation — */
.nav { display: flex; align-items: center; gap: var(--space-4); padding: var(--space-3) var(--space-4); border-bottom: 2px solid var(--color-divider); }
.nav a { color: inherit; text-decoration: none; font-size: 14px; }
.nav a:hover { color: var(--color-accent); }

/* ==========================================================================
   Maintronik-specific components
   ========================================================================== */
body { margin: 0; background: var(--color-bg); color: var(--color-text); }

/* -- header / site nav -- */
.mt-header { position: relative; display: flex; align-items: center; justify-content: space-between; gap: 20px; padding: 18px 28px; flex-wrap: wrap; background: var(--color-text); border-bottom: 2px solid var(--color-divider); color: var(--color-bg); }
.mt-logo { font-family: var(--font-heading); font-weight: 800; font-size: 22px; letter-spacing: 0.3px; color: var(--color-bg); text-decoration: none; }
.mt-logo span { color: var(--color-accent); }
.mt-nav-link { display: flex; align-items: center; gap: 8px; color: var(--color-bg); text-decoration: none; font-family: var(--font-body); font-size: 14px; white-space: nowrap; padding: 6px 0; }
.mt-nav-link:hover { color: var(--color-accent); }
.mt-nav-link svg { flex: none; }
.mt-desktop-nav { display: flex; gap: 22px; flex-wrap: wrap; align-items: center; }
.mt-mobile-toggle { display: none; align-items: center; gap: 12px; }
.mt-burger { background: none; border: 2px solid var(--color-bg); color: var(--color-bg); width: 44px; height: 44px; display: flex; align-items: center; justify-content: center; cursor: pointer; }
.mt-burger:hover { border-color: var(--color-accent); color: var(--color-accent); }
.mt-mobile-menu { max-height: 0; overflow: hidden; transition: max-height 0.25s ease; position: absolute; top: 100%; left: 0; right: 0; background: var(--color-text); border-bottom: 2px solid var(--color-divider); z-index: 20; color: var(--color-bg); }
.mt-mobile-menu.open { max-height: 320px; }
.mt-mobile-menu-inner { display: flex; flex-direction: column; padding: 8px 28px 20px; gap: 4px; }
@media (max-width: 860px) {
  .mt-desktop-nav { display: none; }
  .mt-mobile-toggle { display: flex; }
}

/* -- floating action buttons + cookie banner -- */
.mt-fabs { position: fixed; right: 20px; bottom: 20px; display: flex; flex-direction: column; gap: 12px; z-index: 60; }
.mt-fab { width: 52px; height: 52px; display: flex; align-items: center; justify-content: center; text-decoration: none; box-shadow: var(--shadow-md); transition: transform 0.15s; border-radius: 999px; }
.mt-fab:hover { transform: scale(1.06); }
.mt-fab-whatsapp { background: #25D366; color: #fff; }
.mt-fab-telegram { background: #229ED9; color: #fff; }
@keyframes mt-pulse { 0%{box-shadow:0 0 0 0 rgba(37,211,102,.55)} 70%{box-shadow:0 0 0 12px rgba(37,211,102,0)} 100%{box-shadow:0 0 0 0 rgba(37,211,102,0)} }
.mt-fab-pulse { animation: mt-pulse 2.4s ease-out infinite; }
.mt-cookie { position: fixed; left: 0; right: 0; bottom: 0; z-index: 70; background: var(--color-text); color: var(--color-bg); border-top: 2px solid var(--color-accent); padding: 16px 24px; display: flex; gap: 18px; align-items: center; justify-content: center; flex-wrap: wrap; font-family: var(--font-body); font-size: 13px; }
.mt-cookie[hidden] { display: none; }
.mt-cookie span { opacity: 0.85; }

/* -- hero carousel -- */
.mt-hero { position: relative; height: 560px; overflow: hidden; background: var(--color-text); }
.mt-hero-bg { position: absolute; inset: 0; background-size: cover; background-position: center; filter: grayscale(1); opacity: 0; transition: opacity 0.6s ease; animation: mt-kenburns 12s ease-in-out infinite alternate; }
.mt-hero-bg.active { opacity: 1; }
@keyframes mt-kenburns { from { transform: scale(1); } to { transform: scale(1.08); } }
.mt-hero-scrim { position: absolute; inset: 0; background: linear-gradient(90deg, rgba(10,9,9,0.86), rgba(10,9,9,0.45)); }
.mt-hero-content { position: relative; height: 100%; max-width: 1200px; margin: 0 auto; padding: 0 28px; display: flex; flex-direction: column; justify-content: center; gap: 22px; }
.mt-hero-content h1 { font-family: var(--font-heading); font-weight: 800; color: var(--color-bg); font-size: clamp(32px,5.5vw,56px); line-height: 1.05; margin: 0; max-width: 18ch; }
.mt-hero-content p { font-family: var(--font-body); color: var(--color-bg); font-size: 17px; max-width: 52ch; line-height: 1.6; margin: 0; opacity: 0.85; }
.mt-hero-ctas { display: flex; gap: 14px; flex-wrap: wrap; }
.mt-hero-ctas .btn-secondary { color: var(--color-bg); border-color: var(--color-bg); }
.mt-hero-dots { display: flex; gap: 8px; margin-top: 8px; }
.mt-hero-dots button { width: 40px; height: 3px; border: none; padding: 0; cursor: pointer; background: var(--color-divider); }
.mt-hero-dots button.active { background: var(--color-accent); }
.mt-hero-arrow { position: absolute; top: 50%; transform: translateY(-50%); background: var(--color-bg); }
.mt-hero-arrow.prev { left: 20px; }
.mt-hero-arrow.next { right: 20px; }

/* -- reveal on scroll -- */
.mt-reveal { opacity: 0; transform: translateY(22px); transition: opacity 0.6s ease, transform 0.6s ease; }
.mt-reveal.mt-revealed { opacity: 1; transform: translateY(0); }

/* -- category / brand / solution cards -- */
.mt-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(240px, 1fr)); gap: 2px; background: var(--color-divider); border: 2px solid var(--color-divider); }
.mt-grid-narrow { grid-template-columns: repeat(auto-fit, minmax(220px, 1fr)); }
.mt-cat, .mt-brand { display: flex; flex-direction: column; gap: 14px; padding: 28px; border: 2px solid var(--color-divider); text-decoration: none; color: var(--color-text); background: var(--color-bg); transition: background 0.2s, transform 0.25s, box-shadow 0.25s; }
.mt-brand { gap: 8px; }
.mt-cat:hover, .mt-brand:hover { background: var(--color-neutral-100); transform: translateY(-4px); box-shadow: var(--shadow-md); }
.mt-cat-title { font-family: var(--font-heading); font-weight: 700; font-size: 20px; }
.mt-brand-title { font-family: var(--font-heading); font-weight: 700; font-size: 20px; }
.mt-cat-desc { font-family: var(--font-body); font-size: 14px; opacity: 0.75; line-height: 1.5; }
.mt-brand-desc { font-family: var(--font-body); font-size: 13px; opacity: 0.7; }
.mt-solution { padding: 28px; border: 2px solid var(--color-divider); background: var(--color-bg); display: flex; flex-direction: column; gap: 12px; transition: transform 0.25s, box-shadow 0.25s; }
.mt-solution:hover { transform: translateY(-4px); box-shadow: var(--shadow-md); }
.mt-nowaste { display: flex; gap: 14px; align-items: flex-start; padding: 18px 0; border-bottom: 2px solid var(--color-divider); }
.mt-nowaste:last-child { border-bottom: none; }

/* -- repair item card (device grid) -- */
.mt-repair-card { display: flex; flex-direction: column; background: var(--color-surface); }
.mt-repair-card .card-body-inner { padding: var(--space-3); display: flex; flex-direction: column; gap: 4px; }

/* -- stat band -- */
.mt-stats { padding: 56px 28px; background: var(--color-text); }
.mt-stats-grid { max-width: 1200px; margin: 0 auto; display: grid; grid-template-columns: repeat(auto-fit, minmax(200px, 1fr)); gap: 24px; color: var(--color-bg); }
.mt-stat-num { font-family: var(--font-heading); font-weight: 800; font-size: 28px; color: var(--color-accent); }
.mt-stat-label { font-family: var(--font-body); font-size: 14px; opacity: 0.75; }

/* -- footer -- */
.mt-footer { background: var(--color-text); color: var(--color-bg); border-top: 2px solid var(--color-divider); padding: 48px 28px 28px; font-family: var(--font-body); }
.mt-footer-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(220px, 1fr)); gap: 32px; max-width: 1200px; margin: 0 auto; }
.mt-foot-link { color: var(--color-bg); text-decoration: none; }
.mt-foot-link:hover { color: var(--color-accent); }
.mt-footer-brand { font-family: var(--font-heading); font-weight: 800; font-size: 20px; margin-bottom: 8px; }
.mt-footer-col-title { font-family: var(--font-heading); font-weight: 700; font-size: 13px; text-transform: uppercase; letter-spacing: 0.06em; color: var(--color-accent); margin-bottom: 10px; }
.mt-footer-copy { max-width: 1200px; margin: 0 auto; font-size: 12px; opacity: 0.6; }

/* -- location section -- */
.mt-location { display: grid; grid-template-columns: 1.1fr 1fr; gap: 2px; background: var(--color-divider); border: 2px solid var(--color-divider); }
.mt-location iframe { width: 100%; min-height: 320px; border: none; display: block; }
.mt-location-panel { background: var(--color-bg); padding: 32px; display: flex; flex-direction: column; gap: 22px; }
.mt-location-row { display: flex; gap: 14px; align-items: flex-start; }
.mt-location-row svg { flex: none; }
@media (max-width: 760px) {
  .mt-location { grid-template-columns: 1fr; }
}

/* -- generic page header block -- */
.mt-page-head { padding: 56px 28px 16px; max-width: 1200px; margin: 0 auto; }
.mt-page-head.tight { padding-bottom: 0; }
.mt-back-link { font-family: var(--font-body); font-size: 13px; text-decoration: none; }

/* -- multi-step wizard (auto-part-order.html) -- */
.mt-wizard-step { border-bottom: 2px solid var(--color-divider); padding: 28px 0; }
.mt-wizard-step:first-child { padding-top: 0; }
.mt-wizard-step:last-child { border-bottom: none; padding-bottom: 0; }
.mt-wizard-step[data-locked] { opacity: 0.4; pointer-events: none; }
.mt-wizard-step-head { margin-bottom: 18px; }
.mt-wizard-summary { display: none; width: 100%; align-items: center; gap: 10px; background: none; border: none; padding: 0; cursor: pointer; text-align: left; font-family: var(--font-body); }
.mt-wizard-step.is-done .mt-wizard-summary { display: flex; }
.mt-wizard-step.is-done .mt-wizard-body { display: none; }
.mt-wizard-summary-label { font-size: 12px; text-transform: uppercase; letter-spacing: 0.06em; color: color-mix(in srgb, var(--color-text) 55%, transparent); flex: none; }
.mt-wizard-summary-value { font-family: var(--font-heading); font-weight: 700; font-size: 16px; flex: 1; }
.mt-wizard-summary-edit { font-size: 13px; color: var(--color-accent-700); flex: none; }
.mt-wizard-summary:hover .mt-wizard-summary-edit { color: var(--color-accent); text-decoration: underline; }

.mt-chip-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(140px, 1fr)); gap: 2px; background: var(--color-divider); border: 2px solid var(--color-divider); }
.mt-chip { background: var(--color-bg); border: none; padding: 14px 12px; font-family: var(--font-body); font-weight: 600; font-size: 14px; color: var(--color-text); cursor: pointer; text-align: center; transition: background 0.15s, color 0.15s; }
.mt-chip:hover { background: var(--color-neutral-100); }
.mt-chip.selected { background: var(--color-accent); color: var(--color-bg); }

/* -- utility responsive text -- */
@media (max-width: 640px) {
  .mt-hero { height: 620px; }
}
