/* =========================================================
   Site styles — solar / power solutions business website
   Colors: deep navy + solar amber + energy green
   ========================================================= */
:root {
  --navy: #0b2240;
  --navy-2: #12325c;
  --ink: #13233a;
  --text: #3b4a5e;
  --muted: #6b7a8f;
  --line: #e3e9f1;
  --bg: #ffffff;
  --bg-alt: #f3f7fc;
  --amber: #f5a524;
  --amber-d: #d98a0b;
  --amber-l: #fff4df;
  --green: #18a058;
  --green-l: #e5f7ee;
  --sky: #2f80ed;
  --danger: #d64545;
  --radius: 14px;
  --radius-sm: 8px;
  --shadow: 0 10px 30px rgba(11, 34, 64, .08);
  --shadow-lg: 0 20px 50px rgba(11, 34, 64, .16);
  --max: 1200px;
  --font-head: "Poppins", "Segoe UI", system-ui, -apple-system, sans-serif;
  --font-body: "Inter", "Segoe UI", system-ui, -apple-system, sans-serif;
}

*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  font-family: var(--font-body);
  font-size: 16px;
  line-height: 1.65;
  color: var(--text);
  background: var(--bg);
  -webkit-font-smoothing: antialiased;
}
img { max-width: 100%; display: block; }
a { color: var(--sky); text-decoration: none; }
a:hover { text-decoration: underline; }
h1, h2, h3, h4 { font-family: var(--font-head); color: var(--ink); line-height: 1.2; margin: 0 0 .6em; }
h1 { font-size: clamp(2rem, 4.6vw, 3.4rem); font-weight: 700; letter-spacing: -.02em; }
h2 { font-size: clamp(1.6rem, 3vw, 2.4rem); font-weight: 700; letter-spacing: -.01em; }
h3 { font-size: 1.2rem; font-weight: 600; }
p { margin: 0 0 1em; }
.container { width: 100%; max-width: var(--max); margin: 0 auto; padding: 0 20px; }
.skip-link { position: absolute; left: -999px; top: 0; background: var(--amber); color: var(--navy); padding: 8px 14px; z-index: 1000; }
.skip-link:focus { left: 10px; }

