/* =========================================================
   BRYFLIX HOMEPAGE THEME
   ========================================================= */

/* Overall page — true black with wide mockup red wash */
html,
body {
  min-height: 100%;
  background-color: #000000 !important;
  background-image: none !important;
}

/* Default layout scale — matches Chrome 125% zoom at 100% browser zoom */
html {
  zoom: 1.25;
}

/* Page scrollbar — match Recently Added / Recent Requests scroller style */
html,
body,
body.bryflix-page-requests,
body.bryflix-page-personal,
body.bryflix-page-discover {
  scrollbar-width: thin;
  scrollbar-color: rgba(229, 9, 20, 0.55) transparent;
}

html::-webkit-scrollbar,
body::-webkit-scrollbar {
  width: 6px;
  height: 6px;
}

html::-webkit-scrollbar-track,
body::-webkit-scrollbar-track {
  background: transparent;
}

html::-webkit-scrollbar-thumb,
body::-webkit-scrollbar-thumb {
  background: rgba(229, 9, 20, 0.5);
  border-radius: 999px;
}

html::-webkit-scrollbar-thumb:hover,
body::-webkit-scrollbar-thumb:hover {
  background: rgba(229, 9, 20, 0.75);
}

#__next,
#page_wrapper,
#inner_wrapper {
  background-color: transparent !important;
  background-image: none !important;
}

#page_wrapper {
  position: relative !important;
  background: #000000 !important;
}

/* Large transparent canvas; the visible red is a smaller soft oval inside it */
#page_wrapper::before {
  content: "";
  position: absolute;
  left: 50%;
  top: 3.5rem;
  width: min(90rem, 100%);
  height: 42rem;
  transform: translateX(-50%);
  background: radial-gradient(
    ellipse 72% 34% at 50% 36%,
    rgba(229, 9, 20, 0.55) 0%,
    rgba(229, 9, 20, 0.3) 28%,
    rgba(229, 9, 20, 0.12) 52%,
    transparent 70%
  );
  pointer-events: none;
  z-index: 0;
}

#inner_wrapper {
  position: relative !important;
  z-index: 1 !important;
}

.container {
  background: transparent !important;
}

body {
  color: #ffffff !important;
  font-family:
    "Segoe UI",
    system-ui,
    -apple-system,
    BlinkMacSystemFont,
    Roboto,
    "Helvetica Neue",
    Arial,
    sans-serif !important;
}


/* =========================================================
   BRYFLIX LOGO
   ========================================================= */

/* Target the actual uploaded logo directly */
img[src*="/images/bryflix-logo.png"] {
  display: block !important;
  width: min(700px, 78vw) !important;
  min-width: 280px !important;
  max-width: none !important;
  height: auto !important;
  max-height: none !important;
  object-fit: contain !important;
  margin: 0 auto !important;
  filter:
    drop-shadow(0 8px 18px rgba(229, 9, 20, 0.30))
    drop-shadow(0 20px 45px rgba(229, 9, 20, 0.18)) !important;
}

/* Remove size restrictions from the logo's immediate wrapper */
a:has(> img[src*="/images/bryflix-logo.png"]),
div:has(> img[src*="/images/bryflix-logo.png"]) {
  display: flex !important;
  justify-content: center !important;
  align-items: center !important;
  width: 100% !important;
  max-width: none !important;
  height: auto !important;
  max-height: none !important;
  overflow: visible !important;
  margin: 0 auto !important;
  padding: 0 !important;
}

/* Give the full logo-widget row proper hero spacing */
div:has(img[src*="/images/bryflix-logo.png"]) {
  max-height: none !important;
  overflow: visible !important;
}

div:has(> a > img[src*="/images/bryflix-logo.png"]),
div:has(> div > img[src*="/images/bryflix-logo.png"]) {
  width: 100% !important;
  max-width: none !important;
  padding: 28px 20px 42px !important;
  margin: 0 auto 10px !important;
  overflow: visible !important;
  background: transparent !important;
}


/* =========================================================
   FEATURED PUBLIC CARDS
   ========================================================= */

/* Outer shell — transparent so we don't get a double-card look */
#seerr-card,
#plex-card,
#audiobooks-card {
  min-height: 0 !important;
  padding: 0 !important;
  border: 0 !important;
  border-radius: 22px !important;
  background: transparent !important;
  box-shadow: none !important;
  overflow: visible !important;
  transition: transform 180ms ease !important;
}

#seerr-card:hover,
#plex-card:hover,
#audiobooks-card:hover {
  transform: translateY(-4px) !important;
  border-color: transparent !important;
  box-shadow: none !important;
}

/* Main service icons */
#seerr-card img,
#plex-card img,
#audiobooks-card img {
  width: 68px !important;
  height: 68px !important;
  min-width: 68px !important;
  object-fit: contain !important;
}

/* Main service titles */
#seerr-card h2,
#seerr-card h3,
#plex-card h2,
#plex-card h3,
#audiobooks-card h2,
#audiobooks-card h3 {
  font-size: 1.35rem !important;
  font-weight: 700 !important;
  color: #ffffff !important;
}

/* Main service descriptions */
#seerr-card p,
#plex-card p,
#audiobooks-card p {
  font-size: 0.98rem !important;
  color: rgba(255, 255, 255, 0.66) !important;
}


/* =========================================================
   SERVER TOOLS
   ========================================================= */

#radarr-card,
#sonarr-card,
#qbittorrent-card,
#prowlarr-card,
#tautulli-card {
  border-radius: 15px !important;
  border: 1px solid rgba(255, 255, 255, 0.065) !important;
  background:
    linear-gradient(
      145deg,
      rgba(22, 22, 22, 0.93),
      rgba(12, 12, 12, 0.93)
    ) !important;
  box-shadow:
    0 8px 20px rgba(0, 0, 0, 0.22),
    inset 0 1px 0 rgba(255, 255, 255, 0.025) !important;
  transition:
    transform 160ms ease,
    border-color 160ms ease,
    background 160ms ease !important;
}

#radarr-card:hover,
#sonarr-card:hover,
#qbittorrent-card:hover,
#prowlarr-card:hover,
#tautulli-card:hover {
  transform: translateY(-2px) !important;
  border-color: rgba(229, 9, 20, 0.28) !important;
  background:
    linear-gradient(
      145deg,
      rgba(28, 28, 28, 0.98),
      rgba(14, 14, 14, 0.98)
    ) !important;
}


/* =========================================================
   HEADINGS AND SPACING
   ========================================================= */

h1,
h2,
h3 {
  color: #ffffff !important;
}

h2 {
  font-weight: 700 !important;
  letter-spacing: 0.01em !important;
}

/* Server Tools heading */
h2:not(:empty) {
  text-shadow: 0 2px 12px rgba(0, 0, 0, 0.30);
}

/* Keep the dashboard centred and wide */
main {
  width: min(1450px, calc(100% - 40px)) !important;
  max-width: 1450px !important;
  margin-left: auto !important;
  margin-right: auto !important;
}


/* =========================================================
   MOBILE
   ========================================================= */

@media (max-width: 768px) {
  main {
    width: calc(100% - 22px) !important;
  }

  img[src*="/images/bryflix-logo.png"] {
    width: min(92vw, 520px) !important;
    min-width: 0 !important;
  }

  div:has(> a > img[src*="/images/bryflix-logo.png"]),
  div:has(> div > img[src*="/images/bryflix-logo.png"]) {
    padding: 20px 8px 28px !important;
  }

  #seerr-card,
  #plex-card,
  #audiobooks-card {
    min-height: 115px !important;
    padding: 17px !important;
  }

  #seerr-card img,
  #plex-card img,
  #audiobooks-card img {
    width: 54px !important;
    height: 54px !important;
    min-width: 54px !important;
  }
}
/* =========================================================
   HERO SPACING + TAGLINE
   ========================================================= */

/* Tighten the logo area */
div:has(> a > img[src*="/images/bryflix-logo.png"]),
div:has(> div > img[src*="/images/bryflix-logo.png"]) {
  padding: 45px 20px 24px !important;
  margin-bottom: 0 !important;
}

/* Logo wrap hosts the live systems status under the brand */
div:has(> a > img[src*="/images/bryflix-logo.png"]),
div:has(> div > img[src*="/images/bryflix-logo.png"]),
.bryflix-logo-wrap {
  position: relative !important;
  display: flex !important;
  flex-direction: column !important;
  align-items: center !important;
}

.bryflix-operational.bryflix-hero-status,
.bryflix-hero-status {
  display: inline-flex !important;
  align-items: center;
  justify-content: center;
  gap: 10px;
  width: auto !important;
  max-width: min(36rem, 92vw);
  margin: 10px auto 0 !important;
  margin-left: auto !important;
  margin-right: auto !important;
  padding: 0 12px;
  box-sizing: border-box;
  color: rgba(255, 255, 255, 0.72);
  font-size: 1.05rem;
  font-weight: 500;
  letter-spacing: 0.03em;
  text-align: center;
  white-space: nowrap;
}

.bryflix-hero-status [data-bryflix-status-text] {
  overflow: hidden;
  text-overflow: ellipsis;
}

.bryflix-hero-status .bryflix-status-dot {
  width: 10px;
  height: 10px;
}

.bryflix-hero-status.is-online {
  color: rgba(255, 255, 255, 0.72);
}

.bryflix-hero-status.is-degraded {
  color: #fbbf24;
}

.bryflix-hero-status.is-offline {
  color: #f87171;
}

.bryflix-hero-status.is-checking {
  color: rgba(255, 255, 255, 0.55);
}

/* Pull the featured cards upward */
#seerr-card,
#plex-card,
#audiobooks-card {
  min-height: 185px !important;
}

/* Make featured service text larger */
#seerr-card h3,
#plex-card h3,
#audiobooks-card h3 {
  font-size: 1.65rem !important;
}

#seerr-card p,
#plex-card p,
#audiobooks-card p {
  font-size: 1.05rem !important;
}

/* Make featured icons more prominent */
#seerr-card img,
#plex-card img,
#audiobooks-card img {
  width: 82px !important;
  height: 82px !important;
  min-width: 82px !important;
}
/* =========================================================
   RESPONSIVE LAYOUT FIXES
   ========================================================= */

