/* Static-copy quality overrides, loaded after the original stylesheets.
   adapt.js injects its stylesheet later at runtime, so rules use "html body" + !important where needed.
   Icons are inline SVG redraws of the original 1x PNGs (same colours). */

/* "Späť" back link: crisp arrow instead of the 9x7 px arrow_red.png */
html body .goBack,
html body a.goBack {
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 10 8'%3E%3Cpath d='M4.2 1 1 4l3.2 3M1.3 4H9' fill='none' stroke='%23e33826' stroke-width='1.6' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E") !important;
    background-size: 10px 8px !important;
    background-position: 0 4px !important;
}
html body .goBack:hover,
html body a.goBack:hover {
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 10 8'%3E%3Cpath d='M4.2 1 1 4l3.2 3M1.3 4H9' fill='none' stroke='%23ce3123' stroke-width='1.6' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E") !important;
}

/* back to top button (button_back_to_top.png 50x50) */
html body #back-top a {
    background: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 50 50'%3E%3Ccircle cx='25' cy='25' r='24' fill='%23a9a9a9'/%3E%3Cpath d='m17 28.5 8-8 8 8' fill='none' stroke='%23fff' stroke-width='3' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E") 0 0 / 50px 50px no-repeat !important;
}
html body #back-top a:hover {
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 50 50'%3E%3Ccircle cx='25' cy='25' r='24' fill='%23a9a9a9'/%3E%3Cpath d='m17 28.5 8-8 8 8' fill='none' stroke='%23272525' stroke-width='3' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E") !important;
}

/* download links (icon_download.png 38x42) */
html body a.downloadLink {
    background: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 38 42'%3E%3Crect x='.5' y='.5' width='37' height='41' rx='4' fill='%23fff' stroke='%23e1e1e1'/%3E%3Cpath d='m13.5 15 5.5 5.5 5.5-5.5M13.5 21.5 19 27l5.5-5.5' fill='none' stroke='%238b8b8b' stroke-width='2.2' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E") 0 5px / 38px 42px no-repeat !important;
}
html body a.downloadLink:hover {
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 38 42'%3E%3Crect width='38' height='42' rx='4' fill='%23e33826'/%3E%3Cpath d='m13.5 15 5.5 5.5 5.5-5.5M13.5 21.5 19 27l5.5-5.5' fill='none' stroke='%23fff' stroke-width='2.2' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E") !important;
}

/* red CTA arrow in "Prečo TEMPEST?" box (circle_arrow_white.png 51x51) */
html body .redBox p.redArrow {
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 51 51'%3E%3Ccircle cx='25.5' cy='25.5' r='24.5' fill='%23c0392b' stroke='%23b72415' stroke-width='2'/%3E%3Cpath d='M15.5 25.5h19m-7-7.5 7.5 7.5-7.5 7.5' fill='none' stroke='%23fff' stroke-width='3' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E") !important;
    background-size: 51px 51px !important;
}
html body .redBox:hover p.redArrow {
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 51 51'%3E%3Ccircle cx='25.5' cy='25.5' r='25.5' fill='%23b72415'/%3E%3Cpath d='M15.5 25.5h19m-7-7.5 7.5 7.5-7.5 7.5' fill='none' stroke='%23fff' stroke-width='3' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E") !important;
}

/* home icon in the main menu (icon_home@2x.png squeezed to 14x15) */
html body a.home,
html body a.homeLink {
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 14 15'%3E%3Cpath d='M7 .8 0 7.3h2v7h3.6V10h2.8v4.3H12v-7h2z' fill='%234d4d4d'/%3E%3C/svg%3E") !important;
    background-size: 14px 15px !important;
}

/* "JUMP TO" list icon (icon_list.png 16x10) */
html body .jumpTo {
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 16 10'%3E%3Cpath d='M0 1h2.5M5 1h11M0 5h2.5M5 5h11M0 9h2.5M5 9h11' stroke='%238d8d8d' stroke-width='1.6'/%3E%3C/svg%3E") !important;
    background-size: 16px 10px !important;
}
html body .jumpTo:hover {
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 16 10'%3E%3Cpath d='M0 1h2.5M5 1h11M0 5h2.5M5 5h11M0 9h2.5M5 9h11' stroke='%23fff' stroke-width='1.6'/%3E%3C/svg%3E") !important;
}

/* content images never wider than their column (Foxconn, SNK, Výročná správa tile, …) */
html body .content img,
html body .contentBox img,
html body .whiteBox img {
    max-width: 100% !important;
    height: auto !important;
}
html body .error-img,
html body .error-img img { max-width: 100% !important; height: auto !important; }

/* long captions joined with &nbsp; must still wrap on small screens */
html body p.captionText { overflow-wrap: break-word; }

