/* CUAN AI V5.0 — REFERENCE 2 / GREEN CALM */
:root{--r2-bg:#f8faf8;--r2-panel:#fff;--r2-text:#172129;--r2-muted:#748079;--r2-line:#e4eae6;--r2-green:#39aa5e;--r2-green2:#27884a;--r2-green-soft:#edf7ef;--r2-red:#df4b55;--r2-yellow:#b78315;--r2-shadow:0 8px 24px rgba(36,73,51,.055)}*{box-sizing:border-box}html,body{background:#f8faf8!important;color:var(--r2-text)!important;font-family:Inter,ui-sans-serif,-apple-system,BlinkMacSystemFont,"Segoe UI",Roboto,Arial,sans-serif!important}.app{min-height:100vh}.ref2-sidebar{position:fixed!important;inset:0 auto 0 0!important;width:264px!important;padding:0!important;background:#fff!important;border-right:1px solid var(--r2-line)!important;box-shadow:none!important;z-index:40!important;display:flex!important;flex-direction:column!important}.ref2-brand{height:104px;padding:24px 24px 18px;display:flex;align-items:flex-start;gap:12px;border-bottom:1px solid #f0f2f0}.ref2-logo{width:42px;height:42px;display:grid;place-items:center;border-radius:12px;background:linear-gradient(145deg,#73c986,#2ea45a);color:#fff;font-weight:900;font-size:18px;box-shadow:0 7px 18px rgba(60,169,91,.18)}.ref2-brand b,.ref2-brand small{display:block}.ref2-brand b{font-size:20px;line-height:1;color:#111a20}.ref2-brand small{font-size:10px;color:#717d77;margin-top:8px}.ref2-nav{padding:26px 14px;display:flex!important;flex-direction:column;gap:7px!important;overflow:auto}.ref2-nav a{min-height:54px;padding:0 14px!important;display:flex!important;align-items:center;gap:13px;border-radius:10px!important;border:1px solid transparent!important;background:transparent!important;color:#2f3a42!important;text-decoration:none;transform:none!important}.ref2-nav a span{width:28px;font-size:17px;text-align:center;color:#6c7a72}.ref2-nav a b{font-size:13px;font-weight:600;color:inherit!important}.ref2-nav a:hover{background:#f7faf7!important;border-color:#edf1ee!important}.ref2-nav a.active{background:linear-gradient(135deg,#42ae63,#32a454)!important;border-color:#32a454!important;color:#fff!important;box-shadow:0 8px 20px rgba(52,166,87,.18)!important}.ref2-nav a.active:before{display:none!important}.ref2-nav a.active span{color:#fff}.ref2-user{margin:auto 18px 22px;padding:14px 0 0;border-top:1px solid #edf1ee;display:grid;grid-template-columns:auto 1fr auto;gap:10px;align-items:center}.ref2-avatar{width:40px;height:40px;display:grid;place-items:center;border-radius:50%;border:1px solid #dfe6e1;background:#f8faf8;color:#3f4a43}.ref2-user b,.ref2-user small{display:block}.ref2-user b{font-size:11px;color:#233039}.ref2-user small{font-size:9px;color:#89948e;margin-top:2px}.ref2-user>a{font-size:18px;color:#69766f;text-decoration:none}.ref2-main{margin-left:264px!important;min-height:100vh;background:#fbfcfb!important}.ref2-topbar{height:76px;position:sticky;top:0;z-index:30;padding:0 30px;display:flex;align-items:center;justify-content:space-between;border-bottom:1px solid var(--r2-line);background:rgba(255,255,255,.94);backdrop-filter:blur(12px)}.ref2-menu-btn{display:none!important}.ref2-market{display:flex;align-items:center;gap:8px;font-variant-numeric:tabular-nums}.ref2-symbol{font-size:13px;font-weight:900;color:#172129}.ref2-market>strong{font-size:13px}.ref2-market>b{font-size:12px}.ref2-market.up .ref2-arrow,.ref2-market.up>b{color:#13a553}.ref2-market.down .ref2-arrow,.ref2-market.down>b{color:#df4b55}.ref2-market.flat .ref2-arrow,.ref2-market.flat>b{color:#7a8780}.ref2-arrow{font-size:10px}.ref2-live-pill{margin-left:12px;display:inline-flex;align-items:center;gap:6px;padding:6px 9px;border-radius:8px;background:#edf8f0;color:#198747;font-size:9px;font-weight:800}.ticker-live-dot{width:7px;height:7px;border-radius:50%;background:#d0a344}.ticker-live-dot.live{background:#23ad57;box-shadow:0 0 0 4px rgba(35,173,87,.08)}.ref2-clock{display:flex;align-items:center;gap:6px;color:#252f36;font-size:11px}.ref2-clock b{font-size:11px}.ref2-clock span{color:#6f7b75}.ref2-clock i{font-style:normal;margin-left:8px}.ref2-content{max-width:1500px!important;margin:0 auto!important;padding:26px 30px 34px!important;background:transparent!important}.ref2-content>.alert{margin-bottom:14px}
/* common pages */
.ref2-theme .card,.ref2-theme .stat,.ref2-theme .page-title,.ref2-theme .hero,.ref2-theme .beginner-welcome,.ref2-theme .settings-hero,.ref2-theme .journal-hero,.ref2-theme .watch-page-hero,.ref2-theme .ihsg-intel-hero,.ref2-theme .analysis-stock-id,.ref2-theme .analysis-verdict-card,.ref2-theme .analysis-action-card,.ref2-theme .analysis-proof-card,.ref2-theme .analysis-pillar-card,.ref2-theme .analysis-advanced{background:#fff!important;border:1px solid var(--r2-line)!important;box-shadow:var(--r2-shadow)!important;color:var(--r2-text)!important}.ref2-theme .page-title,.ref2-theme .hero,.ref2-theme .beginner-welcome,.ref2-theme .settings-hero,.ref2-theme .journal-hero,.ref2-theme .watch-page-hero,.ref2-theme .ihsg-intel-hero{border-radius:14px!important;padding:22px 24px!important}.ref2-theme h1,.ref2-theme h2,.ref2-theme h3,.ref2-theme h4{color:#172129!important}.ref2-theme p,.ref2-theme .muted-text{color:#748079!important}.ref2-theme .eyebrow,.ref2-theme .panel-kicker{color:#27884a!important}.ref2-theme .btn{background:#fff!important;color:#2d3941!important;border:1px solid #dce5df!important;box-shadow:none!important;border-radius:9px!important}.ref2-theme .btn:hover{background:#f7faf8!important;transform:none!important}.ref2-theme .btn.primary{background:#36a95c!important;color:#fff!important;border-color:#36a95c!important;box-shadow:0 6px 15px rgba(54,169,92,.15)!important}.ref2-theme label{color:#536159!important}.ref2-theme label input,.ref2-theme label select,.ref2-theme label textarea,.ref2-theme input,.ref2-theme select,.ref2-theme textarea{background:#fff!important;color:#263139!important;border:1px solid #dce5df!important;box-shadow:none!important}.ref2-theme label input:focus,.ref2-theme label select:focus,.ref2-theme label textarea:focus,.ref2-theme input:focus,.ref2-theme select:focus,.ref2-theme textarea:focus{border-color:#82c595!important;box-shadow:0 0 0 3px rgba(79,174,105,.10)!important}.ref2-theme table{background:#fff!important}.ref2-theme th{background:#fbfcfb!important;color:#748079!important}.ref2-theme td{color:#28343b!important;border-color:#edf1ee!important}.ref2-theme tr:hover td{background:#fbfdfb!important}.ref2-theme .badge.good{background:#e8f7ed!important;color:#258048!important}.ref2-theme .badge.warn{background:#fff3dc!important;color:#9d7014!important}.ref2-theme .badge.bad{background:#fde9eb!important;color:#cc4652!important}.ref2-theme .badge.muted{background:#f2f4f3!important;color:#707b75!important}.ref2-theme .pos{color:#19a052!important}.ref2-theme .neg{color:#dc4d58!important}.ref2-theme .note,.ref2-theme .risk-preview,.ref2-theme .checks label,.ref2-theme .journal-details,.ref2-theme .exit-details,.ref2-theme .plan-switch,.ref2-theme .ai-msg,.ref2-theme .ai-compose,.ref2-theme .vision-upload-box,.ref2-theme .ihsg-ai-board,.ref2-theme .ihsg-live-bar,.ref2-theme .ihsg-driver-card,.ref2-theme .ihsg-story-card,.ref2-theme .ihsg-pattern-card,.ref2-theme .ihsg-calendar-card,.ref2-theme .ihsg-preopen-card,.ref2-theme .metric-box,.ref2-theme .reason-item,.ref2-theme .preopen-list div,.ref2-theme .prediction-history,.ref2-theme .analysis-pillar,.ref2-theme .analysis-reasons>div,.ref2-theme .analysis-invalid,.ref2-theme .analysis-advanced-grid>div,.ref2-theme .watch-page-stats>div,.ref2-theme .watch-add-card,.ref2-theme .watch-list-card,.ref2-theme .watch-flow-note{background:#fff!important;border-color:var(--r2-line)!important;box-shadow:none!important;color:#29353c!important}.ref2-theme .ihsg-live-grid div,.ref2-theme .ihsg-ai-paragraph,.ref2-theme .ihsg-watch-next{background:#fbfcfb!important;border-color:var(--r2-line)!important}.ref2-theme .ihsg-day{background:#fff!important;border-color:#e4eae6!important;color:#26323a!important}.ref2-theme .ihsg-day.green{background:#eaf7ee!important;border-color:#cfe9d7!important}.ref2-theme .ihsg-day.red{background:#fdebed!important;border-color:#f2d0d4!important}.ref2-theme .analysis-tabs{background:#f8faf8!important;border-color:#e1e8e3!important}.ref2-theme .analysis-tabs a{color:#67736c!important}.ref2-theme .analysis-tabs a.active{background:#edf7ef!important;border-color:#c7e2cf!important;color:#257b47!important}.ref2-theme .analysis-action-message{background:#fff9e9!important;border-color:#f0dfb9!important}.ref2-theme .analysis-level-grid>div{background:#fbfcfb!important;border-color:#e4eae6!important}.ref2-theme .analysis-advanced summary{background:#fff!important;color:#263139!important}.ref2-theme .watch-table td,.ref2-theme .watch-table th{border-color:#edf1ee!important}.ref2-theme .watch-status-badge.active{background:#e8f7ed!important;color:#258048!important}.ref2-theme .watch-status-badge.off{background:#f2f4f3!important;color:#6f7a74!important}.ref2-theme .auth-card{background:#fff!important;border:1px solid var(--r2-line)!important;box-shadow:0 18px 45px rgba(40,73,51,.08)!important}.ref2-theme.auth{background:#f8faf8!important}
@media(max-width:1050px){.ref2-sidebar{transform:translateX(-100%);transition:.2s}.ref2-main{margin-left:0!important}.ref2-menu-btn{display:inline-grid!important;place-items:center;width:38px;height:38px;border:1px solid #dfe7e2;border-radius:9px;background:#fff;color:#2e3b42}.ref2-topbar{justify-content:flex-start;gap:14px}.ref2-clock{margin-left:auto}body.menu-open .ref2-sidebar{transform:translateX(0);box-shadow:20px 0 45px rgba(35,68,48,.12)!important}.ref2-content{padding:20px!important}}@media(max-width:620px){.ref2-topbar{height:68px;padding:0 14px}.ref2-market{gap:5px}.ref2-market>b:first-of-type{display:none}.ref2-live-pill{margin-left:4px;padding:5px 7px}.ref2-live-pill span{display:none}.ref2-clock span,.ref2-clock i{display:none}.ref2-content{padding:14px!important}.ref2-sidebar{width:82%!important;max-width:286px}.ref2-page-head h1{font-size:26px}}

/* ===== CUAN V5.6.2 — DATA TIMESTAMP / FRESHNESS ===== */
.ref2-market-freshness{display:inline-flex;align-items:center;gap:7px;margin-left:6px;padding-left:10px;border-left:1px solid #e0e8e3;white-space:nowrap}
.ref2-market-freshness>span{display:flex;align-items:center;gap:4px;font-size:10px;color:#66756d}
.ref2-market-freshness em{font-style:normal;color:#8a9690;font-weight:700}
.ref2-market-freshness b{font-size:10px;color:#26362d;font-weight:850}
.cuan-freshness{display:flex;align-items:center;flex-wrap:wrap;gap:8px;margin:10px 0 16px;padding:10px 12px;border:1px solid #dbe9df;border-radius:11px;background:#f7fbf8;color:#51645a}
.cuan-freshness.compact{margin:8px 0 0;padding:8px 10px;background:#fbfdfb}
.cuan-freshness .cf-source{display:inline-flex;align-items:center;padding:5px 8px;border-radius:999px;background:#e5f5eb;color:#197344;font-size:10px;font-weight:900;letter-spacing:.035em}
.cuan-freshness .cf-item{display:inline-flex;align-items:center;gap:5px;font-size:11px;line-height:1.35}
.cuan-freshness .cf-item span{color:#7e8b84;font-weight:700}
.cuan-freshness .cf-item b{color:#24342b;font-size:11px}
.cuan-freshness .cf-dot{color:#b7c2bc}
.cuan-freshness.stale{border-color:#eedab1;background:#fffaf0}.cuan-freshness.stale .cf-source{background:#fff0c9;color:#8d6813}
.cuan-freshness.demo{border-color:#eadfbd;background:#fffaf0}.cuan-freshness.demo .cf-source{background:#f7ebc9;color:#806116}
@media(max-width:1100px){.ref2-market-freshness{display:none}}
@media(max-width:720px){.cuan-freshness{align-items:flex-start}.cuan-freshness .cf-item{width:100%}.cuan-freshness .cf-dot{display:none}}
.simple-position-price small{display:block;margin-top:4px;font-size:10px;color:#7b8981;font-weight:700}
@media(max-width:1100px){
  .ref2-market{flex-wrap:wrap;row-gap:3px}
  .ref2-market-freshness{display:flex;width:100%;margin-left:0;padding-left:0;border-left:0;gap:10px}
  .ref2-market-freshness>span,.ref2-market-freshness b{font-size:9px}
}
@media(max-width:620px){
  .ref2-topbar{height:auto;min-height:82px;padding-top:7px;padding-bottom:7px;align-items:flex-start}
  .ref2-market{padding-top:4px}
  .ref2-market-freshness{gap:7px}
  .ref2-market-freshness>span{gap:3px}
  .ref2-clock{display:none}
}

/* ===== CUAN V6.7 SMART ALERTS ===== */
.ref2-top-actions{margin-left:auto;display:flex;align-items:center;gap:10px;position:relative}
.cuan-alarm-wrap{position:relative}
.cuan-alarm-button{position:relative;min-height:38px;padding:0 12px;border:1px solid #dce8df;border-radius:10px;background:#fff;color:#1f3527;display:flex;align-items:center;gap:7px;font:inherit;font-size:11px;font-weight:850;cursor:pointer;box-shadow:0 3px 10px rgba(37,91,54,.04)}
.cuan-alarm-button:hover,.cuan-alarm-button.active{background:#f1faf3;border-color:#b9dfc4;color:#0d7f3d}
.cuan-alarm-bell{font-size:15px;line-height:1;transform-origin:50% 12%}
.cuan-alarm-button.ringing .cuan-alarm-bell{animation:cuanAlarmBell .75s ease-in-out 3}
.cuan-alarm-button>b{position:absolute;right:-6px;top:-7px;min-width:20px;height:20px;padding:0 5px;border-radius:999px;background:#e44750;color:#fff;display:grid;place-items:center;font-size:9px;font-weight:900;border:2px solid #fff}
@keyframes cuanAlarmBell{0%,100%{transform:rotate(0)}20%{transform:rotate(16deg)}40%{transform:rotate(-14deg)}60%{transform:rotate(10deg)}80%{transform:rotate(-8deg)}}
.cuan-alarm-panel{position:absolute;right:0;top:48px;width:min(420px,calc(100vw - 28px));background:#fff;border:1px solid #dfe9e2;border-radius:16px;box-shadow:0 22px 60px rgba(23,59,36,.18);padding:14px;z-index:120}
.cuan-alarm-head{display:flex;align-items:flex-start;justify-content:space-between;gap:12px;padding:2px 2px 12px;border-bottom:1px solid #edf2ee}
.cuan-alarm-head strong,.cuan-alarm-head small{display:block}.cuan-alarm-head strong{font-size:16px;color:#15221a}.cuan-alarm-head small{font-size:10px;color:#7e8b83;margin-top:3px}.cuan-alarm-head>button{width:30px;height:30px;border:0;border-radius:8px;background:#f5f8f6;color:#526058;font-size:20px;cursor:pointer}
.cuan-alarm-status{margin-top:12px;padding:10px;border:1px solid #dce9df;background:#f8fcf9;border-radius:12px;display:grid;grid-template-columns:auto 1fr auto;gap:9px;align-items:center}
.cuan-alarm-dot{width:9px;height:9px;border-radius:50%;background:#25a958;box-shadow:0 0 0 5px rgba(37,169,88,.09)}
.cuan-alarm-status b,.cuan-alarm-status small{display:block}.cuan-alarm-status b{font-size:11px;color:#21362a}.cuan-alarm-status small{font-size:9px;color:#819087;margin-top:2px}.cuan-alarm-status>button{border:1px solid #cde3d3;background:#fff;color:#138545;border-radius:8px;padding:7px 9px;font-size:9px;font-weight:850;cursor:pointer}.cuan-alarm-status>button.loading{opacity:.6;pointer-events:none}
.cuan-alarm-permission{width:100%;margin-top:10px;border:1px solid #b9dcc3;background:#edf8f0;color:#157b3f;border-radius:10px;padding:9px 12px;font-size:10px;font-weight:850;cursor:pointer}.cuan-alarm-permission.granted{background:#f7faf8;color:#65736b;border-color:#e1e7e3}.cuan-alarm-permission.denied{background:#fff3f3;color:#b94149;border-color:#f1c7ca}
.cuan-alarm-options{margin-top:10px;border:1px solid #e5ece7;border-radius:12px;overflow:hidden}
.cuan-alarm-options label{display:grid;grid-template-columns:1fr auto;gap:12px;align-items:center;padding:11px 12px;border-bottom:1px solid #edf2ee;cursor:pointer;position:relative}.cuan-alarm-options label:last-child{border-bottom:0}.cuan-alarm-options label:hover{background:#fbfdfb}.cuan-alarm-options span b,.cuan-alarm-options span small{display:block}.cuan-alarm-options span b{font-size:11px;color:#26342b}.cuan-alarm-options span small{font-size:9px;color:#839088;line-height:1.35;margin-top:3px;padding-right:5px}.cuan-alarm-options input{position:absolute;opacity:0;pointer-events:none}.cuan-alarm-options i{width:36px;height:20px;border-radius:999px;background:#d9e1dc;position:relative;transition:.18s}.cuan-alarm-options i:after{content:"";position:absolute;width:16px;height:16px;left:2px;top:2px;border-radius:50%;background:#fff;box-shadow:0 1px 4px rgba(0,0,0,.14);transition:.18s}.cuan-alarm-options input:checked+i{background:#30aa5d}.cuan-alarm-options input:checked+i:after{transform:translateX(16px)}
.cuan-alarm-note{margin-top:10px;padding:9px 10px;border-radius:9px;background:#fff9eb;border:1px solid #f2e4b4;color:#776124;font-size:9px;line-height:1.45}
.cuan-alarm-history-head{margin-top:12px;display:flex;align-items:center;justify-content:space-between;gap:10px}.cuan-alarm-history-head b{font-size:11px;color:#28362e}.cuan-alarm-history-head button{border:0;background:transparent;color:#20854a;font-size:9px;font-weight:800;cursor:pointer}
.cuan-alarm-list{margin-top:7px;display:flex;flex-direction:column;gap:7px;max-height:270px;overflow:auto}
.cuan-alarm-empty{padding:15px;text-align:center;border:1px dashed #dbe6df;border-radius:10px;color:#89958e;font-size:10px}
.cuan-alert-item{display:grid;grid-template-columns:34px 1fr auto;gap:9px;align-items:start;padding:9px;border:1px solid #e1e9e4;border-radius:11px;background:#fff;text-decoration:none;color:inherit}.cuan-alert-item:hover{background:#f9fcfa}.cuan-alert-icon{width:34px;height:34px;border-radius:10px;display:grid;place-items:center;background:#edf8f0;font-size:17px}.cuan-alert-item.plan .cuan-alert-icon{background:#eaf8ee}.cuan-alert-item.gc .cuan-alert-icon{background:#fff6df}.cuan-alert-item.rsi .cuan-alert-icon{background:#eef8ef}.cuan-alert-copy b,.cuan-alert-copy span,.cuan-alert-copy small{display:block}.cuan-alert-copy b{font-size:10px;color:#1c2c22}.cuan-alert-copy span{font-size:9px;color:#536259;line-height:1.35;margin-top:2px}.cuan-alert-copy small{font-size:8px;color:#8b9790;margin-top:4px}.cuan-alert-time{font-size:8px;color:#89968e;white-space:nowrap;padding-top:2px}
.cuan-alert-toast{position:fixed;right:22px;bottom:22px;width:min(390px,calc(100vw - 28px));z-index:200;background:#173b25;color:#fff;border-radius:14px;padding:13px 14px;box-shadow:0 18px 50px rgba(17,62,33,.28);display:grid;grid-template-columns:auto 1fr auto;gap:10px;align-items:start;animation:cuanAlertIn .2s ease-out}.cuan-alert-toast .icon{font-size:21px}.cuan-alert-toast b,.cuan-alert-toast span{display:block}.cuan-alert-toast b{font-size:12px}.cuan-alert-toast span{font-size:10px;line-height:1.4;margin-top:3px;color:#d9eee0}.cuan-alert-toast button{border:0;background:rgba(255,255,255,.12);color:#fff;width:28px;height:28px;border-radius:8px;cursor:pointer}.cuan-alert-toast a{grid-column:2/4;color:#fff;font-size:9px;font-weight:800;margin-top:2px}.cuan-alert-toast.gc{background:#735514}.cuan-alert-toast.rsi{background:#176344}.cuan-alert-toast.plan{background:#0f6c39}@keyframes cuanAlertIn{from{opacity:0;transform:translateY(10px)}to{opacity:1;transform:translateY(0)}}
@media(max-width:1100px){.cuan-alarm-button>span:nth-child(2){display:none}.cuan-alarm-button{padding:0 10px}.ref2-top-actions{margin-left:auto}}
@media(max-width:620px){.ref2-top-actions{gap:4px}.cuan-alarm-panel{position:fixed;right:10px;left:10px;top:70px;width:auto;max-height:calc(100vh - 82px);overflow:auto}.cuan-alarm-status{grid-template-columns:auto 1fr}.cuan-alarm-status>button{grid-column:1/3}.cuan-alert-toast{right:12px;bottom:12px}}

.cuan-alert-item.price .cuan-alert-icon{background:#edf4ff}.cuan-alert-toast.price{background:#245d8f}

/* ===== CUAN V6.10 — ALERT MOMENTUM FIX ===== */
.cuan-alert-item.momentum .cuan-alert-icon{background:#eef4ff;color:#2458b8}
.cuan-alert-toast.momentum{background:#174f87}
.cuan-alarm-actions{display:grid;grid-template-columns:1fr auto;gap:8px;margin-top:10px}.cuan-alarm-actions .cuan-alarm-permission{margin-top:0}.cuan-alarm-test{border:1px solid #cde3d3;background:#fff;color:#157b3f;border-radius:10px;padding:9px 12px;font-size:10px;font-weight:850;cursor:pointer;white-space:nowrap}.cuan-alarm-test:hover{background:#f1faf3}@media(max-width:620px){.cuan-alarm-actions{grid-template-columns:1fr}.cuan-alarm-test{width:100%}}

/* ===== CUAN V6.11 — REAL DEEP AI ===== */
.cuan-deep-ai-diag{margin-top:10px;padding:10px 11px;border:1px solid #cce6d4;border-radius:12px;background:linear-gradient(135deg,#f2fbf5,#fbfdfb);display:grid;gap:4px}
.cuan-deep-ai-diag>div{display:flex;align-items:center;gap:7px}.cuan-deep-ai-diag b{font-size:11px;color:#20362a}.cuan-deep-ai-diag strong{margin-left:auto;font-size:9px;color:#0d8a43;background:#e9f8ee;padding:4px 7px;border-radius:999px}.cuan-deep-ai-diag strong.bad{color:#b33d46;background:#fff0f1}.cuan-deep-ai-diag small{font-size:8.5px;color:#738178;line-height:1.35}.cuan-deep-ai-diag.offline{border-color:#f0c9cc;background:#fff7f7}.cuan-deep-ai-dot{width:9px;height:9px;border-radius:50%;display:inline-block}.cuan-deep-ai-dot.on{background:#18a653;box-shadow:0 0 0 4px rgba(24,166,83,.1)}.cuan-deep-ai-dot.off{background:#d24a53;box-shadow:0 0 0 4px rgba(210,74,83,.09)}
.cuan-alert-item.deepai{border-color:#c9e0d1;background:#f7fcf8}.cuan-alert-item.deepai .cuan-alert-icon{background:#e4f7ea;color:#087a3b}.cuan-alert-toast.deepai{background:linear-gradient(135deg,#075f32,#0c8b47)}
.cuan-deep-ai-diag>button{margin-top:4px;border:1px solid #badcc4;background:#fff;color:#137b3e;border-radius:8px;padding:7px 9px;font-size:8.5px;font-weight:850;cursor:pointer}.cuan-deep-ai-diag>button:hover{background:#eef8f1}

/* ===== V7.3 SMART AI POWER ===== */
.ai-power-card{margin-top:18px}
.ai-power-engine-grid{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:14px;margin-top:14px}
.ai-power-engine{border:1px solid #dbe8df;border-radius:16px;padding:16px;background:#fbfdfb}
.ai-power-engine.active{background:#f3fbf6;border-color:#bfe2cb}
.ai-power-engine.rest{background:#fafcfb;border-color:#dde5df}
.ai-power-engine.off,.ai-power-engine.disconnected{background:#fff8f8;border-color:#f0d9d9}
.ai-power-engine-head{display:flex;justify-content:space-between;gap:12px;align-items:flex-start}
.ai-power-engine-head small{font-size:10px;font-weight:900;letter-spacing:.1em;color:#19864d}
.ai-power-engine-head h3{margin:4px 0 5px;font-size:20px;color:#10231a}
.ai-power-engine-head p{margin:0;color:#66736b;font-size:12px;line-height:1.5;max-width:520px}
.ai-power-led{width:12px;height:12px;border-radius:50%;background:#aab4ad;margin-top:4px;box-shadow:0 0 0 6px #eef2ef}
.ai-power-engine.active .ai-power-led{background:#16a45c;box-shadow:0 0 0 6px #e2f6e9}
.ai-power-engine.off .ai-power-led,.ai-power-engine.disconnected .ai-power-led{background:#e6535d;box-shadow:0 0 0 6px #fdecee}
.ai-power-segment{display:flex;gap:4px;margin-top:14px;padding:4px;background:#edf4ef;border-radius:12px}
.ai-power-segment button{flex:1;border:0;background:transparent;border-radius:9px;padding:10px 8px;font-weight:900;font-size:11px;color:#6e7b73;cursor:pointer}
.ai-power-segment button.active{background:#0b914d;color:#fff;box-shadow:0 5px 13px rgba(11,145,77,.16)}
.ai-power-session{display:flex;justify-content:space-between;align-items:center;margin-top:12px;padding-top:10px;border-top:1px solid #e3ebe5;font-size:11px;color:#778279}.ai-power-session b{color:#213329}
.ai-power-usage{display:grid;grid-template-columns:repeat(4,minmax(0,1fr));gap:1px;margin:14px 0;background:#dfe9e2;border:1px solid #dfe9e2;border-radius:14px;overflow:hidden}
.ai-power-usage>div{background:#fff;padding:14px 15px}.ai-power-usage small{display:block;font-size:9px;font-weight:900;letter-spacing:.08em;color:#718078}.ai-power-usage b{display:block;font-size:23px;margin-top:3px;color:#0c7f43}.ai-power-usage span{display:block;font-size:10px;color:#77837b;margin-top:3px}
.cuan-ai-power-summary{display:flex;flex-direction:column;gap:8px;padding:10px 12px;margin-bottom:8px;background:#f5faf6;border:1px solid #dceadf;border-radius:11px}
.cuan-ai-power-summary>div{display:flex;gap:8px;align-items:flex-start}.cuan-ai-power-summary>div>span:last-child{display:flex;flex-direction:column;gap:2px}.cuan-ai-power-summary b{font-size:11px;color:#263a2e}.cuan-ai-power-summary small{font-size:9px;color:#718078;line-height:1.35}.cuan-ai-power-summary>a{font-size:10px;font-weight:900;color:#078547;text-decoration:none;padding-left:20px}
@media(max-width:850px){.ai-power-engine-grid{grid-template-columns:1fr}.ai-power-usage{grid-template-columns:repeat(2,1fr)}}

/* V7.8.8 — Notification & Alarm Controls */
.cuan-alarm-sound-controls{margin-top:10px;padding:10px;border:1px solid #e3ece6;border-radius:12px;background:#fbfdfb;display:grid;grid-template-columns:1fr 1fr;gap:8px}.cuan-alarm-volume-row{grid-column:1/-1}.cuan-alarm-volume-row>span{display:flex;align-items:center;justify-content:space-between;gap:10px;margin-bottom:7px}.cuan-alarm-volume-row b{font-size:10px;color:#294032}.cuan-alarm-volume-row small{font-size:10px;font-weight:900;color:#0b8a4a}.cuan-alarm-volume-row input[type=range]{width:100%;accent-color:#0b9851}.cuan-alarm-sound-controls label{display:block;margin:0}.cuan-alarm-sound-controls label>span{display:block;font-size:9px;font-weight:850;color:#6d7e75;margin-bottom:4px}.cuan-alarm-sound-controls select{width:100%;border:1px solid #d8e5dc;background:#fff;color:#294032;border-radius:9px;padding:8px;font:inherit;font-size:10px}.cuan-alarm-settings-link{display:block;padding:9px 11px;border-top:1px solid #edf2ee;color:#0a8648!important;font-size:10px;font-weight:900;background:#f8fcf9}.cuan-alarm-settings-link:hover{background:#eef9f2}
.notification-settings-card{border-top:3px solid #13a35a!important}.notification-switch-grid{display:grid;grid-template-columns:repeat(3,1fr);gap:10px;margin-bottom:14px}.notification-switch{display:flex!important;align-items:flex-start;gap:10px;padding:12px!important;border:1px solid #dfe9e3;border-radius:12px;background:#f8fbf9;color:#274436!important;margin:0!important}.notification-switch input{width:18px!important;height:18px!important;margin:1px 0 0!important;accent-color:#0a9851}.notification-switch span{display:block}.notification-switch b,.notification-switch small{display:block}.notification-switch b{font-size:12px}.notification-switch small{margin-top:3px;color:#76867e;font-size:10px;line-height:1.35}.notification-volume-box{padding:14px;border:1px solid #dfe9e3;border-radius:13px;background:#fbfdfb;margin-bottom:13px}.notification-volume-box>div{display:flex;justify-content:space-between;align-items:center;gap:10px}.notification-volume-box>div b{font-size:13px;color:#1d3d2e}.notification-volume-box>div span{font-size:15px;font-weight:900;color:#0b8c4c}.notification-volume-box input[type=range]{width:100%;margin:10px 0 5px;accent-color:#0a9851}.notification-volume-box>small{display:block;color:#74847b;font-size:10px;line-height:1.45}.notification-fields{display:grid;grid-template-columns:repeat(3,1fr);gap:12px}.notification-actions{display:flex;gap:9px;flex-wrap:wrap;margin-top:4px}.notification-actions .btn.ghost{margin-top:0}
@media(max-width:780px){.cuan-alarm-sound-controls{grid-template-columns:1fr}.cuan-alarm-volume-row{grid-column:1}.notification-switch-grid,.notification-fields{grid-template-columns:1fr}}

/* V7.9 — Telegram + Background Monitor */
.telegram-settings-card{margin-top:18px}.telegram-action-row{display:flex;gap:10px;flex-wrap:wrap;margin:12px 0}.telegram-action-row form{margin:0}.background-monitor-box{margin-top:16px;padding:16px;border:1px solid #dce8e1;border-radius:16px;background:#f8fbf9}.background-monitor-head{display:flex;justify-content:space-between;align-items:flex-start;gap:12px;margin-bottom:8px}.background-monitor-head small{font-size:10px;font-weight:900;letter-spacing:.1em;color:#73847b}.background-monitor-head h3{margin:3px 0 0;font-size:18px;color:#173728}.background-monitor-box>p{margin:0 0 14px;color:#697c72;font-size:12px;line-height:1.55}.cron-grid{display:grid;grid-template-columns:180px 1fr;gap:10px}.cron-grid>div{background:#fff;border:1px solid #e5ece8;border-radius:12px;padding:11px}.cron-grid>div.wide{grid-column:span 1}.cron-grid small{display:block;font-size:9px;font-weight:900;letter-spacing:.08em;color:#7d8d84}.cron-grid code{display:block;margin-top:6px;padding:8px;border-radius:8px;background:#f1f6f3;color:#214635;font-size:11px;line-height:1.45;word-break:break-all;white-space:normal}.cron-grid span{display:block;margin-top:4px;font-size:10px;color:#7d8d84}.background-runtime{display:grid;grid-template-columns:repeat(4,minmax(0,1fr));gap:8px;margin:12px 0}.background-runtime span{background:#fff;border:1px solid #e5ece8;border-radius:10px;padding:10px;font-size:10px;color:#718179}.background-runtime b{display:block;margin-top:4px;font-size:13px;color:#1e4031}.telegram-error{margin:8px 0;padding:10px 11px;border-radius:10px;background:#fff1f1;border:1px solid #efcaca;color:#b53f3f;font-size:11px}
@media(max-width:900px){.cron-grid{grid-template-columns:1fr}.cron-grid>div.wide{grid-column:auto}.background-runtime{grid-template-columns:repeat(2,1fr)}}

/* ===== CUAN V7.16 — NOTIFICATION CENTER FOCUS ===== */
.cuan-alarm-panel-focus{width:min(500px,calc(100vw - 28px));padding:0;overflow:hidden}
.cuan-alarm-panel-focus .cuan-alarm-head{padding:16px 16px 13px;background:#fff}
.cuan-alarm-panel-focus .cuan-alarm-head strong{font-size:15px;letter-spacing:-.01em}
.cuan-alarm-panel-focus .cuan-alarm-head small{font-size:9.5px;margin-top:4px}
.cuan-alarm-status-focus{margin:12px 14px 0;padding:10px 11px;background:#f7fbf8}
.cuan-alarm-history-head-focus{margin:15px 16px 0;padding-bottom:8px;border-bottom:1px solid #edf2ee}
.cuan-alarm-history-head-focus>div b,.cuan-alarm-history-head-focus>div small{display:block}
.cuan-alarm-history-head-focus>div b{font-size:11px;color:#23362a}
.cuan-alarm-history-head-focus>div small{font-size:8.5px;color:#8a968f;margin-top:2px}
.cuan-alarm-list-focus{margin:0;padding:7px 10px 10px;max-height:min(520px,62vh);gap:0}
.cuan-alarm-list-focus .cuan-alert-item{border:0;border-bottom:1px solid #edf2ee;border-radius:0;padding:11px 7px;background:#fff}
.cuan-alarm-list-focus .cuan-alert-item:last-child{border-bottom:0}
.cuan-alarm-list-focus .cuan-alert-item:hover{background:#f8fbf9}
.cuan-alarm-list-focus .cuan-alert-item.unread{background:#f5fbf7}
.cuan-alarm-list-focus .cuan-alert-icon{width:32px;height:32px;border-radius:50%}
.cuan-alarm-list-focus .cuan-alert-copy b{font-size:10.5px;display:flex;align-items:center;gap:6px}
.cuan-alarm-list-focus .cuan-alert-copy span{font-size:9.5px}
.cuan-alarm-list-focus .cuan-alert-copy small{font-size:8.5px}
.cuan-unread-dot{width:6px;height:6px;border-radius:50%;background:#1dad59;box-shadow:0 0 0 3px rgba(29,173,89,.1);flex:0 0 auto}
.cuan-alarm-focus-footer{border-top:1px solid #e9efeb;background:#fafcfb;padding:11px 14px;display:flex;align-items:center;justify-content:space-between;gap:12px}
.cuan-alarm-focus-footer span{font-size:8.5px;color:#7b8981;line-height:1.35;max-width:280px}
.cuan-alarm-focus-footer a{white-space:nowrap;text-decoration:none;border:1px solid #cde1d3;background:#fff;color:#158045;border-radius:9px;padding:8px 10px;font-size:9px;font-weight:850}
.cuan-alarm-focus-footer a:hover{background:#eff8f2}
@media(max-width:620px){.cuan-alarm-panel-focus{right:8px;left:8px;top:62px;width:auto;max-height:calc(100vh - 74px)}.cuan-alarm-list-focus{max-height:55vh}.cuan-alarm-focus-footer{align-items:stretch;flex-direction:column}.cuan-alarm-focus-footer span{max-width:none}.cuan-alarm-focus-footer a{text-align:center}}

/* ===== CUAN V7.18 — GLOBAL LOADING SYSTEM ===== */
.cuan-global-page-loader{position:fixed;inset:0;z-index:99998;display:flex;align-items:center;justify-content:center;background:rgba(247,251,248,.70);backdrop-filter:blur(2px);opacity:0;visibility:hidden;pointer-events:none;transition:opacity .14s ease,visibility .14s ease}
.cuan-global-page-loader.show{opacity:1;visibility:visible;pointer-events:auto}
.cuan-global-loader-card{display:flex;align-items:center;gap:13px;min-width:260px;max-width:calc(100vw - 36px);padding:15px 18px;border:1px solid #dbe9df;border-radius:16px;background:rgba(255,255,255,.97);box-shadow:0 18px 55px rgba(28,69,45,.14)}
.cuan-global-spinner,.cuan-btn-spinner,.cuan-mini-spinner{display:inline-block;border-radius:50%;border-style:solid;border-color:#d4e8da;border-top-color:#12a357;animation:cuanGlobalSpin .72s linear infinite;flex:0 0 auto}
.cuan-global-spinner{width:28px;height:28px;border-width:3px}.cuan-btn-spinner{width:14px;height:14px;border-width:2px}.cuan-mini-spinner{width:13px;height:13px;border-width:2px}
.cuan-global-loader-copy{display:flex;flex-direction:column;gap:2px}.cuan-global-loader-copy b{font-size:13px;color:#193327}.cuan-global-loader-copy small{font-size:9.5px;color:#75837b;line-height:1.35}
.cuan-global-network-loader{position:fixed;right:18px;top:76px;z-index:99997;display:flex;align-items:center;gap:8px;padding:9px 12px;border:1px solid #d5e8db;border-radius:999px;background:rgba(255,255,255,.97);box-shadow:0 8px 30px rgba(20,67,39,.12);opacity:0;visibility:hidden;transform:translateY(-5px);transition:.15s ease;pointer-events:none}
.cuan-global-network-loader.show{opacity:1;visibility:visible;transform:translateY(0)}.cuan-global-network-loader b{font-size:9.5px;color:#1e4933;white-space:nowrap}
.cuan-global-progress{position:fixed;left:0;right:0;top:0;height:3px;z-index:99999;overflow:hidden;opacity:0;pointer-events:none;background:rgba(18,163,87,.08);transition:opacity .12s}.cuan-global-progress.show{opacity:1}.cuan-global-progress i{display:block;height:100%;width:34%;background:#12a357;transform:translateX(-110%)}.cuan-global-progress.indeterminate i{animation:cuanGlobalBar 1.05s ease-in-out infinite}
.cuan-btn-loading{position:relative!important;pointer-events:none!important;cursor:wait!important;display:inline-flex!important;align-items:center!important;justify-content:center!important;gap:7px!important;white-space:nowrap}.cuan-btn-loading-text{display:inline-block}.cuan-btn-loading .cuan-btn-spinner{border-color:rgba(255,255,255,.46);border-top-color:currentColor}.btn.ghost.cuan-btn-loading .cuan-btn-spinner,button:not(.primary).cuan-btn-loading .cuan-btn-spinner{border-color:#d5e6da;border-top-color:#138b4c}
html.cuan-page-busy body{cursor:wait}
@keyframes cuanGlobalSpin{to{transform:rotate(360deg)}}
@keyframes cuanGlobalBar{0%{transform:translateX(-110%)}55%{transform:translateX(150%)}100%{transform:translateX(310%)}}
@media(max-width:720px){.cuan-global-loader-card{min-width:0;width:calc(100vw - 32px)}.cuan-global-network-loader{right:10px;top:66px;max-width:calc(100vw - 20px)}}
@media(prefers-reduced-motion:reduce){.cuan-global-spinner,.cuan-btn-spinner,.cuan-mini-spinner,.cuan-global-progress.indeterminate i{animation-duration:1.8s}}

/* CUAN V7.18.1 — Notification Center: ringkas, satu baris, mudah dipindai */
.cuan-alert-filters{display:flex;gap:6px;padding:8px 10px;border-bottom:1px solid #edf2ee;background:#fff;overflow-x:auto;scrollbar-width:none}
.cuan-alert-filters::-webkit-scrollbar{display:none}
.cuan-alert-filters button{appearance:none;border:1px solid #dbe7df;background:#fff;color:#5c6c62;border-radius:999px;padding:6px 10px;font-size:9px;font-weight:800;line-height:1;cursor:pointer;white-space:nowrap}
.cuan-alert-filters button:hover{background:#f4faf6}
.cuan-alert-filters button.active{background:#153f2b;border-color:#153f2b;color:#fff}
.cuan-alarm-history-simple{padding-bottom:5px}
.cuan-alert-item-simple{grid-template-columns:30px minmax(0,1fr) auto!important;align-items:center!important;padding:9px 7px!important;min-height:48px}
.cuan-alert-item-simple .cuan-alert-icon{width:28px!important;height:28px!important;font-size:14px!important;background:#f5f8f6!important}
.cuan-alert-item-simple .cuan-alert-copy{min-width:0}
.cuan-alert-item-simple .cuan-alert-copy b{font-size:10.5px!important;line-height:1.25!important;font-weight:800!important;color:#14231a!important;white-space:normal}
.cuan-alert-item-simple .cuan-alert-time{font-size:8px!important;color:#8a978f!important;padding-top:0!important}
.cuan-alert-item-simple.macd-up .cuan-alert-icon{background:#e8f8ee!important}
.cuan-alert-item-simple.macd-down .cuan-alert-icon,.cuan-alert-item-simple.danger .cuan-alert-icon{background:#fff0f1!important}
.cuan-alert-item-simple.warning .cuan-alert-icon{background:#fff8e6!important}
.cuan-alert-item-simple.deepai .cuan-alert-icon{background:#eef5ff!important}
.cuan-alarm-focus-footer-simple{padding-top:8px;padding-bottom:8px}
.cuan-alarm-focus-footer-simple span{font-size:8.5px;color:#87948c}
.cuan-alert-toast>div>span{display:none!important}
.cuan-alert-toast>div b{font-size:12px;line-height:1.3}
@media(max-width:620px){.cuan-alert-filters{padding-left:8px;padding-right:8px}.cuan-alert-item-simple .cuan-alert-copy b{font-size:11px!important}}
