/* edur-ui-v5-responsive — LOCAL DRAFT, append after the existing styles.
 * Evidence: R1.md, R1.json and R1_raw.json; no live verification performed.
 * Each numbered block is independently removable. No global typography reset.
 */

/* B01 — address breaking
 * a_midword; ul > li > span.address; measured: basgitary@1280x800, basgitary@320x640, cookies@1280x800, cookies@320x640, doprava-platby@1280x800, doprava-platby@320x640, gitary@1280x800, gitary@320x640, home@1280x800, home@320x640, korg-nts-4@1280x800, korg-nts-4@320x640, reloop-rmx-10-bt@1280x800, reloop-rmx-10-bt@320x640.
 * Overrides the measured word-break:break-all. Existing manual hyphens / normal overflow-wrap remain inherited; punctuation can still wrap.
 * Undo: remove this block.
 */
html body.template-13 #footer ul > li > span.address {
  word-break: normal;
}

/* B02 — readable paragraph measure
 * g_line_over_90; div.category-top > div.category-perex > p; measured: basgitary@1024x768, basgitary@1280x800, basgitary@1440x900, basgitary@768x1024, gitary@1024x768, gitary@1280x800, gitary@1440x900, gitary@768x1024.
 * g_line_over_90; div.category-content-wrapper > div.category__secondDescription > p; measured: gitary@1280x800, gitary@1440x900.
 * g_line_over_90; div.description-inner > div#edur-description-text > p; measured: korg-nts-4@1024x768, korg-nts-4@1280x800, korg-nts-4@1440x900, korg-nts-4@768x1024.
 * g_line_over_90; div.contentpaneopen > div.td_content_body > p.Standard; measured: doprava-platby@1024x768, doprava-platby@1280x800, doprava-platby@1440x900, doprava-platby@768x1024.
 * g_line_over_90; article.pageArticleDetail > div > p; measured: cookies@1024x768, cookies@1280x800, cookies@1440x900, cookies@768x1024, doprava-platby@1024x768, doprava-platby@1280x800, doprava-platby@1440x900, doprava-platby@768x1024.
 * g_line_over_90; div.info-banner-left > div > p; measured: home@768x1024.
 * wrap is the plain fallback; pretty is progressive enhancement. No forced minimum width on phones.
 * Undo: remove this block.
 */
html body.template-13 div.category-top > div.category-perex > p,
html body.template-13 div.category-content-wrapper > div.category__secondDescription > p,
html body.template-13 div.description-inner > div#edur-description-text > p,
html body.template-13 div.contentpaneopen > div.td_content_body > p.Standard,
html body.template-13 article.pageArticleDetail > div > p,
html body.template-13 div.info-banner-left > div > p {
  max-width: 72ch;
  text-wrap: wrap;
  text-wrap: pretty;
  hyphens: manual;
  overflow-wrap: normal;
}

/* B03 — measured heading orphans
 * e_orphan_last_word; div.sidebar-inner.sidebar-filters-wrapper > div.box.box-bg-variant > h3.pageElement__heading; measured: basgitary@768x1024, gitary@768x1024.
 * e_orphan_last_word; div.contentpaneopen.title > div.contentheading.content_item_no_1 > h2; measured: doprava-platby@320x640, doprava-platby@390x844.
 * e_orphan_last_word; div.category-content-wrapper > div.category__secondDescription > h3; measured: gitary@320x640.
 * e_orphan_last_word; div.description-inner > div#edur-description-text > h2; measured: korg-nts-4@320x640.
 * No font, line-height or heading spacing changes; balance may reduce a final single-word line.
 * Undo: remove this block.
 */
html body.template-13 div.sidebar-inner.sidebar-filters-wrapper > div.box.box-bg-variant > h3.pageElement__heading,
html body.template-13 div.contentpaneopen.title > div.contentheading.content_item_no_1 > h2,
html body.template-13 div.category-content-wrapper > div.category__secondDescription > h3,
html body.template-13 div.description-inner > div#edur-description-text > h2 {
  text-wrap: wrap;
  text-wrap: balance;
  hyphens: manual;
  overflow-wrap: normal;
}

