/* =========================================================
   KOS RAPORTY – AUTOMATYCZNA LISTA + FORMULARZ
   ========================================================= */

.kos-reports-access,
.kos-reports-access * {
    box-sizing: border-box;
}

.kos-reports-access {
    width: 100%;
    max-width: none;
    margin: 0;
    padding: 10px 0 30px;
    font-family: "Open Sans", Helvetica, Arial, Verdana, sans-serif;
    font-weight: 500;
}

/* =========================================================
   LISTA RAPORTÓW – PEŁNA SZEROKOŚĆ
   ========================================================= */

.kos-reports-main {
    width: 100%;
    min-width: 0;
}

/* =========================================================
   LISTA RAPORTÓW
   ========================================================= */

.kos-reports-list {
    display: flex;
    flex-direction: column;
    gap: 20px;
}

.kos-report-card {
    display: grid;
    grid-template-columns: 175px minmax(0, 1fr);
    gap: 28px;
    align-items: start;
    padding: 20px;
    background: #fff;
    border: 2px dotted #d7d7d7;
    border-radius: 12px;
    box-shadow: none;
    transition: border-color .2s ease;
}

.kos-report-card:hover {
    border-color: #c9c9c9;
    box-shadow: none;
    transform: none;
}

.kos-report-card-image {
    width: 100%;
    align-self: start;
    margin: 0;
    padding: 0;
}

.kos-report-cover {
  display: block;
  width: 100%;
  height: auto !important;
  margin: 0;
  border-radius: 8px !important;
  box-shadow: 0 6px 18px rgba(0, 0, 0, .12) !important;
  overflow: hidden !important;
}

.kos-report-cover-placeholder {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 100%;
    aspect-ratio: .72;
    margin: 0;
    border-radius: 8px;
    background: #f3f3f3;
    color: #64748b;
    font-size: 17px;
    box-shadow: 0 6px 18px rgba(0, 0, 0, .10);
}

.kos-report-card-content {
    min-width: 0;
    align-self: start;
    padding-top: 2px;
}

.kos-report-card-title {
    margin: 0 0 12px;
    font-family: "Barlow", Helvetica, Arial, Verdana, sans-serif;
    font-size: 24px;
    font-weight: 600;
    line-height: 1.25;
    color: #172033;
}

.kos-report-card-description {
    margin: 0 0 20px;
    font-size: 15px;
    line-height: 1.65;
    color: #5b6472;
}

.kos-report-card-description p {
    margin: 0 0 10px;
}

.kos-report-card-description p:last-child {
    margin-bottom: 0;
}

.kos-report-card-description strong,
.kos-report-card-description b {
    font-weight: 700;
    color: #303b48;
}

.kos-report-card-description ul,
.kos-report-card-description ol {
    margin: 10px 0 14px 20px;
    padding: 0;
}

.kos-report-card-description li {
    margin: 0 0 5px;
}

.kos-report-card-description a {
    color: #0181ab;
    text-decoration: underline;
    text-underline-offset: 2px;
}

/* =========================================================
   PRZYCISK – 1:1 WG PRZESŁANEGO WZORU

   Gradient ze screena:
   góra  #5CC2DF
   dół   #0181AB
   wysokość: 45 px
   hover: gradient odwrócony
   ========================================================= */

.kos-report-open-form {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;

    height: 45px;
    min-height: 45px;
    padding: 0 25px;

    border: 0;
    border-radius: 23px;

    background: linear-gradient(
        to bottom,
        #5cc2df 0%,
        #0181ab 100%
    );

    color: #fff;
    cursor: pointer;
    font-family: "Open Sans", Helvetica, Arial, Verdana, sans-serif;
    font-size: 14px;
    font-weight: 600;
    line-height: 1;
    text-decoration: none;
    white-space: nowrap;

    box-shadow: none;
    transition: background .22s ease, transform .18s ease;
}

.kos-report-open-form:hover,
.kos-report-open-form:focus-visible {
    background: linear-gradient(
        to bottom,
        #0181ab 0%,
        #5cc2df 100%
    );
    color: #fff;
    outline: none;
}

