a,
button,
button:focus,
button:active,
button:hover {
  outline: none !important;
}

/* Video reel */
@media (max-width: 768px) {
  video {
    border-radius: 0 !important;
    padding: 0 !important;
  }

  .user-overlay {
    border-radius: 0 !important;
  }

  .container-arrows {
    display: none !important;
  }
}

/* Video grid */
.video-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(150px, 1fr));
  gap: 16px;
}

@media (min-width: 640px) {
  .video-grid {
    grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
  }
}

.video-reel {
  position: fixed;
  inset: 0;
  background-color: #000;
  z-index: 1049;
  display: none;
  align-items: center;
  justify-content: center;
}

.video-reel.active {
  display: flex;
}

.close-button {
  position: absolute;
  top: 16px;
  right: 16px;
  background-color: rgba(0, 0, 0, 0.5);
  color: white;
  border: none;
  border-radius: 50%;
  width: 40px;
  height: 40px;
  font-size: 20px;
  cursor: pointer;
  z-index: 10;
  display: flex;
  align-items: center;
  justify-content: center;
}

.video-container {
  height: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
  aspect-ratio: 9 / 16;
  overflow-x: hidden;
}

@media (min-width: 768px) {
  .video-container {
    height: 96vmin;
    min-height: 96vmin;
    width: calc(50vmin);
    min-width: calc(50vmin);
    z-index: 3;
    transition: 0.3s;
    position: relative;
    overflow-x: visible;
    max-width: 700px;
    margin: 0 auto;
    display: flex;
    align-items: center;
    justify-content: center;
  }
}

video#videoPlayer {
  width: 100%;
  height: 100%;
  object-fit: cover;
  border-radius: 16px;
}

.video-overlay {
  position: absolute;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  background-color: rgba(0, 0, 0, 0.1);
  opacity: 0;
  pointer-events: none;
  border-radius: 16px;
}

.video-overlay.visible {
  opacity: 1;
  pointer-events: auto;
}

.play-icon {
  color: white;
  opacity: 0.8;
}

/* Navigation buttons */
.container-arrows {
  position: absolute;
  top: 50%;
  right: 0;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 10px;
  padding: 0 1.25rem;
}
.nav-button {
  transform: translateY(-50%);
  background-color: rgb(139 139 139 / 50%);
  color: white;
  border: none;
  border-radius: 50%;
  width: 48px;
  height: 48px;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
}

.nav-button.disabled {
  opacity: 0;
  cursor: default;
}

/* User info */
.user-info {
  position: absolute;
  bottom: 80px;
  left: 16px;
  display: flex;
  align-items: center;
}

.user-avatar {
  width: 40px;
  height: 40px;
  border-radius: 50%;
  overflow: hidden;
  margin-right: 8px;
}

.user-avatar img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.user-info span {
  color: white;
  font-weight: 500;
}

/* Action buttons */
.action-buttons {
  position: absolute;
  bottom: 90px;
  right: 16px;
  display: flex;
  flex-direction: column;
  gap: 8px;
  align-items: center;
  color: #fff;
}

.action-button {
  background-color: rgba(0, 0, 0, 0.5);
  color: white;
  border: none;
  border-radius: 50%;
  width: 40px;
  height: 40px;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 18px;
}

/* Video controls */
.video-controls {
  position: absolute;
  bottom: 16px;
  left: 16px;
  right: 16px;
  display: flex;
  align-items: center;
  gap: 12px;
}

.control-button {
  background: none;
  border: none;
  color: white;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
}

.progress-container-reels {
  flex: 1;
  height: 4px;
  background-color: rgba(255, 255, 255, 0.3);
  border-radius: 2px;
  overflow: hidden;
  cursor: pointer;
}

.progress-bar-reels {
  height: 100%;
  background-color: white;
  width: 0;
}

.time-display {
  color: white;
  font-size: 14px;
  display: flex;
  gap: 4px;
}

.hidden {
  display: none;
}

/* Prevent scrolling when video reel is open */
body.no-scroll {
  overflow: hidden;
}