/* Keep the logo area from clipping */
div:has(img[src*="/images/bryflix-logo.png"]) {
  height: auto !important;
  min-height: 0 !important;
  max-height: none !important;
  overflow: visible !important;
}

img[src*="/images/bryflix-logo.png"] {
  width: clamp(300px, 48vw, 700px) !important;
  height: auto !important;
}

/* Wide desktop: three main cards, five server tools */
@media (min-width: 1200px) {
  #seerr-card,
  #plex-card,
  #audiobooks-card {
    min-height: 185px !important;
  }
}

/* Laptop, split-screen and tablets */
@media (max-width: 1199px) {
  main {
    width: calc(100% - 32px) !important;
  }

  img[src*="/images/bryflix-logo.png"] {
    width: clamp(300px, 58vw, 560px) !important;
  }

  div:has(> a > img[src*="/images/bryflix-logo.png"]),
  div:has(> div > img[src*="/images/bryflix-logo.png"]) {
    padding: 26px 12px 34px !important;
  }

  #seerr-card,
  #plex-card,
  #audiobooks-card {
    min-height: 145px !important;
    padding: 18px !important;
  }

  #seerr-card img,
  #plex-card img,
  #audiobooks-card img {
    width: 64px !important;
    height: 64px !important;
    min-width: 64px !important;
  }

  #seerr-card h3,
  #plex-card h3,
  #audiobooks-card h3 {
    font-size: 1.3rem !important;
  }
}

/* Phones and narrow windows */
@media (max-width: 700px) {
  main {
    width: calc(100% - 20px) !important;
  }

  img[src*="/images/bryflix-logo.png"] {
    width: min(88vw, 440px) !important;
    min-width: 0 !important;
  }

  div:has(> a > img[src*="/images/bryflix-logo.png"]),
  div:has(> div > img[src*="/images/bryflix-logo.png"]) {
    padding: 20px 6px 38px !important;
  }

  div:has(> a > img[src*="/images/bryflix-logo.png"])::after,
  div:has(> div > img[src*="/images/bryflix-logo.png"])::after {
    font-size: 0.95rem !important;
    bottom: 10px !important;
  }

  #seerr-card,
  #plex-card,
  #audiobooks-card {
    min-height: 110px !important;
    padding: 15px !important;
    border-radius: 18px !important;
  }

  #seerr-card img,
  #plex-card img,
  #audiobooks-card img {
    width: 52px !important;
    height: 52px !important;
    min-width: 52px !important;
  }

  #seerr-card h3,
  #plex-card h3,
  #audiobooks-card h3 {
    font-size: 1.15rem !important;
  }

  #seerr-card p,
  #plex-card p,
  #audiobooks-card p {
    font-size: 0.9rem !important;
  }

  #radarr-card,
  #sonarr-card,
  #qbittorrent-card,
  #prowlarr-card,
  #tautulli-card {
    min-height: 68px !important;
  }
}
/* =========================================================
   SERVER TOOLS VIDEO PRANK
   ========================================================= */

/* Guest-only: prank intercept uses pointer cursor on server tool cards */
body.bryflix-guest-access #radarr-card,
body.bryflix-guest-access #sonarr-card,
body.bryflix-guest-access #qbittorrent-card,
body.bryflix-guest-access #prowlarr-card,
body.bryflix-guest-access #tautulli-card,
body.bryflix-guest-access #dsm-card {
  cursor: pointer !important;
}

#bryflix-prank-overlay {
  position: fixed;
  inset: 0;
  z-index: 999999;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 20px;
  background: rgba(0, 0, 0, 0.9);
  backdrop-filter: blur(10px);
  opacity: 0;
  visibility: hidden;
  transition:
    opacity 180ms ease,
    visibility 180ms ease;
}

#bryflix-prank-overlay.visible {
  opacity: 1;
  visibility: visible;
}

#bryflix-prank-box {
  position: relative;
  width: min(900px, 96vw);
  max-height: 90vh;
  overflow: hidden;
  border: 1px solid rgba(229, 9, 20, 0.5);
  border-radius: 22px;
  background: #000;
  box-shadow:
    0 30px 90px rgba(0, 0, 0, 0.7),
    0 0 45px rgba(229, 9, 20, 0.2);
}

#bryflix-prank-video {
  display: block;
  width: 100%;
  max-height: 90vh;
  object-fit: contain;
  background: #000;
}

#bryflix-prank-close {
  position: absolute;
  top: 10px;
  right: 14px;
  z-index: 2;
  width: 42px;
  height: 42px;
  border: 0;
  border-radius: 50%;
  background: rgba(0, 0, 0, 0.65);
  color: #fff;
  font-size: 2rem;
  line-height: 1;
  cursor: pointer;
}

:root {
  --bryflix-nav-height: 68px;
}

/* =========================================================
   BRYFLIX TOP NAVIGATION
   ========================================================= */

#bryflix-nav {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 100000;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
  width: 100%;
  min-height: var(--bryflix-nav-height);
  height: var(--bryflix-nav-height);
  padding: 0 28px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.08);
  background: rgba(0, 0, 0, 0.94);
  box-shadow: 0 6px 24px rgba(0, 0, 0, 0.28);
  backdrop-filter: blur(16px);
  box-sizing: border-box;
}

/* Content no longer needs body padding — scrollport starts under the nav */
body:has(#bryflix-nav) {
  padding-top: 0;
}

.bryflix-nav-left {
  display: flex;
  align-items: center;
  gap: 28px;
  min-width: 0;
  flex: 1 1 auto;
  overflow: hidden;
}

/* Let dropdowns escape the nav when open */
body.bryflix-discover-open #bryflix-nav,
body.bryflix-discover-open .bryflix-nav-left,
body.bryflix-discover-open .bryflix-nav-links,
body.bryflix-discover-open .bryflix-discover-wrap,
body.bryflix-admin-open #bryflix-nav,
body.bryflix-admin-open .bryflix-nav-left,
body.bryflix-admin-open .bryflix-nav-links,
body.bryflix-admin-open .bryflix-admin-wrap {
  overflow: visible !important;
}

.bryflix-nav-center {
  display: flex;
  flex: 1;
  justify-content: center;
  min-width: 0;
  max-width: 520px;
  margin-left: auto;
}

.bryflix-nav-actions {
  display: flex;
  align-items: center;
  gap: 6px;
  flex-shrink: 0;
  margin-left: 8px;
}

#bryflix-nav .bryflix-nav-logo {
  display: flex !important;
  align-items: center !important;
  justify-content: flex-start !important;
  width: auto !important;
  max-width: none !important;
  height: auto !important;
  max-height: none !important;
  margin: 0 !important;
  padding: 0 !important;
  overflow: visible !important;
  background: transparent !important;
  position: static !important;
  border: 0 !important;
  cursor: pointer !important;
  appearance: none;
}

#bryflix-nav .bryflix-nav-logo::after {
  content: none !important;
  display: none !important;
}

#bryflix-nav .bryflix-nav-logo img {
  display: block !important;
  width: 108px !important;
  min-width: 0 !important;
  max-width: 108px !important;
  height: auto !important;
  max-height: none !important;
  margin: 0 !important;
  padding: 0 !important;
  object-fit: contain !important;
  filter: drop-shadow(0 4px 12px rgba(229, 9, 20, 0.3)) !important;
}

.bryflix-nav-links {
  display: flex;
  align-items: center;
  gap: 4px;
  min-height: 68px;
}

.bryflix-nav-links a,
.bryflix-nav-links button,
.bryflix-nav-bell,
.bryflix-nav-user,
.bryflix-nav-search-toggle {
  position: relative;
  display: inline-flex;
  align-items: center;
  gap: 8px;
  min-height: 42px;
  padding: 0 14px;
  border: 0;
  border-radius: 8px;
  background: transparent;
  color: rgba(255, 255, 255, 0.68);
  font: inherit;
  font-size: 0.92rem;
  font-weight: 600;
  line-height: 1;
  text-decoration: none;
  white-space: nowrap;
  cursor: pointer;
  transition:
    color 160ms ease,
    background 160ms ease;
}

@media (hover: hover) and (pointer: fine) {
  .bryflix-nav-links a:hover,
  .bryflix-nav-links button:hover,
  .bryflix-nav-bell:hover,
  .bryflix-nav-user:hover {
    color: #ffffff;
    background: rgba(255, 255, 255, 0.055);
  }
}

.bryflix-admin-wrap {
  position: relative;
  display: inline-flex;
  align-items: center;
}

.bryflix-admin-wrap[hidden] {
  display: none !important;
}

.bryflix-admin-menu {
  position: absolute;
  top: calc(100% + 6px);
  left: 0;
  right: auto;
  width: max-content;
  min-width: 0;
  padding: 8px;
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 12px;
  background: rgba(12, 12, 12, 0.96);
  box-shadow: 0 16px 40px rgba(0, 0, 0, 0.45);
  backdrop-filter: blur(16px);
  z-index: 100002;
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
  transform: translateY(4px);
  transition:
    opacity 140ms ease,
    transform 140ms ease,
    visibility 140ms ease;
}

.bryflix-admin-wrap.is-open .bryflix-admin-menu,
.bryflix-admin-menu.is-open {
  opacity: 1;
  visibility: visible;
  pointer-events: auto;
  transform: translateY(0);
}

.bryflix-admin-menu a {
  display: block;
  width: 100%;
  padding: 10px 12px;
  border: 0;
  border-radius: 8px;
  background: transparent;
  color: rgba(255, 255, 255, 0.9);
  text-align: left;
  font: inherit;
  font-size: 0.9rem;
  text-decoration: none;
  box-sizing: border-box;
  cursor: pointer;
}

.bryflix-admin-menu a:hover {
  background: rgba(255, 255, 255, 0.08);
  color: #fff;
}

.bryflix-discover-wrap.is-open .bryflix-nav-discover,
.bryflix-admin-wrap.is-open #bryflix-admin-button {
  color: #ffffff;
  background: rgba(255, 255, 255, 0.055);
}

.bryflix-nav-links .active {
  color: #ffffff;
  background: rgba(229, 9, 20, 0.14);
}