/* B04 — measured action labels
 * e_orphan_last_word; div.p-detail-inner > div.p-data-wrapper > div.buttons-wrapper.social-buttons-wrapper; measured: korg-nts-4@1024x768, korg-nts-4@1280x800, korg-nts-4@320x640, korg-nts-4@390x844, reloop-rmx-10-bt@1024x768, reloop-rmx-10-bt@1280x800, reloop-rmx-10-bt@320x640, reloop-rmx-10-bt@390x844.
 * Only text inside existing action links; preserves CTA dimensions and overlay behaviour. Aggregate row orphan is not proof of an orphan inside a label.
 * Undo: remove this block.
 */
html body.template-13 div.p-detail-inner > div.p-data-wrapper > div.buttons-wrapper.social-buttons-wrapper .link-icon {
  text-wrap: wrap;
  text-wrap: balance;
  hyphens: manual;
  overflow-wrap: normal;
  min-width: 0;
}

/* Footer enhancements are conditional: unsupported browsers retain Bootstrap floats.
 * Undo: remove B05–B09 together to restore the original footer layout. */
@supports (display: grid) {
/* B05 — f_footer_uneven_heights; footer#footer .row.custom-footer;
 * all pages @768/1024/1280/1440; stacked continuation @320/390.
 * Stretch equalises direct column boxes within each row, not nested content.
 * Undo: remove this block. */
html body.template-13 footer#footer > div.container.footer-rows > div.row.custom-footer {
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  align-items: stretch;
  column-gap: 21px;
}
/* B06 — f_footer_uneven_heights; same selector/states as B05.
 * Width/float resets apply only in grid-capable browsers.
 * Undo: remove this block. */
html body.template-13 footer#footer > div.container.footer-rows > div.row.custom-footer > div {
  float: none;
  clear: none;
  width: auto;
  min-width: 0;
}
/* B07 — f_footer_uneven_heights; same selector/states as B05.
 * Remove blank Bootstrap clearfix boxes from grid placement only.
 * Undo: remove this block. */
html body.template-13 footer#footer > div.container.footer-rows > div.row.custom-footer::before,
html body.template-13 footer#footer > div.container.footer-rows > div.row.custom-footer::after {
  position: absolute;
}
@media (min-width: 768px) {
/* B08 — f_footer_uneven_heights; same selector as B05; all pages @768/1024.
 * Orchestrator amendment: two tracks throughout 768–1199px.
 * Undo: remove this block. */
html body.template-13 footer#footer > div.container.footer-rows > div.row.custom-footer {
  grid-template-columns: repeat(2, minmax(0, 1fr));
}
}
@media (min-width: 1200px) {
/* B09 — f_footer_uneven_heights; same selector as B05; all pages @1280/1440.
 * Orchestrator amendment: four tracks from 1200px.
 * Undo: remove this block. */
html body.template-13 footer#footer > div.container.footer-rows > div.row.custom-footer {
  grid-template-columns: repeat(4, minmax(0, 1fr));
}
}
}

@media (max-width: 768px) {

/* B10 — unclipped category tile containers
 * c_clipped; li.col-xs-6.col-sm-6 > a > span.text; measured: basgitary@320x640, basgitary@390x844, basgitary@768x1024, gitary@320x640, gitary@390x844, gitary@768x1024.
 * Only forced declaration: overrides style_c.css @media(max-width:768px) .subcategories li{height:160px !important}; container must grow with its label.
 * Undo: remove this block.
 */
html body.template-13.type-category .category-top > ul.subcategories.with-image > li.col-xs-6.col-sm-6 {
  height: auto !important;
}

/* B11 — category tile link shrinkability
 * c_clipped; li.col-xs-6.col-sm-6 > a > span.text; measured: basgitary@320x640, basgitary@390x844, basgitary@768x1024, gitary@320x640, gitary@390x844, gitary@768x1024.
 * Flex child of the measured tile; no image or link sizing change.
 * Undo: remove this block.
 */
html body.template-13.type-category .category-top > ul.subcategories.with-image > li.col-xs-6.col-sm-6 > a {
  min-width: 0;
}

/* B12 — category label wrapping
 * c_clipped; li.col-xs-6.col-sm-6 > a > span.text; measured: basgitary@320x640, basgitary@390x844, basgitary@768x1024, gitary@320x640, gitary@390x844, gitary@768x1024.
 * Overrides saved theme .subcategories li a .text two-line clamp / overflow:hidden / max-height:54px. Natural wrapping permits 2–3 lines and more if necessary; no ellipsis or cap.
 * Undo: remove this block.
 */
html body.template-13.type-category .category-top > ul.subcategories.with-image > li.col-xs-6.col-sm-6 > a > span.text {
  display: block;
  -webkit-line-clamp: unset;
  line-clamp: none;
  height: auto;
  max-height: none;
  overflow: visible;
  text-overflow: clip;
  max-width: 100%;
  white-space: normal;
  text-wrap: wrap;
  text-wrap: balance;
  hyphens: manual;
  overflow-wrap: normal;
  word-break: normal;
  min-width: 0;
}
}