/* Loader styles */
#videoLoader, #videoLoaderPage {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  width: 48px;
  height: 48px;
  border: 5px solid rgba(255, 255, 255, 0.3);
  border-radius: 50%;
  border-top-color: #ffffff;
  animation: spin 1s ease-in-out infinite;
  z-index: 20;
  display: none;
}

#videoLoader.active,
#videoLoaderPage.active {
  display: block;
}
.loader-reels {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background-color: rgba(0, 0, 0, 0.5);
  z-index: 1040;
  color: #fff;
}
.loader-reels .loader-text {
  position: absolute;
  top: 55%;
  left: 50%;
  transform: translate(-50%, -50%);
  font-size: 1rem;
}

@keyframes spin {
  to {
    transform: translate(-50%, -50%) rotate(360deg);
  }
}

.user-overlay {
  position: absolute;
  background: linear-gradient(to top, rgba(0, 0, 0, 0.5), rgba(0, 0, 0, 0));
  display: block;
  width: 100%;
  bottom: 0;
  left: 0;
  min-height: 200px;
  border-bottom-right-radius: 16px;
  border-bottom-left-radius: 16px;
}

.user-link,
.user-avatar-link {
  cursor: pointer;
}

.user-link:hover {
  text-decoration: underline;
}

.text-reel {
  position: absolute;
  bottom: 35px;
  left: 16px;
  font-size: 14px;
  line-height: 13px;
  word-wrap: break-word !important;
  word-break: break-word !important;
  padding-right: 5px;
  color: #fff;
}

[data-bs-theme=dark] .comment-container {
  background-color: #303030;
}

.comment-container {
  position: absolute;
  width: 400px;
  right: 0;
  top: 0;
  height: 100%;
  background-color: #fff;
  visibility: hidden;
  opacity: 0;
  transform: translateX(0);
  transition: .3s linear;
  z-index: -1;
  overflow-y: hidden;
  border-radius: 6px;
  display: flex;
  flex-direction: column;
}

@media (max-width: 1199px) {
  .comment-container.show {
    visibility: visible;
    opacity: 1;
    transform: translateX(0%) !important;
    z-index: 999;
  }
}

@media (max-width: 1499px) {
  .comment-container {
    width: 100%;
    height: 70%;
    bottom: 0;
    top: auto;
  }
}

.comment-container.show {
  visibility: visible;
  opacity: 1;
  transform: translateX(102%);
}

.comment-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 15px;
  padding: 20px;
  padding-bottom: 0;
  flex-shrink: 0
}

.comment-content {
  overflow-y: scroll;
  overflow-x: hidden;
  flex: 1;
  padding: 0 30px;
  scrollbar-width: none;
  -ms-overflow-style: none;
}

.comment-close-icon {
  background: transparent;
  border: none;
  color: inherit;
}

.wrap-container-replies-reel {
  margin-left: calc(40px + 15px);
}

.preloader-reel {
  position: absolute;
  top: 50px;
  left: 0;
  width: 100%;
  height: 100%;
}

.type-reel {
  color: #fff;
  font-size: 12px;
  margin-top: 4px;
}

/* Video thumbnail */
.video-thumbnail {
  position: relative;
  border-radius: 8px;
  overflow: hidden;
  cursor: pointer;
  aspect-ratio: 9/16;
  background-color: #333;
}

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

.video-thumbnail:hover .thumbnail-overlay,
.thumbnail-overlay.show {
  opacity: 1 !important;
}

.thumbnail-overlay {
  position: absolute;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  background-color: rgba(0, 0, 0, 0.3);
  opacity: 0;
  transition: opacity 0.2s ease;
}

.thumbnail-play {
  background-color: rgba(0, 0, 0, 0.5);
  border-radius: 50%;
  padding: 12px;
  color: white;
}

.duration-badge {
  position: absolute;
  bottom: 8px;
  right: 8px;
  background-color: rgba(0, 0, 0, 0.7);
  color: white;
  font-size: 12px;
  padding: 2px 6px;
  border-radius: 4px;
}

.thumbnail-user {
  position: absolute;
  bottom: 8px;
  left: 8px;
  color: white;
  font-size: 14px;
  font-weight: 500;
  max-width: 70%;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  background-color: rgba(0, 0, 0, 0.5);
  padding: 2px 6px;
  border-radius: 4px;
}
.img-blurred {
  filter: blur(25px);
}
/* ===== Comments panel (2026-09-23): bottom sheet on phones, card on desktop.
   Overrides the .comment-container rules above; markup in reels/comments-reel. ===== */
