@import url("https://fonts.googleapis.com/css2?family=Unbounded:wght@200;300;400;500&family=Montserrat:wght@300;400;500&display=swap");

/* Y.Blues theme: dark, blues-metal. It styles the yc-* classes the three renderers share (ui_web, ui_static)
   for the public site and the admin. */
:root {
  --bg: #0c0c0e;
  --panel: #17171b;
  --ink: #fff;
  --muted: rgba(255, 255, 255, 0.66);
  --line: #2c2c33;
  --accent: #c8452a;
  --brass: #e0a24a; /* the amber of the sleeves (Adrastia, The Arrival, Belong to the Barrel) */
  --display: "Unbounded", "Montserrat", system-ui, sans-serif;
  --text: "Montserrat", system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
  --error: #f0877a;
  --radius: 6px;
  --nav-h: 76px; /* sticky bar (68px) + a gap: where an anchored section stops */
  color-scheme: dark;
}

html {
  scroll-padding-top: var(--nav-h);
}

@media (prefers-reduced-motion: no-preference) {
  html {
    scroll-behavior: smooth;
  }
}

* {
  box-sizing: border-box;
}

body {
  margin: 0;
  background: var(--bg);
  color: var(--ink);
  font: 300 16px/1.75 var(--text);
  -webkit-font-smoothing: antialiased;
}

a {
  color: var(--brass);
}

a:hover {
  color: var(--ink);
}

.yc-child a {
  color: var(--ink);
  text-decoration: none;
}

.yc-child a:hover {
  color: var(--brass);
}

/* bar: fixed at the top, solid, above the sections */
.yc-nav {
  position: sticky;
  top: 0;
  z-index: 50;
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 6px 20px;
  padding: 10px max(20px, calc((100% - 1200px) / 2 + 20px));
  background: #000;
  border-bottom: 1px solid rgba(224, 162, 74, 0.45);
}

.yc-brand {
  display: block;
  width: 110px;
  height: 55px;
  overflow: hidden;
  text-indent: -9999px;
  white-space: nowrap;
  background: url("/logo-complet.png") no-repeat left center / contain;
}

.yc-menus {
  display: flex;
  flex-wrap: wrap;
  gap: 2px;
  flex: 1;
}

.yc-menus:has(> .yc-nav-link) {
  flex-wrap: nowrap;
  min-width: 0;
  overflow-x: auto;
  scrollbar-width: none;
}

.yc-menus:has(> .yc-nav-link)::-webkit-scrollbar {
  display: none;
}

.yc-nav-link {
  flex: none;
  line-height: 24px;
  white-space: nowrap;
}

.yc-menu-item,
.yc-nav-link {
  font: 400 12px/1.6 var(--display);
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--ink);
  background: none;
  border: 0;
  padding: 6px 12px;
  border-radius: var(--radius);
  text-decoration: none;
  cursor: pointer;
}

.yc-menu-item:hover,
.yc-nav-link:hover,
.yc-menu-item.yc-active,
.yc-nav-link[aria-current="page"] {
  color: var(--brass);
  background: rgba(255, 255, 255, 0.07);
}

.yc-languages {
  display: flex;
  gap: 4px;
}

.yc-language {
  padding: 4px 8px;
  font: 400 11px/1.6 var(--display);
  letter-spacing: 0.12em;
  text-transform: uppercase;
  text-decoration: none;
  color: var(--muted);
  border: 1px solid var(--line);
  border-radius: var(--radius);
}

.yc-language:hover {
  color: var(--ink);
}

/* admin bar: one dropdown per section */
.yc-menu {
  position: relative;
}

.yc-menu-label {
  list-style: none;
  cursor: pointer;
  padding: 6px 12px;
  border-radius: var(--radius);
  user-select: none;
}

.yc-menu-label::-webkit-details-marker {
  display: none;
}

.yc-menu-label::after {
  content: "";
  display: inline-block;
  margin-left: 8px;
  vertical-align: 2px;
  border: 4px solid transparent;
  border-top-color: currentColor;
  border-bottom: 0;
}

