body {
  background-color: #ffffff;
  color: #000080;
  font-family: "Times New Roman", Times, "Hiragino Mincho ProN", "Yu Mincho", "Songti SC", "STSong", "SimSun", serif;
  margin: 8px;
}

.lang-toggle {
  text-align: right;
  font-size: 0.75rem;
  margin: 0 4px 4px 0;
}

a,
a:visited,
a:hover,
a:active {
  color: #800080;
}

.masthead-home,
.masthead-home:visited,
.masthead-home:active {
  color: #000080;
  text-decoration: none;
}

.masthead-home:hover {
  color: #000080;
  text-decoration: underline;
}

.masthead {
  text-align: center;
  font-weight: bold;
  line-height: 1.25;
  margin: 12px 0;
}

.masthead .initial {
  font-size: 2rem;
}

.masthead .word {
  font-size: 1.125rem;
}

.masthead .subline {
  display: block;
  font-size: 0.8125rem;
  font-weight: bold;
}

.masthead .official {
  display: block;
  font-size: 1rem;
  font-weight: bold;
}

.directory {
  width: 90%;
  margin: 14px auto 4px;
  display: grid;
  grid-template-columns: 1fr 1fr;
  column-gap: 16px;
  align-items: start;
}

.directory-col ul {
  margin: 0;
  padding-left: 24px;
}

.directory-col li {
  margin: 0 0 18px 0;
}

.meta {
  display: block;
  font-size: 0.72rem;
  margin-top: 2px;
}

.spotlight {
  text-align: center;
  text-transform: uppercase;
  font-size: 0.72rem;
  line-height: 1.45;
  margin: 12px 0;
}

.note,
.footer {
  font-size: 0.8125rem;
  text-align: left;
}

.content {
  width: 90%;
  max-width: 780px;
  margin: 16px auto;
  font-size: 0.95rem;
  line-height: 1.5;
}

.content dl {
  margin: 12px 0;
}

.content dt {
  font-weight: bold;
  margin-top: 8px;
}

.content dd {
  margin-left: 20px;
}

.content ul {
  margin: 8px 0;
  padding-left: 24px;
}

.video-embed {
  position: relative;
  width: 100%;
  aspect-ratio: 16 / 9;
  margin: 16px 0;
}

.video-embed iframe {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  border: 0;
}

@media (max-width: 640px) {
  .directory {
    grid-template-columns: 1fr;
  }
}

.yt-wrap {
  width: 92%;
  max-width: 960px;
  margin: 14px auto;
}

.yt-tabs {
  display: flex;
  flex-wrap: wrap;
  gap: 4px;
  border-bottom: 1px solid #999999;
  padding: 0 6px;
  margin-bottom: 12px;
}

.yt-tab {
  font-family: inherit;
  font-size: 0.8125rem;
  font-weight: bold;
  color: #800080;
  background: #f4f4f8;
  border: 1px solid #999999;
  border-bottom: none;
  padding: 4px 12px;
  cursor: pointer;
  margin-bottom: -1px;
  text-decoration: underline;
}

.yt-tab.is-active {
  background: #ffffff;
  color: #000080;
  border-bottom: 1px solid #ffffff;
  text-decoration: none;
}

.yt-watch {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 300px;
  gap: 14px;
  align-items: start;
}

.yt-player-title {
  margin: 0 0 8px 0;
  font-size: 1.05rem;
  font-weight: bold;
  color: #000080;
}

.yt-player-frame {
  position: relative;
  width: 100%;
  aspect-ratio: 16 / 9;
  border: 1px solid #999999;
  background: #000000;
}

.yt-player-frame iframe {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  border: 0;
}

.yt-player-actions {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  align-items: center;
  gap: 8px;
  margin-top: 6px;
  font-size: 0.78rem;
}

.yt-info-box {
  border: 1px solid #b5b5c2;
  background: #f8f8fb;
  padding: 8px 10px;
  font-size: 0.78rem;
  line-height: 1.45;
  margin-bottom: 10px;
}

