/* The app window on the Mac, Windows and Linux pages: it sits across the
   line between the hero and the numbers, in that platform's own title bar. */

.os-window { position: relative; z-index: 2; margin: clamp(-48px, -4vw, -24px) 0 clamp(-120px, -9vw, -60px); }
.os-window + .section { padding-top: clamp(150px, 15vw, 210px); }
.os-window .wrap { max-width: 1080px; }
.os-win { box-shadow: 0 40px 90px -30px rgba(0, 0, 0, .75), 0 0 0 1px rgba(255, 255, 255, .09) inset; }
.os-win::before {
  content: ""; position: absolute; inset: -40px -60px auto; height: 200px; z-index: -1; pointer-events: none;
  background: radial-gradient(50% 60% at 50% 40%, var(--ember-soft), transparent 70%);
}
.os-win { position: relative; }

/* Running containers and the Share button, as in the app. */
.ap-pill-run { color: var(--a-moss); }
.ap-pill-run::before { background: var(--a-moss); box-shadow: 0 0 0 3px rgba(63, 182, 139, .2); }
.ap-share { display: grid; place-items: center; height: 24px; padding: 0 10px; border-radius: 6px; font-weight: 600; font-size: 12px; color: #fff; background: linear-gradient(180deg, #8A1A48, #6A1238); }

/* Title bars */
.ap-titlebar { display: flex; align-items: center; height: 34px; padding: 0 0 0 14px; background: var(--a-side); border-bottom: 1px solid var(--a-line); font-size: 12px; color: var(--a-muted); }
.ap-tb-name { flex: 1; }
.ap-ctl { display: flex; height: 100%; }
.ap-ctl i { width: 46px; height: 100%; position: relative; }
.os-windows .ap-side, .os-linux .ap-side { padding-top: 14px; }

/* Windows 11: square-ish corners, the three caption buttons at the right. */
.os-windows { border-radius: 8px; font-family: "Segoe UI Variable", "Segoe UI", var(--f-text); }
.ap-tb-win .ap-ctl i::before { content: ""; position: absolute; left: 50%; top: 50%; transform: translate(-50%, -50%); }
.ap-tb-win .min::before { width: 10px; height: 1px; background: var(--a-muted); }
.ap-tb-win .max::before { width: 9px; height: 9px; border: 1px solid var(--a-muted); border-radius: 2px; }
.ap-tb-win .ap-ctl .cls::before, .ap-tb-win .ap-ctl .cls::after { content: ""; position: absolute; left: 50%; top: 50%; width: 12px; height: 1px; background: var(--a-muted); }
.ap-tb-win .ap-ctl .cls::before { transform: translate(-50%, -50%) rotate(45deg); }
.ap-tb-win .ap-ctl .cls::after { transform: translate(-50%, -50%) rotate(-45deg); }

/* GNOME: a taller header bar, the title in the middle, round buttons. */
.os-linux { border-radius: 12px; font-family: Cantarell, "Ubuntu", var(--f-text); }
.ap-tb-gnome { height: 44px; padding: 0 10px 0 56px; }
.ap-tb-gnome .ap-tb-name { text-align: center; font-weight: 700; color: var(--a-text); font-size: 13px; }
.ap-tb-gnome .ap-ctl { gap: 10px; align-items: center; }
.ap-tb-gnome .ap-ctl i { width: 22px; height: 22px; border-radius: 50%; background: var(--a-raised); }
.ap-tb-gnome .ap-ctl i::before { content: ""; position: absolute; left: 50%; top: 50%; transform: translate(-50%, -50%); }
.ap-tb-gnome .min::before { width: 8px; height: 1.5px; background: var(--a-text); }
.ap-tb-gnome .max::before { width: 7px; height: 7px; border: 1.5px solid var(--a-text); }
.ap-tb-gnome .ap-ctl .cls::before, .ap-tb-gnome .ap-ctl .cls::after { content: ""; position: absolute; left: 50%; top: 50%; width: 9px; height: 1.5px; background: var(--a-text); }
.ap-tb-gnome .ap-ctl .cls::before { transform: translate(-50%, -50%) rotate(45deg); }
.ap-tb-gnome .ap-ctl .cls::after { transform: translate(-50%, -50%) rotate(-45deg); }

/* Share in the window: the live badge, the banner over the list. */
.ap-shared { display: inline-flex; align-items: center; gap: 5px; height: 24px; padding: 0 9px; border-radius: 6px; font-size: 11.5px; font-weight: 600; color: #F39BBE; background: rgba(214, 51, 108, .14); border: 1px solid rgba(214, 51, 108, .35); }
.ap-shared i { width: 6px; height: 6px; border-radius: 50%; background: #F06595; animation: ty-blink 1.6s ease-in-out infinite; }
.ap-live-n { color: #F39BBE !important; font-weight: 600; }
.ap-banner { display: flex; align-items: center; gap: 10px; margin: 0 0 12px; padding: 8px 10px; border-radius: 8px; background: linear-gradient(90deg, rgba(214, 51, 108, .14), rgba(214, 51, 108, .04)); border: 1px solid rgba(214, 51, 108, .28); font-size: 12px; }
.ap-banner-u { font-family: var(--f-mono); color: var(--a-text); }
.ap-banner-t { flex: 1; color: var(--a-muted); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.ap-copy { padding: 4px 9px; border-radius: 5px; color: var(--a-text); border: 1px solid var(--a-line); font-weight: 600; font-size: 11.5px; }
@keyframes ty-blink { 50% { opacity: .3; } }

/* The sidebar as it is today: Mac toolbar, theme and Kubernetes switches in
   the headings, computers sharing beside Share, Kubernetes in the VM card. */
.os-win .ap-side, .ap-win .ap-side { padding-top: 48px; }
.os-windows .ap-side, .os-linux .ap-side { padding-top: 14px; }
.ap-toolbar { position: absolute; left: 70px; top: 6px; display: flex; align-items: center; gap: 10px; color: var(--a-muted); }
.ap-tbtn { width: 26px; height: 24px; border-radius: 6px; background: var(--a-raised); display: grid; place-items: center; }
.ap-tbtn svg { width: 15px; height: 15px; fill: none !important; stroke: currentColor; stroke-width: 1.6; }
.ap-nav { font-size: 17px; line-height: 1; }
.ap-nav.off { opacity: .4; }
.ap-h { display: flex; align-items: center; gap: 6px; }
.ap-h-ico { width: 12px !important; height: 12px !important; margin-left: auto; fill: none !important; stroke: var(--a-muted); stroke-width: 1.8; stroke-linecap: round; }
.ap-k8s { margin-left: auto; display: inline-flex; align-items: center; gap: 5px; color: var(--a-muted); font-weight: 600; }
.ap-k8s .ap-h-ico { margin: 0 3px 0 0; width: 11px !important; height: 11px !important; stroke-width: 1.6; }
.ap-k8s i, .ap-on { width: 6px; height: 6px; border-radius: 50%; background: var(--a-moss); display: inline-block; }
.ap-on { margin-right: 5px; vertical-align: 1px; }
.ap-peers { display: inline-flex !important; margin-left: auto; }
.ap-peers i { width: 15px; height: 15px; border-radius: 50%; border: 2px solid var(--a-side); background: #1F5A43; }
.ap-peers i.v { margin-left: -6px; background: #4B3F7A; }
.ap-vm-k { margin: -2px 0 0 !important; }
.ap-vm-k dd { white-space: nowrap; }

/* Narrow windows (phones): the sidebar becomes an icon rail beside the list,
   as a narrow app window would, instead of stacking on top of it. */
@media (max-width: 560px) {
  .ap-win .ap-body { grid-template-columns: 52px minmax(0, 1fr); min-height: 380px; }
  .ap-win .ap-side { border-right: 1px solid var(--a-line); border-bottom: 0; padding: 40px 6px 10px; align-items: center; }
  .ap-win .ap-toolbar, .ap-win .ap-h, .ap-win .ap-vm, .ap-win .ap-i span, .ap-win .ap-peers { display: none !important; }
  .ap-win .ap-lights { left: 8px; gap: 4px; }
  .ap-win .ap-lights i { width: 9px; height: 9px; }
  .ap-win .ap-i { width: 36px; height: 34px; padding: 0; justify-content: center; font-size: 0; gap: 0; }
  .ap-win .ap-i svg { width: 17px; height: 17px; }
  .ap-win .ap-i:nth-of-type(6) { margin-top: 8px; }
  .ap-win .ap-pane { padding: 14px 12px 16px; }
  .ap-banner-t { display: none; }
  .ap-banner { gap: 8px; }
  .ap-banner-u { flex: 1; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
  .ap-win .ap-status .ap-st:not(:last-child) { display: none; }
  .os-windows .ap-side, .os-linux .ap-side { padding-top: 12px; }
  .ap-tb-gnome { padding-left: 14px; }
  .ap-tb-gnome .ap-tb-name { text-align: left; }
}
