.thumbnail
{
    position: relative;
}

.thumbnail img
{
    background-repeat: no-repeat;
    /* Hidden until JS marks the image as loaded; fade in once the bytes
       are decoded. .img-loaded on the parent <a> hides the spinner. */
    opacity: 0;
    transition: opacity 280ms ease;
}
.thumbnail img.loaded
{
    opacity: 1;
}

/* CSS-only spinner shown behind the image while it's loading. Hidden
   once the parent gains .img-loaded. The img itself is opaque on top
   once decoded, so the spinner naturally disappears under the cover
   even before the opacity-0 transition completes. */
.thumbnail::before
{
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    width: 28px;
    height: 28px;
    margin: -14px 0 0 -14px;
    border: 2px solid rgba(255, 255, 255, 0.08);
    border-top-color: #888;
    border-radius: 50%;
    animation: cv-thumb-spin 700ms linear infinite;
    z-index: 0;
    pointer-events: none;
    opacity: 1;
    transition: opacity 200ms ease;
}
.thumbnail.img-loaded::before
{
    opacity: 0;
}

@keyframes cv-thumb-spin
{
    to { transform: rotate(360deg); }
}

.thumbnail video
{
    position: absolute;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: none;
    /* The hover preview must never absorb clicks — the surrounding <a>
       is the navigation target and the .upper / .lower / .badges /
       .messages overlays sit on top of this and need to remain
       hover-active. */
    pointer-events: none;
}

.thumbnail:hover video
{
    display: inline-block;
}

