/* TEDY M18 Luxury Presentation Overlay | scoped; no stock/sale/backend mutations. */
:root{--m18-gold:#f2d28b;--m18-gold2:#c49a43;--m18-edge:rgba(230,189,101,.42);--m18-bg:#001c13}
html[data-m18-ui] {scroll-behavior:auto;scroll-padding-top:75px}
html[data-m18-ui] body {background:#00180f;color:#eef8ef;overflow-x:hidden}
html[data-m18-ui] #app .app-shell{background:radial-gradient(ellipse at 42% 8%,rgba(21,83,52,.27),transparent 32%),linear-gradient(155deg,#001d14 0%,#002115 49%,#00160e 100%)}
html[data-m18-ui] #app .topbar{min-height:55px;padding:6px 10px;gap:7px;background:#002116f7;border-bottom:1px solid var(--m18-edge);box-shadow:0 3px 14px #00120955;backdrop-filter:none;z-index:75;align-items:center}
html[data-m18-ui] #app .topbar-title{min-width:0;flex:1}
html[data-m18-ui] #app .topbar-title h2{font-size:clamp(12px,3.4vw,16px);line-height:1.2;font-weight:750}
html[data-m18-ui] #app .topbar-title small,
html[data-m18-ui] #app .topbar-actions>.pill:not(.avatar),
html[data-m18-ui] #app .topbar-actions>.topbar-profile.pill{display:none!important}
html[data-m18-ui] #app .topbar-actions{gap:6px;margin-left:auto}
html[data-m18-ui] #app .avatar{width:43px;min-width:43px;height:43px;border-radius:50%;border:1px solid var(--m18-gold2);color:#f9e8bd;background:#06452e;font-size:14px;box-shadow:inset 0 0 0 1px #ddbf6c50}
html[data-m18-ui] #app button.menu-toggle{display:inline-flex;flex:none;align-items:center;justify-content:center;width:44px;height:44px;padding:0!important;border-radius:12px;border:1px solid var(--m18-gold2)!important;color:#fff4d9;background:#002619!important;box-shadow:none}
html[data-m18-ui] #app .branch-context-m6{padding:0!important;margin:0!important;flex:1 1 130px;min-width:0!important;max-width:52%;display:flex;align-items:center}
html[data-m18-ui] #app .branch-context-m6>label{display:none!important}
html[data-m18-ui] #app .branch-context-m6 .tedy-m16-branch-choice{min-width:0!important;width:100%!important;margin:0!important}
html[data-m18-ui] #app .branch-context-m6 #globalBranch,
html[data-m18-ui] #app .branch-context-m6 .tedy-m16-branch-label{min-height:43px!important;line-height:1.4!important;font-size:12px!important;border-radius:12px!important}
html[data-m18-ui] #app .branch-context-m6 .tedy-m16-branch-label{white-space:nowrap!important;text-overflow:ellipsis!important;overflow:hidden!important;max-width:100%!important}
html[data-m18-ui] #app .m18-language-slot{flex:none;min-width:0;max-width:27%}
html[data-m18-ui] #app .m18-language-slot #tedyMobileLanguageFixed{position:static!important;inset:auto!important;transform:none!important;margin:0!important;padding:0!important;width:100%!important;z-index:auto!important}
html[data-m18-ui] #app .m18-language-slot select{height:43px!important;min-height:43px!important;width:100%!important;max-width:100%!important;margin:0!important;font-size:12px!important;padding:5px 4px!important;border-radius:12px!important;border:1px solid var(--m18-gold2)!important;background:#003324!important;color:#fff4d9!important}
html[data-m18-ui] #app .tedy-r526-language-row{display:none!important}
/* Reversed by the runtime when the sidebar closes, and never modifies route history. */
html[data-m18-ui] #sidebar{scrollbar-width:thin;scrollbar-color:#bb934c #061c14;overscroll-behavior:contain;touch-action:pan-y;-webkit-overflow-scrolling:touch;scroll-behavior:auto;background:linear-gradient(180deg,#002818 0%,#001a12 100%);border-right:1px solid var(--m18-edge)}
html[data-m18-ui] #sidebar .brand{border-bottom:1px solid var(--m18-edge)}
html[data-m18-ui] #sidebar .nav-group-title{font-size:10px;color:#d4b973;letter-spacing:.025em;padding:15px 12px 6px}
html[data-m18-ui] #sidebar .nav-btn{margin:2px 0;min-height:44px;border:1px solid transparent;border-radius:11px;transform:none!important;transition:background-color .12s ease,border-color .12s ease;color:#e4eee7}
html[data-m18-ui] #sidebar .nav-btn.active{border-color:var(--m18-edge);background:#124931;color:#fff8e9}
html[data-m18-ui] #sidebar .nav-btn .label{font-size:12px;line-height:1.35}
html[data-m18-ui] #sidebar .m18-correction-entry{margin:12px 6px;padding:11px 9px;width:calc(100% - 12px);min-height:44px;border:1px solid var(--m18-gold2);border-radius:11px;color:var(--m18-gold);background:#0b3525;display:flex;gap:9px;align-items:center;text-align:left;font-weight:700}
html[data-m18-ui] .m18-menu-shade{position:fixed;inset:0;z-index:108;background:#00130cb3;opacity:0;visibility:hidden;pointer-events:none;transition:opacity .14s linear,visibility .14s linear}
html[data-m18-ui].m18-menu-open .m18-menu-shade{opacity:1;visibility:visible;pointer-events:auto}
html[data-m18-ui].m18-menu-open,html[data-m18-ui].m18-menu-open body{overflow:hidden!important;overscroll-behavior:none!important}
@media(max-width:900px){
 html[data-m18-ui] #app #sidebar{position:fixed!important;left:0!important;top:0!important;width:min(84vw,315px)!important;height:100dvh!important;max-height:100dvh!important;overflow-y:auto!important;overflow-x:hidden!important;z-index:110!important;transform:translate3d(-105%,0,0)!important;transition:transform .17s cubic-bezier(.2,.7,.3,1)!important;box-shadow:none!important;contain:layout style}
 html[data-m18-ui] #app #sidebar.open{transform:translate3d(0,0,0)!important;box-shadow:8px 0 24px #0008!important}
 html[data-m18-ui] #app .topbar-title{display:none!important}
 html[data-m18-ui] #app .mobile-bottom{z-index:55;background:#002017f2;border-top:1px solid var(--m18-edge)}
}
/* Dashboard first viewport: ONLY ERP timestamp, brand icon + exact brand name, and the approved child photo. */
html[data-m18-ui] #main.m18-owner-dashboard{padding-top:0!important}
html[data-m18-ui] #main.m18-owner-dashboard>.page-head,
html[data-m18-ui] #main.m18-owner-dashboard>section.card.hero,
html[data-m18-ui] #main>[data-m17-toolbar]{display:none!important}
html[data-m18-ui] #main .m18-welcome{box-sizing:border-box;min-height:calc(100svh - 108px);min-height:calc(100dvh - 108px);display:flex;flex-direction:column;align-items:center;justify-content:space-evenly;gap:7px;padding:11px 5px 17px;background:radial-gradient(ellipse at 48% 24%,#0a392718,transparent 58%);max-width:680px;margin:0 auto 24px}
html[data-m18-ui] #main .m18-clock{font-size:clamp(10px,2.75vw,12px);line-height:1.4;letter-spacing:0;color:#e7d299;background:#0632237d;border:1px solid #d6ab585a;border-radius:100px;max-width:100%;padding:6px 11px;text-align:center;white-space:normal;font-weight:600;box-shadow:0 1px 12px #0003}
html[data-m18-ui] #main .m18-brand-symbol{display:block;max-width:100%;width:auto;height:clamp(46px,12svh,81px);filter:drop-shadow(0 5px 6px rgba(225,175,70,.18));object-fit:contain}
html[data-m18-ui] #main .m18-brand-title{margin:1px auto 5px;font-size:clamp(18px,5.1vw,32px);line-height:1.35;letter-spacing:0;text-align:center;font-weight:800;color:#f2ce7e;max-width:100%;text-shadow:0 3px 9px #000a}
html[data-m18-ui] #main .m18-brand-title span{display:block}
html[data-m18-ui] #main .m18-line{height:1px;width:90%;background:linear-gradient(90deg,transparent,#daa84b,#ffe7a7,#daa84b,transparent);flex:none}
html[data-m18-ui] #main .m18-photo{flex:0 1 auto;display:block;max-width:min(100%,58svh,510px);margin:3px auto 0;min-height:0;border-radius:clamp(15px,4vw,26px);overflow:hidden;box-shadow:0 10px 35px #0007,0 0 0 1px #dcb86666;aspect-ratio:1 / 1}
html[data-m18-ui] #main .m18-photo img{display:block;width:100%;height:100%;object-fit:contain}
html[data-m18-ui] #main .m18-scroll-tip{flex:none;display:grid;place-items:center;width:38px;height:32px;border:0;background:none;color:#e8bc63;font-size:27px;line-height:1;cursor:pointer;touch-action:manipulation}
/* The entire existing business dashboard remains below; no fake KPIs and no destructive hiding of workflows. */
html[data-m18-ui] #main.m18-owner-dashboard>.grid{scroll-margin-top:78px}
html[data-m18-ui] #main:not(.m18-owner-dashboard)>.page-head>div>p{display:none!important}
html[data-m18-ui] #main .page-head h1{font-size:clamp(19px,4.7vw,29px)!important;line-height:1.35}
html[data-m18-ui] #main .card,html[data-m18-ui] #main .kpi{border-color:#ba97544c;background:linear-gradient(150deg,#063125,#041f17);box-shadow:0 7px 24px #0003;border-radius:17px}
html[data-m18-ui] #main .kpi-label{color:#d4dcca;font-weight:700}
html[data-m18-ui] #main .kpi-value{color:#f6d88f;font-weight:800;font-variant-numeric:tabular-nums}
html[data-m18-ui] #main .kpi-note{color:#bdd4c3}
html[data-m18-ui] #main :is(.btn,.nav-btn,button){touch-action:manipulation}
html[data-m18-ui] #main :is(.btn.primary){border-color:#6cb78a;background:linear-gradient(130deg,#0ca76e,#007b52);color:#fafff8}
html[data-m18-ui] #main .btn:active{transform:none!important}
html[data-m18-ui] #main :is(.table-wrap,.tf-r526-tablewrap){overscroll-behavior-x:contain;scrollbar-width:thin}
html[data-m18-ui] #modalRoot :is(.modal,.modal-backdrop){overscroll-behavior:contain}
/* M17 owner correction modal consistent with the rest of the luxury UI; not white. */
html[data-m18-ui] .tedy-m17-overlay .tedy-m17-panel{background:#062519!important;color:#f2f9ef!important;border:1px solid #c5a15db3!important;border-radius:19px!important}
html[data-m18-ui] .tedy-m17-overlay .tedy-m17-header{background:#003c29!important;color:#f5d99a!important}
html[data-m18-ui] .tedy-m17-overlay .tedy-m17-note{background:#143e2d!important;color:#f8f8ed!important;border-color:#b99957!important}
html[data-m18-ui] .tedy-m17-overlay .tedy-m17-card{background:#0d3526!important;color:#f3f6ec!important;border-color:#a98c565c!important}
html[data-m18-ui] .tedy-m17-overlay .tedy-m17-card small{color:#b8d4c3!important}
html[data-m18-ui] .tedy-m17-overlay :is(input,select,textarea){background:#092e21!important;color:#f6f9f2!important;border:1px solid #8b9d76!important;border-radius:10px!important}
html[data-m18-ui] .tedy-m17-overlay button{border-radius:11px!important}
html[data-m18-ui] .tedy-m17-overlay button.primary{background:#0a8559!important;color:white!important}
@media(max-width:380px){html[data-m18-ui] #app .topbar{gap:4px!important;padding:5px 7px!important}html[data-m18-ui] #app .avatar{width:38px;min-width:38px;height:38px}html[data-m18-ui] #app button.menu-toggle{width:39px;height:40px}html[data-m18-ui] #main .m18-welcome{min-height:calc(100dvh - 104px)}html[data-m18-ui] #main .m18-photo{max-width:min(100%,52svh)}}
@media(prefers-reduced-motion:reduce){html[data-m18-ui] #sidebar,html[data-m18-ui] .m18-menu-shade{transition:none!important}html[data-m18-ui] *{scroll-behavior:auto!important}}
@media print{html[data-m18-ui] #main .m18-welcome,html[data-m18-ui] .m18-menu-shade{display:none!important}html[data-m18-ui] #main.m18-owner-dashboard>.page-head{display:flex!important}}
