/* Ventanas a escala: todo el contenido cabe en el escritorio, sin scroll anidado. */
#win .daytona-screen { container-type: inline-size; }
#win .native-window, #win .native-dialog {
  position: absolute;
  overflow: hidden;
  color: #2e3337;
  background: #f5f6f7;
  border: 1px solid #181c1f;
  border-radius: 1cqw;
  box-shadow: 0 1cqw 3cqw #0007;
  font: 1.7cqw/1.25 Arial, sans-serif;
}
#win .native-window { inset: 7% 3.5% 7%; }
#win .native-title {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: .65cqw 1.2cqw;
  color: #e4e7e9;
  background: linear-gradient(#3b4044, #292e32);
  font-size: 1.7cqw;
  white-space: nowrap;
}
#win .native-title i { font-style: normal; flex: none; margin-left: 1cqw; }
#win .native-menu {
  padding: .7cqw 1.2cqw;
  color: #3c4245;
  background: #e8ebed;
  font-size: 1.5cqw;
  white-space: nowrap;
  border-bottom: 1px solid #c6ccd0;
}
#win .native-dialog .native-menu { display: none; }
#win .calc-window { display: grid; grid-template-rows: 6% 5% 7% 7% 40% 29% 6%; }
#win .calc-toolbar { display: flex; align-items: center; gap: 1.6cqw; padding: .6cqw 1.2cqw; background: #f3f4f4; border-bottom: 1px solid #d1d6d8; }
#win .calc-toolbar > span:first-child { color: #517784; }
#win .calc-font { border: 1px solid #bbc4c8; background: #fff; padding: .4cqw 1cqw; }
#win .calc-formula { display: flex; align-items: center; gap: 1.4cqw; padding: .6cqw; border-bottom: 1px solid #bec9ce; background: #e9edf0; }
#win .calc-formula > span:first-child { width: 9cqw; padding: .5cqw; background: #fff; border: 1px solid #c7d0d4; text-align: center; }
#win .calc-formula b { font: italic 2cqw Georgia, serif; color: #657880; }
#win .calc-formula code { flex: 1; align-self: stretch; display: flex; align-items: center; padding-left: 1cqw; background: #fff; font: 1.7cqw ui-monospace, monospace; }
#win .calc-grid { border-collapse: collapse; table-layout: fixed; width: 100%; height: 100%; background: white; }
#win .calc-grid th, #win .calc-grid td { padding: .6cqw 1cqw; border: 1px solid #d5dde0; font-size: 1.75cqw; text-align: right; white-space: nowrap; }
#win .calc-grid th { background: #e9edef; color: #697c85; font-weight: 400; text-align: center; }
#win .calc-grid th:first-child { width: 4cqw; padding-inline: .4cqw; }
#win .calc-grid td:nth-child(2) { text-align: left; }
#win .calc-head td { font-weight: 700; background: #e5eee2; color: #2f5739; }
#win .calc-total td { background: #edf4e8; font-weight: 700; border-top: 1px solid #8ba47d; }
#win .calc-grid .calc-active { outline: .35cqw solid #2d834f; outline-offset: -.35cqw; background: #e4f4df; }
#win .calc-chart { min-height: 0; padding: 1.4cqw 3cqw; background-color: white; background-image: linear-gradient(#eef1f3 1px, transparent 1px), linear-gradient(90deg, #eef1f3 1px, transparent 1px); background-size: 16cqw 4cqw; }
#win .calc-chart.has-chart { background: #fff; display: flex; flex-direction: column; }
#win .calc-chart > b { font-size: 1.4cqw; font-weight: 500; letter-spacing: .1cqw; color: #62766a; }
#win .calc-chart > div { flex: 1; min-height: 0; display: flex; gap: 5cqw; border-bottom: 1px solid #d4ddd1; padding-top: 2cqw; }
#win .calc-chart > div > span { flex: 1; display: flex; min-height: 0; flex-direction: column; justify-content: flex-end; align-items: center; }
#win .calc-chart i { height: var(--bar); min-height: 1px; width: 75%; background: #829d6d; border-radius: .3cqw .3cqw 0 0; }
#win .calc-chart strong { font-weight: 400; font-size: 1.5cqw; margin-bottom: .4cqw; }
#win .calc-chart small { font-size: 1.4cqw; margin-top: .5cqw; }
#win .calc-empty-note { display: block; margin-top: 2cqw; color: #9aa7ab; font-size: 1.5cqw; }
#win .calc-footer { display: flex; align-items: center; gap: 2cqw; padding: 0 1.4cqw; background: #e9eeec; border-top: 1px solid #cbd5cf; font-size: 1.5cqw; }
#win .calc-footer b { padding: .7cqw 1.3cqw; border-bottom: .4cqw solid #578259; color: #375a38; background: #fff; }
#win .calc-footer > span:last-child { margin-left: auto; color: #657169; }
#win .files-window { display: grid; grid-template-rows: 7% 6% 10% 70% 7%; }
#win .files-path { display: flex; align-items: center; gap: 1.7cqw; padding: 1cqw; background: #e7ebee; border-bottom: 1px solid #c5cdd2; }
#win .files-path > span:nth-child(2) { flex: 1; padding: .9cqw 1.2cqw; background: #fff; border: 1px solid #bfc9ce; border-radius: .4cqw; }
#win .files-body { min-height: 0; display: grid; grid-template-columns: 25% 1fr; background: #fff; }
#win .files-body aside { display: flex; flex-direction: column; padding: 1cqw 0; border-right: 1px solid #d1d7db; background: #edf0f2; gap: .8cqw; color: #515c63; }
#win .files-body aside b { font-size: 1.6cqw; padding: 1.2cqw 1.8cqw .5cqw; color: #8b969d; font-weight: 400; }
#win .files-body aside span { padding: 1cqw 1.8cqw; font-size: 1.6cqw; white-space: nowrap; }
#win .files-body aside .is-selected { background: #bdcfdf; color: #284964; }
#win .files-items { padding: 3cqw 2cqw; display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 2cqw; align-content: start; }
#win .file-item { padding: 1.5cqw 1cqw; display: flex; flex-direction: column; align-items: center; gap: 1.6cqw; border: 1px solid transparent; border-radius: .6cqw; min-width: 0; text-align: center; }
#win .file-item > svg, #win .file-item > img { width: 9cqw; height: 9cqw; object-fit: contain; }
#win .file-item > span { font-size: 1.65cqw; overflow-wrap: anywhere; line-height: 1.4; }
#win .file-item.is-selected { background: #d7e7f4; border-color: #a3c3dc; }
#win .files-items > p { grid-column: 1/-1; color: #8d989f; text-align: center; margin-top: 9cqw; font-size: 1.8cqw; }
#win .files-footer { display: flex; align-items: center; justify-content: space-between; padding: .6cqw 1.4cqw; background: #eef1f2; border-top: 1px solid #d5dbde; font-size: 1.45cqw; color: #65757f; }
#win .files-footer > span { color: #4b7042; }
#win .native-dialog { z-index: 2; border-radius: .9cqw; }
#win .folder-dialog { width: 60%; top: 33%; left: 20%; }
#win .folder-dialog > p { margin: 2cqw 2cqw 1cqw; font-size: 1.8cqw; }
#win .native-input { border: 1px solid #77a6c1; box-shadow: 0 0 0 .3cqw #7bb2d02b; background: #fff; color: #344651; padding: 1.2cqw; font-weight: 400; font-size: 1.9cqw; }
#win .folder-dialog > .native-input { margin: 0 2cqw; }
#win .folder-typing { display: block; width: 0; max-width: max-content; overflow: hidden; white-space: nowrap; animation: folder-name 1s steps(15, end) forwards; }
@keyframes folder-name { to { width: 100%; } }
#win .native-dialog-actions { display: flex; justify-content: end; gap: 1.4cqw; padding: 2cqw; }
#win .native-dialog-actions > span, #win .native-dialog-actions > b { padding: 1.2cqw 3cqw; border: 1px solid #bbc3c8; background: #e9edf0; border-radius: .6cqw; font-weight: 400; font-size: 1.8cqw; }
#win .native-dialog-actions > b { background: #4d83a9; border-color: #426f8c; color: #fff; }
#win .save-dialog { inset: 18% 12% 15%; display: grid; grid-template-rows: 10% 13% 11% 43% 11% 12%; }
#win .save-name { display: flex; align-items: center; gap: 2cqw; padding: 1.4cqw 2cqw; }
#win .save-name > b { flex: 1; }
#win .save-location { padding: 1.2cqw 2cqw; margin: 0 2cqw; background: #e8eef2; border: 1px solid #c7d2da; }
#win .save-empty { margin: 0 2cqw; padding: 3cqw; background: #fff; border-inline: 1px solid #dce1e5; display: flex; flex-direction: column; align-items: center; gap: 1cqw; color: #6e7c85; }
#win .save-empty svg { width: 8cqw; height: 7cqw; }
#win .save-empty small { font-size: 1.4cqw; color: #9ba5ac; }
#win .save-type { display: flex; align-items: center; gap: 1.5cqw; padding: .8cqw 2cqw; font-size: 1.6cqw; }
#win .save-type span { flex: 1; border: 1px solid #becad2; padding: .8cqw; background: #fff; }
#win .save-dialog .native-dialog-actions { padding: .7cqw 2cqw; }
#win .save-dialog .native-dialog-actions > * { padding-block: .7cqw; }
#win .desktop-file-actions { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 10px; padding-top: 14px; }
#win .desktop-file-actions > span { font-size: 10px; color: var(--muted); }
#win .desktop-file-actions > button { padding: 8px 10px; border: 1px solid var(--green-line); border-radius: 7px; color: var(--green); background: var(--green-tint); font-size: 11px; }
#win .blender-file-title { position: absolute; top: 6.6%; left: 31%; width: 38%; padding: .1cqw; color: #d6d6d6; background: #333; text-align: center; font: 1.25cqw/1.2 Arial, sans-serif; }
#win .blender-task-title { position: absolute; top: .5%; left: 13.4%; width: 25%; padding: .1cqw; color: #c8c8c8; background: #303030; font: 1.4cqw/1.2 Arial, sans-serif; white-space: nowrap; }
#win .blender-workspace { left: 9.7%; top: 20.1%; width: 72%; height: 72.7%; display: block; background: #35383c; }
#win .blender-plan-layer, #win .blender-render-layer { position: absolute; inset: 0; display: grid; grid-template-rows: 7% 88% 5%; background: #35383c; }
#win .blender-plan-layer > img, #win .blender-render-layer > img { width: 100%; height: 100%; min-height: 0; object-fit: contain; }
#win .blender-render-layer > img { padding: 1.5cqw .8cqw; background: #222426; }
#win .blender-editor-label { display: flex; align-items: center; justify-content: space-between; padding: .6cqw 1cqw; font: 1.2cqw Arial, sans-serif; color: #c6c9cb; background: #2e3033; }
#win .blender-editor-footer { display: flex; align-items: center; padding: .5cqw 1cqw; font: 1.1cqw Arial, sans-serif; color: #a3a8ac; background: #303337; }
#win .blender-show-plan .blender-render-layer, #win .blender-show-render .blender-plan-layer { display: none; }
#win .blender-showcase .blender-render-layer { animation: blender-preview 18s ease-in-out infinite; }
#win .blender-showcase .blender-plan-layer { animation: blender-plan 18s ease-in-out infinite; }
#win .daytona-pointer.is-looping { animation: blender-cursor 18s ease-in-out infinite; }
#win .blender-showcase .blender-render-layer, #win .blender-showcase .blender-plan-layer, #win .daytona-pointer.is-looping { animation-delay: var(--loop-offset); animation-play-state: var(--loop-state); }
#win .is-paused .folder-typing { animation: none; width: 100%; }
#win .model-render-image { width: 100%; height: auto; }
@keyframes blender-preview {
  0%, 37%, 100% { opacity: 1; }
  43%, 91% { opacity: 0; }
}
@keyframes blender-plan {
  0%, 37%, 100% { opacity: 0; }
  43%, 91% { opacity: 1; }
}
@keyframes blender-cursor {
  0%, 7% { left: 68%; top: 63%; }
  18%, 31% { left: 56%; top: 54%; }
  37% { left: 26%; top: 23%; }
  46% { left: 36%; top: 54%; }
  59% { left: 54%; top: 39%; }
  72% { left: 61%; top: 62%; }
  86% { left: 47%; top: 54%; }
  92% { left: 60%; top: 23%; }
  100% { left: 68%; top: 63%; }
}
@media (prefers-reduced-motion: reduce) {
  #win .blender-showcase .blender-render-layer, #win .blender-showcase .blender-plan-layer, #win .daytona-pointer.is-looping { animation: none; }
  #win .blender-showcase .blender-plan-layer { display: none; }
  #win .folder-typing { animation: none; width: 100%; }
}
