/* ==========================================
   HOTME VIDEO SINGLE PAGE - v6.9.0
   Inspirado en StreamVid + Estilo HotMe
   ========================================== */

:root {
    --hm-bg-primary: #0a0a0f;
    --hm-bg-secondary: #12121a;
    --hm-bg-card: #1a1a25;
    --hm-bg-elevated: #22222e;
    --hm-red: #D73744;
    --hm-red-hover: #e8485a;
    --hm-red-glow: rgba(215, 55, 68, 0.3);
    --hm-text-primary: #ffffff;
    --hm-text-secondary: #a0a0b0;
    --hm-text-muted: #65657a;
    --hm-border: rgba(255, 255, 255, 0.08);
    --hm-radius-sm: 6px;
    --hm-radius-md: 10px;
    --hm-radius-lg: 16px;
    --hm-radius-xl: 20px;
}

/* === PAGE OVERRIDE === */
.hm-single-video-page {
    background: var(--hm-bg-primary);
    color: var(--hm-text-primary);
    font-family: 'Plus Jakarta Sans', 'Outfit', -apple-system, sans-serif;
    min-height: 100vh;
}

/* Forzar fondo oscuro en body cuando se muestra esta página */
body.single-vme_video {
    background: var(--hm-bg-primary) !important;
}

body.single-vme_video .site-content,
body.single-vme_video .entry-content,
body.single-vme_video #content,
body.single-vme_video #primary,
body.single-vme_video #main,
body.single-vme_video main,
body.single-vme_video article {
    background: transparent !important;
    max-width: 100% !important;
    padding: 0 !important;
    margin: 0 !important;
}

/* Ocultar elementos del tema que interfieren */
body.single-vme_video .entry-title,
body.single-vme_video .entry-meta,
body.single-vme_video .post-navigation,
body.single-vme_video .comments-area,
body.single-vme_video .entry-footer,
body.single-vme_video #comments {
    display: none !important;
}

/* ==========================================
   VIDEO PLAYER HERO
   ========================================== */
.hm-player-section {
    position: relative;
    width: 100%;
    background: #000;
}

.hm-player-wrapper {
    position: relative;
    width: 100%;
    max-width: 1400px;
    margin: 0 auto;
    aspect-ratio: 16 / 9;
    background: #000;
    overflow: hidden;
}