.bryflix-nav-links .active::after {
  content: "";
  position: absolute;
  right: 10px;
  bottom: -13px;
  left: 10px;
  height: 2px;
  border-radius: 2px;
  background: #e50914;
  box-shadow: 0 0 12px rgba(229, 9, 20, 0.55);
}

.bryflix-nav-icon,
.bryflix-search-icon,
.bryflix-action-icon {
  flex-shrink: 0;
  width: 17px;
  height: 17px;
  opacity: 0.82;
}

.bryflix-nav-chevron {
  flex-shrink: 0;
  width: 14px;
  height: 14px;
  opacity: 0.72;
}

.bryflix-nav-search {
  display: flex;
  align-items: center;
  gap: 10px;
  width: 100%;
  min-height: 42px;
  padding: 0 14px;
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 10px;
  background: rgba(255, 255, 255, 0.045);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.03);
}

.bryflix-nav-search:focus,
.bryflix-nav-search:focus-within {
  outline: none;
  border-color: rgba(229, 9, 20, 0.35);
  background: rgba(255, 255, 255, 0.055);
}

.bryflix-nav-search input {
  width: 100%;
  min-width: 0;
  border: 0;
  background: transparent;
  color: #ffffff;
  font: inherit;
  font-size: 0.9rem;
  outline: none;
  box-shadow: none;
}

.bryflix-nav-search input:focus {
  outline: none;
  box-shadow: none;
}

.bryflix-nav-search input::placeholder {
  color: rgba(255, 255, 255, 0.42);
}

/* Hide standalone bell on all sizes — notifications live in account menu */
.bryflix-nav-bell {
  display: none !important;
}

.bryflix-nav-user {
  position: relative;
}

.bryflix-user-notif-dot {
  position: absolute;
  top: 6px;
  right: 4px;
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: #e50914;
  box-shadow: 0 0 0 2px rgba(0, 0, 0, 0.9);
  pointer-events: none;
}

.bryflix-nav-search-toggle {
  display: none;
  align-items: center;
  justify-content: center;
  border: 0;
  border-radius: 8px;
  background: transparent;
  color: rgba(255, 255, 255, 0.68);
  cursor: pointer;
}

.bryflix-bell-dot {
  position: absolute;
  top: 10px;
  right: 10px;
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: #e50914;
  box-shadow: 0 0 8px rgba(229, 9, 20, 0.75);
}

.bryflix-user-avatar {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 30px;
  height: 30px;
  border-radius: 8px;
  background: linear-gradient(145deg, #e50914, #b20710);
  color: #ffffff;
  font-size: 0.88rem;
  font-weight: 700;
  box-shadow: 0 4px 14px rgba(229, 9, 20, 0.35);
}

.bryflix-nav-user {
  gap: 6px;
  padding-right: 8px;
}

h1,
h2,
h3 {
  scroll-margin-top: 90px;
}

@media (max-width: 1100px) {
  #bryflix-nav {
    gap: 14px;
    padding: 0 18px;
  }

  .bryflix-nav-left {
    gap: 18px;
  }

  .bryflix-nav-center {
    max-width: 360px;
  }

  .bryflix-nav-links a span,
  .bryflix-nav-links button span {
    display: none;
  }

  .bryflix-nav-links a,
  .bryflix-nav-links button {
    padding: 0 11px;
  }
}

@media (max-width: 900px) {
  :root {
    --bryflix-nav-height: 58px;
  }

  #bryflix-nav {
    flex-wrap: nowrap;
    height: var(--bryflix-nav-height) !important;
    min-height: var(--bryflix-nav-height);
    padding: 0 14px;
  }

  .bryflix-nav-left,
  .bryflix-nav-actions {
    height: var(--bryflix-nav-height);
  }

  .bryflix-nav-search-toggle {
    display: inline-flex;
  }

  /* Bell moved into account menu */
  .bryflix-nav-bell {
    display: none !important;
  }

  /* Keep desktop-style center search off the single mobile row */
  .bryflix-nav-center {
    display: none;
    position: fixed;
    top: var(--bryflix-nav-height);
    left: 0;
    right: 0;
    z-index: 100001;
    max-width: none;
    margin: 0;
    padding: 10px 14px 12px;
    background: rgba(0, 0, 0, 0.96);
    border-bottom: 1px solid rgba(255, 255, 255, 0.08);
    box-shadow: 0 10px 24px rgba(0, 0, 0, 0.35);
  }

  body.bryflix-search-open .bryflix-nav-center {
    display: flex !important;
  }

  body.bryflix-search-open .bryflix-nav-search-toggle {
    color: #ffffff;
    background: rgba(255, 255, 255, 0.055);
  }

  .bryflix-nav-search {
    width: 100%;
    min-height: 40px;
  }

  .bryflix-nav-links {
    gap: 0;
    overflow: hidden; /* no horizontal drag/pan on mobile */
    flex-wrap: nowrap;
    min-width: 0;
  }

  .bryflix-nav-links::-webkit-scrollbar {
    display: none;
  }

  .bryflix-user-label,
  .bryflix-nav-user .bryflix-nav-chevron {
    display: none;
  }

  .bryflix-nav-user {
    padding: 0 6px !important;
  }

  body.bryflix-discover-open .bryflix-nav-links,
  body.bryflix-admin-open .bryflix-nav-links {
    touch-action: none;
  }

  body.bryflix-discover-open #bryflix-nav,
  body.bryflix-discover-open .bryflix-nav-left,
  body.bryflix-discover-open .bryflix-nav-links,
  body.bryflix-discover-open .bryflix-discover-wrap,
  body.bryflix-admin-open #bryflix-nav,
  body.bryflix-admin-open .bryflix-nav-left,
  body.bryflix-admin-open .bryflix-nav-links,
  body.bryflix-admin-open .bryflix-admin-wrap {
    overflow: visible !important;
  }
}

@media (max-width: 700px) {
  :root {
    --bryflix-nav-height: 58px;
  }

  #bryflix-nav {
    min-height: var(--bryflix-nav-height);
    height: var(--bryflix-nav-height) !important;
    padding: 0 10px;
  }

  .bryflix-nav-left,
  .bryflix-nav-actions {
    height: var(--bryflix-nav-height);
  }

  #bryflix-nav .bryflix-nav-logo img {
    width: 78px !important;
    max-width: 78px !important;
  }

  .bryflix-nav-left {
    gap: 10px;
  }

  .bryflix-nav-links {
    min-height: 58px;
  }

  .bryflix-nav-links a,
  .bryflix-nav-links button,
  .bryflix-nav-bell,
  .bryflix-nav-user,
  .bryflix-nav-search-toggle {
    min-height: 38px;
    padding: 0 8px;
  }

  .bryflix-nav-links .active::after {
    right: 6px;
    bottom: -10px;
    left: 6px;
  }

  .bryflix-user-avatar {
    width: 28px;
    height: 28px;
    font-size: 0.82rem;
  }

  .bryflix-nav-center {
    padding: 8px 10px 10px;
  }

  .bryflix-nav-search {
    min-height: 38px;
    padding: 0 12px;
  }

  .bryflix-nav-search input {
    font-size: 0.86rem;
  }
}

/* =========================================================
   DESKTOP FIT + PLEX ICON CORRECTION
   ========================================================= */

/* Keep the Plex icon in a circular badge like the mockup */
#plex-card .service-icon {
  border: 2px solid rgba(229, 160, 13, 0.9) !important;
  border-radius: 50% !important;
  background:
    radial-gradient(circle at 50% 45%, rgba(229, 160, 13, 0.26), rgba(0, 0, 0, 0.7) 70%) !important;
  box-shadow:
    0 0 0 1px rgba(229, 160, 13, 0.22),
    0 0 22px rgba(229, 160, 13, 0.4) !important;
}

#plex-card .service-icon img {
  width: 58px !important;
  height: 58px !important;
  min-width: 58px !important;
  max-width: 58px !important;
}

/* Make the whole dashboard fit naturally at 100% browser zoom */
@media (min-width: 1200px) {
  div:has(> a > img[src*="/images/bryflix-logo.png"]),
  div:has(> div > img[src*="/images/bryflix-logo.png"]) {
    padding-top: 18px !important;
    padding-bottom: 28px !important;
    margin-bottom: 0 !important;
  }

  img[src*="/images/bryflix-logo.png"] {
    width: clamp(360px, 36vw, 560px) !important;
  }

  .bryflix-public-card > .service-card {
    min-height: 165px !important;
    padding: 20px 22px !important;
  }

  .bryflix-public-card .service-icon {
    flex-basis: 82px !important;
    width: 82px !important;
    height: 82px !important;
  }

  .bryflix-public-card .service-icon img {
    width: 58px !important;
    height: 58px !important;
    min-width: 58px !important;
    max-width: 58px !important;
  }

  #plex-card .service-icon img {
    width: 54px !important;
    height: 54px !important;
    min-width: 54px !important;
    max-width: 54px !important;
  }

  .bryflix-public-card .service-name {
    font-size: 1.5rem !important;
  }

  .bryflix-public-card .service-description {
    margin-top: 6px !important;
    font-size: 0.94rem !important;
  }

  .bryflix-server-heading {
    min-height: 44px !important;
    margin-top: 8px !important;
    margin-bottom: 12px !important;
    padding-bottom: 8px !important;
  }

  .bryflix-server-card > .service-card {
    min-height: 128px !important;
    padding: 16px 16px 13px !important;
  }

  .bryflix-server-card .service-title {
    min-height: 62px !important;
  }

  .bryflix-server-card .service-icon {
    flex-basis: 50px !important;
    width: 50px !important;
    height: 50px !important;
  }

  .bryflix-server-card .service-icon img {
    width: 44px !important;
    height: 44px !important;
    min-width: 44px !important;
    max-width: 44px !important;
  }

  .bryflix-card-status {
    right: 16px !important;
    bottom: 10px !important;
    left: 16px !important;
    padding-top: 8px !important;
  }
}

/* =========================================================
   CARD ENHANCEMENTS (JS-INJECTED ELEMENTS)
   ========================================================= */

.bryflix-public-card > .service-card {
  position: relative;
  display: flex !important;
  align-items: center !important;
  gap: 18px !important;
}

