/* Podstrony /cennik (templates/cennik.html) i /cennik-domen (templates/cennik-domen.html). Wspólne elementy podstron są w subpage.css. */

/* pigułki-skróty do sekcji w nagłówku (jak tematy pod wyszukiwarką w /pomoc) */
.h24-prices__jump {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    margin: 24px 0 0;
    padding: 0;
    list-style: none;
}

/* klikalne pigułki jak tematy pod wyszukiwarką w /pomoc (WordPress: .h24-hub-chip) */
.home .h24-prices__jump a {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 7px 15px;
    border: 1px solid #dcd8fa;
    border-radius: 999px;
    background: #ecebfc;
    color: #5146c9;
    font-size: 14px;
    line-height: 1.2;
    text-decoration: none;
    transition: background-color .25s ease, border-color .25s ease, color .25s ease;
}

.home .h24-prices__jump a i {
    color: inherit;
}

.home .h24-prices__jump a:hover,
.home .h24-prices__jump a:focus-visible {
    border-color: var(--h24-brand);
    background: var(--h24-brand);
    color: #fff;
}

/* pakiety hostingu zaraz pod nagłówkiem: odstęp jak sekcja „W standardzie” na /domeny (40 px);
   !important, bo stary mobile.css daje #priceList padding-top: 120px */
.home.h24-prices #priceList {
    padding-top: 40px !important;
}

/* ---------- domeny: tabela ---------- */

.h24-prices__table {
    max-width: 900px;
    margin: 0 auto;
}

/* promocja w tabeli domen i kartach certyfikatów: stara cena przekreślona, nowa obok (stary styles.css: .priceDiscount ukryte, .discountDomain pokazuje);
   bez kart pakietów hostingu, które mają własny wzór z home.css jak na /hosting */
.h24-prices__table .discountDomain .domainPriceNetto {
    display: none;
}

.h24-prices__table .priceDiscount,
.h24-prices__cert .priceDiscount {
    float: none;
    margin: 0;
    font-weight: 400;
}

.h24-prices__table .priceDiscount .oldPrice,
.h24-prices__cert .priceDiscount .oldPrice {
    margin-right: 6px;
    color: var(--h24-text);
    text-decoration: line-through;
}

.h24-prices__table .priceDiscount span:nth-child(2),
.h24-prices__cert .priceDiscount span:nth-child(2) {
    color: var(--h24-heading) !important;
    font-weight: 700;
}

/* rabat jako pigułka obok ceny (stary styles.css pozycjonuje go w rogu) */
.h24-prices__table .priceDiscount span:nth-child(3),
.h24-prices__cert .priceDiscount span:nth-child(3) {
    position: static;
    display: inline-block;
    vertical-align: middle;
    margin-left: 6px;
    padding: 1px 7px;
    border-radius: 999px;
    background: var(--h24-pink);
    color: #fff;
    font-size: 11px;
    font-weight: 700;
}

/* uwagi o VAT: przełącznik netto/brutto podmienia .nettoInfo i .grossInfo (main.js: changePricesToGross) */
.h24-prices__notes {
    max-width: 900px;
    margin: 16px auto 0;
    font-size: 14px;
}

/* pod kartami SSL uwaga na całą szerokość siatki */
.h24-prices__ssl + .h24-prices__notes {
    max-width: none;
}

.h24-prices .grossInfo {
    display: none;
}

.h24-prices__actions {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 14px;
    margin-top: 28px;
}

/* ---------- certyfikaty SSL: małe karty ---------- */

.h24-prices__ssl {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 24px;
}

.h24-prices__cert--0 { --cert-color: var(--h24-turquoise); --cert-bg: var(--h24-tag-bg); }
.h24-prices__cert--1 { --cert-color: var(--h24-brand); --cert-bg: var(--h24-active-bg); }
.h24-prices__cert--2 { --cert-color: var(--h24-pink); --cert-bg: var(--h24-pink-bg); }
.h24-prices__cert--3 { --cert-color: var(--h24-blue); --cert-bg: var(--h24-blue-bg); }