.hm-player-wrapper video,
.hm-player-wrapper iframe {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.hm-player-wrapper img.hm-poster-image {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

/* Success banner */
.hm-success-banner {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    z-index: 10;
    background: linear-gradient(135deg, #22c55e, #16a34a);
    color: white;
    padding: 14px 24px;
    text-align: center;
    font-weight: 600;
    font-size: 0.95rem;
    animation: slideDown 0.5s ease-out;
}

.hm-success-banner a {
    color: white;
    text-decoration: underline;
    margin-left: 12px;
    font-weight: 700;
}

@keyframes slideDown {
    from { transform: translateY(-100%); opacity: 0; }
    to { transform: translateY(0); opacity: 1; }
}

/* Lock overlay */
.hm-lock-overlay {
    position: absolute;
    inset: 0;
    background: linear-gradient(
        180deg,
        rgba(0,0,0,0.2) 0%,
        rgba(0,0,0,0.6) 50%,
        rgba(0,0,0,0.9) 100%
    );
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 16px;
    opacity: 0;
    transition: opacity 0.4s;
    cursor: pointer;
    z-index: 5;
}

.hm-player-wrapper:hover .hm-lock-overlay {
    opacity: 1;
}

.hm-lock-icon {
    width: 72px;
    height: 72px;
    border-radius: 50%;
    background: rgba(215, 55, 68, 0.15);
    border: 2px solid var(--hm-red);
    display: flex;
    align-items: center;
    justify-content: center;
    animation: lockPulse 2s ease-in-out infinite;
}

.hm-lock-icon i {
    font-size: 1.6rem;
    color: var(--hm-red);
}

@keyframes lockPulse {
    0%, 100% { box-shadow: 0 0 0 0 var(--hm-red-glow); }
    50% { box-shadow: 0 0 0 12px transparent; }
}

.hm-lock-text {
    font-family: 'Outfit', sans-serif;
    font-size: 1.2rem;
    font-weight: 600;
    text-align: center;
    max-width: 400px;
    color: var(--hm-text-primary);
}

.hm-lock-sub {
    font-size: 0.85rem;
    color: var(--hm-text-secondary);
}

/* Player bottom gradient */
.hm-player-gradient {
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    height: 120px;
    background: linear-gradient(transparent, var(--hm-bg-primary));
    pointer-events: none;
}

/* ==========================================
   VIDEO INFO BAR
   ========================================== */
.hm-content-area {
    max-width: 1400px;
    margin: 0 auto;
    padding: 0 40px;
}

.hm-video-info {
    display: grid;
    grid-template-columns: 1fr auto;
    gap: 40px;
    padding: 32px 0;
    border-bottom: 1px solid var(--hm-border);
    animation: fadeInUp 0.5s ease-out 0.1s both;
}

.hm-video-meta {
    display: flex;
    flex-direction: column;
    gap: 14px;
}

.hm-video-title {
    font-family: 'Outfit', sans-serif;
    font-size: 2rem;
    font-weight: 700;
    line-height: 1.2;
    color: var(--hm-text-primary);
}

.hm-video-tags {
    display: flex;
    align-items: center;
    gap: 12px;
    flex-wrap: wrap;
}

.hm-tag {
    padding: 4px 12px;
    background: var(--hm-bg-elevated);
    border-radius: 50px;
    font-size: 0.78rem;
    font-weight: 500;
    color: var(--hm-text-secondary);
    border: 1px solid var(--hm-border);
    text-decoration: none;
    display: inline-flex;
    align-items: center;
    gap: 4px;
}

.hm-tag.category {
    background: rgba(215, 55, 68, 0.12);
    color: var(--hm-red);
    border-color: rgba(215, 55, 68, 0.25);
}

.hm-tag.category:hover {
    background: rgba(215, 55, 68, 0.2);
}

.hm-creator-row {
    display: flex;
    align-items: center;
    gap: 12px;
}

.hm-creator-avatar {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    background: var(--hm-bg-elevated);
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 700;
    font-size: 0.85rem;
    color: var(--hm-red);
    border: 2px solid var(--hm-red);
}

.hm-creator-info {
    display: flex;
    flex-direction: column;
}

.hm-creator-name {
    font-weight: 600;
    font-size: 0.95rem;
    color: var(--hm-text-primary);
}

.hm-creator-label {
    font-size: 0.78rem;
    color: var(--hm-text-muted);
}

/* Actions */
.hm-video-actions {
    display: flex;
    align-items: center;
    gap: 12px;
}

.hm-action-btn {
    width: 44px;
    height: 44px;
    border-radius: 50%;
    background: var(--hm-bg-elevated);
    border: 1px solid var(--hm-border);
    color: var(--hm-text-secondary);
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1rem;
    transition: all 0.25s;
}

.hm-action-btn:hover {
    background: var(--hm-bg-card);
    color: var(--hm-text-primary);
    border-color: rgba(255,255,255,0.15);
    transform: translateY(-2px);
}

/* ==========================================
   MAIN LAYOUT
   ========================================== */
.hm-main-layout {
    display: grid;
    grid-template-columns: 1fr 380px;
    gap: 48px;
    padding: 40px 0 60px;
}

/* Full width when no purchase card (already purchased) */
.hm-main-layout:not(:has(.hm-right-column)) {
    grid-template-columns: 1fr;
}

/* ==========================================
   DESCRIPTION
   ========================================== */
.hm-description-block {
    background: var(--hm-bg-secondary);
    border: 1px solid var(--hm-border);
    border-radius: var(--hm-radius-lg);
    padding: 28px;
    margin-bottom: 32px;
    animation: fadeInUp 0.5s ease-out 0.2s both;
}

.hm-description-block h3 {
    font-family: 'Outfit', sans-serif;
    font-size: 1.1rem;
    font-weight: 600;
    margin-bottom: 14px;
    display: flex;
    align-items: center;
    gap: 8px;
    color: var(--hm-text-primary);
}

.hm-description-block h3 i {
    color: var(--hm-red);
    font-size: 0.9rem;
}

.hm-description-text {
    font-size: 0.92rem;
    line-height: 1.75;
    color: var(--hm-text-secondary);
}

.hm-description-text p {
    color: var(--hm-text-secondary);
    margin-bottom: 12px;
}

.hm-description-text p:last-child {
    margin-bottom: 0;
}

.hm-video-stats {
    display: flex;
    gap: 24px;
    margin-top: 20px;
    padding-top: 18px;
    border-top: 1px solid var(--hm-border);
    flex-wrap: wrap;
}

.hm-stat-item {
    display: flex;
    align-items: center;
    gap: 6px;
    font-size: 0.82rem;
    color: var(--hm-text-muted);
}

/* Rating stars */
.hm-rating {
    display: flex;
    align-items: center;
    gap: 4px;
}

.hm-rating i {
    color: #fbbf24;
    font-size: 0.82rem;
}

.hm-rating i.empty {
    color: var(--hm-text-muted);
}

.hm-rating span {
    margin-left: 4px;
    color: var(--hm-text-secondary);
    font-weight: 500;
}

/* ==========================================
   COMMENTS
   ========================================== */
.hm-comments-block {
    background: var(--hm-bg-secondary);
    border: 1px solid var(--hm-border);
    border-radius: var(--hm-radius-lg);
    padding: 28px;
}

.hm-comments-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 24px;
}

.hm-comments-header h3 {
    font-family: 'Outfit', sans-serif;
    font-size: 1.1rem;
    font-weight: 600;
    display: flex;
    align-items: center;
    gap: 8px;
    color: var(--hm-text-primary);
}

.hm-comment-count {
    background: var(--hm-bg-elevated);
    padding: 2px 10px;
    border-radius: 50px;
    font-size: 0.75rem;
    color: var(--hm-text-muted);
}

.hm-comment-login {
    text-align: center;
    padding: 32px 20px;
    color: var(--hm-text-muted);
    font-size: 0.9rem;
}

.hm-comment-login i {
    font-size: 2rem;
    display: block;
    margin-bottom: 12px;
}

.hm-comment-login a {
    color: var(--hm-red);
    text-decoration: none;
    font-weight: 600;
}

.hm-comment-login a:hover {
    text-decoration: underline;
}

/* Comment form */
.hm-comment-form-wrap #respond {
    margin: 0;
    padding: 0;
}

.hm-comment-form-wrap textarea {
    width: 100%;
    background: var(--hm-bg-elevated);
    border: 1px solid var(--hm-border);
    border-radius: var(--hm-radius-md);
    padding: 14px;
    color: var(--hm-text-primary);
    font-family: inherit;
    font-size: 0.9rem;
    resize: vertical;
    min-height: 80px;
}

.hm-comment-form-wrap textarea:focus {
    outline: none;
    border-color: var(--hm-red);
}

.hm-btn-comment,
.hm-comment-form-wrap .submit {
    background: var(--hm-red) !important;
    color: white !important;
    border: none !important;
    padding: 10px 24px !important;
    border-radius: var(--hm-radius-md) !important;
    font-weight: 600 !important;
    cursor: pointer !important;
    transition: all 0.25s !important;
    margin-top: 10px !important;
}

.hm-btn-comment:hover,
.hm-comment-form-wrap .submit:hover {
    background: var(--hm-red-hover) !important;
    box-shadow: 0 4px 20px var(--hm-red-glow) !important;
}

/* Comments list */
.hm-comments-list {
    margin-top: 24px;
    border-top: 1px solid var(--hm-border);
    padding-top: 20px;
}

.hm-comment-item {
    display: flex;
    gap: 12px;
    padding: 14px 0;
    border-bottom: 1px solid var(--hm-border);
}

.hm-comment-item:last-child {
    border-bottom: none;
}

.hm-comment-avatar {
    width: 36px;
    height: 36px;
    border-radius: 50%;
    background: var(--hm-bg-elevated);
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 700;
    font-size: 0.8rem;
    color: var(--hm-red);
    flex-shrink: 0;
}

.hm-comment-body {
    flex: 1;
}

.hm-comment-meta {
    display: flex;
    align-items: center;
    gap: 10px;
    margin-bottom: 6px;
}

.hm-comment-meta strong {
    font-size: 0.85rem;
    color: var(--hm-text-primary);
}

.hm-comment-meta span {
    font-size: 0.75rem;
    color: var(--hm-text-muted);
}

.hm-comment-body p {
    font-size: 0.88rem;
    color: var(--hm-text-secondary);
    line-height: 1.5;
    margin: 0;
}

/* ==========================================
   PURCHASE CARD (Sidebar)
   ========================================== */
.hm-purchase-card {
    position: sticky;
    top: 84px;
    background: var(--hm-bg-secondary);
    border: 1px solid var(--hm-border);
    border-radius: var(--hm-radius-xl);
    overflow: hidden;
    animation: fadeInUp 0.5s ease-out 0.3s both;
    transition: box-shadow 0.4s, border-color 0.4s;
}

.hm-purchase-thumbnail {
    position: relative;
    aspect-ratio: 16 / 9;
    overflow: hidden;
}

.hm-purchase-thumbnail img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.5s;
}