.yc-menu[open] > .yc-menu-label,
.yc-menu-label:hover {
  background: rgba(255, 255, 255, 0.07);
}

.yc-menu-items {
  position: absolute;
  z-index: 10;
  top: calc(100% + 8px);
  left: 0;
  min-width: 220px;
  padding: 6px;
  display: flex;
  flex-direction: column;
  background: var(--panel);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.6);
}

.yc-menu-items .yc-menu-item {
  text-align: left;
}

.yc-session {
  display: flex;
  align-items: center;
  gap: 12px;
}

.yc-user {
  color: var(--brass);
  font-weight: 400;
}

/* content */
.yc-content {
  max-width: 1200px;
  margin: 0 auto;
  padding: 40px 20px 72px;
}

.yc-heading,
.yc-title {
  margin: 0 0 24px;
  font-family: var(--display);
  font-weight: 300;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  line-height: 1.25;
}

h1.yc-heading {
  font-size: 28px;
}

.yc-section {
  margin: 0;
  padding: 56px 24px 8px;
  background: rgba(12, 12, 14, 0.3); /* the background video stays visible behind the sections */
  border-top: 1px solid var(--line);
}

.yc-section-title {
  margin: 0 0 24px;
  font-family: var(--display);
  font-size: 24px;
  font-weight: 300;
  line-height: 1.25;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: var(--ink);
  text-shadow: 0 1px 14px rgba(0, 0, 0, 0.85);
}

.yc-section-title::after {
  content: "";
  display: block;
  width: 40px;
  height: 1px;
  margin-top: 16px;
  background: var(--brass);
}

.yc-section .yc-section {
  padding: 0;
  background: none;
  border-top: 0;
}

.yc-section .yc-section .yc-section-title {
  margin: 32px 0 12px;
  font-size: 14px;
  font-weight: 400;
  letter-spacing: 0.16em;
}

.yc-section .yc-section .yc-section-title::after {
  content: none;
}

/* footer: the last section of a page, the one without anchor */
.yc-page > .yc-section:not([id]):last-child {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 4px;
  padding: 32px 16px 40px;
  text-align: center;
  background: rgba(0, 0, 0, 0.55);
}

.yc-page > .yc-section:not([id]):last-child .yc-text {
  max-width: none;
  margin: 0;
  font-size: 13px;
  letter-spacing: 0.06em;
  color: rgba(255, 255, 255, 0.82);
}

.yc-page > .yc-section:not([id]):last-child .yc-links {
  margin: 4px 0 0;
  justify-content: center;
}

.yc-page > .yc-section:not([id]):last-child .yc-link {
  font-size: 12px;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: rgba(255, 255, 255, 0.82);
  text-decoration: none;
  border-bottom: 1px solid rgba(224, 162, 74, 0.6);
}

.yc-page > .yc-section:not([id]):last-child .yc-link:hover {
  color: var(--brass);
}

.yc-page > .yc-section:not([id]):last-child .yc-image {
  height: 84px;
  width: auto;
  margin-top: 10px;
  padding: 3px 12px;
  background: #fff; /* the logo is drawn on a light background */
  border-radius: 8px;
}

/* background video: one fixed layer behind the page; the poster is what stays when the frame is off */
.yc-background-video {
  position: fixed;
  inset: var(--bar-h, 0px) 0 0; /* under the bar: the top of the video is not hidden by it */
  z-index: -1;
  pointer-events: none;
  overflow: hidden;
  background: #000;
}

.yc-background-video::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(rgba(0, 0, 0, 0.3), rgba(0, 0, 0, 0.45));
}

img.yc-background-poster {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center top;
}

/* 16:9 frame covering the visible area (the viewport under the bar) whatever its ratio: centered sideways, and
   glued to the top, so that only the bottom of the picture is cut */
iframe.yc-background-frame {
  position: absolute;
  top: 0;
  left: 50%;
  width: 100vw;
  height: 56.25vw;
  min-width: calc((100vh - var(--bar-h, 0px)) * 1.7778);
  min-height: calc(100vh - var(--bar-h, 0px));
  transform: translateX(-50%);
  border: 0;
  object-fit: cover;
}