@media (max-width: 390px) {

/* B13 — card name flex children
 * c_clipped; div.p-in > div.p-in-in > a.name; measured: home@320x640, home@390x844.
 * Narrow the measured text-bearing child without altering product, image, price or CTA dimensions.
 * Undo: remove this block.
 */
html body.template-13 div.p-in > div.p-in-in {
  min-width: 0;
}

/* B14 — card name wrapping
 * c_clipped; div.p-in > div.p-in-in > a.name; measured: home@320x640, home@390x844.
 * Targeted higher-specificity override of R1 measured two-line clamp (client height 45px). edur-ui.css already requests unclamping on .p .name, but R1 still measures a clamp; this exact chain takes precedence. Reserve three computed line heights (4.5em fallback); allow longer names to grow.
 * Undo: remove this block.
 */
html body.template-13 div.p-in > div.p-in-in > a.name {
  display: block;
  height: auto;
  min-height: 4.5em;
  min-height: 3lh;
  max-height: none;
  -webkit-line-clamp: unset;
  line-clamp: none;
  overflow: visible;
  text-overflow: clip;
  white-space: normal;
  text-wrap: wrap;
  text-wrap: balance;
  hyphens: manual;
  overflow-wrap: normal;
  word-break: normal;
  min-width: 0;
}
}

/* B15 — remaining measured body copy
 * h_prep_at_line_end; div.main-page-info-container > div.about-banner > p; measured: home@1280x800, home@390x844.
 * h_prep_at_line_end; div.custom-footer__newsletter.col-sm-6 > div.newsletter-header > p; measured: basgitary@1024x768, basgitary@1280x800, cookies@1024x768, cookies@1280x800, doprava-platby@1024x768, doprava-platby@1280x800, gitary@1024x768, gitary@1280x800, home@1024x768, home@1280x800, korg-nts-4@1024x768, korg-nts-4@1280x800, reloop-rmx-10-bt@1024x768, reloop-rmx-10-bt@1280x800.
 * h_prep_at_line_end; fieldset > div.form-group.js-validated-element-wrapper > p.label; measured: basgitary@1280x800, cookies@1280x800, doprava-platby@1280x800, gitary@1280x800, home@1280x800, korg-nts-4@1280x800, reloop-rmx-10-bt@1280x800.
 * Plain wrapping fallback; pretty improves paragraph endings but does not bind Slovak prepositions.
 * Undo: remove this block.
 */
html body.template-13 div.main-page-info-container > div.about-banner > p,
html body.template-13 div.custom-footer__newsletter.col-sm-6 > div.newsletter-header > p,
html body.template-13 fieldset > div.form-group.js-validated-element-wrapper > p.label {
  text-wrap: wrap;
  text-wrap: pretty;
  hyphens: manual;
  overflow-wrap: normal;
}

/* B16 — e_orphan_last_word / h_prep_at_line_end; h1–h3 in the audited
 * main content and footer; R1 heading states @320/390/768 plus orchestrator scope.
 * Undo: remove this block. */
