:root {
  color-scheme: dark;
  font-family: Roboto, Arial, sans-serif;
  background: #0f0f0f;
  color: #f1f1f1;
  font-synthesis: none;
  text-rendering: optimizeLegibility;
}

* {
  box-sizing: border-box;
}

body {
  margin: 0;
  min-width: 320px;
  background: #0f0f0f;
}

button,
input {
  font: inherit;
}

button,
a {
  -webkit-tap-highlight-color: transparent;
}

a {
  color: inherit;
  text-decoration: none;
}

.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

.topbar {
  position: sticky;
  z-index: 5;
  top: 0;
  display: grid;
  grid-template-columns: minmax(160px, 1fr) minmax(240px, 640px) minmax(160px, 1fr);
  align-items: center;
  gap: 24px;
  height: 64px;
  padding: 0 32px;
  background: #0f0f0f;
}

.brand {
  display: inline-flex;
  align-items: center;
  justify-self: start;
}

.brand-name {
  font-size: 18px;
  font-weight: 700;
  letter-spacing: -.4px;
  white-space: nowrap;
}

.search {
  display: flex;
  width: 100%;
  height: 40px;
}

.search input {
  min-width: 0;
  flex: 1;
  padding: 0 16px;
  border: 1px solid #303030;
  border-radius: 22px 0 0 22px;
  outline: none;
  background: #121212;
  color: #f1f1f1;
  font-size: 16px;
}

.search input:focus {
  border-color: #3ea6ff;
}

.search input::placeholder {
  color: #888;
}

.search button {
  display: grid;
  width: 64px;
  place-items: center;
  border: 1px solid #303030;
  border-left: 0;
  border-radius: 0 22px 22px 0;
  background: #222;
  color: #f1f1f1;
  cursor: pointer;
}

.search button:hover {
  background: #303030;
}

.search svg {
  width: 21px;
  height: 21px;
  fill: none;
  stroke: currentColor;
  stroke-linecap: round;
  stroke-width: 2;
}

.subscribe-link {
  justify-self: end;
  padding: 10px 16px;
  border-radius: 22px;
  background: #f1f1f1;
  color: #0f0f0f;
  font-size: 14px;
  font-weight: 600;
  transition: background 150ms ease;
}

.subscribe-link:hover {
  background: #d9d9d9;
}

main {
  width: min(100% - 64px, 1280px);
  margin: 0 auto;
}

.channel {
  padding-top: 20px;
}

.channel-banner {
  position: relative;
  height: clamp(130px, 20vw, 220px);
  overflow: hidden;
  border-radius: 20px;
  background-color: #272727;
  background-image:
    linear-gradient(rgba(18, 18, 18, .16), rgba(18, 18, 18, .16)),
    url("https://yt3.googleusercontent.com/0lVtZ8I52jToGHZca4Ph4xBH2gmATnzcpeq__XM678j5UGmutR7lOJTAQxy4jiiJAAmYLyz1fg=w1707-fcrop64=1,00005a57ffffa5a8-k-c0xffffffff-no-nd-rj");
  background-position: center 42%;
  background-size: cover;
}

.channel-heading {
  display: flex;
  align-items: center;
  gap: 22px;
  padding: 24px 4px 20px;
}

.channel-avatar {
  width: 96px;
  height: 96px;
  flex: 0 0 auto;
  border-radius: 50%;
  background: #272727;
  object-fit: cover;
}

.channel-heading h1 {
  margin: 0;
  font-size: clamp(24px, 3vw, 34px);
  font-weight: 700;
  letter-spacing: -.5px;
}

.channel-tabs {
  display: flex;
  gap: 26px;
  min-height: 48px;
  align-items: stretch;
  border-bottom: 1px solid #303030;
}

.channel-tab {
  position: relative;
  display: flex;
  align-items: center;
  padding: 0 4px;
  border: 0;
  background: transparent;
  color: #aaa;
  font-size: 14px;
}

button.channel-tab {
  color: #f1f1f1;
  font-weight: 600;
}

.channel-tab.active::after {
  position: absolute;
  right: 0;
  bottom: -1px;
  left: 0;
  height: 2px;
  background: #f1f1f1;
  content: "";
}

