/* Reef CPO v4. Canonical theme values: app/design_tokens.py; neutral actions,
   purple brand/focus, semantic status colors. Loaded after each page stylesheet. */
@font-face{font-family:Inter;font-style:normal;font-weight:100 900;font-display:swap;src:url('/static/fonts/InterVariable.woff2') format('woff2')}
:root{--reef-bg:#171717;--reef-card:#262626;--reef-raised:#404040;--reef-sidebar:#404040;--reef-fg:#fff;--reef-muted:#d0d1d2;--reef-border:#757575;--reef-primary:#fff;--reef-on-primary:#171717;--reef-focus:#b972e9;--reef-active:#171717;--reef-shadow:0 1px 3px #00000012}
body.light-theme{--reef-bg:#fff;--reef-card:#fff;--reef-raised:#f0f0f0;--reef-sidebar:#f0f0f0;--reef-fg:#171717;--reef-muted:#737373;--reef-border:#d0d1d2;--reef-primary:#171717;--reef-on-primary:#fff;--reef-focus:#831fc8;--reef-active:#d0d1d2}
body{font-family:Inter,-apple-system,BlinkMacSystemFont,'Segoe UI',sans-serif!important;background:var(--reef-bg)!important;color:var(--reef-fg)!important;-webkit-font-smoothing:antialiased}
button,input,select,textarea{font:inherit}button,a,input,select,textarea{touch-action:manipulation}button:disabled{cursor:not-allowed;opacity:.55}button:focus-visible,a:focus-visible,input:focus-visible,textarea:focus-visible,select:focus-visible,[tabindex]:focus-visible{outline:2px solid var(--reef-focus)!important;outline-offset:3px!important;box-shadow:none!important}
.app-wrapper{height:100dvh}.app-body,.main-content,.main-content-inner{min-width:0;min-height:0}.app-header{height:64px!important;background:var(--reef-bg)!important;border-color:var(--reef-border)!important;padding:0 24px!important;gap:16px}.header-left,.header-right{min-width:0}.header-logo{gap:16px}.header-logo img{height:25px}.reef-product-label{display:flex;gap:5px;align-items:center;border-left:1px solid var(--reef-border);padding-left:16px;font-size:14px;font-weight:650;color:var(--reef-fg);white-space:nowrap}.reef-product-label span{font-weight:400;color:var(--reef-muted)}
.btn-header,.btn-sidebar-toggle{min-height:36px;border-radius:8px!important;color:var(--reef-muted)!important}.btn-sidebar-toggle{min-width:36px}.btn-header:hover,.btn-sidebar-toggle:hover{background:var(--reef-raised)!important;color:var(--reef-fg)!important;border-color:var(--reef-border)!important}.geo-state-picker,.business-category-picker{background:var(--reef-bg)!important;border-color:var(--reef-border)!important;min-width:0;padding:4px 8px}.geo-state-select,.business-category-select{min-height:32px!important;min-width:0!important;background:var(--reef-bg)!important;color:var(--reef-fg)!important;border:0!important;max-width:220px;padding:4px 6px!important}
.app-sidebar{background:var(--reef-sidebar)!important;border-color:var(--reef-border)!important}.sidebar-section{padding:16px 10px}.sidebar-section-title{font-size:11px!important;font-weight:600!important;letter-spacing:.08em!important;color:var(--reef-muted)!important}.nav-item{min-height:42px;margin:3px 0;border-radius:8px!important;color:var(--reef-fg)!important;font-size:13px!important;font-weight:500}.nav-item i{color:var(--reef-muted)!important}.nav-item.active{background:var(--reef-active)!important;color:var(--reef-fg)!important;border-left-color:transparent!important}.nav-item:hover{background:var(--reef-active)!important}.main-content-inner{padding:28px!important}.page-title{font-weight:650!important;font-size:24px!important;letter-spacing:-.6px;color:var(--reef-fg)!important}.page-title i{color:var(--reef-muted)!important}.page-subtitle{color:var(--reef-muted)!important;line-height:1.6;font-size:14px!important}
body :is(.tool-card,.chart-card,.stat-card,.stats-card,.bulk-card,.result-card,.segment-card,.info-card,.loi-form-section,.admin-card,.msgex-card,.modal-content,.detail-panel){background:var(--reef-card)!important;border:1px solid var(--reef-border)!important;border-radius:10px!important;box-shadow:var(--reef-shadow)!important;color:var(--reef-fg)!important}.tool-card:hover{transform:none!important;border-color:var(--reef-muted)!important}.tool-card .icon{background:var(--reef-raised)!important;color:var(--reef-fg)!important;border-radius:8px!important}.tool-card h3,.chart-card h3,.stat-card .value,.stats-card h3{color:var(--reef-fg)!important}.stat-card{border-left-width:1px!important}.stat-card .value{font-variant-numeric:tabular-nums;font-size:28px!important;font-weight:600!important}.stat-card .icon{color:var(--reef-muted)!important}.tools-grid{gap:16px!important}
body :is(.sidebar,.func-sidebar,.info-panel,.search-section,.address-display,.header,.segment-layers-panel,.area-search-panel){background:var(--reef-card)!important;color:var(--reef-fg)!important;border-color:var(--reef-border)!important}body :is(.func-sidebar-header,.card-header,.detail-header){background:var(--reef-raised)!important;border-color:var(--reef-border)!important;color:var(--reef-fg)!important}body :is(.sidebar h2,.func-sidebar h2,.info-card h3,.search-section h2,.segment-card h4){color:var(--reef-fg)!important}
body :is(input:not([type=checkbox]):not([type=radio]):not([type=range]):not([type=hidden]),select,textarea){background:var(--reef-bg)!important;color:var(--reef-fg)!important;border-color:var(--reef-border)!important;border-radius:8px!important;min-height:36px}input::placeholder,textarea::placeholder{color:var(--reef-muted)!important}body :is(.btn-primary,.btn-search,.btn-check,.btn-generate,.btn-loi-link,.btn-send-fillout-sms,.msgex-btn-primary){background:var(--reef-primary)!important;color:var(--reef-on-primary)!important;border:1px solid var(--reef-primary)!important;border-radius:8px!important;box-shadow:none!important;min-height:38px}.btn-primary:hover,.btn-search:hover,.btn-check:hover{filter:brightness(.88)}
body table{color:var(--reef-fg);font-variant-numeric:tabular-nums}body th{background:var(--reef-raised)!important;color:var(--reef-muted)!important;font-weight:500!important;font-size:12px}body td,body th{border-color:var(--reef-border)!important}body tbody tr:hover{background:var(--reef-raised)!important}.loi-form-rest:not(.unlocked){opacity:1!important}.loi-form-rest:not(.unlocked) :is(button,input,select,textarea){opacity:.55}.reef-skip-link{position:fixed;left:12px;top:-100px;padding:12px 18px;background:var(--reef-primary);color:var(--reef-on-primary);z-index:20000;border-radius:8px}.reef-skip-link:focus{top:12px}
@media(max-width:1100px){.app-header{padding:0 12px!important;gap:8px}.reef-product-label,.geo-state-label,.business-category-label{display:none}.header-right{gap:6px}.geo-state-select{max-width:155px}.business-category-select{max-width:140px}.btn-header{padding:8px!important}}
@media(max-width:768px){.app-header{flex-wrap:nowrap!important}.header-logo img{height:22px}.header-right .btn-report,.header-right .btn-finder{display:none}.geo-state-picker{max-width:155px}.geo-state-select{max-width:104px}.business-category-picker{max-width:125px}.business-category-icon{display:none}.business-category-select{max-width:106px}.main-content-inner{padding:16px!important}.page-title{font-size:22px!important}.btn-header,.btn-sidebar-toggle,button{min-height:44px}.btn-header,.btn-sidebar-toggle{min-width:40px}.sidebar,.func-sidebar{max-width:100vw!important}.header-right{overflow-x:auto}.header-left{gap:4px}.header-logo .logo-fallback{font-size:14px}.tools-grid{grid-template-columns:1fr!important}body :is(input,select,textarea){font-size:16px!important}.geo-state-select,.business-category-select{font-size:12px!important}}
@media(prefers-reduced-motion:reduce){*,*::before,*::after{animation-duration:.01ms!important;animation-iteration-count:1!important;transition-duration:.01ms!important;scroll-behavior:auto!important}}
.reef-eyebrow{font-size:11px;letter-spacing:.1em;font-weight:600;color:var(--reef-muted);margin-bottom:12px}.welcome-section{background:var(--reef-bg)!important;border-bottom:1px solid var(--reef-border);padding:0 0 24px!important}.welcome-section h1{color:var(--reef-fg)!important;font-size:30px!important;letter-spacing:-.9px;font-weight:600!important}.welcome-section p{color:var(--reef-muted)!important;max-width:720px}.section-title{color:var(--reef-fg)!important;font-size:15px!important;font-weight:600!important}.section-title i{color:var(--reef-muted)!important}.stat-value{font-size:28px!important;font-weight:600!important;color:var(--reef-fg)!important;font-variant-numeric:tabular-nums}.stat-label,.stat-sub{color:var(--reef-muted)!important}
body #sidebar{background:var(--reef-card)!important;color:var(--reef-fg)!important}body .header h1,body .bulk-card h4,body .stats-card h4,body .stat-num{color:var(--reef-fg)!important}.area-type-control{background:var(--reef-raised)!important;border-color:var(--reef-border)!important}.area-type-option{color:var(--reef-muted)!important}.area-type-option[aria-checked="true"]{background:var(--reef-primary)!important;color:var(--reef-on-primary)!important}.btn-header.btn-finder{background:var(--reef-raised)!important}.reef-provider-row{display:flex;flex-wrap:wrap;gap:12px;padding:12px 0;border-bottom:1px solid var(--reef-border);font-size:13px}.reef-provider-row strong{text-transform:capitalize;min-width:140px}.reef-provider-row small{flex-basis:100%;color:var(--reef-muted)}.reef-platform-card{margin-bottom:24px;padding:20px}.reef-platform-card .page-subtitle{margin:12px 0}.reef-phone-evidence{font-size:12px;line-height:1.5;color:var(--reef-muted);margin-top:6px}.leaflet-popup .reef-phone-evidence{color:#525252}
@media(max-width:768px){#sidebar{width:100%!important;max-width:100vw!important}.container{width:100%;min-width:0}.area-type-option{min-width:0!important}.app-header{max-width:100vw}}
body .loi-form-section h3,body .admin-card-header h3,body .msgex-section h3{color:var(--reef-fg)!important}body .tool-card .icon i{color:var(--reef-fg)!important}

/* Login shares the same Reef surfaces and primary action as the application. */
body .login-card{background:var(--reef-card)!important;border:1px solid var(--reef-border)!important;border-radius:12px!important;color:var(--reef-fg)!important;box-shadow:var(--reef-shadow)!important}body .login-card h1,body .login-card label{color:var(--reef-fg)!important}body .login-card .subtitle{color:var(--reef-muted)!important}body .login-card button[type=submit]{background:var(--reef-primary)!important;color:var(--reef-on-primary)!important;min-height:44px;border-radius:8px}