.bryflix-public-card .service-title-text {
  display: inline-flex !important;
  align-items: center;
  gap: 8px;
}

.bryflix-card-arrow {
  margin-left: auto;
  padding-left: 12px;
  color: rgba(255, 255, 255, 0.34);
  font-size: 1.55rem;
  font-weight: 400;
  line-height: 1;
}

.bryflix-server-heading {
  display: flex !important;
  align-items: center !important;
  width: 100% !important;
  gap: 10px !important;
  border: 0 !important;
  background: transparent !important;
  padding-left: 0 !important;
  padding-right: 0 !important;
}

.bryflix-heading-icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 28px;
  height: 28px;
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.06);
  color: rgba(255, 255, 255, 0.82);
  font-size: 0.95rem;
}

.bryflix-server-heading .service-group-name {
  margin-right: auto !important;
  font-size: 1.05rem !important;
  font-weight: 700 !important;
}

.bryflix-operational {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  margin-left: auto !important;
  margin-right: 0 !important;
  color: rgba(255, 255, 255, 0.58);
  font-size: 0.88rem;
  font-weight: 500;
  white-space: nowrap;
}

/* Hero status must stay centered under the logo (overrides Server Tools margin-left:auto) */
.bryflix-operational.bryflix-hero-status {
  margin-left: auto !important;
  margin-right: auto !important;
  width: auto !important;
}

/* Collapse chevron steals right alignment with the Tautulli card */
.bryflix-server-heading > svg {
  display: none !important;
}

.bryflix-card-status {
  display: flex;
  align-items: center;
  gap: 7px;
  margin-top: auto;
  padding-top: 10px;
  font-size: 0.82rem;
  font-weight: 600;
}

.bryflix-card-status.is-online {
  color: #34d399;
}

.bryflix-card-status.is-offline {
  color: #f87171;
}

.bryflix-card-status.is-checking {
  color: rgba(255, 255, 255, 0.48);
}

.bryflix-status-dot {
  flex-shrink: 0;
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.35);
}

.bryflix-status-dot.is-online {
  background: #34d399;
  box-shadow: 0 0 10px rgba(52, 211, 153, 0.65);
}

.bryflix-status-dot.is-offline {
  background: #f87171;
  box-shadow: 0 0 10px rgba(248, 113, 113, 0.55);
}

.bryflix-status-dot.is-degraded {
  background: #fbbf24;
  box-shadow: 0 0 10px rgba(251, 191, 36, 0.55);
}

.bryflix-status-dot.is-checking {
  background: rgba(255, 255, 255, 0.35);
  animation: bryflix-status-pulse 1.4s ease-in-out infinite;
}

.bryflix-operational.is-online {
  color: rgba(255, 255, 255, 0.58);
}

.bryflix-operational.is-degraded {
  color: #fbbf24;
}

.bryflix-operational.is-offline {
  color: #f87171;
}

.bryflix-operational.is-checking {
  color: rgba(255, 255, 255, 0.48);
}

@keyframes bryflix-status-pulse {
  0%,
  100% {
    opacity: 0.45;
  }

  50% {
    opacity: 1;
  }
}

/* Hide the System Health group — monitors only, no UI cards */
.bryflix-health-group-hidden,
.services-group.bryflix-health-group-hidden {
  display: none !important;
}

/* Hide Homepage's native monitor badge; Bryflix renders its own */
.bryflix-server-card .site-monitor-status,
.bryflix-server-card .ping-status,
.bryflix-public-card .site-monitor-status,
.bryflix-public-card .ping-status {
  display: none !important;
}

.bryflix-server-card > .service-card {
  display: flex !important;
  flex-direction: column !important;
  height: 100% !important;
}

.bryflix-server-card .service-description {
  text-transform: none !important;
}

/* Hide Homepage footer (refresh + version) — no need to scroll for it */
#footer {
  display: none !important;
}

/* Desktop/home: scroll lives in #__next BELOW the fixed nav (not under it) */
@media (min-width: 901px) {
  html {
    height: 100% !important;
    overflow: hidden !important;
  }

  body {
    height: 100% !important;
    overflow: hidden !important;
  }

  body:has(#bryflix-nav) #__next {
    position: fixed !important;
    top: var(--bryflix-nav-height) !important;
    left: 0 !important;
    right: 0 !important;
    bottom: 0 !important;
    height: auto !important;
    max-height: none !important;
    overflow-x: hidden !important;
    overflow-y: auto !important;
  }

  body:has(#bryflix-nav) #page_wrapper,
  body:has(#bryflix-nav) #inner_wrapper {
    height: auto !important;
    max-height: none !important;
    overflow: visible !important;
  }
}

/* Mobile: same idea — scrollbar starts under the nav */
@media (max-width: 900px) {
  html {
    height: 100% !important;
    overflow: hidden !important;
  }

  body:has(#bryflix-nav) {
    height: 100% !important;
    overflow: hidden !important;
  }

  body:has(#bryflix-nav) #__next {
    position: fixed !important;
    top: var(--bryflix-nav-height) !important;
    left: 0 !important;
    right: 0 !important;
    bottom: 0 !important;
    height: auto !important;
    max-height: none !important;
    overflow-x: hidden !important;
    overflow-y: auto !important;
  }
}

/* =========================================================
   MOCKUP SPACING + CARD STYLE
   ========================================================= */

#information-widgets {
  margin: 0 !important;
  padding: 0 20px !important;
  border-bottom: 0 !important;
}

#information-widgets div:has(> a > img[src*="/images/bryflix-logo.png"]),
#information-widgets div:has(> div > img[src*="/images/bryflix-logo.png"]) {
  display: flex !important;
  flex-direction: column !important;
  align-items: center !important;
  justify-content: center !important;
  padding: 36px 16px 6px !important;
  margin: 0 auto !important;
  background: transparent !important;
  gap: 0 !important;
}

#information-widgets img[src*="/images/bryflix-logo.png"] {
  width: clamp(420px, 52vw, 760px) !important;
  min-width: 0 !important;
  max-width: 760px !important;
  margin: 0 auto !important;
}

#information-widgets div:has(> a > img[src*="/images/bryflix-logo.png"])::after,
#information-widgets div:has(> div > img[src*="/images/bryflix-logo.png"])::after {
  position: static !important;
  left: auto !important;
  bottom: auto !important;
  transform: none !important;
  display: block !important;
  width: 100% !important;
  margin-top: 2px !important;
  font-size: 1.15rem !important;
  color: rgba(255, 255, 255, 0.62) !important;
  text-align: center !important;
}

.container {
  max-width: 1420px !important;
  padding-left: 28px !important;
  padding-right: 28px !important;
}

main {
  width: min(1420px, calc(100% - 40px)) !important;
  max-width: 1420px !important;
}

.container > div:has(#seerr-card) {
  margin-top: 0 !important;
  padding-top: 14px !important;
  overflow: visible !important;
}

/* Let hover lift escape Homepage's overflow clipping */
.container > div:has(#seerr-card),
.container > div:has(#seerr-card) > *,
.container > div:has(#seerr-card) ul,
.container > div:has(#seerr-card) .grid,
div:has(> #seerr-card),
ul:has(> #seerr-card),
.overflow-hidden:has(#seerr-card),
.overflow-hidden:has(#plex-card),
.overflow-hidden:has(#audiobooks-card) {
  overflow: visible !important;
}

.container .grid,
.container ul[class*="grid"] {
  gap: 16px !important;
}

/* Featured cards — mockup scale */
#seerr-card,
#plex-card,
#audiobooks-card {
  min-height: 0 !important;
  padding: 0 !important;
  border: 0 !important;
  background: transparent !important;
  box-shadow: none !important;
  border-radius: 22px !important;
  overflow: visible !important;
}

/* One visual surface only — the inner service-card */
.bryflix-public-card > .service-card {
  min-height: 156px !important;
  padding: 22px 24px !important;
  gap: 18px !important;
  border-radius: 22px !important;
  background:
    linear-gradient(
      155deg,
      rgba(28, 28, 28, 0.96),
      rgba(12, 12, 12, 0.98)
    ) !important;
  box-shadow:
    0 14px 34px rgba(0, 0, 0, 0.45) !important;
  transition:
    box-shadow 180ms ease,
    border-color 180ms ease !important;
}

#seerr-card > .service-card {
  border: 1px solid rgba(168, 85, 247, 0.35) !important;
  border-bottom: 3px solid #a855f7 !important;
  box-shadow:
    0 14px 34px rgba(0, 0, 0, 0.45),
    0 0 32px rgba(168, 85, 247, 0.12) !important;
}

#plex-card > .service-card {
  border: 1px solid rgba(229, 160, 13, 0.35) !important;
  border-bottom: 3px solid #e5a00d !important;
  box-shadow:
    0 14px 34px rgba(0, 0, 0, 0.45),
    0 0 32px rgba(229, 160, 13, 0.12) !important;
}

#audiobooks-card > .service-card {
  border: 1px solid rgba(45, 212, 191, 0.35) !important;
  border-bottom: 3px solid #2dd4bf !important;
  box-shadow:
    0 14px 34px rgba(0, 0, 0, 0.45),
    0 0 32px rgba(45, 212, 191, 0.12) !important;
}

#seerr-card:hover > .service-card {
  box-shadow:
    0 18px 40px rgba(0, 0, 0, 0.5),
    0 0 36px rgba(168, 85, 247, 0.18) !important;
}

#plex-card:hover > .service-card {
  box-shadow:
    0 18px 40px rgba(0, 0, 0, 0.5),
    0 0 36px rgba(229, 160, 13, 0.18) !important;
}

#audiobooks-card:hover > .service-card {
  box-shadow:
    0 18px 40px rgba(0, 0, 0, 0.5),
    0 0 36px rgba(45, 212, 191, 0.18) !important;
}

/* Circular icon badges — match mockup rings, not square tiles */
.bryflix-public-card .service-icon,
#seerr-card .service-icon,
#plex-card .service-icon,
#audiobooks-card .service-icon {
  display: flex !important;
  align-items: center !important;
  justify-content: center !important;
  flex-shrink: 0 !important;
  width: 76px !important;
  height: 76px !important;
  min-width: 76px !important;
  min-height: 76px !important;
  flex-basis: 76px !important;
  margin: 0 !important;
  padding: 0 !important;
  overflow: visible !important;
  border-radius: 9999px !important;
  border-style: solid !important;
  border-width: 2.5px !important;
  background-clip: padding-box !important;
}

