/* V10.18 mobile pass: bottom tab bar, readable type, thumb-sized targets, single-scroll pages,
   sticky primary actions (POS, new booking, public booking) and stacked tables on phones. */
.n118-tabbar,.n118-actionbar{display:none}

@media (max-width:900px){
 /* Bottom tab bar */
 .n118-tabbar{display:grid;grid-template-columns:repeat(var(--n118-tabs,5),minmax(0,1fr));position:fixed;inset-inline:0;bottom:0;z-index:150;background:#fff;border-top:1px solid #dfe8e3;box-shadow:0 -8px 24px rgba(16,40,32,.08);padding:4px 4px max(4px,env(safe-area-inset-bottom))}
 .n118-tabbar a,.n118-tabbar button{display:flex;flex-direction:column;align-items:center;justify-content:center;gap:2px;min-height:54px;border:0;background:none;color:#5d6f68;font:inherit;font-size:11px;font-weight:700;text-decoration:none;border-radius:12px;cursor:pointer;-webkit-tap-highlight-color:transparent}
 .n118-tabbar i{font-style:normal;font-size:20px;line-height:1}
 .n118-tabbar .active{color:#0f6b52;background:#ecf6f1}
 .n118-tabbar .n118-tab-main i{width:44px;height:44px;margin-top:-18px;border-radius:50%;display:grid;place-items:center;background:#167257;color:#fff;font-size:24px;box-shadow:0 8px 18px rgba(22,114,87,.35);border:3px solid #fff}
 .n118-tabbar .n118-tab-main{color:#167257}
 body.n118-has-tabbar .page-content{padding-bottom:calc(92px + env(safe-area-inset-bottom))!important}
 body.n118-has-tabbar.n118-has-actionbar .page-content{padding-bottom:calc(164px + env(safe-area-inset-bottom))!important}
 body.sidebar-open .n118-tabbar{visibility:hidden}

 /* Sticky action bar above the tab bar (POS total, booking save) */
 .n118-actionbar{display:flex;align-items:center;gap:10px;position:fixed;inset-inline:8px;bottom:calc(70px + env(safe-area-inset-bottom));z-index:149;background:#13261f;color:#fff;border-radius:16px;padding:8px 8px 8px 14px;box-shadow:0 12px 30px rgba(10,30,24,.28);transition:transform .2s,opacity .2s}
 body:not(.n118-has-tabbar) .n118-actionbar{bottom:max(10px,env(safe-area-inset-bottom))}
 .n118-actionbar[hidden]{display:none}
 .n118-actionbar.n118-away{transform:translateY(140%);opacity:0;pointer-events:none}
 .n118-actionbar-info{flex:1 1 auto;min-width:0;display:flex;flex-direction:column;line-height:1.35}
 .n118-actionbar-info small{font-size:12px;color:#b9cec5;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}
 .n118-actionbar-info b{font-size:18px;white-space:nowrap}
 .n118-actionbar button{flex:0 0 auto;min-height:46px;border:0;border-radius:12px;padding:0 18px;background:#2fb383;color:#fff;font:inherit;font-weight:800;font-size:15px;cursor:pointer}
 .n118-actionbar button:disabled{background:#3b4f48;color:#a9bab3}

 /* Inputs: 16px stops iOS zoom-on-focus; 44px is a comfortable thumb target */
 .app-main input:not([type=checkbox]):not([type=radio]):not([type=range]):not([type=hidden]),.app-main select,.app-main textarea{font-size:16px!important}
 .app-main input:not([type=checkbox]):not([type=radio]):not([type=range]):not([type=hidden]),.app-main select{min-height:44px}
 .app-main .btn{min-height:42px}
 .n118-fs{font-size:11.5px!important}

 /* Subscription notice: one compact row instead of a tall card on every screen */
 .page-content .n113-notice{flex-direction:row!important;align-items:center!important;flex-wrap:wrap;gap:6px 10px;padding:8px 12px!important;margin-bottom:10px!important}
 .page-content .n113-notice>div{gap:4px 8px}
 .page-content .n113-notice small{display:none}
 .page-content .n113-notice-actions{width:auto!important;margin-inline-start:auto;gap:12px}
 .page-content .n113-notice .btn{min-height:36px!important}
 .page-content .n113-link{display:inline-flex;align-items:center;min-height:36px}

 /* Page headings: less vertical chrome */
 .page-content .workspace-heading{gap:10px!important;margin-bottom:12px!important}
 .page-content .workspace-heading h1{font-size:24px!important;line-height:1.4!important}
 .page-content .workspace-heading p{font-size:13px!important;margin-top:2px!important}

 /* One scroll per page: no nested scroll boxes on phones */
 .premium-pos-shell .premium-catalog-grid,#serviceCards.compact-scroll,.booking-service-grid.compact-scroll,.premium-cart-rows{max-height:none!important;overflow:visible!important}
 body[data-controller] .premium-pos-shell.n111-pos.n111-stacked .premium-pos-catalog,body[data-controller] .premium-pos-shell.n111-pos .premium-pos-catalog,body[data-controller] .premium-pos-shell .premium-pos-catalog{height:auto!important;max-height:none!important;overflow:visible!important}
 body[data-controller] .premium-pos-shell .premium-catalog-grid.active{height:auto!important}
 body[data-controller] .premium-pos-shell.n111-pos.n111-stacked,body[data-controller] .premium-pos-shell.n111-pos{grid-template-rows:auto!important;height:auto!important}
 body[data-controller] .premium-pos-shell.n111-pos.n111-stacked .premium-checkout-panel,body[data-controller] .premium-pos-shell .premium-checkout-panel{height:auto!important;max-height:none!important;overflow:visible!important}

 /* Cashier: grid children must not exceed the viewport */
 .v8-shift-live{grid-template-columns:minmax(0,1fr)!important}
 .v8-shift-live>*{min-width:0}

 /* Appointments: KPI cards become a swipeable strip so the day's list is reachable */
 .appointment-kpi-row{display:flex!important;gap:8px!important;overflow-x:auto;scroll-snap-type:x mandatory;padding-bottom:4px;margin-inline:-2px;scrollbar-width:none}
 .appointment-kpi-row::-webkit-scrollbar{display:none}
 .appointment-kpi-row>*{flex:0 0 42%;scroll-snap-align:start;min-width:140px}
 .view-switcher button,.catalog-tabs button{min-height:42px!important;font-size:13px!important}

 /* POS: readable catalog and cart */
 .premium-catalog-item{min-height:72px!important}
 .catalog-item-body b{font-size:14px!important}
 .catalog-item-body small,.catalog-item-price small{font-size:12px!important}
 .catalog-item-price{font-size:15px!important}
 .catalog-item-add{width:30px!important;height:30px!important;font-size:16px!important}
 .premium-cart-row{grid-template-columns:minmax(0,1fr) auto 70px 36px!important;gap:8px!important}
 .cart-row-main b,.cart-line-total b{font-size:13px!important}
 .cart-row-main small,.cart-line-total small{font-size:11px!important}
 .premium-qty button{width:36px!important;height:36px!important;font-size:16px}
 .premium-qty span{min-width:28px!important;font-size:14px!important}
 .cart-delete{width:36px!important;height:36px!important}
 .line-barber{height:38px!important;min-height:38px!important;font-size:13px!important;max-width:100%!important}
 .payment-methods{grid-template-columns:repeat(2,minmax(0,1fr))!important;gap:8px!important}
 .payment-methods button{min-height:48px;font-size:13px!important}
 .premium-totals>div{font-size:13px!important}
 .premium-pay-button b{font-size:14px!important}
 .premium-pay-button small{font-size:11px!important}
 .premium-pay-button{min-height:60px}
 .icon-button{width:42px!important;height:42px!important}
 .checkout-field label,.payment-section>label{font-size:12px!important}

 /* Customers: cards with real tap targets */
 .customer-card-top a[href^="tel:"]{display:inline-flex;align-items:center;min-height:32px;font-size:14px!important}
 .customer-card-actions{gap:6px!important}
 .customer-card-actions a{min-height:42px!important;min-width:42px;display:inline-flex!important;align-items:center;justify-content:center;font-size:13px!important}
 .customer-card-actions a span{font-size:inherit!important}
 .customer-since{font-size:11px!important}

 /* Reports: thumb-sized period chips and tree */
 .page-content a[href*="period="],.page-content a[href*="range="]{min-height:40px;display:inline-flex;align-items:center}
 .report-module-count-v101,.report-tree-kicker{font-size:11px!important}
}

/* Tables become stacked cards on phones (set up by nalyva-mobile-v118.js) */
@media (max-width:700px){
 table.n118-stack{min-width:0!important;width:100%!important;border-collapse:separate!important;border-spacing:0!important}
 .table-wrap:has(>table.n118-stack){overflow:visible!important}
 table.n118-stack thead{display:none!important}
 table.n118-stack,table.n118-stack tbody,table.n118-stack tr,table.n118-stack td{display:block!important;width:auto!important}
 table.n118-stack tr{border:1px solid #e3ebe7!important;border-radius:14px!important;padding:6px 12px!important;margin:0 0 10px!important;background:#fff}
 table.n118-stack td{display:flex!important;justify-content:space-between;align-items:center;gap:12px;padding:7px 0!important;border:0!important;border-bottom:1px dashed #edf2ef!important;text-align:end!important;font-size:14px;min-height:36px;overflow-wrap:anywhere}
 table.n118-stack td:last-child{border-bottom:0!important}
 table.n118-stack td::before{content:attr(data-label);flex:0 0 auto;max-width:45%;text-align:start;color:#6a7c75;font-size:12px;font-weight:700}
 table.n118-stack td[data-label=""]::before,table.n118-stack td[colspan]::before{display:none}
 table.n118-stack td[data-label=""],table.n118-stack td[colspan]{justify-content:center}
 table.n118-stack td .btn,table.n118-stack td .table-row-actions{flex-wrap:wrap}
 table.n118-stack td:first-child:not([colspan]){font-size:16px;font-weight:800;justify-content:flex-start;text-align:start!important;border-bottom-style:solid!important}
 table.n118-stack td:first-child:not([colspan])::before{display:none}
}

/* Public booking page: confirm button pinned to the bottom of the screen */
@media (max-width:900px){
 .premium-public-body .public-confirm-premium{position:fixed!important;inset-inline:10px!important;bottom:max(10px,env(safe-area-inset-bottom))!important;width:auto!important;z-index:120;min-height:62px;box-shadow:0 14px 34px rgba(10,30,24,.3)!important;margin:0!important}
 .premium-public-body .premium-booking-page{padding-bottom:96px!important}
 .premium-public-body .public-confirm-premium:disabled{opacity:1!important;background:#dfe9e4!important;color:#41574f!important;box-shadow:0 10px 26px rgba(10,30,24,.18)!important}
 .premium-public-body .public-confirm-premium:disabled small{color:#5f746c!important}
 .premium-public-body .public-confirm-premium{grid-template-columns:40px 1fr!important;padding:10px 14px!important}
 .premium-public-body .public-confirm-premium>span{width:40px!important;height:40px!important;font-size:18px}
 .premium-public-body .public-confirm-premium b{font-size:16px!important}
 .premium-public-body .public-confirm-premium small{font-size:12.5px!important;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}
 .premium-public-body input,.premium-public-body select,.premium-public-body textarea{font-size:16px!important}
 .premium-public-body .booking-policy summary,.premium-public-body .public-terms a{display:inline-flex;align-items:center;min-height:40px}
 .premium-public-body .premium-booking-hero{padding-block:18px!important}
 .premium-public-body .hero-trust{display:none!important}
}

@media print{.n118-tabbar,.n118-actionbar{display:none!important}}
body.theme-midnight .n118-tabbar{background:#10241d;border-top-color:#29493e}
body.theme-midnight .n118-tabbar a,body.theme-midnight .n118-tabbar button{color:#acc1b8}
body.theme-midnight .n118-tabbar .active{background:#183b2e;color:#9ddbbf}
body.theme-midnight table.n118-stack tr{background:#142d25;border-color:#29493e!important}