.hm-purchase-card:hover .hm-purchase-thumbnail img {
    transform: scale(1.05);
}

.hm-purchase-badge {
    position: absolute;
    top: 12px;
    left: 12px;
    background: var(--hm-red);
    color: white;
    padding: 4px 12px;
    border-radius: 50px;
    font-size: 0.72rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.hm-purchase-body {
    padding: 24px;
}

.hm-purchase-price-row {
    display: flex;
    align-items: baseline;
    gap: 8px;
    margin-bottom: 4px;
}

.hm-purchase-currency {
    font-size: 0.85rem;
    color: var(--hm-text-muted);
    font-weight: 500;
}

.hm-purchase-price {
    font-family: 'Outfit', sans-serif;
    font-size: 2.4rem;
    font-weight: 800;
    color: var(--hm-text-primary);
}

.hm-purchase-price-alt {
    font-size: 0.9rem;
    color: var(--hm-text-secondary);
    margin-bottom: 4px;
}

.hm-purchase-note {
    font-size: 0.78rem;
    color: var(--hm-text-muted);
    margin-bottom: 20px;
}

.hm-btn-buy {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    width: 100%;
    padding: 16px;
    background: var(--hm-red);
    color: white;
    border: none;
    border-radius: var(--hm-radius-md);
    font-size: 1rem;
    font-weight: 700;
    font-family: 'Outfit', sans-serif;
    cursor: pointer;
    transition: all 0.3s;
    letter-spacing: 0.3px;
    text-decoration: none;
    text-align: center;
}

.hm-btn-buy:hover {
    background: var(--hm-red-hover);
    box-shadow: 0 8px 30px var(--hm-red-glow);
    transform: translateY(-2px);
    color: white;
    text-decoration: none;
}

.hm-btn-buy i {
    font-size: 1.1rem;
}

.hm-purchase-features {
    margin-top: 20px;
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.hm-feature-item {
    display: flex;
    align-items: center;
    gap: 10px;
    font-size: 0.82rem;
    color: var(--hm-text-secondary);
}

.hm-feature-item i {
    color: #22c55e;
    font-size: 0.75rem;
    width: 18px;
    text-align: center;
}

.hm-purchase-divider {
    height: 1px;
    background: var(--hm-border);
    margin: 20px 0;
}

.hm-guest-notice {
    display: flex;
    align-items: flex-start;
    gap: 10px;
    padding: 14px;
    background: rgba(215, 55, 68, 0.06);
    border-radius: var(--hm-radius-sm);
    border: 1px solid rgba(215, 55, 68, 0.12);
}

.hm-guest-notice i {
    color: var(--hm-red);
    margin-top: 2px;
    font-size: 0.85rem;
}

.hm-guest-notice p {
    font-size: 0.78rem;
    color: var(--hm-text-secondary);
    line-height: 1.5;
    margin: 0;
}

/* ==========================================
   NAVIGATION (Prev/Next)
   ========================================== */
.hm-post-nav {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 16px;
    margin-bottom: 32px;
}

.hm-post-nav a {
    display: flex;
    align-items: center;
    gap: 14px;
    padding: 16px 20px;
    background: var(--hm-bg-secondary);
    border: 1px solid var(--hm-border);
    border-radius: var(--hm-radius-md);
    text-decoration: none;
    color: var(--hm-text-primary);
    transition: all 0.25s;
}

.hm-post-nav a:hover {
    background: var(--hm-bg-card);
    border-color: rgba(255,255,255,0.12);
    transform: translateY(-2px);
    color: var(--hm-text-primary);
    text-decoration: none;
}

.hm-post-nav > :last-child {
    justify-content: flex-end;
    text-align: right;
}

.hm-post-nav-icon {
    width: 36px;
    height: 36px;
    border-radius: 50%;
    background: var(--hm-bg-elevated);
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--hm-text-muted);
    flex-shrink: 0;
}

.hm-post-nav-text {
    display: flex;
    flex-direction: column;
}

.hm-post-nav-label {
    font-size: 0.72rem;
    color: var(--hm-text-muted);
    text-transform: uppercase;
    letter-spacing: 0.5px;
    margin-bottom: 2px;
}

.hm-post-nav-title {
    font-size: 0.88rem;
    font-weight: 600;
}

/* ==========================================
   RELATED VIDEOS
   ========================================== */
.hm-related-section {
    padding: 40px 0 80px;
    border-top: 1px solid var(--hm-border);
    animation: fadeInUp 0.5s ease-out 0.4s both;
}

.hm-section-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 24px;
}