#seerr-card .service-icon {
  border-color: #a855f7 !important;
  background:
    radial-gradient(circle at 50% 42%, rgba(168, 85, 247, 0.35), rgba(8, 8, 8, 0.92) 68%) !important;
  box-shadow:
    0 0 0 3px rgba(168, 85, 247, 0.15),
    0 0 28px rgba(168, 85, 247, 0.55),
    inset 0 0 18px rgba(168, 85, 247, 0.18) !important;
}

#plex-card .service-icon {
  border-color: #e5a00d !important;
  background:
    radial-gradient(circle at 50% 42%, rgba(229, 160, 13, 0.32), rgba(8, 8, 8, 0.92) 68%) !important;
  box-shadow:
    0 0 0 3px rgba(229, 160, 13, 0.15),
    0 0 28px rgba(229, 160, 13, 0.5),
    inset 0 0 18px rgba(229, 160, 13, 0.16) !important;
}

#audiobooks-card .service-icon {
  border-color: #2dd4bf !important;
  background:
    radial-gradient(circle at 50% 42%, rgba(45, 212, 191, 0.32), rgba(8, 8, 8, 0.92) 68%) !important;
  box-shadow:
    0 0 0 3px rgba(45, 212, 191, 0.15),
    0 0 28px rgba(45, 212, 191, 0.5),
    inset 0 0 18px rgba(45, 212, 191, 0.16) !important;
}

.bryflix-public-card .service-icon img,
#seerr-card .service-icon img,
#plex-card .service-icon img,
#audiobooks-card .service-icon img {
  width: 40px !important;
  height: 40px !important;
  min-width: 40px !important;
  max-width: 40px !important;
  border-radius: 0 !important;
  object-fit: contain !important;
}

/* Featured cards — stronger mockup chrome */
#seerr-card,
#plex-card,
#audiobooks-card {
  min-height: 0 !important;
  padding: 0 !important;
  border: 0 !important;
  background: transparent !important;
  box-shadow: none !important;
  border-radius: 22px !important;
  overflow: visible !important;
}

.bryflix-public-card > .service-card {
  min-height: 156px !important;
  padding: 22px 24px !important;
  gap: 18px !important;
  border-radius: 22px !important;
}

.bryflix-public-card .service-name,
#seerr-card h3,
#plex-card h3,
#audiobooks-card h3 {
  font-size: 1.58rem !important;
  line-height: 1.15 !important;
}

.bryflix-public-card .service-description,
#seerr-card p,
#plex-card p,
#audiobooks-card p {
  margin-top: 6px !important;
  font-size: 1rem !important;
  color: rgba(255, 255, 255, 0.58) !important;
}

.bryflix-card-arrow {
  font-size: 1.75rem !important;
  color: rgba(255, 255, 255, 0.28) !important;
}

/* Server Tools — mockup scale */
.bryflix-server-heading {
  margin-top: 0 !important;
  margin-bottom: 12px !important;
  padding-bottom: 10px !important;
  border-bottom: 1px solid rgba(255, 255, 255, 0.06) !important;
}

.bryflix-server-heading .service-group-name {
  font-size: 1.12rem !important;
}

.bryflix-server-heading .bryflix-operational {
  font-size: 0.94rem !important;
}

.bryflix-server-card > .service-card {
  min-height: 124px !important;
  padding: 16px 16px 14px !important;
  border-radius: 16px !important;
  background:
    linear-gradient(
      145deg,
      rgba(22, 22, 22, 0.96),
      rgba(12, 12, 12, 0.96)
    ) !important;
}

.bryflix-server-card .service-title {
  min-height: 0 !important;
}

.bryflix-server-card .service-name,
.bryflix-server-card .service-title-text {
  font-size: 1.05rem !important;
}

.bryflix-server-card .service-description {
  margin-top: 4px !important;
  font-size: 0.86rem !important;
  color: rgba(255, 255, 255, 0.5) !important;
}

.bryflix-server-card .service-icon {
  display: flex !important;
  align-items: center !important;
  justify-content: center !important;
  width: 48px !important;
  height: 48px !important;
  flex-basis: 48px !important;
  border-radius: 50% !important;
  overflow: hidden !important;
  border: 1px solid rgba(255, 255, 255, 0.08) !important;
  background: rgba(255, 255, 255, 0.04) !important;
}

.bryflix-server-card .service-icon img {
  width: 42px !important;
  height: 42px !important;
  min-width: 42px !important;
  max-width: 42px !important;
  border-radius: 50% !important;
  object-fit: cover !important;
}

.bryflix-card-status {
  margin-top: auto !important;
  padding-top: 10px !important;
  border-top: 1px solid rgba(255, 255, 255, 0.06) !important;
  font-size: 0.86rem !important;
}

@media (min-width: 1200px) {
  #information-widgets div:has(> a > img[src*="/images/bryflix-logo.png"]),
  #information-widgets div:has(> div > img[src*="/images/bryflix-logo.png"]) {
    padding-top: 40px !important;
    padding-bottom: 4px !important;
  }

  #information-widgets img[src*="/images/bryflix-logo.png"] {
    width: clamp(480px, 48vw, 780px) !important;
    max-width: 780px !important;
  }

  .bryflix-public-card > .service-card {
    min-height: 152px !important;
    padding: 20px 24px !important;
  }

  .bryflix-server-card > .service-card {
    min-height: 128px !important;
  }

  .bryflix-server-card .service-title {
    min-height: 0 !important;
  }
}

/* =========================================================
   MOBILE / NARROW — undo desktop scale + fix packing
   ========================================================= */

@media (max-width: 900px) {
  html {
    zoom: 1;
  }

  #page_wrapper::before {
    top: 2.5rem;
    width: min(90rem, 100%);
    height: 30rem;
    background: radial-gradient(
      ellipse 85% 32% at 50% 22%,
      rgba(229, 9, 20, 0.5) 0%,
      rgba(229, 9, 20, 0.26) 28%,
      rgba(229, 9, 20, 0.09) 52%,
      transparent 70%
    );
  }

  #information-widgets {
    padding: 0 12px !important;
  }

  #information-widgets div:has(> a > img[src*="/images/bryflix-logo.png"]),
  #information-widgets div:has(> div > img[src*="/images/bryflix-logo.png"]) {
    padding: 24px 8px 4px !important;
  }

  #information-widgets img[src*="/images/bryflix-logo.png"] {
    width: min(86vw, 420px) !important;
    max-width: 420px !important;
  }

  #information-widgets div:has(> a > img[src*="/images/bryflix-logo.png"])::after,
  #information-widgets div:has(> div > img[src*="/images/bryflix-logo.png"])::after {
    margin-top: 4px !important;
    font-size: 0.95rem !important;
  }

  .container {
    padding-left: 14px !important;
    padding-right: 14px !important;
  }

  .bryflix-public-card > .service-card {
    min-height: 0 !important;
    padding: 16px 16px !important;
    gap: 14px !important;
  }

  .bryflix-public-card .service-icon,
  #seerr-card .service-icon,
  #plex-card .service-icon,
  #audiobooks-card .service-icon {
    width: 58px !important;
    height: 58px !important;
    min-width: 58px !important;
    min-height: 58px !important;
    flex-basis: 58px !important;
  }

  .bryflix-public-card .service-icon img,
  #seerr-card .service-icon img,
  #plex-card .service-icon img,
  #audiobooks-card .service-icon img {
    width: 32px !important;
    height: 32px !important;
    min-width: 32px !important;
    max-width: 32px !important;
  }

  .bryflix-public-card .service-name,
  #seerr-card h3,
  #plex-card h3,
  #audiobooks-card h3 {
    font-size: 1.2rem !important;
  }

  .bryflix-public-card .service-description,
  #seerr-card p,
  #plex-card p,
  #audiobooks-card p {
    margin-top: 3px !important;
    font-size: 0.86rem !important;
    line-height: 1.25 !important;
  }

  .bryflix-card-arrow {
    font-size: 1.35rem !important;
  }

  .bryflix-server-heading {
    flex-wrap: wrap !important;
    align-items: center !important;
    gap: 8px !important;
    margin-bottom: 12px !important;
    padding-bottom: 10px !important;
  }

  .bryflix-server-heading .service-group-name {
    white-space: nowrap !important;
    font-size: 1rem !important;
    margin-right: 0 !important;
  }

  .bryflix-server-heading .bryflix-operational {
    flex: 1 1 100% !important;
    justify-content: flex-start !important;
    margin-left: 36px !important;
    font-size: 0.8rem !important;
    white-space: nowrap !important;
  }

  .bryflix-server-heading > svg:last-child {
    display: none !important;
  }

  .bryflix-server-card > .service-card {
    min-height: 0 !important;
    padding: 14px 14px 12px !important;
  }

  .bryflix-server-card .service-name,
  .bryflix-server-card .service-title-text {
    font-size: 0.98rem !important;
  }

  .bryflix-server-card .service-description {
    font-size: 0.8rem !important;
  }
}

@media (max-width: 700px) {
  #bryflix-nav .bryflix-nav-links a span,
  #bryflix-nav .bryflix-nav-links button span {
    display: none;
  }

  .bryflix-server-heading .bryflix-operational {
    margin-left: 0 !important;
  }

  .bryflix-operational.bryflix-hero-status {
    margin-left: auto !important;
    margin-right: auto !important;
  }
}

/* =========================================================
   SEERR POSTER ROWS
   ========================================================= */

.bryflix-seerr-rows {
  flex: 0 0 100%;
  width: 100%;
  max-width: 100%;
  min-width: 0;
  box-sizing: border-box;
  margin: 4px 0 20px;
  padding: 0 8px;
  display: flex;
  flex-direction: column;
  gap: 22px;
}

/* Keep the 3 featured cards in a normal-width row */
#layout-groups,
#layout-groups .services-group,
#layout-groups .services-group > div {
  max-width: 100% !important;
  min-width: 0 !important;
}

