/* TCAL — static overrides */

/* Avoid horizontal scroll */
html, body { overflow-x: clip; }

/* Hide "go-top" arrow (leftover from WP theme) */
.go-top, .gototop, .go-to-top, .scroll-top, #go-top {
    display: none !important;
}

/* === WA Form (replaces FluentForm) === */
.wa-form-wrap {
    max-width: 560px;
    margin: 24px auto;
    padding: 24px;
    background: #fff;
    border-radius: 14px;
    box-shadow: 0 4px 20px rgba(15, 23, 36, 0.08);
}
.wa-form {
    display: flex;
    flex-direction: column;
    gap: 16px;
}
.wa-form .wa-field {
    display: flex;
    flex-direction: column;
    gap: 6px;
}
.wa-form .wa-label {
    font-size: 14px;
    font-weight: 600;
    color: #334155;
}
.wa-form .wa-required {
    color: #e11d48;
    font-weight: 700;
}
.wa-form input[type="text"],
.wa-form textarea {
    font-family: inherit;
    font-size: 16px;
    padding: 12px 14px;
    border: 1px solid #d1d5db;
    border-radius: 8px;
    background: #f9fafb;
    color: #0f172a;
    transition: border-color .15s, background .15s;
    width: 100%;
    box-sizing: border-box;
}
.wa-form input[type="text"]:focus,
.wa-form textarea:focus {
    outline: none;
    border-color: #25D366;
    background: #fff;
}
.wa-form textarea {
    resize: vertical;
    min-height: 110px;
}
.wa-submit {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    padding: 14px 22px;
    background: #25D366;
    color: #fff;
    border: 0;
    border-radius: 10px;
    font-size: 16px;
    font-weight: 700;
    cursor: pointer;
    transition: background .15s, transform .15s;
    width: 100%;
    box-sizing: border-box;
}
.wa-submit:hover {
    background: #1eaf54;
    transform: translateY(-1px);
}
.wa-submit:active {
    transform: translateY(0);
}
.wa-submit .wa-icon {
    width: 22px;
    height: 22px;
}

/* === Broken/placeholder CTA button fix === */
.ct-link-text.dentist-orange-button[href="http://"] {
    display: none;
}

/* === Mobile-first tweaks === */
@media (max-width: 768px) {
    html, body { margin: 0; padding: 0; }
    .ct-section { padding-left: 16px !important; padding-right: 16px !important; }
    .ct-new-columns { flex-direction: column !important; gap: 20px !important; }
    .ct-div-block, .dentist-service-column, .dentist-benefits-image { width: 100% !important; max-width: 100% !important; }
    h1, .ct-headline.dentist-heading-one { font-size: clamp(28px, 7vw, 40px) !important; line-height: 1.15 !important; }
    h2, .ct-headline.dentist-heading-two { font-size: clamp(22px, 5.5vw, 30px) !important; }
    h3, .ct-headline.dentist-heading-three { font-size: clamp(18px, 4.5vw, 22px) !important; }
    .wa-form-wrap { margin: 16px; padding: 18px; }

    /* 3 benefit tiles (Vele jaren ervaring / ... / ...) — ładniejsze na mobile */
    #div_block-234-24,
    #div_block-239-24,
    #div_block-237-24 {
        min-height: 0 !important;
        height: auto !important;
        max-height: none !important;
        padding: 24px 20px !important;
        border-radius: 12px !important;
        text-align: center !important;
        align-items: center !important;
    }
    #div_block-234-24 .dentist-benefits-image,
    #div_block-239-24 .dentist-benefits-image,
    #div_block-237-24 .dentist-benefits-image {
        width: 56px !important;
        height: auto !important;
        margin: 0 auto 12px !important;
    }
    #div_block-234-24 .ct-headline,
    #div_block-239-24 .ct-headline,
    #div_block-237-24 .ct-headline {
        font-size: 18px !important;
        margin: 0 0 10px !important;
        text-align: center !important;
    }
    #div_block-234-24 .ct-text-block,
    #div_block-239-24 .ct-text-block,
    #div_block-237-24 .ct-text-block {
        font-size: 14px !important;
        line-height: 1.5 !important;
        text-align: center !important;
    }
    /* Sekcja 231-24 — negatywny margin który nachodził na hero */
    #new_columns-480-24 {
        margin-top: 0 !important;
    }
    #section-231-24 > .ct-section-inner-wrap {
        padding: 24px 16px !important;
    }
}

