/*
 * Autor: Lukasz Turczyn DFS
 * Data: 2026-09-27 (cookie banner: 2026-09-29; optional contact consent card: 2026-11-29; skip link, compact banner,
 * required-consent row: 2026-11-30)
 * Opis: okred-static.css - styles of the okred-forms.js outcome layer, of the cookie banner and of the optional contact
 * consent card (.okf-consent, text version kontakt-2026-12) on the static sites
 * (ambasadorkredytowy.pl, creditembassy.pl). Canonical source sites/_shared/, copied byte for byte into
 * sites/<domain>/assets/ (tools/sites/sync_shared_assets.py). Colours follow each site's --primary
 * (fallback: creditembassy navy). State is never carried by colour alone (every panel has a text title and
 * an icon glyph, every field error a text message); text contrast >= 4.5:1; targets >= 44px; logical
 * alignment (start) so Hebrew renders right-to-left; wraps at 320px (codes and references break anywhere).
 */
.okf-outcome{margin:16px 0;padding:14px 16px;border:2px solid #cbd5e1;border-radius:12px;background:#fff;color:#1a202c;font-size:.9375rem;line-height:1.5;text-align:start;overflow-wrap:anywhere;word-break:break-word}
.okf-outcome[hidden]{display:none!important}
.okf-outcome:focus{outline:3px solid var(--primary,#1B2A4A);outline-offset:3px}
.okf-outcome--success{border-color:#15803d;background:#f0fdf4}
.okf-outcome--error{border-color:#b91c1c;background:#fef2f2}
.okf-outcome--warn{border-color:#c2410c;background:#fff7ed}
.okf-outcome p{margin:0 0 8px;color:#1a202c;font-size:.9375rem;line-height:1.5;text-align:start;font-weight:400}
.okf-outcome p.okf-outcome__title{display:flex;gap:10px;align-items:flex-start;font-weight:700;font-size:1rem}
.okf-icon{flex:0 0 auto;display:inline-flex;align-items:center;justify-content:center;width:24px;height:24px;border-radius:50%;color:#fff;background:#475569;font-size:.875rem;font-weight:800;line-height:1}
.okf-outcome--success .okf-icon{background:#15803d}
.okf-outcome--error .okf-icon{background:#b91c1c}
.okf-outcome--warn .okf-icon{background:#c2410c}
.okf-ref,.okf-code{font-family:ui-monospace,SFMono-Regular,Menlo,Consolas,monospace;direction:ltr;unicode-bidi:isolate}
.okf-ref{font-size:1.0625rem;letter-spacing:.08em}
.okf-actions{display:flex;flex-wrap:wrap;gap:8px;margin:10px 0 4px}
.okf-btn{min-height:44px;padding:10px 16px;border:2px solid var(--primary,#1B2A4A);border-radius:10px;background:#fff;color:var(--primary,#1B2A4A);font:inherit;font-size:.9375rem;font-weight:600;cursor:pointer;line-height:1.2}
.okf-btn:hover{background:#eef2f7}
.okf-btn--primary{background:var(--primary,#1B2A4A);color:#fff}
.okf-btn--primary:hover{background:var(--primary-light,#2C4070)}
.okf-btn:focus-visible{outline:3px solid var(--primary,#1B2A4A);outline-offset:2px}
.okf-outcome p.okf-contact{display:flex;flex-wrap:wrap;gap:4px 18px;margin:6px 0 0}
.okf-contact__link{display:inline-flex;align-items:center;min-height:44px;color:var(--primary,#1B2A4A)!important;font-weight:700;text-decoration:underline;overflow-wrap:anywhere}
.okf-contact__link:focus-visible{outline:3px solid var(--primary,#1B2A4A);outline-offset:2px}
.okf-field-error{display:block;margin-top:4px;color:#b91c1c;font-size:.8125rem;font-weight:600;line-height:1.4;text-align:start}
.okf-field-error::before{content:"\26A0\FE0E  "}
[aria-invalid="true"]{border-color:#b91c1c!important}
.okf-status{min-height:1.4em;margin:8px 0 0;font-size:.875rem;font-weight:600;text-align:center;color:#1a202c}
.okf-spinner{display:inline-block;width:1em;height:1em;border:2px solid currentColor;border-right-color:transparent;border-radius:50%;vertical-align:-.15em;animation:okf-spin .8s linear infinite}
.okf-busy{cursor:progress!important;opacity:.85}
@keyframes okf-spin{to{transform:rotate(360deg)}}
@media (prefers-reduced-motion:reduce){.okf-spinner{animation-duration:2.4s}}
/* Until the script has bound the form, the submit button is hidden (and disabled in the markup, which also
   blocks implicit submission) and a "call or write" note is shown - never a dead button, never a native
   submit that would put personal data anywhere. */
form[data-okf-guard]:not([data-okf-ready]) [data-okf-submit]{display:none!important}
form[data-okf-guard][data-okf-ready] .okf-notready{display:none}
.okf-notready,.okf-noscript{margin:12px 0 0;padding:10px 12px;border:2px dashed #94a3b8;border-radius:10px;font-size:.9375rem;line-height:1.5;color:#1a202c;text-align:start}
.okf-notready a,.okf-noscript a{font-weight:700;text-decoration:underline;color:var(--primary,#1B2A4A)}
form[hidden]{display:none!important}
/* The widget appears on the first interaction with the form; the reserved height avoids a layout shift. */
.okf-captcha-wrap{display:flex;flex-wrap:wrap;margin:4px 0 16px;min-height:78px}
.okf-captcha-wrap .okf-field-error{flex-basis:100%}
/* Under the submit button (as on the main site): the reserved height no longer leaves an empty band between the
   required consent and the card, and the widget never pushes the button away from the pointer. */
[data-okf-submit]+.okf-captcha-wrap{margin:16px 0 0}
/* Honeypot: out of sight and out of the tab order without a negative offset (which would scroll RTL pages). */
.okf-hp{position:absolute!important;width:1px!important;height:1px!important;padding:0!important;margin:-1px!important;overflow:hidden!important;clip:rect(0,0,0,0)!important;clip-path:inset(50%)!important;white-space:nowrap!important;border:0!important}
.okf-sr{position:absolute!important;width:1px;height:1px;padding:0;margin:-1px;overflow:hidden;clip:rect(0,0,0,0);white-space:nowrap;border:0}
/* Visible keyboard focus on the contact form fields (the sites' own focus styles are a faint glow). */
[data-okf-guard] input:focus-visible,[data-okf-guard] select:focus-visible,[data-okf-guard] textarea:focus-visible{outline:3px solid var(--primary,#1B2A4A);outline-offset:2px}
/* A checkbox row laid out as flex (creditembassy .form-checkbox): the error message takes its own line. */
[data-okf-guard] .form-checkbox{flex-wrap:wrap}
[data-okf-guard] .form-checkbox>label{flex:1 1 0;min-width:0}
[data-okf-guard] .form-checkbox>.okf-field-error{flex-basis:100%}
/* Panels and fields that receive focus never end up under the sites' fixed navigation bar. */
.okf-outcome,[data-okf-guard] input,[data-okf-guard] select,[data-okf-guard] textarea,.okf-captcha{scroll-margin-top:96px}
@media (max-width:360px){.okf-outcome{padding:12px}.okf-actions{flex-direction:column}.okf-btn{width:100%}}
/* Cookie banner (okred-static.js 1.2.0; compact layout 1.4.0): a region fixed at the bottom, not a modal. Accept and
   Reject share one style (equal weight); the current choice is spelled out in text, the matching button adds a check
   mark. The policy link is an inline link at the end of the text. From 768px the copy and the two buttons share one
   row; on phones the heading is not painted and the buttons sit side by side under the text.
   z-index 990: above page content, below the sites' fixed navigation and open mobile menus (1000) and below
   every dialog/overlay (1100+), so an open menu or dialog is never covered. Logical alignment for RTL. */
.okc-banner{position:fixed;left:0;right:0;bottom:0;z-index:990;max-height:70vh;overflow-y:auto;background:#fff;color:#1a202c;border-top:3px solid var(--primary,#1B2A4A);box-shadow:0 -8px 30px rgba(10,22,40,.18);font-size:.9375rem;line-height:1.5;text-align:start}
.okc-banner[hidden],.okc-spacer[hidden],.okc-state[hidden],.okc-link[hidden]{display:none!important}
.okc-inner{max-width:1100px;margin:0 auto;padding:16px 20px;padding-bottom:calc(16px + env(safe-area-inset-bottom,0px))}
.okc-banner .okc-title{margin:0 0 6px;padding:0;font-family:inherit;font-size:1.0625rem;font-weight:700;line-height:1.3;letter-spacing:normal;text-transform:none;color:#1a202c;text-align:start}
.okc-banner .okc-title:focus{outline:3px solid var(--primary,#1B2A4A);outline-offset:3px}
.okc-banner .okc-text,.okc-banner .okc-state{margin:0 0 10px;padding:0;font-size:.9375rem;line-height:1.5;color:#1a202c;text-align:start}
.okc-banner .okc-state{font-weight:700}
.okc-actions{display:flex;flex-wrap:wrap;align-items:center;gap:10px 12px}
.okc-banner .okc-btn{flex:1 1 130px;max-width:240px;min-height:44px;margin:0;padding:10px 16px;border:2px solid var(--primary,#1B2A4A);border-radius:10px;background:var(--primary,#1B2A4A);color:#fff;font:inherit;font-size:.9375rem;font-weight:700;line-height:1.2;text-align:center;cursor:pointer}
.okc-banner .okc-btn:hover{background:var(--primary-light,#2C4070);border-color:var(--primary-light,#2C4070)}
.okc-banner .okc-btn:focus-visible{outline:3px solid var(--primary,#1B2A4A);outline-offset:3px}
.okc-banner .okc-btn[data-current]::before{content:"\2713\FE0E\00A0"}
.okc-banner .okc-link{color:var(--primary,#1B2A4A);font-weight:700;text-decoration:underline;white-space:nowrap}
.okc-banner .okc-link:focus-visible{outline:3px solid var(--primary,#1B2A4A);outline-offset:2px}
@media (min-width:768px){.okc-inner{display:flex;align-items:center;max-width:1280px;gap:12px 28px;padding-top:12px;padding-bottom:calc(12px + env(safe-area-inset-bottom,0px))}.okc-copy{flex:1 1 0;min-width:0}.okc-banner .okc-title{display:inline;margin:0;margin-inline-end:8px;font-size:1rem}.okc-banner .okc-text{display:inline;margin:0}.okc-banner .okc-state{margin:4px 0 0}.okc-actions{flex:0 0 auto;flex-wrap:nowrap}.okc-banner .okc-btn{flex:0 0 auto;min-width:124px}}
/* Phones and narrow tablets (under 768px): the heading stays in the accessibility tree (it names the region) but is not painted; Accept and Reject
   stay equal, side by side. */
@media (max-width:767px){.okc-banner{max-height:45vh;border-top-width:2px}.okc-inner{padding:10px 16px;padding-bottom:calc(10px + env(safe-area-inset-bottom,0px))}.okc-banner .okc-title{position:absolute;width:1px;height:1px;margin:-1px;padding:0;overflow:hidden;clip:rect(0 0 0 0);clip-path:inset(50%);white-space:nowrap}.okc-banner .okc-text,.okc-banner .okc-state{margin-bottom:8px;font-size:.8125rem;line-height:1.4}.okc-actions{display:grid;grid-template-columns:repeat(2,minmax(0,240px));gap:6px 8px}.okc-banner .okc-btn{flex:none;min-width:0;max-width:none;padding:8px 10px}}
@media print{.okc-banner,.okc-spacer{display:none!important}}
/* Optional contact consent card (kontakt-2026-12, 2026-11-29): static HTML directly above the submit button, never
   pre-ticked, so nothing shifts. The whole card is the tap target (the label's ::after covers it, >= 44px); the tint
   is 8% of each site's --primary over white (plain #eef2f7 where color-mix is missing), the text stays >= 4.5:1 on it; logical alignment so Hebrew renders right-to-left. */
.okf-consent{margin:4px 0 18px;text-align:start}
.okf-consent .okf-consent__why{margin:0 0 8px;font-size:.875rem;line-height:1.5;color:var(--text-muted,#475569)}
.okf-consent .okf-consent__box{position:relative;display:flex;align-items:flex-start;gap:12px;min-height:44px;padding:14px 16px;border:1px solid rgba(15,23,42,.3);border-radius:12px;background:#eef2f7;background:color-mix(in srgb,var(--primary,#1B2A4A) 8%,#fff);color:var(--text-dark,#1a1a2e)}
.okf-consent .okf-consent__box:focus-within{border-color:var(--primary,#1B2A4A)}
.okf-consent .okf-consent__box input[type=checkbox]{position:relative;z-index:1;flex:0 0 auto;width:22px;height:22px;min-width:22px;margin:2px 0 0;padding:0;accent-color:var(--primary,#1B2A4A);cursor:pointer}
.okf-consent .okf-consent__box label{display:block;flex:1 1 0;min-width:0;margin:0;padding:0;font-size:.875rem;font-weight:400;line-height:1.5;color:var(--text-dark,#1a1a2e);cursor:pointer;text-align:start}
.okf-consent .okf-consent__box label::after{content:"";position:absolute;inset:0}
.okf-consent .okf-consent__title{display:flex;align-items:flex-start;gap:8px;margin:0 0 4px;font-size:1rem;font-weight:700;line-height:1.35;color:var(--text-dark,#1a1a2e)}
.okf-consent .okf-consent__ico{flex:0 0 auto;margin-top:2px;color:var(--primary,#1B2A4A)}
.okf-consent .okf-consent__body{display:block}
.okf-consent .okf-consent__note{display:block;margin-top:6px;font-size:.78rem;line-height:1.45;color:var(--text-muted,#475569);overflow-wrap:anywhere}
.okf-consent .okf-consent__box input[type=checkbox]:focus-visible{outline:3px solid var(--primary,#1B2A4A);outline-offset:2px}
/* The muted line on a calculator result for a visitor who did not tick the card (no auto-consent, no second form). */
.consent-declined-note{margin:12px 0 0;font-size:.875rem;line-height:1.5;color:var(--text-muted,#475569);text-align:start}
.consent-declined-note[hidden]{display:none}
.consent-declined-note a{color:var(--primary,#1B2A4A);font-weight:600;text-decoration:underline}
/* Required privacy consent row (2026-12, UX review S-04): the same 22px box and >= 44px row as the optional card under
   it and body-colour text, so the required consent no longer looks like the lesser of the two. The "Required" tag says
   in words what the asterisk means; logical alignment for RTL; the field error takes its own line. */
[data-okf-guard] .okf-required{display:flex;flex-wrap:wrap;align-items:flex-start;gap:4px 12px;min-height:44px;margin:0 0 18px;padding:9px 0;text-align:start}
[data-okf-guard] .okf-required>input[type=checkbox]{flex:0 0 auto;width:22px;height:22px;min-width:22px;margin:2px 0 0;padding:0;accent-color:var(--primary,#1B2A4A);cursor:pointer}
[data-okf-guard] .okf-required>label{display:block;flex:1 1 0;min-width:0;margin:0;padding:0;font-size:.9rem;font-weight:400;line-height:1.5;color:var(--text-dark,#1a1a2e);cursor:pointer;text-align:start}
[data-okf-guard] .okf-required>label a{color:var(--primary,#1B2A4A);font-weight:600;text-decoration:underline}
[data-okf-guard] .okf-required .okf-required__tag{display:inline-block;margin-inline-end:6px;padding:1px 8px;border:1px solid currentColor;border-radius:999px;font-size:.75rem;font-weight:700;line-height:1.5;color:#b91c1c;vertical-align:1px}
[data-okf-guard] .okf-required>input[type=checkbox]:focus-visible{outline:3px solid var(--primary,#1B2A4A);outline-offset:2px}
[data-okf-guard] .okf-required>.okf-field-error{flex-basis:100%}
/* Skip link (2026-11-30, UX review S-37): the first link of the page, painted only while focused, above the fixed
   navigation; the target is the page's <main id="main" tabindex="-1">, which takes the focus without a ring. */
.okf-skip{position:fixed;top:0;inset-inline-start:12px;z-index:1200;transform:translateY(-120%);padding:12px 18px;border-radius:0 0 10px 10px;background:#fff;color:var(--primary,#1B2A4A);font-size:1rem;font-weight:700;line-height:1.25;text-decoration:underline;box-shadow:0 6px 20px rgba(10,22,40,.3)}
.okf-skip:focus{transform:none;outline:3px solid var(--primary,#1B2A4A);outline-offset:-3px}
main[tabindex="-1"]:focus{outline:none}
