/*
 * hub-extras.css — HUB diaspora.ro
 * Cod integrat & curat — zero !important in cod.
 * Sectiuni:
 *   1. Performanta video & media  (sursa: hub-extras)
 *   2. Functionalitati UI          (sursa: hub-extras)
 *   3. Ajustari desktop            (sursa: hub-extras)
 *   4. Cards 3D & layout text      (sursa: hub-extras)
 */


/* ── 1. Performanta video & media ──────────────────── */

/* ── GPU ACCELERATION pentru toate elementele media ─────────── */
.hub-video-wrap video,
.post-media video,
.story-video video,
video[data-hub] {
  will-change: transform;
  transform: translateZ(0);
  backface-visibility: hidden;
  -webkit-backface-visibility: hidden;

  /* Rendering de calitate maximă */
  image-rendering: auto;
  -webkit-optimize-contrast: auto;

  /* Prevenim flash-ul alb la tranziție */
  background: #000;

  /* Aspect ratio conservat */
  object-fit: contain;
  max-width: 100%;
  display: block;
}

/* ── VIDEO CONTAINER — aspect ratio box ─────────────────────── */
.hub-video-container {
  position: relative;
  width: 100%;
  background: #000;
  border-radius: 12px;
  overflow: hidden;
}

/* Aspect ratio 9:16 pentru video-uri verticale (telefon) */
.hub-video-container.portrait {
  aspect-ratio: 9 / 16;
}
/* Aspect ratio 16:9 pentru landscape */
.hub-video-container.landscape {
  aspect-ratio: 16 / 9;
}
/* Fallback pentru browsere vechi */
@supports not (aspect-ratio: 1) {
  .hub-video-container.landscape::before { content:''; display:block; padding-top: 56.25%; }
  .hub-video-container.portrait::before  { content:''; display:block; padding-top: 177.77%; }
  .hub-video-container video { position:absolute;top:0;left:0;width:100%;height:100%; }
}

/* ── VIDEO LOADING STATE — spinner centrat ──────────────────── */
.hub-video-container::after {
  content: '';
  position: absolute;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  background: rgba(0,0,0,0.3);
  opacity: 0;
  transition: opacity 0.2s ease;
  pointer-events: none;
}

/* ── LQIP — Low Quality Image Placeholder ───────────────────── */
img[data-lqip],
img[data-src] {
  /* blur aplicat inline via JS, dar fallback CSS */
  transition: filter 600ms ease, transform 600ms ease, opacity 200ms ease;
  transform-origin: center;
}

/* Când imaginea e complet încărcată */
img[data-lqip].hub-loaded,
img[data-src].hub-loaded {
  filter: none;
  transform: scale(1) translateZ(0);
}

/* ── IMAGE — quality rendering ──────────────────────────────── */
.post-media img,
.hub-img,
.story-thumb img,
.user-avatar,
.comment-avatar {
  image-rendering: -webkit-optimize-contrast;
  image-rendering: crisp-edges; /* PNG cu transparență */
  image-rendering: auto;        /* Suprascriem cu browser default (smoothing) */

  /* GPU layer */
  transform: translateZ(0);
  will-change: transform;
}

/* ── SMOOTH TAB / VIEW TRANSITIONS ─────────────────────────── */
.tab-content,
.view-panel,
[data-view] {
  transition: opacity 200ms ease;
}

/* ── FEED POST — skeleton loading ──────────────────────────── */
.post-card {
  transition: opacity 300ms ease, transform 200ms ease;
}

.post-card.loading {
  pointer-events: none;
}