/* hero: the first section, full height under the bar; its h2 only feeds the menu */
#accueil {
  padding: 0;
  background: none;
  border-top: 0;
}

#accueil > .yc-section-title {
  position: absolute;
  width: 1px;
  height: 1px;
  margin: -1px;
  overflow: hidden;
  clip-path: inset(50%);
  white-space: nowrap;
}

#accueil > .yc-detail {
  min-height: calc(100vh - var(--nav-h));
  min-height: calc(100svh - var(--nav-h));
  display: flex;
  flex-wrap: wrap;
  align-content: center;
  align-items: center;
  justify-content: center;
  gap: 16px;
  padding: 24px 0;
  text-align: center;
}

#accueil > .yc-detail > .yc-heading {
  position: absolute;
  width: 1px;
  height: 1px;
  margin: -1px;
  overflow: hidden;
  clip-path: inset(50%);
  white-space: nowrap;
}

#accueil > .yc-detail > .yc-text {
  flex: 1 0 100%;
  max-width: none;
  margin: 0;
  font-size: clamp(16px, 2vw, 22px);
  font-weight: 300;
  letter-spacing: 0.04em;
  text-shadow: 0 1px 12px rgba(0, 0, 0, 0.8);
}

/* call to action: the first is filled, the following ones outlined */
a.yc-button.yc-cta {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 44px;
  min-height: 44px;
  padding: 10px 32px;
  font: 400 12px/1.4 var(--display);
  letter-spacing: 0.2em;
  text-transform: uppercase;
  text-decoration: none;
  color: #1a1206;
  background: var(--brass);
  border: 1px solid var(--brass);
  border-radius: 2px;
}

a.yc-button.yc-cta:hover {
  color: #000;
}

a.yc-button.yc-cta ~ a.yc-button.yc-cta {
  color: var(--ink);
  background: transparent;
  border-color: rgba(255, 255, 255, 0.7);
}

a.yc-button.yc-cta ~ a.yc-button.yc-cta:hover {
  color: var(--brass);
  background: rgba(255, 255, 255, 0.06);
  border-color: var(--brass);
}

.yc-text,
.yc-slot-text {
  max-width: 72ch;
  margin: 0 0 1em;
}

.yc-pre {
  white-space: pre-wrap;
}

.yc-collection {
  display: grid;
  gap: 20px;
  margin: 0 0 32px;
}

.yc-layout-list,
.yc-layout-timeline {
  grid-template-columns: 1fr;
}

.yc-layout-grid {
  grid-template-columns: repeat(auto-fill, minmax(240px, 1fr));
}

/* carousel: a strip browsed with the two buttons (or a swipe); images and videos enlarge in a modal */
.yc-carousel {
  position: relative;
  margin: 0 0 32px;
}

.yc-layout-carousel {
  display: flex;
  align-items: start;
  gap: 16px;
  margin: 0;
  overflow-x: auto;
  scroll-snap-type: x mandatory;
  overscroll-behavior-x: contain;
  scrollbar-width: none;
}

.yc-layout-carousel::-webkit-scrollbar {
  display: none;
}

@media (prefers-reduced-motion: no-preference) {
  .yc-layout-carousel {
    scroll-behavior: smooth;
  }
}

.yc-layout-carousel > .yc-card {
  flex: 0 0 min(360px, 82%);
  scroll-snap-align: start;
}

.yc-layout-carousel .yc-slot-image {
  aspect-ratio: 3 / 2;
  object-fit: cover;
  cursor: zoom-in;
}

/* videos: cards of the same height */
#videos .yc-layout-carousel {
  align-items: stretch;
}

/* the biography, then the band members centered under it */
#bio .yc-detail {
  margin-bottom: 32px;
}

#bio .yc-layout-grid {
  grid-template-columns: repeat(auto-fit, minmax(200px, 260px));
  justify-content: center;
}

#bio .yc-layout-grid .yc-card {
  text-align: center;
}

#bio .yc-layout-grid .yc-slot-image {
  aspect-ratio: 1;
  object-fit: cover;
  object-position: center 30%;
}

