@font-face{font-family:Plex;src:url('/assets/plex-ar-400.woff2') format('woff2');font-weight:400;font-display:swap}
@font-face{font-family:Plex;src:url('/assets/plex-ar-600.woff2') format('woff2');font-weight:600;font-display:swap}
:root{--bg:#f5f7f9;--surface:#fff;--ink:#17252a;--muted:#6e7b80;--line:#e0e7e9;--green:#147d68;--green-dark:#0c5c4c;--green-soft:#eaf6f1;--red:#a53636;--red-soft:#fff0ee;--yellow:#8f6413;--yellow-soft:#fff7e5;--radius:16px;--shadow:0 8px 30px #173a3510;font-family:Plex,Arial,sans-serif;color:var(--ink);background:var(--bg);font-size:15px;line-height:1.65}
*{box-sizing:border-box}body{margin:0}button,input,select,textarea{font:inherit}button{cursor:pointer}button:disabled{cursor:wait;opacity:.52}button:focus-visible,a:focus-visible,input:focus-visible,select:focus-visible,textarea:focus-visible,img:focus-visible{outline:3px solid #69bba3;outline-offset:3px}[hidden]{display:none!important}a{color:var(--green);text-decoration:none}h1,h2,h3,p{margin-top:0}h1{font-size:30px;line-height:1.45;margin-bottom:6px}h2{font-size:20px;margin-bottom:6px}h3{font-size:17px;margin-bottom:10px}p{margin-bottom:12px}small{font-size:12px;font-weight:400;color:var(--muted);display:block;line-height:1.7}strong,b,h1,h2,h3{font-weight:600}.muted{color:var(--muted);font-size:13px;line-height:1.8}.eyebrow{font-size:12px;font-weight:600;color:var(--green);margin-bottom:4px}.brand{display:inline-flex;align-items:center;gap:11px;color:var(--ink);font-size:20px;font-weight:600;line-height:1.4}.brand small{font-size:10px;letter-spacing:.02em}.brand-mark{background:var(--green);color:white;border-radius:13px;width:40px;height:42px;display:inline-flex;align-items:center;justify-content:center;font-size:28px;font-weight:600}.button{border:1px solid var(--line);background:white;color:var(--ink);border-radius:9px;padding:9px 16px;font-size:13px;font-weight:600;white-space:nowrap;line-height:1.7;transition:background .15s,border-color .15s}.button:hover:not(:disabled){border-color:#a2bcb3;background:#f6faf8}.button.primary{background:var(--green);color:white;border-color:var(--green)}.button.primary:hover:not(:disabled){background:var(--green-dark)}.button.subtle{background:transparent}.button.danger{background:var(--red-soft);border-color:#f0d5d1;color:var(--red)}.button.wide{width:100%;padding:12px}.text-button{border:0;background:transparent;font-size:12px;font-weight:600;color:var(--muted);padding:8px 0}.text-button:hover{text-decoration:underline}.text-button.danger{color:var(--red)}.icon-button{border:0;background:#f3f6f5;width:32px;height:32px;border-radius:8px;font-size:25px;line-height:1}.action-row{display:flex;gap:8px;align-items:center;flex-wrap:wrap}label{display:block;font-size:13px;font-weight:600}input,select,textarea{width:100%;display:block;border:1px solid #d7e0e2;border-radius:8px;background:white;color:var(--ink);padding:10px 12px;font-size:13px;line-height:1.6;margin-top:6px;min-width:0}input::placeholder,textarea::placeholder{color:#9ba6a9;font-size:12px}textarea{resize:vertical;min-height:70px}input[type=checkbox]{display:inline-block;width:17px;height:17px;margin:0;accent-color:var(--green);flex-shrink:0}label small{margin-top:5px}.check-label{display:flex;align-items:center;gap:9px;font-weight:400;font-size:13px}.error-text{color:var(--red);font-size:13px;white-space:pre-wrap;overflow-wrap:anywhere}.card{background:white;border:1px solid var(--line);border-radius:var(--radius);padding:23px;box-shadow:0 3px 12px #173a3503}.pill{display:inline-flex;border-radius:99px;padding:5px 11px;background:#edf0f2;font-size:11px;font-weight:600;white-space:nowrap}.pill.good{background:var(--green-soft);color:var(--green)}.pill.warn{background:var(--yellow-soft);color:var(--yellow)}.pill.bad{background:var(--red-soft);color:var(--red)}.count{font-size:11px;background:#e7eeec;color:#6a7e76;border-radius:7px;min-width:25px;text-align:center;padding:2px 6px}#notice{position:fixed;bottom:22px;left:24px;right:24px;max-width:640px;margin:auto;border-radius:12px;padding:14px 20px;box-shadow:0 8px 35px #1235;background:#173a32;color:white;z-index:30;font-size:13px;white-space:pre-wrap}#notice.error{background:#8c3532}.boot-view{height:100vh;display:flex;flex-direction:column;gap:15px;align-items:center;justify-content:center;color:var(--muted)}
.auth-shell{min-height:100vh;display:grid;grid-template-columns:minmax(280px,1fr) minmax(360px,1fr);background:#fff}.auth-intro{background:#edf5f0;padding:50px 11%;display:flex;flex-direction:column;justify-content:space-between;min-height:100vh;background-image:radial-gradient(ellipse at 0% 100%,#bddcce99,transparent 65%)}.auth-intro h1{font-size:43px;line-height:1.5;margin-bottom:20px}.intro-text{max-width:350px;font-size:16px;color:#61786d}.intro-foot{font-size:12px;color:#678274;margin-bottom:0}.auth-card{width:100%;max-width:480px;align-self:center;justify-self:center;padding:45px}.auth-card h2{font-size:26px;margin-top:8px}.auth-card form{display:grid;gap:18px;margin-top:28px}.segmented{display:flex;border-bottom:1px solid var(--line);margin-bottom:32px;gap:25px}.segmented button{background:none;border:0;border-bottom:2px solid transparent;padding:9px 0 12px;color:var(--muted);font-size:13px}.segmented button.selected{border-color:var(--green);color:var(--green);font-weight:600}
.topbar{height:78px;background:white;border-bottom:1px solid var(--line);display:flex;align-items:center;justify-content:space-between;padding:0 30px;gap:20px}.topbar-actions{display:flex;align-items:center;gap:10px}.user-name{font-size:13px;margin-inline-end:8px}.workspace{display:grid;grid-template-columns:272px minmax(0,1fr);min-height:calc(100vh - 78px)}.sidebar{border-inline-end:1px solid var(--line);padding:32px 20px;background:#f9fbfa}.sidebar-heading{display:flex;align-items:center;justify-content:space-between;gap:10px;margin:0 6px 22px}.sidebar-heading h2{font-size:17px}.accounts-list{display:grid;gap:7px}.account-item{width:100%;background:none;text-align:start;border:1px solid transparent;border-radius:10px;padding:12px;display:flex;align-items:center;justify-content:space-between;gap:10px}.account-item:hover{background:#edf4f0}.account-item.selected{background:#e6f1eb;border-color:#c8dfd1}.account-item .account-item-name{font-size:13px;font-weight:600;display:block;overflow-wrap:anywhere}.account-item small{font-size:10px}.status-dot{width:8px;height:8px;min-width:8px;border-radius:50%;background:#bcc6c6}.status-dot.running{background:#209471}.status-dot.starting{background:#d6a132}.status-dot.error{background:#c45950}.account-add{margin-top:25px;border-top:1px solid var(--line);padding:22px 6px 0}.account-add label{font-size:12px;margin-bottom:9px}.inline-input{display:flex;gap:7px;align-items:center}.inline-input input{margin:0}.account-add .button{padding:9px 11px}.account-add small{margin-top:10px}.sidebar-note{font-size:11px;color:#8a9691;line-height:1.9;margin:25px 6px}.main-content{padding:30px 38px 40px;max-width:1300px;min-width:0;width:100%}.account-heading{display:flex;align-items:center;justify-content:space-between;gap:18px;margin-bottom:22px}.heading-status{display:flex;gap:7px;flex-wrap:wrap;justify-content:flex-end}.account-actions{display:flex;justify-content:space-between;align-items:center;gap:22px;margin-bottom:18px}.account-actions h2{font-size:16px}.account-actions p{margin-bottom:0;font-size:12px}.account-actions .error-text{margin-top:8px}.callout{background:#eaf0f6;border:1px solid #d8e3ed;color:#496272;border-radius:12px;font-size:13px;padding:17px 22px;margin-bottom:20px}.automation-bar{padding:18px 22px;display:flex;gap:20px;align-items:center;justify-content:space-between;border:1px solid #cce2d7;background:#edf7f1;border-radius:12px;margin-bottom:22px}.automation-bar strong{font-size:14px}.automation-bar p{font-size:12px;color:#668173;margin:3px 0 0}.automation-bar.active{background:#e1f3e8;border-color:#9dcbb1}.section-tabs{display:flex;gap:22px;border-bottom:1px solid var(--line);overflow:auto;white-space:nowrap;margin:0 0 25px;scrollbar-width:thin}.section-tabs button{border:0;border-bottom:2px solid transparent;background:transparent;color:var(--muted);font-size:12px;padding:10px 0 13px;font-weight:600}.section-tabs button.selected{color:var(--green);border-color:var(--green)}.section-heading{display:flex;align-items:center;justify-content:space-between;gap:16px;margin-bottom:16px}.section-heading h2{font-size:19px}.section-heading p{font-size:12px;color:var(--muted);margin:0}.section-heading h3{margin:0}.list-heading{margin-top:27px}.settings-form{display:grid;gap:20px}.switch-row{display:flex;align-items:center;gap:13px;border-bottom:1px solid var(--line);padding-bottom:19px}.switch-row strong{font-size:14px}.switch-row small{margin:3px 0 0}.fields-grid{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:17px}.fields-grid.four{grid-template-columns:repeat(4,minmax(0,1fr))}.form-footer{display:flex;align-items:center;justify-content:flex-end;gap:15px;padding-top:5px;flex-wrap:wrap}.form-footer>.muted{margin-inline-end:auto;font-size:11px;max-width:400px}.add-watched{display:grid;grid-template-columns:1fr 1.65fr auto;align-items:end;gap:13px;margin-bottom:13px;padding:18px}.watched-list{display:grid;gap:10px}.watched-card{border:1px solid var(--line);border-radius:12px;background:white;padding:18px 20px}.watched-top{display:flex;align-items:flex-start;justify-content:space-between;gap:13px}.watched-top h3{margin:0 0 4px;font-size:14px;overflow-wrap:anywhere}.watched-url{font-size:11px;overflow-wrap:anywhere;display:block;max-width:100%;direction:ltr;text-align:right;line-height:1.6}.watched-meta{display:flex;flex-wrap:wrap;gap:14px;font-size:11px;color:var(--muted);margin-top:12px}.watched-actions{display:flex;gap:8px;margin-top:14px;padding-top:12px;border-top:1px solid #eff2f2;flex-wrap:wrap}.watched-actions .button{font-size:11px;padding:6px 11px}.watched-error{color:var(--red);font-size:11px;margin:9px 0 0;white-space:pre-wrap}.empty-list{border:1px dashed #d1ded7;border-radius:12px;text-align:center;color:var(--muted);font-size:13px;padding:32px 20px;background:#fafcfb}.empty-list strong{display:block;color:#4f665b;margin-bottom:5px}.rule-preview{font-size:13px;white-space:pre-wrap;overflow-wrap:anywhere;color:#61706c;margin:10px 0}.rule-questions{font-size:12px;color:var(--green);white-space:pre-wrap}.account-manage{display:flex;gap:25px;border-top:1px solid var(--line);margin-top:35px;padding-top:15px}.welcome-state{max-width:580px;text-align:center;margin:95px auto 0}.welcome-state p:not(.eyebrow){font-size:14px;max-width:440px;margin:15px auto;color:var(--muted)}.welcome-icon{display:inline-flex;align-items:center;justify-content:center;width:72px;height:72px;background:#e0eee6;border-radius:23px;color:var(--green);font-size:46px;margin-bottom:25px}.welcome-state h1{font-size:29px}.steps{display:flex;justify-content:center;gap:20px;margin-top:30px;font-size:12px;color:#73867c;flex-wrap:wrap}.steps b{display:inline-flex;width:22px;height:22px;background:#e5ece8;border-radius:50%;justify-content:center;margin-inline-end:5px}.extension-shortcut{display:flex;align-items:center;justify-content:space-between;gap:20px;margin-top:18px}.extension-shortcut p{margin:0}.activity-list{display:grid;gap:8px}.activity-item{border:1px solid var(--line);border-radius:10px;padding:15px 18px;background:white;font-size:12px}.activity-heading{display:flex;align-items:center;justify-content:space-between;gap:12px}.activity-heading strong{font-size:13px}.activity-heading time{font-size:10px;color:var(--muted);white-space:nowrap}.activity-item p{font-size:12px;color:#63716d;white-space:pre-wrap;overflow-wrap:anywhere;margin:7px 0 0}.activity-item a{font-size:11px}.activity-answer{border-inline-start:2px solid #b8d6c5;padding-inline-start:10px}
dialog{border:1px solid var(--line);border-radius:18px;padding:26px;max-width:500px;width:calc(100% - 32px);box-shadow:0 30px 90px #0d291c40;color:var(--ink);max-height:calc(100dvh - 40px);overflow:auto}dialog::backdrop{background:#102c28aa;backdrop-filter:blur(3px)}.dialog-heading{display:flex;align-items:flex-start;justify-content:space-between;gap:15px;margin-bottom:15px}.dialog-heading h2{font-size:20px;margin:0}.dialog-heading p{margin:4px 0 0;font-size:11px}.remote-dialog{width:min(1060px,calc(100% - 30px));max-width:1060px;padding:20px}.remote-toolbar{display:flex;gap:7px;align-items:end;flex-wrap:wrap}.remote-toolbar .button{font-size:11px;padding:7px 12px}.remote-tabs-label{min-width:160px;flex:1;font-size:10px;max-width:340px;margin-inline-start:auto}.remote-tabs-label select{margin:0;font-size:11px;padding:7px}.remote-page-label{font-size:10px;color:var(--muted);overflow:hidden;text-overflow:ellipsis;white-space:nowrap;direction:ltr;margin:9px 0}.remote-stage{position:relative;border:1px solid #d6e1db;border-radius:8px;background:#e9efec;overflow:hidden;min-height:150px;display:flex;align-items:center;justify-content:center}.remote-stage img{display:block;width:100%;height:auto;cursor:crosshair;touch-action:manipulation;user-select:none}.remote-stage img:not([src]){display:none}.remote-stage p{color:var(--muted);font-size:13px;margin:30px}.remote-type-form{padding-top:15px;display:grid;gap:8px}.remote-type-form>label{font-size:11px}.remote-type-form .inline-input input{font-size:13px}.remote-type-form .check-label{font-size:11px}.remote-keyboard{display:flex;gap:6px;flex-wrap:wrap;margin-top:12px}.remote-keyboard .button{font-size:10px;padding:6px 10px}.remote-note{font-size:10px;color:var(--muted);margin:12px 0 0}
@media(min-width:1500px){.main-content{padding-inline:55px}}@media(max-width:1100px){.main-content{padding:25px}.workspace{grid-template-columns:235px minmax(0,1fr)}.sidebar{padding:25px 15px}.account-actions{align-items:flex-start;flex-direction:column;gap:15px}.fields-grid.four{grid-template-columns:repeat(2,minmax(0,1fr))}.section-tabs{gap:18px}.add-watched{grid-template-columns:1fr 1.4fr}.add-watched>.button{grid-column:1/-1;justify-self:end}.auth-intro{padding:45px 10%}.auth-intro h1{font-size:36px}}@media(max-width:760px){.topbar{height:auto;min-height:72px;padding:15px 18px;flex-wrap:wrap;gap:12px}.brand{font-size:18px}.topbar-actions{gap:7px}.user-name{font-size:11px}.topbar-actions .button{font-size:11px;padding:6px 9px}.workspace{display:block}.sidebar{border-inline-end:0;border-bottom:1px solid var(--line);padding:18px}.sidebar-heading{margin:0 0 10px}.sidebar-heading .eyebrow,.sidebar-note{display:none}.sidebar-heading h2{font-size:14px;margin:0}.accounts-list{display:flex;overflow:auto;gap:7px}.account-item{min-width:160px;max-width:220px;padding:9px 12px;flex-shrink:0}.account-item small{font-size:9px}.account-add{margin-top:12px;padding:12px 0 0}.account-add>label{margin:0 0 6px}.account-add small{display:none}.main-content{padding:23px 18px}.account-heading{align-items:flex-start;flex-direction:column;gap:9px;margin-bottom:18px}.account-heading h1{font-size:25px}.account-subtitle{font-size:11px}.heading-status{justify-content:flex-start}.card{padding:18px}.account-actions{gap:14px}.action-row{gap:7px}.action-row .button{font-size:11px;padding:8px 11px}.automation-bar{padding:16px;align-items:flex-start;gap:13px;flex-direction:column}.automation-bar p{font-size:11px}.automation-bar .button{width:100%}.section-tabs{margin-bottom:22px;gap:23px}.section-heading h2{font-size:17px}.section-heading p{font-size:11px}.fields-grid{gap:13px}.settings-form{gap:18px}.form-footer>.muted{width:100%;max-width:none}.form-footer .button{width:100%}.add-watched{display:flex;flex-direction:column;align-items:stretch;gap:13px}.add-watched>.button{width:100%}.watched-card{padding:16px}.watched-meta{gap:7px 13px}.extension-shortcut{align-items:flex-start;flex-direction:column}.account-manage{gap:20px}.welcome-state{margin:45px auto}.welcome-state h1{font-size:25px}.welcome-state p:not(.eyebrow){font-size:13px}.steps{gap:13px;font-size:11px}.auth-shell{display:block;min-height:100dvh}.auth-intro{padding:25px 25px 28px;min-height:0;gap:27px}.auth-intro>div:nth-child(2) h1{font-size:27px;line-height:1.5;margin-bottom:10px}.auth-intro h1 br{display:none}.auth-intro .eyebrow{display:none}.intro-text{font-size:13px;max-width:none;margin:0}.intro-foot{display:none}.auth-card{padding:30px 25px;max-width:480px}.auth-card h2{font-size:23px}.segmented{margin-bottom:22px}.auth-card form{margin-top:23px}.remote-dialog{padding:14px;width:calc(100% - 16px);max-height:calc(100dvh - 16px);border-radius:12px}.remote-dialog .dialog-heading h2{font-size:16px}.remote-dialog .dialog-heading p{font-size:10px}.remote-toolbar{gap:5px}.remote-toolbar .button{font-size:10px;padding:6px 9px}.remote-tabs-label{max-width:none;flex-basis:100%;margin:3px 0 0}.remote-keyboard .button{font-size:10px;padding:6px 8px}.remote-note{font-size:9px}.remote-type-form .button{padding:9px;font-size:11px}#notice{bottom:12px;left:12px;right:12px;font-size:12px}.activity-heading{align-items:flex-start;flex-direction:column;gap:4px}}@media(prefers-reduced-motion:reduce){*{transition:none!important;scroll-behavior:auto!important}}
.transfer-steps{font-size:13px;padding-inline-start:20px;margin:0 0 14px;line-height:2}.remote-hint{font-size:12px;color:var(--muted);margin:0 0 9px}.remote-stage:focus-within{outline:3px solid var(--green);outline-offset:2px}.remote-stage img:focus{outline:none}.remote-stage.typing::after{content:'الكيبورد متصل بالشاشة';position:absolute;top:8px;inset-inline-start:8px;background:var(--green);color:#fff;font-size:11px;font-weight:600;border-radius:7px;padding:3px 9px;pointer-events:none}.remote-extra{margin-top:12px;font-size:12px}.remote-extra summary{cursor:pointer;color:var(--muted);font-weight:600;padding:4px 0}
/* الوضع الليلي: يتبع إعداد الجهاز مثل لوحة الإضافة، وبنفس ألوانها */
@media(prefers-color-scheme:dark){:root{--bg:#14181D;--surface:#1C2229;--ink:#E6E9EC;--muted:#98A1AD;--line:#2C343D;--field:#171C22;--green:#5BB098;--green-dark:#74C2AC;--green-soft:#1D3530;--red:#F2827A;--red-soft:#3A1F1E;--yellow:#E7B85A;--yellow-soft:#362C17;--shadow:0 8px 30px #0006;color-scheme:dark}
.button,.card,.watched-card,.activity-item,.topbar,dialog,.auth-shell{background:var(--surface);color:var(--ink)}.button:hover:not(:disabled){background:#232A32;border-color:#3A4550}.button.primary{color:#0E2620}.button.danger{border-color:#5A2E2B}.brand-mark{color:#0E2620}
input,select,textarea{background:var(--field);border-color:var(--line);color:var(--ink)}input::placeholder,textarea::placeholder{color:#6B7480}
.icon-button{background:#232A32;color:var(--ink)}.pill{background:#262E36}.count{background:#262E36;color:var(--muted)}
.auth-intro{background:#17201F;background-image:radial-gradient(ellipse at 0% 100%,#1D353099,transparent 65%)}.intro-text,.intro-foot{color:var(--muted)}
.sidebar{background:#181D23}.account-item:hover{background:#1F272E}.account-item.selected{background:var(--green-soft);border-color:#2E4D45}.sidebar-note{color:var(--muted)}
.callout{background:#1A2530;border-color:#27384A;color:#A9BDCD}.automation-bar{background:#17241F;border-color:#24443A}.automation-bar.active{background:#1D3530;border-color:#2F6152}.automation-bar p{color:var(--muted)}
.watched-actions{border-top-color:var(--line)}.empty-list{background:#181D23;border-color:var(--line)}.empty-list strong{color:var(--ink)}.rule-preview,.activity-item p{color:var(--muted)}.activity-answer{border-inline-start-color:#2F6152}
.welcome-icon{background:var(--green-soft)}.steps{color:var(--muted)}.steps b{background:#262E36}
#notice{background:#24443A}#notice.error{background:#5A2E2B}dialog::backdrop{background:#000a}.remote-stage{background:#11151A;border-color:var(--line)}.remote-stage.typing::after{color:#0E2620}}