.external-tab:hover {
  color: #f1f1f1;
}

.videos-section {
  padding: 24px 0 56px;
}

.section-toolbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
  margin-bottom: 20px;
}

.section-toolbar h2 {
  margin: 0;
  font-size: 20px;
  font-weight: 600;
}

.sort-controls {
  display: flex;
  gap: 8px;
}

.sort-button {
  padding: 8px 12px;
  border: 0;
  border-radius: 8px;
  background: #272727;
  color: #f1f1f1;
  cursor: pointer;
  font-size: 13px;
  white-space: nowrap;
}

.sort-button:hover {
  background: #3f3f3f;
}

.sort-button.selected {
  background: #f1f1f1;
  color: #0f0f0f;
}

.video-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  column-gap: 16px;
  row-gap: 36px;
}

.video-card {
  min-width: 0;
}

.thumbnail-button {
  position: relative;
  display: block;
  width: 100%;
  aspect-ratio: 16 / 9;
  padding: 0;
  overflow: hidden;
  border: 0;
  border-radius: 12px;
  background: #272727;
  cursor: pointer;
}

.thumbnail-button img {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: border-radius 160ms ease, transform 220ms ease;
}

.thumbnail-button:hover img {
  transform: scale(1.035);
}

.duration {
  position: absolute;
  right: 8px;
  bottom: 8px;
  padding: 3px 5px;
  border-radius: 4px;
  background: rgba(0, 0, 0, .8);
  color: #fff;
  font-size: 12px;
  font-weight: 600;
}

.video-details {
  display: flex;
  gap: 12px;
  padding-top: 12px;
}

.video-avatar {
  width: 36px;
  height: 36px;
  flex: 0 0 auto;
  border-radius: 50%;
  object-fit: cover;
}

.video-copy {
  min-width: 0;
}

.video-title {
  display: -webkit-box;
  overflow: hidden;
  color: #f1f1f1;
  font-size: 15px;
  font-weight: 600;
  line-height: 1.4;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 2;
}

.all-videos-link {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  margin-top: 38px;
  padding: 10px 14px;
  border: 1px solid #3f3f3f;
  border-radius: 20px;
  color: #f1f1f1;
  font-size: 14px;
}

.all-videos-link:hover {
  background: #272727;
}

.empty-state {
  padding: 36px 0;
  color: #aaa;
  text-align: center;
}

.player-dialog {
  width: min(1000px, calc(100% - 32px));
  max-width: none;
  padding: 0;
  overflow: hidden;
  border: 1px solid #303030;
  border-radius: 14px;
  background: #0f0f0f;
  color: #f1f1f1;
}

.player-dialog::backdrop {
  background: rgba(0, 0, 0, .8);
}

.player-dialog-bar {
  display: flex;
  min-height: 52px;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding: 8px 14px 8px 18px;
}

.player-dialog-bar p {
  margin: 0;
  overflow: hidden;
  font-size: 15px;
  font-weight: 600;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.close-player {
  width: 36px;
  height: 36px;
  flex: 0 0 auto;
  border: 0;
  border-radius: 50%;
  background: transparent;
  color: #f1f1f1;
  cursor: pointer;
  font-size: 28px;
  line-height: 1;
}

.close-player:hover {
  background: #272727;
}

.player-frame {
  aspect-ratio: 16 / 9;
  background: #000;
}

.player-frame iframe {
  display: block;
  width: 100%;
  height: 100%;
  border: 0;
}

.player-fallback {
  display: grid;
  min-height: 220px;
  height: 100%;
  align-content: center;
  justify-items: center;
  gap: 14px;
  padding: 24px;
  color: #aaa;
  text-align: center;
}

.player-fallback p {
  max-width: 520px;
  margin: 0;
  line-height: 1.5;
}

.player-fallback a {
  padding: 10px 16px;
  border-radius: 22px;
  background: #f1f1f1;
  color: #0f0f0f;
  font-size: 14px;
  font-weight: 600;
}

@media (max-width: 1050px) {
  .video-grid {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }
}

@media (max-width: 760px) {
  .topbar {
    grid-template-columns: 1fr minmax(0, 1.7fr) auto;
    gap: 12px;
    height: 56px;
    padding: 0 16px;
  }

  .search {
    height: 36px;
  }

  .search input {
    padding: 0 10px;
    font-size: 14px;
  }

  .search button {
    width: 42px;
  }

  .subscribe-link {
    padding: 9px 12px;
    font-size: 12px;
  }

  main {
    width: min(100% - 32px, 680px);
  }

  .channel {
    padding-top: 12px;
  }

  .channel-banner {
    border-radius: 14px;
  }

  .channel-heading {
    gap: 16px;
    padding: 18px 2px;
  }

  .channel-avatar {
    width: 72px;
    height: 72px;
  }

  .video-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    column-gap: 12px;
    row-gap: 28px;
  }

  .video-details {
    gap: 9px;
    padding-top: 9px;
  }

  .video-avatar {
    width: 30px;
    height: 30px;
  }
}

