/* ============================================================================
   ALG Electric Oy (pohja demo7, teemattu 22.10.2026)
   Viileä, tekninen, premium. Hehkuvat gradientit + lasimaiset (glass) pinnat +
   mono-aksentti. Sopii: IT, autoala, turva, teollisuus, startupit, automaatio.
   TEEMA VAIHDETAAN VAIN TÄSTÄ :root-lohkosta. Kaikki muu perii muuttujat.
   ============================================================================ */

:root {
  --c-accent: #F59E0B;   /* toissijainen aksentti: logon oranssi/keltainen (ALG Electric) */
  /* --- Efektivärit: teemattaessa vaihdetaan nämä, ei CSS:n sisältä käsin --- */
  --c-ok-bright: #34D399;   /* paneelin ok-arvo */
  /* Lomakkeen tilaviestit — teemattavissa kuten muutkin värit */
  --c-ok:  #34D399;
  --c-err: #F87171;
  /* ---- VÄRIT (syvä yö-navy + sähkönsininen→violetti hehku) ---- */
  --c-bg:        #08090F;   /* lähes musta, häivähdys sinistä */
  --c-bg-2:      #0C0E17;   /* osio-vaihtelu */
  --c-surface:   #11141F;   /* kortti / glass-pohja */
  --c-surface-2: #161A28;   /* nostettu pinta */
  --c-text:      #AEB4C6;   /* leipä (viileä harmaa) */
  --c-heading:   #F4F6FC;   /* otsikot (lähes valkoinen) */
  --c-muted:     #808596;   /* haalea */
  --c-border:    #232838;   /* hiusviiva tummalla */
  --c-primary:   #1E88F5;   /* logon sähkönsininen (ALG Electric) */
  --c-primary-2: #0B6FE0;   /* hover */
  --c-on-primary:#FFFFFF;
  --c-accent2:   var(--c-accent);   /* alias */   /* violetti (gradientin toinen pää) */
  --c-accent3:   #38BDF8;   /* logon vaalea sininen */
  --c-dark:      #060710;   /* syvin (footer) */
  --c-on-dark:   #C4C9D8;

  /* ---- LIUKUVÄRIT + HEHKU ---- */
  --grad:      linear-gradient(118deg, #0369A1 0%, #1D4ED8 55%, #1E3A8A 100%);   /* painikkeet ja merkit: valkoinen teksti ≥ 4,5:1 (21.10.2026) */
  --grad-text: linear-gradient(118deg, var(--c-accent3) 0%, var(--c-primary) 55%, #60A5FA 100%);   /* kirkas versio tummalle taustalle */
  --grad-soft: linear-gradient(118deg, color-mix(in srgb, var(--c-primary) 90%, #fff), var(--c-accent3));
  /* hero-orbit: isot, sumeat hehkupallot taustalle */
  --glow-cyan: none;   /* ei hehkutaustoja (muisti ei-hehkutaustoja) */
  --glow-vio: none;   /* ei hehkutaustoja (muisti ei-hehkutaustoja) */
  --glow-blue: none;   /* ei hehkutaustoja (muisti ei-hehkutaustoja) */
  /* hieno verkkoviiva-grid taustaksi (tech-tuntu) */
  --grid-lines: none;   /* ei ruudukkoviivoja */

  /* ---- MUODOT (pehmeästi pyöristetty, premium) ---- */
  --r-sm: 10px;
  --r:    16px;
  --r-lg: 24px;
  --r-pill: 999px;

  /* ---- VARJOT + HEHKU ---- */
  --shadow:    0 24px 60px -28px rgba(0,0,0,.9);
  --shadow-lg: 0 40px 90px -34px rgba(0,0,0,.95);
  --glow-primary: none;   /* ei hehkua painikkeisiin (Valtteri 22.9.2026) */
  --ring: 0 0 0 1px color-mix(in srgb, #ffffff 8%, transparent);

  /* ---- TYPOGRAFIA (geometrinen display + selkeä leipä + mono-aksentti) ---- */
  --font-display: 'Saira', 'Saira Fallback', system-ui, -apple-system, sans-serif;
  --font-body:    'Inter', 'Inter Fallback', system-ui, -apple-system, sans-serif;
  --font-mono:    'Inter', 'Inter Fallback', system-ui, -apple-system, sans-serif;   /* ei monofonttia: asiakkaan ilme on selkeä, ei tech-koodi */

  /* ---- MITAT ---- */
  --container: 1160px;
  --pad-x: clamp(18px, 5vw, 40px);
  --gap: clamp(18px, 2.4vw, 26px);
  --section-y: clamp(64px, 9vw, 120px);
}

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-padding-top: 84px; }
body {
  margin: 0; background: var(--c-bg); color: var(--c-text);
  font-family: var(--font-body); line-height: 1.65; font-size: 1rem;
  -webkit-font-smoothing: antialiased; overflow-x: hidden;
}
a { color: inherit; text-decoration: none; -webkit-tap-highlight-color: transparent; }
img { max-width: 100%; height: auto; display: block; }
button { font: inherit; -webkit-tap-highlight-color: transparent; }
:focus-visible { outline: 2px solid var(--c-accent3); outline-offset: 3px; border-radius: 4px; }

.skip-link { position: absolute; left: -9999px; top: 0; z-index: 200; background: var(--c-primary); color: #fff; padding: 12px 18px; border-radius: 0 0 10px 0; font-weight: 700; }
.skip-link:focus { left: 0; }

.wrap { max-width: var(--container); margin-inline: auto; padding-inline: var(--pad-x); }
.section { padding-block: var(--section-y); position: relative; }
.section--tint { background: var(--c-bg-2); }
.section--snug { padding-block: clamp(48px, 7vw, 88px); }

/* ---- TYPOGRAFIA-ASTEIKKO ---- */
h1, h2, h3, h4 { font-family: var(--font-display); color: var(--c-heading); line-height: 1.08; letter-spacing: -.02em; margin: 0; font-weight: 700; }
h1 { font-size: clamp(2.3rem, 5.2vw, 3.7rem); font-weight: 800; letter-spacing: -.02em; text-wrap: balance; }
h2 { font-size: clamp(1.85rem, 3.6vw, 2.85rem); }
h3 { font-size: 1.22rem; }
p  { margin: 0 0 1rem; }
.grad-text { background: var(--grad-text); -webkit-background-clip: text; background-clip: text; color: transparent; }

.eyebrow { display: inline-flex; align-items: center; gap: 8px; font-family: var(--font-body);   /* ei mono-eyebrowta (muisti ei-hehkutaustoja) */ font-size: .78rem; font-weight: 600; letter-spacing: .04em; text-transform: uppercase; color: var(--c-accent3); margin-bottom: 16px; }
.eyebrow::before { content: "//"; color: var(--c-primary); opacity: .8; }

.sec-head { max-width: 640px; margin-bottom: clamp(34px, 5vw, 54px); }
.sec-head--center { margin-inline: auto; text-align: center; }
.sec-head .lead { color: var(--c-muted); font-size: 1.08rem; margin-top: 14px; max-width: 56ch; }
.lead { color: var(--c-muted); }

/* ===========================  CLS-VARAUS  ============================ */
/* shared.js rakentaa navin vasta ajossaan. Ilman varausta koko sivu hyppää
   navin korkeuden verran alas, kun navi ilmestyy (mitattu CLS jopa 0,21).
   Kun kääre on täytetty, :empty ei enää päde eikä sääntö vaikuta mihinkään. */
#site-nav:empty { display: block; height: 77px; }

/* ============================ NAPIT ============================ */
.btn { display: inline-flex; align-items: center; justify-content: center; gap: 9px; padding: 14px 24px; border-radius: var(--r-pill); font-weight: 600; font-size: .98rem; border: 1px solid transparent; cursor: pointer; transition: transform .22s, box-shadow .3s, background .3s, border-color .25s; white-space: nowrap; min-height: 48px; }
.btn .arr { transition: transform .25s; }
.btn-primary { background: var(--grad); background-size: 180% 180%; background-position: 0% 50%; background-origin: border-box; background-repeat: no-repeat; color: var(--c-on-primary); box-shadow: var(--glow-primary); }
.btn-ghost { background: color-mix(in srgb, #fff 4%, transparent); color: var(--c-heading); border-color: var(--c-border); }
.btn-call { background: transparent; color: var(--c-heading); border-color: var(--c-border); }
.btn-call svg { color: var(--c-accent3); }
/* Pitkä painiketeksti + `white-space: nowrap` levittää napin yli kapean näytön
   ja aiheuttaa koko sivun vaakaylivuodon. Mitattu 20.9.2026: 412px leveä nappi
   375px:n näytöllä. Kapealla ruudulla teksti saa rivittyä. */
@media (max-width: 640px) {
  .btn { white-space: normal; text-align: center; }
}
@media (hover: hover) {
  .btn-primary:hover { background-position: 100% 50%; transform: translateY(-2px); }
  .btn-primary:hover .arr { transform: translateX(4px); }
  .btn-ghost:hover, .btn-call:hover { border-color: color-mix(in srgb, var(--c-primary) 60%, var(--c-border)); color: var(--c-heading); transform: translateY(-2px); }
}

/* ============================ HERO ============================ */
.hero { position: relative; padding-block: clamp(40px, 5vw, 64px) clamp(44px, 6vw, 80px);   /* ei ylisuurta ylätäytettä (Miikka 2.10.2026, VS Game Station) */ overflow: hidden; }
.hero::before { content: ""; position: absolute; inset: 0; z-index: 0; background: var(--glow-cyan), var(--glow-vio), var(--glow-blue); }
.hero::after { content: ""; position: absolute; inset: 0; z-index: 0; background: var(--grid-lines); background-size: 60px 60px; mask-image: radial-gradient(70% 60% at 50% 30%, #000 0%, transparent 75%); opacity: .5; }
.hero-grid { position: relative; z-index: 1; display: grid; grid-template-columns: 1.05fr .95fr; gap: clamp(28px, 5vw, 56px); align-items: center; }
.hero-copy { min-width: 0; }
.hero-pill { display: inline-flex; align-items: center; gap: 9px; font-family: var(--font-mono); font-size: .76rem; letter-spacing: .03em; color: var(--c-on-dark); background: color-mix(in srgb, #fff 5%, transparent); border: 1px solid var(--c-border); padding: 7px 14px; border-radius: var(--r-pill); margin-bottom: 22px; }
.hero-pill .live { width: 8px; height: 8px; border-radius: 50%; background: var(--c-accent3); box-shadow: 0 0 0 0 color-mix(in srgb, var(--c-accent3) 70%, transparent); animation: pulse 2.2s infinite; }
@keyframes pulse { 0% { box-shadow: 0 0 0 0 color-mix(in srgb, var(--c-accent3) 70%, transparent); } 70% { box-shadow: 0 0 0 9px transparent; } 100% { box-shadow: 0 0 0 0 transparent; } }
.hero h1 { margin-bottom: 20px; }
.hero-sub { font-size: clamp(1.05rem, 1.7vw, 1.22rem); color: var(--c-on-dark); max-width: none; margin-bottom: 30px; text-wrap: pretty; }   /* leveys palstasta, ei ch-rajasta (Valtteri 21.10.2026, Auto Craft) */
.hero-cta { display: flex; flex-wrap: wrap; gap: 12px; }
.hero-metrics { display: flex; flex-wrap: wrap; gap: 28px; margin-top: 38px; padding-top: 28px; border-top: 1px solid var(--c-border); }
.hero-metrics .m b { font-family: var(--font-display); display: block; font-size: 1.7rem; font-weight: 800; color: var(--c-heading); }
.hero-metrics .m span { font-size: .82rem; color: var(--c-muted); }

/* CSS-piirretty "status panel" -visuaali (ei stock-kuvaa) */
.hero-visual { position: relative; z-index: 1; }
.panel { background: linear-gradient(180deg, color-mix(in srgb, var(--c-surface) 92%, transparent), var(--c-surface)); border: 1px solid var(--c-border); border-radius: var(--r-lg); padding: 20px; box-shadow: var(--shadow-lg), var(--ring); backdrop-filter: blur(8px); }
.panel-bar { display: flex; align-items: center; gap: 8px; margin-bottom: 18px; }
.panel-bar .d { width: 11px; height: 11px; border-radius: 50%; background: var(--c-border); }
.panel-bar .d:nth-child(2) { background: #2A3145; } .panel-bar .d:nth-child(3) { background: #333b52; }
.panel-bar .tag { margin-left: auto; font-family: var(--font-mono); font-size: .72rem; color: var(--c-muted); }
.panel-row { display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 13px 14px; border-radius: var(--r-sm); background: color-mix(in srgb, #fff 3%, transparent); border: 1px solid var(--c-border); margin-bottom: 10px; }
.panel-row .lbl { display: flex; align-items: center; gap: 10px; font-size: .9rem; color: var(--c-on-dark); }
.panel-row .ic { width: 30px; height: 30px; border-radius: 8px; display: grid; place-items: center; background: color-mix(in srgb, var(--c-primary) 18%, transparent); color: var(--c-accent3); }
.panel-row .val { font-family: var(--font-mono); font-size: .86rem; color: var(--c-accent3); }
.panel-row .val.ok { color: var(--c-ok-bright); }
/* mini-graafi palkit */
.panel-graph { display: flex; align-items: flex-end; gap: 7px; height: 84px; padding: 14px; border-radius: var(--r-sm); background: color-mix(in srgb, #fff 3%, transparent); border: 1px solid var(--c-border); margin-top: 10px; }
.panel-graph i { flex: 1; border-radius: 4px 4px 0 0; background: var(--grad); opacity: .85; }
.hero-chip { position: absolute; z-index: 2; display: inline-flex; align-items: center; gap: 9px; background: color-mix(in srgb, var(--c-surface-2) 90%, transparent); border: 1px solid var(--c-border); border-radius: var(--r-pill); padding: 9px 15px; font-size: .82rem; font-weight: 600; color: var(--c-heading); box-shadow: var(--shadow); backdrop-filter: blur(8px); }
.hero-chip.c1 { top: -18px; right: 18px; } .hero-chip.c1 .dot { width: 8px; height: 8px; border-radius: 50%; background: var(--c-ok-bright); }
.hero-chip.c2 { bottom: -16px; left: -14px; } .hero-chip.c2 b { color: var(--c-accent3); font-family: var(--font-mono); }

/* ============================ LOGO-MARQUEE ============================ */
.marquee { border-block: 1px solid var(--c-border); padding-block: 22px; overflow: hidden; position: relative; }
.marquee::before, .marquee::after { content: ""; position: absolute; top: 0; bottom: 0; width: 90px; z-index: 2; }
.marquee::before { left: 0; background: linear-gradient(90deg, var(--c-bg), transparent); }
.marquee::after { right: 0; background: linear-gradient(270deg, var(--c-bg), transparent); }
.marquee-row { display: flex; gap: 56px; width: max-content; animation: scroll 28s linear infinite; }
.marquee-row span { font-family: var(--font-display); font-weight: 700; font-size: 1.25rem; color: var(--c-muted); letter-spacing: -.01em; white-space: nowrap; opacity: .75; }
@keyframes scroll { to { transform: translateX(-50%); } }

/* ============================ BENTO (palvelut) ============================ */
.bento { display: grid; grid-template-columns: repeat(6, 1fr); gap: var(--gap); }
.tile { position: relative; background: var(--c-surface); border: 1px solid var(--c-border); border-radius: var(--r-lg); padding: 28px; overflow: hidden; transition: border-color .25s, transform .25s, box-shadow .3s; }
.tile::after { content: ""; position: absolute; inset: 0; border-radius: inherit; background: radial-gradient(60% 80% at 100% 0%, color-mix(in srgb, var(--c-primary) 14%, transparent), transparent 60%); opacity: 0; transition: opacity .3s; pointer-events: none; }
@media (hover: hover) { a.tile:hover { transform: translateY(-4px); border-color: color-mix(in srgb, var(--c-primary) 50%, var(--c-border)); box-shadow: var(--shadow); } a.tile:hover::after { opacity: 1; } }
.tile .ico { width: 46px; height: 46px; border-radius: 12px; display: grid; place-items: center; background: color-mix(in srgb, var(--c-primary) 16%, transparent); color: var(--c-accent3); margin-bottom: 18px; border: 1px solid color-mix(in srgb, var(--c-primary) 30%, transparent); }
.tile h3 { color: var(--c-heading); margin-bottom: 8px; }
.tile p { font-size: .96rem; margin: 0; }
.tile .tlink { display: inline-flex; align-items: center; gap: 7px; margin-top: 16px; font-family: var(--font-mono); font-size: .82rem; font-weight: 600; color: var(--c-accent3); }
.tile--wide { grid-column: span 4; }
.tile--tall { grid-column: span 2; }
.tile--half { grid-column: span 3; }
.tile--third { grid-column: span 2; }
/* iso featured-tile sisältää mini-visualin */
.tile--feat { grid-column: span 4; display: grid; grid-template-columns: 1.1fr 1fr; gap: 24px; align-items: center; background: linear-gradient(135deg, var(--c-surface), var(--c-bg-2)); }
.tile--feat .codeblock { background: var(--c-bg); border: 1px solid var(--c-border); border-radius: var(--r-sm); padding: 16px; font-family: var(--font-mono); font-size: .8rem; color: var(--c-on-dark); line-height: 1.9; }
.tile--feat .codeblock .k { color: var(--c-accent3); } .tile--feat .codeblock .v { color: var(--c-accent2); } .tile--feat .codeblock .c { color: var(--c-muted); }

/* ============================ STATS-BAND ============================ */
.statband { position: relative; border-radius: var(--r-lg); border: 1px solid var(--c-border); background: linear-gradient(135deg, var(--c-surface), var(--c-bg-2)); padding: clamp(34px, 5vw, 54px); overflow: hidden; }
.statband::before { content: ""; position: absolute; inset: 0; background: var(--glow-vio); opacity: .5; }
.statband-grid { position: relative; display: grid; grid-template-columns: repeat(4, 1fr); gap: 28px; text-align: center; }
.statband .s b { font-family: var(--font-display); display: block; font-size: clamp(2.2rem, 4.4vw, 3.4rem); font-weight: 800; color: var(--c-heading); letter-spacing: -.03em; }
.statband .s b .grad-text { display: inline; font-size: inherit; color: transparent; }
/* 🛑 Ilman yllä olevaa font-sizea ja coloria sääntö `.statband .s span`
   (0,3,1) voittaa `.grad-text`in (0,1,0) ja kaappaa <b>:n sisällä olevalta
   gradienttispanilta sekä koon (54px -> 14px) että läpinäkyvyyden. Luku
   renderöityi pienenä ja harmaana. Havaittu 20.9.2026 lasketuista tyyleistä. */
.statband .s span { color: var(--c-muted); font-size: .9rem; }

/* ============================ FEATURE-SPLIT ============================ */
.feature-split { display: grid; grid-template-columns: 1fr 1fr; gap: clamp(30px, 5vw, 64px); align-items: center; }
.feature-list { list-style: none; padding: 0; margin: 22px 0 0; display: grid; gap: 14px; }
.feature-list li { display: flex; gap: 13px; align-items: flex-start; }
.feature-list .ck { flex: none; width: 26px; height: 26px; border-radius: 8px; display: grid; place-items: center; background: color-mix(in srgb, var(--c-primary) 18%, transparent); color: var(--c-accent3); margin-top: 2px; }
.feature-list b { color: var(--c-heading); font-family: var(--font-display); font-weight: 600; }
/* CSS dashboard-mockup */
.dash { background: var(--c-surface); border: 1px solid var(--c-border); border-radius: var(--r-lg); padding: 22px; box-shadow: var(--shadow-lg); }
.dash-head { display: flex; align-items: center; justify-content: space-between; margin-bottom: 18px; }
.dash-head b { font-family: var(--font-display); color: var(--c-heading); font-size: 1rem; }
.dash-head .pp { font-family: var(--font-mono); font-size: .74rem; color: var(--c-ok-bright); background: color-mix(in srgb, var(--c-ok-bright) 14%, transparent); padding: 4px 10px; border-radius: var(--r-pill); }
.dash-stats { display: grid; grid-template-columns: repeat(3, 1fr); gap: 12px; margin-bottom: 16px; }
.dash-stats div { background: color-mix(in srgb, #fff 3%, transparent); border: 1px solid var(--c-border); border-radius: var(--r-sm); padding: 12px; }
.dash-stats b { display: block; font-family: var(--font-display); color: var(--c-heading); font-size: 1.3rem; }
.dash-stats span { font-size: .72rem; color: var(--c-muted); }
.dash-graph { display: flex; align-items: flex-end; gap: 8px; height: 110px; padding-top: 6px; }
.dash-graph i { flex: 1; border-radius: 5px 5px 0 0; background: var(--grad); opacity: .8; }

/* ============================ TIMELINE (prosessi) ============================ */
.timeline { display: grid; grid-template-columns: repeat(4, 1fr); gap: 22px; position: relative; }
.timeline::before { content: ""; position: absolute; top: 19px; left: 6%; right: 6%; height: 2px; background: linear-gradient(90deg, transparent, var(--c-primary), var(--c-accent2), transparent); opacity: .55; }
.tstep { position: relative; text-align: left; }
.tstep-node, .tnode { width: 40px; height: 40px; border-radius: 50%; display: grid; place-items: center; font-family: var(--font-mono); font-weight: 700; color: var(--c-on-primary); background: var(--grad); box-shadow: var(--glow-primary); margin-bottom: 18px; position: relative; z-index: 1; }
.tstep h3 { color: var(--c-heading); margin-bottom: 7px; font-size: 1.08rem; }
.tstep p { font-size: .94rem; margin: 0; }

/* ============================ HINNOITTELU (tasot) ============================ */
.pricing { display: grid; grid-template-columns: repeat(3, 1fr); gap: var(--gap); align-items: stretch; }
.tier { display: flex; flex-direction: column; background: var(--c-surface); border: 1px solid var(--c-border); border-radius: var(--r-lg); padding: 30px; transition: transform .25s, box-shadow .3s, border-color .25s; }
.tier--feat { background: linear-gradient(170deg, color-mix(in srgb, var(--c-primary) 16%, var(--c-surface)), var(--c-surface)); border-color: color-mix(in srgb, var(--c-primary) 55%, var(--c-border)); box-shadow: var(--glow-primary); position: relative; }
.tier--feat .badge { position: absolute; top: -12px; left: 30px; font-family: var(--font-mono); font-size: .72rem; font-weight: 700; letter-spacing: .04em; color: var(--c-on-primary); background: var(--grad); padding: 5px 12px; border-radius: var(--r-pill); }
.tier .pl { font-family: var(--font-mono); font-size: .82rem; color: var(--c-accent3); text-transform: uppercase; letter-spacing: .04em; }
.tier .price { font-family: var(--font-display); font-size: 2.6rem; font-weight: 800; color: var(--c-heading); margin: 10px 0 4px; letter-spacing: -.03em; }
.tier .price small { font-size: .9rem; font-weight: 500; color: var(--c-muted); }
.tier .pdesc { color: var(--c-muted); font-size: .92rem; margin-bottom: 20px; }
.tier ul { list-style: none; padding: 0; margin: 0 0 24px; display: grid; gap: 11px; }
.tier li { display: flex; gap: 10px; align-items: flex-start; font-size: .94rem; }
.tier li svg { flex: none; color: var(--c-accent3); margin-top: 3px; }
.tier .btn { margin-top: auto; width: 100%; }

/* ============================ FAQ ============================ */
.faq { display: grid; gap: 12px; max-width: 800px; margin-inline: auto; }
.faq details { background: var(--c-surface); border: 1px solid var(--c-border); border-radius: var(--r); overflow: hidden; transition: border-color .25s; }
.faq details[open] { border-color: color-mix(in srgb, var(--c-primary) 45%, var(--c-border)); }
.faq summary { cursor: pointer; list-style: none; padding: 20px 22px; font-family: var(--font-display); font-weight: 600; color: var(--c-heading); display: flex; align-items: center; justify-content: space-between; gap: 16px; }
.faq summary::-webkit-details-marker { display: none; }
.faq summary::after { content: "+"; font-family: var(--font-mono); font-size: 1.4rem; color: var(--c-accent3); transition: transform .25s; }
.faq details[open] summary::after { transform: rotate(45deg); }
.faq .a { padding: 0 22px 20px; color: var(--c-muted); }
.faq .a p { margin: 0; }

/* ============================ CTA-BAND ============================ */
.cta-band { position: relative; text-align: center; border-radius: var(--r-lg); padding: clamp(44px, 7vw, 80px) var(--pad-x); overflow: hidden; background: linear-gradient(135deg, var(--c-surface), var(--c-bg-2)); border: 1px solid var(--c-border); }
.cta-band::before { content: ""; position: absolute; inset: 0; background: var(--glow-cyan), var(--glow-vio); opacity: .7; }
.cta-band > * { position: relative; z-index: 1; }
.cta-band h2 { margin-bottom: 14px; }
.cta-band p { color: var(--c-on-dark); max-width: 52ch; margin-inline: auto; margin-bottom: 28px; }
.cta-band .hero-cta { justify-content: center; }

/* ============================ YHTEYS + LOMAKE ============================ */
.contact-grid { display: grid; grid-template-columns: 1fr 1fr; gap: clamp(30px, 5vw, 60px); align-items: start; }
.contact-info .row { display: flex; gap: 14px; align-items: flex-start; margin-bottom: 22px; }
.contact-info .row svg { flex: none; color: var(--c-accent3); margin-top: 3px; }
.contact-info .row b { display: block; color: var(--c-heading); font-family: var(--font-display); }
.contact-info .row span, .contact-info .row a { color: var(--c-muted); }
.map { margin-top: 8px; border-radius: var(--r); overflow: hidden; border: 1px solid var(--c-border); }
.map iframe { width: 100%; height: 240px; border: 0; display: block; filter: grayscale(1) invert(.9) hue-rotate(180deg) brightness(.9); }

.form { background: var(--c-surface); border: 1px solid var(--c-border); border-radius: var(--r-lg); padding: clamp(22px, 3vw, 34px); box-shadow: var(--shadow); }
.field { margin-bottom: 16px; }
.field label { display: block; font-size: .86rem; font-weight: 600; color: var(--c-on-dark); margin-bottom: 7px; font-family: var(--font-display); }
.field input, .field textarea, .field select { width: 100%; font-size: 16px; font-family: var(--font-body); color: var(--c-heading); background: var(--c-bg); border: 1px solid var(--c-border); border-radius: var(--r-sm); padding: 13px 15px; transition: border-color .2s, box-shadow .2s; }
.field input::placeholder, .field textarea::placeholder { color: var(--c-muted); }
.field input:focus, .field textarea:focus { outline: none; border-color: var(--c-primary); box-shadow: 0 0 0 3px color-mix(in srgb, var(--c-primary) 22%, transparent); }
.field textarea { min-height: 120px; resize: vertical; }
.hp { position: absolute; left: -9999px; width: 1px; height: 1px; opacity: 0; }
.form-note { font-size: .82rem; color: var(--c-muted); margin: 12px 0 0; }
.form-msg { margin: 12px 0 0; font-weight: 600; font-size: .94rem; }
.form-msg.ok { color: var(--c-ok); } .form-msg.err { color: var(--c-err); }

/* ============================ ALASIVUJEN PIENET ELEMENTIT ============================ */
.svc-stack { display: grid; gap: clamp(26px, 4vw, 48px); }
.svc-detail { display: grid; grid-template-columns: 1fr 1fr; gap: clamp(24px, 4vw, 52px); align-items: center; }
.svc-detail:nth-child(even) .svc-d-media { order: 2; }
.svc-d-media { background: var(--c-surface); border: 1px solid var(--c-border); border-radius: var(--r-lg); padding: 22px; box-shadow: var(--shadow); }
.svc-d-list { list-style: none; padding: 0; margin: 18px 0 24px; display: grid; gap: 11px; }
.svc-d-list li { display: flex; gap: 10px; align-items: flex-start; font-size: .96rem; }
.svc-d-list li svg { flex: none; color: var(--c-accent3); margin-top: 3px; }
.values { display: grid; grid-template-columns: repeat(3, 1fr); gap: var(--gap); }
.value { background: var(--c-surface); border: 1px solid var(--c-border); border-radius: var(--r-lg); padding: 28px; }
.value .ico { width: 46px; height: 46px; border-radius: 12px; display: grid; place-items: center; background: color-mix(in srgb, var(--c-primary) 16%, transparent); color: var(--c-accent3); margin-bottom: 16px; border: 1px solid color-mix(in srgb, var(--c-primary) 30%, transparent); }
.value h3 { color: var(--c-heading); margin-bottom: 8px; }
.value p { font-size: .95rem; margin: 0; }
.legal { max-width: 760px; }
.legal h3 { color: var(--c-heading); margin-top: 32px; margin-bottom: 8px; }
.legal p { color: var(--c-muted); }

/* ============================ RESPONSIIVISUUS ============================ */
@media (max-width: 980px) {
  .hero-grid { grid-template-columns: 1fr; gap: 48px; }
  .hero-visual { max-width: 460px; }
  .bento { grid-template-columns: repeat(2, 1fr); }
  .tile--wide, .tile--tall, .tile--half, .tile--third, .tile--feat { grid-column: span 2; }
  .tile--feat { grid-template-columns: 1fr; }
  .feature-split, .svc-detail, .contact-grid { grid-template-columns: 1fr; }
  .svc-detail:nth-child(even) .svc-d-media { order: 0; }
  .statband-grid { grid-template-columns: repeat(2, 1fr); gap: 30px; }
  .timeline { grid-template-columns: repeat(2, 1fr); gap: 30px; }
  .timeline::before { display: none; }
  .pricing { grid-template-columns: 1fr; max-width: 460px; margin-inline: auto; }
  .values { grid-template-columns: 1fr; }
}
@media (max-width: 560px) {
  .bento { grid-template-columns: 1fr; }
  .tile--wide, .tile--tall, .tile--half, .tile--third, .tile--feat { grid-column: span 1; }
  .statband-grid { grid-template-columns: 1fr 1fr; gap: 22px; }
  .hero-metrics { gap: 20px; }
  .hero-chip { display: none; }
}

@media (prefers-reduced-motion: reduce) {
  * { animation: none !important; transition: none !important; }
}


/* Lomakkeen alasvetovalikko — samat mitat ja tila kuin muilla kentillä.
   Oma nuoli-ikoni, koska selaimen oletusnuoli ei noudata teemaa.
   (Lisätty pohjiin 26.8.2026: viisi asiakasta oli joutunut kirjoittamaan tämän itse.) */
.field select, .form-group select {
  width: 100%; font: inherit; font-size: 16px; color: inherit;
  appearance: none; -webkit-appearance: none;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='14' height='9' viewBox='0 0 14 9' fill='none' stroke='%23888' stroke-width='2'%3E%3Cpath d='m1 1 6 6 6-6'/%3E%3C/svg%3E");
  background-repeat: no-repeat; background-position: right 16px center;
  padding-right: 42px;
}


/* ============================================================================
   VAALEA VARIANTTI  —  lisää <body class="vaalea">
   Tumma tech-pohja kääntyy vaaleaksi: hehkut himmennetään, ei poisteta.
   Ks. perustelu demo5:n ja demo13:n vastaavista lohkoista.
   ============================================================================ */
body.vaalea {
  --c-bg:        #F7F8FC;
  --c-bg-2:      #EEF1F8;
  --c-surface:   #FFFFFF;
  --c-surface-2: #F1F4FA;
  --c-text:      #414759;
  --c-heading:   #0B0E18;
  --c-muted:     #6B7185;
  --c-border:    #DFE3EE;
  --c-dark:      #0B0E18;
  --c-on-dark:   #D8DCE8;
  --shadow:      0 14px 36px -18px rgba(11,14,24,.14);
  --shadow-lg:   0 28px 64px -28px rgba(11,14,24,.18);
}
body.vaalea nav.site { background: var(--c-bg); border-bottom: 1px solid var(--c-border); backdrop-filter: none; -webkit-backdrop-filter: none; }
body.vaalea nav.site a, body.vaalea nav.site .brand { color: var(--c-heading); }
/* Hehkuorbit himmeämmiksi — täydellä voimalla ne sumentavat vaalean pinnan */
body.vaalea .orb, body.vaalea .glow, body.vaalea [class*="orb"] { opacity: .28; }


/* ============================================================================
   OSIOKIRJASTO — lisätty pohjiin 26.8.2026
   Nämä kolme rakennettiin aiemmin käsin lähes joka asiakkaalle (mm. A tape).
   Kaikki käyttävät pohjan omia muuttujia, joten ne teemautuvat itsestään.
   ============================================================================ */

/* --- Yhteyshenkilökortit: isot kasvokuvat, ei pikkuruisia nappikuvia ---------
   Rajaa kuvat KASVOIHIN ennen käyttöä. Koko vartalo 60 px ympyrässä tarkoittaa,
   ettei kasvoja erota — tämä oli A tapen ensimmäisen version virhe. */
.person-cards { display: grid; grid-template-columns: repeat(auto-fit, minmax(210px, 1fr)); gap: 16px; margin: 26px 0 8px; }
.person { display: flex; flex-direction: column; background: var(--c-surface);
  border: 1px solid var(--c-border); border-radius: var(--r); overflow: hidden; box-shadow: var(--shadow-sm); }
.person img { width: 100%; height: auto; aspect-ratio: 1 / 1; object-fit: cover; display: block; }
.person > div { padding: 16px 18px 18px; }
.person b { display: block; font-family: var(--font-display); font-size: 1.08rem; color: var(--c-heading); margin-bottom: 4px; }
.person a, .person span { display: block; font-size: .95rem; color: var(--c-muted); }
@media (hover: hover) { .person a:hover { color: var(--c-primary); } }

/* --- 2×2-korttiruudukko: neljä referenssiä tai palvelua ----------------------
   Palvelukorttien rivisääntö: 4 kpl EI KOSKAAN 3+1, vaan 2×2. */
.cards--2 { grid-template-columns: repeat(2, 1fr); }
@media (max-width: 860px) { .cards--2 { grid-template-columns: 1fr; } }
.cards--2 .card .num { display: inline-block; align-self: flex-start; font-size: .9rem;
  letter-spacing: .12em; font-weight: 700; color: var(--c-primary);
  background: color-mix(in srgb, var(--c-primary) 12%, transparent);
  padding: 5px 13px; border-radius: var(--r-pill); }

/* --- Nostolainaus: asiakassitaatti omalla kaistallaan ------------------------
   Toimii sekä vaalealla että tummalla osiolla (peri väri isännältä). */
.pull { margin: 0; max-width: 900px; margin-inline: auto; text-align: center; }
.pull p { font-family: var(--font-display); font-weight: 600;
  font-size: clamp(1.35rem, 3vw, 2.1rem); line-height: 1.35;
  max-width: none; margin: 0 0 22px; letter-spacing: -.02em; }
.pull footer { font-size: .96rem; letter-spacing: .04em; opacity: .75; }
.pull::before { content: "”"; display: block; font-family: var(--font-display);
  font-size: clamp(3.5rem, 8vw, 6rem); line-height: .6; opacity: .18; margin-bottom: 8px; }

/* ============================================================================
   SISÄLTÖSIVUJEN KOMPONENTIT
   Lisätty 20.9.2026 (Foorly). Pohjassa oli vain etusivun osiot; pitkät
   palvelu- ja artikkelisivut tarvitsevat leipätekstin, taulukot ja murupolun.
   Kaikki perii :root-muuttujat — ei kovakoodattuja värejä.
   ============================================================================ */

/* --- Alasivun kevyempi hero (ei paneelia, ei 100vh) --- */
.hero--sub { padding-block: clamp(96px, 12vw, 150px) clamp(40px, 6vw, 68px); min-height: 0; }
.hero--sub .hero-copy { max-width: 780px; }
.hero--sub h1 { margin-bottom: 18px; }

/* --- Murupolku --- */
.crumbs { font-size: .9rem; color: var(--c-muted); margin-bottom: 22px; display: flex;
  flex-wrap: wrap; gap: 8px; align-items: center; }
.crumbs a { color: var(--c-muted); text-decoration: none; }
.crumbs span[aria-current] { color: var(--c-text); }
@media (hover: hover) { .crumbs a:hover { color: var(--c-accent3); } }

/* --- Leipätekstipalsta: rajattu rivinpituus luettavuuden vuoksi ---
   HUOM: kun samassa elementissä on .wrap, se tuo margin-inline:auto ja
   kapea palsta keskittyisi — jolloin se ei linjaudu muiden osioiden
   vasemman reunan kanssa. Siksi .wrap.prose pitää säiliön täysleveänä
   ja rajaa rivinpituuden vasta lapsista. (Korjattu 20.9.2026.) */
.prose { max-width: 74ch; }
.wrap.prose { max-width: var(--container); }
.wrap.prose > * { max-width: 74ch; }
.prose > h2 { margin-top: 0; margin-bottom: 18px; }
.prose > h3 { margin-top: 34px; margin-bottom: 12px; }
.prose > p { color: var(--c-text); margin-bottom: 18px; line-height: 1.75; }
.prose > p:last-child { margin-bottom: 0; }
/* Sisältölinkit. Globaali `a { color: inherit }` tekee leipätekstin linkeistä
   näkymättömiä, joten ne merkitään erikseen kaikissa tekstiä sisältävissä
   lohkoissa — myös UKK-vastauksissa ja nostolaatikoissa, jotka ovat .prose:n
   ulkopuolella. (Havaittu 20.9.2026: UKK-linkit eivät erottuneet lainkaan.) */
.prose a, .faq .a a, .callout a, .card p a, .lead a, .hero-sub a {
  color: var(--c-accent3); text-decoration: underline; text-underline-offset: 3px;
  text-decoration-thickness: 1px; text-decoration-color: color-mix(in srgb, var(--c-accent3) 45%, transparent); }
@media (hover: hover) {
  .prose a:hover, .faq .a a:hover, .callout a:hover, .card p a:hover,
  .lead a:hover, .hero-sub a:hover { text-decoration-color: currentColor; }
}
.prose strong { color: var(--c-heading); font-weight: 650; }

/* --- Nostolaatikko: yksi asia jonka lukijan pitää muistaa --- */
.callout { margin: 32px 0; padding: clamp(22px, 3vw, 30px); border-radius: var(--r-lg);
  background: var(--c-surface); border: 1px solid var(--c-border);
  border-left: 3px solid var(--c-accent3); box-shadow: var(--shadow); }
.callout h3 { margin: 0 0 10px; font-size: 1.16rem; }
.callout p { margin: 0; color: var(--c-text); line-height: 1.7; }

/* --- Taulukko: vaakavieritys mobiilissa, ei sivun ylivuotoa --- */
.tbl-wrap { overflow-x: auto; margin: 26px 0; border: 1px solid var(--c-border);
  border-radius: var(--r); background: var(--c-surface); -webkit-overflow-scrolling: touch; }
.tbl { width: 100%; border-collapse: collapse; font-size: .96rem; min-width: 520px; }
.tbl caption { text-align: left; padding: 16px 18px 0; font-family: var(--font-mono);
  font-size: .76rem; letter-spacing: .1em; text-transform: uppercase; color: var(--c-muted); }
.tbl th, .tbl td { padding: 13px 18px; text-align: left; border-bottom: 1px solid var(--c-border); }
.tbl thead th { font-family: var(--font-mono); font-size: .76rem; letter-spacing: .08em;
  text-transform: uppercase; color: var(--c-muted); font-weight: 600; }
.tbl tbody th { color: var(--c-heading); font-weight: 600; }
.tbl tbody td { color: var(--c-text); }
.tbl tbody tr:last-child th, .tbl tbody tr:last-child td { border-bottom: 0; }

/* --- Kortit: peruskortti + kahden vertailu --- */
.cards { display: grid; gap: var(--gap); }
.card { display: flex; flex-direction: column; gap: 12px; padding: clamp(22px, 3vw, 30px);
  border-radius: var(--r-lg); background: var(--c-surface); border: 1px solid var(--c-border);
  box-shadow: var(--shadow); }
.card h3 { margin: 0; font-size: 1.22rem; }
.card p { color: var(--c-text); margin: 0; line-height: 1.7; }
.card-lead { color: var(--c-accent3) !important; font-family: var(--font-mono);
  font-size: .82rem; letter-spacing: .04em; }
.card .feature-list { margin: 4px 0 0; }
.split-cards { display: grid; grid-template-columns: repeat(2, 1fr); gap: var(--gap); margin: 30px 0; }
@media (max-width: 860px) { .split-cards { grid-template-columns: 1fr; } }
/* Tasakokoinen 3-sarakkeinen ruudukko (artikkelilistaus). Bento-ruudukko jättää
   1–2 kortin ryhmän kapeaksi ja tyhjäksi; tämä pitää kortit yhtä leveinä. */
.cards--3 { grid-template-columns: repeat(3, 1fr); }
@media (max-width: 960px) { .cards--3 { grid-template-columns: repeat(2, 1fr); } }
@media (max-width: 640px) { .cards--3 { grid-template-columns: 1fr; } }
.card h3 a { color: inherit; }
@media (hover: hover) { .card h3 a:hover { color: var(--c-accent3); } }
.card .tlink { margin-top: auto; }

/* --- Chip-lista: toimialat, paikkakunnat, avainsanat --- */
.chips { display: flex; flex-wrap: wrap; gap: 10px; list-style: none; padding: 0; margin: 0; }
.chips li { padding: 9px 16px; border-radius: var(--r-pill); font-size: .93rem;
  color: var(--c-text); background: var(--c-surface); border: 1px solid var(--c-border); }

/* --- Alasivun hero kahdessa palstassa: teksti + kuvitus --- */
.hero-sub-grid { display: grid; grid-template-columns: 1.15fr .85fr; gap: clamp(24px, 4vw, 56px); align-items: center; }
.hero-sub-grid .hero-copy { max-width: none; }
.hero-sub-kuva { display: grid; place-items: center; position: relative; }
.hero-sub-kuva img { width: 100%; max-width: 400px; height: auto;
  filter: drop-shadow(0 30px 60px color-mix(in srgb, var(--c-accent2) 26%, transparent)); }
.hero-sub-kuva::before { content: ""; position: absolute; inset: 12% 8%; border-radius: 50%;
  background: radial-gradient(circle, color-mix(in srgb, var(--c-accent3) 18%, transparent), transparent 70%);
  filter: blur(38px); z-index: -1; }
@media (max-width: 860px) {
  .hero-sub-grid { grid-template-columns: 1fr; }
  .hero-sub-kuva img { max-width: 300px; }
}

/* Hallinta: tiedotepalkki (inertti ilman hallinnan tiedote-moduulia). Sijainti heti navin alla (A3). */
.site-tiedote { background: color-mix(in srgb, var(--c-primary) 10%, var(--c-surface)); color: var(--c-heading);
  border-bottom: 1px solid var(--c-border); font-family: var(--font-body); }
.site-tiedote[hidden] { display: none; }
.site-tiedote-in { max-width: var(--container); margin-inline: auto; padding: 10px var(--pad-x);
  font-size: .95rem; line-height: 1.45; font-weight: 600; text-align: center; overflow-wrap: anywhere; }
@media (max-width: 640px) { .site-tiedote-in { font-size: .88rem; padding-block: 8px; } }

/* ===== Kontrastikorjaukset 21.10.2026 (kontrasti.py, 47 demon palautekooste) ===== */
.tier--feat .price small, .tier--feat .pdesc { color: color-mix(in srgb, var(--c-muted) 70%, #fff); }   /* korostetun kortin liukuväripohjalla ≥ 4,5:1 */


/* ============================================================================
   ALG ELECTRIC: asiakaskohtaiset lisäykset (22.10.2026)
   Valokuvahero ja kuvalliset palvelukortit pohjan CSS-paneelien tilalle
   (asiakas pyysi selkeitä palveluja esittäviä kuvia), Kenelle-ruudukko,
   soittopainikkeen malli (_ohjeet.md §12, Auto Craft 19.10.2026).
   ============================================================================ */
.brand img { height: 44px; width: auto; display: block; }
.foot-brand .brand img { height: 52px; }
.eyebrow::before { color: var(--c-accent); opacity: 1; }

/* Hero: taustakuva koko osion levyisenä tekstin takana, teksti vasemmalla, liukuväri tekstin alla
   (Miikka 22.10.2026). Kontrasti mitataan pikseleistä (kontrasti.py): vasen reuna lähes peittävä. */
.hero { min-height: clamp(540px, 72vh, 760px); display: flex; align-items: center; padding-block: clamp(56px, 8vw, 100px); }
.hero-bg { position: absolute; inset: 0; z-index: 0; }
.hero-bg img { width: 100%; height: 100%; object-fit: cover; object-position: 72% 55%; display: block; }   /* talo ja valaistut ikkunat oikealle, verho vasemmalle */
.hero-bg::after { content: ""; position: absolute; inset: 0;
  background:
    linear-gradient(90deg, rgba(8,9,15,.97) 0%, rgba(8,9,15,.93) 36%, rgba(8,9,15,.55) 58%, rgba(8,9,15,.14) 100%),
    linear-gradient(180deg, rgba(8,9,15,.45) 0%, rgba(8,9,15,0) 35%, rgba(8,9,15,.2) 70%, var(--c-bg) 100%); }
.hero-in { position: relative; z-index: 1; width: 100%; }
.hero-copy { max-width: 620px; }
@media (max-width: 860px) {
  .hero { min-height: 0; }
  .hero-bg img { object-position: 78% 55%; }
  .hero-bg::after { background: linear-gradient(180deg, rgba(8,9,15,.9) 0%, rgba(8,9,15,.86) 70%, var(--c-bg) 100%); }
}
.hero-trust { display: grid; grid-template-columns: repeat(2, max-content); gap: 10px 32px; margin: 30px 0 0; padding: 22px 0 0; border-top: 1px solid var(--c-border); list-style: none; }   /* 2 × 2, ei orpoa (3 + 1) */
@media (max-width: 400px) { .hero-trust { grid-template-columns: 1fr; } }
.hero-trust li { display: flex; align-items: center; gap: 8px; font-size: .94rem; font-weight: 500; color: var(--c-on-dark); }
.hero-trust svg { color: var(--c-accent); flex: none; }

/* Palvelut: kuvalliset kortit 3 × 2 */
.svc-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: var(--gap); }
.svc { background: var(--c-surface); border: 1px solid var(--c-border); border-radius: var(--r-lg); overflow: hidden; display: flex; flex-direction: column; }
.svc img { width: 100%; height: auto; aspect-ratio: 800 / 520; object-fit: cover; display: block; }
.svc > div { padding: 22px 24px 26px; }
.svc h3 { margin-bottom: 8px; }
.svc p { margin: 0; font-size: .96rem; }

/* Kenelle: neljä korttia */
.who { display: grid; grid-template-columns: repeat(4, 1fr); gap: var(--gap); }
.who article { background: var(--c-surface); border: 1px solid var(--c-border); border-radius: var(--r-lg); padding: 26px; }
.who .ico { width: 46px; height: 46px; border-radius: 12px; display: grid; place-items: center; background: color-mix(in srgb, var(--c-primary) 16%, transparent); color: var(--c-accent3); margin-bottom: 16px; border: 1px solid color-mix(in srgb, var(--c-primary) 30%, transparent); }
.who h3 { font-size: 1.1rem; margin-bottom: 6px; }
.who p { margin: 0; font-size: .94rem; }

/* Miksi: valokuva dashboardin tilalla, lista koko leveydelle kuvan alle (_ohjeet §12) */
.why-list { margin-top: clamp(28px, 4vw, 44px); grid-template-columns: repeat(2, 1fr); gap: 16px 32px; }
.feature-split > div:first-child > p:not(.lead) { margin: 0; color: var(--c-text); }
@media (max-width: 640px) { .why-list { grid-template-columns: 1fr; } }
.feature-photo { border-radius: var(--r-lg); overflow: hidden; border: 1px solid var(--c-border); box-shadow: var(--shadow-lg); }
.feature-photo img { width: 100%; height: auto; aspect-ratio: 4 / 3; object-fit: cover; display: block; }

/* Soittopainikkeet: ikoni + numero tietokoneella, puhelimella vain "Soita" (Valtteri 19.–20.10.2026) */
.btn .ico { flex: none; }
.btn .txt { display: flex; flex-direction: column; align-items: flex-start; line-height: 1.25; text-align: left; }
.btn .nro { font-size: .82rem; font-weight: 600; letter-spacing: .02em; opacity: .92; white-space: nowrap; }
.btn .nro--yksin { font-size: inherit; letter-spacing: inherit; opacity: 1; font-weight: inherit; }
.soita { display: none; }
@media (pointer: coarse) and (max-width: 640px) { .btn .nro { display: none; } .soita { display: inline; } }

@media (max-width: 980px) {
  .svc-grid { grid-template-columns: repeat(2, 1fr); }
  .who { grid-template-columns: repeat(2, 1fr); }
}
@media (max-width: 560px) {
  .svc-grid, .who { grid-template-columns: 1fr; }
}