.yc-page > a.yc-button.yc-cta {
  margin: 16px 0 32px;
}

/* photos: two rows */
#photos .yc-layout-carousel {
  display: grid;
  grid-auto-flow: column;
  grid-template-rows: repeat(2, auto);
  grid-auto-columns: min(300px, 72%);
}

#photos .yc-card {
  padding: 0;
  background: none;
  border: 0;
}

#photos .yc-slot-image {
  margin: 0;
}

.yc-carousel-prev,
.yc-carousel-next {
  position: absolute;
  top: 50%;
  z-index: 5;
  width: 44px;
  height: 44px;
  padding: 0;
  font: 300 20px/1 var(--display);
  color: var(--ink);
  background: rgba(0, 0, 0, 0.7);
  border: 1px solid rgba(255, 255, 255, 0.5);
  border-radius: 50%;
  translate: 0 -50%;
  cursor: pointer;
}

.yc-carousel-prev {
  left: 8px;
}

.yc-carousel-next {
  right: 8px;
}

.yc-carousel-prev::before {
  content: "\2190";
}

.yc-carousel-next::before {
  content: "\2192";
}

.yc-carousel-prev:hover,
.yc-carousel-next:hover {
  color: var(--brass);
  border-color: var(--brass);
}

.yc-carousel-prev:focus-visible,
.yc-carousel-next:focus-visible {
  outline: 2px solid var(--brass);
  outline-offset: 2px;
}

.yc-layout-timeline .yc-card {
  border-left: 3px solid var(--accent);
}

.yc-card {
  padding: 16px;
  background: var(--panel);
  border: 1px solid var(--line);
  border-radius: var(--radius);
}

.yc-slot-image {
  display: block;
  width: 100%;
  height: auto;
  margin-bottom: 12px;
  border-radius: 4px;
  background: var(--bg);
}

.yc-slot-title {
  margin: 0 0 4px;
  font-family: var(--display);
  font-size: 15px;
  font-weight: 300;
  letter-spacing: 0.08em;
  line-height: 1.4;
}

h1.yc-slot-title {
  font-size: 26px;
  text-transform: uppercase;
  letter-spacing: 0.12em;
}

.yc-slot-subtitle {
  margin: 0 0 8px;
  color: var(--muted);
}

.yc-slot-badge {
  display: inline-block;
  margin-bottom: 8px;
  padding: 1px 8px;
  font: 400 10px/1.8 var(--display);
  text-transform: uppercase;
  letter-spacing: 0.14em;
  color: #1a1206;
  background: var(--brass);
  border-radius: 999px;
}

.yc-children {
  margin-top: 12px;
  padding-top: 12px;
  border-top: 1px solid var(--line);
}

.yc-child-list {
  gap: 0;
  margin: 0;
}

.yc-child {
  padding: 4px 0;
  background: none;
  border: 0;
  border-radius: 0;
}

.yc-child .yc-slot-title {
  margin: 0;
  font: 300 15px/1.6 var(--text);
  letter-spacing: 0;
}

.yc-links {
  display: flex;
  flex-wrap: wrap;
  gap: 8px 20px;
  margin: 24px 0;
}

.yc-slot-embed,
.yc-embed {
  display: block;
  width: 100%;
  max-width: 720px;
}

.yc-embed,
.yc-slot-embed:not(:has(.yc-embed)) {
  position: relative;
  aspect-ratio: 16 / 9;
  margin: 12px 0;
  overflow: hidden;
  background: #000;
  border-radius: var(--radius);
}

.yc-slot-embed .yc-embed {
  max-width: none;
  margin: 0;
}

.yc-embed > *,
.yc-slot-embed:not(:has(.yc-embed)) > * {
  position: absolute;
  inset: 0;
  display: block;
  width: 100%;
  height: 100%;
  border: 0;
  object-fit: cover;
}