.content-container .leftnav
{
    display: table-cell;
    width: 230px;
    background: #161616;
    background: -moz-linear-gradient(left,  #161616 0%, #141414 100%);
    background: -webkit-linear-gradient(left,  #161616 0%,#141414 100%);
    background: linear-gradient(to right,  #161616 0%,#141414 100%);
    filter: progid:DXImageTransform.Microsoft.gradient( startColorstr='#161616', endColorstr='#141414',GradientType=1 );
    border-right: 1px solid #a30000;
    padding-top: 20px;
    vertical-align: top;
}

.content-container .leftnav ul
{
    margin: 0;
    padding: 0;
    list-style: none;
    padding-left: 10px;
    padding-right: 10px;
    padding-bottom: 25px;
}

.content-container .leftnav li
{
    line-height: 2em;
    padding-left: 0.5em;
    border-radius: 3px;
    border-bottom: 1px solid #444343;
}

.content-container .leftnav li a
{
    display: inline-block;
    width: 100%;
    color: #e6e6e6;
}

.content-container .leftnav li a:hover,
.content-container .leftnav li a:active,
.content-container .leftnav li a:focus
{
    color: #b2b2b2;
    text-decoration: none;
}

.content-container .leftnav li:hover
{
    background-color: #900000;
    cursor: pointer;
}

.content-container .content-body
{
    display: table-cell;
    padding-top: 20px;
    background-color: #252525;
}

.content-container .leftnav iframe
{
    width: 100%;
}

.button-bar
{
    margin-bottom: 10px;
}

.vjs-loading .vjs-loading-spinner
{
    display: block !important;;
}

.vjs-loading .vjs-loading-spinner:before,
.vjs-loading .vjs-loading-spinner:after
{
    -webkit-animation: vjs-spinner-spin 1.1s cubic-bezier(0.6, 0.2, 0, 0.8) infinite, vjs-spinner-fade 1.1s linear infinite;
    animation: vjs-spinner-spin 1.1s cubic-bezier(0.6, 0.2, 0, 0.8) infinite, vjs-spinner-fade 1.1s linear infinite;
}

.vjs-watermark
{
    position: absolute;
    display: inline;
    z-index: 500;
}

.btn-link
{
    color: white;
}

.monospaced
{
    font-family: monospace;
}

.premiumcolor
{
    color: gold;
}

.radio input[type="radio"],
.radio-inline input[type="radio"],
.checkbox input[type="checkbox"],
.checkbox-inline input[type="checkbox"]
{
    margin-left: 0;
}

.show-dots
{
    display: inline-block;
    text-overflow: ellipsis;
    white-space: nowrap;
    overflow: hidden !important;
    padding-right: 10px;
    width: 100%;
}

/* ─── Chunked download manager (Plan 2, super-only beta) ─── */

/*
 * Class-only rules (apply in BOTH the floating widget and the
 * /downloads page) handle text + tap-target sizing. The container-
 * scoped rules below handle layout/positioning/visibility only.
 *
 * Font sizes use explicit px (not rem). Bootstrap 3 sets html
 * { font-size: 10px }, so 1rem = 10px — way below the body's 14px
 * floor. Using px keeps sizing predictable: body's 14px is the
 * minimum (matches the rest of the site), 15-16px for emphasis, 18px
 * for section headers.
 */

.cv-dl-row
{
    padding: 16px;
    border-bottom: 1px solid #2a2a2a;
    font-size: 14px;
}

.cv-dl-row.cv-dl-failed
{
    border-left: 4px solid #c00;
}

.cv-dl-row.cv-dl-completed
{
    border-left: 4px solid #0a0;
}

.cv-dl-row-name
{
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
    word-break: break-all;
    margin-bottom: 8px;
    font-size: 15px;
}

.cv-dl-row-bottom
{
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-top: 8px;
    font-size: 14px;
}

.cv-dl-row-meta
{
    font-size: 14px;
}

.cv-dl-row-controls
{
    display: flex;
    gap: 8px;
}

.cv-dl-btn
{
    min-width: 44px;
    min-height: 44px;
    padding: 8px 12px;
    background: transparent;
    color: #f0f0f0;
    border: 1px solid #444;
    border-radius: 4px;
    cursor: pointer;
    font-size: 14px;
}

.cv-dl-btn:hover
{
    background: #2a2a2a;
}

.cv-dl-progress
{
    margin: 0;
    height: 8px;
    background: #2a2a2a;
}

.cv-dl-progress > .progress-bar
{
    height: 100%;
}

/* Widget container (floating bar/sheet) */

#cv-downloads
{
    display: none;                 /* hidden until first download */
    font-size: 14px;               /* override Bootstrap shrinkage */
}

#cv-downloads.cv-dl-visible
{
    display: block;
}

#cv-downloads .cv-dl-bar
{
    position: fixed;
    bottom: 0;
    left: 0;
    right: 0;
    background: #1a1a1a;
    color: #f0f0f0;
    padding: 12px 16px;
    border-top: 1px solid #333;
    cursor: pointer;
    z-index: 10000;
    font-size: 15px;
}

#cv-downloads .cv-dl-bar-summary
{
    display: flex;
    justify-content: space-between;
    align-items: center;
    font-size: 15px;
}

#cv-downloads .cv-dl-bar-label,
#cv-downloads .cv-dl-bar-count
{
    font-size: 14px;
}

#cv-downloads .cv-dl-sheet
{
    display: none;
    position: fixed;
    bottom: 0;
    left: 0;
    right: 0;
    max-height: 70vh;
    background: #1a1a1a;
    color: #f0f0f0;
    z-index: 10001;
    overflow-y: auto;
    border-top: 1px solid #333;
    font-size: 14px;
}

#cv-downloads.cv-dl-expanded .cv-dl-sheet
{
    display: block;
}

#cv-downloads.cv-dl-expanded .cv-dl-bar
{
    display: none;
}

#cv-downloads .cv-dl-backdrop
{
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.5);
    z-index: 10000;
}

#cv-downloads.cv-dl-expanded .cv-dl-backdrop
{
    display: block;
}

#cv-downloads .cv-dl-sheet-header
{
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 16px;
    border-bottom: 1px solid #333;
    font-size: 16px;
}

@media (min-width: 768px)
{
    #cv-downloads .cv-dl-bar,
    #cv-downloads .cv-dl-sheet
    {
        position: fixed;
        bottom: 16px;
        right: 16px;
        left: auto;
        max-width: 380px;
        width: 380px;
        border-radius: 4px;
        max-height: 60vh;
    }

    #cv-downloads .cv-dl-backdrop
    {
        display: none !important;   /* no dimming on desktop */
    }
}

/* /downloads page sections */

#cv-downloads-page
{
    font-size: 14px;
}

#cv-downloads-page .cv-dl-page-section
{
    margin: 24px 0;
}

#cv-downloads-page .cv-dl-page-section-header
{
    font-size: 18px;
    border-bottom: 1px solid #333;
    padding-bottom: 8px;
    cursor: pointer;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

#cv-downloads-page .cv-dl-page-section.collapsed .cv-dl-page-rows
{
    display: none;
}

#cv-downloads-page .cv-dl-btn-clear
{
    margin-left: auto;
    background: transparent;
    border: 1px solid #444;
    font-size: 14px;
}