@media (max-width: 500px) {
  .topbar {
    grid-template-columns: auto minmax(0, 1fr);
  }

  .search {
    grid-column: 2;
    grid-row: 1;
  }

  .subscribe-link {
    display: none;
  }

  .section-toolbar {
    align-items: flex-start;
    flex-direction: column;
    gap: 14px;
  }

  .sort-controls {
    max-width: 100%;
    overflow-x: auto;
    padding-bottom: 2px;
  }

  .sort-button {
    padding: 8px 10px;
  }

  .video-title {
    font-size: 14px;
  }

}

@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    scroll-behavior: auto !important;
    transition-duration: .01ms !important;
  }
}

:root {
  color-scheme: light;
  font-family: "Trebuchet MS", "Segoe UI", sans-serif;
  background: #fffaf0;
  color: #23332d;
  font-synthesis: none;
  text-rendering: optimizeLegibility;
}

html {
  scroll-behavior: smooth;
}

body {
  background:
    radial-gradient(ellipse at 10% 12%, rgba(255, 219, 148, .28), transparent 28rem),
    #fffaf0;
  color: #23332d;
}

.topbar {
  height: 76px;
  grid-template-columns: minmax(190px, 1fr) minmax(240px, 520px) minmax(190px, 1fr);
  gap: 28px;
  padding: 0 max(32px, calc((100vw - 1280px) / 2));
  border-bottom: 1px solid rgba(71, 89, 73, .1);
  background: rgba(255, 250, 240, .94);
  backdrop-filter: blur(14px);
}

.brand {
  gap: 10px;
}

.brand-mark {
  display: grid;
  width: 38px;
  height: 38px;
  place-items: center;
  border-radius: 14px;
  background: #f5ad45;
  color: #fff;
  font-family: Georgia, serif;
  font-size: 24px;
  font-weight: 700;
  transform: rotate(-5deg);
}

.brand-name {
  color: #294239;
  font-family: Georgia, "Times New Roman", serif;
  font-size: 18px;
  letter-spacing: -.5px;
}

.brand-name strong {
  color: #e78336;
}

.search {
  height: 44px;
}

.search input {
  border-color: #e8dfce;
  border-radius: 24px 0 0 24px;
  background: #fff;
  color: #23332d;
}

.search input:focus {
  border-color: #e69b45;
}

.search input::placeholder {
  color: #8b9188;
}

.search button {
  border-color: #e8dfce;
  border-radius: 0 24px 24px 0;
  background: #f4ecdf;
  color: #42564b;
}

.search button:hover {
  background: #eadcc5;
}

.subscribe-link {
  border-radius: 24px;
  background: #287c68;
  color: #fff;
  font-size: 13px;
  letter-spacing: .1px;
}

.subscribe-link:hover {
  background: #206652;
}

main {
  width: min(100% - 64px, 1280px);
}

.channel {
  padding-top: 26px;
}

