/* Loaded after page styles so small-screen rules are consistent across themes. */
.tv-shell{grid-template-columns:270px minmax(0,1fr)}
.tv-content{width:100%;min-width:0}
@media(max-width:1100px){.tv-shell{grid-template-columns:minmax(0,1fr)}}
@media(max-width:700px){
 .tv-main,.tv-content,.pay-page,.order-manage-page,.manage-grid,.manage-main,.manage-card{min-width:0;max-width:100%}
 .tv-content table{display:block;max-width:100%;overflow-x:auto;min-width:0!important;-webkit-overflow-scrolling:touch}
 .tv-content table>thead,.tv-content table>tbody,.tv-content table>tfoot{min-width:100%}
 .tv-content table td,.tv-content table th{min-width:100px}
 .tv-content table td:has(input),.tv-content table td:has(select){min-width:150px}
 .tv-content .responsive-table table{display:table;min-width:600px!important}
 .tv-content .popover-form,.tv-content .order-manage-popover{position:fixed;inset:85px 12px auto;max-height:calc(100dvh - 110px);overflow:auto;width:auto;z-index:60}
 .landing-nav{flex-direction:column;align-items:stretch!important;padding:16px!important}
 .landing-nav .public-links{justify-content:flex-start!important;width:100%;gap:8px}
 .landing-nav .public-links a{white-space:normal;font-size:13px;padding:10px}
 .landing-brand{max-width:100%}
 .cta .tv-btn.secondary{color:#3730a3!important;background:#eef2ff!important}
 .store-body .store-grid,.store-body .store-grid.compact,.store-body .store-catalog>.store-grid{grid-template-columns:repeat(2,minmax(0,1fr))!important;gap:10px}
 .store-body .store-grid>.product-card{min-width:0;margin:0!important;grid-column:auto!important;grid-row:auto!important}
 .store-body .product-card .image{height:auto;aspect-ratio:4/5}
 .store-body .product-card .body{padding:10px}
 .store-body .product-card h3{font-size:14px;line-height:1.4;margin:6px 0;overflow-wrap:anywhere}
 .store-body .product-card .product-price{font-size:14px;flex-wrap:wrap;gap:4px}
 .store-body .product-card-bottom{font-size:11px;gap:4px;flex-wrap:wrap}
 .store-body .product-card>a{display:block!important}
}

/* Order records become readable cards on phones; desktop keeps its comparison table. */
@media(max-width:700px){
 .tv-content .orders-index-page .orders-table{display:block;width:100%;min-width:0!important;overflow:visible}
 .orders-index-page .orders-table-scroll{overflow:visible}
 .orders-index-page .table-scroll-hint{display:none}
 .orders-index-page .orders-table thead{position:absolute;width:1px;height:1px;overflow:hidden;clip-path:inset(50%);white-space:nowrap}
 .orders-index-page .orders-table tbody{display:block;padding:12px;min-width:0}
 .orders-index-page .orders-table tbody tr{display:block;border:1px solid #e6eaf0;border-radius:14px;padding:12px;background:#fff;margin-bottom:12px}
 .orders-index-page .orders-table tbody tr:last-child{margin-bottom:0}
 .tv-content .orders-index-page .orders-table td{display:block;width:100%;min-width:0;padding:8px 0;border:0;white-space:normal;overflow-wrap:anywhere;font-size:14px}
 .orders-index-page .orders-table td[data-label]::before{content:attr(data-label);display:block;font-size:10px;font-weight:800;letter-spacing:.06em;text-transform:uppercase;color:#64748b;margin-bottom:4px}
 .orders-index-page .order-number-cell strong{font-size:16px;overflow-wrap:normal}
 .orders-index-page .order-customer-cell small,.orders-index-page .orders-subtext{font-size:12px;overflow-wrap:anywhere}
 .orders-index-page .orders-table td.orders-money{font-size:19px}
 .orders-index-page .orders-table td.orders-actions-col{min-width:0;border-top:1px solid #edf0f5;margin-top:8px;padding-top:12px}
 .orders-index-page .orders-actions-col::before{display:none!important}
 .orders-index-page .orders-manage-btn{display:flex;width:100%;min-height:44px;justify-content:space-between;align-items:center}
}
@media(max-width:700px){
 .tv-content .responsive-table:has(.mobile-records){overflow:visible}
 .tv-content .responsive-table:has(.mobile-records)>.table-scroll-hint{display:none}
 .tv-content .responsive-table table.mobile-records{display:block;width:100%;min-width:0!important;overflow:visible}
 .mobile-records thead{position:absolute;width:1px;height:1px;overflow:hidden;clip-path:inset(50%);white-space:nowrap}
 .mobile-records tbody,.mobile-records tfoot{display:block}
 .mobile-records tbody tr{display:block;padding:12px;border:1px solid #e6eaf0;border-radius:12px;margin-bottom:12px;background:#fff}
 .tv-content table.mobile-records td{display:block;width:100%;min-width:0!important;max-width:100%;padding:8px 0;white-space:normal;overflow-wrap:anywhere;border:0}
 .mobile-records td[data-label]::before{content:attr(data-label);display:block;color:#64748b;font-size:11px;font-weight:700;margin-bottom:5px}
 .mobile-records td>*{max-width:100%;min-width:0}
 .mobile-records td .inline-form{min-width:0;flex-wrap:wrap}
 .mobile-records td input,.mobile-records td select{width:100%!important;min-width:0!important}
 .mobile-records td input[type=checkbox],.mobile-records td input[type=radio]{width:auto!important}
 .mobile-records .tv-product-cell{min-width:0}
 .mobile-records .tv-btn{white-space:normal}
 .tv-topbar{flex-wrap:wrap}
}
@media(max-width:700px){
 .tv-content .orders-index-page .orders-table thead,.tv-content table.mobile-records thead{min-width:0!important;max-width:1px;left:0}
}
/* Compact mobile records: primary identity spans the card; details share rows. */
@media(max-width:700px){
 .tv-content table.mobile-records tbody tr{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:8px 14px;padding:14px}
 .tv-content table.mobile-records td{padding:3px 0;font-size:13px}
 .mobile-records td:first-child,.mobile-records td[colspan],.mobile-records td:has(form),.mobile-records td:has(.tv-product-cell){grid-column:1/-1}
 .mobile-records td[data-label]::before{font-size:10px;margin-bottom:3px}
 .tv-content .orders-index-page .orders-table tbody tr{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:9px 14px;padding:14px}
 .tv-content .orders-index-page .orders-table td{padding:0;font-size:13px}
 .orders-index-page .orders-table td[data-label="Order"],.orders-index-page .orders-table td[data-label="Customer"],.orders-index-page .orders-table td.orders-actions-col{grid-column:1/-1}
 .orders-index-page .orders-table td[data-label="Order"]::before,.orders-index-page .orders-table td[data-label="Customer"]::before{display:none}
 .orders-index-page .order-number-cell strong{font-size:14px;line-height:1.4}
 .orders-index-page .order-number-cell small{font-size:11px;margin-top:2px}
 .orders-index-page .order-customer-cell strong{font-size:13px}
 .orders-index-page .order-customer-cell small{display:inline;font-size:11px;margin-right:8px;line-height:1.5}
 .orders-index-page .orders-table td[data-label="Customer"]{padding-bottom:8px;border-bottom:1px solid #eef1f6}
 .orders-index-page .orders-table td[data-label]::before{font-size:9px;margin-bottom:3px}
 .orders-index-page .orders-table td.orders-money{font-size:16px;line-height:1.4}
 .orders-index-page .orders-status,.orders-index-page .orders-source-pill{padding:4px 7px;font-size:10px}
 .orders-index-page .orders-subtext{font-size:11px;margin-top:2px}
 .orders-index-page .orders-table td.orders-actions-col{margin-top:2px;padding-top:9px}
 .orders-index-page .orders-manage-btn{min-height:40px;font-size:12px}
}

/* Full-aspect store branding and compact catalogue controls. */
.store-body > .public-nav > .store-brand .store-logo{width:140px;height:52px;flex:0 0 140px;overflow:visible}
.store-body .store-logo img,.store-footer .store-logo img{position:static!important;display:block;width:100%!important;height:100%!important;max-width:100%!important;object-fit:contain;object-position:left center;border-radius:0}
.store-body > .public-nav > .store-brand:has(.store-logo)>strong{display:none}
.store-body .compact-catalog-search{display:grid;grid-template-columns:minmax(0,1fr) auto auto;align-items:start;gap:8px}
.store-body .compact-catalog-search>.tv-input{grid-column:1;min-width:0;height:42px;margin:0;font-size:16px}
.store-body .compact-catalog-search>.catalog-search-submit{grid-column:2;min-height:42px;padding:9px 14px;width:auto}
.catalog-more-filters{grid-column:3;min-width:0}
.catalog-more-filters>summary{cursor:pointer;list-style:none;display:flex;align-items:center;justify-content:space-between;gap:12px;min-height:42px;padding:9px 12px;border:1px solid #dce1e9;border-radius:10px;font-size:14px;font-weight:600}
.catalog-more-filters>summary::-webkit-details-marker{display:none}
.catalog-more-filters[open]{grid-column:1/-1}
.catalog-more-filters[open]>summary{width:max-content;margin-bottom:12px}
.catalog-filter-fields{display:grid;grid-template-columns:repeat(3,minmax(0,1fr)) auto auto;gap:8px;align-items:center}
.store-body .catalog-filter-fields .tv-input,.store-body .catalog-filter-fields .tv-select{grid-column:auto;min-width:0;height:42px;margin:0;font-size:16px}
.store-body .catalog-filter-fields .tv-btn{grid-column:auto;width:auto;padding:9px 14px;min-height:42px}
.catalog-clear{font-size:13px;text-align:center;padding:10px}
@media(max-width:700px){
 .store-body>.public-nav{display:flex;flex-wrap:wrap;gap:4px;padding:8px 14px;overflow:visible;background:#fff;isolation:isolate}
 .store-body>.public-nav>.store-brand{max-width:100%;flex:0 0 100%;justify-content:center}
 .store-body>.public-nav>.store-brand .store-logo{width:130px;height:44px;flex:0 0 130px}
 .store-body>.public-nav>.public-links{width:100%;flex:0 1 100%;min-width:0;margin:0;justify-content:flex-start;gap:4px;overflow-x:auto}
 .store-body>.public-nav>.public-links a{flex:1 0 auto;text-align:center;padding:8px 10px;font-size:13px}
 .store-body .store-filter-panel{padding:10px;border-radius:12px}
 .store-body .compact-catalog-search{grid-template-columns:minmax(0,1fr) auto}
 .catalog-more-filters{grid-column:1/-1}
 .catalog-more-filters>summary{border:0;padding:4px 2px;min-height:32px;width:max-content}
 .catalog-filter-fields{grid-template-columns:repeat(2,minmax(0,1fr))}
 .store-body .catalog-filter-fields>.tv-select{grid-column:1/-1}
 .store-body .catalog-filter-fields>.tv-btn{grid-column:1}
 .catalog-heading{flex-wrap:wrap;gap:6px}.catalog-heading p{max-width:none;text-align:left;margin:0}
 .store-body .category-pills{justify-content:flex-start;scroll-padding-inline:0}
}

/* Store controls share the owner's brand color, including catalogue actions. */
.store-body .tv-btn:not(.secondary),.store-body .store-cta,.store-body .store-buy-btn,.store-body .category-pills a[aria-current]{background:var(--primary);color:var(--store-button-text,#fff);border-color:var(--primary)}
.store-body .tv-btn.secondary{background:transparent;color:var(--primary);border:1px solid var(--primary)}
.store-body .store-filter-form.compact-catalog-search>input.tv-input:first-child{grid-column:1;grid-row:1;width:100%;min-width:0}
.store-body .store-filter-form.compact-catalog-search>button.catalog-search-submit{grid-column:2;grid-row:1;margin:0;align-self:stretch}
@media(max-width:700px){
 .store-body>.public-nav{flex-wrap:nowrap;align-items:center;min-height:64px;padding:6px 12px;gap:10px}
 .store-body>.public-nav>.store-brand{flex:0 0 80px;max-width:80px;justify-content:flex-start}
 .store-body>.public-nav>.store-brand .store-logo{width:80px;height:46px;flex:0 0 80px}
 .store-body>.public-nav>.public-links{flex:1 1 0;width:auto;min-width:0;justify-content:flex-start;gap:0;scrollbar-width:none}
 .store-body>.public-nav>.public-links a{flex:0 0 auto;padding:12px 7px;font-size:12px;white-space:nowrap}
 .store-body .store-filter-panel{padding:8px;margin-top:10px}
 .store-body .store-filter-form.compact-catalog-search{gap:6px;grid-template-columns:minmax(0,1fr) auto}
 .store-body .store-filter-form.compact-catalog-search>button.catalog-search-submit{padding:8px 12px;font-size:14px;min-height:42px}
 .store-body .catalog-more-filters>summary{min-height:30px;padding:2px 4px;font-size:13px;margin-bottom:0}
 .store-body .catalog-more-filters[open]>summary{margin-bottom:8px}
 .store-body .category-pills{margin-bottom:0;scrollbar-width:none;padding-bottom:4px;gap:8px}
 .store-body .category-pills::-webkit-scrollbar{display:none}
 .store-body .category-pills a{padding:8px 12px;font-size:12px}
 .store-body .store-empty{padding:28px 12px}
}

/* Preserve the full photo in catalogue cards, detail galleries and related items. */
.store-body .store-grid .product-card .image{background-size:contain;background-repeat:no-repeat;background-position:center}
.store-body .product-gallery{min-width:0}
.store-body .product-gallery .product-main-image{display:flex;align-items:center;justify-content:center;overflow:hidden;background:#f3f4f6}
.store-body .product-gallery .product-main-image>img{display:block;width:100%;height:100%;object-fit:contain;object-position:center}
.store-body .product-thumbs{gap:8px;padding:4px 2px}
.store-body .product-thumbs button{flex:0 0 76px;width:76px;height:84px;padding:3px;border:2px solid transparent;border-radius:10px;background:#f3f4f6;cursor:pointer}
.store-body .product-thumbs button[aria-pressed="true"]{border-color:var(--primary)}
.store-body .product-thumbs button img{display:block;width:100%;height:100%;object-fit:contain;border-radius:6px}

/* Compact owner pages: retain readable controls without oversized record cards. */
.growth-page .growth-row>div{flex:1;min-width:0}
.growth-page .growth-row>.tv-btn{flex:0 0 auto;white-space:nowrap;word-break:normal;overflow-wrap:normal}
@media(max-width:700px){
 .payments-owner-page .pay-page,.growth-page{gap:12px}
 .payments-owner-page .pay-card,.payments-owner-page .payment-policy,.growth-page .growth-card{padding:14px;border-radius:12px;min-width:0}
 .payments-owner-page .payment-policy p{font-size:13px;line-height:1.5;margin:6px 0 10px}
 .payments-owner-page .pay-stats,.growth-page .growth-grid{grid-template-columns:repeat(2,minmax(0,1fr));gap:8px}
 .payments-owner-page .pay-stat{padding:12px;min-width:0}
 .payments-owner-page .pay-stat strong,.growth-page .growth-stat strong{font-size:18px;overflow-wrap:anywhere}
 .payments-owner-page .pay-head h1,.growth-page .growth-head h1{font-size:24px}
 .payments-owner-page .pay-head p,.growth-page .growth-head p{font-size:13px;margin:4px 0}
 .payments-owner-page .pay-provider{gap:8px;margin-bottom:10px}
 .payments-owner-page .pay-provider p{margin:4px 0;font-size:13px}
 .payments-owner-page .pay-provider h3{margin-bottom:4px}
 .payments-owner-page .pay-grid{gap:12px}
 .growth-page .growth-list{gap:0}
 .growth-page .growth-row{gap:10px;padding:12px 0;font-size:14px}
 .growth-page .growth-row .tv-muted{font-size:13px;line-height:1.45;margin-top:4px}
 .growth-page .growth-row>.tv-btn{padding:10px;min-height:40px}
 .growth-page .growth-score{flex-shrink:0;width:70px;height:70px;font-size:20px;border-width:7px}
 .tv-content :is(.categories-page,.reseller-team-page,.payments-owner-page) table.mobile-records tbody tr{gap:8px 12px;padding:10px;margin-bottom:8px}
 .tv-content :is(.categories-page,.reseller-team-page,.payments-owner-page) table.mobile-records td{padding:0;line-height:1.4}
 .tv-content :is(.categories-page,.reseller-team-page,.payments-owner-page) table.mobile-records td::before{margin-bottom:2px}
 .tv-content .categories-page table.mobile-records td:nth-child(5){grid-column:2;align-self:end}
 .tv-content .categories-page table.mobile-records td:nth-child(5)::before{display:none}
 .categories-page .popover-form{position:static;width:100%;min-width:0;margin-top:8px}
 .tv-content .categories-page table.mobile-records tr:has(details[open]) td:nth-child(5){grid-column:1/-1}
 .categories-page .tv-card,.reseller-team-page .tv-card{padding:12px}
 .tv-content .reseller-team-page table.mobile-records td:nth-child(2){grid-column:1;grid-row:2}
 .tv-content .reseller-team-page table.mobile-records td:nth-child(4){grid-column:2;grid-row:2}
 .tv-content .reseller-team-page table.mobile-records td.reseller-empty-actions{display:none}
 .tv-content .reseller-team-page table.mobile-records .reseller-link-row input{width:0!important;flex:1 1 0}
 .reseller-team-page .reseller-commission-form .tv-btn{white-space:nowrap}
}
