.media-collector-child-nav {
  display: flex;
  gap: 8px;
  width: min(100%, 760px);
  margin: 0 auto 20px;
  padding: 7px;
  border: 1px solid rgba(126,178,255,.2);
  border-radius: 18px;
  background: linear-gradient(145deg,rgba(24,31,49,.92),rgba(24,18,39,.92));
  box-shadow: 0 14px 34px rgba(0,0,0,.18);
}

.media-collector-child-nav button {
  flex: 1 1 0;
  min-height: 44px;
  border: 1px solid transparent;
  border-radius: 13px;
  background: transparent;
  color: #b9c8df;
  font-weight: 850;
  letter-spacing: .01em;
}

.media-collector-child-nav button.active {
  color: #102033;
  border-color: rgba(166,237,255,.95);
  background: linear-gradient(135deg,#8cecff,#73d9ff 45%,#b7a2ff);
  box-shadow: 0 8px 22px rgba(79,198,255,.16);
}

.media-watch-section {
  width: 100%;
  max-width: 1280px;
  margin: 0 auto;
  padding: 0 clamp(0px,1vw,10px) 52px;
}

.media-watch-heading {
  margin-bottom: 18px;
}

.media-watch-heading h1 {
  margin: 4px 0 7px;
}

.media-watch-heading p:last-child {
  max-width: 760px;
  margin: 0;
  color: var(--muted);
  line-height: 1.55;
}

.watch-quota-card {
  display: grid;
  gap: 12px;
  margin-bottom: 18px;
  padding: 18px;
  border: 1px solid rgba(127,190,255,.24);
  border-radius: 22px;
  background:
    radial-gradient(circle at 10% 0%,rgba(88,200,255,.14),transparent 38%),
    linear-gradient(145deg,rgba(24,35,61,.94),rgba(37,24,58,.94));
  box-shadow: 0 18px 42px rgba(0,0,0,.18);
}

.watch-quota-top {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 18px;
}

.watch-quota-copy small {
  display: block;
  color: #b6c7df;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: .08em;
}

.watch-quota-copy strong {
  display: block;
  margin-top: 4px;
  font-size: clamp(1.3rem,4vw,2rem);
}

.watch-quota-card p {
  margin: 0;
  color: #c6d2e7;
}

.watch-quota-track {
  height: 9px;
  overflow: hidden;
  border-radius: 999px;
  background: rgba(255,255,255,.09);
}

.watch-quota-track::before {
  content: '';
  display: block;
  width: var(--watch-quota-progress,0%);
  height: 100%;
  border-radius: inherit;
  background: linear-gradient(90deg,#73d9ff,#a7a0ff);
  transition: width .22s ease;
}

.watch-quota-card[data-state="warning"] .watch-quota-track::before {
  background: linear-gradient(90deg,#f2b84b,#ffcf73);
}

.watch-quota-card[data-state="exhausted"] {
  border-color: rgba(255,111,111,.34);
}

.watch-filter-panel {
  display: grid;
  grid-template-columns: minmax(220px,1.35fr) repeat(3,minmax(150px,.7fr));
  gap: 10px;
  padding: 14px;
  margin-bottom: 14px;
  border: 1px solid rgba(120,183,255,.2);
  border-radius: 20px;
  background: linear-gradient(145deg,rgba(18,24,38,.95),rgba(28,20,42,.95));
}

.watch-filter-panel label {
  display: grid;
  gap: 6px;
  min-width: 0;
  color: #c7d6ec;
  font-size: .72rem;
  font-weight: 800;
  letter-spacing: .05em;
  text-transform: uppercase;
}

.watch-filter-panel input,
.watch-filter-panel select {
  width: 100%;
  min-height: 42px;
  padding: 9px 11px;
  border: 1px solid rgba(126,178,255,.28);
  border-radius: 12px;
  background: rgba(26,31,49,.92);
  color: #eef6ff;
  font: inherit;
}

.watch-filter-panel .watch-filter-search {
  grid-column: span 2;
}

.watch-status {
  min-height: 24px;
  margin: 8px 0 12px;
  color: #aebed5;
}

.watch-grid {
  display: grid;
  grid-template-columns: repeat(3,minmax(0,1fr));
  gap: 16px;
}

.watch-video-card {
  min-width: 0;
  overflow: hidden;
  border: 1px solid rgba(126,178,255,.2);
  border-radius: 20px;
  background: linear-gradient(160deg,rgba(24,30,45,.98),rgba(16,15,25,.98));
  box-shadow: 0 14px 34px rgba(0,0,0,.18);
}

.watch-video-preview {
  position: relative;
  aspect-ratio: 16/10;
  overflow: hidden;
  background: linear-gradient(135deg,rgba(82,98,150,.35),rgba(85,50,119,.35));
}

.watch-video-preview img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.watch-video-placeholder {
  display: grid;
  place-items: center;
  width: 100%;
  height: 100%;
  font-size: 2.4rem;
}

.watch-video-play {
  position: absolute;
  left: 50%;
  top: 50%;
  display: grid;
  place-items: center;
  width: 50px;
  height: 50px;
  padding-left: 3px;
  border: 1px solid rgba(255,255,255,.34);
  border-radius: 50%;
  background: rgba(7,11,20,.72);
  color: #fff;
  transform: translate(-50%,-50%);
  backdrop-filter: blur(8px);
}

.watch-video-duration,
.watch-video-state {
  position: absolute;
  bottom: 10px;
  padding: 5px 8px;
  border-radius: 999px;
  background: rgba(8,11,18,.82);
  font-size: .67rem;
  font-weight: 800;
}

.watch-video-duration {
  right: 10px;
}

.watch-video-state {
  left: 10px;
}

.watch-video-state.owned {
  background: rgba(26,113,77,.9);
}

.watch-video-copy {
  display: grid;
  gap: 10px;
  padding: 15px;
}

.watch-video-path {
  color: #8fcfff;
  font-size: .7rem;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: .06em;
}

.watch-video-copy h2 {
  margin: 0;
  font-size: 1.08rem;
}

.watch-video-copy > p {
  display: -webkit-box;
  min-height: 42px;
  margin: 0;
  overflow: hidden;
  color: #aebdd2;
  line-height: 1.45;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
}

.watch-video-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}

.watch-video-tags button,
.watch-player-tags span {
  padding: 5px 8px;
  border: 1px solid rgba(112,201,255,.24);
  border-radius: 999px;
  background: rgba(61,75,118,.36);
  color: #dbeeff;
  font-size: .66rem;
  font-weight: 750;
}

.watch-video-progress {
  height: 5px;
  overflow: hidden;
  border-radius: 999px;
  background: rgba(255,255,255,.08);
}

.watch-video-progress span {
  display: block;
  height: 100%;
  background: linear-gradient(90deg,#73d9ff,#b7a2ff);
}

.watch-video-actions {
  display: grid;
  gap: 7px;
}

.watch-primary {
  min-height: 42px;
  border: 1px solid rgba(166,237,255,.85);
  border-radius: 12px;
  background: linear-gradient(135deg,#8cecff,#73d9ff 45%,#a99cff);
  color: #102033;
  font-weight: 900;
}

.watch-owned-note,
.watch-locked-note {
  color: #8f9fb6;
  font-size: .7rem;
}

.watch-loading {
  grid-column: 1/-1;
  display: grid;
  place-items: center;
  gap: 10px;
  min-height: 240px;
  color: #b9c7da;
}

.watch-player-dialog {
  width: min(960px,calc(100vw - 20px));
  max-height: 92dvh;
  padding: 0;
  overflow: hidden;
  border: 1px solid rgba(126,178,255,.3);
  border-radius: 24px;
  background: #11141e;
  color: #f4f7ff;
}

.watch-player-dialog::backdrop {
  background: rgba(0,0,0,.78);
  backdrop-filter: blur(6px);
}

.watch-player-shell {
  display: grid;
  max-height: 92dvh;
  overflow: auto;
}

.watch-player-head {
  position: sticky;
  top: 0;
  z-index: 2;
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 12px;
  padding: 15px 16px;
  background: rgba(17,20,30,.97);
  border-bottom: 1px solid rgba(255,255,255,.08);
}

.watch-player-head h2 {
  margin: 0 0 4px;
}

.watch-player-head p {
  margin: 0;
  color: #91a4bd;
}

.watch-player-head button {
  flex: 0 0 auto;
}

.watch-player-video-wrap {
  padding: 12px;
  background: #05070c;
}

#watch-player {
  display: block;
  width: 100%;
  max-height: 62dvh;
  border-radius: 14px;
  background: #000;
}

.watch-player-info {
  display: grid;
  gap: 12px;
  padding: 16px;
}

.watch-player-info > p {
  margin: 0;
  color: #bac7d9;
  line-height: 1.55;
}

.watch-player-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}

.watch-player-quota {
  padding: 10px 12px;
  border: 1px solid rgba(117,217,255,.2);
  border-radius: 12px;
  background: rgba(56,74,115,.28);
  font-weight: 850;
}

.watch-player-message {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 9px;
  padding: 11px 12px;
  border: 1px solid rgba(242,184,75,.28);
  border-radius: 12px;
  background: rgba(242,184,75,.08);
}

.watch-player-message a {
  color: #8cecff;
  font-weight: 850;
}

.watch-player-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.watch-player-actions button,
.watch-player-actions a {
  min-height: 40px;
  padding: 9px 13px;
  border-radius: 11px;
}

@media (max-width: 1000px) {
  .watch-grid {
    grid-template-columns: repeat(2,minmax(0,1fr));
  }

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

  .watch-filter-panel .watch-filter-search {
    grid-column: span 2;
  }
}

@media (max-width: 700px) {
  .media-collector-child-nav {
    width: 100%;
    margin-bottom: 14px;
    padding: 5px;
    border-radius: 15px;
  }

  .media-collector-child-nav button {
    min-height: 40px;
    border-radius: 11px;
    font-size: .8rem;
  }

  .media-watch-section {
    padding-bottom: 34px;
  }

  .watch-quota-card {
    padding: 14px;
    border-radius: 17px;
  }

  .watch-quota-top {
    display: grid;
    gap: 8px;
  }

  .watch-filter-panel {
    grid-template-columns: 1fr;
    padding: 10px;
    border-radius: 16px;
  }

  .watch-filter-panel .watch-filter-search {
    grid-column: auto;
  }

  .watch-grid {
    grid-template-columns: 1fr;
    gap: 12px;
  }

  .watch-video-card {
    border-radius: 17px;
  }

  .watch-player-dialog {
    width: calc(100vw - 10px);
    max-height: 96dvh;
    border-radius: 18px;
  }

  .watch-player-shell {
    max-height: 96dvh;
  }

  .watch-player-head {
    padding: 12px;
  }

  .watch-player-video-wrap {
    padding: 6px;
  }

  #watch-player {
    max-height: 54dvh;
    border-radius: 10px;
  }

  .watch-player-info {
    padding: 13px;
  }
}

.watch-secondary {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 38px;
  padding: 8px 11px;
  border: 1px solid rgba(126,178,255,.28);
  border-radius: 11px;
  background: rgba(55,67,104,.28);
  color: #dcecff;
  font-size: .76rem;
  font-weight: 800;
  text-decoration: none;
}


/* A_REGARDER_V2 — page indépendante + filtres Médiathèque */
.media-watch-page .media-collector-main {
  display:grid;
  gap:0;
}
.media-watch-page .media-watch-section {
  margin:0 auto;
}
.media-watch-page .watch-filter-toolbar {
  grid-template-columns:minmax(0,1fr) minmax(220px,.38fr);
}
.media-watch-page .library-sticky-controls .media-folder-navigation {
  display:grid;
}
.media-watch-page .library-sticky-controls.collapsed .library-sticky-body {
  pointer-events:none;
}
.media-watch-page .watch-status {
  min-height:24px;
  margin:8px 0 12px;
}
.watch-grid.layout-grid {
  display:grid;
  grid-template-columns:repeat(3,minmax(0,1fr));
  gap:16px;
}
.watch-grid.layout-list {
  display:grid;
  grid-template-columns:1fr;
  gap:12px;
}
.watch-grid.layout-list .watch-video-card {
  display:grid;
  grid-template-columns:minmax(220px,320px) minmax(0,1fr);
}
.watch-grid.layout-list .watch-video-preview {
  min-height:100%;
  aspect-ratio:auto;
}
.watch-grid.layout-horizontal {
  display:flex;
  gap:14px;
  overflow-x:auto;
  overflow-y:hidden;
  padding:2px 2px 12px;
  scroll-snap-type:x mandatory;
  scrollbar-width:thin;
}
.watch-grid.layout-horizontal .watch-video-card {
  flex:0 0 min(350px,86vw);
  scroll-snap-align:start;
}
.watch-grid.layout-horizontal .watch-loading {
  flex:1 0 100%;
}
@media (max-width:1000px) {
  .watch-grid.layout-grid {
    grid-template-columns:repeat(2,minmax(0,1fr));
  }
}
@media (max-width:780px) {
  .media-watch-page .watch-filter-toolbar {
    grid-template-columns:1fr;
  }
}
@media (max-width:700px) {
  .watch-grid.layout-grid {
    grid-template-columns:1fr;
    gap:12px;
  }
  .watch-grid.layout-list .watch-video-card {
    display:block;
  }
  .watch-grid.layout-list .watch-video-preview {
    aspect-ratio:16/10;
  }
}