#layout-groups ul.services-list:has(#seerr-card) {
  width: 100% !important;
  max-width: 100% !important;
  min-width: 0 !important;
  grid-template-columns: repeat(3, minmax(0, 1fr)) !important;
}

#seerr-card,
#plex-card,
#audiobooks-card {
  min-width: 0 !important;
  max-width: 100% !important;
}

.bryflix-poster-row-header {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 12px;
  padding: 0 2px;
}

.bryflix-poster-row-title {
  color: rgba(255, 255, 255, 0.92);
  font-size: 1.05rem;
  font-weight: 650;
  letter-spacing: 0.01em;
  text-decoration: none;
}

.bryflix-poster-row-title:hover {
  color: #ffffff;
}

.bryflix-poster-row-more {
  color: rgba(255, 255, 255, 0.45);
  font-size: 1.45rem;
  line-height: 1;
  text-decoration: none;
  padding: 0 4px;
}

.bryflix-poster-row-more:hover {
  color: rgba(255, 255, 255, 0.85);
}

.bryflix-poster-scroller {
  display: flex;
  gap: 12px;
  overflow-x: auto;
  overflow-y: hidden;
  padding: 4px 2px 10px;
  scroll-snap-type: x proximity;
  scrollbar-width: thin;
  scrollbar-color: rgba(229, 9, 20, 0.55) transparent;
  -webkit-overflow-scrolling: touch;
}

.bryflix-poster-scroller::-webkit-scrollbar {
  height: 6px;
}

.bryflix-poster-scroller::-webkit-scrollbar-thumb {
  background: rgba(229, 9, 20, 0.5);
  border-radius: 999px;
}

.bryflix-poster-scroller:focus {
  outline: none;
}

.bryflix-poster-card {
  flex: 0 0 auto;
  width: 128px;
  color: inherit;
  text-decoration: none;
  scroll-snap-align: start;
  transition: transform 160ms ease;
}

.bryflix-poster-card:hover {
  transform: translateY(-4px);
}

.bryflix-poster-art {
  position: relative;
  width: 128px;
  aspect-ratio: 2 / 3;
  border-radius: 10px;
  overflow: hidden;
  background: rgba(255, 255, 255, 0.04);
  box-shadow: 0 10px 24px rgba(0, 0, 0, 0.45);
}

.bryflix-poster-art img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

.bryflix-poster-fallback {
  display: grid;
  place-items: center;
  width: 100%;
  height: 100%;
  color: rgba(255, 255, 255, 0.45);
  font-size: 0.78rem;
  letter-spacing: 0.04em;
  text-transform: uppercase;
}

.bryflix-poster-type {
  position: absolute;
  top: 8px;
  left: 8px;
  padding: 3px 7px;
  border-radius: 999px;
  background: rgba(0, 0, 0, 0.72);
  color: rgba(255, 255, 255, 0.9);
  font-size: 0.62rem;
  font-weight: 700;
  letter-spacing: 0.04em;
  text-transform: uppercase;
}

.bryflix-poster-status {
  position: absolute;
  top: 8px;
  right: 8px;
  width: 18px;
  height: 18px;
  border-radius: 50%;
  background: rgba(16, 185, 129, 0.95);
  box-shadow: 0 0 0 2px rgba(0, 0, 0, 0.35);
}

.bryflix-poster-status::after {
  content: "";
  position: absolute;
  left: 5px;
  top: 3px;
  width: 5px;
  height: 9px;
  border: solid #04140f;
  border-width: 0 2px 2px 0;
  transform: rotate(45deg);
}

.bryflix-poster-availability {
  position: absolute;
  left: 8px;
  right: 8px;
  bottom: 8px;
  padding: 5px 7px;
  border-radius: 8px;
  background: rgba(0, 0, 0, 0.78);
  color: rgba(255, 255, 255, 0.95);
  font-size: 0.68rem;
  font-weight: 650;
  line-height: 1.2;
  text-align: center;
  letter-spacing: 0.01em;
  backdrop-filter: blur(6px);
}

.bryflix-poster-meta {
  margin-top: 8px;
  min-width: 0;
}

.bryflix-poster-title {
  color: rgba(255, 255, 255, 0.9);
  font-size: 0.82rem;
  font-weight: 600;
  line-height: 1.25;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.bryflix-poster-sub {
  margin-top: 3px;
  color: rgba(255, 255, 255, 0.45);
  font-size: 0.72rem;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

/* Home Continue Watching / Watch Next — personal cards in poster-row scrollers */
.bryflix-personal-home-rows .bryflix-home-shelf-card {
  flex: 0 0 auto;
  width: 128px;
  scroll-snap-align: start;
  transition: transform 160ms ease;
}

.bryflix-personal-home-rows .bryflix-home-shelf-card:hover {
  transform: translateY(-4px);
}

.bryflix-personal-home-rows .bryflix-personal-poster {
  width: 128px;
  border-radius: 10px;
}

.bryflix-personal-home-rows .bryflix-personal-card-title {
  font-size: 0.82rem;
}

.bryflix-personal-home-rows .bryflix-personal-card-sub {
  font-size: 0.72rem;
  -webkit-line-clamp: 1;
  white-space: nowrap;
  display: block;
}

@media (max-width: 900px) {
  .bryflix-seerr-rows {
    gap: 18px;
    padding: 0 4px;
  }

  #layout-groups ul.services-list:has(#seerr-card) {
    grid-template-columns: 1fr !important;
  }

  .bryflix-poster-card,
  .bryflix-poster-art,
  .bryflix-personal-home-rows .bryflix-home-shelf-card,
  .bryflix-personal-home-rows .bryflix-personal-poster {
    width: 112px;
  }
}

/* =========================================================
   REQUESTS PAGE
   ========================================================= */

body.bryflix-page-requests #page_wrapper,
body.bryflix-page-requests #bryflix-seerr-rows,
body.bryflix-page-requests #bryflix-personal-home-rows,
body.bryflix-page-personal #page_wrapper,
body.bryflix-page-personal #bryflix-seerr-rows,
body.bryflix-page-personal #bryflix-personal-home-rows,
body.bryflix-page-discover #page_wrapper,
body.bryflix-page-discover #bryflix-seerr-rows,
body.bryflix-page-discover #bryflix-personal-home-rows {
  display: none !important;
}

/* SPA pages also scroll under the nav, not behind it */
html:has(body.bryflix-page-requests),
html:has(body.bryflix-page-personal),
html:has(body.bryflix-page-discover) {
  height: 100% !important;
  overflow: hidden !important;
}

body.bryflix-page-requests,
body.bryflix-page-personal,
body.bryflix-page-discover {
  height: 100% !important;
  overflow: hidden !important;
}

body.bryflix-page-requests #__next,
body.bryflix-page-personal #__next,
body.bryflix-page-discover #__next {
  display: none !important;
}

.bryflix-requests-page,
.bryflix-personal-page,
.bryflix-discover-page {
  position: fixed !important;
  top: var(--bryflix-nav-height) !important;
  left: 0 !important;
  right: 0 !important;
  bottom: 0 !important;
  z-index: 2;
  /* Beat the global `main { max-width: 1420px }` so the scrollbar sits on the viewport edge */
  width: 100% !important;
  max-width: none !important;
  margin: 0 !important;
  /* No horizontal padding here — it insets the scrollbar on desktop */
  padding: 24px 0 64px !important;
  overflow-x: hidden !important;
  overflow-y: auto !important;
  box-sizing: border-box !important;
}

.bryflix-requests-page > *,
.bryflix-personal-page > *,
.bryflix-discover-page > * {
  width: min(1100px, calc(100% - 40px));
  margin-left: auto;
  margin-right: auto;
}

.bryflix-personal-page > * {
  width: min(1180px, calc(100% - 40px));
}

.bryflix-requests-header {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 16px;
  margin-bottom: 22px;
}

.bryflix-requests-header h1 {
  margin: 0;
  color: #fff;
  font-size: clamp(1.8rem, 3vw, 2.4rem);
  font-weight: 750;
  letter-spacing: 0.01em;
}

.bryflix-requests-lead {
  margin: 6px 0 0;
  color: rgba(255, 255, 255, 0.55);
  font-size: 0.95rem;
}

.bryflix-requests-seerr {
  color: rgba(255, 255, 255, 0.7);
  text-decoration: none;
  font-size: 0.9rem;
  white-space: nowrap;
}

.bryflix-requests-seerr:hover {
  color: #fff;
}

.bryflix-requests-tabs {
  display: inline-flex;
  gap: 6px;
  margin: 0 0 16px;
  padding: 4px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid rgba(255, 255, 255, 0.06);
}

.bryflix-requests-tabs button {
  border: 0;
  background: transparent;
  color: rgba(255, 255, 255, 0.55);
  font: inherit;
  font-size: 0.88rem;
  font-weight: 650;
  padding: 0.45rem 0.95rem;
  border-radius: 999px;
  cursor: pointer;
  transition: background 0.15s ease, color 0.15s ease;
}

.bryflix-requests-tabs button:hover {
  color: rgba(255, 255, 255, 0.9);
}

.bryflix-requests-tabs button.is-active {
  background: #e50914;
  color: #fff;
}

.bryflix-requests-toolbar {
  display: flex;
  align-items: center;
  gap: 14px;
  margin-bottom: 18px;
}

.bryflix-requests-toolbar input {
  flex: 1;
  min-width: 0;
  min-height: 44px;
  padding: 0 14px;
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 10px;
  background: rgba(255, 255, 255, 0.045);
  color: #fff;
  font: inherit;
  font-size: 0.92rem;
  outline: none;
}

.bryflix-requests-toolbar input:focus {
  border-color: rgba(229, 9, 20, 0.4);
}

.bryflix-requests-count {
  color: rgba(255, 255, 255, 0.45);
  font-size: 0.85rem;
  white-space: nowrap;
}

