/* The RIS's power strip: drawn as the strip itself — a bar with its sockets, a light on each that is
   lit when the socket has power, and under each the round power button that switches it. */
.strip + .strip {
  margin-top: 14px;
}
.strip-state {
  display: flex;
  align-items: center;
  gap: 8px;
  margin: 0 0 8px;
  color: var(--muted);
  font-size: var(--text-sm);
}
.strip-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: #7fd18a;
  box-shadow: 0 0 6px rgba(127, 209, 138, 0.7);
}
.strip[data-online="false"] .strip-dot {
  background: var(--error);
  box-shadow: none;
}
.strip-body {
  position: relative;
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(118px, 1fr));
  gap: 10px;
  margin: 0;
  padding: 16px 16px 16px 30px;
  list-style: none;
  border: 1px solid #3d4037;
  border-radius: 18px;
  background: linear-gradient(180deg, #2a2c27, #1b1c19);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.06), 0 6px 18px rgba(0, 0, 0, 0.35);
}
/* The strip's cord, leaving from its left end. */
.strip-body::before {
  content: "";
  position: absolute;
  top: 50%;
  left: -14px;
  width: 26px;
  height: 6px;
  border-radius: 3px;
  background: #3d4037;
  transform: translateY(-50%);
}
.strip[data-online="false"] .strip-body {
  opacity: 0.55;
}
.socket {
  display: grid;
  align-content: start;
  justify-items: center;
  gap: 6px;
  padding: 12px 8px 10px;
  border-radius: 12px;
  background: rgba(0, 0, 0, 0.18);
  text-align: center;
}
/* The socket's face: two pin slots and its light. */
.socket-face {
  position: relative;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 12px;
  width: 58px;
  height: 58px;
  border: 1px solid #44473e;
  border-radius: 50%;
  background: radial-gradient(circle at 50% 40%, #30332d, #191a17);
}
.socket-face i {
  width: 6px;
  height: 16px;
  border-radius: 3px;
  background: #0b0c0a;
}
.socket-led {
  position: absolute;
  top: 6px;
  right: 6px;
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: #3a3d36;
}
.socket[data-on="true"] .socket-led {
  background: #7fd18a;
  box-shadow: 0 0 8px rgba(127, 209, 138, 0.9);
}
.socket-no {
  color: var(--muted);
  font-size: var(--text-xs);
  letter-spacing: 0.04em;
  text-transform: uppercase;
}
.socket-name {
  font-size: var(--text-sm);
  font-weight: 500;
  line-height: 1.3;
}
/* The power button: grey when off, lit when on, a turning ring while a switch is under way. */
.power-button {
  position: relative;
  display: grid;
  place-items: center;
  width: 46px;
  height: 46px;
  padding: 0;
  border: 2px solid #4a4d44;
  border-radius: 50%;
  background: #22241f;
  color: var(--muted);
  cursor: pointer;
  transition: border-color 0.2s, color 0.2s, box-shadow 0.2s;
}
.power-button svg {
  width: 20px;
  height: 20px;
}
.power-button:hover:not(:disabled) {
  border-color: var(--gold);
  color: var(--softgold);
}
.power-button[aria-pressed="true"] {
  border-color: #7fd18a;
  color: #7fd18a;
  box-shadow: 0 0 12px rgba(127, 209, 138, 0.35);
}
.power-button:disabled {
  cursor: default;
  opacity: 0.6;
}
.socket[data-busy="true"] .power-button {
  opacity: 1;
}
.socket[data-busy="true"] .power-button::after {
  content: "";
  position: absolute;
  inset: -6px;
  border: 2px solid transparent;
  border-top-color: var(--gold);
  border-radius: 50%;
  animation: power-turn 0.9s linear infinite;
}
@keyframes power-turn {
  to {
    transform: rotate(360deg);
  }
}
.socket-state {
  min-height: 1.3em;
  color: var(--muted);
  font-size: var(--text-xs);
  line-height: 1.3;
}
.socket[data-on="true"] .socket-state {
  color: #7fd18a;
}
.socket[data-busy="true"] .socket-state {
  color: var(--gold);
}
.socket[data-failed="true"] .socket-state {
  color: var(--error);
}
.power-note {
  margin: 10px 0 0;
  color: var(--muted);
  font-size: var(--text-sm);
}
@media (max-width: 560px) {
  .strip-body {
    grid-template-columns: repeat(2, 1fr);
  }
}
.power-error {
  margin: 10px 0 0;
  color: var(--error);
  font-size: var(--text-sm);
}
/* Outside the hours open to the renter: the strip stays, its buttons rest, and this says when. */
.strip-hours {
  margin: 8px 0 0;
  color: var(--gold);
  font-size: var(--text-sm);
}
/* Every socket at once, at the panel's top right: lit like a socket's button when all are on. */
.power-all {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  align-self: center;
  padding: 6px 14px 6px 8px;
  border: 2px solid #4a4d44;
  border-radius: 999px;
  background: #22241f;
  color: var(--muted);
  font: 600 var(--text-sm) var(--font-site);
  cursor: pointer;
  transition: border-color 0.2s, color 0.2s, box-shadow 0.2s;
}
.power-all svg {
  width: 18px;
  height: 18px;
}
.power-all:hover:not(:disabled) {
  border-color: var(--gold);
  color: var(--softgold);
}
.power-all[data-on="true"] {
  border-color: #7fd18a;
  color: #7fd18a;
  box-shadow: 0 0 12px rgba(127, 209, 138, 0.35);
}
.power-all:disabled {
  cursor: default;
  opacity: 0.6;
}