/* ---------- Buttons ---------- */
.btn {
  display: inline-flex; align-items: center; gap: .5em;
  padding: .8em 1.4em; border-radius: 999px; border: 2px solid transparent;
  font-family: var(--font-head); font-weight: 600; font-size: .95rem;
  cursor: pointer; transition: transform .15s, box-shadow .15s, background .15s, color .15s;
  text-decoration: none !important; line-height: 1.2;
}
.btn:hover { transform: translateY(-2px); }
.btn-primary { background: var(--amber); color: var(--navy); box-shadow: 0 6px 18px rgba(245, 165, 36, .35); }
.btn-primary:hover { background: #ffb53d; }
.btn-dark { background: var(--navy); color: #fff; }
.btn-dark:hover { background: var(--navy-2); }
.btn-outline { border-color: currentColor; color: var(--navy); background: transparent; }
.btn-ghost { border-color: rgba(255,255,255,.55); color: #fff; background: rgba(255,255,255,.06); }
.btn-ghost:hover { background: rgba(255,255,255,.16); }
.btn-wa { background: #25d366; color: #fff; }
.btn-sm { padding: .55em 1em; font-size: .85rem; }
.btn-row { display: flex; flex-wrap: wrap; gap: 12px; }

/* ---------- Top bar & header ---------- */
.topbar { background: var(--navy); color: #c8d4e6; font-size: .85rem; }
.topbar .container { display: flex; justify-content: space-between; align-items: center; gap: 12px; min-height: 40px; flex-wrap: wrap; }
.topbar a { color: #fff; }
.topbar .tb-left { display: flex; gap: 20px; flex-wrap: wrap; }
.topbar .tb-left span { display: inline-flex; align-items: center; gap: 6px; }
.lang-select { background: transparent; color: #fff; border: 1px solid rgba(255,255,255,.3); border-radius: 6px; padding: 3px 6px; font-size: .82rem; }
.lang-select option { color: var(--ink); }
#google_translate_element { display: none; }

.site-header { position: sticky; top: env(safe-area-inset-top, 0px); z-index: 100; background: rgba(255,255,255,.96); backdrop-filter: blur(8px); border-bottom: 1px solid var(--line); }
.nav { display: flex; align-items: center; justify-content: space-between; min-height: 72px; gap: 16px; }
.logo { display: flex; align-items: center; gap: 10px; color: var(--navy); text-decoration: none !important; }
.logo svg, .logo img { width: 46px; height: 46px; flex: none; object-fit: contain; }
.site-footer .logo img { background: #fff; border-radius: 50%; padding: 4px; width: 54px; height: 54px; }
.logo-text { font-family: var(--font-head); font-weight: 700; font-size: 1.15rem; line-height: 1.05; }
.logo-text small { display: block; font-size: .68rem; font-weight: 600; letter-spacing: .12em; text-transform: uppercase; color: #3f8a2a; }
.site-footer .logo-text small { color: #8fd16b; }
.nav-links { display: flex; align-items: center; gap: 4px; list-style: none; margin: 0; padding: 0; }
.nav-links a { display: block; padding: 8px 11px; border-radius: 8px; color: var(--ink); font-weight: 500; font-size: .92rem; text-decoration: none; }
.nav-links a:hover { background: var(--bg-alt); }
.nav-links a.active { color: var(--amber-d); }
.nav-links .btn { margin-left: 8px; color: var(--navy); }
.nav-toggle { display: none; background: none; border: 0; padding: 8px; cursor: pointer; color: var(--navy); }
.nav-toggle svg { width: 28px; height: 28px; }

@media (max-width: 1080px) {
  .nav-toggle { display: block; }
  .nav-links {
    position: absolute; left: 0; right: 0; top: 100%;
    flex-direction: column; align-items: stretch; gap: 0;
    background: #fff; border-bottom: 1px solid var(--line); box-shadow: var(--shadow);
    padding: 8px 16px 16px; display: none;
  }
  .nav-links.open { display: flex; }
  .nav-links a { padding: 12px 8px; border-bottom: 1px solid var(--line); border-radius: 0; }
  .nav-links .btn { margin: 12px 0 0; justify-content: center; border-radius: 999px; }
}

/* ---------- Sections ---------- */
section { padding: 88px 0; }
.section-alt { background: var(--bg-alt); }
.section-dark { background: var(--navy); color: #c8d4e6; }
.section-dark h2, .section-dark h3 { color: #fff; }
.eyebrow { display: inline-block; font-family: var(--font-head); font-size: .78rem; font-weight: 600; letter-spacing: .16em; text-transform: uppercase; color: var(--amber-d); margin-bottom: 12px; }
.section-dark .eyebrow { color: var(--amber); }
.section-head { max-width: 720px; margin-bottom: 48px; }
.section-head.center { margin-left: auto; margin-right: auto; text-align: center; }
.lead { font-size: 1.12rem; color: var(--muted); }
.section-dark .lead { color: #a9b8cd; }

.grid { display: grid; gap: 24px; }
.grid-2 { grid-template-columns: repeat(2, 1fr); }
.grid-3 { grid-template-columns: repeat(3, 1fr); }
.grid-4 { grid-template-columns: repeat(4, 1fr); }
@media (max-width: 960px) { .grid-3, .grid-4 { grid-template-columns: repeat(2, 1fr); } }
@media (max-width: 640px) { .grid-2, .grid-3, .grid-4 { grid-template-columns: 1fr; } section { padding: 64px 0; } }

.split { display: grid; grid-template-columns: 1.05fr 1fr; gap: 56px; align-items: center; }
.split.reverse > :first-child { order: 2; }
@media (max-width: 900px) { .split { grid-template-columns: 1fr; gap: 32px; } .split.reverse > :first-child { order: 0; } }

/* ---------- Hero ---------- */
.hero { position: relative; color: #fff; padding: 110px 0 96px; overflow: hidden; background: var(--navy); }
.hero-bg { position: absolute; inset: 0; background-size: cover; background-position: center; }
.hero-bg::after { content: ""; position: absolute; inset: 0; background: linear-gradient(100deg, rgba(8,24,46,.94) 0%, rgba(8,24,46,.78) 48%, rgba(8,24,46,.25) 100%); }
.hero .container { position: relative; }
.hero h1 { color: #fff; max-width: 760px; }
.hero h1 .hl { color: var(--amber); }
.hero .tagline { font-family: var(--font-head); font-size: 1.15rem; color: #ffd48a; margin-bottom: 14px; }
.hero p.desc { max-width: 600px; color: #d4deeb; font-size: 1.08rem; }
.hero .btn-row { margin-top: 28px; }
.hero-meta { display: flex; flex-wrap: wrap; gap: 10px; margin-top: 36px; }
.chip { display: inline-flex; align-items: center; gap: 6px; padding: 6px 14px; border-radius: 999px; font-size: .85rem; background: rgba(255,255,255,.1); border: 1px solid rgba(255,255,255,.2); color: #fff; }
.hero-caption { position: absolute; right: 20px; bottom: 14px; font-size: .72rem; color: rgba(255,255,255,.6); }

.page-hero { background: linear-gradient(120deg, var(--navy) 0%, var(--navy-2) 100%); color: #d4deeb; padding: 72px 0 64px; position: relative; overflow: hidden; }
.page-hero::after { content: ""; position: absolute; right: -120px; top: -120px; width: 380px; height: 380px; border-radius: 50%; background: radial-gradient(circle, rgba(245,165,36,.35), transparent 70%); }
.page-hero h1 { color: #fff; font-size: clamp(1.9rem, 4vw, 2.8rem); }
.page-hero p { max-width: 680px; font-size: 1.08rem; margin: 0; }
.breadcrumb { font-size: .85rem; margin-bottom: 10px; color: #9fb0c8; }
.breadcrumb a { color: var(--amber); }

/* ---------- Cards ---------- */
.card { background: #fff; border: 1px solid var(--line); border-radius: var(--radius); padding: 28px; box-shadow: var(--shadow); transition: transform .2s, box-shadow .2s; }
.card:hover { transform: translateY(-4px); box-shadow: var(--shadow-lg); }
.card .icon { width: 54px; height: 54px; border-radius: 14px; background: var(--amber-l); color: var(--amber-d); display: grid; place-items: center; margin-bottom: 18px; }
.card .icon svg { width: 28px; height: 28px; }
.card p:last-child { margin-bottom: 0; }
.card-img { padding: 0; overflow: hidden; display: flex; flex-direction: column; }
.card-img .ph { aspect-ratio: 16/10; overflow: hidden; background: var(--bg-alt); }
.card-img .ph img { width: 100%; height: 100%; object-fit: cover; transition: transform .5s; }
.card-img:hover .ph img { transform: scale(1.05); }
.card-img .body { padding: 22px 24px 26px; display: flex; flex-direction: column; flex: 1; }
.card-img .body .more { margin-top: auto; padding-top: 10px; font-weight: 600; font-family: var(--font-head); font-size: .9rem; }
.tag { display: inline-block; font-size: .72rem; font-weight: 600; letter-spacing: .06em; text-transform: uppercase; color: var(--green); background: var(--green-l); padding: 3px 10px; border-radius: 999px; margin-bottom: 10px; }
ul.ticks { list-style: none; padding: 0; margin: 0 0 1em; }
ul.ticks li { position: relative; padding-left: 28px; margin-bottom: 8px; }
ul.ticks li::before { content: ""; position: absolute; left: 0; top: .35em; width: 18px; height: 18px; border-radius: 50%; background: var(--green-l) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%2318a058' stroke-width='3.5' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M5 12l5 5L20 7'/%3E%3C/svg%3E") center/11px no-repeat; }
.section-dark ul.ticks li::before { background-color: rgba(24,160,88,.2); }

.cat-links { display: flex; flex-wrap: wrap; gap: 10px; margin-top: 36px; justify-content: center; }
.cat-links a { padding: 8px 16px; border: 1px solid var(--line); border-radius: 999px; background: #fff; color: var(--ink); font-size: .9rem; font-weight: 500; }
.cat-links a:hover { border-color: var(--amber); text-decoration: none; }

/* ---------- Steps ---------- */
.steps { counter-reset: step; }
.step { position: relative; padding: 28px 24px; border-radius: var(--radius); background: rgba(255,255,255,.04); border: 1px solid rgba(255,255,255,.1); }
.step::before { counter-increment: step; content: "0" counter(step); font-family: var(--font-head); font-weight: 700; font-size: 2.4rem; color: var(--amber); opacity: .9; display: block; margin-bottom: 8px; }
.steps.light .step { background: #fff; border-color: var(--line); box-shadow: var(--shadow); }

/* ---------- Banner ---------- */
.banner { background: linear-gradient(110deg, var(--amber) 0%, #ffc85c 100%); color: var(--navy); padding: 56px 0; }
.banner .container { display: flex; justify-content: space-between; align-items: center; gap: 24px; flex-wrap: wrap; }
.banner h2 { margin: 0 0 6px; color: var(--navy); }
.banner p { margin: 0; color: #4a3a12; }

/* ---------- Image frame ---------- */
.img-frame { position: relative; border-radius: 20px; overflow: hidden; box-shadow: var(--shadow-lg); }
.img-frame img { width: 100%; height: 100%; object-fit: cover; aspect-ratio: 4/3; }
.img-frame .badge { position: absolute; left: 18px; bottom: 18px; background: #fff; padding: 12px 16px; border-radius: 12px; box-shadow: var(--shadow); font-family: var(--font-head); font-weight: 600; color: var(--navy); font-size: .92rem; display: flex; gap: 10px; align-items: center; }
.img-frame .badge span { width: 10px; height: 10px; border-radius: 50%; background: var(--green); box-shadow: 0 0 0 4px var(--green-l); }

/* ---------- Forms ---------- */
.form-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 16px 18px; }
.form-grid .full { grid-column: 1 / -1; }
@media (max-width: 640px) { .form-grid { grid-template-columns: 1fr; } }
label { display: block; font-weight: 600; font-size: .88rem; color: var(--ink); margin-bottom: 6px; }
label .opt { font-weight: 400; color: var(--muted); }
input, select, textarea {
  width: 100%; font: inherit; font-size: .95rem; color: var(--ink);
  padding: 11px 13px; border: 1px solid #cfd8e4; border-radius: 10px; background: #fff;
  transition: border-color .15s, box-shadow .15s;
}
input:focus, select:focus, textarea:focus { outline: none; border-color: var(--amber); box-shadow: 0 0 0 4px rgba(245,165,36,.18); }
input[type=range] { padding: 0; accent-color: var(--amber-d); border: 0; }
input:invalid.touched, select:invalid.touched { border-color: var(--danger); }
.hint { font-size: .8rem; color: var(--muted); margin-top: 4px; }
.seg { display: inline-flex; background: var(--bg-alt); border-radius: 999px; padding: 4px; border: 1px solid var(--line); }
.seg button { border: 0; background: transparent; padding: 7px 16px; border-radius: 999px; font: 600 .85rem var(--font-head); color: var(--muted); cursor: pointer; }
.seg button.on { background: #fff; color: var(--navy); box-shadow: 0 2px 6px rgba(0,0,0,.08); }
.form-status { margin-top: 14px; padding: 12px 16px; border-radius: 10px; background: var(--green-l); color: #116b3c; font-size: .92rem; }
.form-status.err { background: #fde8e8; color: #9b2c2c; }

/* ---------- Calculator ---------- */
.calc { display: grid; grid-template-columns: 1fr 1.1fr; gap: 28px; align-items: start; }
@media (max-width: 900px) { .calc { grid-template-columns: 1fr; } }
.result-hero { background: linear-gradient(130deg, var(--navy), var(--navy-2)); color: #fff; border-radius: var(--radius); padding: 26px; margin-bottom: 18px; }
.result-hero .big { font-family: var(--font-head); font-size: 3rem; font-weight: 700; color: var(--amber); line-height: 1; }
.result-hero .big small { font-size: 1.2rem; color: #fff; }
.stats { display: grid; grid-template-columns: repeat(2, 1fr); gap: 12px; }
.stat { background: #fff; border: 1px solid var(--line); border-radius: 12px; padding: 14px 16px; }
.stat .k { font-size: .78rem; color: var(--muted); }
.stat .v { font-family: var(--font-head); font-weight: 700; color: var(--ink); font-size: 1.25rem; }
.stat.good .v { color: var(--green); }
.warn { background: var(--amber-l); border: 1px solid #f7d79a; color: #7a5208; border-radius: 10px; padding: 12px 14px; font-size: .9rem; margin-top: 12px; }

/* ---------- Design studio ---------- */
.studio { display: grid; grid-template-columns: 340px 1fr; gap: 24px; align-items: start; }
@media (max-width: 900px) { .studio { grid-template-columns: 1fr; } }
.canvas-box { background: #fff; border: 1px solid var(--line); border-radius: var(--radius); padding: 14px; box-shadow: var(--shadow); }
.canvas-box canvas { width: 100%; height: auto; display: block; border-radius: 8px; cursor: pointer; touch-action: manipulation; }
.legend { display: flex; gap: 16px; flex-wrap: wrap; font-size: .82rem; color: var(--muted); margin-top: 10px; }
.legend i { display: inline-block; width: 12px; height: 12px; border-radius: 3px; vertical-align: -1px; margin-right: 5px; }

/* ---------- Products ---------- */
.filters { display: flex; flex-wrap: wrap; gap: 8px; margin-bottom: 32px; }
.filters button { border: 1px solid var(--line); background: #fff; padding: 8px 16px; border-radius: 999px; font: 600 .88rem var(--font-head); color: var(--ink); cursor: pointer; }
.filters button.on { background: var(--navy); color: #fff; border-color: var(--navy); }
.product .body h3 { margin-bottom: .35em; }
.product .body p { font-size: .93rem; }
.product ul.ticks li { font-size: .88rem; margin-bottom: 4px; }

/* ---------- Gallery ---------- */
.gallery { display: grid; grid-template-columns: repeat(3, 1fr); gap: 18px; }
@media (max-width: 900px) { .gallery { grid-template-columns: repeat(2, 1fr); } }
@media (max-width: 560px) { .gallery { grid-template-columns: 1fr; } }
.g-item { position: relative; border-radius: var(--radius); overflow: hidden; cursor: zoom-in; aspect-ratio: 4/3; border: 0; padding: 0; background: var(--bg-alt); }
.g-item img { width: 100%; height: 100%; object-fit: cover; transition: transform .5s; }
.g-item:hover img { transform: scale(1.06); }
.g-item .cap { position: absolute; left: 0; right: 0; bottom: 0; padding: 40px 16px 14px; background: linear-gradient(transparent, rgba(8,24,46,.85)); color: #fff; text-align: left; font-size: .9rem; }
.g-item .cap b { display: block; font-family: var(--font-head); font-size: 1rem; }
.lightbox { position: fixed; inset: 0; background: rgba(5,14,28,.92); display: grid; place-items: center; z-index: 500; padding: 20px; }
.lightbox img { max-height: 82vh; width: auto; border-radius: 10px; }
.lightbox p { color: #dfe7f2; text-align: center; margin-top: 12px; }
.lightbox button { position: absolute; top: calc(14px + env(safe-area-inset-top, 0px)); right: 18px; background: rgba(255,255,255,.12); color: #fff; border: 0; width: 44px; height: 44px; border-radius: 50%; font-size: 1.5rem; cursor: pointer; }

/* ---------- Tables / FAQ ---------- */
.table-wrap { overflow-x: auto; border-radius: var(--radius); border: 1px solid var(--line); background: #fff; }
table { width: 100%; border-collapse: collapse; font-size: .95rem; }
th, td { padding: 14px 18px; text-align: left; border-bottom: 1px solid var(--line); }
th { background: var(--bg-alt); font-family: var(--font-head); color: var(--ink); font-size: .88rem; }
tr:last-child td { border-bottom: 0; }
details { background: #fff; border: 1px solid var(--line); border-radius: 12px; padding: 4px 20px; margin-bottom: 12px; }
details summary { cursor: pointer; font-family: var(--font-head); font-weight: 600; color: var(--ink); padding: 14px 0; list-style: none; position: relative; padding-right: 28px; }
details summary::-webkit-details-marker { display: none; }
details summary::after { content: "+"; position: absolute; right: 0; top: 10px; font-size: 1.4rem; color: var(--amber-d); }
details[open] summary::after { content: "−"; }
details p { padding-bottom: 10px; }

/* ---------- Contact ---------- */
.contact-card { display: flex; gap: 16px; align-items: flex-start; }
.contact-card .icon { flex: none; margin: 0; }
.contact-card h3 { margin-bottom: .2em; font-size: 1.02rem; }
.contact-card p { margin: 0; }

/* ---------- Footer ---------- */
.site-footer { background: #071a32; color: #9fb0c8; padding: 64px 0 calc(24px + env(safe-area-inset-bottom, 0px)); font-size: .92rem; }
.site-footer h4 { color: #fff; font-size: 1rem; margin-bottom: 14px; }
.site-footer a { color: #c8d4e6; }
.site-footer ul { list-style: none; padding: 0; margin: 0; }
.site-footer li { margin-bottom: 8px; }
.footer-grid { display: grid; grid-template-columns: 1.4fr 1fr 1fr 1.2fr; gap: 32px; }
@media (max-width: 900px) { .footer-grid { grid-template-columns: 1fr 1fr; } }
@media (max-width: 560px) { .footer-grid { grid-template-columns: 1fr; } }
.site-footer .logo { color: #fff; margin-bottom: 14px; }
.footer-bottom { border-top: 1px solid rgba(255,255,255,.1); margin-top: 40px; padding-top: 20px; display: flex; justify-content: space-between; flex-wrap: wrap; gap: 10px; font-size: .82rem; }

.wa-float { position: fixed; right: 18px; bottom: calc(18px + env(safe-area-inset-bottom, 0px)); width: 56px; height: 56px; border-radius: 50%; background: #25d366; display: grid; place-items: center; box-shadow: 0 8px 24px rgba(0,0,0,.25); z-index: 90; transition: transform .2s; }
.wa-float:hover { transform: scale(1.08); }
.wa-float svg { width: 30px; height: 30px; fill: #fff; }

/* ---------- Utilities ---------- */
[hidden] { display: none !important; }
.reveal { opacity: 0; transform: translateY(24px); transition: opacity .7s ease, transform .7s ease; }
.reveal.in { opacity: 1; transform: none; }
.no-js .reveal { opacity: 1; transform: none; }
.center { text-align: center; }
.mt-0 { margin-top: 0; } .mt-2 { margin-top: 24px; } .mt-3 { margin-top: 40px; }
.small { font-size: .85rem; color: var(--muted); }
.note { font-size: .82rem; color: var(--muted); font-style: italic; }

.map-embed { width: 100%; aspect-ratio: 16/10; border: 0; border-radius: var(--radius); box-shadow: var(--shadow); }
.contact-card p, .contact-card a, .site-footer li, .site-footer a, .topbar a { overflow-wrap: anywhere; }
.contact-card > div { min-width: 0; }
.brand-list { display: flex; flex-wrap: wrap; gap: 8px; }
.brand-list span { padding: 7px 14px; border-radius: 999px; background: var(--bg-alt); border: 1px solid var(--line); font: 600 .9rem var(--font-head); color: var(--ink); }
.values { display: grid; grid-template-columns: repeat(4, 1fr); gap: 16px; }
@media (max-width: 860px) { .values { grid-template-columns: repeat(2, 1fr); } }
.value { display: flex; gap: 12px; align-items: center; padding: 18px; border-radius: 14px; background: #fff; border: 1px solid var(--line); box-shadow: var(--shadow); }
.value .ic { font-size: 1.6rem; }
.value b { display: block; font-family: var(--font-head); color: var(--ink); font-size: .95rem; letter-spacing: .02em; }
.value span { font-size: .78rem; color: var(--muted); text-transform: uppercase; letter-spacing: .06em; }
@media (max-width: 860px) { .values { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; } .value { padding: 14px; gap: 8px; } .value b { font-size: .85rem; } .value span { font-size: .7rem; } }

/* ---------- Wiring diagram ---------- */
.wr-card { background: #fff; border: 1px solid var(--line); border-radius: 20px; box-shadow: var(--shadow); padding: 18px; }
.wr-scenes { display: flex; flex-wrap: wrap; gap: 8px; margin-bottom: 10px; }
.wr-scenes button { font: 600 .9rem var(--font-head); border: 1px solid var(--line); background: #fff; color: var(--ink); padding: 8px 16px; border-radius: 999px; cursor: pointer; transition: background .2s, color .2s; }
.wr-scenes button.on { background: #0f3d3b; color: #fff; border-color: #0f3d3b; }
.wr-scroll { overflow-x: auto; -webkit-overflow-scrolling: touch; border-radius: 14px; background: linear-gradient(180deg, #f7fbfb, #eef5f5); }
.wr-stage { min-width: 0; }
.wr-stage svg { display: block; width: 100%; height: auto; user-select: none; -webkit-user-select: none; }
.wr-wire { fill: none; stroke-width: 4; stroke-linecap: round; opacity: .35; transition: opacity .4s, stroke .4s; }
.wr-wire.live { opacity: .9; }
.wr-label { font: 700 17px var(--font-head); fill: var(--ink); }
.wr-tiny { font: 700 7px var(--font-body); }
.wr-badge { font: 700 12px var(--font-head); fill: #fde68a; }
.wr-tag { font: 700 11px var(--font-head); }
.wr-lcd { font: 700 13px "Consolas", "Courier New", monospace; fill: #4ade80; }
.wr-lcd-s { font: 700 6.5px "Consolas", monospace; fill: #86efac; letter-spacing: .05em; }
.wr-lcd.err, .wr-lcd-s.err { fill: #f87171; }
.wr-meter { font: 700 11px "Consolas", "Courier New", monospace; fill: #1a2e05; }
.wr-meter-s { font: 700 7px "Consolas", monospace; fill: #365314; }
.wr-tile { cursor: pointer; outline: none; }
.wr-tile .wr-glow { fill: none; stroke: var(--amber); stroke-width: 3; opacity: 0; transition: opacity .25s; }
.wr-tile:hover .wr-glow, .wr-tile:focus-visible .wr-glow { opacity: .5; }
.wr-tile.sel .wr-glow { opacity: 1; }
.wr-tile.down .wr-label { fill: #dc2626; }
.wr-win { fill: #475569; transition: fill .5s; }
.wr-win.lit { fill: #fcd34d; }
.wr-legend { display: flex; flex-wrap: wrap; gap: 8px 20px; align-items: center; margin: 12px 4px 4px; font-size: .9rem; color: var(--text); }
.wr-legend i { display: inline-block; width: 22px; height: 4px; border-radius: 2px; vertical-align: middle; margin-right: 6px; }
.wr-legend .dc { background: #0e9aa7; } .wr-legend .ac { background: #d9822b; } .wr-legend .imp { background: #2f6fe4; } .wr-legend .exp { background: #16a34a; }
.wr-hint { margin-left: auto; color: var(--muted); font-size: .85rem; }
.wr-bottom { display: grid; grid-template-columns: 1.3fr 1fr; gap: 16px; margin-top: 10px; }
@media (max-width: 800px) { .wr-bottom { grid-template-columns: 1fr; } .wr-hint { margin-left: 0; } }
.wr-scene-text { margin: 0; font-size: 1rem; }
.wr-info { background: #0f3d3b; color: #d5ecea; border-radius: 14px; padding: 14px 16px; }
.wr-info h4 { color: #fff; margin: 0 0 4px; font-size: 1rem; }
.wr-info p { margin: 0; font-size: .92rem; }

/* ---------- Circuit-board background ---------- */
.circuit-bg { position: fixed; inset: 0; width: 100%; height: 100%; pointer-events: none; z-index: 101; }
@media (min-width: 1081px) {
  .nav-links a.active { position: relative; color: #136f4b; background: #ecf8f1; border: 1px solid #9fd6b8; border-radius: 6px; padding: 6px 11px; box-shadow: 0 0 0 3px rgba(159, 214, 184, .25); }
  .nav-links a.active::before, .nav-links a.active::after { content: ""; position: absolute; left: 9px; right: 9px; height: 6px; background: repeating-linear-gradient(90deg, #8fcaa9 0 2px, transparent 2px 7px); }
  .nav-links a.active::before { top: -7px; } .nav-links a.active::after { bottom: -7px; }
}
@media print { .circuit-bg { display: none; } }
