/* Keizoku "Retro OS" special theme: a late-90s desktop.
   Windows with title bars, bevelled buttons, a taskbar with Start, and a teal desktop.
   Builds on the shared flat layer in themes.css; everything here is scoped to data-skin="retroos". */

:root[data-skin="retroos"]{
  --bg1:#008080;--bg2:#008080;--bg3:#008080;
  --glass:#c0c0c0;--glass2:#c0c0c0;--edge:#808080;--shadow:rgba(0,0,0,.35);
  --ink:#000000;--sub:#3c3c3c;--phy:#000080;--chem:#007a3d;--math:#7a1fa2;--hot:#a00000;
  --acc:#000080;--on-acc:#ffffff;--inv:#ffffff;
  --page:#008080;
  --card-bg:#c0c0c0;--card-bd:0;--card-r:0;--chip-r:0;
  --tile-bg:#ffffff;--tile-bd:0;
  --t-font:Tahoma,"Segoe UI",Verdana,"Noto Sans",sans-serif;--t-num:Tahoma,"Segoe UI",Verdana,sans-serif;--t-title:Tahoma,"Segoe UI",Verdana,sans-serif;
  --os-face:#c0c0c0;--os-hi:#ffffff;--os-lo:#808080;--os-dk:#000000;--os-li:#dfdfdf;
  --os-title:linear-gradient(90deg,#000080,#1084d0);
  --os-raised:inset -1px -1px #000,inset 1px 1px #fff,inset -2px -2px #808080,inset 2px 2px #dfdfdf;
  --os-pressed:inset -1px -1px #fff,inset 1px 1px #000,inset -2px -2px #dfdfdf,inset 2px 2px #808080;
  --os-sunken:inset -1px -1px #fff,inset 1px 1px #808080,inset -2px -2px #dfdfdf,inset 2px 2px #000;
  color-scheme:light;
}

/* ---------- desktop ---------- */
html:root:root:root[data-skin="retroos"] body{background:#008080!important;color:#000;font-family:var(--t-font)!important;font-size:14px;padding-bottom:calc(58px + env(safe-area-inset-bottom,0px))!important}
html:root:root:root[data-skin="retroos"] body *{font-family:var(--t-font)!important}
html:root:root:root[data-skin="retroos"] body ::selection{background:#000080;color:#fff}
html:root:root:root[data-skin="retroos"] body .mark-by{color:#e6f4f4}
html:root:root:root[data-skin="retroos"] body .mark-by b{color:#fff}

/* ---------- header becomes the main window's title bar ---------- */
html:root:root:root[data-skin="retroos"] body h1{background:var(--os-title)!important;border:0!important;border-radius:0!important;box-shadow:var(--os-raised),0 0 0 2px #c0c0c0!important;min-height:0!important;padding:6px 64px 6px 10px!important;justify-content:flex-start!important;position:relative}
html:root:root:root[data-skin="retroos"] body h1 .ib,html:root:root:root[data-skin="retroos"] body h1 .cm{display:none!important}
html:root:root:root[data-skin="retroos"] body h1 span{color:#fff!important;-webkit-text-fill-color:#fff!important;font-size:1rem!important;font-weight:700!important;letter-spacing:0!important;text-transform:none!important;padding-left:24px!important;position:relative}
html:root:root:root[data-skin="retroos"] body h1 span::before{content:"";position:absolute;left:0;top:50%;width:16px;height:16px;margin-top:-8px;background:conic-gradient(#ff3b30 0 25%,#34c759 0 50%,#ffcc00 0 75%,#007aff 0);transform:skew(-8deg);border:1px solid #fff}
html:root:root:root[data-skin="retroos"] body h1::after{content:"";position:absolute;right:6px;top:50%;margin-top:-9px;width:54px;height:18px;background:url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='54' height='18'%3E%3Cg font-family='Tahoma,sans-serif' font-size='11' font-weight='700' text-anchor='middle'%3E%3Crect x='0' y='1' width='16' height='14' fill='%23c0c0c0' stroke='%23000' stroke-width='1'/%3E%3Cpath d='M1 14V2h14' stroke='%23fff' fill='none'/%3E%3Crect x='4' y='10' width='7' height='2' fill='%23000'/%3E%3Crect x='18' y='1' width='16' height='14' fill='%23c0c0c0' stroke='%23000'/%3E%3Cpath d='M19 14V2h14' stroke='%23fff' fill='none'/%3E%3Crect x='22' y='4' width='9' height='8' fill='none' stroke='%23000' stroke-width='1.5'/%3E%3Crect x='38' y='1' width='16' height='14' fill='%23c0c0c0' stroke='%23000'/%3E%3Cpath d='M39 14V2h14' stroke='%23fff' fill='none'/%3E%3Cpath d='M42 4l8 8M50 4l-8 8' stroke='%23000' stroke-width='1.6'/%3E%3C/g%3E%3C/svg%3E") no-repeat}

/* ---------- windows: cards, the timer and dialogs ---------- */
html:root:root:root[data-skin="retroos"] body :is(.card,.tpanel,.dlg){background:#c0c0c0!important;border:0!important;border-radius:0!important;box-shadow:var(--os-raised)!important;padding:30px 12px 12px!important;position:relative;color:#000}
html:root:root:root[data-skin="retroos"] body :is(.card,.tpanel,.dlg)::before{content:attr(data-ost);position:absolute;left:3px;right:3px;top:3px;height:20px;background:var(--os-title);color:#fff;font:700 12px/20px var(--t-font);padding:0 62px 0 6px;white-space:nowrap;overflow:hidden;text-overflow:ellipsis;display:block!important;border:0!important;width:auto!important;transform:none!important;z-index:1}
html:root:root:root[data-skin="retroos"] body :is(.card,.tpanel,.dlg)::after{content:"";position:absolute;right:6px;top:4px;width:54px;height:18px;background:url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='54' height='18'%3E%3Crect x='0' y='1' width='16' height='14' fill='%23c0c0c0' stroke='%23000'/%3E%3Cpath d='M1 14V2h14' stroke='%23fff' fill='none'/%3E%3Crect x='4' y='10' width='7' height='2' fill='%23000'/%3E%3Crect x='18' y='1' width='16' height='14' fill='%23c0c0c0' stroke='%23000'/%3E%3Cpath d='M19 14V2h14' stroke='%23fff' fill='none'/%3E%3Crect x='22' y='4' width='9' height='8' fill='none' stroke='%23000' stroke-width='1.5'/%3E%3Crect x='38' y='1' width='16' height='14' fill='%23c0c0c0' stroke='%23000'/%3E%3Cpath d='M39 14V2h14' stroke='%23fff' fill='none'/%3E%3Cpath d='M42 4l8 8M50 4l-8 8' stroke='%23000' stroke-width='1.6'/%3E%3C/svg%3E") no-repeat;display:block!important;border:0!important;z-index:2;pointer-events:none}
html:root:root:root[data-skin="retroos"] body .dlg{padding-top:32px!important}
html:root:root:root[data-skin="retroos"] body .ovl{background:rgba(0,0,0,.25)!important;-webkit-backdrop-filter:none!important;backdrop-filter:none!important}
html:root:root:root[data-skin="retroos"] body :is(.lbl,.dh,.cflb,.setsec,small,.pnote,.empty){color:#3c3c3c}
html:root:root:root[data-skin="retroos"] body .dh{color:#000!important}

/* inner panels: flat groups and sunken fields */
html:root:root:root[data-skin="retroos"] body :is(.glass:not(.card):not(.dlg):not(.tpanel):not(.nav):not(.navpill):not(.navcirc):not(.seg):not(.bdpick):not(.skinmenu)){background:#c0c0c0!important;border:0!important;border-radius:0!important;box-shadow:var(--os-raised)!important}
html:root:root:root[data-skin="retroos"] body .unit{background:#fff!important;border:0!important;border-radius:0!important;box-shadow:var(--os-sunken)!important}
html:root:root:root[data-skin="retroos"] body .unit b{color:#000080!important}
html:root:root:root[data-skin="retroos"] body .unit:first-child{background:#000080!important}
html:root:root:root[data-skin="retroos"] body .unit:first-child *{color:#fff!important}

/* ---------- buttons ---------- */
html:root:root:root[data-skin="retroos"] body :is(button.tbtn,.btn,.task,.chip,.tab,.reset,.qn,.cfseg button,.cfft,.rvtag,.rvadd,.lkbtn,.addbd,.ctaddbtn,.exsw,.lockbtn,.bdpick,.kssel,.seg button,.plsub,.sbp,.plgo,.difb,.plnav,.difback,.rvsx,.sbdel,.tdx,.mkaddb,.mkretry,.mkeve,.pk-trig,.rvpre button){background:#c0c0c0!important;background-image:none!important;color:#000!important;border:0!important;border-radius:0!important;box-shadow:var(--os-raised)!important;text-shadow:none!important;-webkit-backdrop-filter:none!important;backdrop-filter:none!important}
html:root:root:root[data-skin="retroos"] body :is(button.tbtn,.btn,.task,.chip,.tab,.cfft,.seg button,.plsub,.sbp,.plgo,.difb,.bdpick,.kssel):active{box-shadow:var(--os-pressed)!important}
html:root:root:root[data-skin="retroos"] body :is(.tbtn.main,.btn){font-weight:700;outline:1px solid #000;outline-offset:-1px}
html:root:root:root[data-skin="retroos"] body :is(.tab.on,.task.on,.tasks .task.on,.seg button.on,.chip.on,.cfseg button.on,.cfft.on,.rvpre button.on,.difb.on,.plsub.on,.sbp.on,.cm.on){background:#dcdcdc!important;background-image:repeating-conic-gradient(#c0c0c0 0 25%,#fff 0 50%) 0 0/2px 2px!important;box-shadow:var(--os-pressed)!important;color:#000!important;font-weight:700}
html:root:root:root[data-skin="retroos"] body :is(.tab.on,.task.on) *{color:#000!important}
html:root:root:root[data-skin="retroos"] body .seg{background:transparent!important;border:0!important;box-shadow:none!important;padding:0!important;gap:4px}
html:root:root:root[data-skin="retroos"] body .tabs .tab small{color:#000080!important;opacity:1}
html:root:root:root[data-skin="retroos"] body .tabs.tscroll .tab::after{background:linear-gradient(90deg,#000080 0 var(--p),#ffffff var(--p))!important;height:4px;box-shadow:inset 1px 1px #808080}

/* ---------- fields ---------- */
html:root:root:root[data-skin="retroos"] body :is(input:not([type=checkbox]):not([type=radio]),textarea,.sel,.tdadd,.mksearch,.absearch){background:#fff!important;color:#000!important;border:0!important;border-radius:0!important;box-shadow:var(--os-sunken)!important}
html:root:root:root[data-skin="retroos"] body .tdadd input{box-shadow:none!important}
html:root:root:root[data-skin="retroos"] body :is(input,textarea):focus{outline:1px dotted #000!important;outline-offset:-4px}
html:root:root:root[data-skin="retroos"] body .kssel{background:#fff!important;box-shadow:var(--os-sunken)!important;padding-right:4px!important}
html:root:root:root[data-skin="retroos"] body .kssel .chev{width:16px;height:16px;display:inline-flex;align-items:center;justify-content:center;background:#c0c0c0;box-shadow:var(--os-raised);color:#000;opacity:1;font-size:.6rem}

/* checkboxes and ticks */
html:root:root:root[data-skin="retroos"] body :is(.mark,.chk,.ck-box){background:#fff!important;border:0!important;border-radius:0!important;box-shadow:var(--os-sunken)!important;color:transparent!important}
html:root:root:root[data-skin="retroos"] body :is(.td.done .mark,.mark[aria-pressed="true"],.plslot.done .plsh .mark){color:#000!important;background:#fff!important;font-weight:700}
html:root:root:root[data-skin="retroos"] body input[type=checkbox]{accent-color:#000080}

/* ---------- progress bars: blocks in a sunken trough ---------- */
html:root:root:root[data-skin="retroos"] body :is(.bar,.difbar,.plbar,.wfbar,.mlsr .bar){background:#fff!important;border-radius:0!important;box-shadow:var(--os-sunken)!important;height:14px!important;padding:2px;box-sizing:border-box}
html:root:root:root[data-skin="retroos"] body :is(.bar>i,.chpb i,.difbar i){border-radius:0!important;background:repeating-linear-gradient(90deg,#000080 0 7px,transparent 7px 9px)!important;height:100%}
html:root:root:root[data-skin="retroos"] body .ring circle:nth-of-type(2){stroke:#000080!important}

/* ---------- menus, popovers ---------- */
html:root:root:root[data-skin="retroos"] body :is(.skinmenu,.bdmenu,.lkmenu,.exmenu,.rvmenu,.ambmenu,.ctmenu,.ksmenu,.rvsylmenu){background:#c0c0c0!important;border:0!important;border-radius:0!important;box-shadow:var(--os-raised),3px 3px 0 rgba(0,0,0,.35)!important;padding:3px!important;-webkit-backdrop-filter:none!important;backdrop-filter:none!important}
html:root:root:root[data-skin="retroos"] body :is(.skinmenu,.bdmenu,.ksmenu) button{border-radius:0!important;color:#000!important;background:transparent!important;box-shadow:none!important}
html:root:root:root[data-skin="retroos"] body :is(.skinmenu,.bdmenu,.ksmenu) button:is(:hover,.on){background:#000080!important;color:#fff!important}
html:root:root:root[data-skin="retroos"] body :is(.skinmenu,.bdmenu,.ksmenu) button:is(:hover,.on) *{color:#fff!important}
html:root:root:root[data-skin="retroos"] body .mh{color:#000080!important;font-weight:700}

/* ---------- Focus.exe ---------- */
html:root:root:root[data-skin="retroos"] body .tpanel .tdisp{color:#000!important;background:#fff;box-shadow:var(--os-sunken);padding:8px 10px;margin:6px 0 4px}
html:root:root:root[data-skin="retroos"] body .tpanel .tdisp:not(.cu)::after{content:"";display:block;height:16px;margin-top:10px;background:linear-gradient(90deg,transparent 0 var(--tp,0%),#fff var(--tp,0%)),repeating-linear-gradient(90deg,#000080 0 8px,transparent 8px 10px);box-shadow:var(--os-sunken);padding:2px}
html:root:root:root[data-skin="retroos"] body .tpanel.done::before{content:"Focus.exe \2014 Complete"}

/* ---------- taskbar ---------- */
html:root:root:root[data-skin="retroos"] body .nav .navdiv{display:none!important}
html:root:root:root[data-skin="retroos"] body .nav button.navhome,html:root:root:root[data-skin="retroos"] body .nav button.navhome.on{background:#c0c0c0!important;background-image:none!important;color:#000!important;box-shadow:var(--os-raised)!important}
html:root:root:root[data-skin="retroos"] body .nav{position:fixed!important;top:auto!important;height:auto!important;min-height:0!important;left:0!important;right:0!important;bottom:0!important;width:auto!important;transform:none!important;z-index:30;margin:0!important;border-radius:0!important;background:#c0c0c0!important;border:0!important;box-shadow:inset 0 1px #dfdfdf,inset 0 2px #fff!important;padding:4px 6px calc(4px + env(safe-area-inset-bottom,0px))!important;display:flex!important;gap:4px!important;align-items:center;max-width:none!important;-webkit-backdrop-filter:none!important;backdrop-filter:none!important}
html:root:root:root[data-skin="retroos"] body .nav::after{content:var(--osclk,"");flex:0 0 auto;margin-left:auto;padding:4px 8px;font-size:12px;box-shadow:inset -1px -1px #fff,inset 1px 1px #808080;color:#000;white-space:nowrap}
html:root:root:root[data-skin="retroos"] body .nav :is(.navpill){display:flex!important;gap:3px!important;flex:1 1 auto;min-width:0;background:none!important;border:0!important;box-shadow:none!important;padding:0!important;overflow-x:auto;scrollbar-width:none}
html:root:root:root[data-skin="retroos"] body .nav button{background:#c0c0c0!important;color:#000!important;border:0!important;border-radius:0!important;box-shadow:var(--os-raised)!important;height:32px;min-width:34px;padding:0 8px!important;flex:0 0 auto!important;font-size:12px!important;display:inline-flex;align-items:center;gap:5px}
html:root:root:root[data-skin="retroos"] body .nav button.on{box-shadow:var(--os-pressed)!important;background-image:repeating-conic-gradient(#c0c0c0 0 25%,#fff 0 50%) 0 0/2px 2px!important;font-weight:700}
html:root:root:root[data-skin="retroos"] body .nav button.on::before,html:root:root:root[data-skin="retroos"] body .nav .navdot{display:none!important}
html:root:root:root[data-skin="retroos"] body .nav .navhome{width:auto!important;height:32px!important;border-radius:0!important;font-weight:700!important;padding:0 10px 0 8px!important}
html:root:root:root[data-skin="retroos"] body .nav .navhome svg{display:none}
html:root:root:root[data-skin="retroos"] body .nav .navhome::before{content:"";display:inline-block!important;width:16px;height:16px;background:conic-gradient(#ff3b30 0 25%,#34c759 0 50%,#ffcc00 0 75%,#007aff 0);transform:skew(-8deg)}
html:root:root:root[data-skin="retroos"] body .nav .navhome::after{content:"Start";font-weight:700;font-size:13px}
html:root:root:root[data-skin="retroos"] body .nav button.navhome.osopen.osopen{box-shadow:var(--os-pressed)!important}
html:root:root:root[data-skin="retroos"] body .nav .nvl{font-size:12px}
@media (max-width:560px){html:root:root:root[data-skin="retroos"] body .nav button:not(.on):not(.navhome) .nvl{display:none}}

/* Start menu */
.osstart{position:fixed;left:4px;bottom:calc(46px + env(safe-area-inset-bottom,0px));z-index:60;display:flex;background:#c0c0c0;box-shadow:inset -1px -1px #000,inset 1px 1px #fff,inset -2px -2px #808080,inset 2px 2px #dfdfdf,3px 3px 0 rgba(0,0,0,.35);padding:3px;min-width:210px;font-family:Tahoma,"Segoe UI",Verdana,sans-serif}
.osstart .osside{width:24px;background:linear-gradient(#000080,#1084d0);color:#fff;writing-mode:vertical-rl;transform:rotate(180deg);display:flex;align-items:center;gap:2px;padding:6px 0;font-size:15px;letter-spacing:.5px}
.osstart .osside span{font-weight:400;opacity:.85}
.osstart .ositems{flex:1;display:flex;flex-direction:column;padding:2px}
.osstart .ositems button{display:flex;align-items:center;gap:10px;border:0;background:transparent;color:#000;font:13px Tahoma,"Segoe UI",Verdana,sans-serif;text-align:left;padding:8px 10px;cursor:pointer}
.osstart .ositems button:is(:hover,:focus-visible){background:#000080;color:#fff;outline:0}
.osstart .osic{width:20px;text-align:center;font-size:15px}
.osstart hr{border:0;border-top:1px solid #808080;border-bottom:1px solid #fff;margin:3px 2px;width:auto}

/* scrollbars */
html:root:root:root[data-skin="retroos"] ::-webkit-scrollbar{width:16px;height:16px;background:repeating-conic-gradient(#c0c0c0 0 25%,#fff 0 50%) 0 0/2px 2px}
html:root:root:root[data-skin="retroos"] ::-webkit-scrollbar-thumb{background:#c0c0c0;box-shadow:inset -1px -1px #000,inset 1px 1px #fff,inset -2px -2px #808080,inset 2px 2px #dfdfdf}

/* swatch in Appearance */
.mat-retroos{border-radius:0;background:#008080;box-shadow:inset 0 0 0 2px #c0c0c0,inset 0 0 0 3px #000;position:relative}
.mat-retroos::after{content:"";position:absolute;left:3px;right:3px;top:3px;height:5px;background:linear-gradient(90deg,#000080,#1084d0)}

/* keep window contents clear of the title bar */
html:root:root:root[data-skin="retroos"] body .herocard .exsw{top:32px!important}
html:root:root:root[data-skin="retroos"] body :is(.card,.tpanel,.dlg)>:is(.x,.dlgx,.close){top:30px!important}
html:root:root:root[data-skin="retroos"] body .ring circle:nth-of-type(1){stroke:#fff!important}
html:root:root:root[data-skin="retroos"] body .ring circle:nth-of-type(2){stroke-linecap:butt}
html:root:root:root[data-skin="retroos"] body .lkbadge{border-radius:0!important;background:#c0c0c0!important;border:0!important;box-shadow:var(--os-raised)!important;color:#000!important}
html:root:root:root[data-skin="retroos"] body .nav button.navhome.navhome::before{content:""!important;display:inline-block!important;position:static!important;width:16px!important;height:16px!important;inset:auto!important;border-radius:0!important;background:conic-gradient(#ff3b30 0 25%,#34c759 0 50%,#ffcc00 0 75%,#007aff 0)!important;transform:skew(-8deg)!important;opacity:1!important}
html:root:root:root[data-skin="retroos"] body .nav button.on:not(.navhome){background:repeating-conic-gradient(#c0c0c0 0 25%,#fff 0 50%) 0 0/2px 2px!important;color:#000!important}
@media (max-width:560px){html:root:root:root[data-skin="retroos"] body .nav button:not(.navhome) .nvl{display:none!important}html:root:root:root[data-skin="retroos"] body .nav button:not(.navhome){padding:0 6px!important;min-width:36px}}
html:root:root:root[data-skin="retroos"] body .nav{overflow:hidden}
/* roadmap: unit headings and mark brackets sit on the desktop, so they read as desktop labels */
html:root:root:root[data-skin="retroos"] body .grp .gt,html:root:root:root[data-skin="retroos"] body .grp .gt *{color:#fff!important}
html:root:root:root[data-skin="retroos"] body .mblk{border-color:#fff!important}
html:root:root:root[data-skin="retroos"] body .mblk .mside,html:root:root:root[data-skin="retroos"] body .mblk .mside *{color:#fff!important}
/* square corners everywhere, like the real thing */
html:root:root:root[data-skin="retroos"] body *:not(svg):not(svg *){border-radius:0!important}
html:root:root:root[data-skin="retroos"] body :is(button.tbtn.main.main,.btn.btn,.tbtn.main.on){background:#c0c0c0!important;background-image:none!important;color:#000!important;box-shadow:var(--os-raised)!important}
html:root:root:root[data-skin="retroos"] body :is(.srows,.langcur){background:#fff!important;border:0!important;box-shadow:var(--os-sunken)!important}
html:root:root:root[data-skin="retroos"] body .pcard{background:#c0c0c0!important;border:0!important;box-shadow:var(--os-raised)!important}
html:root:root:root[data-skin="retroos"] body .si{background:#c0c0c0!important;box-shadow:var(--os-raised)!important;color:#000080!important}
html:root:root:root[data-skin="retroos"] body :is(.card,.tpanel,.dlg)::before{text-align:left!important;letter-spacing:0!important;text-transform:none!important}
html:root:root:root[data-skin="retroos"] body h1{display:flex!important;align-items:center;text-align:left!important}