.kos-report-open-form:active {
    transform: translateY(1px);
}

.kos-report-free-badge {
    display: inline-block;
    color: #fff;
    font-size: 10px;
    font-weight: 700;
    line-height: 1;
    letter-spacing: .04em;
}

.kos-report-free-badge::after {
    content: "•";
    display: inline-block;
    margin-left: 8px;
    opacity: .75;
}

.kos-report-button-label {
    font-size: 14px;
    font-weight: 600;
    line-height: 1;
}

/* =========================================================
   LIGHTBOX FORMULARZA
   ========================================================= */

body.kos-report-modal-open {
    overflow: hidden;
}

.kos-report-modal {
    position: fixed !important;
    inset: 0 !important;
    z-index: 2147483000 !important;

    display: flex;
    align-items: center;
    justify-content: center;

    width: 100vw !important;
    height: 100vh !important;
    height: 100dvh !important;
    margin: 0 !important;
    padding: 24px;

    background: rgba(12, 25, 40, .68);
    backdrop-filter: blur(3px);
    -webkit-backdrop-filter: blur(3px);
}

.kos-report-modal[hidden] {
    display: none !important;
}

.kos-report-modal-dialog {
    position: relative !important;
    z-index: 2147483001 !important;

    width: min(760px, 100%);
    max-height: calc(100vh - 48px);
    overflow: auto;

    border-radius: 16px;
    background: #fff;

    box-shadow: 0 24px 70px rgba(0, 0, 0, .24);
}

.kos-report-modal-close {
    position: absolute;
    top: 14px;
    right: 14px;
    z-index: 2147483002 !important;

    display: inline-flex;
    align-items: center;
    justify-content: center;

    width: 40px;
    height: 40px;
    padding: 0;

    border: 0;
    border-radius: 50%;

    background: #eef3f6;
    color: #172033;

    cursor: pointer;
    font-size: 28px;
    font-weight: 400;
    line-height: 1;

    transition: background .2s ease, color .2s ease, transform .2s ease;
}

.kos-report-modal-close:hover,
.kos-report-modal-close:focus-visible {
    background: #dfe9ee;
    color: #0181ab;
    outline: none;
}

.kos-report-modal-close:active {
    transform: scale(.96);
}

.kos-report-form-card {
    padding: 34px;
    background: #fff;
    border: 1px solid #e2e8ee;
    border-radius: 14px;
    box-shadow: 0 8px 25px rgba(16, 24, 40, .045);
}


.kos-report-modal .kos-report-form-card {
    border: 0;
    border-radius: 16px;
    box-shadow: none;
    padding: 38px 42px 40px;
}

.kos-report-form-heading {
    margin: 0 0 12px;
    font-family: "Barlow", Helvetica, Arial, Verdana, sans-serif;
    font-size: 27px;
    font-weight: 600;
    line-height: 1.25;
    color: #172033;
}

.kos-report-selected-info {
    margin: 0 0 25px;
    padding: 12px 14px;
    border-radius: 7px;
    background: #f4f8fa;
    font-size: 14px;
    line-height: 1.5;
    color: #53606e;
}

.kos-report-selected-info strong {
    color: #172033;
}

.kos-report-form,
.kos-report-form * {
    box-sizing: border-box;
}

.kos-report-form p {
    margin: 0;
    padding: 0;
}

.kos-form-row {
    display: grid;
    gap: 20px;
    margin: 0 0 18px;
}

.kos-form-row-2 {
    grid-template-columns: repeat(2, minmax(0, 1fr));
}

.kos-form-field {
    margin: 0 0 18px;
}

.kos-form-row .kos-form-field {
    margin-bottom: 0;
}

.kos-report-form .kos-form-field > label {
    display: block;
    margin: 0;
    font-size: 15px;
    font-weight: 500;
    line-height: 1.4;
    color: #172033;
}

.kos-report-form .kos-form-field > label > .wpcf7-form-control-wrap {
    display: block;
    margin-top: 8px;
}

.kos-report-form .required {
    color: #d63638;
    margin-left: 2px;
}

