/* Original front elevation based on Hartman Systems' photograph and 20 × 15
   inch enclosure dimensions in Information Display, November 1985, pp. 16, 26. */
.tv-hartman-box { display: none; }

#tv-room[data-model="hartman"][data-view="cabinet"] {
  & #tv-stage {
    width: min(100%, 47rem, max(22rem, calc((100svh - 13rem) * 1.3333)));
    aspect-ratio: 4 / 3;
    container-type: inline-size;
    margin-block: min(4vh, 1.8rem) .75rem;
  }
  & #tv-cabinet, & #tv-channel-knob { display: none; }
  & .tv-hartman-box {
    display: block;
    position: absolute;
    inset: 0;
    isolation: isolate;
    pointer-events: none;
    z-index: 0;
    border-radius: .6% / .8%;
    /* Cool gray enamel, slight tooling grain and a rolled edge under grazing light. */
    background:
      repeating-linear-gradient(167deg, #302e2706 0 .045cqw, transparent .06cqw .21cqw),
      repeating-linear-gradient(91deg, #fffff807 0 .065cqw, transparent .09cqw .32cqw),
      linear-gradient(180deg, #e1e0d3 0%, #cdcec3 .55%, #959a91 1.1%, #bbbeb3 1.8%, transparent 4%),
      linear-gradient(105deg, #b6b9ad, #c7c9bc 24%, #b3b6ab 65%, #a0a497 100%);
    box-shadow: inset .28cqw .28cqw .18cqw #eff0df99, inset -.34cqw -.5cqw .3cqw #52584e,
      0 .55cqw 0 #5a5e54, 0 .94cqw 0 #373b35, 1.15cqw 2.4cqw 2.4cqw #060705a0;
  }
  & .hm-bezel {
    position: absolute;
    left: 10.5%;
    top: 5%;
    width: 79%;
    height: 80%;
    border-radius: 5.4% 5.1% 5.4% 5.2% / 7% 7% 6.5% 6.8%;
    background: linear-gradient(150deg, #4c5049, #55594e 22%, #8a8e81 60%, #b6b9ac 92%);
    box-shadow: 0 .18cqw .14cqw #ebecdb, 0 -.13cqw .14cqw #686c61,
      inset .45cqw .56cqw .8cqw #41463c, inset -.2cqw -.2cqw .32cqw #dee2d1;
  }
  & #tv-screen {
    left: 12%;
    top: 7%;
    width: 76%;
    height: 76%;
    border-radius: 4.6% / 6.1%;
    box-shadow: 0 0 0 .23cqw #242924, 0 .17cqw .25cqw .26cqw #bbc1b1,
      -.23cqw -.31cqw .34cqw .12cqw #565a50;
  }
  & #tv-screen::after {
    background:
      radial-gradient(ellipse at 31% 7%, #e4eee721, transparent 34%),
      radial-gradient(ellipse at 48% 46%, transparent 56%, #08201d18 77%, #0b18164d 96%);
    box-shadow: inset .22cqw .33cqw .5cqw #17251ca1;
  }
  & .hm-ear {
    position: absolute;
    top: 2%;
    bottom: 2.4%;
    width: 4.3%;
    border-radius: .22cqw;
    background: linear-gradient(100deg, #d8dacbc2, #b3b7a980 45%, #a3a79a69);
    box-shadow: inset .12cqw 0 .06cqw #f3f2e0b0, inset -.12cqw 0 .08cqw #6c7466b3;
  }
  & .hm-ear-left { left: .85%; }
  & .hm-ear-right { right: .85%; }
  & .hm-ear::before, & .hm-ear::after {
    content: "";
    position: absolute;
    width: 46%;
    aspect-ratio: 1;
    left: 27%;
    border-radius: 50%;
    background:
      linear-gradient(146deg, transparent 43%, #171b15 46% 52%, #aeb0a1 54%, transparent 58%) center / 76% 76% no-repeat,
      radial-gradient(ellipse at 36% 31%, #c9ccbc 6%, #acafa1 37%, #707669 68%, #40473e 76%);
    box-shadow: -.08cqw -.11cqw .1cqw #777f72, .13cqw .14cqw .1cqw #e0e2d2;
  }
  & .hm-ear::before { top: 3%; }
  & .hm-ear::after { bottom: 3%; transform: rotate(70deg); }
  & .hm-handle {
    position: absolute;
    top: 24%;
    width: 2.35%;
    height: 43%;
    border-radius: 45% / 5%;
    /* Bent black tubing sits forward of the mounting feet. */
    background: linear-gradient(90deg, #191e18, #41483c 19%, #5e6559 34%, #353a30 57%, #1b211a 78%, #171c16 90%);
    box-shadow: .9cqw .9cqw .47cqw #4e5548a3, .16cqw .19cqw .09cqw #32382c;
  }
  & .hm-handle-left { left: 3.95%; }
  & .hm-handle-right { right: 4.15%; }
  & .hm-handle::before, & .hm-handle::after {
    content: "";
    position: absolute;
    left: -6%;
    width: 123%;
    height: 11%;
    border-radius: 35% / 26%;
    background: linear-gradient(160deg, #757a6a, #3d4437 23%, #282e25 56%, #181c16);
    box-shadow: .45cqw .1cqw .18cqw #464e3f99;
    z-index: -1;
  }
  & .hm-handle::before { top: -2%; }
  & .hm-handle::after { bottom: -2%; }
  & .hm-dial {
    position: absolute;
    top: 91.7%;
    width: 3.25%;
    aspect-ratio: 1;
    transform: translate(-50%, -50%);
    border-radius: 50%;
    background:
      radial-gradient(ellipse at 35% 30%, #606659 0%, #3e433a 42%, transparent 58%),
      repeating-conic-gradient(from 8deg, #2e342b 0deg 10deg, #515649 11deg 14deg, #252b23 15deg 22deg);
    box-shadow: inset .12cqw .16cqw .16cqw #959b8c, inset -.14cqw -.14cqw .17cqw #141a14,
      .19cqw .30cqw 0 #30382d, .43cqw .58cqw .31cqw #565e508c;
  }
  & .hm-dial::after {
    content: "";
    display: block;
    position: absolute;
    inset: 12% 46% 54% 44%;
    border-radius: 1px;
    transform: rotate(-24deg);
    transform-origin: 50% 100%;
    background: #c8cdbd;
  }
  & .hm-dial-one { left: 20%; }
  & .hm-dial-two { left: 28%; }
  & .hm-dial-three { left: 36%; }
  & .hm-dial-two::after { transform: rotate(24deg); }
  & .hm-dial-three::after { transform: rotate(5deg); }
  & .hm-indicator {
    position: absolute;
    top: 91.7%;
    left: 48%;
    transform: translate(-50%, -50%);
    width: 1%;
    aspect-ratio: 1;
    border-radius: 50%;
    background: radial-gradient(circle at 35% 33%, #555b4b, #35392e);
    box-shadow: 0 0 0 .17cqw #6b7062, 0 .13cqw .15cqw .16cqw #d1d4c3;
  }
  & #tv-power-knob {
    left: 20%;
    top: 91.7%;
    width: max(5.8%, 44px);
  }
  @media (max-width: 47rem) {
    & #tv-stage { width: 100%; margin-block: .45rem .55rem; }
  }
  @media (forced-colors: active) {
    & .tv-hartman-box { border: 2px solid CanvasText; }
    & .hm-bezel, & .hm-dial, & .hm-handle { border: 1px solid CanvasText; }
  }
}