.yc-embed-play {
  font: 400 12px/1.4 var(--display);
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: var(--ink);
  background: linear-gradient(160deg, #1d1d22, #000);
  cursor: pointer;
}

.yc-embed-play::before {
  content: "";
  display: block;
  width: 0;
  height: 0;
  margin: 0 auto 8px;
  border: 14px solid transparent;
  border-left: 24px solid var(--accent);
  border-right: 0;
}

.yc-embed-play:hover {
  color: var(--brass);
}

/* with a thumbnail behind it, the button is only the play mark (its text stays for screen readers) */
.yc-embed-thumb + .yc-embed-play {
  font-size: 0;
  background: rgba(0, 0, 0, 0.28);
  transition: background-color 120ms ease;
}

.yc-embed-thumb + .yc-embed-play:hover {
  background: rgba(0, 0, 0, 0.1);
}

.yc-embed-thumb + .yc-embed-play::before {
  margin: 0 auto;
  border-left-color: var(--ink);
  filter: drop-shadow(0 2px 8px rgba(0, 0, 0, 0.6));
}

/* modal: the enlarged image or video of a carousel */
.yc-modal {
  position: fixed;
  inset: 0;
  z-index: 100;
  display: grid;
  place-items: center;
  padding: 56px 16px 24px;
  background: #000; /* hides the background video while an image or a video is watched */
  cursor: zoom-out;
}

body:has(.yc-modal) {
  overflow: hidden; /* the page stays put behind the modal */
}

.yc-modal-image {
  max-width: 100%;
  max-height: 100%;
  object-fit: contain;
}

iframe.yc-modal-frame {
  width: min(100%, 1200px, calc((100vh - 96px) * 16 / 9));
  aspect-ratio: 16 / 9;
  border: 0;
  background: #000;
}

.yc-modal-close {
  position: absolute;
  top: 8px;
  right: 12px;
  width: 44px;
  height: 44px;
  font: 300 32px/1 var(--display);
  color: var(--ink);
  background: none;
  border: 0;
  cursor: pointer;
}

.yc-modal-close:hover {
  color: var(--brass);
}

.yc-image {
  max-width: 100%;
  height: auto;
}

.yc-not-found {
  color: var(--muted);
}

/* forms (contact, login, admin) */
.yc-screen {
  max-width: 560px;
}

.yc-field {
  display: flex;
  flex-direction: column;
  gap: 6px;
  margin-bottom: 16px;
}

.yc-label {
  font: 400 11px/1.6 var(--display);
  letter-spacing: 0.14em;
  text-transform: uppercase;
}

.yc-input {
  font: 300 16px/1.6 var(--text);
  color: inherit;
  background: var(--panel);
  border: 1px solid var(--line);
  border-radius: 4px;
  padding: 9px 12px;
}

textarea.yc-input {
  min-height: 9em;
  resize: vertical;
}

.yc-input:focus {
  outline: 2px solid var(--accent);
  outline-offset: 1px;
}

.yc-field-boolean .yc-input {
  align-self: flex-start;
  width: 18px;
  height: 18px;
}

.yc-error,
.yc-status {
  color: var(--error);
  font-weight: 400;
}

.yc-error {
  font-size: 13px;
}

.yc-error:empty,
.yc-status:empty {
  display: none;
}

.yc-actions {
  display: flex;
  gap: 8px;
  margin-top: 24px;
}

.yc-button {
  font: 400 12px/1.4 var(--display);
  letter-spacing: 0.16em;
  text-transform: uppercase;
  padding: 11px 24px;
  color: #1a1206;
  background: var(--brass);
  border: 1px solid var(--brass);
  border-radius: 2px;
  cursor: pointer;
}

.yc-delete.yc-button {
  color: var(--error);
  background: transparent;
  border-color: var(--error);
}

/* the form of a section: the section already has the title */
.yc-section .yc-screen > .yc-title {
  display: none;
}

.yc-button:hover {
  filter: brightness(1.15);
}

.yc-cancel,
.yc-sign-out.yc-button {
  color: var(--ink);
  background: transparent;
  border-color: var(--line);
}

.yc-message {
  margin: 0 0 24px;
  font-size: 20px;
  font-weight: 400;
}

/* admin lists */
.yc-table {
  width: 100%;
  border-collapse: collapse;
  margin: 16px 0;
}

.yc-table th,
.yc-table td,
.yc-cell {
  padding: 8px 10px;
  text-align: left;
  border-bottom: 1px solid var(--line);
  vertical-align: top;
}

.yc-viewable {
  cursor: pointer;
}

.yc-row-actions {
  white-space: nowrap;
}

.yc-row-actions .yc-button + .yc-button {
  margin-left: 8px;
}

.yc-media-thumb {
  display: block;
  width: 96px;
  height: 64px;
  object-fit: cover;
  border-radius: 4px;
  background: var(--panel);
}

.yc-media-large {
  display: block;
  max-width: min(100%, 560px);
  max-height: 420px;
  border-radius: var(--radius);
}

tr.yc-row:hover .yc-viewable {
  background: rgba(255, 255, 255, 0.04);
}

/* a record to read: one label and its value per row */
.yc-fields {
  margin: 16px 0;
}

.yc-field-row {
  display: grid;
  grid-template-columns: minmax(140px, 220px) 1fr;
  gap: 4px 20px;
  padding: 10px 0;
  border-bottom: 1px solid var(--line);
}

.yc-field-label {
  font: 400 11px/1.8 var(--display);
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--brass);
}