.oa-rc { --rc-bg: #1c1c1f; --rc-fg: #f5f5f7; --rc-soft: #2a2a2f; --rc-line: rgba(255,255,255,.09); --rc-mute: #9a9aa3; --rc-red: #d10000;
  background: var(--rc-bg) !important; color: var(--rc-fg); border-radius: 18px 18px 0 0; overflow: hidden; box-shadow: 0 -10px 40px rgba(0,0,0,.45); }
.oa-rc-grab { width: 40px; height: 4px; border-radius: 4px; background: rgba(255,255,255,.22); margin: 8px auto 0; flex-shrink: 0; }
.oa-rc-head { margin: 0 !important; padding: 8px 12px 10px 16px !important; border-bottom: 1px solid var(--rc-line); }
.oa-rc-title { margin: 0; font-size: 17px; font-weight: 800; letter-spacing: .01em; display: flex; align-items: center; gap: 8px; }
.oa-rc-count { display: inline-block; min-width: 22px; padding: 2px 8px; border-radius: 999px; background: var(--rc-soft); color: var(--rc-mute); font-size: 12px; font-weight: 700; text-align: center; }
.oa-rc-count:empty { display: none; }
.oa-rc-close { width: 40px; height: 40px; border-radius: 50%; background: var(--rc-soft) !important; color: var(--rc-fg) !important; font-size: 16px; display: flex; align-items: center; justify-content: center; -webkit-tap-highlight-color: transparent; }
.oa-rc-close:hover { background: rgba(255,255,255,.14) !important; }
.oa-rc-wrap { min-height: 0; }
.oa-rc-list { padding: 4px 16px 12px !important; }
.oa-rc-list::-webkit-scrollbar { display: none; }
/* skeleton while loading */
.preloader-reel { top: 62px !important; padding: 14px 16px; background: var(--rc-bg); }
.oa-rc-skel { display: flex; gap: 12px; margin-bottom: 18px; }
.oa-rc-skel-av { width: 36px; height: 36px; border-radius: 50%; flex: none; }
.oa-rc-skel-lines { flex: 1; display: flex; flex-direction: column; gap: 8px; padding-top: 4px; }
.oa-rc-skel-lines i { display: block; height: 10px; border-radius: 5px; width: 40%; }
.oa-rc-skel-lines i + i { width: 80%; }
/* empty state */
.oa-rc-empty { display: flex; flex-direction: column; align-items: center; text-align: center; gap: 4px; padding: 48px 16px; color: var(--rc-mute); }
.oa-rc-empty i { font-size: 34px; color: rgba(255,255,255,.3); margin-bottom: 6px; }
.oa-rc-empty strong { color: var(--rc-fg); font-size: 16px; }
.oa-rc-empty span { font-size: 14px; }
/* a comment */
.oa-rc-row { display: flex; gap: 12px; padding: 12px 0 !important; margin: 0 !important; border: 0 !important; }
.oa-rc-row.oa-rc-reply { padding-left: 46px !important; }
.oa-rc-av { flex: none; }
.oa-rc-av img { width: 36px; height: 36px; border-radius: 50%; object-fit: cover; display: block; }
.oa-rc-reply .oa-rc-av img { width: 28px; height: 28px; }
.oa-rc-body { flex: 1; min-width: 0; }
.oa-rc-top { display: flex; align-items: center; gap: 6px; flex-wrap: wrap; min-height: 22px; }
.oa-rc-name { font-weight: 700; font-size: 14px; color: var(--rc-fg) !important; text-decoration: none; }
.oa-rc-verified { color: #2d8cff; font-size: 12px; }
.oa-rc-creator { font-size: 10px; font-weight: 800; letter-spacing: .06em; text-transform: uppercase; color: #fff; background: var(--rc-red); border-radius: 4px; padding: 1px 5px; }
.oa-rc-time { font-size: 12px; color: var(--rc-mute); }
.oa-rc-more { margin-left: auto; }
.oa-rc-more-btn { width: 32px; height: 28px; border: 0; background: transparent; color: var(--rc-mute); border-radius: 8px; cursor: pointer; }
.oa-rc-more-btn:hover { background: var(--rc-soft); color: var(--rc-fg); }
.oa-rc-text { margin: 3px 0 4px !important; font-size: 15px; line-height: 1.4; color: var(--rc-fg); }
.oa-rc-text a { color: #ff5a5a; }
.oa-rc-actions { display: flex; align-items: center; gap: 6px; }
.oa-rc-act { border: 0; background: transparent; color: var(--rc-mute); font-size: 13px; font-weight: 700; padding: 6px 8px; margin-left: -8px; border-radius: 8px; cursor: pointer; display: inline-flex; align-items: center; gap: 5px; min-height: 36px; -webkit-tap-highlight-color: transparent; }
.oa-rc-act:hover { color: var(--rc-fg); background: var(--rc-soft); }
.oa-rc-act.oa-rc-like { margin-left: 4px; float: none !important; }
.oa-rc-act.oa-rc-like .text-red { color: var(--rc-red) !important; }
.oa-rc-act.oa-rc-like .mr-1 { margin-right: 0 !important; }
.oa-rc-act .countCommentsLikes:empty { display: none; }
.wrap-container-replies-reel { margin-left: 48px !important; }
.showMoreRepliesReel { color: var(--rc-mute); font-size: 13px; font-weight: 700; text-decoration: none; }
.line-replies { display: inline-block; width: 24px; height: 1px; background: var(--rc-mute); vertical-align: middle; margin-right: 8px; }
/* replying-to strip */
.oa-rc-replying { background: var(--rc-soft) !important; color: var(--rc-mute); font-size: 13px; font-weight: 700; padding: 8px 16px !important; }
.oa-rc-replying .username-reply { color: var(--rc-fg); }
/* composer */
.oa-rc-foot { display: flex; align-items: center; gap: 10px; padding: 10px 12px calc(10px + env(safe-area-inset-bottom, 0px)) 16px !important; border-top: 1px solid var(--rc-line); background: var(--rc-bg); flex-shrink: 0; position: relative; }
.oa-rc-me { width: 34px; height: 34px; border-radius: 50%; object-fit: cover; flex: none; }
.oa-rc-form { display: flex; align-items: center; gap: 8px; flex: 1; min-width: 0; }
.oa-rc-box { flex: 1; min-width: 0; display: flex; align-items: center; background: var(--rc-soft); border: 1px solid transparent; border-radius: 999px; padding-right: 4px; transition: border-color .15s; }
.oa-rc-box:focus-within { border-color: var(--rc-red); }
.oa-rc-box .commentOnReel { flex: 1; min-width: 0; background: transparent !important; color: var(--rc-fg) !important; height: 44px; padding: 0 6px 0 16px; font-size: 16px; /* 16px: iOS won't zoom */ box-shadow: none !important; }
.oa-rc-box .commentOnReel::placeholder { color: var(--rc-mute); }
.oa-rc-emoji { width: 40px; height: 40px; border: 0; background: transparent; color: var(--rc-mute); font-size: 20px; border-radius: 50%; cursor: pointer; flex: none; -webkit-tap-highlight-color: transparent; }
.oa-rc-emoji:hover { color: var(--rc-fg); }
.oa-rc-send { width: 44px; height: 44px; border-radius: 50%; border: 0; background: var(--rc-red); color: #fff; font-size: 17px; flex: none; cursor: pointer; box-shadow: 0 3px 12px rgba(209,0,0,.4); transition: opacity .15s, transform .15s; -webkit-tap-highlight-color: transparent; }
.oa-rc-send:disabled { opacity: .35; box-shadow: none; cursor: default; }
.oa-rc-send:not(:disabled):active { transform: scale(.94); }
.oa-rc-foot .blocked { position: absolute; inset: 0; z-index: 2; }
@media (min-width: 1200px) {
  .oa-rc { border-radius: 16px; border: 1px solid var(--rc-line); box-shadow: 0 14px 50px rgba(0,0,0,.45); }
  .oa-rc-grab { display: none; }
  .oa-rc-head { padding-top: 14px !important; }
}