/* === FAB phone === */
.kb-fab-phone {
    display: none;
}
@media (max-width: 768px) {
    .kb-fab-phone {
        display: inline-flex;
        align-items: center;
        justify-content: center;
        position: fixed;
        right: 16px;
        bottom: 20px;
        width: 58px;
        height: 58px;
        background: #25D366;
        color: #fff;
        border-radius: 50%;
        box-shadow: 0 6px 18px rgba(37, 211, 102, 0.45), 0 2px 6px rgba(0,0,0,0.15);
        z-index: 9998;
        text-decoration: none;
        animation: kb-fab-pulse 2.4s ease-in-out infinite;
    }
    .kb-fab-phone svg { width: 28px; height: 28px; fill: #fff; }
}
@keyframes kb-fab-pulse {
    0%, 100% { transform: scale(1); }
    50% { transform: scale(1.06); }
}

/* === Contact section — form + contact info side by side === */
#section-551-69 .wa-contact-row-wrap,
.wa-contact-row-wrap {
    display: flex !important;
    flex-direction: row !important;
    flex-wrap: wrap !important;
    gap: 32px !important;
    width: 100% !important;
    max-width: 1100px !important;
    margin: 24px auto !important;
    align-items: stretch !important;
    padding: 0 20px !important;
    box-sizing: border-box;
}
.wa-contact-row-wrap > .wa-form-wrap {
    flex: 1 1 380px !important;
    margin: 0 !important;
    max-width: none !important;
    min-width: 0;
    width: auto !important;
}
.wa-contact-info {
    flex: 1 1 340px !important;
    min-width: 0;
    background: rgba(255, 255, 255, 0.10);
    backdrop-filter: blur(8px);
    border: 1px solid rgba(255, 255, 255, 0.18);
    border-radius: 14px;
    padding: 28px;
    color: #fff;
    box-shadow: 0 4px 20px rgba(15, 23, 36, 0.15);
    box-sizing: border-box;
}
.wa-contact-heading {
    font-size: 22px;
    margin: 0 0 18px;
    color: #fff;
    letter-spacing: 0.02em;
}
.wa-contact-row {
    display: flex;
    gap: 14px;
    align-items: flex-start;
    padding: 10px 0;
    color: #fff;
    text-decoration: none;
    transition: opacity .15s;
    border-bottom: 1px solid rgba(255,255,255,0.08);
    text-align: left !important;
}
.wa-contact-row span,
.wa-contact-row strong,
.wa-contact-row small {
    text-align: left !important;
    display: block;
}
.wa-contact-row:hover { opacity: 0.8; }
.wa-contact-row:last-of-type { border-bottom: 0; }
.wa-contact-row svg {
    width: 22px;
    height: 22px;
    flex: 0 0 auto;
    margin-top: 2px;
}
.wa-contact-row span {
    font-size: 15px;
    line-height: 1.4;
}
.wa-contact-row small {
    opacity: 0.7;
    font-size: 13px;
}
.wa-contact-hours {
    margin-top: 18px;
    padding-top: 18px;
    border-top: 1px solid rgba(255,255,255,0.15);
}
.wa-contact-hours h4 {
    margin: 0 0 10px;
    font-size: 15px;
    text-transform: uppercase;
    letter-spacing: 0.06em;
    opacity: 0.85;
}
.wa-hours-row {
    display: flex;
    justify-content: space-between;
    padding: 4px 0;
    font-size: 14px;
}

/* === Footer fill — ciemniejsze tło + top separator oddzielają od sekcji kontakt === */
#section-18-4 {
    background: #083b5d !important;
    padding: 48px 20px 24px !important;
    color: #cbd5e1 !important;
    border-top: 1px solid rgba(255,255,255,0.08);
    box-shadow: inset 0 6px 12px -6px rgba(0,0,0,0.35);
    position: relative;
}
/* Akcentowy niebieski pasek między kontaktem a stopką */
#section-18-4::before {
    content: "";
    display: block;
    position: absolute;
    top: -1px;
    left: 0;
    right: 0;
    height: 3px;
    background: linear-gradient(90deg, transparent 0%, #00adef 20%, #00adef 80%, transparent 100%);
}
/* Dodaj margines nad stopką żeby oddychała */
#section-551-69 {
    padding-bottom: 48px !important;
}
#section-18-4 .ct-section-inner-wrap {
    max-width: 1200px !important;
    margin: 0 auto !important;
    padding: 0 !important;
}
.tcal-footer {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
    gap: 32px;
    margin-bottom: 32px;
}
.tcal-footer-col h4 {
    font-size: 14px;
    color: #fff;
    margin: 0 0 14px;
    text-transform: uppercase;
    letter-spacing: 0.08em;
}
.tcal-footer-col p,
.tcal-footer-col a {
    color: #cbd5e1;
    font-size: 14px;
    line-height: 1.6;
    text-decoration: none;
    display: block;
}
.tcal-footer-col a:hover { color: #fff; }
.tcal-footer-bottom {
    border-top: 1px solid rgba(255,255,255,0.1);
    padding-top: 18px;
    text-align: center;
    font-size: 13px;
    opacity: 0.7;
}

/* Hero: make text readable on top of bg image */
#section-4-24 {
    background-size: cover !important;
    background-position: center !important;
    background-attachment: scroll !important;
}
#section-4-24 .ct-section-inner-wrap {
    max-width: 1200px !important;
    margin: 0 auto !important;
}
#headline-534-24 {
    text-shadow: 0 2px 20px rgba(0,0,0,0.4);
}

