:root {
  --anko-blue: #0808a8;
  --anko-yellow: #ffff00;
  --anko-cream: #fffef0;
  --anko-footer: #eee1a8;
  --anko-border: #203445;
  --anko-muted: #d5d5d5;
  --anko-link: #0000c8;
  --anko-red: #c92e4e;
  color-scheme: light;
  font-family: "Yu Gothic", "Meiryo", sans-serif;
}

* {
  box-sizing: border-box;
}

html {
  min-width: 320px;
  background: var(--anko-cream);
}

body {
  margin: 0;
  min-width: 320px;
  min-height: 100vh;
  background: var(--anko-cream);
  color: #080808;
}

button,
input,
select {
  font: inherit;
}

button {
  color: inherit;
}

.koan-app {
  width: min(100%, 1600px);
  min-height: 100vh;
  margin: 0 auto;
  display: flex;
  flex-direction: column;
  overflow: hidden;
}

.site-header {
  position: relative;
  padding-top: 74px;
}

.identity-panel {
  position: absolute;
  top: 24px;
  right: 18px;
  width: min(555px, calc(100% - 36px));
  min-height: 38px;
  padding: 5px 16px;
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 16px;
  border: 2px solid var(--anko-border);
  border-radius: 8px;
  background: #fff;
  font-size: 22px;
  line-height: 1.15;
}

.identity-panel strong {
  font-weight: 500;
}

.primary-nav {
  width: 100%;
  min-width: 0;
  padding: 0 8px;
  display: flex;
  align-items: flex-end;
  gap: 4px;
  overflow-x: auto;
  scrollbar-width: thin;
}

.primary-tab {
  flex: 0 0 156px;
  position: relative;
  width: 156px;
  height: 145px;
  padding: 12px 8px 12px;
  display: grid;
  grid-template-rows: 82px auto;
  place-items: center;
  gap: 4px;
  border: 0;
  border-radius: 26px 26px 0 0;
  background: transparent;
  cursor: pointer;
  font-size: 25px;
  line-height: 1;
  white-space: nowrap;
}

.primary-tab:hover,
.primary-tab:focus-visible {
  background: #ededcf;
  outline: none;
}

.primary-tab img {
  max-width: 80px;
  max-height: 76px;
  image-rendering: auto;
}

.primary-tab.is-active {
  background: var(--anko-blue);
  color: #fff;
}

.primary-tab.is-corrupt:not(.is-active) {
  background: var(--anko-yellow);
}

.primary-tab.is-corrupt.is-active {
  outline: 7px solid var(--anko-yellow);
  outline-offset: -1px;
}

.primary-tab.is-label-glitch,
.primary-tab.is-icon-glitch,
.primary-tab.is-scan-glitch {
  isolation: isolate;
}

.primary-tab.is-label-glitch [data-tab-label] {
  animation: corrupt-label-glitch 480ms steps(2, end) both;
}

.primary-tab.is-icon-glitch img {
  animation: corrupt-icon-glitch 480ms steps(2, end) both;
}

.primary-tab.is-scan-glitch::after {
  content: "";
  position: absolute;
  inset: 7px 5px 5px;
  z-index: 2;
  border-radius: inherit;
  background: repeating-linear-gradient(0deg, transparent 0 7px, rgb(255 0 64 / .28) 7px 9px, transparent 9px 15px, rgb(0 110 255 / .3) 15px 17px);
  mix-blend-mode: multiply;
  pointer-events: none;
  animation: corrupt-scan-glitch 480ms steps(2, end) both;
}

