/* ==========================================================
   TOMATHERM — MOBILNÝ DIZAJN (len do 760 px)
   Počítač ostáva bez zmeny. Všetko pod body.tt-mob.
   ========================================================== */

@media (max-width: 760px) {

  .tt-mob { overflow-x: clip; }

  /* ---------- HLAVIČKA: logo + ikony, 56 px ---------- */
  .tt-mob .tt-header { background: #fff; backdrop-filter: none; transition: transform .3s ease; }
  .tt-mob .tt-header.tt-hide { transform: translateY(-100%); }
  .tt-mob .tt-header-row { height: auto; min-height: 56px; padding: 0 10px 0 22px; gap: 2px; flex-wrap: wrap; }
  .tt-mob .tt-logo { margin-right: auto; font-size: 20px; gap: 8px; }
  .tt-mob .tt-logo img, .tt-mob .tt-logo .tt-logo-img { height: 34px !important; width: 34px !important; max-width: 34px !important; }

  .tt-mob .tt-m-only { display: inline-flex !important; }
  .tt-mob .tt-d-only,
  .tt-mob .tt-header-phone,
  .tt-mob .tt-cart-btn { display: none !important; }

  .tt-mob .tt-ibtn {
    width: 44px; height: 44px; border: 0; background: transparent; color: var(--ink);
    align-items: center; justify-content: center; border-radius: 10px; position: relative;
    text-decoration: none; cursor: pointer; padding: 0;
  }
  .tt-mob .tt-ibtn:focus-visible { outline: 2px solid var(--blue); outline-offset: 2px; }
  .tt-mob .tt-badge {
    position: absolute; top: 5px; right: 3px; min-width: 18px; height: 18px; padding: 0 4px;
    border-radius: 999px; background: var(--red); color: #fff; font-size: 11px; font-weight: 700;
    display: flex; align-items: center; justify-content: center;
  }

  /* vyhľadávanie sa rozbalí pod hlavičkou */
  .tt-mob .tt-search { display: none; order: 9; flex-basis: 100%; max-width: none; padding: 0 12px 10px 0; }
  .tt-mob .tt-search.open { display: block; }
  .tt-mob .tt-search input[type=search] { font-size: 16px; border: 1.5px solid var(--ink); height: 44px; }

  /* ---------- KATEGÓRIE: čipy hore, pri scrolle zbalené do jedného tlačidla ---------- */
  .tt-mob .tt-catbar { background: #fff; border-top: 1px solid var(--line); position: relative; }
  .tt-mob .tt-catbar .tt-container { padding: 0; }

  /* rozbalený stav (hore na stránke): posúvateľné čipy */
  .tt-mob .tt-catbar-toggle { display: none !important; }
  .tt-mob .tt-catbar nav {
    display: flex !important; gap: 6px; overflow-x: auto; flex-wrap: nowrap;
    padding: 8px 22px 10px; scroll-snap-type: x proximity; scroll-padding-inline: 22px;
    scrollbar-width: none;
    max-height: 64px; opacity: 1;
    transition: max-height .3s ease, padding .3s ease, opacity .2s ease;
  }
  .tt-mob .tt-catbar nav::-webkit-scrollbar { display: none; }
  .tt-mob .tt-catbar nav a {
    flex: none; scroll-snap-align: start; white-space: nowrap;
    font-size: 13px; font-weight: 600; line-height: 1.2; color: var(--ink);
    padding: 9px 13px; border-radius: 999px; border: 1px solid var(--line); background: var(--paper);
  }
  .tt-mob .tt-catbar nav a.current { background: var(--ink); color: #fff; border-color: var(--ink); }

  /* zbalený stav (po scrolle dole): jedno tlačidlo „Kategórie“ */
  .tt-mob .tt-cats-mini .tt-catbar-toggle {
    display: flex !important; align-items: center; gap: 8px;
    width: 100%; min-height: 44px; padding: 0 22px; border: 0; background: #fff;
    font-family: 'Archivo', sans-serif; font-weight: 700; font-size: 14px; color: var(--ink);
    cursor: pointer; text-align: left;
  }
  .tt-mob .tt-cats-mini .tt-catbar-toggle .tt-cats-cur {
    font-family: 'Instrument Sans', system-ui, sans-serif; font-weight: 500; color: var(--muted);
    overflow: hidden; text-overflow: ellipsis; white-space: nowrap; min-width: 0;
  }
  .tt-mob .tt-cats-mini .tt-catbar-toggle .tt-catbar-arrow { margin-left: auto; transition: transform .25s ease; }
  .tt-mob .tt-cats-mini .tt-catbar-toggle.open .tt-catbar-arrow { transform: rotate(180deg); }
  .tt-mob .tt-cats-mini .tt-catbar-toggle:focus-visible { outline: 2px solid var(--blue); outline-offset: -2px; }

  .tt-mob .tt-cats-mini .tt-catbar nav:not(.open) {
    max-height: 0; padding-top: 0; padding-bottom: 0; opacity: 0; overflow: hidden; pointer-events: none;
  }

  /* po kliknutí: panel so všetkými kategóriami */
  .tt-mob .tt-cats-mini .tt-catbar nav.open {
    position: absolute; left: 0; right: 0; top: 100%;
    display: grid !important; grid-template-columns: 1fr 1fr; gap: 6px;
    max-height: min(70vh, 460px); overflow-y: auto; overflow-x: hidden;
    padding: 10px 22px 16px; background: #fff;
    border-top: 1px solid var(--line); border-bottom: 1px solid var(--line);
    box-shadow: 0 18px 40px rgba(19,24,41,.18);
    animation: tt-cats-in .22s ease;
  }
  .tt-mob .tt-cats-mini .tt-catbar nav.open a {
    white-space: normal; border-radius: 10px; padding: 12px; font-size: 13px; line-height: 1.3;
    min-height: 44px; display: flex; align-items: center;
  }

  /* ---------- HERO: kratší, dve tlačidlá, kompaktný termostat ---------- */
  .tt-mob .tt-hero-grid { padding-top: 14px; padding-bottom: 28px; gap: 18px; grid-template-columns: minmax(0, 1fr); }
  .tt-mob .tt-hero-grid > div { min-width: 0; }
  .tt-mob .tt-hero-grid > div:last-child { margin-top: 0; }
  .tt-mob .tt-eyebrow { text-transform: none; letter-spacing: 0; font-family: inherit; font-size: 13px; font-weight: 600; }
  .tt-mob .tt-hero h1 { font-size: clamp(2.05rem, 10vw, 2.6rem); line-height: 1; margin-top: 10px; }
  .tt-mob .tt-hero-sub { font-size: 16px; line-height: 1.5; margin-top: 12px; }

  .tt-mob .tt-hero-ctas { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; margin-top: 18px; }
  .tt-mob .tt-hero-ctas .tt-mcta {
    width: auto; min-height: 48px; display: inline-flex !important; align-items: center; justify-content: center;
    text-align: center; border-radius: 10px; font-size: 15px; font-weight: 700; padding: 0 10px;
  }
  .tt-mob .tt-mcta-primary { background: var(--red); color: #fff !important; }
  .tt-mob .tt-mcta-line { border: 2px solid var(--ink); color: var(--ink); background: transparent; }

  /* výhody ako posúvateľné čipy */
  .tt-mob .tt-hero-trust {
    margin: 14px -22px 0; padding: 0 22px; gap: 6px; flex-wrap: nowrap; overflow-x: auto; scrollbar-width: none;
  }
  .tt-mob .tt-hero-trust::-webkit-scrollbar { display: none; }
  .tt-mob .tt-hero-trust span {
    flex: none; white-space: nowrap; font-size: 12px; font-weight: 600;
    padding: 6px 10px; border-radius: 999px; background: rgba(19,24,41,.06);
  }

  /* logá značiek – malý pruh */
  .tt-mob .tt-hero-brands {
    display: flex; gap: 8px; overflow-x: auto; scrollbar-width: none; padding-top: 14px;
  }
  .tt-mob .tt-hero-brands::-webkit-scrollbar { display: none; }
  .tt-mob .tt-hero-brands img { height: 26px; max-width: 110px; flex: none; }

  /* termostat ako nízka vodorovná karta */
  .tt-mob .tt-thermo-wrap .tt-house { display: none; }
  .tt-mob .tt-thermo-card {
    display: grid; grid-template-columns: auto 1fr; align-items: center; gap: 2px 14px;
    padding: 14px 16px; border-radius: 12px;
  }
  .tt-mob .tt-thermo-head { grid-column: 2; grid-row: 1; justify-content: flex-start; }
  .tt-mob .tt-thermo-head > span:first-child { display: none; }
  .tt-mob .tt-thermo-temp { grid-column: 1; grid-row: 1 / span 2; font-size: 46px; margin: 0; text-align: left; }
  .tt-mob .tt-thermo-note { grid-column: 2; grid-row: 2; text-align: left; margin: 0; font-size: 13px; }
  .tt-mob .tt-thermo-slider { grid-column: 1 / -1; margin-top: 10px; height: 6px; }
  .tt-mob input[type=range].tt-thermo-slider::-webkit-slider-thumb { width: 32px; height: 32px; }
  .tt-mob .tt-thermo-scale { grid-column: 1 / -1; margin-top: 4px; }
  .tt-mob .tt-thermo-card > p:last-child { grid-column: 1 / -1; margin: 10px 0 0 !important; }
  .tt-mob .tt-thermo-card > p:last-child .tt-btn { display: flex; justify-content: center; min-height: 48px; align-items: center; border-radius: 10px; font-size: 15px; }

  /* ---------- SEKCIE ---------- */
  .tt-mob .tt-section { padding: 30px 0; }
  .tt-mob .tt-section-head { margin-bottom: 14px; align-items: baseline; }
  .tt-mob .tt-section-head h2 { font-size: 26px; }

  /* ---------- PRODUKTY NA TITULKE: swipe karusel ---------- */
  .tt-mob #tt-reco-heat ul.products,
  .tt-mob #tt-reco-cool ul.products {
    display: flex !important; gap: 12px; overflow-x: auto; overflow-y: hidden;
    scroll-snap-type: x mandatory; scroll-padding: 0 22px;
    margin: 0 -22px !important; padding: 26px 22px 8px !important;
    scrollbar-width: none;
  }
  .tt-mob #tt-reco-heat ul.products::-webkit-scrollbar,
  .tt-mob #tt-reco-cool ul.products::-webkit-scrollbar { display: none; }
  .tt-mob #tt-reco-heat ul.products li.product,
  .tt-mob #tt-reco-cool ul.products li.product {
    flex: 0 0 74% !important; scroll-snap-align: start; padding: 0 14px 14px !important; border-radius: 14px;
  }
  .tt-mob #tt-reco-heat ul.products li.product,
  .tt-mob #tt-reco-cool ul.products li.product { --tt-img-top: 10px; --tt-img-h: 160px; }
  .tt-mob #tt-reco-heat ul.products li.product h2,
  .tt-mob #tt-reco-cool ul.products li.product h2 { font-size: 16px !important; }
  .tt-mob #tt-reco-heat ul.products li.product .price,
  .tt-mob #tt-reco-cool ul.products li.product .price { font-size: 20px !important; }
  .tt-mob #tt-reco-heat ul.products li.product .button,
  .tt-mob #tt-reco-cool ul.products li.product .button {
    min-height: 48px; display: flex !important; align-items: center; justify-content: center;
    border-radius: 10px !important; font-size: 15px !important;
  }
  .tt-mob .tt-rail-dots { display: flex; justify-content: center; gap: 6px; margin-top: 10px; }
  .tt-mob .tt-rail-dots i { width: 7px; height: 7px; border-radius: 999px; background: var(--line); transition: width .3s, background .3s; }
  .tt-mob .tt-rail-dots i.on { width: 22px; background: var(--red); }

  /* ostatné výpisy produktov: väčšie tlačidlo na prst */
  .tt-mob ul.products li.product .button { min-height: 44px; display: flex !important; align-items: center; justify-content: center; }

  /* ---------- SORTIMENT: dlaždice 2 × N ---------- */
  .tt-mob .tt-grid-3 { grid-template-columns: 1fr 1fr; gap: 8px; }
  .tt-mob .tt-cat-card { padding: 14px; min-height: 96px; display: flex; flex-direction: column; justify-content: space-between; border-radius: 12px; }
  .tt-mob .tt-cat-card .name { font-size: 15px; line-height: 1.25; }
  .tt-mob .tt-cat-card .note, .tt-mob .tt-cat-card .go { display: none; }

  /* ---------- KALKULAČKA: veľký palec + tlačidlá namiesto zoznamu ---------- */
  .tt-mob .tt-calc input[type=range]::-webkit-slider-thumb { width: 32px; height: 32px; }
  .tt-mob .tt-calc input[type=range]::-moz-range-thumb { width: 28px; height: 28px; }
  .tt-mob .tt-calc select.tt-has-seg { display: none; }
  .tt-mob .tt-seg { display: grid !important; grid-template-columns: repeat(3, 1fr); gap: 6px; }
  .tt-mob .tt-seg button {
    min-height: 44px; border-radius: 10px; border: 1.5px solid var(--line); background: var(--paper);
    color: var(--ink); font: inherit; font-size: 13px; font-weight: 600; line-height: 1.2; padding: 4px; cursor: pointer;
  }
  .tt-mob .tt-seg button[aria-pressed="true"] { background: var(--ink); color: #fff; border-color: var(--ink); }

  /* ---------- PÄTIČKA: harmonika ---------- */
  .tt-mob .tt-footer-grid { gap: 0; }
  .tt-mob .tt-footer-grid > div:first-child { padding-bottom: 18px; }
  .tt-mob .tt-fcol { border-bottom: 1px solid rgba(255,255,255,.12); }
  .tt-mob .tt-fcol > summary {
    pointer-events: auto; cursor: pointer; min-height: 52px;
    display: flex; align-items: center; justify-content: space-between;
  }
  .tt-mob .tt-fcol > summary h4 { margin: 0; font-size: 13px; color: #fff; }
  .tt-mob .tt-fcol > summary::after { content: "+"; font-size: 22px; color: #fff; }
  .tt-mob .tt-fcol[open] > summary::after { content: "–"; }
  .tt-mob .tt-fcol ul { padding-bottom: 12px; }
  .tt-mob .tt-fcol li { margin: 0; padding: 7px 0; }
  .tt-mob .tt-footer { padding-bottom: calc(76px + env(safe-area-inset-bottom, 0px)); }

  /* ---------- SPODNÁ LIŠTA ---------- */
  .tt-dock {
    position: fixed; left: 0; right: 0; bottom: 0; z-index: 55;
    display: grid; grid-template-columns: 1fr 1fr 1.2fr; gap: 8px;
    padding: 8px 10px calc(8px + env(safe-area-inset-bottom, 0px));
    background: #fff; border-top: 1px solid var(--line); box-shadow: 0 -8px 24px rgba(19,24,41,.10);
    transform: translateY(110%); transition: transform .35s cubic-bezier(.2,.8,.2,1);
  }
  .tt-dock.show { transform: none; }
  .tt-dock a {
    min-height: 48px; display: flex; align-items: center; justify-content: center; gap: 6px;
    border-radius: 10px; font-weight: 700; font-size: 14px; text-decoration: none; color: var(--ink);
  }
  .tt-dock .tt-dock-call { border: 1.5px solid var(--ink); }
  .tt-dock .tt-dock-calc { border: 1.5px solid var(--line); }
  .tt-dock .tt-dock-sale { background: var(--red); color: #fff; }
  .tt-dock a:focus-visible { outline: 2px solid var(--blue); outline-offset: 2px; }
}

/* ==========================================================
   POČÍTAČ: kategórie sa pri scrolle zbalia do tlačidla
   ========================================================== */
@media (min-width: 761px) {
  .tt-mob .tt-header-row { transition: height .3s ease; }
  .tt-mob .tt-logo img, .tt-mob .tt-logo .tt-logo-img { transition: height .3s ease, width .3s ease, max-width .3s ease; }
  .tt-mob .tt-catbar { position: relative; }
  .tt-mob .tt-catbar nav {
    max-height: 160px; opacity: 1;
    transition: max-height .3s ease, opacity .2s ease;
  }

  /* zbalený stav: nižšia hlavička + tlačidlo */
  .tt-mob .tt-cats-mini .tt-header-row { height: 64px; }
  .tt-mob .tt-cats-mini .tt-logo img,
  .tt-mob .tt-cats-mini .tt-logo .tt-logo-img { height: 42px !important; width: 42px !important; max-width: 42px !important; }

  .tt-mob .tt-cats-mini .tt-catbar nav:not(.open) { max-height: 0; opacity: 0; overflow: hidden; pointer-events: none; }

  .tt-mob .tt-cats-mini .tt-catbar-toggle {
    display: inline-flex !important; align-items: center; gap: 10px;
    height: 44px; padding: 0 2px; border: 0; background: transparent; cursor: pointer;
    font-family: 'Archivo', sans-serif; font-weight: 700; font-size: 14px; color: #fff;
  }
  .tt-mob .tt-cats-mini .tt-catbar-toggle .tt-cats-cur { font-family: 'Instrument Sans', system-ui, sans-serif; font-weight: 500; color: rgba(255,255,255,.7); }
  .tt-mob .tt-cats-mini .tt-catbar-toggle .tt-catbar-arrow { transition: transform .25s ease; }
  .tt-mob .tt-cats-mini .tt-catbar-toggle.open .tt-catbar-arrow { transform: rotate(180deg); }
  .tt-mob .tt-cats-mini .tt-catbar-toggle:hover { color: #F09E8C; }
  .tt-mob .tt-cats-mini .tt-catbar-toggle:focus-visible { outline: 2px solid #F09E8C; outline-offset: 2px; }

  /* otvorený panel: tmavý ako pás kategórií, 4 stĺpce zarovnané s obsahom */
  .tt-mob .tt-cats-mini .tt-catbar nav.open {
    position: absolute; left: 0; right: 0; top: 100%; z-index: 5;
    display: grid !important; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 8px;
    max-height: none; overflow: visible;
    padding: 14px max(20px, calc((100% - 1112px) / 2)) 20px;
    background: var(--ink); box-shadow: 0 24px 48px rgba(19,24,41,.28);
    animation: tt-cats-in .22s ease;
  }
  .tt-mob .tt-cats-mini .tt-catbar nav.open a {
    white-space: normal; border: 0; border-radius: 6px; padding: 14px 16px;
    background: rgba(255,255,255,.07); color: #fff; font-size: 14px; line-height: 1.3;
  }
  .tt-mob .tt-cats-mini .tt-catbar nav.open a:hover { background: rgba(255,255,255,.14); }
  .tt-mob .tt-cats-mini .tt-catbar nav.open a.current { background: var(--red); }
}
@keyframes tt-cats-in { from { opacity: 0; transform: translateY(-6px); } to { opacity: 1; transform: none; } }

/* na počítači sa lišta nikdy neukáže */
@media (min-width: 761px) { .tt-dock { display: none; } }

@media (prefers-reduced-motion: reduce) {
  .tt-mob .tt-header, .tt-dock, .tt-mob .tt-catbar nav, .tt-mob .tt-header-row { transition: none; }
  .tt-mob .tt-cats-mini .tt-catbar nav.open { animation: none; }
}