.channel-banner {
  height: clamp(150px, 24vw, 290px);
  border-radius: 28px;
  background-color: #f4c56c;
  background-image:
    linear-gradient(90deg, rgba(28, 54, 43, .1), rgba(28, 54, 43, 0) 58%),
    url("https://yt3.googleusercontent.com/0lVtZ8I52jToGHZca4Ph4xBH2gmATnzcpeq__XM678j5UGmutR7lOJTAQxy4jiiJAAmYLyz1fg=w1707-fcrop64=1,00005a57ffffa5a8-k-c0xffffffff-no-nd-rj");
  box-shadow: 0 18px 40px rgba(87, 67, 33, .13);
}

.welcome-copy {
  max-width: 760px;
  margin: 0 auto;
  padding: 48px 20px 36px;
  text-align: center;
}

.eyebrow {
  display: inline-block;
  margin-bottom: 12px;
  color: #c5752f;
  font-size: 12px;
  font-weight: 800;
  letter-spacing: 1.8px;
  text-transform: uppercase;
}

.welcome-copy h1 {
  margin: 0;
  color: #294239;
  font-family: Georgia, "Times New Roman", serif;
  font-size: clamp(30px, 5vw, 48px);
  font-weight: 700;
  letter-spacing: -1.3px;
  line-height: 1.12;
}

.welcome-copy p {
  max-width: 660px;
  margin: 16px auto 20px;
  color: #637067;
  font-size: 16px;
  line-height: 1.75;
}

.welcome-link {
  display: inline-flex;
  align-items: center;
  gap: 9px;
  padding: 11px 17px;
  border: 1px solid #d6e5d7;
  border-radius: 24px;
  color: #287c68;
  font-size: 14px;
  font-weight: 700;
  transition: background 150ms ease, transform 150ms ease;
}

.welcome-link:hover {
  transform: translateY(-2px);
  background: #edf5eb;
}

.channel-heading {
  gap: 17px;
  padding: 18px 4px 24px;
}

.channel-avatar,
.video-avatar {
  border: 3px solid #fff;
  box-shadow: 0 3px 12px rgba(45, 59, 44, .12);
}

.channel-heading h2 {
  margin: 0;
  color: #294239;
  font-family: Georgia, "Times New Roman", serif;
  font-size: 22px;
}

.channel-heading p {
  margin: 5px 0 0;
  color: #788177;
  font-size: 13px;
}

.channel-tabs {
  gap: 26px;
  border-bottom-color: #e6dece;
}

.channel-tab {
  color: #7a8178;
}

button.channel-tab {
  color: #287c68;
}

.channel-tab.active::after {
  height: 3px;
  border-radius: 3px 3px 0 0;
  background: #e99b42;
}

.external-tab:hover {
  color: #287c68;
}

.videos-section {
  padding: 30px 0 72px;
}

.section-toolbar {
  margin-bottom: 24px;
}

.section-toolbar h2 {
  color: #294239;
  font-family: Georgia, "Times New Roman", serif;
  font-size: 25px;
}

.sort-controls {
  gap: 7px;
}

.sort-button {
  border: 1px solid transparent;
  border-radius: 20px;
  background: #f1eadc;
  color: #59665d;
}

.sort-button:hover {
  background: #e8dfce;
}

.sort-button.selected {
  border-color: #287c68;
  background: #287c68;
  color: #fff;
}

.video-grid {
  column-gap: 22px;
  row-gap: 38px;
}

.thumbnail-button {
  border-radius: 18px;
  background: #eee3d1;
  box-shadow: 0 7px 18px rgba(67, 62, 45, .1);
}

.thumbnail-button img {
  transition: transform 250ms ease;
}

.thumbnail-button:hover img {
  transform: scale(1.045);
}

.duration {
  border-radius: 6px;
  font-size: 11px;
}

.video-details {
  gap: 10px;
  padding-top: 13px;
}

.video-title {
  color: #34473d;
  font-size: 14px;
  line-height: 1.5;
}

.video-title:hover {
  color: #287c68;
}

.all-videos-link {
  border-color: #d7e4d8;
  border-radius: 24px;
  color: #287c68;
  font-weight: 700;
}

.all-videos-link:hover {
  background: #edf5eb;
}

.empty-state {
  color: #727d73;
}

.site-footer {
  padding: 48px 32px 28px;
  background: #294239;
  color: #edf2e8;
}