.hm-section-header h2 {
    font-family: 'Outfit', sans-serif;
    font-size: 1.4rem;
    font-weight: 700;
    color: var(--hm-text-primary);
}

.hm-section-header a {
    color: var(--hm-red);
    text-decoration: none;
    font-size: 0.85rem;
    font-weight: 600;
}

.hm-section-header a:hover {
    color: var(--hm-red-hover);
}

.hm-related-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 20px;
}

.hm-related-card {
    background: var(--hm-bg-secondary);
    border: 1px solid var(--hm-border);
    border-radius: var(--hm-radius-md);
    overflow: hidden;
    transition: all 0.3s;
    cursor: pointer;
    text-decoration: none;
    color: var(--hm-text-primary);
    display: block;
}

.hm-related-card:hover {
    transform: translateY(-6px);
    box-shadow: 0 12px 40px rgba(0,0,0,0.4);
    border-color: rgba(255,255,255,0.12);
    color: var(--hm-text-primary);
    text-decoration: none;
}

.hm-related-thumb {
    position: relative;
    aspect-ratio: 16 / 9;
    overflow: hidden;
}

.hm-related-thumb img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.4s;
}

.hm-related-card:hover .hm-related-thumb img {
    transform: scale(1.08);
}

.hm-related-play {
    position: absolute;
    inset: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    background: rgba(0,0,0,0.3);
    opacity: 0;
    transition: opacity 0.3s;
}