/* Skeleton shimmer pe imagine */
.img-skeleton,
.video-skeleton {
  background: linear-gradient(90deg,
    var(--card, #f5f5f5) 25%,
    rgba(255,255,255,0.5) 50%,
    var(--card, #f5f5f5) 75%
  );
  background-size: 200% 100%;
  animation: hub-shimmer 1.5s infinite;
  border-radius: 8px;
}

@keyframes hub-shimmer {
  0%   { background-position: 200% center; }
  100% { background-position: -200% center; }
}

/* ── VIDEO CONTROLS — mai vizibile pe mobile ────────────────── */
video::-webkit-media-controls {
  opacity: 0.9;
}

video::-webkit-media-controls-panel {
  background: linear-gradient(transparent, rgba(0,0,0,0.6));
}

/* ── PLAY BUTTON OVERLAY (custom) ─────────────────────────── */
.hub-play-overlay {
  position: absolute;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  background: transparent;
  transition: background 150ms ease;
  z-index: 2;
}

.hub-play-overlay:hover {
  background: rgba(0,0,0,0.1);
}

.hub-play-overlay svg {
  width: 56px;
  height: 56px;
  fill: rgba(255,255,255,0.92);
  filter: drop-shadow(0 2px 8px rgba(0,0,0,0.6));
  transition: transform 150ms ease, opacity 150ms ease;
}

.hub-play-overlay:hover svg {
  transform: scale(1.08);
}

.hub-play-overlay.playing {
  opacity: 0;
  transition: opacity 300ms ease;
}

.hub-play-overlay.playing:hover {
  opacity: 0.7;
}

/* ── VIDEO PROGRESS BAR (thin, top) ─────────────────────────── */
.hub-video-progress {
  position: absolute;
  top: 0;
  left: 0;
  height: 3px;
  background: linear-gradient(90deg, var(--brandl, #7c3aed), var(--brand, #a855f7));
  width: 0%;
  transition: width 250ms linear;
  z-index: 3;
  border-radius: 0 2px 2px 0;
}

/* ── STORY THUMBNAIL — circular cu ring ─────────────────────── */
.story-ring {
  background: linear-gradient(135deg, var(--brandl, #7c3aed), var(--amber, #f59e0b));
  padding: 2px;
  border-radius: 50%;
  display: inline-flex;
}

.story-ring img,
.story-ring .story-avatar {
  border-radius: 50%;
  border: 2px solid var(--bg, #fff);
  width: 52px;
  height: 52px;
  object-fit: cover;
}

/* ── NETWORK QUALITY INDICATOR (debug, ascuns în prod) ───────── */
.hub-net-indicator {
  display: none; /* Activat via console: document.querySelector('.hub-net-indicator').style.display='block' */
  position: fixed;
  bottom: 80px;
  right: 12px;
  background: rgba(0,0,0,0.7);
  color: #fff;
  font-size: 10px;
  padding: 2px 6px;
  border-radius: 4px;
  z-index: 9999;
  pointer-events: none;
}

/* ── MEDIA QUERIES — Mobile video optimization ──────────────── */
@media (max-width: 600px) {
  .hub-video-container {
    border-radius: 0;
    margin: 0 -16px; /* Full-bleed pe mobile */
  }

  video {
    /* Pe mobile, prevent double-tap zoom pe video */
    touch-action: manipulation;
  }

  /* Thumbnail mai mici pe mobile */
  .story-ring img,
  .story-ring .story-avatar {
    width: 44px;
    height: 44px;
  }
}

/* ── DARK MODE — background negru pentru video ──────────────── */
@media (prefers-color-scheme: dark) {
  .hub-video-container,
  .post-media {
    background: #000;
  }
}

/* ── REDUCED MOTION — dezactivăm animații ───────────────────── */
@media (prefers-reduced-motion: reduce) {
  video,
  img,
  .tab-content,
  .view-panel,
  .hub-play-overlay,
  .hub-video-progress {
    transition-duration: 0.001ms;
    animation-duration: 0.001ms;
  }

  .img-skeleton,
  .video-skeleton {
    animation: none;
    background: var(--card, #f0f0f0);
  }
}

/* ── CONTAIN pentru layout stability ───────────────────────── */
.post-card {
  contain: layout style;
}

.post-media {
  contain: layout;
}

/* ── PRELOAD INDICATOR (animated border când se preîncarcă) ─── */
video[data-preloading] {
  outline: 2px solid rgba(124, 58, 237, 0.3);
  outline-offset: -2px;
  animation: hub-preload-pulse 1s ease-in-out infinite alternate;
}

@keyframes hub-preload-pulse {
  from { outline-color: rgba(124,58,237,0.1); }
  to   { outline-color: rgba(124,58,237,0.4); }
}

/* ── UPLOAD PROGRESS ─────────────────────────────────────────── */
.hub-upload-progress {
  height: 4px;
  border-radius: 2px;
  background: var(--card, #f0f0f0);
  overflow: hidden;
  margin-top: 8px;
}

.hub-upload-progress-bar {
  height: 100%;
  background: linear-gradient(90deg, var(--brandl, #7c3aed), var(--brand, #a855f7));
  border-radius: 2px;
  transition: width 200ms ease;
  width: 0%;
}

/* ── UPLOAD ERROR MESSAGE ─────────────────────────────────────── */
.hub-upload-error {
  color: #dc2626;
  font-size: 13px;
  padding: 8px 12px;
  background: rgba(220, 38, 38, 0.08);
  border: 1px solid rgba(220, 38, 38, 0.2);
  border-radius: 8px;
  margin-top: 8px;
  display: none;
}

.hub-upload-error.visible {
  display: block;
}

/* ── IMAGE — prevent CLS (Cumulative Layout Shift) ──────────── */
.post-media img {
  aspect-ratio: attr(width) / attr(height);
}

/* Dimensiuni cunoscute pentru placeholder */
.post-media img[width][height] {
  width: 100%;
  height: auto;
}


/* ── 2. Functionalitati UI (reactions, fab, modal) ── */

/* ── REACTION PICKER ─────────────────────────────────────────── */
.hub-reaction-picker {
  position: absolute;
  display: flex;
  gap: 4px;
  background: var(--card, #fff);
  border: 1px solid var(--border, #ddd);
  border-radius: 30px;
  padding: 6px 10px;
  box-shadow: 0 4px 24px rgba(0,0,0,0.18);
  z-index: 2000;
  opacity: 0;
  transform: scale(0.85) translateY(8px);
  pointer-events: none;
  transition: opacity 150ms ease, transform 150ms ease;
}
.hub-reaction-picker.visible { opacity: 1; transform: scale(1) translateY(0); pointer-events: all; }
.hub-react-btn {
  background: none; border: none; font-size: 22px; cursor: pointer;
  padding: 2px 4px; border-radius: 50%;
  transition: transform 200ms cubic-bezier(0.34,1.56,0.64,1), background 150ms;
  line-height: 1;
}
.hub-react-btn:hover { transform: scale(1.35) translateY(-4px); background: var(--brandbg, rgba(124,58,237,.09)); }
.hub-reaction-badge {
  display: inline-flex; align-items: center; gap: 2px;
  background: var(--card2, #f0f0f0); border-radius: 12px;
  padding: 1px 7px; font-size: 13px; cursor: pointer;
  transition: background 120ms;
}
.hub-reaction-badge:hover { background: var(--brandbg, rgba(124,58,237,.1)); }

/* ── POLL ────────────────────────────────────────────────────── */
.hub-poll { background: var(--card2,#f5f5f5); border-radius: 12px; padding: 14px 16px; margin-top: 10px; }
.hub-poll-q { font-weight: 600; font-size: 15px; margin: 0 0 10px; }
.hub-poll-opts { display: flex; flex-direction: column; gap: 8px; }
.hub-poll-opt {
  position: relative; overflow: hidden;
  background: var(--card,#fff); border: 1.5px solid var(--border,#ddd);
  border-radius: 8px; padding: 10px 12px; text-align: left; cursor: pointer;
  display: flex; align-items: center; justify-content: space-between;
  transition: border-color 150ms, background 150ms;
  font-size: 14px;
}
.hub-poll-opt:hover:not(:disabled) { border-color: var(--brand,#7c3aed); }
.hub-poll-opt.selected { border-color: var(--brand,#7c3aed); background: var(--brandbg,rgba(124,58,237,.08)); }
.hub-poll-opt:disabled { cursor: default; }
.hub-poll-bar {
  position: absolute; left: 0; top: 0; bottom: 0;
  background: rgba(124,58,237,0.12);
  transition: width 400ms ease;
  z-index: 0;
}
.hub-poll-opt-text { position: relative; z-index: 1; }
.hub-poll-pct { position: relative; z-index: 1; font-weight: 600; color: var(--brand,#7c3aed); font-size: 13px; }
.hub-poll-total { font-size: 12px; color: var(--muted,#888); margin: 8px 0 0; }

/* ── MODALS ──────────────────────────────────────────────────── */
.hub-modal-overlay {
  position: fixed; inset: 0; background: rgba(0,0,0,0.5);
  display: flex; align-items: flex-end; justify-content: center;
  z-index: 3000; padding: 16px;
}
@media (min-width: 640px) { .hub-modal-overlay { align-items: center; } }
.hub-modal-box {
  background: var(--card,#fff); border-radius: 16px 16px 0 0;
  width: 100%; max-width: 480px; max-height: 85vh;
  overflow-y: auto; overscroll-behavior: contain;
  box-shadow: 0 -8px 32px rgba(0,0,0,0.2);
  animation: hub-slide-up 200ms ease;
}
@media (min-width: 640px) { .hub-modal-box { border-radius: 16px; box-shadow: 0 8px 40px rgba(0,0,0,0.3); } }
@keyframes hub-slide-up { from { transform: translateY(40px); opacity: 0; } }
.hub-modal-header {
  display: flex; justify-content: space-between; align-items: center;
  padding: 16px; border-bottom: 1px solid var(--border,#eee);
  font-weight: 700; font-size: 16px; position: sticky; top: 0;
  background: var(--card,#fff); z-index: 1;
}
.hub-modal-header button { background: none; border: none; font-size: 20px; cursor: pointer; color: var(--muted,#888); padding: 4px 8px; border-radius: 6px; }
.hub-modal-header button:hover { background: var(--card2,#f0f0f0); }
.hub-modal-search { width: calc(100% - 32px); margin: 12px 16px 4px; padding: 10px 14px; border: 1.5px solid var(--border,#ddd); border-radius: 8px; font-size: 14px; background: var(--bg,#f5f5f5); }
.hub-input { display: block; width: calc(100% - 32px); margin: 6px 16px; padding: 10px 14px; border: 1.5px solid var(--border,#ddd); border-radius: 8px; font-size: 14px; background: var(--bg,#f5f5f5); font-family: var(--font,inherit); }
.hub-btn-brand { background: var(--brand,#7c3aed); color: #fff; border: none; border-radius: 8px; padding: 10px 20px; font-weight: 600; cursor: pointer; font-size: 14px; transition: opacity 150ms; }
.hub-btn-brand:hover { opacity: 0.88; }
.hub-link-btn { display: inline-block; padding: 2px 8px; border-radius: 6px; background: var(--brandbg,rgba(124,58,237,.1)); color: var(--brand,#7c3aed); font-size: 12px; text-decoration: none; margin: 2px; }

/* ── CURRENCY ────────────────────────────────────────────────── */
.hub-currency-content { padding: 16px; }
.hub-currency-row { display: flex; align-items: center; gap: 10px; margin-bottom: 12px; }
.hub-currency-row input { padding: 10px; border: 1.5px solid var(--border,#ddd); border-radius: 8px; font-size: 18px; font-weight: 700; }
.hub-cur-results { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; }
.hub-cur-row { display: flex; justify-content: space-between; align-items: center; background: var(--bg,#f5f5f5); padding: 10px 12px; border-radius: 8px; }
.hub-cur-row span:first-child { font-weight: 600; color: var(--muted,#888); font-size: 13px; }
.hub-cur-row span:last-child { font-weight: 700; font-size: 16px; color: var(--ink,#1c1e21); }
.hub-cur-updated { font-size: 11px; color: var(--muted,#888); margin-top: 8px; }

/* ── CONSULATE ───────────────────────────────────────────────── */
.hub-con-list { padding: 8px 16px 16px; }
.hub-con-item { padding: 12px; border-radius: 10px; border: 1px solid var(--border,#eee); margin-bottom: 8px; }
.hub-con-item b { font-size: 15px; }
.hub-con-item small { color: var(--muted,#888); font-size: 13px; display: block; margin: 2px 0; }
.hub-con-item a { color: var(--brand,#7c3aed); text-decoration: none; }
.hub-con-emergency { display: block; margin-top: 4px; background: rgba(228,30,63,0.08); padding: 4px 8px; border-radius: 6px; font-size: 12px; }

/* ── NEWS ────────────────────────────────────────────────────── */
.hub-news-list { padding: 8px; }
.hub-news-item { display: flex; gap: 10px; padding: 10px; border-radius: 10px; text-decoration: none; color: var(--ink,#1c1e21); border-bottom: 1px solid var(--border,#eee); transition: background 120ms; }
.hub-news-item:hover { background: var(--bg,#f5f5f5); }
.hub-news-img { width: 72px; height: 54px; object-fit: cover; border-radius: 8px; flex-shrink: 0; }
.hub-news-title { font-weight: 600; font-size: 14px; margin: 0 0 4px; }
.hub-news-src { color: var(--muted,#888); font-size: 12px; }

/* ── BUSINESS DIRECTORY ──────────────────────────────────────── */
.hub-biz-list { padding: 8px 16px; }
.hub-biz-item { display: flex; gap: 12px; padding: 12px 0; border-bottom: 1px solid var(--border,#eee); align-items: flex-start; }
.hub-biz-logo { width: 48px; height: 48px; object-fit: cover; border-radius: 8px; flex-shrink: 0; }
.hub-biz-logo-ph { width: 48px; height: 48px; border-radius: 8px; background: var(--card2,#f0f0f0); display: flex; align-items: center; justify-content: center; font-size: 24px; flex-shrink: 0; }
.hub-biz-info b { font-size: 15px; }
.hub-biz-info small { display: block; color: var(--muted,#888); font-size: 12px; margin: 2px 0; }
.hub-biz-form { padding: 16px; border-top: 1px solid var(--border,#eee); }
.hub-biz-form b { display: block; margin-bottom: 10px; }

/* ── 2FA ─────────────────────────────────────────────────────── */
.hub-2fa-secret { font-family: monospace; font-size: 16px; letter-spacing: 3px; background: var(--bg,#f5f5f5); padding: 12px 16px; border-radius: 8px; text-align: center; user-select: all; border: 1px dashed var(--border,#ddd); margin: 10px 0; word-break: break-all; }

/* ── SCHEDULED ───────────────────────────────────────────────── */
.hub-sched-item { display: flex; align-items: flex-start; gap: 10px; padding: 10px; border-radius: 10px; border: 1px solid var(--border,#eee); margin-bottom: 8px; }
.hub-sched-item p { flex: 1; margin: 0 0 4px; font-size: 14px; }
.hub-sched-item small { color: var(--muted,#888); font-size: 12px; }
.hub-sched-del { background: none; border: none; color: var(--red,#e41e3f); cursor: pointer; font-size: 16px; padding: 4px; flex-shrink: 0; }

/* ── ADMIN DASHBOARD ─────────────────────────────────────────── */
.hub-admin-box { max-width: 560px; }
.hub-admin-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; padding: 16px; }
.hub-stat-card { background: var(--bg,#f5f5f5); border-radius: 10px; padding: 16px; text-align: center; }
.hub-stat-card span { display: block; font-size: 28px; font-weight: 800; color: var(--brand,#7c3aed); }
.hub-stat-card small { font-size: 12px; color: var(--muted,#888); }
.hub-stat-warn { background: rgba(228,30,63,0.08); }
.hub-stat-warn span { color: var(--red,#e41e3f); }

/* ── FAB (Floating Action Buttons) ──────────────────────────── */
#hub-fab-container { position: fixed; bottom: 80px; right: 16px; z-index: 1500; }
.hub-fab-group { display: flex; flex-direction: column-reverse; align-items: flex-end; gap: 8px; }
.hub-fab-main {
  width: 52px; height: 52px; border-radius: 50%;
  background: var(--brand,#7c3aed); color: #fff; border: none;
  font-size: 22px; cursor: pointer; box-shadow: 0 4px 16px rgba(124,58,237,0.4);
  transition: transform 200ms, background 150ms;
  display: flex; align-items: center; justify-content: center;
}
.hub-fab-main:hover { transform: scale(1.1); }
.hub-fab-items { display: flex; flex-direction: column-reverse; gap: 8px; overflow: hidden; max-height: 0; transition: max-height 300ms ease; }
.hub-fab-items.open { max-height: 600px; }
.hub-fab-item {
  width: 44px; height: 44px; border-radius: 50%;
  background: var(--card,#fff); border: 2px solid var(--border,#ddd);
  font-size: 20px; cursor: pointer; box-shadow: 0 2px 8px rgba(0,0,0,0.15);
  transition: transform 150ms, box-shadow 150ms;
  display: flex; align-items: center; justify-content: center;
}
.hub-fab-item:hover { transform: scale(1.12); box-shadow: 0 4px 16px rgba(0,0,0,0.2); }
@media (max-width: 480px) { #hub-fab-container { bottom: 70px; right: 10px; } }

/* ── TRANSLATE BUTTON ────────────────────────────────────────── */
.hub-translate-btn {
  background: none; border: 1px solid var(--border,#ddd);
  border-radius: 6px; padding: 3px 8px; font-size: 12px;
  color: var(--muted,#888); cursor: pointer; margin-left: 4px;
  transition: border-color 120ms, color 120ms;
}
.hub-translate-btn:hover { border-color: var(--brand,#7c3aed); color: var(--brand,#7c3aed); }

/* ── NEW POSTS BANNER ────────────────────────────────────────── */
.hub-new-posts-banner {
  background: var(--brand,#7c3aed); color: #fff;
  text-align: center; padding: 10px; font-size: 14px; font-weight: 600;
  cursor: pointer; border-radius: 10px; margin: 8px 0;
  animation: hub-banner-pulse 2s ease-in-out infinite;
}
@keyframes hub-banner-pulse {
  0%,100% { transform: scale(1); }
  50% { transform: scale(1.01); }
}

/* ── READ RECEIPTS ────────────────────────────────────────────── */
.msg-read-indicator { font-size: 11px; color: var(--muted,#888); margin-left: 4px; }
.msg-read-indicator.read { color: var(--brand,#7c3aed); }

/* ── WS STATUS ────────────────────────────────────────────────── */
.hub-ws-status-dot {
  display: inline-block; width: 8px; height: 8px; border-radius: 50%;
  background: #ccc; margin-right: 4px;
  transition: background 400ms;
}
.hub-ws-status-dot.connected { background: #42b72a; box-shadow: 0 0 6px rgba(66,183,42,0.6); }

/* ── DARK MODE ────────────────────────────────────────────────── */
@media (prefers-color-scheme: dark) {
  .hub-modal-box { background: #1c1e21; }
  .hub-modal-header { background: #1c1e21; border-bottom-color: #3a3b3c; }
  .hub-fab-item { background: #242526; border-color: #3a3b3c; }
  .hub-stat-card { background: #242526; }
  .hub-poll-opt { background: #242526; border-color: #3a3b3c; }
  .hub-biz-logo-ph { background: #242526; }
}

/* ── REDUCED MOTION ───────────────────────────────────────────── */
@media (prefers-reduced-motion: reduce) {
  .hub-reaction-picker, .hub-react-btn, .hub-fab-main, .hub-fab-item,
  .hub-modal-box, .hub-new-posts-banner {
    transition-duration: 0.001ms;
    animation-duration: 0.001ms;
  }
}


/* ── 3. Ajustari layout desktop ────────────────────── */

/* ── Radio banner: pozitionare corecta pe desktop ── */
@media (min-width: 1024px) {

  /* Banda radio ancorata la limitele coloanei de continut,
     nu centrata pe viewport (ceea ce o scotea din context). */
  .radio-banner {
    left:  calc(var(--rail-w, 248px) + var(--gap, 28px));
    right: calc(var(--right-w, 320px) + var(--gap, 28px));
    transform: none;
    max-width: none;
    border-radius: 0 0 14px 14px;
    z-index: 210;
  }

  /* Hub-scroll: adauga spatiu cand radio este activ */
  .hub-scroll.radio-open {
    padding-top: calc(var(--bar-h, 56px) + var(--gap, 28px) + 52px);
  }

  /* Radio card pe desktop: aspect-ratio mai relaxat */
  .radio-card {
    border-radius: 14px;
    box-shadow:
      0 2px 6px rgba(15, 23, 42, .06),
      0 6px 18px rgba(15, 23, 42, .10);
    transition: transform 0.20s ease, box-shadow 0.20s ease;
  }

  .radio-card:hover {
    transform: translateY(-3px);
    box-shadow:
      0 4px 12px rgba(15, 23, 42, .10),
      0 12px 32px rgba(15, 23, 42, .16);
  }

  .radio-card.playing {
    box-shadow:
      0 0 0 2px var(--brand, #7c3aed),
      0 4px 16px rgba(124, 58, 237, .22);
  }

  /* Aside: radio-banner nu mai iese din contextul paginii */
  .hub-aside {
    z-index: 9;
  }

  /* Radio view pe desktop: grid 3 coloane cu gap generos */
  .radio-grid {
    grid-template-columns: repeat(3, 1fr);
    gap: 14px;
    padding: 0 0 24px;
  }

  .radio-header {
    padding: 20px 0 12px;
  }

  /* Top-bar (hub-header) sa fie deasupra radio-banner */
  .hub-header {
    z-index: 220;
  }
}

/* ── Desktop mediu 769–1023px: radio banner full-width ── */
@media (min-width: 769px) and (max-width: 1023px) {
  .radio-banner {
    left: 0;
    right: 0;
    transform: none;
    max-width: none;
    border-radius: 0;
  }

  .radio-grid {
    grid-template-columns: repeat(3, 1fr);
    gap: 12px;
    padding: 0 0 20px;
  }
}


/* ── 4. Cards 3D & layout text ─────────────────────── */

/* ── dx-hero-grid: container cu perspectiva 3D ── */
.dx-hero-grid {
  perspective: 1200px;
  perspective-origin: 50% 30%;
}

/* ── dx-hero-card: efect 3D realist ── */
.dx-hero-card {
  border-radius: 20px;
  box-shadow:
    0 2px 4px rgba(15, 23, 42, .06),
    0 8px 24px rgba(15, 23, 42, .18),
    0 24px 56px rgba(15, 23, 42, .12);
  transform: perspective(800px) translateZ(0) rotateX(0.4deg);
  transition:
    transform 0.28s cubic-bezier(.22, .68, 0, 1.2),
    box-shadow 0.28s ease;
  will-change: transform;
  isolation: isolate;
}

.dx-hero-card:hover,
.dx-hero-card:focus-within {
  transform: perspective(800px) translateY(-9px) scale(1.03) rotateX(2.5deg);
  box-shadow:
    0 4px 8px rgba(15, 23, 42, .07),
    0 18px 44px rgba(15, 23, 42, .24),
    0 36px 72px rgba(15, 23, 42, .14),
    inset 0 0 0 1px rgba(255, 255, 255, .08);
}

/* Stralucire top-edge: efect de margine luminoasa */
.dx-hero-card::before {
  content: "";
  position: absolute;
  inset: 0;
  border-radius: inherit;
  background: linear-gradient(
    to bottom,
    rgba(255, 255, 255, .18) 0%,
    rgba(255, 255, 255, .06) 30%,
    transparent 60%
  );
  z-index: 2;
  pointer-events: none;
}

/* Imaginea — zoom mai pronuntat pe hover */
.dx-hero-card:hover .dx-hero-bg {
  transform: scale(1.09);
  filter: saturate(1.22) contrast(1.05) brightness(1.04);
  transition: transform 0.55s cubic-bezier(.2, .8, .2, 1), filter 0.28s;
}

/* Text — contrast si lizibilitate */
.dx-hero-content {
  padding: 16px 16px 18px;
  position: relative;
  z-index: 3;
}

.dx-hero-title {
  font-size: 16px;
  font-weight: 800;
  line-height: 1.2;
  letter-spacing: -0.015em;
  text-shadow: 0 1px 8px rgba(0, 0, 0, .55), 0 2px 20px rgba(0, 0, 0, .35);
  margin-bottom: 4px;
}

.dx-hero-sub {
  font-size: 12px;
  font-weight: 500;
  opacity: 0.88;
  text-shadow: 0 1px 6px rgba(0, 0, 0, .45);
  line-height: 1.4;
}

/* ── v237-story: scroll-lateral mobile (GALA) ── */
.v237-stories {
  perspective: 900px;
  perspective-origin: 50% 40%;
}

.v237-story {
  border-radius: 20px;
  box-shadow:
    0 2px 6px rgba(13, 28, 71, .08),
    0 10px 28px rgba(13, 28, 71, .20);
  transform: perspective(600px) translateZ(0) rotateX(0.3deg);
  transition:
    transform 0.24s cubic-bezier(.22, .68, 0, 1.2),
    box-shadow 0.24s ease;
  will-change: transform;
}

.v237-story:hover,
.v237-story:focus-within {
  transform: perspective(600px) translateY(-7px) scale(1.025) rotateX(2deg);
  box-shadow:
    0 4px 10px rgba(13, 28, 71, .10),
    0 20px 48px rgba(13, 28, 71, .30);
}

/* Text story — bold, shadow pronuntat */
.v237-story-title {
  font-size: 14px;
  font-weight: 800;
  line-height: 1.22;
  letter-spacing: -0.012em;
  text-shadow:
    0 1px 6px rgba(0, 0, 0, .55),
    0 2px 16px rgba(0, 0, 0, .40);
}

.v237-story-tag {
  font-size: 10.5px;
  font-weight: 700;
  letter-spacing: 0.07em;
  text-transform: uppercase;
  opacity: 0.92;
}

.v237-story-meta {
  font-size: 11.5px;
  font-weight: 500;
  opacity: 0.85;
  line-height: 1.45;
}

/* ── v237-lane: quick-lane buttons 3D ── */
.v237-lane {
  border-radius: 18px;
  box-shadow:
    0 2px 6px rgba(13, 28, 71, .10),
    0 8px 22px rgba(13, 28, 71, .16);
  transition:
    transform 0.22s cubic-bezier(.22, .68, 0, 1.2),
    box-shadow 0.22s ease;
}

.v237-lane:hover {
  transform: translateY(-5px) scale(1.02);
  box-shadow:
    0 6px 16px rgba(13, 28, 71, .16),
    0 20px 44px rgba(13, 28, 71, .24);
}