.kos-report-form input[type="text"],
.kos-report-form input[type="email"] {
    display: block;
    width: 100%;
    height: 50px;
    margin: 0;
    padding: 0 15px;
    border: 1px solid #d6dae1;
    border-radius: 8px;
    background: #fff;
    font-family: "Open Sans", Helvetica, Arial, Verdana, sans-serif;
    font-size: 15px;
    font-weight: 500;
    color: #172033;
    transition: border-color .2s ease, box-shadow .2s ease;
}

.kos-report-form input[type="text"]:focus,
.kos-report-form input[type="email"]:focus {
    outline: none;
    border-color: #0ea5c6;
    box-shadow: 0 0 0 3px rgba(14, 165, 198, .12);
}

.kos-data-security {
    margin: 4px 0 22px;
    padding: 15px 17px;
    border: 1px solid #dbe9f0;
    border-radius: 9px;
    background: #eef7fb;
}

.kos-data-security strong {
    display: block;
    margin-bottom: 4px;
    font-family: "Barlow", Helvetica, Arial, Verdana, sans-serif;
    font-size: 16px;
    font-weight: 600;
    color: #172033;
}

.kos-data-security span {
    display: block;
    font-size: 13px;
    line-height: 1.55;
    color: #596373;
}

.kos-form-consents {
    margin: 0;
}

.kos-consent {
    margin: 0 0 14px;
}

.kos-consent:last-child {
    margin-bottom: 0;
}

.kos-form-consents .wpcf7-acceptance,
.kos-form-consents .wpcf7-list-item {
    display: block;
    margin: 0;
}

.kos-form-consents label {
    display: flex;
    align-items: flex-start;
    gap: 10px;
    margin: 0;
    cursor: pointer;
    font-size: 14px;
    font-weight: 500;
    line-height: 1.55;
    color: #3b4451;
}

.kos-form-consents input[type="checkbox"] {
    flex: 0 0 18px;
    width: 18px;
    height: 18px;
    margin: 2px 0 0;
}

.kos-form-consents a {
    color: #0a92b2;
    text-decoration: underline;
    text-underline-offset: 2px;
}

.kos-form-consents a:hover {
    text-decoration: none;
}

.kos-form-submit {
    margin: 24px 0 0;
}

.kos-form-submit input[type="submit"] {
    display: block;
    width: 100%;
    min-height: 54px;
    margin: 0;
    padding: 12px 25px;
    border: 0;
    border-radius: 8px;
    background: #0ea5c6;
    color: #fff;
    cursor: pointer;
    font-family: "Open Sans", Helvetica, Arial, Verdana, sans-serif;
    font-size: 16px;
    font-weight: 600;
    transition: background .2s ease, transform .2s ease;
}

.kos-form-submit input[type="submit"]:hover {
    background: #0b92af;
}

.kos-form-submit input[type="submit"]:active {
    transform: translateY(1px);
}

.kos-report-form .wpcf7-not-valid-tip {
    display: block;
    margin: 5px 0 0;
    font-size: 13px;
}

.kos-report-form .wpcf7-response-output {
    margin: 22px 0 0 !important;
    padding: 16px 18px !important;
    border-radius: 9px;
    font-size: 14px;
    line-height: 1.65;
}

.kos-report-form .wpcf7 form.sent .wpcf7-response-output {
    border-color: #0ea5c6;
    background: #eef9fb;
    color: #263238;
}

@media (max-width: 991px) {
}

@media (max-width: 767px) {
  .kos-reports-access {
        padding-bottom: 20px;
    }

    .kos-report-card {
        grid-template-columns: 1fr;
        gap: 20px;
        padding: 16px;
        border-radius: 10px;
    }

    .kos-report-card-image {
        max-width: 220px;
        margin: 0 auto;
    }

    .kos-report-card-title {
        font-size: 22px;
    }

    .kos-report-open-form {
        width: 100%;
        padding-left: 18px;
        padding-right: 18px;
    }

    .kos-report-form-card {
        padding: 23px 18px;
    }

    .kos-report-form-heading {
        font-size: 24px;
    }

    .kos-form-row-2 {
        grid-template-columns: 1fr;
        gap: 0;
    }

    .kos-form-row .kos-form-field {
        margin-bottom: 16px;
    }

    .kos-form-row .kos-form-field:last-child {
        margin-bottom: 0;
    }
}


