/* Daily-work refinement: one navigation, legible type, actions above the fold. */
body{font-size:14px}
.topbar{grid-template-columns:minmax(0,1fr) auto;gap:16px;padding:22px 24px 16px;min-height:86px;align-items:center}
.topbar .ph{grid-column:1;grid-row:1;padding:0;min-width:0;gap:5px}
.topbar .ph .h-page{font-size:25px;line-height:1.25;letter-spacing:-.8px;font-weight:600}
.topbar .ph .sub{font-size:12px;line-height:1.5}
.topbar .controls{grid-column:2;grid-row:1;min-width:0}
.topbar .controls>.btn:first-child{font-size:13px;padding:0 12px;width:auto;gap:8px;border:1px solid var(--rule)}
.topbar .controls>.btn:first-child>span{display:inline;font-size:11px;color:var(--ink-meta)}
body[data-page=dashboard] .topbar .ph,body[data-page=schedule] .topbar .ph{display:flex}
.page{padding:8px 24px 28px;gap:18px}.view{gap:18px}
.btn,.input,.select,.dd-toggle{font-size:13px;border-radius:10px}
.btn{font-weight:600}.input:focus,.select:focus,textarea:focus{outline:2px solid #357747;outline-offset:1px}
.studio-page-head{align-items:center;gap:16px;margin:0 0 18px}
.studio-breadcrumb{display:none}.studio-page-head h1{font-size:22px;letter-spacing:-.65px}
.studio-page-head p{margin-top:5px;font-size:12px}.studio-heading-dot{display:none}
.studio-metrics{gap:16px;margin-bottom:18px}
.studio-card{padding:20px;border:1px solid #e8ebe6;border-radius:18px}
.studio-card-label{font-size:13px;line-height:1.4}.studio-arrow{width:28px;height:28px}
.studio-number{font-size:32px;line-height:1.2;letter-spacing:-1px;margin:8px 0}
.studio-under{font-size:12px;gap:10px;flex-wrap:wrap}
.studio-spark{margin-top:12px}.studio-spark svg{height:52px}
.studio-bars{height:52px;margin-top:14px}
.studio-axis{font-size:11px;margin-top:6px}
.studio-day-number{padding:4px 0 12px;gap:12px}.studio-day-number .studio-number{font-size:42px}
.studio-day-bottom{padding-top:12px;gap:16px}.studio-day-bottom a>b{font-size:20px}
.studio-day-bottom a>span{font-size:12px}
.studio-main-grid{gap:16px;grid-template-columns:minmax(0,1.7fr) minmax(290px,1fr)}
.studio-main-stack{gap:16px}.studio-main-stack>.studio-task-card{order:-1}
.studio-card h2{font-size:16px;letter-spacing:-.3px}.studio-card-head{margin-bottom:12px}
.studio-card-head p,.studio-card>p{font-size:12px}
.studio-task{padding:12px 0;gap:12px}.studio-task b{font-size:14px;font-weight:600}
.studio-task span,.studio-task time{font-size:12px;line-height:1.5}
.studio-attention>a{padding:13px 0}.studio-attention>a b{font-size:13px}.studio-attention>a small{font-size:12px}
.studio-funnel>a{font-size:13px}.studio-funnel>a:last-of-type{margin-bottom:12px}
.studio-week button{min-height:72px;border-radius:10px;padding:8px 4px}
.studio-visit-person b,.studio-visit-services{font-size:13px}.studio-visit-person span{font-size:12px}
.studio-empty{min-height:140px;padding:20px 12px}.studio-empty>p{font-size:12px}
.work-list-tools{display:flex;align-items:center;justify-content:space-between;gap:12px;flex-wrap:wrap;margin:0 0 16px}
.work-queues{display:flex;gap:4px;align-items:center;flex-wrap:wrap}
.work-queues button{border:1px solid transparent;border-radius:8px;background:transparent;min-height:36px;padding:7px 12px;font:500 13px/1.3 var(--f-body);color:#566058;cursor:pointer;white-space:nowrap}
.work-queues button:hover{background:#edf2e9;color:#172118}
.work-queues button[aria-pressed=true]{background:#e7f2e2;color:#244a2d;border-color:#cfe0c9;font-weight:600}
.work-queues button:focus-visible{outline:2px solid #357747;outline-offset:2px}
.work-list-options{display:flex;gap:8px;min-width:0}.work-list-options .select{width:auto;max-width:230px;height:36px;min-height:36px}
.work-no-results{display:flex;flex-direction:column;align-items:center;gap:12px;padding:48px 20px;border:1px solid var(--rule);border-radius:16px;background:#fff;text-align:center}
.work-no-results b{font-size:17px}.work-no-results span{color:#626a64}
html.ui-amo .amo-bar{margin-bottom:12px;gap:10px}
html.ui-amo .amo-filter{border:1px solid #dce2d9;border-radius:10px}
html.ui-amo .amo-filter input{font-size:13px;min-height:40px}
html.ui-amo .amo-filter-btn{width:40px;min-height:40px}
html.ui-amo .amo-filter-panel{border:1px solid #dce2d9;border-radius:12px;box-shadow:0 10px 35px #1721181c}
html.ui-amo .amo-total{font-size:12px;color:#566058}
html.ui-amo .amo-kanban{gap:14px;margin-top:0;scrollbar-width:thin;scrollbar-color:#aeb8ac transparent}
html.ui-amo .amo-col-head{padding:10px 10px 13px;min-height:64px}
html.ui-amo .amo-col-head>b{font-size:13px}.amo-col-head span{font-size:12px}
html.ui-amo .amo-card{border-radius:12px;padding:14px;border:1px solid #e4e8df;margin-bottom:10px;box-shadow:0 1px 2px #14221704}
html.ui-amo .amo-card:hover{border-color:#afc7a9;box-shadow:0 3px 10px #18281909}
html.ui-amo .amo-card:focus-visible{outline:2px solid #357747;outline-offset:2px}
html.ui-amo .ac-name{font-size:14px;font-weight:600}.ac-sub{font-size:12px}.ac-top time{font-size:11px}
html.ui-amo .amo-deal-fields .info-row{font-size:13px;line-height:1.6;padding-top:9px;padding-bottom:9px}
html.ui-amo .amo-deal-fields .info-row>label{font-size:12px;color:#606a60}
html.ui-amo .amo-deal-fields .info-row .inline{font-size:13px;line-height:1.5;min-height:30px}
html.ui-amo .amo-deal-head h2{font-size:18px}
html.ui-amo .amo-stage-select{font-size:13px}
.deal-feed-event b{font-size:13px}.deal-feed-event p{font-size:13px;line-height:1.6}.deal-feed-event small{font-size:11px;color:#687266}
.dp-msg{font-size:14px;line-height:1.6}.dp-msg.out,.dp-msg.out a{color:#1d3825}
.amo-widget-tile{font-size:13px}.amo-widget-tile em,.amo-widget-tile span{font-size:12px;line-height:1.6}
.chats-layout{grid-template-columns:310px minmax(0,1fr);border:1px solid #e1e6dd;border-radius:16px}
.chats-layout .chats-context{display:none}.chats-list{width:auto;min-width:0}
.chats-list-head{padding:18px 16px 10px}.chats-list-head b{font-size:15px}.chats-list-head span{font-size:12px}
.chats-list-search{padding:0 12px 10px}.chats-list-search input{font-size:13px;height:40px;min-height:40px}
.work-chat-filters{padding:0 12px 12px;border-bottom:1px solid var(--rule);display:flex;flex-direction:column;gap:8px;flex:none}
.work-chat-filters .work-queues{gap:2px}.work-chat-filters .work-queues button{padding:7px 9px;font-size:12px;flex:1}
.work-chat-filters .select{width:100%;height:34px;min-height:34px;font-size:12px;background:#f7f9f5}
.chat-list-row{padding:13px 14px;gap:11px;min-height:76px}.chat-list-row .av{width:34px;height:34px;min-width:34px;border-radius:50%;font-size:12px}
.chat-list-main b{font-size:13px;line-height:1.5}.chat-list-main>span{font-size:12px;line-height:1.5}.chat-list-meta time{font-size:11px;white-space:nowrap}
.chat-list-row.active{background:#edf6e7;box-shadow:inset 3px 0 #365e36}
.chat-conversation-head{min-height:72px;padding:13px 20px;gap:12px}.chat-conversation-head>div b{font-size:15px}.chat-conversation-head>div span{font-size:12px}
.chat-conversation-body{background:#f7f9f5;padding:20px}
.chat-conversation-compose{padding:12px 16px;gap:10px;align-items:flex-end}
.chat-conversation-compose textarea.input{height:64px;min-height:64px;max-height:180px;resize:vertical;padding:10px 12px;font:400 14px/1.5 var(--f-body);color:#172118;background:#fff}
.chat-conversation-compose .btn,.chat-conversation-compose .chat-compose-icon{height:40px;min-height:40px;border-radius:10px;flex:none}
body[data-page=chats] .page{padding-bottom:18px}
.pipe-table td,.pipe-table .record-link{font-size:13px}.pipe-table th{font-size:12px}
@media(min-width:1700px){.studio-card{padding:22px}.chats-layout{grid-template-columns:350px minmax(0,1fr)}}
@media(min-width:761px) and (max-width:1100px){
 .topbar{padding:18px 18px 12px}.page{padding:8px 18px 24px}.topbar .controls>.btn:first-child>span{display:none}
 .studio-main-grid{grid-template-columns:minmax(0,1fr)}.studio-main-grid>aside{display:grid;grid-template-columns:1fr 1fr}
 .studio-metrics{grid-template-columns:1fr 1fr}.studio-day{grid-column:1/-1}
 .chats-layout{grid-template-columns:285px minmax(0,1fr)}.work-list-options{flex-wrap:wrap}
 .topbar .controls>.btn-primary{font-size:13px;width:auto;padding:0 12px}
}
@media(max-width:760px){
 .topbar{padding:16px 14px 12px;gap:10px;min-height:70px}.topbar .ph .h-page,body[data-page=dashboard] .topbar .ph .h-page{font-size:22px}
 .topbar .controls{gap:6px}.topbar .controls>.btn:first-child{display:flex;width:36px;font-size:0;padding:0;gap:0}.topbar .controls>.btn:first-child>span{display:none}
 .topbar .controls>.btn-primary{font-size:0;width:36px;padding:0}.page{padding:8px 14px 95px}
 .studio-page-head{gap:12px;align-items:flex-start;margin-bottom:16px}.studio-page-head h1{font-size:19px}.studio-page-head p{font-size:12px}
 .studio-period{width:100%;gap:6px}.studio-period .select{flex:1;min-width:0}
 .studio-metrics{grid-template-columns:1fr 1fr;gap:10px;margin-bottom:16px}.studio-metrics .studio-revenue{grid-column:1/-1}
 .studio-card{padding:16px;border-radius:14px}.studio-number{font-size:28px}.studio-day .studio-number{font-size:34px}
 .studio-day{grid-column:auto;display:block}.studio-day-number{gap:8px}.studio-day-icon{display:none!important}
 .studio-day-bottom{gap:7px;grid-template-columns:1fr}.studio-day-bottom a{display:flex;align-items:center;gap:7px}.studio-day-bottom a>b{font-size:17px}.studio-day-bottom a>span{font-size:11px}
 .studio-main-grid{grid-template-columns:1fr;gap:12px}.studio-main-grid>aside{display:flex}.studio-main-stack{gap:12px}
 .studio-card-head{gap:10px}.studio-card h2{font-size:15px}.studio-text-link{font-size:12px}
 .studio-week{gap:3px}.studio-week button{min-height:66px}.studio-week button b{font-size:18px}
 .work-list-tools{gap:10px;margin-bottom:10px}.work-queues{flex-wrap:nowrap;overflow-x:auto;max-width:100%;padding:2px 0 5px;scrollbar-width:thin}
 .work-queues button{font-size:12px;min-height:36px;padding:7px 10px}
 .work-list-options{width:100%}.work-list-options .select{flex:1;min-width:0;max-width:50%;font-size:12px}
 html.ui-amo .amo-bar{gap:8px}.amo-filter input{width:80px!important}.amo-filter-panel{max-width:calc(100vw - 32px)}
 .chats-layout{display:flex;border-radius:14px}.chat-conversation-head{padding:12px;min-height:64px}.chat-conversation-head>div b{font-size:14px}
 .chat-conversation-body{padding:12px}.chat-conversation-compose{padding:10px;gap:8px;flex-wrap:wrap}.chat-conversation-compose textarea.input{font-size:16px;flex:1;min-width:150px;height:70px;min-height:70px}
 .chat-conversation-compose .btn{font-size:12px;padding:8px 12px;margin-left:auto}
 .work-chat-filters .work-queues{overflow:visible;padding:0}.work-chat-filters .select{min-height:38px}
 .dp-msg{font-size:14px}.studio-chat-back{min-width:34px}
 body[data-page=chats] .page{padding:4px 10px calc(78px + env(safe-area-inset-bottom))}
 .input,.select,.dd-toggle,textarea{font-size:16px}
}

/* The legacy host owns view padding; override at the same specificity. */
#view-host>.view:not([hidden]){padding:8px 24px 24px;gap:16px}
#view-host>#view-dashboard:not([hidden]){gap:16px}
.studio-page-head,.studio-metrics{margin-bottom:0}
.studio-metrics .studio-card{padding:16px 20px}
.studio-chart-empty{height:62px;color:#626a64;font-size:12px}
html.ui-amo .amo-bar{padding-bottom:0;margin-bottom:0}
.work-list-tools{margin-bottom:0}
html.ui-amo .deal-card.amo-card{padding:12px 14px;border-radius:12px;margin-bottom:0;gap:5px}
html.ui-amo .amo-col .col-body{gap:9px}
body[data-page=pipeline] .main{height:100vh;height:100dvh;display:flex;flex-direction:column;overflow:hidden}
body[data-page=pipeline] .topbar{flex:none}
body[data-page=pipeline] #view-host{flex:1;min-height:0;overflow:hidden}
#view-host>#view-pipeline:not([hidden]){height:100%;min-height:0;overflow:auto}
html.ui-amo .amo-kanban{flex:1;min-height:240px;max-height:none;overflow-x:auto;overflow-y:hidden}
html.ui-amo .amo-kanban>.amo-col{height:100%;max-height:none;min-height:0}
html.ui-amo .amo-col-head{flex:none}
#view-host>#view-chats:not([hidden]){padding:8px 24px 18px;min-height:0}
@media(max-width:760px){
 #view-host>.view:not([hidden]){padding:4px 14px 90px;gap:14px}
 #view-host>#view-chats:not([hidden]){padding:4px 10px calc(78px + env(safe-area-inset-bottom))}
 #view-host>#view-pipeline:not([hidden]){padding-bottom:calc(78px + env(safe-area-inset-bottom))}
 .studio-metrics .studio-card{padding:14px}
 body[data-page=chats] #view-host{padding-bottom:0}
}

html.ui-amo .task-groups .amo-col{height:auto;max-height:none;flex:none}
/* Route visibility uses [hidden], not .active. Fill the actual remaining viewport. */
#view-host>#view-chats:not([hidden]){height:100%;flex:1;min-height:0}
.chats-page .chats-list-scroll{max-height:none}
#view-finance .hero,#view-finance .card{padding:20px;border-radius:18px}
#view-finance .studio-spark svg{height:95px}
#view-finance .fin-figure{margin-top:12px}
#view-finance .studio-fin-chart{margin-top:12px}
#view-customers td{font-size:13px;line-height:1.55;padding-top:13px;padding-bottom:13px}
#view-customers th{font-size:12px}
@media(max-width:760px){
 #view-finance .hero,#view-finance .card{padding:16px}
 #view-finance .studio-spark svg{height:78px}
 .studio-day-bottom a{justify-content:flex-start;text-align:left}
}

.amo-cmp-chat,.dp-chat-input{align-items:flex-end}
.amo-cmp-chat textarea#dp-chat-text,.dp-chat-input textarea#dp-chat-text{min-height:62px;height:62px;max-height:150px;resize:vertical;padding:10px 12px;font:400 14px/1.5 var(--f-body);color:#172118;background:#fff}
@media(max-width:760px){.amo-cmp-chat textarea#dp-chat-text,.dp-chat-input textarea#dp-chat-text{font-size:16px;min-width:140px}.amo-cmp-chat{gap:6px}}