.yc-field-value {
  margin: 0;
  overflow-wrap: anywhere;
  white-space: pre-wrap;
}

.yc-field-value:empty::before {
  content: "\2014";
  color: var(--muted);
}

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

.yc-media-preview {
  max-width: 200px;
  height: auto;
  margin-top: 8px;
}

.yc-confirm-box {
  padding: 16px;
  background: var(--panel);
  border: 1px solid var(--accent);
  border-radius: var(--radius);
}

a:focus-visible,
a.yc-button.yc-cta:focus-visible,
.yc-button:focus-visible,
.yc-menu-item:focus-visible,
.yc-menu-label:focus-visible {
  outline: 2px solid var(--brass);
  outline-offset: 2px;
}

.yc-nav-link:focus-visible {
  outline-offset: -2px; /* the scrolling menu would clip it */
}

@media (max-width: 640px) {
  :root:not(:has(.yc-burger)) {
    --nav-h: 124px; /* two rows: brand and languages, then the menu */
  }

  .yc-nav {
    padding: 10px 16px;
  }

  .yc-brand {
    margin-right: auto;
  }

  .yc-menus {
    flex-basis: 100%;
    order: 3;
  }

  .yc-section {
    padding: 40px 16px 8px;
  }

  .yc-section-title {
    font-size: 19px;
    letter-spacing: 0.16em;
  }

  .yc-menu-items {
    position: static;
    margin-top: 4px;
    box-shadow: none;
  }

  .yc-content {
    padding: 28px 8px 48px;
  }

  .yc-card {
    padding: 12px;
  }

  /* touch targets of 44 px */
  .yc-nav-link,
  .yc-menu-item {
    display: inline-flex;
    align-items: center;
    min-height: 44px;
  }

  .yc-language {
    display: inline-flex;
    align-items: center;
    min-height: 40px;
    padding: 4px 12px;
  }

  .yc-button {
    min-height: 44px;
  }

  .yc-input {
    min-height: 44px;
    font-size: 16px; /* under 16 px a phone zooms the page when a field gets the focus */
  }

  .yc-carousel-prev,
  .yc-carousel-next {
    width: 40px;
    height: 40px;
    background: rgba(0, 0, 0, 0.55);
  }

  .yc-carousel-prev {
    left: 2px;
  }

  .yc-carousel-next {
    right: 2px;
  }

  .yc-modal {
    padding: 56px 0 16px;
  }

  h1.yc-heading {
    font-size: 22px;
  }

  .yc-table {
    display: block;
    overflow-x: auto;
  }
}

/* wide screens: the whole logo at the top left, the menu pushed to the right */
:root:has(.yc-burger) {
  --nav-h: 100px;
  --bar-h: 93px; /* the height of the bar: 8 + 76 + 8 + its border */
}

.yc-nav:has(.yc-burger) {
  padding: 8px 28px;
  gap: 6px 24px;
}

