/* Login presentation. BankID state visibility is controlled by the existing flow. */
body.paydrive-login-page {
    margin: 0;
    min-height: 100vh;
    background: #f5faf9;
    color: #082c32;
    font-family: "Quicksand", "Segoe UI", sans-serif;
    font-size: 16px;
    line-height: 1.65;
    -webkit-font-smoothing: antialiased;
}

.paydrive-login-page *,
.paydrive-login-page *::before,
.paydrive-login-page *::after { box-sizing: border-box; }

.paydrive-login-page a { color: inherit; }
.paydrive-login-page button { font-family: inherit; }
.paydrive-login-page a:focus-visible,
.paydrive-login-page button:focus-visible {
    outline: 3px solid #438999;
    outline-offset: 5px;
}

.pd-login-skip {
    position: fixed;
    top: -100px;
    left: 20px;
    z-index: 100;
    padding: 12px 18px;
    border-radius: 9px;
    background: #fff;
}
.pd-login-skip:focus { top: 12px; }

.pd-login-header { background: #184147; }
.pd-login-header-inner {
    width: min(1220px, calc(100% - 96px));
    min-height: 94px;
    margin: 0 auto;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 24px;
}
.pd-login-logo { display: flex; align-items: center; }
.pd-login-logo img { display: block; width: 152px; height: auto; }
.paydrive-login-page .pd-login-back {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    color: #fff;
    font-size: 14px;
    font-weight: 600;
    text-decoration: none;
}
.pd-login-back:hover { text-decoration: underline; text-underline-offset: 5px; }

.pd-login-main {
    width: min(1140px, calc(100% - 96px));
    margin: 0 auto;
    padding: 76px 0 62px;
    display: grid;
    grid-template-columns: minmax(0, 1fr) minmax(360px, 450px);
    align-items: start;
    gap: clamp(44px, 7vw, 104px);
}
.pd-login-intro { padding: 12px 0 0; }
.pd-login-eyebrow {
    margin: 0 0 22px;
    display: flex;
    align-items: center;
    gap: 10px;
    font-size: 12px;
    font-weight: 700;
    letter-spacing: 1.8px;
    line-height: 1.4;
    text-transform: uppercase;
}
.pd-login-eyebrow > span {
    display: inline-block;
    width: 8px;
    height: 8px;
    background: #397367;
    border-radius: 50%;
}
.pd-login-intro h1 {
    margin: 0;
    color: #082c32;
    font-family: inherit;
    font-size: clamp(42px, 4.4vw, 62px);
    font-weight: 600;
    letter-spacing: -2.6px;
    line-height: 1.14;
}
.pd-login-intro h1 > span { color: #397367; }
.pd-login-lead { max-width: 420px; margin: 26px 0 32px; color: #456369; font-size: 17px; line-height: 1.8; }
.pd-login-benefits { list-style: none; padding: 0; margin: 0; display: grid; gap: 21px; }
.pd-login-benefits li { display: flex; align-items: center; gap: 16px; }
.pd-login-benefit-icon {
    display: flex;
    flex: 0 0 44px;
    width: 44px;
    height: 44px;
    align-items: center;
    justify-content: center;
    border: 1px solid #c6dcd5;
    border-radius: 13px;
    color: #184147;
    background: #eaf3ef;
}
.pd-login-benefit-icon svg { width: 23px; height: 23px; stroke: currentColor; stroke-width: 1.6; stroke-linecap: round; stroke-linejoin: round; }
.pd-login-benefits strong { display: block; font-weight: 700; line-height: 1.5; }
.pd-login-benefits strong + span { display: block; color: #456369; font-size: 14px; line-height: 1.5; }
.pd-login-signoff { color: #52726d; font-size: 14px; font-weight: 600; margin: 32px 0 0 60px; }

.pd-login-panel { padding-top: 16px; outline: none; }
.pd-login-form { margin: 0; }
.pd-login-card {
    padding: 40px 34px 32px;
    border: 1px solid #c5ddd4;
    border-radius: 22px;
    background: #fff;
    box-shadow: 0 18px 48px -34px rgba(7, 60, 67, .3);
}
.pd-login-card-heading { text-align: center; }
.pd-login-card-heading .pd-login-eyebrow { justify-content: center; margin-bottom: 12px; color: #3c655d; font-size: 11px; }
.pd-login-card-heading h1,
.pd-login-card-heading h2 {
    color: #082c32;
    margin: 0 0 10px;
    font-family: inherit;
    font-size: 33px;
    font-weight: 600;
    line-height: 1.25;
    letter-spacing: -1px;
}
.pd-login-card-heading > p:last-child { margin: 0; font-size: 14px; color: #3c605e; }
.pd-login-bankid { text-align: center; padding: 27px 0 21px; }
.pd-login-bankid img { display: block; width: 76px; height: 76px; object-fit: contain; margin: 0 auto 14px; }
.pd-login-bankid p { margin: 0; font-size: 14px; font-weight: 600; }
.pd-login-actions { display: grid; gap: 12px; }
.paydrive-login-page .pd-login-card .btn {
    width: 100%;
    min-height: 52px;
    padding: 13px 18px;
    border-radius: 9px;
    border-width: 1px;
    font-size: 14px;
    font-weight: 700;
    line-height: 1.5;
    white-space: normal;
    text-transform: none;
    box-shadow: none;
    transition: background-color .15s ease, border-color .15s ease;
}
.paydrive-login-page .pd-login-card .pd-login-primary {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 14px;
    color: #fff;
    background: #073c43;
    border-color: #073c43;
}
.paydrive-login-page .pd-login-card .pd-login-primary:hover { color: #fff; background: #20565b; border-color: #20565b; }
.paydrive-login-page .pd-login-card .pd-login-secondary { color: #184147; background: #f5faf9; border-color: #9bbeb2; }
.paydrive-login-page .pd-login-card .pd-login-secondary:hover { color: #184147; background: #e8f2ee; border-color: #184147; }
.paydrive-login-page .pd-login-card .btn:disabled { opacity: .55; cursor: wait; }
.pd-login-howto { text-align: center; font-size: 12px; margin: 22px 0 0; }
.pd-login-howto a { text-decoration: underline; text-underline-offset: 3px; }
.pd-login-help { display: flex; justify-content: center; align-items: center; gap: 14px; margin-top: 25px; font-size: 13px; color: #456369; }
.pd-login-help-icon { display: flex; color: #184147; }
.pd-login-help strong { display: block; font-weight: 700; color: #184147; }
.pd-login-help p { margin: 0; }
.pd-login-help a { font-weight: 700; text-decoration: underline; text-underline-offset: 3px; }
.pd-login-notice, .pd-login-warning { font-size: 14px; border-radius: 10px; }
.pd-login-warning { padding: 12px 14px; background: #fff7e7; border: 1px solid #dcc99d; color: #6b4c17; }
.pd-login-status { padding: 26px 0 8px; overflow-wrap: anywhere; }
.pd-login-status p { margin: 0 0 16px; }
.pd-login-status-logo { display: block; width: 76px; max-width: 100%; margin: 16px auto; }
.pd-login-status .spinner-border.text-info { display: block; width: 36px; height: 36px; margin: 24px auto 10px; color: #184147 !important; }
.pd-login-status-error { color: #9b3030; }
.pd-login-status-success { color: #236143; }
.pd-login-cancel { margin-top: 24px; }
.pd-login-qr-card #qrCodeHeader { margin: 20px 0; font-size: 14px; }
.pd-login-qr-card #qrcode { width: 100%; max-width: 300px; min-height: 220px; margin: 0 auto; background: #fff; border-radius: 10px; overflow: hidden; }
.pd-login-qr-card #qrcode:empty { background: transparent; }
.pd-login-qr-card #qrcode img { display: block; max-width: 100%; height: auto; margin: auto; }
.pd-login-qr-card #bankIdInfo { display: block; overflow-wrap: anywhere; font-size: 12px; }
.pd-login-footer {
    width: min(1220px, calc(100% - 96px));
    margin: 0 auto;
    padding: 25px 0 30px;
    border-top: 1px solid #d2e4dd;
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 18px;
    color: #52706d;
    font-size: 12px;
    font-weight: 600;
}
.pd-login-footer p { margin: 0; }
.pd-login-footer a { text-decoration: none; }
.pd-login-footer a:hover { text-decoration: underline; text-underline-offset: 4px; }
.pd-login-footer a span { margin-left: 6px; }

@media (max-width: 1000px) {
    .pd-login-main { width: calc(100% - 64px); gap: 36px; grid-template-columns: minmax(0, 1fr) minmax(330px, .95fr); padding-top: 52px; }
    .pd-login-intro h1 { font-size: 46px; letter-spacing: -1.8px; }
    .pd-login-lead { font-size: 15px; }
    .pd-login-card { padding: 32px 26px 28px; }
    .pd-login-benefits strong + span { font-size: 12px; }
}
@media (max-width: 760px) {
    .pd-login-header-inner { width: calc(100% - 40px); min-height: 76px; gap: 16px; }
    .pd-login-logo img { width: 128px; }
    .paydrive-login-page .pd-login-back { font-size: 12px; gap: 7px; }
    .pd-login-main { width: min(520px, calc(100% - 40px)); padding: 35px 0 36px; grid-template-columns: minmax(0, 1fr); gap: 28px; }
    .pd-login-intro { padding: 0; }
    .pd-login-intro > .pd-login-eyebrow { margin-bottom: 16px; }
    .pd-login-intro h1 { font-size: clamp(38px, 8.8vw, 46px); letter-spacing: -1.8px; }
    .pd-login-intro h1 br { display: none; }
    .pd-login-intro h1 > span { display: block; }
    .pd-login-lead { margin: 18px 0 0; max-width: none; font-size: 15px; line-height: 1.7; }
    .pd-login-benefits { display: none; }
    .pd-login-signoff { display: none; }
    .pd-login-panel { padding-top: 0; }
    .pd-login-card { padding: 30px 24px 27px; }
    .pd-login-card-heading h1,.pd-login-card-heading h2 { font-size: 30px; }
    .pd-login-bankid { padding: 22px 0 20px; }
    .pd-login-help { margin-top: 22px; }
    .pd-login-footer { width: calc(100% - 40px); flex-wrap: wrap; gap: 8px; padding: 21px 0 25px; }
}
@media (max-width: 370px) {
    .pd-login-main { width: calc(100% - 28px); }
    .pd-login-card { padding: 28px 18px 24px; }
    .pd-login-intro h1 { font-size: 35px; }
    .pd-login-header-inner { width: calc(100% - 28px); }
    .pd-login-logo img { width: 113px; }
    .pd-login-back svg { display: none; }
}
@media (prefers-reduced-motion: reduce) {
    .paydrive-login-page *, .paydrive-login-page *::before, .paydrive-login-page *::after { transition: none !important; }
}