.bryflix-requests-list {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.bryflix-requests-item {
  display: flex;
  gap: 14px;
  padding: 10px;
  border: 1px solid rgba(255, 255, 255, 0.06);
  border-radius: 14px;
  background: rgba(255, 255, 255, 0.03);
  color: inherit;
  text-decoration: none;
  transition: background 160ms ease, border-color 160ms ease, transform 160ms ease;
}

.bryflix-requests-item:hover {
  background: rgba(255, 255, 255, 0.055);
  border-color: rgba(255, 255, 255, 0.12);
  transform: translateY(-1px);
}

.bryflix-requests-poster {
  position: relative;
  flex: 0 0 64px;
  width: 64px;
  aspect-ratio: 2 / 3;
  border-radius: 8px;
  overflow: hidden;
  background: rgba(255, 255, 255, 0.04);
}

.bryflix-requests-poster img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

.bryflix-requests-body {
  min-width: 0;
  flex: 1;
  display: flex;
  flex-direction: column;
  justify-content: center;
  gap: 6px;
}

.bryflix-requests-title-row {
  display: flex;
  align-items: baseline;
  gap: 10px;
  min-width: 0;
}

.bryflix-requests-title {
  margin: 0;
  color: #fff;
  font-size: 1.05rem;
  font-weight: 650;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.bryflix-requests-type {
  flex-shrink: 0;
  color: rgba(255, 255, 255, 0.4);
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 0.04em;
  text-transform: uppercase;
}

.bryflix-requests-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 8px 12px;
  color: rgba(255, 255, 255, 0.48);
  font-size: 0.82rem;
}

.bryflix-requests-availability {
  display: inline-flex;
  align-self: flex-start;
  padding: 4px 8px;
  border-radius: 999px;
  background: rgba(229, 9, 20, 0.16);
  color: rgba(255, 255, 255, 0.9);
  font-size: 0.75rem;
  font-weight: 650;
}

.bryflix-requests-empty {
  padding: 40px 12px;
  color: rgba(255, 255, 255, 0.45);
  text-align: center;
}

@media (max-width: 700px) {
  .bryflix-requests-header {
    flex-direction: column;
    align-items: flex-start;
  }

  .bryflix-requests-toolbar {
    flex-direction: column;
    align-items: stretch;
  }
}

/* =========================================================
   AUTH MENU + PERSONAL PAGES
   ========================================================= */

.bryflix-user-wrap {
  position: relative;
}

.bryflix-discover-wrap {
  position: relative;
  display: inline-flex;
  align-items: center;
}

.bryflix-discover-menu {
  position: absolute;
  top: calc(100% + 6px);
  left: 0;
  right: auto;
  min-width: 240px;
  padding: 8px;
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 12px;
  background: rgba(12, 12, 12, 0.96);
  box-shadow: 0 16px 40px rgba(0, 0, 0, 0.45);
  backdrop-filter: blur(16px);
  z-index: 100002;
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
  transform: translateY(4px);
  transition:
    opacity 140ms ease,
    transform 140ms ease,
    visibility 140ms ease;
}

.bryflix-discover-wrap.is-open .bryflix-discover-menu,
.bryflix-discover-menu.is-open {
  opacity: 1;
  visibility: visible;
  pointer-events: auto;
  transform: translateY(0);
}

.bryflix-discover-menu button {
  display: block;
  width: 100%;
  padding: 10px 12px;
  border: 0;
  border-radius: 8px;
  background: transparent;
  color: rgba(255, 255, 255, 0.9);
  text-align: left;
  font: inherit;
  font-size: 0.9rem;
  cursor: pointer;
}

.bryflix-discover-menu button:hover {
  background: rgba(255, 255, 255, 0.08);
}

.bryflix-discover-page {
  color: #fff;
}

.bryflix-discover-header h1 {
  margin: 0 0 8px;
  font-size: clamp(1.8rem, 3vw, 2.4rem);
}

.bryflix-discover-lead {
  margin: 0 0 28px;
  color: rgba(255, 255, 255, 0.55);
}

.bryflix-discover-gate {
  display: grid;
  gap: 16px;
  justify-items: start;
  padding: 28px 24px;
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 16px;
  background: rgba(255, 255, 255, 0.03);
}

.bryflix-discover-gate p {
  margin: 0;
  color: rgba(255, 255, 255, 0.7);
}

.bryflix-discover-section {
  margin-bottom: 36px;
}

.bryflix-discover-section-head {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 14px;
}

.bryflix-discover-section-head h2 {
  margin: 0;
  font-size: 1.25rem;
}

.bryflix-discover-see-all {
  border: 0;
  background: transparent;
  color: rgba(255, 255, 255, 0.55);
  font: inherit;
  font-size: 0.9rem;
  cursor: pointer;
}

.bryflix-discover-see-all:hover {
  color: #fff;
}

.bryflix-discover-row {
  display: grid;
  grid-auto-flow: column;
  grid-auto-columns: minmax(140px, 160px);
  gap: 14px;
  overflow-x: auto;
  padding-bottom: 8px;
  scrollbar-width: thin;
  scrollbar-color: rgba(229, 9, 20, 0.55) transparent;
}

.bryflix-discover-row::-webkit-scrollbar {
  height: 6px;
}

.bryflix-discover-row::-webkit-scrollbar-thumb {
  background: rgba(229, 9, 20, 0.5);
  border-radius: 999px;
}

.bryflix-discover-empty {
  color: rgba(255, 255, 255, 0.45);
  font-size: 0.92rem;
  padding: 8px 0;
}

.bryflix-user-label {
  max-width: 110px;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  font-size: 0.86rem;
  font-weight: 600;
}

.bryflix-user-menu {
  position: absolute;
  top: calc(100% + 8px);
  right: 0;
  min-width: 230px;
  padding: 8px;
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 12px;
  background: rgba(12, 12, 12, 0.96);
  box-shadow: 0 16px 40px rgba(0, 0, 0, 0.45);
  backdrop-filter: blur(16px);
  z-index: 100001;
}

.bryflix-user-menu button {
  display: block;
  width: 100%;
  padding: 10px 12px;
  border: 0;
  border-radius: 8px;
  background: transparent;
  color: rgba(255, 255, 255, 0.9);
  text-align: left;
  font: inherit;
  font-size: 0.9rem;
  cursor: pointer;
}

.bryflix-user-menu button:hover {
  background: rgba(255, 255, 255, 0.08);
}

.bryflix-notifications-panel {
  position: fixed;
  inset: 0;
  z-index: 200000;
  display: grid;
  place-items: start end;
  padding: calc(var(--bryflix-nav-height) + 10px) 14px 14px;
  background: rgba(0, 0, 0, 0.45);
}

.bryflix-notifications-panel[hidden] {
  display: none !important;
}

.bryflix-notifications-inner {
  width: min(360px, calc(100vw - 28px));
  padding: 16px;
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 14px;
  background: rgba(12, 12, 12, 0.98);
  box-shadow: 0 18px 40px rgba(0, 0, 0, 0.5);
}

.bryflix-notifications-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 10px;
}

.bryflix-notifications-head h2 {
  margin: 0;
  color: #fff;
  font-size: 1.05rem;
}

.bryflix-notifications-head-actions {
  display: flex;
  align-items: center;
  gap: 6px;
}

.bryflix-notifications-clear {
  border: 0;
  background: transparent;
  color: rgba(255, 255, 255, 0.5);
  font: inherit;
  font-size: 0.78rem;
  font-weight: 600;
  cursor: pointer;
  padding: 4px 6px;
  border-radius: 6px;
}

.bryflix-notifications-clear:hover {
  color: rgba(255, 255, 255, 0.9);
  background: rgba(255, 255, 255, 0.06);
}

.bryflix-notifications-close {
  border: 0;
  background: transparent;
  color: rgba(255, 255, 255, 0.55);
  font-size: 1.4rem;
  cursor: pointer;
  line-height: 1;
}

.bryflix-notifications-empty {
  margin: 0;
  color: rgba(255, 255, 255, 0.55);
  font-size: 0.92rem;
  line-height: 1.45;
}

.bryflix-notifications-list {
  display: flex;
  flex-direction: column;
  gap: 8px;
  max-height: min(60vh, 420px);
  overflow-y: auto;
  margin: 0 0 12px;
  padding-right: 2px;
  scrollbar-width: thin;
  scrollbar-color: rgba(229, 9, 20, 0.55) transparent;
}

.bryflix-notifications-item {
  display: flex;
  gap: 6px;
  align-items: stretch;
  padding: 0;
  border-radius: 10px;
  color: inherit;
  background: rgba(255, 255, 255, 0.03);
  transition: background 140ms ease;
}

.bryflix-notifications-item:hover {
  background: rgba(255, 255, 255, 0.07);
}

.bryflix-notifications-item-link {
  display: flex;
  gap: 10px;
  align-items: center;
  flex: 1 1 auto;
  min-width: 0;
  padding: 8px 4px 8px 8px;
  text-decoration: none;
  color: inherit;
}

.bryflix-notifications-dismiss {
  flex: 0 0 auto;
  align-self: stretch;
  border: 0;
  background: transparent;
  color: rgba(255, 255, 255, 0.35);
  font-size: 1.15rem;
  line-height: 1;
  cursor: pointer;
  padding: 0 10px;
  border-radius: 0 10px 10px 0;
}

.bryflix-notifications-dismiss:hover {
  color: rgba(255, 255, 255, 0.9);
  background: rgba(255, 255, 255, 0.06);
}

.bryflix-notifications-poster {
  flex: 0 0 auto;
  width: 42px;
  aspect-ratio: 2 / 3;
  border-radius: 6px;
  overflow: hidden;
  background: rgba(255, 255, 255, 0.06);
}

.bryflix-notifications-poster img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

.bryflix-notifications-poster .bryflix-poster-fallback {
  font-size: 0.55rem;
}

.bryflix-notifications-body {
  min-width: 0;
  flex: 1 1 auto;
}

.bryflix-notifications-label {
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 0.03em;
  text-transform: uppercase;
  color: rgba(255, 255, 255, 0.55);
}

.bryflix-notifications-item.is-ready .bryflix-notifications-label {
  color: #34d399;
}

.bryflix-notifications-item.is-downloading .bryflix-notifications-label {
  color: #fbbf24;
}

.bryflix-notifications-item.is-failed .bryflix-notifications-label {
  color: #f87171;
}

