/* ==========================================================================
   Page-specific styles
   ========================================================================== */

/* ---------- HERO ---------- */
.hero {
  padding: 168px 0 100px;
  position: relative;
  overflow: hidden;
}
.hero .container {
  display: grid;
  grid-template-columns: 1.05fr 0.95fr;
  gap: 40px;
  align-items: center;
}
.hero h1 { font-size: clamp(34px, 5.2vw, 58px); }
.hero .lede { font-size: 18px; max-width: 520px; }
.hero-cta { display: flex; gap: 14px; margin-top: 32px; flex-wrap: wrap; }
.hero-trust { display: flex; gap: 26px; margin-top: 46px; flex-wrap: wrap; }
.hero-trust .trust-item { display: flex; align-items: center; gap: 10px; font-size: 13.5px; color: var(--text-dim); }
.hero-trust .trust-item strong { color: var(--text); font-family: 'Space Grotesk', sans-serif; font-size: 20px; display: block; }

@media (max-width: 980px) {
  .hero .container { grid-template-columns: 1fr; text-align: center; }
  .hero .lede { margin-left: auto; margin-right: auto; }
  .hero-cta, .hero-trust { justify-content: center; }
}

/* ---------- Device Panel visual (hero) ---------- */
.panel-wrap { display: flex; justify-content: center; }
.device-panel {
  width: 100%;
  max-width: 360px;
  background: linear-gradient(160deg, #eef2f9, #d7dfec);
  border-radius: 22px;
  padding: 20px;
  box-shadow: 0 50px 90px -30px rgba(0,0,20,0.7), inset 0 0 0 1px rgba(255,255,255,0.6);
  animation: floaty 7s ease-in-out infinite;
}
.device-panel .brand-strip { display: flex; align-items: center; justify-content: space-between; padding: 0 4px 14px; }
.device-panel .brand-strip .brand-mark { width: 26px; height: 26px; }
.device-panel .brand-strip span { font-size: 11px; font-weight: 700; color: #1f2a44; letter-spacing: 0.04em; }

.display-unit {
  background: #0a0a0a;
  border-radius: 12px;
  padding: 18px 16px;
  border: 3px solid #1a1a1a;
  box-shadow: inset 0 0 20px rgba(0,0,0,0.6);
}
.display-row { display: flex; justify-content: space-between; align-items: center; margin-bottom: 12px; }
.led-group { display: flex; gap: 10px; }
.led {
  font-family: 'Space Grotesk', monospace;
  font-size: 11px; font-weight: 700;
  padding: 4px 8px; border-radius: 4px;
  color: #3a1010; background: #3a1010;
  border: 1px solid rgba(255,255,255,0.05);
  transition: all .25s;
}
.led.on { color: #ff3b3b; background: #3a0d0d; text-shadow: 0 0 8px #ff3b3b; box-shadow: 0 0 12px rgba(255,59,59,0.5); }
.led.on.green { color: #37ff8e; background: #0d3a1e; text-shadow: 0 0 8px #37ff8e; box-shadow: 0 0 12px rgba(55,255,142,0.5); }

.seven-seg {
  font-family: 'Space Grotesk', monospace;
  font-size: 46px; font-weight: 700;
  color: #ff3b3b;
  text-shadow: 0 0 16px rgba(255,59,59,0.65), 0 0 3px rgba(255,59,59,0.9);
  text-align: right;
  letter-spacing: 2px;
  transition: color .3s, text-shadow .3s;
}
.seven-seg.state-off { color: #4a4f5c; text-shadow: none; }
.seven-seg.state-fault { color: #ffcf3b; text-shadow: 0 0 16px rgba(255,207,59,0.65); animation: blink-fast 0.5s steps(1) infinite; }
@keyframes blink-fast { 50% { opacity: 0.25; } }

.panel-buttons { display: grid; grid-template-columns: repeat(4, 1fr); gap: 10px; margin-top: 16px; }
.panel-btn {
  background: linear-gradient(160deg, #f6f8fc, #c9d3e4);
  border-radius: 10px;
  padding: 10px 4px;
  text-align: center;
  font-size: 10.5px;
  font-weight: 700;
  color: #2a3550;
  box-shadow: 0 3px 0 #9aa8c4, 0 4px 8px rgba(0,0,0,0.25);
  border: 1px solid rgba(255,255,255,0.6);
  user-select: none;
}
.panel-btn.active { transform: translateY(2px); box-shadow: 0 1px 0 #9aa8c4; background: linear-gradient(160deg, #cfe0ff, #9dc0ff); }
.panel-btn.on { color: #0e6b2e; }
.panel-btn.off { color: #a11c1c; }

.panel-caption { text-align: center; font-size: 11.5px; color: #5a6683; margin-top: 14px; letter-spacing: 0.02em; }

/* ---------- Water tank animation ---------- */
.tank-duo { display: flex; gap: 22px; justify-content: center; align-items: flex-end; margin: 26px 0 6px; }
.tank {
  width: 78px; height: 130px;
  border: 2px solid rgba(255,255,255,0.16);
  border-radius: 10px;
  position: relative;
  overflow: hidden;
  background: rgba(255,255,255,0.02);
}
.tank .water {
  position: absolute; left: 0; right: 0; bottom: 0;
  height: 40%;
  background: linear-gradient(180deg, #3b9bf6, #1656c9);
  transition: height 1.4s var(--ease);
}
.tank .water .wave {
  position: absolute; top: -8px; left: 0;
  width: 200%; height: 16px;
  background: radial-gradient(ellipse at center, rgba(255,255,255,0.5) 0%, transparent 70%);
  background-size: 40px 16px;
  animation: wave-move 3s linear infinite;
  opacity: 0.6;
}
@keyframes wave-move { from { transform: translateX(0); } to { transform: translateX(-40px); } }
.tank .pct { position: absolute; inset: 0; display: flex; align-items: center; justify-content: center; font-family: 'Space Grotesk', sans-serif; font-weight: 700; font-size: 13px; color: #fff; text-shadow: 0 1px 4px rgba(0,0,0,0.5); z-index: 2; }
.tank-label { text-align: center; font-size: 10.5px; letter-spacing: 0.08em; color: var(--text-dimmer); margin-top: 8px; text-transform: uppercase; }

.bubbles { position: absolute; inset: 0; overflow: hidden; pointer-events: none; }
.bubble {
  position: absolute; bottom: -10px;
  width: 5px; height: 5px; border-radius: 50%;
  background: rgba(255,255,255,0.55);
  animation: bubble-rise linear infinite;
}
@keyframes bubble-rise {
  0% { transform: translateY(0) translateX(0); opacity: 0; }
  10% { opacity: 0.9; }
  100% { transform: translateY(-140px) translateX(6px); opacity: 0; }
}

/* ---------- Marquee ---------- */
.marquee-wrap {
  overflow: hidden;
  border-top: 1px solid var(--border);
  border-bottom: 1px solid var(--border);
  padding: 22px 0;
  background: rgba(255,255,255,0.015);
  -webkit-mask-image: linear-gradient(90deg, transparent, black 8%, black 92%, transparent);
  mask-image: linear-gradient(90deg, transparent, black 8%, black 92%, transparent);
}
.marquee-track { display: flex; gap: 60px; width: max-content; animation: marquee 26s linear infinite; }
.marquee-track span { font-family: 'Space Grotesk', sans-serif; font-size: 15px; color: var(--text-dimmer); white-space: nowrap; display: flex; align-items: center; gap: 10px; }
.marquee-track span::before { content: "◆"; color: var(--blue-500); font-size: 8px; }
@keyframes marquee { from { transform: translateX(0); } to { transform: translateX(-50%); } }

/* ---------- Stats strip ---------- */
.stats-strip {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 1px;
  background: var(--border);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  overflow: hidden;
}
.stat-cell { background: var(--bg-alt); padding: 30px 20px; text-align: center; }
.stat-cell .num { font-family: 'Space Grotesk', sans-serif; font-weight: 700; font-size: clamp(26px, 3vw, 34px); background: var(--grad-text); -webkit-background-clip: text; background-clip: text; color: transparent; }
.stat-cell .lbl { font-size: 13px; color: var(--text-dim); margin-top: 6px; }
@media (max-width: 760px) { .stats-strip { grid-template-columns: repeat(2, 1fr); } }

/* ---------- Benefit grid ---------- */
.benefit-grid { display: grid; grid-template-columns: repeat(5, 1fr); gap: 18px; }
.benefit-item { text-align: center; padding: 26px 14px; border-radius: var(--radius); border: 1px solid var(--border); background: rgba(255,255,255,0.02); transition: transform .35s var(--ease), border-color .35s; }
.benefit-item:hover { transform: translateY(-6px); border-color: var(--border-strong); }
.benefit-item .ico { width: 56px; height: 56px; margin: 0 auto 14px; border-radius: 50%; display: flex; align-items: center; justify-content: center; background: var(--grad-brand-soft); border: 1px solid rgba(80,140,255,0.25); font-size: 24px; }
.benefit-item span { font-size: 13.5px; font-weight: 600; color: var(--text); }
@media (max-width: 880px) { .benefit-grid { grid-template-columns: repeat(2, 1fr); } }

/* ---------- How it works steps ---------- */
.steps { position: relative; display: grid; grid-template-columns: repeat(5, 1fr); gap: 18px; counter-reset: step; }
.steps::before {
  content: "";
  position: absolute; top: 34px; left: 8%; right: 8%; height: 2px;
  background: linear-gradient(90deg, transparent, var(--border-strong) 15%, var(--border-strong) 85%, transparent);
}
.step { position: relative; text-align: center; padding-top: 4px; }
.step .step-num {
  counter-increment: step;
  width: 68px; height: 68px; margin: 0 auto 18px;
  border-radius: 50%;
  background: var(--surface-2);
  border: 1px solid var(--border-strong);
  display: flex; align-items: center; justify-content: center;
  font-size: 26px;
  position: relative; z-index: 1;
}
.step h4 { font-size: 15px; margin-bottom: 6px; }
.step p { font-size: 13.5px; }
@media (max-width: 980px) { .steps { grid-template-columns: repeat(2, 1fr); } .steps::before { display: none; } }

/* ---------- App showcase ---------- */
.showcase-strip {
  display: flex;
  gap: 26px;
  overflow-x: auto;
  padding: 30px 6px 20px;
  scroll-snap-type: x mandatory;
}
.showcase-strip::-webkit-scrollbar { height: 8px; }
.showcase-item { flex: 0 0 auto; scroll-snap-align: center; text-align: center; }
.showcase-item .phone { width: 220px; }
.showcase-item h4 { font-size: 14px; margin-top: 16px; }
.showcase-item p { font-size: 12.5px; max-width: 220px; margin: 4px auto 0; }

.app-feature-grid { display: grid; grid-template-columns: repeat(2, 1fr); gap: 20px; margin-top: 20px; }
.app-feature { display: flex; gap: 14px; align-items: flex-start; }
.app-feature .dot-ico { width: 40px; height: 40px; flex-shrink: 0; border-radius: 12px; background: var(--grad-brand-soft); border: 1px solid rgba(80,140,255,0.25); display: flex; align-items: center; justify-content: center; font-size: 18px; }
.app-feature h5 { margin: 0 0 4px; font-size: 14.5px; }
.app-feature p { margin: 0; font-size: 13px; }

.gallery-block { display: grid; grid-template-columns: 0.85fr 1.15fr; gap: 60px; align-items: center; }
.gallery-block.reverse { grid-template-columns: 1.15fr 0.85fr; }
.gallery-block.reverse .gallery-visual { order: 2; }
.gallery-visual { display: flex; justify-content: center; }
@media (max-width: 900px) {
  .gallery-block, .gallery-block.reverse { grid-template-columns: 1fr; text-align: center; }
  .gallery-block.reverse .gallery-visual { order: 0; }
  .app-feature-grid { grid-template-columns: 1fr; }
}

/* ---------- Manual / Product page ---------- */
.spec-table { width: 100%; border-collapse: collapse; margin-top: 10px; }
.spec-table th, .spec-table td { text-align: left; padding: 14px 18px; border-bottom: 1px solid var(--light-border); font-size: 14.5px; }
.spec-table th { color: var(--light-text-dim); font-weight: 600; font-size: 12.5px; text-transform: uppercase; letter-spacing: 0.06em; }
.spec-table tr:last-child td { border-bottom: none; }
.spec-table td:first-child { font-weight: 700; color: var(--blue-600); white-space: nowrap; }

.keypad-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 16px; }
.keypad-item { background: var(--light-surface); border: 1px solid var(--light-border); border-radius: var(--radius); padding: 22px; display: flex; gap: 14px; align-items: flex-start; }
.keypad-item .key-badge {
  width: 46px; height: 46px; border-radius: 12px; flex-shrink: 0;
  display: flex; align-items: center; justify-content: center;
  font-weight: 700; font-size: 14px; color: #fff;
  background: var(--grad-brand);
}
.keypad-item h5 { margin: 0 0 4px; font-size: 14.5px; color: var(--light-text); }
.keypad-item p { margin: 0; font-size: 13px; }
@media (max-width: 880px) { .keypad-grid { grid-template-columns: 1fr 1fr; } }
@media (max-width: 560px) { .keypad-grid { grid-template-columns: 1fr; } }

.install-steps { counter-reset: inst; }
.install-step { display: grid; grid-template-columns: 52px 1fr; gap: 20px; padding: 22px 0; border-bottom: 1px dashed var(--light-border); }
.install-step:last-child { border-bottom: none; }
.install-step .n {
  counter-increment: inst;
  width: 52px; height: 52px; border-radius: 50%;
  background: var(--grad-brand); color: #fff;
  display: flex; align-items: center; justify-content: center;
  font-family: 'Space Grotesk', sans-serif; font-weight: 700; font-size: 20px;
}
.install-step h5 { margin: 0 0 6px; font-size: 16px; color: var(--light-text); }
.install-step p { margin: 0; }

.mode-compare { display: grid; grid-template-columns: 1fr 1fr; gap: 24px; }
.mode-card { border-radius: var(--radius); padding: 30px; }
.mode-card.auto { background: linear-gradient(160deg, #eef5ff, #e2ecff); border: 1px solid #c9dcff; }
.mode-card.manual { background: var(--light-surface); border: 1px solid var(--light-border); }
.mode-card h4 { color: var(--light-text); }
.mode-card ul { margin-top: 14px; }
.mode-card li { display: flex; gap: 10px; margin-bottom: 10px; font-size: 14.5px; color: var(--light-text-dim); }
.mode-card .step-line { display: flex; align-items: center; gap: 10px; font-size: 13.5px; color: var(--light-text-dim); padding: 8px 0; }
.mode-card .arrow { color: var(--blue-500); font-weight: 700; }
@media (max-width: 800px) { .mode-compare { grid-template-columns: 1fr; } }

.safety-list { display: grid; grid-template-columns: 1fr 1fr; gap: 14px; }
.safety-item { display: flex; gap: 12px; align-items: flex-start; background: var(--light-surface); border: 1px solid var(--light-border); border-radius: 14px; padding: 16px 18px; }
.safety-item .n { color: var(--amber); font-size: 18px; }
@media (max-width: 700px) { .safety-list { grid-template-columns: 1fr; } }

.wiring-diagram { background: var(--light-surface); border: 1px solid var(--light-border); border-radius: var(--radius); padding: 34px; }
.terminal-row { display: flex; justify-content: center; gap: 10px; margin: 24px 0; flex-wrap: wrap; }
.terminal {
  width: 70px; height: 70px; border-radius: 12px;
  background: linear-gradient(160deg, #dfe6f2, #b9c5da);
  border: 1px solid #9fb0cc;
  display: flex; flex-direction: column; align-items: center; justify-content: center;
  font-family: 'Space Grotesk', sans-serif; font-weight: 700; font-size: 20px; color: #1f2a44;
  box-shadow: 0 3px 0 #8fa0bc;
}
.terminal small { font-size: 9px; font-weight: 600; color: #4a5776; margin-top: 2px; }
.terminal.motor { background: linear-gradient(160deg, #ffe3e3, #ffc2c2); border-color: #f3a5a5; box-shadow: 0 3px 0 #e39a9a;}
.terminal.supply { background: linear-gradient(160deg, #dff5e6, #b9ebc7); border-color: #9ed8ae; box-shadow: 0 3px 0 #8fc99e;}
.terminal.starter { background: linear-gradient(160deg, #fff2d6, #ffe2a6); border-color: #f0cf8a; box-shadow: 0 3px 0 #dcb96f;}
.wire-legend { display: flex; gap: 24px; justify-content: center; flex-wrap: wrap; margin-top: 18px; }
.wire-legend .item { display: flex; align-items: center; gap: 8px; font-size: 13px; color: var(--light-text-dim); }
.wire-legend .swatch { width: 14px; height: 14px; border-radius: 4px; }

/* ---------- Download card ---------- */
.download-card {
  display: flex;
  align-items: center;
  gap: 22px;
  padding: 26px 30px;
  max-width: 620px;
  margin: 36px auto 0;
}
.download-card .dl-icon {
  width: 64px; height: 64px; flex-shrink: 0;
  border-radius: 16px;
  background: var(--grad-brand);
  display: flex; align-items: center; justify-content: center;
  font-size: 30px;
  box-shadow: 0 12px 28px -8px rgba(43,110,240,0.6);
}
.download-card .dl-body { flex: 1; text-align: left; }
.download-card h4 { margin: 0 0 4px; font-size: 16.5px; }
.download-card .dl-meta { display: flex; gap: 10px; flex-wrap: wrap; margin-top: 8px; }
.download-card .dl-meta .pill { font-size: 11.5px; }
@media (max-width: 560px) {
  .download-card { flex-direction: column; text-align: center; padding: 26px 20px; }
  .download-card .dl-body { text-align: center; }
  .download-card .dl-meta { justify-content: center; }
}

/* ---------- Contact page ---------- */
.contact-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 24px; }
.contact-card { text-align: center; }
.avatar {
  width: 78px; height: 78px; border-radius: 50%;
  margin: 0 auto 18px;
  background: var(--grad-brand);
  display: flex; align-items: center; justify-content: center;
  font-family: 'Space Grotesk', sans-serif; font-weight: 700; font-size: 24px; color: #fff;
  box-shadow: 0 12px 28px -8px rgba(43,110,240,0.6);
}
.contact-card h4 { font-size: 18px; margin-bottom: 2px; }
.contact-card .role { color: var(--cyan-300); font-size: 12.5px; font-weight: 600; letter-spacing: 0.04em; text-transform: uppercase; margin-bottom: 16px; }
.contact-line { display: flex; align-items: center; justify-content: center; gap: 8px; font-size: 13.5px; color: var(--text-dim); padding: 8px 0; border-top: 1px solid var(--border); }
.contact-line:first-of-type { border-top: 1px solid var(--border); margin-top: 4px; }
.contact-line a:hover { color: var(--cyan-300); }
@media (max-width: 880px) { .contact-grid { grid-template-columns: 1fr; } }

.contact-split { display: grid; grid-template-columns: 1fr 1fr; gap: 50px; align-items: start; }
.info-row { display: flex; gap: 16px; padding: 18px 0; border-bottom: 1px solid var(--border); }
.info-row:last-child { border-bottom: none; }
.info-row h5 { margin: 0 0 4px; font-size: 14.5px; }
.info-row p { margin: 0; font-size: 13.5px; }

.form-field { margin-bottom: 18px; }
.form-field label { display: block; font-size: 13px; font-weight: 600; color: var(--text-dim); margin-bottom: 8px; }
.form-field input, .form-field textarea, .form-field select {
  width: 100%;
  background: rgba(255,255,255,0.04);
  border: 1px solid var(--border-strong);
  border-radius: 12px;
  padding: 13px 16px;
  color: var(--text);
  font-family: inherit;
  font-size: 14.5px;
  transition: border-color .25s, box-shadow .25s, background .25s;
}
.form-field textarea { resize: vertical; min-height: 120px; }
.form-field input:focus, .form-field textarea:focus, .form-field select:focus {
  outline: none;
  border-color: var(--blue-500);
  box-shadow: 0 0 0 4px rgba(59,123,246,0.18);
  background: rgba(255,255,255,0.06);
}
.form-row-2 { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; }
@media (max-width: 700px) { .contact-split { grid-template-columns: 1fr; } .form-row-2 { grid-template-columns: 1fr; } }

.form-status { font-size: 13.5px; padding: 12px 16px; border-radius: 10px; margin-top: 14px; display: none; }
.form-status.show { display: block; }
.form-status.ok { background: rgba(47,214,107,0.12); border: 1px solid rgba(47,214,107,0.3); color: #6dfca4; }

/* ---------- Coming soon / Raise ticket ---------- */
.coming-soon-hero { text-align: center; padding: 190px 0 140px; position: relative; }
.cs-orb {
  width: 180px; height: 180px; margin: 0 auto 40px;
  position: relative;
}
.cs-orb .ring {
  position: absolute; inset: 0;
  border-radius: 50%;
  border: 2px dashed rgba(80,140,255,0.35);
  animation: spin 14s linear infinite;
}
.cs-orb .ring2 { inset: 18px; border-color: rgba(56,217,232,0.3); animation: spin 10s linear infinite reverse; }
.cs-orb .core {
  position: absolute; inset: 44px;
  border-radius: 50%;
  background: var(--grad-brand);
  display: flex; align-items: center; justify-content: center;
  font-size: 44px;
  box-shadow: 0 0 60px rgba(59,123,246,0.55);
  animation: pulse-core 2.4s ease-in-out infinite;
}
@keyframes spin { to { transform: rotate(360deg); } }
@keyframes pulse-core { 0%,100% { transform: scale(1); } 50% { transform: scale(1.06); } }

.progress-bar { max-width: 380px; margin: 34px auto 0; height: 8px; border-radius: 999px; background: rgba(255,255,255,0.06); overflow: hidden; position: relative; }
.progress-bar .fill { position: absolute; inset: 0; width: 62%; background: var(--grad-brand); border-radius: 999px; }
.progress-bar .fill::after {
  content: ""; position: absolute; inset: 0;
  background: linear-gradient(90deg, transparent, rgba(255,255,255,0.5), transparent);
  width: 40%;
  animation: shine 1.8s linear infinite;
}
@keyframes shine { from { transform: translateX(-120%); } to { transform: translateX(280%); } }
.progress-label { font-size: 12.5px; color: var(--text-dimmer); margin-top: 12px; letter-spacing: 0.04em; }

.notify-row { display: flex; gap: 10px; max-width: 420px; margin: 34px auto 0; }
.notify-row input {
  flex: 1;
  background: rgba(255,255,255,0.05);
  border: 1px solid var(--border-strong);
  border-radius: 999px;
  padding: 13px 20px;
  color: var(--text);
  font-family: inherit;
  font-size: 14px;
}
.notify-row input:focus { outline: none; border-color: var(--blue-500); }

.feature-preview-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 20px; margin-top: 20px; }
.feature-preview { opacity: 0.55; filter: grayscale(0.4); }
.feature-preview .pill { background: rgba(255,178,56,0.1); border-color: rgba(255,178,56,0.3); color: var(--amber); }
@media (max-width: 880px) { .feature-preview-grid { grid-template-columns: 1fr; } }

/* ---------- 404-ish / small pages shared ---------- */
.cta-band {
  border-radius: var(--radius-lg);
  padding: 64px 48px;
  text-align: center;
  background: radial-gradient(circle at 30% 20%, rgba(59,123,246,0.25), transparent 55%), linear-gradient(160deg, #0e1424, #080b14);
  border: 1px solid var(--border-strong);
  position: relative;
  overflow: hidden;
}
.cta-band h2 { font-size: clamp(24px, 3.6vw, 36px); }
.cta-band .btn-row { display: flex; gap: 14px; justify-content: center; margin-top: 26px; flex-wrap: wrap; }
