/*
Theme Name: Торбинка
Theme URI: https://torbynka.shop
Author: Торбинка
Description: Тема інтернет-магазину Торбинка у стилі каталогу з лендингом товару (працює разом з плагіном Torbynka Core і WooCommerce).
Version: 1.0.1
Requires PHP: 8.0
Text Domain: torbynka
*/
:root{--tb-primary:#1B2A4A;--tb-primary2:#2F5FD0;--tb-cta:#F26B1D;--tb-cta-dark:#D9570C;--tb-accent:#2E7D32;--tb-bg:#F4F6FA;--tb-text:#111C33;--tb-muted:#6B7689;--tb-border:#DDE3EC}
*,*:before,*:after{box-sizing:border-box}
html{-webkit-text-size-adjust:100%}
body{margin:0;font-family:"Inter",system-ui,-apple-system,"Segoe UI",Roboto,Arial,sans-serif;font-size:16px;line-height:1.55;color:var(--tb-text);background:#fff}
img{max-width:100%;height:auto}
a{color:var(--tb-primary2)}
.tb-container{max-width:1160px;margin:0 auto;padding:0 16px}
.screen-reader-text{position:absolute!important;clip:rect(1px,1px,1px,1px);width:1px;height:1px;overflow:hidden}

/* Top banner */
.th-banner{background:var(--tb-primary);color:#fff;text-align:center;font-size:14px;padding:7px 12px;font-weight:600}

/* Header */
.th-header{background:#fff;border-bottom:1px solid var(--tb-border);position:sticky;top:0;z-index:40}
.th-header-row{display:flex;align-items:center;gap:20px;height:70px}
.th-logo{display:flex;align-items:center;gap:8px;text-decoration:none;color:var(--tb-primary);font-weight:900;font-size:26px;letter-spacing:-.02em;white-space:nowrap}
.th-logo img{max-height:46px;width:auto}
.th-logo-mark{width:34px;height:34px;border-radius:10px;background:var(--tb-cta);color:#fff;display:inline-flex;align-items:center;justify-content:center;font-size:20px}
.th-search{flex:1;display:flex;max-width:520px}
.th-search input{flex:1;border:1.5px solid var(--tb-border);border-right:0;border-radius:10px 0 0 10px;padding:11px 14px;font-size:15px;font-family:inherit;min-width:0}
.th-search input:focus{outline:0;border-color:var(--tb-primary2)}
.th-search button{border:0;background:var(--tb-primary);color:#fff;border-radius:0 10px 10px 0;padding:0 16px;cursor:pointer;font-size:16px}
.th-contact{margin-left:auto;text-align:right;line-height:1.25;font-size:13px;color:var(--tb-muted);white-space:nowrap}
.th-contact a{display:block;font-size:17px;font-weight:800;color:var(--tb-primary);text-decoration:none}
.th-trust{background:var(--tb-bg);border-bottom:1px solid var(--tb-border)}
.th-trust ul{list-style:none;margin:0;padding:9px 0;display:flex;justify-content:center;gap:28px;flex-wrap:wrap;font-size:14px;font-weight:600}
.th-trust li{display:flex;align-items:center;gap:7px}
.th-trust li:before{content:"✓";width:18px;height:18px;border-radius:50%;background:var(--tb-accent);color:#fff;font-size:11px;font-weight:800;display:inline-flex;align-items:center;justify-content:center}

/* Home / catalog */
.th-main{padding:28px 0 50px}
.th-h1{font-size:30px;margin:0 0 18px;color:var(--tb-primary);font-weight:900}
.th-h2{font-size:22px;margin:30px 0 14px;color:var(--tb-primary);font-weight:800}
.th-cats{display:flex;gap:12px;overflow-x:auto;padding:2px 2px 10px;margin:0 -2px 8px;scrollbar-width:thin}
.th-cat{flex:0 0 auto;display:flex;flex-direction:column;align-items:center;gap:8px;width:118px;text-decoration:none;color:var(--tb-text);font-size:14px;font-weight:600;text-align:center}
.th-cat-img{width:96px;height:96px;border-radius:50%;background:var(--tb-bg);border:2px solid transparent;overflow:hidden;display:flex;align-items:center;justify-content:center;font-size:30px}
.th-cat-img img{width:100%;height:100%;object-fit:cover}
.th-cat:hover .th-cat-img,.th-cat.is-active .th-cat-img{border-color:var(--tb-cta)}
.th-grid{display:grid;grid-template-columns:repeat(4,1fr);gap:18px}
.th-card{display:flex;flex-direction:column;background:#fff;border:1px solid var(--tb-border);border-radius:14px;overflow:hidden;text-decoration:none;color:var(--tb-text);transition:box-shadow .15s,transform .15s}
.th-card:hover{box-shadow:0 10px 28px rgba(17,28,51,.10);transform:translateY(-2px)}
.th-card-img{position:relative;aspect-ratio:1/1;background:#fff;display:flex;align-items:center;justify-content:center}
.th-card-img img{width:100%;height:100%;object-fit:contain}
.th-card-badge{position:absolute;top:10px;left:10px;background:#E11D2E;color:#fff;font-weight:800;font-size:13px;border-radius:7px;padding:3px 8px}
.th-card-body{padding:12px 14px 14px;display:flex;flex-direction:column;gap:6px;flex:1}
.th-card-name{font-weight:600;font-size:15px;line-height:1.35;display:-webkit-box;-webkit-line-clamp:2;-webkit-box-orient:vertical;overflow:hidden;min-height:2.7em}
.th-card-price{margin-top:auto}
.th-card-price .now{font-size:20px;font-weight:800}
.th-card-price .old{font-size:14px;color:var(--tb-muted);text-decoration:line-through;margin-left:6px}
.th-card-btn{display:block;text-align:center;background:var(--tb-cta);color:#fff;border-radius:9px;padding:9px;font-weight:700;font-size:14px}
.th-card:hover .th-card-btn{background:var(--tb-cta-dark)}
.th-more{text-align:center;margin-top:24px}
.th-more a{display:inline-block;border:1.5px solid var(--tb-primary);color:var(--tb-primary);border-radius:10px;padding:11px 26px;font-weight:700;text-decoration:none}
.th-more a:hover{background:var(--tb-primary);color:#fff}
.th-count{color:var(--tb-muted);font-size:14px;margin-top:8px}
.th-empty{background:var(--tb-bg);border-radius:14px;padding:30px;text-align:center;color:var(--tb-muted)}
.th-page{max-width:820px}
.th-page h1{color:var(--tb-primary)}

/* Footer */
.th-footer{background:var(--tb-primary);color:rgba(255,255,255,.85);padding:34px 0 20px;font-size:14px;margin-top:20px}
.th-footer a{color:#fff;text-decoration:none}
.th-footer a:hover{text-decoration:underline}
.th-footer-grid{display:grid;grid-template-columns:1.3fr 1fr 1fr;gap:28px}
.th-footer h4{color:#fff;margin:0 0 10px;font-size:15px}
.th-footer ul{list-style:none;margin:0;padding:0;display:grid;gap:6px}
.th-footer .th-phone{font-size:20px;font-weight:800}
.th-pay{display:flex;gap:8px;flex-wrap:wrap;margin-top:10px}
.th-pay span{background:rgba(255,255,255,.12);border-radius:6px;padding:4px 9px;font-size:12px;font-weight:700}
.th-legal{border-top:1px solid rgba(255,255,255,.15);margin-top:24px;padding-top:14px;font-size:12px;color:rgba(255,255,255,.6);white-space:pre-line}

@media (max-width:1000px){.th-grid{grid-template-columns:repeat(3,1fr)}}
@media (max-width:760px){
  .th-header-row{height:auto;flex-wrap:wrap;padding:10px 0;gap:10px}
  .th-logo{font-size:22px}
  .th-search{order:3;flex-basis:100%;max-width:none}
  .th-contact a{font-size:15px}
  .th-trust ul{justify-content:flex-start;gap:6px 16px;font-size:13px;padding:8px 0}
  .th-grid{grid-template-columns:repeat(2,1fr);gap:10px}
  .th-card-body{padding:10px}
  .th-card-name{font-size:14px}
  .th-card-price .now{font-size:17px}
  .th-cat{width:86px;font-size:12px}
  .th-cat-img{width:72px;height:72px}
  .th-h1{font-size:24px}
  .th-footer-grid{grid-template-columns:1fr}
}

.th-subcats{display:flex;flex-wrap:wrap;gap:8px;margin:-6px 0 22px}
.th-subcat{padding:7px 14px;border:1px solid var(--tb-border);border-radius:999px;text-decoration:none;color:var(--tb-text);font-size:14px;background:#fff}
.th-subcat.is-active,.th-subcat:hover{background:var(--tb-primary);border-color:var(--tb-primary);color:#fff}