/* =========================================================
   LIGHTBOX – MOBILE
   ========================================================= */

@media (max-width: 767px) {
    .kos-report-modal {
        align-items: flex-start;
        padding: 12px;
        overflow-y: auto;
    }

    .kos-report-modal-dialog {
        width: 100%;
        max-height: none;
        margin: 12px 0;
        border-radius: 13px;
    }

    .kos-report-modal .kos-report-form-card {
        padding: 28px 18px 24px;
    }

    .kos-report-modal-close {
        top: 9px;
        right: 9px;
        width: 36px;
        height: 36px;
        font-size: 25px;
    }

    .kos-report-form-heading {
        padding-right: 42px;
    }
}

/* =========================================================
   KOS RAPORTY 1.1.0 – USTALONE STYLE + WERSJE JĘZYKOWE
   ========================================================= */

/* Zachowujemy dokładnie ten styl w kolejnych wersjach. */
.kos-report-cover {
  display: block;
  width: 100%;
  height: auto !important;
  margin: 0;
  border-radius: 8px !important;
  box-shadow: 0 6px 18px rgba(0, 0, 0, .12) !important;
  overflow: hidden !important;
}

.kos-report-card-title {
    color: #444444;
}

/* Wersja językowa raportu. */
.kos-report-lang-en {
    display: none !important;
}

.kos-reports-access.kos-lang-en .kos-report-lang-pl {
    display: none !important;
}

.kos-reports-access.kos-lang-en div.kos-report-lang-en {
    display: block !important;
}

.kos-reports-access.kos-lang-en span.kos-report-lang-en {
    display: inline !important;
}

.kos-reports-access.kos-lang-en .kos-report-free-badge.kos-report-lang-en {
    display: inline-flex !important;
}

/* Modal jest przenoszony bezpośrednio do <body>, dlatego otrzymuje
   własną klasę językową niezależnie od kontenera shortcode. */
.kos-report-modal.kos-lang-en .kos-report-lang-pl {
    display: none !important;
}

.kos-report-modal.kos-lang-en div.kos-report-lang-en {
    display: block !important;
}

.kos-report-modal.kos-lang-en span.kos-report-lang-en {
    display: inline !important;
}

.kos-report-modal.kos-lang-en .kos-report-free-badge.kos-report-lang-en {
    display: inline-flex !important;
}

.kos-report-language-hidden {
    display: none !important;
}

/* Przycisk raportu – bez przesuwania po hoverze. */
.kos-report-open-form,
.kos-report-open-form:hover,
.kos-report-open-form:focus-visible,
.kos-report-open-form:active {
    transform: none !important;
}

