/* ===== MODERN TORRENT TABLE ===== */
.table td, .table th { font-size: 1rem; }
thead th { font-weight: 600; white-space: nowrap; vertical-align: middle; }
thead th i { opacity: 0.75; }

/* Иконки Bootstrap Icons - выравнивание по базовой линии текста */
.bi { vertical-align: -0.125em; }

/* ===== POSTER ===== */
.torrent-poster-cell { width:85px; padding:8px 6px !important; text-align:center; vertical-align:middle; }
.torrent-poster { width:60px; height:85px; object-fit:cover; border-radius:8px; display:block; margin:6px auto 0; box-shadow:0 4px 12px rgba(0,0,0,0.15); transition:all 0.3s cubic-bezier(0.4,0,0.2,1); cursor:pointer; }
.torrent-poster:hover { transform:scale(1.08) translateY(-3px); box-shadow:0 8px 20px rgba(0,0,0,0.25); }
.torrent-poster-placeholder { width:60px; height:85px; display:flex; align-items:center; justify-content:center; background:linear-gradient(135deg,var(--bs-secondary-bg),var(--bs-dark-bg)); border-radius:8px; margin:6px auto 0; border:1px solid rgba(var(--bs-primary-rgb),0.2); }

/* ===== POSTER ZOOM ===== */
.poster-zoom-overlay { position:fixed; top:0; left:0; width:100%; height:100%; z-index:9999; pointer-events:none; display:flex; align-items:center; justify-content:center; }
.poster-zoom-img { max-width:280px; max-height:400px; object-fit:cover; border-radius:12px; box-shadow:0 20px 60px rgba(0,0,0,.5); opacity:0; transform:scale(0.85); transition:opacity 0.2s ease,transform 0.2s ease; pointer-events:none; }
.poster-zoom-img.visible { opacity:1; transform:scale(1); }

/* ===== CATEGORY ===== */
.category-icon-link { display:block; text-align:center; text-decoration:none; line-height:1; margin-bottom:6px; }
.category-icon-small { font-size:20px; transition:all 0.2s ease; display:inline-block; }
.category-icon-small:hover { transform:scale(1.2); filter:drop-shadow(0 2px 4px rgba(0,0,0,0.2)); }
.category-card:hover { border-color:#3b82f6 !important; background:rgba(59,130,246,0.05); transform:translateY(-2px); box-shadow:0 4px 12px rgba(59,130,246,0.12); }

/* ===== TORRENT INFO ===== */
.torrent-info-cell { vertical-align:middle !important; padding:10px 12px !important; }
.torrent-title { display:flex; align-items:flex-start; justify-content:space-between; gap:10px; margin-bottom:6px; }
.torrent-name-link { font-weight:700; font-size:1rem; color:var(--bs-body-color); text-decoration:none; flex:1; line-height:1.4; transition:all 0.2s ease; display:inline-block; }
.torrent-name-link:hover { color:var(--bs-primary); transform:translateX(2px); }
.torrent-actions-inline { display:flex; align-items:center; gap:8px; flex-shrink:0; }
.torrent-actions-inline a { opacity:0.7; transition:all 0.2s ease; }
.torrent-actions-inline a:hover { opacity:1; transform:scale(1.1); }
.torrent-meta { margin-top:6px; display:flex; align-items:center; flex-wrap:wrap; gap:8px; font-size:0.8rem; color:var(--bs-secondary-color); }
.torrent-date { display:inline-flex; align-items:center; background:rgba(var(--bs-primary-rgb),0.08); padding:2px 8px; border-radius:12px; }
.torrent-flags { display:inline-flex; gap:4px; }

/* ===== TAGS ===== */
.torrent-tags { display:flex; flex-wrap:wrap; gap:4px; margin-top:6px; }
.torrent-tags .badge { font-size:0.7rem; padding:3px 10px; border-radius:20px; font-weight:600; background:linear-gradient(135deg,var(--bs-primary),var(--bs-info)); color:white; transition:all 0.2s ease; }
.torrent-tags .badge:hover { transform:translateY(-1px); box-shadow:0 2px 6px rgba(0,0,0,0.15); }

/* Бейджи в ячейках размера/сидов/личей/сскачиваний (из старого инлайн-блока) */
.size-badge, .snatched-badge, .seeders-badge, .leechers-badge {
    transition: all 0.2s ease;
    min-width: 60px;
    text-align: center;
}
.size-badge:hover, .snatched-badge:hover, .seeders-badge:hover, .leechers-badge:hover {
    transform: translateY(-1px);
    box-shadow: 0 2px 4px rgba(0,0,0,0.1);
}
td div .badge {
    margin-right: 4px;
    margin-bottom: 4px;
    font-size: 0.8rem;
}

/* ===== STAT CELLS ===== */
.torrent-stat-cell { vertical-align:middle !important; white-space:nowrap; font-size:0.9rem; padding:8px 6px !important; text-align:center; font-weight:600; }
.torrent-stat-cell a { text-decoration:none; font-weight:600; transition:all 0.2s ease; display:inline-flex; align-items:center; gap:4px; }
.torrent-stat-cell a:hover { transform:translateY(-1px); }
.torrent-stat-cell a.text-success:hover { text-shadow:0 0 8px rgba(40,167,69,0.3); }
.torrent-stat-cell a.text-danger:hover  { text-shadow:0 0 8px rgba(220,53,69,0.3); }

/* ===== UPLOADER ===== */
.torrent-uploader-cell { vertical-align:middle !important; font-size:0.85rem; padding:8px 8px !important; max-width:130px; font-weight:500; }
.torrent-uploader-cell a { display:inline-flex; align-items:center; gap:4px; transition:all 0.2s ease; }
.torrent-uploader-cell a:hover { color:var(--bs-primary) !important; transform:translateX(2px); }

/* ===== ROW ===== */
.torrent-row { transition:all 0.2s ease; border-left:3px solid transparent; }
.torrent-row:hover { background:rgba(var(--bs-primary-rgb),0.05) !important; border-left-color:var(--bs-primary); transform:translateX(2px); }
.torrent-row.is-dead { opacity:0.55; filter:grayscale(0.3); }
.torrent-row.is-dead:hover { opacity:0.8; filter:none; }

/* ===== RESPONSIVE ===== */
@media (max-width: 768px) {
    .torrent-poster,.torrent-poster-placeholder { width:40px; height:55px; }
    .torrent-name-link { font-size:0.9rem !important; }
    .torrent-stat-cell { font-size:0.85rem !important; }
    thead th i { font-size:1rem; }
    thead th span { display: none; }

    .size-badge, .snatched-badge, .seeders-badge, .leechers-badge {
        padding: 2px 6px;
        font-size: 0.8rem;
        min-width: 50px;
    }
    td div {
        font-size: 0.85rem;
    }
}