/* Services / benefits columns — ensure they span full content width */
#section-231-24 .ct-section-inner-wrap,
#section-345-24 .ct-section-inner-wrap,
#section-551-69 .ct-section-inner-wrap {
    max-width: 1200px !important;
    margin: 0 auto !important;
}

@media (max-width: 768px) {
    .wa-contact-row-wrap { flex-direction: column; padding: 0 16px; }
    .wa-contact-info { padding: 20px; }
    .tcal-footer { grid-template-columns: 1fr; text-align: center; }
}

/* === Footer: hide old Oxygen footer content (logo img + nav) === */
#section-18-4 #div_block-65-4,
#section-18-4 .dentist-footer-logo,
#section-18-4 .oxy-nav-menu,
#section-18-4 > .ct-section-inner-wrap > *:not(.tcal-footer):not(.tcal-footer-bottom) {
    display: none !important;
}
#section-18-4 > .ct-section-inner-wrap {
    display: block !important;
    padding: 0 !important;
}
/* Force grid cols at PC (min 3-4 cols) */
.tcal-footer {
    display: grid !important;
    grid-template-columns: repeat(4, 1fr) !important;
    gap: 40px !important;
    margin-bottom: 32px !important;
}
@media (max-width: 1100px) {
    .tcal-footer {
        grid-template-columns: repeat(2, 1fr) !important;
    }
}
@media (max-width: 640px) {
    .tcal-footer {
        grid-template-columns: 1fr !important;
        text-align: center;
    }
}

/* === Contact stack: narrow sections — full width w kontakt-row-wrap === */
#section-551-69 > .ct-section-inner-wrap,
#section-551-69 .ct-section-inner-wrap {
    max-width: none !important;
    padding-left: 0 !important;
    padding-right: 0 !important;
}
#nestable_shortcode-557-69,
#nestable_shortcode-557-69 > * {
    width: 100% !important;
    max-width: none !important;
}

/* === Contact page — hide duplicate info tiles + map (redundant with wa-contact-info) === */
body.page-template-default #div_block-89-13,
#section-4-13 #div_block-89-13,
#_map-3-13,
.oxy-map {
    display: none !important;
}
/* Contact page hero H1 — centered */
#section-4-13 .ct-headline.dentist-heading-one,
#headline-61-4 {
    text-align: center !important;
    font-size: clamp(28px, 5vw, 44px) !important;
    margin: 0 0 24px !important;
}
/* Map iframe — styling */
#_map-3-13,
.oxy-map {
    width: 100% !important;
    max-width: 1100px !important;
    margin: 0 auto !important;
    border-radius: 14px !important;
    overflow: hidden !important;
    box-shadow: 0 6px 24px rgba(15, 23, 36, 0.15);
    min-height: 400px;
}
.oxy-map iframe {
    width: 100% !important;
    height: 400px !important;
    border: 0 !important;
    display: block;
}

/* Mobile: wa-contact + form full width, no side padding */
@media (max-width: 768px) {
    #section-551-69 .wa-contact-row-wrap,
    .wa-contact-row-wrap {
        padding: 0 12px !important;
        max-width: 100% !important;
        margin: 16px 0 !important;
        gap: 16px !important;
    }
    .wa-contact-info,
    .wa-contact-row-wrap > .wa-form-wrap {
        padding: 18px !important;
        flex: 1 1 100% !important;
    }
    /* Zlikwiduj Oxygen padding na sekcji kontakt (padding-right/left:10%) */
    #section-551-69 > .ct-section-inner-wrap,
    #section-551-69 .ct-section-inner-wrap {
        padding-left: 8px !important;
        padding-right: 8px !important;
    }
}

/* === AGRESYWNY reset mobile kontakt — strona statyczna, forsujemy pełną szerokość === */
@media (max-width: 768px) {
    /* Wszystkie zagnieżdżone div_blocki na stronie /contact/ — usuń padding/margin */
    #section-4-13 .ct-section-inner-wrap,
    #section-4-13 .ct-new-columns,
    #section-4-13 .ct-div-block,
    #section-4-13 .ct-nestable-shortcode,
    #div_block-88-13,
    #div_block-15-13,
    #div_block-79-13,
    #nestable_shortcode-107-70,
    #new_columns-87-13 {
        padding: 0 !important;
        margin: 0 !important;
        max-width: 100% !important;
        width: 100% !important;
    }
    /* Top section: padding top = wysokość sticky header + oddech, H1 nie nachodzi pod menu */
    #section-4-13 > .ct-section-inner-wrap {
        padding: 130px 12px 24px !important;
    }
    /* Box "Contact formulier" — ładny padding wewnątrz, pełna szerokość */
    #div_block-88-13 {
        padding: 20px 16px !important;
        border-radius: 12px !important;
    }
    /* Analogiczny agresywny reset dla pl/kontakt */
    [id^="section-"] .ct-section-inner-wrap,
    [id^="section-"] .ct-new-columns,
    [id^="section-"] .ct-div-block,
    [id^="section-"] .ct-nestable-shortcode {
        max-width: 100% !important;
    }
}
