/* nse-window.css — shared "old mac" window + desk details (10/29, from tools.html .tool-window)
   needs --ink on the page (nothing here reads --key). font is inherited (Space Mono only). */
:root { --win-ground: #D6D6D6; --win-bar-text: #EDEDED; }

/* ---- window ---- */
.nse-win { border: 1.5px solid var(--ink); background: var(--win-ground); color: var(--ink); min-width: 0; display: flex; flex-direction: column; }
.nse-win__bar { background: var(--ink); color: var(--win-bar-text); padding: 5px 10px; display: flex; justify-content: space-between; align-items: center; gap: 12px; font-size: 12px; font-weight: 700; letter-spacing: .08em; flex-shrink: 0; }
.nse-win__name { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; min-width: 0; }
.nse-win__ctl { display: flex; flex-shrink: 0; }
.nse-win__ctl i { font-style: normal; font-size: 10px; width: 20px; height: 20px; display: inline-flex; align-items: center; justify-content: center; border: 1.5px solid currentColor; line-height: 1; user-select: none; }
.nse-win__ctl i + i { border-left: none; }
.nse-win--ground { --bg: var(--win-ground); }  /* opt-in: controls that paint with --bg sit on the window ground (sound, contact). not on every .nse-win: services' accordion hover reads --bg */
.nse-win__status { border-top: 1.5px solid var(--ink); padding: 4px 10px; font-size: 10px; letter-spacing: .08em; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }

/* ---- desk widgets: move on their own, never touchable (背景は静かに) ---- */
.nse-widget, .nse-widget * { pointer-events: none; user-select: none; }
.nse-clock { padding: 8px 10px 10px; font-size: 11px; letter-spacing: .06em; line-height: 1.5; }
.nse-clock span, .nse-clock b { display: block; }
.nse-clock b { font-size: 22px; letter-spacing: .02em; }
.nse-clock b + span { margin-top: 6px; }
.nse-widget canvas { display: block; width: 100%; height: auto; }

/* ---- desk: band that holds the page's window(s) + widget rail. gutter 48 / 24 at 900- / 16 at 600-. pages keep only their differences ---- */
.nse-desk { position: relative; display: grid; grid-template-columns: minmax(0, 1fr) 220px; gap: 28px; align-items: start; padding: 56px 48px 64px; }
.nse-desk > .nse-vcode { left: 16px; top: 64px; bottom: 72px; }
.nse-desk__rail { display: flex; flex-direction: column; gap: 20px; pointer-events: none; }  /* scrolls away with the page, never sticky */
/* --stack: the rail always sits after the window(s), full width at every size (pages whose content is images: the window reaches the desk gutter on both sides = 48 / 24 at 900- / 16 at 600-) */
.nse-desk--stack { grid-template-columns: minmax(0, 1fr); }
.nse-desk--stack .nse-desk__rail { flex-direction: row; }
.nse-desk--stack .nse-desk__rail > .nse-win { flex: 1 1 0; max-width: 220px; }
@media (max-width: 1339px) {
  .nse-desk { grid-template-columns: minmax(0, 1fr); }
  .nse-desk__rail { flex-direction: row; }  /* after the window(s) in DOM order */
  .nse-desk__rail > .nse-win { flex: 1 1 0; max-width: 220px; }
}
@media (max-width: 900px) {
  .nse-desk { padding: 44px 24px 48px; }
  .nse-desk > .nse-vcode { left: 6px; }
}
@media (max-width: 600px) {
  .nse-desk { padding: 36px 16px 40px; --crop-x: 4px; --crop-y: 12px; }
  .nse-desk > .nse-vcode { display: none; }
  .nse-desk__rail .nse-clock b { font-size: 18px; }
}

/* ---- print details ---- */
.nse-crop { position: absolute; width: 14px; height: 14px; pointer-events: none; border: 0 solid var(--ink); }
.nse-crop.tl { top: var(--crop-y, 24px); left: var(--crop-x, 20px); border-width: 1px 0 0 1px; }
.nse-crop.tr { top: var(--crop-y, 24px); right: var(--crop-x, 20px); border-width: 1px 1px 0 0; }
.nse-crop.bl { bottom: var(--crop-y, 24px); left: var(--crop-x, 20px); border-width: 0 0 1px 1px; }
.nse-crop.br { bottom: var(--crop-y, 24px); right: var(--crop-x, 20px); border-width: 0 1px 1px 0; }
.nse-vcode { position: absolute; writing-mode: vertical-rl; font-size: 9px; letter-spacing: .14em; line-height: 1; white-space: nowrap; overflow: hidden; pointer-events: none; user-select: none; opacity: .6; }
.nse-rules > * + * { border-left: 1px solid var(--ink); padding-left: 12px; }
@media (max-width: 900px) {  /* narrow: stack, so no rule ever lands at a line start */
  .nse-rules { flex-direction: column; align-items: flex-start; }
  .nse-rules > * + * { border-left: 0; padding-left: 0; }
}
