/* Mobile presentation is isolated from the established desktop composition. */
.mobile-only { display: none; }
.storefront [hidden] { display: none !important; }
@media (max-width: 999px) {
    html, body { height: auto; min-height: 100%; }
    body.storefront { color: #ecf4f1; font: 16px/1.65 Arial, Helvetica, sans-serif; background: #303737; }
    .site-page { display: block; }
    .site-viewport { display: block; padding: 0; }
    .storefront *, .storefront *::before, .storefront *::after { box-sizing: border-box; }
    .mobile-only { display: block; }
    .desktop-only, .desktop-product, .desktop-card-details { display: none !important; }
    .storefront a { text-underline-offset: 4px; }
    .storefront :is(a, button, summary, input, textarea):focus-visible { outline: 2px solid #73e0ce; outline-offset: 4px; }
    .storefront img { max-width: 100%; height: auto; }
    .storefront h1, .storefront h2 { color: #f4f5f0; font-family: Georgia, 'Times New Roman', serif; font-weight: 400; line-height: 1.2; }
    .storefront h1 { font-size: clamp(30px, 7.5vw, 42px); margin: 0 0 16px; }
    .storefront h2 { font-size: 26px; margin: 0 0 12px; }
    .storefront p { margin: 0 0 18px; }
    .storefront .eyebrow { color: #a3d3c9; font-size: 11px; letter-spacing: .16em; margin: 0 0 12px; }
    .mobile-header { position: relative; padding: 22px 20px 0; max-width: 680px; margin: auto; border-bottom: 1px solid #52605e; }
    .mobile-brand { display: block; width: fit-content; color: #f2f4ee !important; text-decoration: none !important; }
    .mobile-brand > span { font: italic 32px/1.2 Georgia, serif; }
    .mobile-brand small { display: block; font-size: 11px; letter-spacing: .09em; margin-top: 7px; color: #b6c8c4; }
    .language-switch { position: absolute; top: 24px; right: 14px; display: grid; place-items: center; width: 44px; height: 44px; font-size: 13px; border: 1px solid #657a74; border-radius: 50%; }
    .mobile-main-nav { display: flex; justify-content: space-between; align-items: center; gap: 8px; margin-top: 18px; }
    .mobile-main-nav > a, .mobile-menu > summary { display: block; padding: 12px 4px; min-height: 48px; font-size: 14px; cursor: pointer; white-space: nowrap; }
    .mobile-main-nav > a[aria-current] { border-bottom: 2px solid #86dacb; color: #fff; }
    .mobile-menu summary::after { content: ' +'; color: #a3d3c9; }
    .mobile-menu[open] summary::after { content: ' −'; }
    .mobile-menu > nav { position: absolute; left: 12px; right: 12px; z-index: 10; background: #3b4845; box-shadow: 0 16px 30px #0006; border: 1px solid #6c8580; padding: 12px 20px; border-radius: 4px; }
    .mobile-menu nav a { display: block; padding: 12px 0; min-height: 48px; border-bottom: 1px solid #657a7455; }
    /* Unwrap the legacy layout tables; the document has one natural scroll. */
    .storefront > table, .storefront > table > tbody, .storefront > table > tbody > tr, .storefront > table > tbody > tr > td,
    .site-shell, .site-shell table, .site-shell tbody, .site-shell tr, .site-shell td {
        display: block; width: 100% !important; height: auto !important; min-height: 0; border-spacing: 0;
    }
    .site-shell { max-width: 680px; background: none; zoom: 1; }
    .site-shell td { font-size: 16px; color: #ecf4f1; }
    .site-navigation, .site-middle > tbody > tr > td:not(:nth-child(4)) { display: none !important; }
    .site-middle > tbody > tr > td:nth-child(4) { background: transparent; box-shadow: none; border: 0; text-align: left; }
    .site-shell .scroll-panel { width: 100% !important; height: auto !important; max-height: none; overflow: visible !important; padding: 24px 20px; }
    .site-middle :is(table, td, span, div)[style*='font-size'] { font-size: inherit !important; }
    body:not([data-view='gallery']) .site-middle a { font-size: inherit; }
    .site-middle :is(td.width-5px, td.width-10px, td.width-14px, td.width-20px, td.width-25px, td.width-30px, td.contact-spacer) { display: none !important; }
    .site-middle .ramka, .site-middle .ramka_gal { border: 0; }
    .site-middle table :is(td, th) { text-align: left; }
    .site-middle .scroll-panel td { overflow-wrap: anywhere; }
    .site-middle .scroll-panel img { object-fit: contain; }
    .site-shell > tbody > tr > td > table:last-child:not(.site-middle) { margin: 24px 0 0; padding: 24px 20px; border-top: 1px solid #52605e; }
    .site-shell > tbody > tr > td > table:last-child:not(.site-middle) td:not(:nth-child(3)) { display: none; }
    .site-shell > tbody > tr > td > table:last-child:not(.site-middle) a { display: inline-block; padding: 8px 0; font-size: 14px; }
    .site-shell .fb-like { display: none; }
    .storefront .mobile-button { display: flex; align-items: center; justify-content: center; gap: 16px; width: 100%; min-height: 52px; border: 1px solid #a9d4c9; border-radius: 3px; padding: 12px 16px; background: #c4e8df; color: #183b32; font: 600 15px/1.45 Arial, sans-serif; text-decoration: none; text-align: center; }
    .mobile-button:hover { background: #dcf4ec; }
    .mobile-text-link { display: inline-block; min-height: 44px; padding: 10px 0; font-size: 14px; }
    .mobile-home { max-width: 680px; margin: auto; padding: 32px 20px; text-align: left; }
    .mobile-home > p:not(.eyebrow) { color: #c1cfca; }
    .home-feature { display: block; margin-top: 28px; }
    .home-feature img { display: block; width: 100%; }
    .home-feature > span { display: flex; justify-content: space-between; padding: 12px 0; font-family: Georgia, serif; font-size: 23px; }
    .site-shell .gallery-panel { padding: 0; }
    .gallery-intro { padding: 28px 20px 20px; }
    .gallery-intro > p:not(.eyebrow) { color: #c1cfca; font-size: 14px; line-height: 1.6; }
    .gallery-categories { display: flex; gap: 8px; overflow-x: auto; padding: 4px 0 8px; margin-bottom: 10px; scrollbar-width: none; }
    .gallery-categories::-webkit-scrollbar { display: none; }
    .gallery-categories a { flex: 0 0 auto; padding: 10px 14px; border: 1px solid #627872; border-radius: 3px; min-height: 44px; font-size: 13px !important; }
    .gallery-categories a[aria-current] { background: #526e63; color: #fff; border-color: #b8dbcb; }
    .gallery-filters { display: flex; gap: 20px; border-bottom: 1px solid #52605e; }
    .gallery-filters a { min-height: 44px; padding: 8px 0 10px; font-size: 14px !important; color: #bfcfca; }
    .gallery-filters a[aria-current] { color: #e7fff2; border-bottom: 2px solid #9dd3bd; }
    .gallery-grid { display: block; height: auto; min-height: 0; }
    .gallery-grid .galeria_miniatury { margin: 0 0 32px; font-size: 16px; text-align: left; background: #37413e; }
    .gallery-grid .galeria_miniatury > a { display: block; }
    .gallery-grid img { display: block; width: 100%; height: auto; object-fit: contain; background: #3c3c3c; }
    .mobile-card-details { padding: 20px; }
    .storefront .availability { display: inline-block; color: #b3dcca; font: 12px/1.5 Arial, sans-serif; letter-spacing: .04em; margin-bottom: 8px; }
    .mobile-card-details h2 { margin-bottom: 8px; font-size: 28px; }
    .mobile-card-details h2 a { color: #f4f5f0; }
    .storefront .mobile-price { font-size: 19px; color: #f0f3ed; line-height: 1.6; }
    .mobile-price del { font-size: 14px; color: #bdc9c1; }
    .mobile-price:empty { display: none; }
    .mobile-card-link { display: flex; justify-content: space-between; align-items: center; min-height: 48px; padding: 12px 0 0; border-top: 1px solid #5b6a61; font-size: 14px !important; }
    .gallery-pagination { display: none; }
    .gallery-load { padding: 0 20px 20px; text-align: center; }
    .gallery-status { color: #c1cfca; font-size: 14px; }
    .mobile-back-top { position: fixed; right: 16px; bottom: 18px; bottom: max(18px, env(safe-area-inset-bottom)); z-index: 4; padding: 10px 16px; min-height: 44px; border: 1px solid #8eac9e; border-radius: 24px; background: #293731; box-shadow: 0 3px 16px #0004; font-size: 13px; }
    .gallery-more[aria-disabled='true'] { opacity: .65; }
    .mobile-product { padding: 12px 0 100px; }
    .mobile-product > .gallery-return { margin: 0 20px 16px; }
    .product-heading { padding: 0 20px 6px; }
    .product-heading h1 { margin-bottom: 10px; }
    .mobile-product figure { margin: 0 0 24px; }
    .mobile-product figure img { display: block; width: 100%; height: auto; }
    .mobile-product figcaption { padding: 8px 20px 0; font-size: 12px; color: #bdcbc5; text-align: right; }
    .product-purchase, .product-description { padding: 0 20px 28px; }
    .product-purchase > p { color: #c1cfca; font-size: 13px; margin: 12px 0; }
    .purchase-info { display: flex; flex-wrap: wrap; gap: 6px 18px; }
    .purchase-info a { min-height: 44px; padding: 10px 0; font-size: 13px !important; text-decoration: underline; }
    .product-description { font-size: 16px; color: #e0e8e1; overflow-wrap: anywhere; }
    .product-photographs > h2 { padding: 0 20px; margin-bottom: 22px; }
    .mobile-purchase-bar { position: fixed; bottom: 0; left: 0; right: 0; z-index: 5; display: flex; justify-content: space-between; align-items: center; gap: 12px; padding: 12px 16px; padding-bottom: max(12px, env(safe-area-inset-bottom)); border-top: 1px solid #668071; background: #293731; box-shadow: 0 -8px 24px #0002; }
    .mobile-purchase-bar > span { min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; font-size: 14px; }
    .mobile-purchase-bar small { display: block; color: #b3dcca; font-size: 11px; }
    .mobile-purchase-bar .mobile-button { width: auto; min-height: 48px; flex-shrink: 0; font-size: 13px; }
    body:has(.mobile-product) .site-shell { padding-bottom: 72px; }
    .storefront :is(input.kontakt, textarea.kontakt, select.kontakt) { width: 100%; max-width: 100%; margin: 4px 0 16px; padding: 12px; min-height: 48px; font: 16px/1.5 Arial, sans-serif; border-radius: 3px; background: #f1f4ed; color: #24382e; border-color: #93b6a5; }
    .storefront textarea.kontakt { min-height: 180px; }
    .storefront input[type='submit'] { background: #c4e8df; font-weight: bold; }
    .storefront input[name='ver1'], .storefront input[type='reset'] { display: none; }
    .kontakttab > tbody > tr > td:nth-child(2) { margin-bottom: 24px; }
    .kontakttab label { display: block; text-align: left; }
    .photo-link::after { display: none; }
    body[data-view='tutorial'] .galeria_miniatury { padding: 0 20px 28px !important; }
    body[data-view='tutorial'] .galeria_miniatury img { width: 100%; }
    body[data-view='about'] .site-middle img { width: min(100%, 440px); display: block; margin: auto; }
}
@media (max-width: 350px) {
    .mobile-main-nav { gap: 4px; }
    .mobile-main-nav > a, .mobile-menu > summary { font-size: 13px; padding-inline: 2px; }
}