.h24-prices__cert {
    padding: 24px;
    text-align: center;
}

.h24-prices__cert-icon {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 52px;
    height: 52px;
    border-radius: 14px;
    background: var(--cert-bg);
    color: var(--cert-color);
    font-size: 24px;
}

.home .h24-prices__cert h3 {
    margin-top: 14px;
    font-size: 19px;
    transition: color var(--h24-transition);
}

.h24-prices__cert:hover h3 {
    color: var(--cert-color);
}

/* linia podziału pod opisem (nie nad ceną), żeby rabat nad ceną nie nachodził na linię */
.home .h24-prices__cert-desc {
    margin-top: 4px;
    padding-bottom: 16px;
    border-bottom: 1px solid var(--h24-divider);
    font-size: 14px;
}

/* wzór ceny i promocji wspólny z hostingiem i /certyfikaty-ssl (home.css: .h24-price__unit) */
.h24-prices__cert .pricingPrice,
.h24-prices__cert .priceDiscount {
    margin-top: 22px;
    white-space: nowrap;
}

/* promocja: stara cena, nowa cena, rabat i okres mogą przejść do drugiej linii (dłuższe teksty EN/DE/UK na wąskiej karcie),
   ale każdy element zostaje w całości */
.h24-prices__cert .priceDiscount {
    white-space: normal;
}

.h24-prices__cert .priceDiscount > span {
    white-space: nowrap;
}

.h24-prices__cert .pricingPrice > span:first-child,
.h24-prices__cert .priceDiscount span:nth-child(2) {
    color: var(--cert-color) !important;
    font-size: 24px;
    font-weight: 700;
}

.h24-prices__cert .priceDiscount .oldPrice {
    margin-right: 10px;
    font-size: 15px;
}

.h24-prices__cert .priceDiscount span:nth-child(3) {
    position: absolute;
    top: -14px;
    right: -14px;
    margin: 0;
    padding: 3px 7px;
    border-radius: 999px;
    background: var(--cert-color);
    color: #fff !important;
    width: auto;
    height: auto !important; /* stary styles.css: .priceDiscount span:nth-child(3) z !important */
    font-size: 11px;
    font-weight: 700;
    line-height: 1.3 !important;
}

/* promocja: zamiast ceny regularnej cena po rabacie */
.h24-prices__cert .priceDiscount {
    display: none;
}

.h24-prices__cert.discountPricingService .pricingPrice {
    display: none;
}

.h24-prices__cert.discountPricingService .priceDiscount {
    position: relative;
    /* elementy w jednej linii; gdy brakuje miejsca (dłuższe teksty EN/DE/UK), stara cena przechodzi nad nową,
       a nowa cena z okresem zostają razem: row-reverse + wrap-reverse i kolejność (order) poniżej */
    display: inline-flex;
    flex-direction: row-reverse;
    flex-wrap: wrap-reverse;
    justify-content: center;
    align-items: baseline;
}

.h24-prices__cert.discountPricingService .priceDiscount .h24-price__unit { order: 1; }
.h24-prices__cert.discountPricingService .priceDiscount span:nth-child(2) { order: 2; }
.h24-prices__cert.discountPricingService .priceDiscount .oldPrice { order: 3; }

.h24-prices__cert.discountPricingService .priceDiscount {
}