/* mobile: zoomable diagrams were positioned off-screen (left:-296px) — show them inline */
@media (max-width: 979px) {
    html body .zoomBox {
        position: static !important;
        left: auto !important;
        display: block !important;
        width: auto !important;
        margin: 0 0 20px 0;
    }
    html body .zoomBox p { float: none !important; width: auto !important; }
    html body .buttonZoom, html body .buttonZoomActive { display: none !important; }
}

/* mobile: the zoomable diagram itself lives in a hidden .fullWidthContent block opened only by the desktop zoom button */
@media (max-width: 979px) {
    html body div[id^="contentHide_"] {
        display: block !important; position: static !important; left: auto !important;
        width: auto !important; max-width: 100% !important; margin: 0 0 20px 0 !important; padding: 0 !important;
    }
    html body div[id^="contentHide_"] img { width: auto !important; max-width: 100% !important; height: auto !important; }
    html body .buttonCancel { display: none !important; }
    html body .fullWidthContent .zoomBox.open { display: none !important; }
    html body .error-center, html body .error-box { width: auto !important; max-width: 100% !important; }
    html body img.error-img { display: block; margin: 0 auto 20px auto !important; }
}

/* the removed Share link used to provide the bottom spacing of the left sidebar box */
html body .whiteBox.sideBar { padding-bottom: 30px; }

/* the CTA arrow is positioned for the desktop box only; the original mobile stylesheet shows no arrow */
html body .redBox p.redArrow { background-repeat: no-repeat !important; }
@media (max-width: 979px) {
    html body .redBox p.redArrow, html body .redBox:hover p.redArrow { background-image: none !important; }
}
html body .goBack, html body a.goBack, html body a.home, html body a.homeLink, html body .jumpTo { background-repeat: no-repeat !important; }

/* mobile: two-column download tables (Výročné správy, Press kit, …) stack into one column */
@media (max-width: 979px) {
    html body .content table:has(a.downloadLink),
    html body .content table:has(a.downloadLink) tbody,
    html body .content table:has(a.downloadLink) tr,
    html body .content table:has(a.downloadLink) td { display: block; width: auto !important; }
}

/* ---- mobile/tablet QA round (agent findings) ---- */

/* homepage "Výročná správa" tile has a fixed 180px height: keep the logo inside it */
html body .whiteBox a img[src*="VS19.svg"] {
    width: auto !important; height: 120px !important; max-width: 100% !important; margin-top: 10px !important;
}

/* stop mobile Chrome from "font boosting" paragraphs (lists stayed small, sizes looked mismatched) */
html { -webkit-text-size-adjust: 100%; text-size-adjust: 100%; }

/* "Plná verzia / Mobilná verzia" switch: centred, comfortable tap target on every page */
html body p.fullscreenView { text-align: center; clear: both; padding: 12px 0; }
html body p.fullscreenView a { display: inline-block; padding: 8px; }

/* photo gallery arrows: 44px tap targets */
html body .gallery-left-arrow,
html body .gallery-right-arrow {
    display: inline-block; width: 44px !important; height: 44px !important;
    background-position: center !important; vertical-align: middle;
}

html body .content p:empty { display: none; }

@media (max-width: 979px) {
    /* back-to-top was positioned for desktop (margin-left:986px) and never visible on phones/tablets */
    html body #back-top {
        margin-left: 0 !important; left: auto !important; right: 16px !important;
        top: auto !important; bottom: 16px !important; z-index: 50;
    }
    /* stacked CTA buttons (eOffice "Chcem vedieť viac" + "Licenčná zmluva") must not touch */
    html body .content a[style*="border-radius:6px"] { margin: 6px 0; }
    /* small tap targets: breadcrumb and "Späť" */
    html body .footerMenu a, html body a.goBack { display: inline-block; padding-top: 8px; padding-bottom: 8px; }
    html body a.goBack { background-position: 0 12px !important; }
    /* "Úvod" home icon in the mobile menu sits in line with its text */
    html body #menu-mobile a.homeLink, html body .mm-menu a.homeLink {
        background-position: 20px center !important; padding-left: 44px !important;
    }
}

/* article h1 had line-height 21–23px at 30px font: two-line titles overlapped (Raiffeisen) */
html body .content h1 { line-height: 1.25 !important; }

/* case-study index cards: clean cut with ellipsis instead of a half-visible line */
html body .classic p { height: auto !important; overflow: visible !important; }
html body .classic p a {
    display: -webkit-box; -webkit-box-orient: vertical; -webkit-line-clamp: 6; line-clamp: 6; overflow: hidden;
}

@media (max-width: 979px) {
    /* breadcrumb: current item does not wrap on its own line */
    html body .footerMenu a.active { white-space: nowrap; }
}
@media (max-width: 600px) {
    /* justified text leaves wide gaps in a narrow column */
    html body .content p { text-align: left !important; }
}
