/* App navigation and notification surfaces share the existing TeamIT palette. */
.mobile-only,.mobile-nav,.mobile-brand{display:none}
.sidebar nav{min-height:0;overflow-y:auto;overscroll-behavior:contain;flex:1;padding-right:5px}
.sidebar-bottom{flex:none}
.sidebar .nav-item{min-height:43px}
.notification-bell{position:relative;width:36px;height:36px}
.unread-badge{display:inline-flex;align-items:center;justify-content:center;min-width:18px;height:18px;border-radius:6px;background:#d8edb7;color:#284b36;font:600 9px system-ui,sans-serif;padding:0 4px;margin-left:auto}
.notification-bell .unread-badge{position:absolute;top:-2px;right:-4px;background:#a64f44;color:#fff;min-width:15px;height:15px;font-size:8px;border:2px solid #f9faf6;padding:0 3px}
.notification-summary{display:flex;gap:36px;align-items:center;padding:25px 28px;background:#eaf0e1;border:1px solid #e0e8d5;border-radius:10px;margin-bottom:20px}
.notification-summary>div{display:flex;flex-direction:column;gap:10px}
.notification-summary span{font-size:8px;letter-spacing:1.2px;color:#839578}
.notification-summary strong{font-size:29px;font-weight:500;letter-spacing:-.8px}
.notification-summary>p{margin-left:auto;font-size:10px;color:#6e8862}
.notification-summary>p.monitor-stale{color:#a08351}
.active-incidents{display:flex;flex-wrap:wrap;gap:10px;margin-bottom:20px}
.incident-chip{padding:11px 16px;border:1px solid #e9cec7;color:#a15e57;background:#fbefea;border-radius:7px;font-size:11px;text-align:left}
.notification-panel .panel-heading{padding:18px 24px}
.notification-panel .segmented button{font-size:10px;padding:8px 12px}
.notification-item{display:flex;align-items:flex-start;gap:17px;padding:25px 26px;border-bottom:1px solid #edf0e8}
.notification-item.is-unread{background:#fafcf6}
.notification-symbol{display:grid;place-items:center;width:40px;height:40px;border-radius:11px;flex:none}
.incident-down{color:#b06f60;background:#f8e9e3}
.incident-up{color:#6e925c;background:#eaf2e0}
.notification-content{min-width:0;flex:1}
.notification-title{display:flex;justify-content:space-between;align-items:baseline;gap:16px;margin:2px 0 10px}
.notification-title h3{font-size:14px;font-weight:550;letter-spacing:-.15px}
.notification-title time{font:10px ui-monospace,monospace;color:#99a593;white-space:nowrap}
.notification-content p{font-size:11px;color:#8b9b81;line-height:1.9}
.notification-actions{display:flex;align-items:center;justify-content:space-between;gap:10px;margin-top:17px}
.notification-read-state{font-size:9px;color:#a4ae9c}
.is-unread .notification-read-state{color:#71905b}
.notification-actions .text-button{font-size:10px;padding:6px 0}
.notification-empty{display:flex;flex-direction:column;align-items:center;text-align:center;padding:65px 24px;color:#899b7c}
.notification-empty>.icon{width:31px;height:31px;margin-bottom:20px;stroke-width:1.2}
.notification-empty h3{font-size:18px;font-weight:500;color:#5d7852;margin-bottom:12px}
.notification-empty p{font-size:12px;line-height:1.9;max-width:340px}
.notification-more{display:flex;justify-content:center;padding:0 20px}
.notification-more:has(button:not([hidden])){padding:22px}
.notification-policy{font-size:10px;color:#9caa92;line-height:1.9;margin:22px 0}
.app-settings-grid{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:22px;margin-bottom:22px}
.app-settings-card{display:flex;flex-direction:column;align-items:flex-start;background:#fff;border:1px solid var(--line);border-radius:11px;padding:30px;min-width:0}
.setting-icon{display:grid;place-items:center;width:48px;height:48px;border-radius:12px;background:#edf3e5;color:#7f9d68;margin-bottom:25px}
.setting-icon .icon{height:24px;width:24px;stroke-width:1.4}
.app-settings-card h2{font-size:21px;letter-spacing:-.5px;font-weight:500;margin-bottom:14px}
.app-settings-card>p{color:#91a084;font-size:12px;line-height:1.9;margin-bottom:20px}
.app-settings-card>.pill{margin-bottom:23px}
.app-settings-card>.button{min-height:44px}
.app-settings-card>.setting-help{margin:17px 0 0;font-size:10px;color:#9baa8d}
.install-instructions{margin-top:22px;padding:19px;background:#f5f8ef;border-radius:8px;font-size:12px;color:#7b906b;line-height:1.9}
.install-instructions ol{padding-left:19px;margin:10px 0 0}
.install-instructions li+li{margin-top:10px}
.settings-devices{margin-bottom:22px}
.push-device{display:flex;align-items:center;gap:15px;padding:22px 25px;border-bottom:1px solid var(--line)}
.push-device:last-child{border:0}
.push-device>.icon{color:#91aa7b;flex:none}
.push-device>div{min-width:0;flex:1}
.push-device strong{display:block;font-size:12px;font-weight:500;word-break:break-word}
.push-device small{display:block;font-size:10px;color:#9ca98e;line-height:1.8;margin-top:7px}
.push-device .button{font-size:10px;padding:10px 14px}
.devices-empty{padding:27px 25px;color:#91a084;font-size:12px;line-height:1.9}
.alert-rules{display:flex;align-items:flex-start;gap:16px;padding:26px;border:1px solid #e2e9d8;border-radius:10px;background:#eff3e7}
.alert-rules>.icon{flex:none;color:#89a172}
.alert-rules h3{font-size:13px;font-weight:550;margin-bottom:10px}
.alert-rules p{font-size:11px;color:#8c9e7c;line-height:1.9;max-width:790px}
html.menu-open{overflow:hidden}
.mobile-menu{margin:auto 0 0;padding:0;width:100%;max-width:100%;max-height:90dvh;border:0;border-radius:20px 20px 0 0;color:var(--ink);background:#fff;overflow:auto;padding-bottom:env(safe-area-inset-bottom)}
.mobile-menu::backdrop{background:#17372f55;backdrop-filter:blur(3px)}
.mobile-menu .drawer-heading{padding:24px}
.mobile-menu-user{display:flex;flex-direction:column;gap:7px;padding:24px;border-bottom:1px solid var(--line)}
.mobile-menu-user strong{font-size:15px;font-weight:550}
.mobile-menu-user span{font-size:11px;color:#8ea081}
.mobile-menu nav{display:flex;flex-direction:column;padding:10px 12px 16px}
.mobile-menu nav button{display:flex;align-items:center;gap:15px;background:none;border:0;border-radius:9px;text-align:left;padding:16px 12px;min-height:52px;color:#6f8762;font-size:14px}
.mobile-menu nav button:hover{background:#f3f7ed}
#mobile-logout{color:#b26e61}

@media(max-width:1020px){
  .app-settings-grid{gap:16px}
  .app-settings-card{padding:24px}
  .app-settings-card h2{font-size:19px}
  .notification-summary{gap:24px}
}
@media(max-width:900px){
  :root{font-size:15px}
  .sidebar{display:none}
  .main-content{margin-left:0;grid-column:auto}
  .shell{display:block;min-height:100dvh}
  .mobile-only{display:flex}
  .topbar{position:sticky;top:0;z-index:12;min-height:64px;height:auto;padding:calc(10px + env(safe-area-inset-top)) max(18px,env(safe-area-inset-right)) 10px max(18px,env(safe-area-inset-left));gap:12px;background:#f9faf6f5;backdrop-filter:blur(14px)}
  .mobile-brand{display:inline-flex;height:34px;width:34px;font-size:28px;border-radius:10px;flex:none}
  .breadcrumb{flex:1;min-width:0;font-size:12px;color:#49644c;overflow:hidden;white-space:nowrap}
  .breadcrumb>span{display:none}
  .breadcrumb{font-size:0;gap:0}
  .breadcrumb strong{font-size:12px;overflow:hidden;text-overflow:ellipsis}
  .topbar-right{gap:7px}
  .topbar-right>#connection-state,.topbar-right>.mono,.topbar-right>.topbar-divider,.topbar-right>.small-avatar{display:none}
  .topbar .icon-button{width:40px;height:40px}
  .topbar .icon-button .icon{height:21px;width:21px}
  .notification-bell .unread-badge{top:0;right:0}
  .mobile-nav{position:fixed;inset:auto 0 0;z-index:15;display:flex;justify-content:space-around;gap:2px;padding:8px max(8px,env(safe-area-inset-right)) calc(8px + env(safe-area-inset-bottom)) max(8px,env(safe-area-inset-left));background:#f9faf6f5;border-top:1px solid #e0e8d8;backdrop-filter:blur(15px)}
  .mobile-nav button{display:flex;position:relative;flex:1;min-height:48px;flex-direction:column;align-items:center;justify-content:center;gap:6px;background:none;border:0;border-radius:10px;font-size:9px;color:#95a18b;padding:6px 2px}
  .mobile-nav button.active{color:#3d674a;background:#e8efdd}
  .mobile-nav .icon{width:20px;height:20px;stroke-width:1.5}
  .mobile-nav .unread-badge{position:absolute;left:calc(50% + 3px);top:2px;margin:0;height:15px;min-width:15px;border:2px solid #f9faf6;font-size:7px;background:#a85a4c;color:#fff}
  .content,.topology-view .content{padding:24px max(16px,env(safe-area-inset-right)) calc(92px + env(safe-area-inset-bottom)) max(16px,env(safe-area-inset-left));max-width:100%}
  .page-heading,.topology-view .page-heading{margin-bottom:24px;gap:14px}
  h1,.topology-view .page-heading h1{font-size:25px;letter-spacing:-.65px;line-height:1.3}
  .page-heading p,.topology-view .page-heading p{font-size:12px;line-height:1.8;margin-top:9px;max-width:none}
  .page-heading .eyebrow{font-size:8px;letter-spacing:1.4px;margin-bottom:13px}
  .topology-view .page-heading p{font-size:11px;max-width:290px}
  .button{min-height:44px;padding:12px 16px;font-size:12px}
  .page-heading>.button{width:100%;justify-content:center;margin-top:18px}
  .topology-view .page-heading>.button{width:42px;height:42px;min-height:42px;min-width:42px;margin:0;padding:11px;font-size:0}
  .text-button{font-size:11px;min-height:40px;white-space:normal;text-align:left}
  .icon-button{min-width:40px;min-height:40px}
  label{font-size:13px}
  input,select{font-size:16px;min-height:48px;padding:13px 14px}
  input::placeholder{font-size:13px}
  .notice{font-size:12px;padding:15px 16px;line-height:1.9}
  #page-topology>.graph-panel{height:max(520px,calc(100dvh - var(--graph-top,180px) - 92px - env(safe-area-inset-bottom)));margin-bottom:20px}
  #page-topology .graph-panel>.panel-heading{padding:16px;min-height:66px;gap:8px;flex-wrap:wrap}
  #page-topology .graph-panel .panel-title{font-size:12px}
  #page-topology .graph-caption{display:none}
  #page-topology #network-graph{height:calc(100% - 43px)}
  #page-topology .graph-bottom{left:14px;right:14px;bottom:10px}
  #page-topology .legend{font-size:8px;gap:9px}
  #page-topology .legend .dot{height:5px;width:5px}
  #page-topology .graph-footnote{padding:13px 16px;font-size:9px}
  .zoom-controls{border-radius:8px}
  .zoom-controls button{min-width:34px;height:34px;font-size:18px;padding:0}
  .zoom-controls span{font-size:9px;padding:0 4px}
  .segmented button,#page-topology .segmented button{min-height:34px;font-size:9px;padding:7px 9px}
  #network-graph .svg-title{font-size:17px}
  #network-graph .svg-small{font-size:11px}
  #network-graph .svg-label{font-size:10px;letter-spacing:1px}
  #page-topology .bottom-grid{display:block}
  .metrics-grid{gap:12px}
  .metric{padding:18px 15px;min-height:130px}
  .metric-top{font-size:8px;line-height:1.6}
  .metric-value{font-size:29px;margin-top:18px}
  .metric p{font-size:9px;line-height:1.8}
  .metric .sparkline{display:none}
  .metric-value.text-value{font-size:24px}
  .panel-heading,.table-panel .panel-heading{padding:20px;min-height:64px}
  .table-panel .panel-heading>.button{margin-top:17px;width:100%;justify-content:center}
  .table-panel table,.table-panel tbody,.table-panel tr,.table-panel td{display:block;width:100%;white-space:normal}
  .table-panel thead{display:none}
  .table-panel tbody tr{padding:15px 20px;border-bottom:1px solid var(--line)}
  .table-panel tbody tr:last-child{border-bottom:0}
  .table-panel td{display:flex;align-items:center;justify-content:space-between;gap:18px;border:0;padding:9px 0;font-size:12px;text-align:right;line-height:1.6}
  .table-panel td::before{content:attr(data-label);font:10px/1.6 system-ui,sans-serif;letter-spacing:.3px;color:#9ba98f;flex:none;text-align:left}
  .table-panel td:has(.table-node){padding-top:0;padding-bottom:13px}
  .table-panel td:has(.table-node)::before{display:none}
  .table-node{text-align:left;gap:12px}
  .table-node strong{font-size:14px}
  .table-node small{font-size:11px;overflow-wrap:anywhere}
  .mini-avatar{height:36px;width:36px;font-size:10px}
  .pill,.inspector-header .pill{font-size:10px}
  .table-panel td .pill{font-size:10px;padding:6px 9px}
  .table-panel .empty-row{justify-content:center;text-align:center;padding:20px 0}
  .node-grid{gap:18px}
  .node-card{padding:23px}
  .node-card .inspector-header h2{font-size:22px}
  .node-card .inspector-header small{font-size:11px}
  .node-card .inspector-domain{font-size:12px;padding:13px}
  .node-card .detail-row{font-size:12px;padding:14px 0;gap:16px;line-height:1.7}
  .node-card .detail-row dd{overflow-wrap:anywhere;max-width:65%}
  .node-card .detail-row dd.mono{font-size:11px}
  .node-card .resource-line{font-size:11px}
  .node-card .inspector-note{font-size:11px;line-height:1.9}
  .node-card-actions{flex-wrap:wrap;gap:9px;margin-top:20px}
  .node-card-actions>.button{flex:1;justify-content:center;font-size:11px}
  .node-drawer,.mobile-menu{padding-bottom:env(safe-area-inset-bottom)}
  .node-drawer .drawer-heading{padding-top:calc(22px + env(safe-area-inset-top))}
  .node-drawer .detail-row{font-size:13px}
  .node-drawer .inspector-domain{font-size:13px}
  .node-drawer .inspector-header small{font-size:12px}
  .node-drawer .inspector-note{font-size:13px}
  .app-settings-grid{grid-template-columns:1fr;gap:18px}
  .app-settings-card{padding:27px 24px}
  .app-settings-card h2{font-size:22px;line-height:1.4}
  .app-settings-card>p{font-size:13px}
  .app-settings-card>.button{width:100%;justify-content:center;font-size:13px}
  .app-settings-card>.setting-help{font-size:12px}
  .install-instructions{font-size:13px;padding:17px}
  .push-device{padding:21px 20px;gap:12px;align-items:flex-start;flex-wrap:wrap}
  .push-device>div{flex-basis:70%}
  .push-device strong{font-size:13px}
  .push-device small{font-size:12px}
  .push-device .button{margin-left:31px;font-size:11px;min-height:40px}
  .devices-empty{font-size:13px;padding:23px 20px}
  .alert-rules{padding:22px 20px}
  .alert-rules h3{font-size:14px;line-height:1.5}
  .alert-rules p{font-size:12px}
  .notification-summary{display:grid;grid-template-columns:1fr 1fr;gap:23px;padding:24px;margin-bottom:18px}
  .notification-summary span{font-size:8px}
  .notification-summary strong{font-size:32px}
  .notification-summary>p{grid-column:1/-1;margin:0;font-size:11px}
  .notification-panel .panel-heading{display:flex;align-items:center;justify-content:space-between;flex-wrap:wrap;gap:13px;padding:16px}
  .notification-panel .segmented{margin:0}
  .notification-panel .segmented button{font-size:10px}
  .notification-panel .panel-heading>.button{font-size:11px;width:auto;margin:0;padding:10px 12px}
  .notification-panel .panel-heading>.button .icon{height:15px;width:15px}
  .notification-item{padding:24px 20px;gap:13px}
  .notification-symbol{width:34px;height:34px;border-radius:9px}
  .notification-symbol .icon{height:18px;width:18px}
  .notification-title{display:block;margin-top:0}
  .notification-title h3{font-size:15px;line-height:1.5;margin-bottom:8px}
  .notification-title time{font-size:10px}
  .notification-content p{font-size:12px;line-height:1.9}
  .notification-actions{flex-wrap:wrap;margin-top:14px;gap:6px}
  .notification-read-state{font-size:10px}
  .notification-actions .text-button{font-size:11px}
  .notification-policy{font-size:12px;line-height:1.9}
  .security-card h3{font-size:16px}
  .security-card p,.role-guide p{font-size:12px}
  .security-card .pill{font-size:10px}
  .settings-actions>.button{width:100%;justify-content:center;font-size:13px}
  .role-guide h3{font-size:16px}
  #modal{padding:23px;width:calc(100vw - 28px);max-width:490px;max-height:calc(100dvh - 32px);overflow:auto}
  #modal-description{font-size:13px}
  .modal-footer{gap:8px;flex-wrap:wrap}
  .modal-footer>.button{flex:1;justify-content:center}
  .auth-story{padding:22px 24px}
  .auth-form-wrap{padding:35px 24px calc(30px + env(safe-area-inset-bottom))}
  .auth-form-card>.muted{font-size:13px}
  .auth-form-card .button{font-size:14px;min-height:48px}
  .auth-form-card .auth-policy p{font-size:11px}
  .toast{left:50%;bottom:calc(85px + env(safe-area-inset-bottom));max-width:calc(100vw - 32px);width:max-content;font-size:12px;line-height:1.7}
  .page-footer{margin-top:25px;padding-bottom:0;font-size:10px}
}
@media(max-width:360px){
  .content,.topology-view .content{padding-left:12px;padding-right:12px}
  .topbar{padding-left:14px;padding-right:14px;gap:9px}
  .notification-panel .panel-heading>.button{width:100%;justify-content:center}
  .metrics-grid{gap:9px}
  .metric{padding:15px 12px}
  .app-settings-card{padding:24px 20px}
}
