@font-face{font-family:Space Grotesk;src:url(/assets/fonts/space-grotesk/space-grotesk-latin.woff2) format("woff2");font-style:normal;font-weight:400 700;font-display:swap}
*{box-sizing:border-box}
[hidden]{display:none!important}
:root{font-family:"Space Grotesk",ui-sans-serif,system-ui,sans-serif;color:#173d2b;background:#f1f4ed}
body{margin:0;min-height:100dvh}
button,input{font:inherit}
button{cursor:pointer}
.page{min-height:100dvh;display:flex;justify-content:center;align-items:center;padding:20px 14px}
.access-card{width:100%;max-width:440px;background:#fff;border:1px solid #dfe7db;border-radius:28px;padding:22px;box-shadow:0 18px 55px #123b2612}
.brand{background:#16452d;border-radius:19px;padding:23px 14px;text-align:center;color:#fff}
.brand-name{font-size:14px;font-weight:700;letter-spacing:.1em}
.brand-subtitle{margin-top:6px;font-size:12px;color:#d8eadc}
.language-switch{display:flex;justify-content:flex-end;gap:9px;margin:16px 0;color:#718074;font-size:12px;font-weight:700}
.language-switch a{color:#536f59;text-decoration:none}
.language-switch a[aria-current=page]{color:#16452d;text-decoration:underline;text-underline-offset:4px}
h1{margin:18px 0 10px;text-align:center;font-size:clamp(21px,5vw,26px);line-height:1.25}
.description{margin:0 0 25px;text-align:center;font-size:14px;line-height:1.55;color:#637468}
.field-label{display:block;margin-bottom:13px;font-size:13px;font-weight:750}
.pin-boxes{display:flex;justify-content:center;align-items:center;gap:0;min-height:52px;margin:12px auto;text-align:center}
.pin-box{display:none;border:0;border-radius:0;background:transparent;box-shadow:none;color:#16452d;font-size:32px;font-weight:750;line-height:1.4;font-variant-numeric:tabular-nums}
.pin-box.filled{display:inline-block;border:0;background:transparent}
.pin-input{display:block;width:100%;height:1px;padding:0;border:0;opacity:.01;outline:0}
.keypad{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:9px;max-width:280px;margin:17px auto 20px}
.key{height:49px;background:#fff;border:1px solid #dce5d9;border-radius:12px;color:#173d2b;font-size:20px;font-weight:650}
.key:active{background:#e6f2e8;transform:scale(.98)}
.key-secondary{background:#f0f4ee;font-size:18px}
.submit-button{display:block;width:100%;padding:15px;border:0;border-radius:999px;background:#16452d;color:#fff;font-size:15px;font-weight:750}
.submit-button:disabled{opacity:.45;cursor:not-allowed}
.alternative-section{margin-top:24px;padding-top:19px;border-top:1px solid #e4eae1;text-align:center}
.alternative-section p{margin:0 0 7px;color:#637468;font-size:13px}
.text-button{background:none;border:0;padding:6px;color:#16452d;font-size:14px;font-weight:750;text-decoration:underline;text-underline-offset:4px}
.contact-input{width:100%;padding:15px 13px;border:1px solid #cad9ca;border-radius:12px;margin-bottom:20px;outline-color:#3c7750}
.back-button{display:block;margin:20px auto 0}
.message{margin:19px 0 0;padding:13px;border-radius:12px;background:#f1f4ed;color:#31543a;font-size:13px;text-align:center}
@media(max-width:360px){.access-card{padding:16px}.pin-boxes{gap:3px}.pin-box{height:37px}}


/* Sijaintitarkistus */
.location-heading {
    display: flex;
    align-items: flex-start;
    gap: 13px;
    margin: 10px 0 20px;
}

.location-icon {
    display: grid;
    flex: 0 0 48px;
    width: 48px;
    height: 48px;
    place-items: center;
    border-radius: 14px;
    background: #e6f1e6;
    color: #16452d;
    font-size: 29px;
}

.location-heading h2 {
    margin: 0 0 7px;
    font-size: 20px;
    line-height: 1.3;
}

.location-heading p {
    margin: 0;
    color: #637468;
    font-size: 13px;
    line-height: 1.5;
}

.location-area {
    margin-bottom: 20px;
    padding: 15px;
    border-radius: 13px;
    background: #f1f5ef;
    color: #173d2b;
    font-size: 14px;
    font-weight: 700;
}

.location-result {
    margin: 0 0 18px;
    padding: 13px;
    border-radius: 12px;
    background: #edf5ed;
    color: #245333;
    font-size: 13px;
    line-height: 1.5;
}

.location-result.warning {
    background: #fff5e5;
    color: #875414;
}

.location-skip,
.location-back {
    display: block;
    margin: 17px auto 0;
    text-align: center;
}

.location-back {
    color: #637468;
    font-weight: 500;
}


/* Varakoodin näyttö onnistuneen tunnistautumisen jälkeen */
#backup-code-panel {
    text-align: center;
    padding: 12px 0 4px;
}

#backup-code-panel h2 {
    margin: 0 0 12px;
    color: #16452d;
    font-size: 23px;
    line-height: 1.3;
}

#backup-code-panel p {
    color: #637468;
    font-size: 14px;
    line-height: 1.6;
}

#backup-code-panel .backup-code-value {
    margin: 23px 0;
    padding: 23px 12px;
    border: 2px solid #9dbca3;
    border-radius: 18px;
    background: #edf6ed;
    color: #16452d;
    font-size: clamp(36px, 11vw, 54px);
    font-weight: 700;
    letter-spacing: .2em;
    font-variant-numeric: tabular-nums;
    line-height: 1.2;
    overflow-wrap: anywhere;
}

@media (max-width: 360px) {
    #backup-code-panel .backup-code-value {
        letter-spacing: .12em;
    }
}

/* Keskitetty PIN ilman erillisiä kenttiä myös pienillä näytöillä. */
#pin-boxes{gap:0}
#pin-boxes .pin-box{height:auto;padding:0;border:0;background:transparent;box-shadow:none}

/* PIN keskellä ohjeen ja näppäimistön väliä. */
.pin-label-accessible{position:absolute;width:1px;height:1px;padding:0;margin:-1px;overflow:hidden;clip:rect(0,0,0,0);white-space:nowrap;border:0}
.description{margin-bottom:0}
#pin-boxes{margin:24px auto 0;min-height:52px}
#pin-panel .keypad{margin-top:24px}

/* Apusivun yhteinen brändi ja kaikkien vaiheiden tasaus. */
.site-header{background:#16452d;color:#fff;padding:16px 20px}
.site-header-inner{max-width:1080px;margin:auto;display:flex;align-items:center;justify-content:space-between;gap:20px}
.site-brand{display:flex;align-items:center;gap:12px;color:#fff;text-decoration:none}
.site-brand img{display:block;flex:none}
.site-brand span{font-size:15px;font-weight:700;line-height:1.15;letter-spacing:-.02em}
.site-brand strong{display:block;color:#a3e635}
.site-header .language-switch{margin:0;gap:12px;font-size:14px}
.site-header .language-switch a{color:#dce9df;padding:10px 2px}
.site-header .language-switch a[aria-current=page]{color:#a3e635}
.page{min-height:calc(100dvh - 80px);padding:32px 16px;align-items:flex-start}
.access-card{max-width:440px;padding:28px 24px;border-radius:24px;box-shadow:0 12px 36px #123b2110}
.access-card h1{margin:0 0 12px;font-size:clamp(22px,5vw,26px);line-height:1.3}
.description{max-width:320px;margin:0 auto;line-height:1.6}
#pin-panel,#contact-panel,#location-panel,#backup-code-panel,.message{width:100%;max-width:320px;margin-left:auto;margin-right:auto}
.keypad{max-width:320px;gap:10px}
.key{height:52px;border-radius:12px;font-size:21px}
.submit-button{max-width:320px;margin:0 auto;min-height:50px;padding:14px 18px;border-radius:12px;line-height:1.35}
.contact-input{min-height:50px;font-size:16px;margin-bottom:20px}
#contact-panel{padding-top:28px}
.field-label{text-align:left;margin-bottom:10px}
.alternative-section{margin-top:24px;padding-top:20px}
.text-button{min-height:44px;line-height:1.4}
.location-result{margin:24px 0 0;padding:16px;text-align:center;line-height:1.6;border-radius:12px}
.location-skip,.location-back{margin:12px auto 0}
#backup-code-panel{padding-top:28px}
#backup-code-panel h2{font-size:22px;margin-bottom:12px}
#backup-code-panel p{margin:12px 0}
#backup-code-panel .backup-code-value{margin:24px 0;padding:20px 12px;border-radius:12px;font-size:48px;letter-spacing:.16em;text-indent:.16em}
button:focus-visible,a:focus-visible{outline:3px solid #84b58f;outline-offset:4px}
@media(max-width:360px){.site-header{padding:12px 16px}.site-brand{gap:8px}.site-brand img{width:40px;height:40px}.site-brand span{font-size:13px}.access-card{padding:24px 18px}.page{padding:24px 12px}.site-header-inner{gap:12px}}

.access-card:has(#pin-panel[hidden]) > .description{display:none}

/* Sijaintitallennuksen odotus samassa PIN-kentässä. */
#pin-panel.location-saving .pin-box {
    color: transparent;
    background: linear-gradient(100deg, #e5e7eb 20%, #f8fafc 45%, #e5e7eb 70%);
    background-size: 250% 100%;
    animation: apu-location-shimmer 1.4s ease-in-out infinite;
    border-color: #d1d5db;
}
#pin-panel.location-saving .pin-box:nth-child(2n) { animation-delay: .12s; }
#pin-panel.location-saving #pin-input { caret-color: transparent; color: transparent; }
#pin-panel.location-saving .key { opacity: .55; }
@keyframes apu-location-shimmer { from { background-position: 100% 0; } to { background-position: -100% 0; } }
@media (prefers-reduced-motion: reduce) {
    #pin-panel.location-saving .pin-box { animation: none; background: #e5e7eb; }
}

/* Help header language selector and location explanation. */
.site-header .language-switch, .language-switch {
    display: inline-flex; align-items: center; gap: 4px; padding: 4px;
    margin: 0; border: 1px solid rgba(255,255,255,.3); border-radius: 999px;
    background: rgba(0,0,0,.12); flex-shrink: 0;
}
.site-header .language-switch a, .language-switch a {
    display: grid; place-items: center; min-width: 44px; min-height: 36px;
    padding: 0 12px; border-radius: 999px; color: #fff;
    font-size: 14px; font-weight: 700; text-decoration: none; line-height: 1;
}
.site-header .language-switch a[aria-current="page"], .language-switch a[aria-current="page"] {
    color: #16452d; background: #a4ed21; text-decoration: none;
}
.language-switch a:focus-visible, .location-explanation summary:focus-visible {
    outline: 3px solid #a4ed21; outline-offset: 3px;
}
.access-card > h1 { font-size: clamp(24px, 3vw, 32px); line-height: 1.25; }
.access-card > .description { margin-bottom: 12px; line-height: 1.5; }

.access-card { position: relative; }
.access-card > h1 { padding-inline: 12px; }
.location-info-button {
    position: absolute; top: 12px; right: 12px; width: 36px; height: 36px;
    display: grid; place-items: center; padding: 0; border: 1px solid #b4c7b8;
    border-radius: 50%; background: #f1f5ef; color: #16452d;
    font: 700 18px/1 Georgia, serif; cursor: pointer;
}
.location-info-button:focus-visible, .location-info-close:focus-visible { outline: 3px solid #a4ed21; outline-offset: 3px; }
.location-info-dialog {
    width: min(480px, calc(100vw - 32px)); max-height: calc(100dvh - 48px);
    padding: 44px 24px 24px; border: 1px solid #dce6da; border-radius: 22px;
    background: #fff; color: #173d2b; box-shadow: 0 20px 70px rgba(0,0,0,.25);
    overflow-y: auto; text-align: left;
}
.location-info-dialog::backdrop { background: rgba(10,30,20,.55); }
.location-info-close {
    position: absolute; right: 10px; top: 8px; width: 36px; height: 36px;
    border: 0; border-radius: 50%; background: #f1f5ef; color: #16452d;
    font-size: 28px; line-height: 1; cursor: pointer;
}
.location-explanation-content { font-size: 14px; line-height: 1.6; }
.location-explanation-content h2 { margin: 0 0 12px; font-size: 21px; line-height: 1.3; }
.location-explanation-content p { margin: 0; }
html.help-info-open { overflow: hidden; }