.hm-related-card:hover .hm-related-play {
    opacity: 1;
}

.hm-related-play i {
    font-size: 2rem;
    color: white;
    filter: drop-shadow(0 2px 8px rgba(0,0,0,0.5));
}

.hm-related-price-badge {
    position: absolute;
    bottom: 8px;
    right: 8px;
    background: rgba(0,0,0,0.8);
    backdrop-filter: blur(8px);
    padding: 4px 10px;
    border-radius: 50px;
    font-size: 0.78rem;
    font-weight: 700;
    color: #22c55e;
}

.hm-related-price-badge.hm-free {
    color: #fbbf24;
}

.hm-related-info {
    padding: 14px;
}

.hm-related-title {
    font-family: 'Outfit', sans-serif;
    font-weight: 600;
    font-size: 0.92rem;
    margin-bottom: 6px;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    color: var(--hm-text-primary);
}

.hm-related-creator {
    font-size: 0.78rem;
    color: var(--hm-text-muted);
}

.hm-related-creator span {
    color: var(--hm-text-secondary);
}

/* ==========================================
   ANIMATIONS
   ========================================== */
@keyframes fadeInUp {
    from { opacity: 0; transform: translateY(20px); }
    to { opacity: 1; transform: translateY(0); }
}

/* ==========================================
   RESPONSIVE
   ========================================== */