.yt-info-box p {
  margin: 0 0 6px 0;
}

.yt-info-row {
  margin: 4px 0;
}

.yt-url-input {
  width: 100%;
  box-sizing: border-box;
  font-family: monospace;
  font-size: 0.7rem;
  color: #000080;
  background: #ffffff;
  border: 1px solid #999999;
  padding: 2px 4px;
  margin-top: 2px;
}

.yt-queue-box {
  border: 1px solid #b5b5c2;
  background: #ffffff;
}

.yt-box-bar {
  background: #eef0f6;
  border-bottom: 1px solid #b5b5c2;
  padding: 4px 8px;
  font-size: 0.78rem;
  font-weight: bold;
  color: #000080;
}

.yt-queue-list {
  max-height: 280px;
  overflow-y: auto;
}

.yt-queue-item {
  display: flex;
  gap: 8px;
  align-items: flex-start;
  width: 100%;
  text-align: left;
  background: #ffffff;
  border: none;
  border-bottom: 1px solid #e6e6ef;
  padding: 6px 8px;
  cursor: pointer;
  font-family: inherit;
  color: #000080;
}

.yt-queue-item:last-child {
  border-bottom: none;
}

.yt-queue-item.is-active {
  background: #eef0f6;
}

.yt-queue-thumb {
  width: 96px;
  height: 54px;
  object-fit: cover;
  border: 1px solid #999999;
  flex-shrink: 0;
  display: block;
}

.yt-queue-text {
  min-width: 0;
  font-size: 0.75rem;
  line-height: 1.3;
}

.yt-queue-title {
  display: block;
  color: #800080;
  text-decoration: underline;
  font-weight: bold;
  margin-bottom: 2px;
}

.yt-queue-item.is-active .yt-queue-title {
  color: #000080;
  text-decoration: none;
}

.yt-browse-box {
  border: 1px solid #b5b5c2;
  background: #ffffff;
  margin-top: 14px;
}

.yt-browse-header {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  align-items: center;
  gap: 8px;
  background: #eef0f6;
  border-bottom: 1px solid #b5b5c2;
  padding: 5px 10px;
  font-size: 0.78rem;
}

.yt-filter-group {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 6px;
}

.yt-filter-btn {
  font-family: inherit;
  font-size: 0.78rem;
  color: #800080;
  background: none;
  border: none;
  padding: 0;
  cursor: pointer;
  text-decoration: underline;
}

.yt-filter-btn.is-active {
  color: #000080;
  font-weight: bold;
  text-decoration: none;
}

.yt-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 14px;
  padding: 12px;
}

.yt-card {
  font-size: 0.75rem;
  line-height: 1.35;
}

.yt-thumb-btn {
  display: block;
  width: 100%;
  padding: 0;
  margin: 0 0 5px 0;
  border: 1px solid #999999;
  background: #000000;
  cursor: pointer;
}

.yt-card.is-active .yt-thumb-btn {
  outline: 2px solid #000080;
}

.yt-thumb {
  display: block;
  width: 100%;
  aspect-ratio: 16 / 9;
  object-fit: cover;
}

.yt-card-title-btn {
  font-family: inherit;
  font-size: 0.78rem;
  font-weight: bold;
  color: #800080;
  background: none;
  border: none;
  padding: 0;
  margin: 0 0 3px 0;
  text-align: left;
  cursor: pointer;
  text-decoration: underline;
}

.yt-card.is-active .yt-card-title-btn {
  color: #000080;
}

.yt-card-meta {
  display: block;
  font-size: 0.7rem;
  color: #000080;
}

@media (max-width: 780px) {
  .yt-watch {
    grid-template-columns: 1fr;
  }

  .yt-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (max-width: 480px) {
  .yt-grid {
    grid-template-columns: 1fr;
  }
}