html body.template-13 h1,
html body.template-13 h2,
html body.template-13 h3 {
  text-wrap: wrap;
  text-wrap: balance;
  hyphens: manual;
  overflow-wrap: normal;
  word-break: normal;
}
/* B17 — h_prep_at_line_end / g_line_over_90; body copy in audited
 * main/category/product/article/footer roots; states @320/390/768/1024/1280/1440.
 * Undo: remove this block. */
html body.template-13 :is(main, #content, .category-top, .category-content-wrapper,
  .p-detail-inner, .pageArticleDetail, .contentpaneopen, #footer) :is(p, li, dd) {
  text-wrap: wrap;
  text-wrap: pretty;
  hyphens: manual;
  overflow-wrap: normal;
  word-break: normal;
}
/* B18 — c_clipped; affected text-bearing flex/grid children, R1 @320/390/768.
 * Shrink containers without introducing arbitrary word breaks.
 * Undo: remove this block. */
html body.template-13 :is(.p-in, .p-in-in, .category-top, .category-content-wrapper,
  .description-inner, .newsletter-header, .subcategories.with-image) > * {
  min-width: 0;
}
@media (max-width: 390px) {
/* B19 — a_word_wider_than_box; li.menu-item-987/903 > a > b;
 * all pages @320/390, including active Basgitary. 13px at 320px, capped at 16px.
 * Clamp reduces only these labels; no mid-word breaking or navigation resizing.
 * Undo: remove this block. */
html body.template-13 li.menu-item-987 > a > b,
html body.template-13 li.menu-item-903 > a > b {
  font-size: 13px;
  font-size: clamp(13px, 4.0625vw, 16px);
  white-space: normal;
  word-break: normal;
  overflow-wrap: normal;
  hyphens: manual;
  min-width: 0;
}
}
/* B20 — e_orphan_last_word; div.p-data-wrapper .social-buttons-wrapper;
 * korg-nts-4/reloop-rmx-10-bt @320/390/1024/1280.
 * Wrap the ordinary action group; absolute sharing panel keeps its positioning.
 * Undo: remove this block. */
html body.template-13 div.p-data-wrapper div.buttons-wrapper.social-buttons-wrapper,
html body.template-13 div.p-data-wrapper div.buttons-wrapper.social-buttons-wrapper > .link-icons {
  flex-wrap: wrap;
  min-width: 0;
}
/* B21 — e_orphan_last_word; same action group/states as B20.
 * Keep each complete label (including Opýtať sa) together as groups wrap.
 * Undo: remove this block. */
html body.template-13 div.p-data-wrapper div.buttons-wrapper.social-buttons-wrapper > .link-icons > a.link-icon,
html body.template-13 div.p-data-wrapper div.buttons-wrapper.social-buttons-wrapper > .link-icons > a.link-icon > span {
  white-space: nowrap;
  text-wrap: nowrap;
  word-break: normal;
  overflow-wrap: normal;
  hyphens: manual;
}
/* B22 — f_footer_uneven_heights; newsletter h3.pageElement__heading.topic
 * versus top-level banner headings; all pages @768/1024/1280/1440.
 * Match saved theme's 18px/1.1 heading metrics and remove unequal top margins.
 * Contact heading follows a logo and is intentionally outside this top-heading row.
 * Undo: remove this block. */
html body.template-13 footer#footer .row.custom-footer .newsletter-header > h3.pageElement__heading.topic,
html body.template-13 footer#footer .row.custom-footer .banner-wrapper > span > h4 {
  margin-top: 0;
  font-size: 18px;
  line-height: 1.1;
}
/* B23 — a_midword; footer span.address; all pages @320/1280.
 * Existing address is a single text node; future semantic line spans only.
 * See CSS_NOTES.md for the required markup; no whole-address nowrap.
 * Undo: remove this block. */
html body.template-13 footer#footer span.address > .edur-address-line {
  display: block;
}
/* B24 — a_midword; same address/states as B23; optional street-line wrapper
 * protects punctuation in M.R.Štefánika 2288/17 after the documented markup change.
 * Undo: remove this block. */
html body.template-13 footer#footer span.address > .edur-address-street {
  white-space: nowrap;
}