@media (max-width: 1240px) {
    .h24-prices__ssl { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}

@media (max-width: 640px) {
    .h24-prices__ssl { grid-template-columns: minmax(0, 1fr); }
    .h24-prices__actions .home-btn { width: 100%; }
    /* cztery kolumny cen mieszczą się bez przewijania */
    .h24-prices__table th,
    .h24-prices__table td { padding: 10px 6px; font-size: 13px; white-space: normal; }
    /* długie rozszerzenia (np. .nieruchomosci.pl) łamią się zamiast rozpychać tabelę */
    .h24-prices__table td:first-child { word-break: break-all; }
}

/* ---------- /cennik-domen: pasek z wyszukiwarką, zakładki grup, karty grup ---------- */

.h24-dp {
    --h24-dp-top: 75px; /* wysokość menu (top.css: .topBar) */
}

.h24-dp__list {
    padding: 10px 0 60px;
}

.h24-dp__sentinel {
    display: block;
    height: 1px;
}

/* pasek przyklejony pod menu; tło i cień dopiero po przyklejeniu (.h24-dp__bar--stuck, IntersectionObserver w szablonie) */
.h24-dp__bar {
    position: sticky;
    top: var(--h24-dp-top);
    z-index: 5;
    display: flex;
    align-items: center;
    gap: 24px;
    margin: 0 -16px;
    padding: 12px 16px;
    border-radius: 0 0 var(--h24-radius) var(--h24-radius);
    transition: background var(--h24-transition), box-shadow var(--h24-transition);
}

.h24-dp__bar--stuck {
    background: rgba(255, 255, 255, .94);
    box-shadow: var(--h24-shadow-hover);
    -webkit-backdrop-filter: blur(8px);
    backdrop-filter: blur(8px);
}

.home .h24-dp__gross {
    flex: none;
    margin: 0;
    padding-right: 24px;
    border-right: 1px solid var(--h24-divider);
}

.h24-dp__bar .home-search {
    flex: 1;
    max-width: none;
    margin: 0;
}

.h24-dp__bar--stuck .home-search {
    box-shadow: none;
}

.h24-dp__bar--stuck .home-search:focus-within {
    box-shadow: 0 0 0 3px rgba(101, 86, 231, .18);
}

/* zakładki grup: jeden rząd, na telefonie przewijany w poziomie wewnątrz paska */
/* pasek przewija się w poziomie (overflow-x), co przycina też cień aktywnego przycisku
   (5px 5px 5px: 10 px w prawo i w dół); miejsce na cień w paddingu listy, odjęte w marginesach */
.h24-dp__tabs {
    margin: 16px -12px 18px 0;
    overflow-x: auto;
    scrollbar-width: none;
}

.h24-dp__tabs::-webkit-scrollbar {
    display: none;
}

.h24-dp__tabs ul {
    display: grid;
    grid-template-columns: repeat(5, minmax(max-content, 1fr));
    gap: 12px;
    margin: 0;
    padding: 4px 12px 14px 0;
    list-style: none;
}

.home .h24-dp__tabs button {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    width: 100%;
    height: 48px;
    padding: 0 20px;
    border: 1px solid var(--h24-search-border);
    border-radius: 999px !important;
    background: var(--h24-card-bg);
    box-shadow: none;
    color: var(--h24-heading);
    font-family: inherit;
    font-size: 15px;
    font-weight: 400 !important;
    white-space: nowrap;
    cursor: pointer;
    transition: background var(--h24-transition), border-color var(--h24-transition), color var(--h24-transition), box-shadow var(--h24-transition);
}

.home .h24-dp__tabs button i {
    color: var(--h24-brand);
    font-size: 16px;
    transition: color var(--h24-transition);
}

.home .h24-dp__tabs button:hover {
    border-color: var(--h24-hover-bg);
    background: var(--h24-hover-bg);
    color: var(--h24-brand);
}

.home .h24-dp__tabs button[aria-pressed="true"] {
    border-color: var(--h24-brand);
    background: var(--h24-brand);
    box-shadow: var(--h24-shadow-button);
    color: #fff;
    font-weight: 700 !important;
}

.home .h24-dp__tabs button[aria-pressed="true"] i {
    color: #fff;
}

/* ---------- karta grupy ---------- */

.h24-dp__group + .h24-dp__group {
    margin-top: 24px;
}

.home .h24-dp__card {
    padding: 24px 28px 20px;
}

/* karta nie unosi się po najechaniu: to długa tabela, nie link */
.home .h24-dp__card:hover {
    transform: none;
    box-shadow: var(--h24-shadow);
}

.h24-dp__head {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 6px 14px;
    margin-bottom: 18px;
}

.home .h24-dp__icon {
    width: 52px;
    height: 52px;
    border-radius: 14px;
    font-size: 22px;
}

.home .h24-dp__head h2 {
    margin: 0;
    font-size: 22px;
}

.h24-dp__count {
    padding: 4px 12px;
    border-radius: 999px;
    background: var(--h24-active-bg);
    color: var(--h24-brand);
    font-size: 13px;
    font-weight: 700;
}

.home .h24-dp__head p {
    margin: 0 0 0 auto;
    font-size: 14px;
    text-align: right;
}

/* tabela: nagłówek na lawendowym tle z zaokrągleniem, ceny wyśrodkowane */
.h24-dp__table {
    width: 100%;
    border-collapse: separate;
    border-spacing: 0;
    font-size: 15px;
}

/* nagłówek jak w tabeli domen na /cennik (.home-domain-table), zaokrąglony tylko u góry */
.h24-dp__table thead th {
    padding: 11px 16px;
    background: var(--h24-lavender-from);
    color: var(--h24-heading);
    font-size: 14px;
    font-weight: 700;
}

.h24-dp__table thead th:first-child { border-radius: 10px 0 0 0; }
.h24-dp__table thead th:last-child { border-radius: 0 10px 0 0; }

.h24-dp__table th,
.h24-dp__table td {
    width: 25%;
    text-align: center;
}

.h24-dp__table th:first-child {
    text-align: left;
}

.h24-dp__table tbody th,
.h24-dp__table tbody td {
    padding: 8px 16px;
    border-bottom: 1px solid var(--h24-divider);
    color: var(--h24-text);
    transition: background var(--h24-transition);
}

.h24-dp__table tbody th {
    color: var(--h24-heading);
    font-weight: 700;
}

.h24-dp__table tbody tr:last-child > *,
.h24-dp__table tbody tr.h24-dp__row--last > * {
    border-bottom: 0;
}

/* wiersze pasujące do wyszukiwania: turkusowe tło jak etykieta kategorii */
.h24-dp__table tbody tr.h24-dp__row--match > * {
    background: var(--h24-tag-bg);
}

.h24-dp__table tbody tr.h24-dp__row--match th {
    color: var(--h24-tag-text);
}

.h24-dp__row--extra,
.h24-dp__table tbody tr.h24-dp__row--hidden {
    display: none;
}

.h24-dp__group--expanded .h24-dp__row--extra:not(.h24-dp__row--hidden) {
    display: table-row;
}

.h24-dp__group--expanded .h24-dp__more {
    display: none;
}

/* zwijanie wraca, gdy grupa jest otwarta przyciskiem (wtedy przycisk zostaje, z napisem „Zwiń listę”) */
.h24-dp__group--expanded .h24-dp__more:has(button[aria-expanded="true"]) {
    display: block;
}

/* linię nad przyciskiem daje dolna krawędź ostatniego widocznego wiersza */
.h24-dp__more {
    margin-top: 12px;
    text-align: center;
}

.home .h24-dp__more button {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    padding: 8px 16px;
    border: 0;
    border-radius: 10px !important;
    background: none;
    box-shadow: none;
    color: var(--h24-brand);
    font-family: inherit;
    font-size: 15px;
    font-weight: 700 !important;
    cursor: pointer;
    transition: background var(--h24-transition);
}

.home .h24-dp__more button:hover {
    background: var(--h24-hover-bg);
}

.h24-dp__more i {
    transition: transform var(--h24-transition);
}

.h24-dp__more button[aria-expanded="true"] i {
    transform: rotate(180deg);
}

.h24-dp__empty {
    display: flex;
    align-items: center;
    gap: 16px;
    padding: 24px 28px;
}

.home .h24-dp__empty p {
    margin: 0;
}

.home .h24-dp__notes {
    max-width: none;
    text-align: right;
}

/* ---------- transfer ---------- */

.h24-dp__transfer {
    display: flex;
    align-items: center;
    gap: 20px 28px;
    margin-top: 40px;
    padding: 24px 28px;
}

.h24-dp__transfer-text {
    flex: 1;
    min-width: 0;
}

.home .h24-dp__transfer h2 {
    margin: 0 0 4px;
    font-size: 20px;
}

.home .h24-dp__transfer p {
    margin: 0;
    font-size: 14px;
}

.h24-dp__transfer-facts {
    display: flex;
    margin: 0;
    padding: 0;
    list-style: none;
}

.h24-dp__transfer-facts li {
    display: flex;
    align-items: center;
    gap: 10px;
    max-width: 150px;
    padding: 0 20px;
    color: var(--h24-heading);
    font-size: 14px;
    line-height: 1.4;
}

.h24-dp__transfer-facts li + li {
    border-left: 1px solid var(--h24-divider);
}

.h24-dp__transfer-facts i {
    flex: none;
    color: var(--h24-turquoise);
    font-size: 22px;
}

.home .h24-dp__transfer .home-btn {
    flex: none;
}

.home .h24-dp__transfer .home-btn i {
    margin: 0 0 0 10px;
    transition: transform var(--h24-transition);
}

.home .h24-dp__transfer .home-btn:hover i {
    transform: translateX(4px);
}

@media (max-width: 1400px) {
    .h24-dp__transfer { flex-wrap: wrap; }
    .h24-dp__transfer-text { flex-basis: calc(100% - 80px); }
    .h24-dp__transfer-facts { flex: 1; margin-left: 80px; } /* pod tekstem: ikona 52 px + odstęp 28 px */
    .h24-dp__transfer-facts li:first-child { padding-left: 0; }
}

@media (max-width: 900px) {
    .home .h24-dp__head p { flex-basis: 100%; margin: 6px 0 0; text-align: left; }
}

@media (max-width: 640px) {
    .h24-dp__bar { flex-direction: column; align-items: stretch; gap: 10px; margin: 0 -10px; padding: 10px; }
    .home .h24-dp__gross { justify-content: flex-start; padding: 0; border: 0; }
    .h24-dp__bar .home-search { height: 52px; }
    .h24-dp__bar .home-search .home-btn { height: 40px; padding: 0 16px; }
    .h24-dp__tabs { margin: 10px -12px 10px 0; }
    .h24-dp__tabs ul { display: flex; gap: 8px; }
    .home .h24-dp__tabs button { height: 42px; padding: 0 16px; font-size: 14px; }
    .home .h24-dp__card { padding: 18px 12px 12px; }
    .h24-dp__head { padding: 0 4px; }
    .home .h24-dp__icon { width: 44px; height: 44px; border-radius: 12px; font-size: 19px; }
    .home .h24-dp__head h2 { font-size: 19px; }
    .h24-dp__table { table-layout: fixed; font-size: 12px; }
    .h24-dp__table thead th { padding: 9px 2px; font-size: 11px; }
    .h24-dp__table thead th:first-child { padding-left: 6px; }
    .h24-dp__table tbody th,
    .h24-dp__table tbody td { padding: 8px 2px; }
    /* długie rozszerzenia (np. .nieruchomosci.pl) łamią się zamiast rozpychać tabelę */
    .h24-dp__table th:first-child { width: 31%; overflow-wrap: anywhere; }
    .h24-dp__table th:not(:first-child),
    .h24-dp__table td { width: 21%; }
    .h24-dp__table th:nth-child(3),
    .h24-dp__table td:nth-child(3) { width: 27%; }
    .h24-dp__transfer { padding: 20px; }
    .h24-dp__transfer-text { flex-basis: calc(100% - 72px); }
    .h24-dp__transfer-facts { flex-direction: column; gap: 10px; flex-basis: 100%; margin-left: 0; }
    .h24-dp__transfer-facts li { max-width: none; padding: 0; }
    .h24-dp__transfer-facts li + li { border: 0; }
    .home .h24-dp__transfer .home-btn { flex: 1 1 100%; box-sizing: border-box; justify-content: center; }
}