@keyframes corrupt-label-glitch {
  0%, 100% { transform: translate(0); text-shadow: none; opacity: 1; }
  18% { transform: translate(-5px, 1px) skewX(8deg); text-shadow: 5px 0 #ef164f, -4px 0 #0088ff; }
  36% { transform: translate(4px, -1px) skewX(-11deg); letter-spacing: .11em; opacity: .72; }
  54% { transform: translate(-2px, 1px); text-shadow: -5px 0 #ef164f, 4px 0 #0088ff; }
  72% { transform: translate(3px, 0) skewX(5deg); filter: contrast(2); }
}

@keyframes corrupt-icon-glitch {
  0%, 100% { transform: translate(0); filter: none; opacity: 1; }
  20% { transform: translate(5px, -2px); filter: hue-rotate(120deg) contrast(1.8); }
  42% { transform: translate(-5px, 2px) scaleX(1.08); opacity: .62; }
  64% { transform: translate(3px, 0); filter: invert(1) hue-rotate(210deg); }
  82% { transform: translate(-2px, -1px); filter: saturate(2.4); }
}

@keyframes corrupt-scan-glitch {
  0%, 100% { clip-path: inset(100% 0 0); opacity: 0; transform: translateX(0); }
  18% { clip-path: inset(12% 0 64%); opacity: 1; transform: translateX(5px); }
  42% { clip-path: inset(54% 0 22%); opacity: .8; transform: translateX(-6px); }
  68% { clip-path: inset(31% 0 47%); opacity: 1; transform: translateX(3px); }
}

.primary-tab[data-tab="schedule"] {
  flex-basis: 190px;
  width: 190px;
  font-size: 20px;
}

.primary-tab[data-tab="schedule"] [data-tab-label] {
  max-width: 180px;
  white-space: normal;
  text-align: center;
}

.secondary-nav {
  min-height: 49px;
  padding: 0 20px;
  display: flex;
  align-items: stretch;
  gap: 32px;
  background: var(--anko-blue);
  color: #fff;
  overflow-x: auto;
  scrollbar-width: thin;
}

.secondary-nav:empty::before {
  content: "";
  min-height: 49px;
}

.secondary-link {
  min-height: 49px;
  padding: 7px 8px 6px 22px;
  border: 0;
  background: transparent;
  color: #fff;
  cursor: pointer;
  font-size: 27px;
  font-weight: 700;
  white-space: nowrap;
}

.secondary-link::before {
  content: "❙";
  margin-right: 18px;
  color: #ffd800;
}

.secondary-link:hover,
.secondary-link:focus-visible,
.secondary-link.is-active {
  text-decoration: underline;
  text-underline-offset: 5px;
  outline: none;
}

.workspace {
  flex: 1;
  min-height: 570px;
  padding: 14px;
  display: grid;
  grid-template-columns: 282px minmax(0, 1fr);
  gap: 20px;
}

.sidebar {
  display: flex;
  flex-direction: column;
  gap: 22px;
}

.side-card {
  padding: 6px 8px 12px;
  border: 2px solid var(--anko-border);
  border-radius: 18px;
  background: #fff;
  font-size: 20px;
}

.side-card h2 {
  margin: 0 0 8px;
  padding: 3px 18px;
  border-radius: 16px;
  background: var(--anko-muted);
  font-size: 23px;
  font-weight: 500;
  line-height: 1.05;
}

.side-card p {
  margin: 0 18px;
  line-height: 1.15;
}

.schedule-card {
  min-height: 318px;
}

.mini-calendar {
  width: 234px;
  height: 172px;
  margin: 4px auto 16px;
  display: grid;
  place-items: center;
  border: 2px solid #111;
  background-color: var(--anko-cream);
  background-image:
    linear-gradient(#111 1px, transparent 1px),
    linear-gradient(90deg, #111 1px, transparent 1px);
  background-size: 100% 28px, 46px 100%;
  cursor: pointer;
}

.mini-calendar span {
  padding: 8px 16px;
  background: var(--anko-cream);
  font-size: 22px;
}

.fixed-date {
  color: #3276b5;
  font-size: 21px;
}

.content-panel {
  min-width: 0;
  min-height: 550px;
  padding: 46px 38px 28px;
  border: 2px solid var(--anko-border);
  border-radius: 20px;
  background: #fff;
  position: relative;
}

.content-panel:focus {
  outline: none;
}

.panel-title {
  position: absolute;
  top: 6px;
  left: 18px;
  right: 8px;
  min-height: 30px;
  margin: 0;
  padding: 2px 18px;
  border-radius: 18px;
  background: var(--anko-muted);
  font-size: 22px;
  font-weight: 500;
  line-height: 1.2;
}

.loading-message {
  color: #666;
}

.home-notice {
  max-width: 700px;
  margin: 0 auto 36px;
  font-size: 21px;
  line-height: 1.25;
}

.home-notice h1 {
  margin: 0 0 18px;
  text-align: center;
  font-size: 27px;
}

.home-notice h2 {
  margin: 0 0 10px;
  font-size: 22px;
}

.week-grid {
  display: grid;
  grid-template-columns: repeat(7, minmax(82px, 1fr));
  border: 1px solid #777;
  overflow-x: auto;
}

.week-day {
  min-height: 52px;
  display: grid;
  place-items: center;
  border-right: 1px solid #777;
  border-bottom: 1px solid #777;
  background: #ddddff;
  font-size: 21px;
  font-weight: 700;
}

.week-day:nth-child(1) {
  background: #ffc8c8;
}

.week-day:nth-child(7) {
  border-right: 0;
  background: #f0f0d2;
}

.week-cell {
  min-height: 142px;
  border-right: 1px solid #777;
  background: #fff;
}

.week-cell:nth-last-child(1) {
  border-right: 0;
  background: #f4f4dd;
}

.week-cell:nth-last-child(6) {
  background: #def5d4;
}

.puzzle-layout {
  min-height: 430px;
  display: grid;
  grid-template-columns: minmax(270px, 1fr) minmax(320px, 1.25fr);
  gap: 34px;
  align-items: center;
}

.puzzle-form {
  align-self: start;
  padding-top: 26px;
}

.puzzle-form label {
  display: block;
  margin-bottom: 34px;
  font-size: 22px;
}

.puzzle-form input {
  width: min(100%, 285px);
  height: 42px;
  margin-top: 24px;
  padding: 4px 10px;
  border: 2px solid #222;
  background: #fff;
  font-size: 22px;
}

.puzzle-buttons,
.form-actions {
  display: flex;
  gap: 28px;
  flex-wrap: wrap;
}

.ui-button {
  min-width: 138px;
  min-height: 40px;
  padding: 4px 18px;
  border: 2px solid #b8b8b8;
  border-radius: 9px;
  background: linear-gradient(#fff, #f0f0f0);
  cursor: pointer;
  font-size: 20px;
}

.ui-button:hover,
.ui-button:focus-visible {
  border-color: #555;
  outline: 2px solid #8dc6ff;
  outline-offset: 1px;
}

.ui-button:disabled {
  cursor: default;
  opacity: .55;
}

.puzzle-feedback,
.inline-status {
  min-height: 30px;
  margin-top: 18px;
  font-weight: 700;
}

.is-error {
  color: #b10000;
}

.is-success {
  color: #067500;
}

.puzzle-visual {
  max-width: 100%;
  max-height: 410px;
  justify-self: center;
  object-fit: contain;
}

.puzzle-visual.facility {
  width: 510px;
}

.replay-note {
  margin: 0 0 16px;
  padding: 8px 12px;
  border: 1px solid #b28c00;
  background: #fff8c7;
  font-size: 15px;
}

.section-heading {
  margin: 0 0 22px;
  font-size: 23px;
}

.subheading {
  margin: 20px 0 12px;
  padding-bottom: 6px;
  border-bottom: 1px solid #777;
  font-size: 21px;
}

.condition-form {
  max-width: 920px;
}

.form-row {
  min-height: 44px;
  display: grid;
  grid-template-columns: 190px minmax(180px, 320px);
  gap: 12px;
  align-items: center;
}

.form-row label {
  color: #222;
  font-size: 19px;
}

.form-row.is-required label {
  color: var(--anko-red);
}

.form-row input,
.form-row select {
  width: 100%;
  min-height: 34px;
  padding: 3px 8px;
  border: 2px solid #222;
  background: #fff;
}

.condition-divider {
  margin: 18px 0 12px;
  border: 0;
  border-top: 1px solid #777;
}

.form-actions {
  margin-top: 22px;
}

.mock-table {
  width: 100%;
  border-collapse: collapse;
  margin-top: 16px;
  font-size: 18px;
}

.mock-table th,
.mock-table td {
  min-height: 36px;
  padding: 6px 12px;
  border: 1px solid #fff;
  text-align: center;
}

.mock-table th {
  background: #a7c0ca;
  font-weight: 500;
}

.mock-table td {
  background: #e0e4e7;
}

.mock-table .empty-row {
  text-align: center;
}

.text-link,
.bulletin-link {
  padding: 0;
  border: 0;
  background: transparent;
  color: var(--anko-link);
  cursor: pointer;
  text-decoration: underline;
  text-underline-offset: 2px;
}

.survey-controls {
  display: flex;
  gap: 18px;
  align-items: center;
  flex-wrap: wrap;
}

.survey-section {
  margin-top: 28px;
}

.survey-section h3 {
  margin: 0 0 8px 16px;
  color: var(--anko-blue);
  font-size: 20px;
}

.admin-bar {
  max-width: 650px;
  display: grid;
  grid-template-columns: 180px 1fr;
  border: 1px solid #c5c5c5;
}

.admin-bar strong {
  padding: 8px 14px;
  background: #aaa8eb;
  text-align: center;
}

.admin-bar select {
  margin: 4px 12px;
  border: 2px solid #222;
}

.calendar-shell {
  overflow-x: auto;
}

.month-grid {
  width: min(780px, 100%);
  min-width: 620px;
  margin: 18px 0;
  display: grid;
  grid-template-columns: repeat(5, 1fr);
  grid-template-rows: repeat(5, 84px);
  border-top: 2px solid #111;
  border-left: 2px solid #111;
}

.month-cell {
  border-right: 2px solid #111;
  border-bottom: 2px solid #111;
}

.calendar-copy {
  max-width: 1040px;
  font-size: 19px;
  line-height: 1.35;
}

.calendar-copy ol {
  padding-left: 28px;
}

.url-table {
  width: 100%;
  border-collapse: collapse;
  margin: 20px 0 10px;
}

.url-table th,
.url-table td {
  padding: 8px 12px;
  border: 1px solid #fff;
}

.url-table th {
  background: #b7ddb8;
}

.url-table td {
  background: #f4f3d9;
}

.url-table input {
  width: 100%;
  min-height: 36px;
  border: 2px solid #222;
}

.facility-controls {
  margin: 6px 0 14px 220px;
  display: flex;
  gap: 8px;
  align-items: center;
  flex-wrap: wrap;
}

.facility-controls select {
  min-width: 110px;
  min-height: 34px;
  border: 2px solid #222;
  background: #fff;
}

.facility-grid-wrap {
  overflow-x: auto;
}

.facility-grid {
  width: 100%;
  min-width: 960px;
  border-collapse: collapse;
  font-size: 14px;
}

.facility-grid th,
.facility-grid td {
  height: 34px;
  border: 1px solid #111;
  text-align: center;
}

.facility-grid thead th:not(:first-child) {
  width: 7.6%;
}

.facility-grid th:first-child,
.facility-grid td:first-child {
  width: 220px;
  padding-left: 12px;
  text-align: left;
}

.facility-event {
  background: #d5d5d5;
  white-space: nowrap;
}

.bulletin-group {
  max-width: 880px;
  margin-bottom: 26px;
}

.bulletin-group h2 {
  margin: 0 0 8px;
  padding: 7px 24px;
  border-bottom: 2px solid #888;
  background: linear-gradient(90deg, #f0f0dc, #fff);
  font-size: 20px;
  font-weight: 500;
}

.bulletin-list {
  margin: 0;
  padding: 0 24px;
  list-style: none;
}

.bulletin-list li {
  margin: 7px 0;
}

.unread {
  display: inline-block;
  margin-left: 10px;
  padding: 2px 9px;
  border-radius: 7px;
  background: #ff7d72;
  color: #fff;
  font-size: 14px;
}

.locked-bulletin {
  min-height: 400px;
  display: grid;
  place-items: center;
  text-align: center;
}

.locked-bulletin strong {
  display: block;
  margin-bottom: 16px;
  font-size: 28px;
}

.site-footer {
  min-height: 53px;
  padding: 7px 14px;
  display: grid;
  grid-template-columns: 1fr auto 1fr;
  align-items: center;
  gap: 14px;
  background: var(--anko-footer);
  font-size: 23px;
}

.footer-button,
.progress-button {
  min-width: 174px;
  min-height: 35px;
  padding: 2px 16px;
  border: 2px solid #b8b8b8;
  border-radius: 8px;
  background: #fff;
  cursor: pointer;
}

.progress-button {
  justify-self: end;
  min-width: 205px;
  font-size: 16px;
}

.system-dialog {
  width: min(620px, calc(100% - 32px));
  padding: 0;
  border: 2px solid var(--anko-border);
  border-radius: 14px;
}

.system-dialog::backdrop {
  background: rgb(0 0 0 / .44);
}

.dialog-card {
  position: relative;
  padding: 32px;
  background: #fff;
}

.dialog-card h2 {
  margin: 0 36px 18px 0;
  font-size: 24px;
}

.dialog-close {
  position: absolute;
  top: 10px;
  right: 12px;
  width: 36px;
  height: 36px;
  border: 0;
  background: transparent;
  cursor: pointer;
  font-size: 28px;
}

.progress-list {
  margin: 0 0 24px;
  padding: 0;
  list-style: none;
}

.progress-list li {
  padding: 10px 0;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
  border-bottom: 1px solid #ddd;
}

.status-chip {
  min-width: 76px;
  padding: 3px 8px;
  border-radius: 10px;
  background: #ececec;
  text-align: center;
  font-size: 14px;
}

.status-chip.solved {
  background: #d6f3d0;
  color: #135d0d;
}

.restore-effect {
  position: fixed;
  inset: 0;
  z-index: 500;
  display: grid;
  place-items: center;
  padding: 18px;
  overflow: hidden;
  background: rgb(0 0 0 / 0);
  pointer-events: auto;
  transition: background-color 220ms linear;
}

.restore-effect[hidden] {
  display: none;
}

body.is-restoring {
  overflow: hidden;
}

.restore-terminal {
  position: relative;
  width: min(390px, calc(100vw - 36px));
  height: min(580px, calc(100svh - 36px));
  min-height: min(440px, calc(100svh - 36px));
  display: flex;
  flex-direction: column;
  overflow: hidden;
  border: 1px solid rgb(255 255 255 / .48);
  border-radius: 9px;
  background: #0c0c0c;
  color: #f2f2f2;
  box-shadow: 0 22px 60px rgb(0 0 0 / .52);
  font-family: "Segoe UI", "Yu Gothic UI", sans-serif;
  opacity: 0;
  transform: translateY(14px) scale(.96);
}

.restore-effect.is-terminal {
  background: rgb(0 0 0 / .48);
}

.restore-effect.is-terminal .restore-terminal {
  animation: restore-terminal-open 220ms ease-out forwards;
}

.restore-effect.is-closing {
  background: rgb(0 0 0 / 0);
}

.restore-effect.is-closing .restore-terminal {
  animation: restore-terminal-close 220ms ease-in forwards;
}

.restore-terminal-bar {
  min-height: 42px;
  display: flex;
  align-items: center;
  border-bottom: 1px solid #343434;
  background: #202020;
}

.restore-terminal-bar h2 {
  margin: 0 0 0 9px;
  color: #f0f0f0;
  font-size: 14px;
  font-weight: 400;
}

.restore-terminal-icon {
  width: 22px;
  height: 22px;
  margin-left: 12px;
  display: grid;
  place-items: center;
  border: 1px solid #777;
  border-radius: 3px;
  background: #111;
  color: #f2f2f2;
  font: 11px/1 Consolas, monospace;
}

.restore-terminal-controls {
  height: 100%;
  margin-left: auto;
  display: flex;
  align-self: stretch;
}

.restore-terminal-control {
  width: 44px;
  display: grid;
  place-items: center;
  color: #ddd;
  font-size: 12px;
}

.restore-terminal-control.is-close {
  font-size: 16px;
}

.restore-terminal-body {
  flex: 1;
  padding: 18px 16px 24px;
  overflow: auto;
  background: #0c0c0c;
  color: #f2f2f2;
  font: 16px/1.6 Consolas, "IBM Plex Mono", monospace;
  white-space: pre-wrap;
}

.restore-terminal-preamble {
  color: #c9c9c9;
}

.restore-terminal-message {
  color: #fff;
}

.restore-terminal-cursor {
  width: 8px;
  height: 1.15em;
  display: inline-block;
  margin-left: 2px;
  vertical-align: -2px;
  background: #fff;
  animation: restore-cursor-blink 750ms steps(1, end) infinite;
}

@keyframes restore-terminal-open {
  from { opacity: 0; transform: translateY(14px) scale(.96); }
  to { opacity: 1; transform: translateY(0) scale(1); }
}

@keyframes restore-terminal-close {
  from { opacity: 1; transform: translateY(0) scale(1); }
  to { opacity: 0; transform: translateY(8px) scale(.97); }
}

@keyframes restore-cursor-blink {
  50% { opacity: 0; }
}

@media (max-width: 1080px) {
  .site-header {
    padding-top: 66px;
    overflow: hidden;
  }

  .primary-nav {
    overflow-x: auto;
  }

  .primary-tab {
    flex-basis: 128px;
    width: 128px;
    height: 126px;
    grid-template-rows: 68px auto;
    font-size: 20px;
  }

  .primary-tab[data-tab="schedule"] {
    flex-basis: 165px;
    width: 165px;
    font-size: 17px;
  }

  .workspace {
    grid-template-columns: 240px minmax(0, 1fr);
  }

  .mini-calendar {
    width: 205px;
  }

  .puzzle-layout {
    grid-template-columns: 1fr;
  }

  .puzzle-visual {
    max-height: 330px;
  }
}

@media (max-width: 760px) {
  .site-header {
    padding-top: 62px;
  }

  .identity-panel {
    top: 12px;
    left: 10px;
    right: 10px;
    width: auto;
    min-height: 36px;
    padding-inline: 10px;
    gap: 8px;
    font-size: 14px;
  }

  .primary-nav {
    padding-inline: 4px;
  }

  .primary-tab {
    flex-basis: 94px;
    width: 94px;
    height: 105px;
    padding: 8px 4px;
    grid-template-rows: 58px auto;
    border-radius: 18px 18px 0 0;
    font-size: 15px;
  }

  .primary-tab img {
    max-width: 62px;
    max-height: 58px;
  }

  .primary-tab[data-tab="schedule"] {
    flex-basis: 128px;
    width: 128px;
    font-size: 13px;
  }

  .primary-tab.is-corrupt.is-active {
    outline-width: 4px;
  }

  .secondary-nav {
    min-height: 43px;
    padding-inline: 8px;
    gap: 10px;
  }

  .secondary-link {
    min-height: 43px;
    padding: 6px 6px 5px 10px;
    font-size: 16px;
  }

  .secondary-link::before {
    margin-right: 8px;
  }

  .workspace {
    padding: 8px;
    display: flex;
    flex-direction: column;
    gap: 12px;
  }

  .content-panel {
    order: -1;
    min-height: 560px;
    padding: 46px 18px 24px;
    border-radius: 14px;
  }

  .sidebar {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 10px;
  }

  .side-card {
    min-width: 0;
    font-size: 14px;
  }

  .side-card h2 {
    padding-inline: 10px;
    font-size: 16px;
  }

  .side-card p {
    margin-inline: 8px;
  }

  .schedule-card {
    min-height: 0;
  }

  .mini-calendar {
    width: 100%;
    height: 116px;
    margin-bottom: 8px;
    background-size: 100% 23px, 38px 100%;
  }

  .mini-calendar span {
    font-size: 16px;
  }

  .fixed-date {
    font-size: 15px;
  }

  .panel-title {
    left: 8px;
    font-size: 17px;
  }

  .home-notice {
    font-size: 16px;
  }

  .week-grid {
    grid-template-columns: repeat(7, minmax(64px, 1fr));
    overflow-x: auto;
  }

  .puzzle-layout {
    min-height: 460px;
    gap: 10px;
  }

  .puzzle-form {
    padding-top: 8px;
  }

  .puzzle-form label {
    margin-bottom: 14px;
    font-size: 18px;
  }

  .puzzle-form input {
    margin-top: 12px;
  }

  .puzzle-visual {
    width: 100%;
    max-height: 290px;
  }

  .form-row {
    grid-template-columns: 120px minmax(0, 1fr);
  }

  .facility-controls {
    margin-left: 0;
  }

  .site-footer {
    grid-template-columns: 1fr auto;
    font-size: 15px;
  }

  .footer-button {
    display: none;
  }

  .progress-button {
    min-width: 145px;
    font-size: 13px;
  }

  .restore-terminal {
    width: min(360px, calc(100vw - 24px));
    height: min(560px, calc(100svh - 24px));
    min-height: min(420px, calc(100svh - 24px));
  }
}

@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    scroll-behavior: auto !important;
  }

  .primary-tab.is-label-glitch,
  .primary-tab.is-label-glitch [data-tab-label],
  .primary-tab.is-icon-glitch,
  .primary-tab.is-icon-glitch img,
  .primary-tab.is-scan-glitch,
  .primary-tab.is-scan-glitch::after {
    animation: none !important;
  }

  .restore-effect.is-terminal .restore-terminal {
    animation: restore-terminal-fade 180ms linear forwards;
  }

  .restore-effect.is-closing .restore-terminal {
    animation: restore-terminal-fade-out 180ms linear forwards;
  }
}

@keyframes restore-terminal-fade {
  from { opacity: 0; transform: none; }
  to { opacity: 1; transform: none; }
}

@keyframes restore-terminal-fade-out {
  from { opacity: 1; transform: none; }
  to { opacity: 0; transform: none; }
}