.yc-nav:has(.yc-burger) .yc-brand {
  width: 152px;
  height: 76px;
}

.yc-nav:has(.yc-burger) .yc-menus {
  justify-content: flex-end;
}

.yc-nav:has(.yc-burger) .yc-nav-link {
  padding: 6px 10px;
}

/* screens under 1280 px: the sections menu folds behind a burger (a checkbox before the menu, opened by :checked, no script) */
.yc-burger-toggle {
  position: absolute;
  width: 1px;
  height: 1px;
  margin: -1px;
  overflow: hidden;
  opacity: 0;
  clip: rect(0 0 0 0);
}

.yc-burger {
  display: none;
}

@media (max-width: 1279px) {
  :root:has(.yc-burger) {
    --nav-h: 72px;
    --bar-h: 71px; /* 10 + 50 + 10 + its border */
  }

  .yc-nav:has(.yc-burger) {
    padding: 10px 16px;
    row-gap: 0;
  }

  .yc-nav:has(.yc-burger) .yc-brand {
    order: 1;
    width: 100px;
    height: 50px;
    margin-right: auto;
  }

  .yc-nav:has(.yc-burger) .yc-languages {
    order: 2;
  }

  .yc-burger {
    order: 3;
    position: relative;
    display: block;
    flex: none;
    width: 44px;
    height: 44px;
    cursor: pointer;
    border-radius: var(--radius);
  }

  .yc-burger::before,
  .yc-burger::after {
    content: "";
    position: absolute;
    top: 21px;
    left: 11px;
    width: 22px;
    height: 2px;
    background: var(--ink);
  }

  .yc-burger::before {
    box-shadow: 0 -7px 0 var(--ink), 0 7px 0 var(--ink);
  }

  .yc-burger::after {
    opacity: 0;
    transform: rotate(-45deg);
  }

  .yc-burger-toggle:checked + .yc-burger::before {
    box-shadow: none;
    transform: rotate(45deg);
  }

  .yc-burger-toggle:checked + .yc-burger::after {
    opacity: 1;
  }

  .yc-burger-toggle:focus-visible + .yc-burger {
    outline: 2px solid var(--brass);
  }

  .yc-nav:has(.yc-burger) .yc-menus {
    order: 4;
    display: none;
    flex-basis: 100%;
    flex-direction: column;
    flex-wrap: nowrap;
    gap: 0;
    margin-top: 8px;
    padding: 4px 0 8px;
    overflow: visible;
    border-top: 1px solid var(--line);
    max-height: calc(100vh - 80px);
    max-height: calc(100svh - 80px);
    overflow-y: auto;
    justify-content: flex-start;
  }

  .yc-burger-toggle:checked ~ .yc-menus {
    display: flex;
  }

  .yc-nav:has(.yc-burger) .yc-nav-link {
    display: flex;
    align-items: center;
    min-height: 48px;
    padding: 8px 4px;
    font-size: 13px;
    border-radius: 0;
    border-bottom: 1px solid rgba(255, 255, 255, 0.06);
  }
}

@media (max-width: 1279px) and (prefers-reduced-motion: no-preference) {
  .yc-burger::before,
  .yc-burger::after {
    transition: transform 0.2s, box-shadow 0.2s, opacity 0.2s;
  }
}

@media (max-width: 380px) {
  :root:has(.yc-burger) {
    --bar-h: 65px;
  }

  .yc-nav:has(.yc-burger) .yc-brand {
    width: 88px;
    height: 44px;
  }
}

/* no moving background on small screens, for reduced motion or reduced data: the poster only
   (the frame is lazy-loaded, so hidden it is never fetched; the Save-Data header is out of CSS's reach) */
@media (prefers-reduced-motion: reduce), (max-width: 640px), (prefers-reduced-data: reduce) {
  iframe.yc-background-frame {
    display: none;
  }
}

@media (prefers-reduced-motion: no-preference) {
  .yc-embed-play,
  .yc-menu-item,
  .yc-nav-link,
  .yc-button {
    transition: background-color 120ms ease, filter 120ms ease;
  }
}