.kos-report-open-form {
    height: 45px;
    min-height: 45px;
    padding: 0 25px;
    border: 0 !important;
    border-radius: 23px !important;
    background: linear-gradient(to bottom, #5CC2DF 0%, #0181AB 100%) !important;
    color: #fff !important;
    box-shadow: none !important;
    transition: background .22s ease !important;
}

.kos-report-open-form:hover,
.kos-report-open-form:focus-visible {
    background: linear-gradient(to bottom, #0181AB 0%, #5CC2DF 100%) !important;
    color: #fff !important;
}

/* Oznaczenie BEZPŁATNY / FREE. */
.kos-report-free-badge {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 4px 8px;
    border-radius: 999px;
    background: #E83278 !important;
    color: #fff !important;
    font-size: 10px;
    font-weight: 700;
    line-height: 1;
    letter-spacing: .04em;
}

.kos-report-free-badge::after {
    content: none !important;
    display: none !important;
}

/* Przycisk formularza – ten sam styl, bez ruchu. */
.kos-form-submit input[type="submit"],
.kos-report-form input[type="submit"],
.kos-report-modal input[type="submit"] {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: auto !important;
    min-width: 180px;
    min-height: 45px;
    margin: 0 !important;
    padding: 10px 26px !important;
    border: 0 !important;
    border-radius: 999px !important;
    background: linear-gradient(to bottom, #5CC2DF 0%, #0181AB 100%) !important;
    color: #fff !important;
    font-family: "Open Sans", Helvetica, Arial, Verdana, sans-serif !important;
    font-size: 14px !important;
    font-weight: 600 !important;
    line-height: 1 !important;
    cursor: pointer;
    box-shadow: none !important;
    transform: none !important;
    transition: background .22s ease !important;
}

.kos-form-submit input[type="submit"]:hover,
.kos-form-submit input[type="submit"]:focus,
.kos-report-form input[type="submit"]:hover,
.kos-report-form input[type="submit"]:focus,
.kos-report-modal input[type="submit"]:hover,
.kos-report-modal input[type="submit"]:focus {
    background: linear-gradient(to bottom, #0181AB 0%, #5CC2DF 100%) !important;
    color: #fff !important;
    transform: none !important;
}

.kos-form-submit input[type="submit"]:active,
.kos-report-form input[type="submit"]:active,
.kos-report-modal input[type="submit"]:active {
    transform: none !important;
}

@media (max-width: 767px) {
    .kos-form-submit input[type="submit"],
    .kos-report-form input[type="submit"],
    .kos-report-modal input[type="submit"] {
        width: 100% !important;
        min-width: 0;
    }
}


/* =========================================================
   KOS RAPORTY 1.5.7 – COOKIEYES / reCAPTCHA + HONEYPOT
   ========================================================= */

/* Honeypot: poza ekranem, ale pozostaje zwykłym polem formularza dla botów. */
.kos-honeypot {
    position: absolute !important;
    left: -10000px !important;
    top: auto !important;
    width: 1px !important;
    height: 1px !important;
    overflow: hidden !important;
    opacity: 0 !important;
    pointer-events: none !important;
}

.kos-honeypot input {
    width: 1px !important;
    height: 1px !important;
    min-width: 0 !important;
    min-height: 0 !important;
    padding: 0 !important;
    border: 0 !important;
}

/* Komunikat, gdy CookieYes blokuje aktywną integrację reCAPTCHA. */
.kos-recaptcha-consent-notice {
    margin: 0 0 20px;
    padding: 16px 18px;
    border: 1px solid #cfe5ee;
    border-radius: 9px;
    background: #eef8fb;
    color: #444444;
    font-family: "Open Sans", Helvetica, Arial, Verdana, sans-serif;
    font-size: 14px;
    line-height: 1.6;
    text-align: left;
}

.kos-recaptcha-consent-notice[hidden] {
    display: none !important;
}

.kos-recaptcha-consent-notice strong,
.kos-recaptcha-consent-notice span {
    display: block;
}

.kos-recaptcha-consent-notice strong {
    margin: 0 0 5px;
    color: #444444;
    font-weight: 700;
}

.kos-recaptcha-consent-notice span {
    margin: 0 0 12px;
    color: #5b6472;
}

.kos-cookie-settings-button {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-height: 40px;
    margin: 0;
    padding: 8px 18px;
    border: 0 !important;
    border-radius: 999px !important;
    background: #444444 !important;
    color: #ffffff !important;
    font-family: "Open Sans", Helvetica, Arial, Verdana, sans-serif !important;
    font-size: 13px !important;
    font-weight: 600 !important;
    line-height: 1 !important;
    cursor: pointer;
    box-shadow: none !important;
    transform: none !important;
}

.kos-cookie-settings-button:hover,
.kos-cookie-settings-button:focus-visible {
    background: #2f2f2f !important;
    color: #ffffff !important;
    transform: none !important;
}

/* Gdy reCAPTCHA jest zablokowana, użytkownik dostaje jasny komunikat zamiast
   ogólnego błędu CF7 i nie może wysłać formularza do czasu zmiany zgód. */
.kos-report-form input[type="submit"][data-kos-recaptcha-blocked="1"],
.kos-report-modal input[type="submit"][data-kos-recaptcha-blocked="1"] {
    opacity: .5 !important;
    cursor: not-allowed !important;
    pointer-events: none !important;
}