.bryflix-notifications-item.is-pending .bryflix-notifications-label {
  color: #60a5fa;
}

.bryflix-notifications-title {
  margin-top: 2px;
  color: rgba(255, 255, 255, 0.92);
  font-size: 0.9rem;
  font-weight: 650;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.bryflix-notifications-detail {
  margin-top: 3px;
  display: flex;
  justify-content: space-between;
  gap: 8px;
  color: rgba(255, 255, 255, 0.45);
  font-size: 0.75rem;
}

.bryflix-notifications-detail span {
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.bryflix-notifications-all {
  width: 100%;
  border: 0;
  border-radius: 8px;
  padding: 10px 12px;
  background: rgba(255, 255, 255, 0.06);
  color: rgba(255, 255, 255, 0.85);
  font: inherit;
  font-size: 0.88rem;
  font-weight: 600;
  cursor: pointer;
}

.bryflix-notifications-all:hover {
  background: rgba(255, 255, 255, 0.1);
  color: #fff;
}

#bryflix-login-modal {
  position: fixed;
  inset: 0;
  z-index: 200000;
  display: grid;
  place-items: center;
}

#bryflix-login-modal[hidden] {
  display: none !important;
}

.bryflix-login-backdrop {
  position: absolute;
  inset: 0;
  background: rgba(0, 0, 0, 0.72);
}

.bryflix-login-card {
  position: relative;
  z-index: 1;
  width: min(420px, calc(100% - 32px));
  padding: 28px 24px 24px;
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 18px;
  background: linear-gradient(180deg, rgba(28, 28, 28, 0.98), rgba(10, 10, 10, 0.98));
  box-shadow: 0 24px 60px rgba(0, 0, 0, 0.55);
}

.bryflix-login-card h2 {
  margin: 0 0 8px;
  color: #fff;
  font-size: 1.4rem;
}

.bryflix-login-copy {
  margin: 0 0 18px;
  color: rgba(255, 255, 255, 0.6);
  font-size: 0.92rem;
  line-height: 1.45;
}

.bryflix-login-start {
  width: 100%;
  min-height: 46px;
  border: 0;
  border-radius: 10px;
  background: linear-gradient(145deg, #e50914, #b20710);
  color: #fff;
  font: inherit;
  font-size: 0.95rem;
  font-weight: 700;
  cursor: pointer;
}

.bryflix-login-start:disabled {
  opacity: 0.65;
  cursor: wait;
}

.bryflix-login-status {
  margin: 14px 0 0;
  color: rgba(255, 255, 255, 0.55);
  font-size: 0.85rem;
}

.bryflix-login-close {
  position: absolute;
  top: 10px;
  right: 12px;
  border: 0;
  background: transparent;
  color: rgba(255, 255, 255, 0.55);
  font-size: 1.4rem;
  cursor: pointer;
}

.bryflix-personal-page {
  color: #fff;
}

.bryflix-personal-header {
  display: block;
}

.bryflix-personal-header h1 {
  margin: 0;
  color: #fff;
  font-size: clamp(1.8rem, 3vw, 2.4rem);
  font-weight: 750;
}

.bryflix-personal-lead {
  margin: 6px 0 0;
  color: rgba(255, 255, 255, 0.55);
}

.bryflix-surprise-me {
  display: inline-flex;
  align-items: center;
  margin-top: 14px;
  border: 1px solid #e50914;
  background: #e50914;
  color: #fff;
  border-radius: 999px;
  padding: 0.55rem 1.1rem;
  font-size: 0.9rem;
  font-weight: 650;
  cursor: pointer;
  transition: background 0.15s ease, border-color 0.15s ease, transform 0.15s ease, filter 0.15s ease;
}

.bryflix-surprise-me:hover {
  background: #f6121d;
  border-color: #f6121d;
  filter: brightness(1.05);
}

.bryflix-surprise-me:active {
  transform: scale(0.98);
}

.bryflix-surprise-me:disabled,
.bryflix-surprise-me.is-loading {
  opacity: 0.7;
  cursor: wait;
}

.bryflix-surprise-wrap {
  margin-top: 4px;
}

.bryflix-surprise-filters {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-top: 12px;
}

.bryflix-surprise-field {
  display: flex;
  flex-direction: column;
  gap: 4px;
  min-width: 140px;
}

.bryflix-surprise-field span {
  color: rgba(255, 255, 255, 0.42);
  font-size: 0.72rem;
  font-weight: 600;
  letter-spacing: 0.04em;
  text-transform: uppercase;
}

.bryflix-surprise-field select {
  appearance: none;
  border: 1px solid rgba(255, 255, 255, 0.16);
  background: rgba(255, 255, 255, 0.06)
    url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='8' viewBox='0 0 12 8'%3E%3Cpath fill='%23ffffff99' d='M1 1l5 5 5-5'/%3E%3C/svg%3E")
    no-repeat right 10px center;
  color: #fff;
  border-radius: 10px;
  padding: 0.55rem 2rem 0.55rem 0.75rem;
  font-size: 0.88rem;
  font-weight: 550;
  cursor: pointer;
}

.bryflix-surprise-field select:hover,
.bryflix-surprise-field select:focus {
  border-color: rgba(229, 9, 20, 0.55);
  outline: none;
}

.bryflix-surprise-field select option {
  color: #111;
}

.bryflix-personal-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(150px, 1fr));
  gap: 16px;
  margin-top: 22px;
}

.bryflix-watch-next-sections {
  display: flex;
  flex-direction: column;
  gap: 28px;
  margin-top: 22px;
}

.bryflix-watch-next-section-head h2 {
  margin: 0 0 4px;
  color: rgba(255, 255, 255, 0.92);
  font-size: 1.15rem;
  font-weight: 700;
}

.bryflix-watch-next-blurb {
  margin: 0 0 12px;
  color: rgba(255, 255, 255, 0.45);
  font-size: 0.88rem;
}

.bryflix-personal-badge {
  position: absolute;
  left: 8px;
  top: 8px;
  padding: 3px 7px;
  border-radius: 6px;
  background: rgba(229, 9, 20, 0.92);
  color: #fff;
  font-size: 0.65rem;
  font-weight: 700;
  letter-spacing: 0.02em;
  text-transform: uppercase;
}

.bryflix-personal-card {
  color: inherit;
  text-decoration: none;
}

.bryflix-personal-poster {
  position: relative;
  aspect-ratio: 2 / 3;
  border-radius: 12px;
  overflow: hidden;
  background: rgba(255, 255, 255, 0.04);
  box-shadow: 0 10px 24px rgba(0, 0, 0, 0.4);
}

.bryflix-personal-poster img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

.bryflix-personal-progress {
  position: absolute;
  left: 0;
  right: 0;
  bottom: 0;
  height: 4px;
  background: rgba(255, 255, 255, 0.18);
}

.bryflix-personal-progress span {
  display: block;
  height: 100%;
  background: #e50914;
}

.bryflix-personal-meta {
  margin-top: 8px;
}

.bryflix-personal-card-title {
  color: rgba(255, 255, 255, 0.92);
  font-size: 0.9rem;
  font-weight: 650;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.bryflix-personal-card-sub {
  margin-top: 3px;
  color: rgba(255, 255, 255, 0.45);
  font-size: 0.75rem;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.bryflix-personal-empty,
.bryflix-personal-loading {
  margin-top: 28px;
  color: rgba(255, 255, 255, 0.5);
  text-align: center;
}

@media (max-width: 700px) {
  .bryflix-personal-grid {
    grid-template-columns: repeat(auto-fill, minmax(120px, 1fr));
    gap: 12px;
  }
}

/* =========================================================
   GLOBAL SCROLLBAR THEME (force red like poster rows)
   Viewport scrollbars often stay OS-blue; we scroll on body instead.
   ========================================================= */

html,
body,
#__next,
.bryflix-requests-page,
.bryflix-personal-page,
.bryflix-discover-page {
  scrollbar-width: thin !important;
  scrollbar-color: rgba(229, 9, 20, 0.55) transparent !important;
}

html::-webkit-scrollbar,
body::-webkit-scrollbar,
#__next::-webkit-scrollbar,
#page_wrapper::-webkit-scrollbar,
#inner_wrapper::-webkit-scrollbar,
.bryflix-requests-page::-webkit-scrollbar,
.bryflix-personal-page::-webkit-scrollbar,
.bryflix-discover-page::-webkit-scrollbar {
  width: 6px !important;
  height: 6px !important;
}

html::-webkit-scrollbar-track,
body::-webkit-scrollbar-track,
#__next::-webkit-scrollbar-track,
#page_wrapper::-webkit-scrollbar-track,
#inner_wrapper::-webkit-scrollbar-track,
.bryflix-requests-page::-webkit-scrollbar-track,
.bryflix-personal-page::-webkit-scrollbar-track,
.bryflix-discover-page::-webkit-scrollbar-track {
  background: transparent !important;
}

html::-webkit-scrollbar-thumb,
body::-webkit-scrollbar-thumb,
#__next::-webkit-scrollbar-thumb,
#page_wrapper::-webkit-scrollbar-thumb,
#inner_wrapper::-webkit-scrollbar-thumb,
.bryflix-requests-page::-webkit-scrollbar-thumb,
.bryflix-personal-page::-webkit-scrollbar-thumb,
.bryflix-discover-page::-webkit-scrollbar-thumb {
  background: rgba(229, 9, 20, 0.55) !important;
  border-radius: 999px !important;
  border: none !important;
  box-shadow: none !important;
}

html::-webkit-scrollbar-thumb:hover,
body::-webkit-scrollbar-thumb:hover,
#__next::-webkit-scrollbar-thumb:hover,
#page_wrapper::-webkit-scrollbar-thumb:hover,
#inner_wrapper::-webkit-scrollbar-thumb:hover,
.bryflix-requests-page::-webkit-scrollbar-thumb:hover,
.bryflix-personal-page::-webkit-scrollbar-thumb:hover,
.bryflix-discover-page::-webkit-scrollbar-thumb:hover {
  background: rgba(229, 9, 20, 0.8) !important;
}

html::-webkit-scrollbar-corner,
body::-webkit-scrollbar-corner {
  background: transparent !important;
}