.footer-inner {
  display: grid;
  width: min(100%, 1216px);
  grid-template-columns: minmax(220px, 1fr) minmax(220px, .8fr);
  gap: 28px 64px;
  margin: 0 auto;
}

.footer-brand .brand-name {
  color: #fffaf0;
}

.footer-intro p {
  max-width: 260px;
  color: #c3d0c4;
  font-size: 14px;
  line-height: 1.6;
}

.footer-nav {
  display: flex;
  align-content: start;
  justify-content: flex-end;
  flex-wrap: wrap;
  gap: 12px 22px;
  padding-top: 11px;
}

.footer-nav a {
  color: #f4d69f;
  font-size: 13px;
  font-weight: 700;
}

.footer-nav a:hover {
  color: #fff;
  text-decoration: underline;
  text-underline-offset: 4px;
}

.footer-policy {
  padding-top: 22px;
  border-top: 1px solid rgba(233, 241, 229, .18);
  scroll-margin-top: 90px;
}

.footer-policy h2 {
  margin: 0 0 10px;
  color: #fffaf0;
  font-family: Georgia, "Times New Roman", serif;
  font-size: 18px;
}

.footer-policy p {
  margin: 0;
  color: #c3d0c4;
  font-size: 13px;
  line-height: 1.75;
}

.footer-note {
  grid-column: 1 / -1;
  margin: 0;
  padding-top: 18px;
  border-top: 1px solid rgba(233, 241, 229, .18);
  color: #aebfb0;
  font-size: 12px;
}

.player-dialog {
  border-color: #d7e4d8;
  background: #fffaf0;
  color: #23332d;
}

.player-dialog-bar p {
  color: #294239;
}

.close-player {
  color: #294239;
}

.close-player:hover {
  background: #f1eadc;
}

.player-fallback {
  color: #637067;
}

.player-fallback a {
  background: #287c68;
  color: #fff;
}

@media (max-width: 760px) {
  .topbar {
    grid-template-columns: 1fr minmax(0, 1.5fr) auto;
    gap: 12px;
    padding: 0 16px;
  }

  main {
    width: min(100% - 32px, 680px);
  }

  .channel-banner {
    border-radius: 20px;
  }

  .welcome-copy {
    padding: 36px 10px 24px;
  }

  .welcome-copy p {
    font-size: 15px;
  }

  .site-footer {
    padding: 38px 24px 24px;
  }

  .footer-inner {
    grid-template-columns: 1fr;
    gap: 22px;
  }

  .footer-nav {
    justify-content: flex-start;
    padding: 0 0 8px;
  }
}

@media (max-width: 500px) {
  .topbar {
    grid-template-columns: 1fr minmax(0, 1.2fr);
    gap: 10px;
    padding: 0 12px;
  }

  .brand {
    gap: 7px;
  }

  .brand-mark {
    width: 32px;
    height: 32px;
    border-radius: 11px;
    font-size: 21px;
  }

  .brand-name {
    font-size: 15px;
  }

  .search input {
    font-size: 13px;
  }

  main {
    width: min(100% - 28px, 680px);
  }

  .channel-banner {
    height: 145px;
    border-radius: 16px;
    background-position: center;
  }

  .welcome-copy h1 {
    font-size: 32px;
    letter-spacing: -.8px;
  }

  .welcome-copy p {
    line-height: 1.65;
  }

  .channel-heading {
    gap: 12px;
    padding: 15px 0 19px;
  }

  .channel-avatar {
    width: 62px;
    height: 62px;
  }

  .channel-heading h2 {
    font-size: 18px;
  }

  .channel-heading p {
    font-size: 12px;
  }

  .videos-section {
    padding-top: 24px;
  }

  .section-toolbar h2 {
    font-size: 23px;
  }

  .video-grid {
    column-gap: 11px;
    row-gap: 25px;
  }

  .thumbnail-button {
    border-radius: 12px;
  }

  .video-details {
    gap: 0;
  }

  .video-avatar {
    display: none;
  }

  .footer-nav {
    flex-direction: column;
    gap: 14px;
  }

  .site-footer {
    padding-right: 20px;
    padding-left: 20px;
  }
}