@media (max-width: 1200px) {
    .hm-related-grid {
        grid-template-columns: repeat(3, 1fr);
    }
    .hm-related-card:nth-child(4) {
        display: none;
    }
}

@media (max-width: 1024px) {
    .hm-content-area {
        padding: 0 24px;
    }
    .hm-main-layout {
        grid-template-columns: 1fr;
        gap: 32px;
    }
    .hm-purchase-card {
        position: static;
        max-width: 480px;
    }
    .hm-right-column {
        order: -1;
    }
    /* Lock siempre visible en táctil */
    .hm-lock-overlay {
        opacity: 1;
    }
}

@media (max-width: 768px) {
    .hm-content-area {
        padding: 0 16px;
    }
    .hm-video-info {
        grid-template-columns: 1fr;
        gap: 20px;
    }
    .hm-video-title {
        font-size: 1.5rem;
    }
    .hm-video-actions {
        justify-content: flex-start;
    }
    .hm-purchase-card {
        max-width: 100%;
    }
    .hm-related-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 12px;
    }
    .hm-related-card:nth-child(4) {
        display: block;
    }
    .hm-post-nav {
        grid-template-columns: 1fr;
    }
    .hm-post-nav > :last-child {
        justify-content: flex-start;
        text-align: left;
    }
    .hm-main-layout {
        padding: 24px 0 40px;
    }
    .hm-lock-icon {
        width: 56px;
        height: 56px;
    }
    .hm-lock-icon i {
        font-size: 1.2rem;
    }
    .hm-lock-text {
        font-size: 1rem;
    }
}

@media (max-width: 480px) {
    .hm-video-title {
        font-size: 1.3rem;
    }
    .hm-purchase-price {
        font-size: 2rem;
    }
    .hm-purchase-body {
        padding: 18px;
    }
    .hm-description-block {
        padding: 20px;
    }
    .hm-related-grid {
        grid-template-columns: 1fr 1fr;
        gap: 10px;
    }
    .hm-related-info {
        padding: 10px;
    }
    .hm-related-title {
        font-size: 0.82rem;
    }
    .hm-section-header h2 {
        font-size: 1.15rem;
    }
    .hm-video-tags {
        gap: 8px;
    }
    .hm-tag {
        font-size: 0.72rem;
        padding: 3px 8px;
    }
}

/* ==========================================
   SCROLLBAR
   ========================================== */
.hm-single-video-page ::-webkit-scrollbar {
    width: 8px;
}
.hm-single-video-page ::-webkit-scrollbar-track {
    background: var(--hm-bg-primary);
}
.hm-single-video-page ::-webkit-scrollbar-thumb {
    background: var(--hm-bg-elevated);
    border-radius: 4px;
}
