/* Front-end styles for Vox Core features. */
:root {
    --vxcr-color-text: currentColor;
    --vxcr-color-surface: #ffffff;
    --vxcr-color-surface-soft: rgba(255, 255, 255, 0.76);
    --vxcr-color-border: #000000;
    --vxcr-color-border-soft: rgba(0, 0, 0, 0.08);
    --vxcr-color-muted: rgba(0, 0, 0, 0.58);
    --vxcr-color-soft: rgba(0, 0, 0, 0.05);
    --vxcr-color-progress-soft: rgba(47, 47, 52, 0.18);
    --vxcr-color-accent: #2f2f34;
    --vxcr-color-primary: var(--vxcr-color-accent);
    --vxcr-color-success: #0f7a3a;
    --vxcr-color-success-soft: rgba(15, 122, 58, 0.12);
    --vxcr-color-danger: #b42318;
    --vxcr-color-danger-soft: rgba(180, 35, 24, 0.12);
    --vxcr-color-shadow: rgba(0, 0, 0, 0.08);
}
.vxcr-player-controller,
.vxcr-player-details {
    margin: 1.5rem 0;
}

.vxcr-player-controller {
    display: grid;
    grid-template-columns: auto minmax(0, 1fr);
    align-items: center;
    gap: 1rem;
    padding: 1rem;
    border: 1px solid var(--vxcr-color-border-soft);
    border-radius: 18px;
    background: var(--vxcr-color-surface-soft);
}

.vxcr-player__button,
.vxcr-favorite-toggle,
.vxcr-favorite-card__remove,
.vxcr-player__track-button {
    cursor: pointer;
}

.vxcr-player__button {
    width: 3rem;
    height: 3rem;
    flex: 0 0 3rem;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border: 0;
    border-radius: 999px;
    font-size: 1.1rem;
}

.vxcr-player__icon {
    display: inline-flex;
    align-items: center;
    justify-content: center;
}

.vxcr-player__progress {
    display: grid;
    grid-template-columns: auto minmax(8rem, 1fr) auto;
    align-items: center;
    gap: 0.75rem;
    min-width: 0;
}

.vxcr-player__slider {
    --vxcr-progress: 0%;
    width: 100%;
    min-width: 0;
    cursor: pointer;
    accent-color: currentColor;
}

.vxcr-player__slider::-webkit-slider-runnable-track {
    height: 0.35rem;
    border-radius: 999px;
    background: linear-gradient(to right, currentColor 0 var(--vxcr-progress), var(--vxcr-color-progress-soft) var(--vxcr-progress) 100%);
}

.vxcr-player__slider::-moz-range-track {
    height: 0.35rem;
    border-radius: 999px;
    background: var(--vxcr-color-progress-soft);
}

.vxcr-player__slider::-moz-range-progress {
    height: 0.35rem;
    border-radius: 999px;
    background: currentColor;
}

.vxcr-player__time {
    min-width: 3rem;
    font-size: 0.9rem;
    font-variant-numeric: tabular-nums;
    opacity: 0.75;
}

.vxcr-player__playlist,
.vxcr-player__timeline {
    margin: 0;
    padding: 0;
    list-style: none;
}

.vxcr-player__playlist {
    display: grid;
    gap: 0.6rem;
}

.vxcr-player__track-item {
    display: grid;
    grid-template-columns: 2ch auto minmax(0, 1fr) auto;
    align-items: center;
    gap: 0.75rem;
    padding: 0.65rem 0.75rem;
    border: 1px solid var(--vxcr-color-border-soft);
    border-radius: 14px;
    background: var(--vxcr-color-surface-soft);
}

.vxcr-player__track-number {
    font-variant-numeric: tabular-nums;
    opacity: 0.65;
    text-align: right;
}

.vxcr-player__track-button {
    width: 2rem;
    height: 2rem;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border: 0;
    border-radius: 999px;
}

.vxcr-player__track-button:disabled {
    display: none;
}

.vxcr-player__track-title {
    min-width: 0;
    font-weight: 600;
}

.vxcr-player__track-duration,
.vxcr-favorite-card__duration {
    display: inline-flex;
    align-items: center;
    gap: 0.35rem;
    opacity: 0.72;
    white-space: nowrap;
}

.vxcr-player__timeline {
    position: relative;
    display: grid;
}

.vxcr-player__timeline::before {
    content: "";
    position: absolute;
    top: 1.25rem;
    bottom: 1.25rem;
    left: 1rem;
    width: 2px;
    background: var(--vxcr-color-border);
}

.vxcr-player__timeline-item {
    position: relative;
    display: grid;
    grid-template-columns: 2rem minmax(0, 1fr);
    align-items: center;
    gap: 1rem;
    padding: 0.65rem 0;
}

.vxcr-player__timeline-marker {
    position: relative;
    z-index: 1;
    width: 2rem;
    height: 2rem;
    display: grid;
    place-items: center;
    border-radius: 999px;
    background: var(--vxcr-color-surface);
    box-shadow: 0 0 0 1px var(--vxcr-color-border);
}

.vxcr-player__timeline-content {
    display: grid;
    gap: 0.25rem;
    padding: 0.7rem 0.85rem;
    border: 1px solid var(--vxcr-color-border-soft);
    border-radius: 16px;
    background: var(--vxcr-color-surface-soft);
}

.vxcr-player__timeline-item.is-locked .vxcr-player__timeline-content {
    opacity: 0.58;
}

.vxcr-player__timeline-item.is-completed .vxcr-player__timeline-marker {
    box-shadow: 0 0 0 2px currentColor;
}

.vxcr-player__slot {
    font-size: 0.82rem;
    font-weight: 700;
    opacity: 0.68;
    text-transform: uppercase;
    letter-spacing: 0.04em;
}

.vxcr-hero-favorite {
    display: inline-flex;
    justify-content: flex-end;
    width: auto;
    margin-left: 0.75rem;
    vertical-align: middle;
}

.vxcr-favorite-toggle {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    width: fit-content;
    max-width: none;
    min-width: auto;
    align-self: flex-start;
    margin: 0 0 1.25rem;
    padding: 0.65rem 1rem;
    border: 1px solid var(--vxcr-color-border);
    border-radius: 999px;
    background: transparent;
    color: inherit;
    transition: transform 160ms ease, box-shadow 160ms ease, border-color 160ms ease, background-color 160ms ease;
}

.vxcr-favorite-toggle:hover,
.vxcr-favorite-toggle:focus-visible {
    transform: translateY(-1px);
    box-shadow: 0 10px 24px var(--vxcr-color-border-soft);
}

.vxcr-favorite-toggle__icon {
    color: var(--vxcr-color-muted);
    font-size: 1.2rem;
    line-height: 1;
}

.vxcr-favorite-toggle.is-favorite .vxcr-favorite-toggle__icon {
    color: currentColor;
    font-weight: 700;
}

.vxcr-favorites-grid {
    display: grid;
    grid-template-columns: 1fr;
    gap: 1.25rem;
}

@media (min-width: 640px) {
    .vxcr-favorites-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }
}

@media (min-width: 1024px) {
    .vxcr-favorites-grid {
        grid-template-columns: repeat(3, minmax(0, 1fr));
    }
}

.vxcr-favorite-card {
    position: relative;
    overflow: hidden;
    border: 1px solid var(--vxcr-color-border-soft);
    border-radius: 20px;
    background: var(--vxcr-color-surface);
    box-shadow: 0 12px 32px var(--vxcr-color-soft);
}

.vxcr-favorite-card__remove {
    position: absolute;
    top: 0.75rem;
    right: 0.75rem;
    z-index: 2;
    width: 2.25rem;
    height: 2.25rem;
    border: 0;
    border-radius: 999px;
    background: var(--vxcr-color-surface-soft);
    font-size: 1.4rem;
    line-height: 1;
}

.vxcr-favorite-card__image {
    display: block;
    aspect-ratio: 16 / 10;
    overflow: hidden;
    background: var(--vxcr-color-soft);
}

.vxcr-favorite-card__image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
}

.vxcr-favorite-card__placeholder {
    width: 100%;
    height: 100%;
    display: grid;
    place-items: center;
    font-size: 3rem;
}

.vxcr-favorite-card__body {
    display: grid;
    gap: 0.5rem;
    padding: 1rem;
}

.vxcr-favorite-card__title {
    margin: 0;
    font-size: 1.05rem;
}

.vxcr-favorite-card__duration,
.vxcr-favorite-card__terms p {
    margin: 0;
}

.vxcr-favorite-card__terms {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
    font-size: 0.9rem;
}

.vxcr-favorite-card__terms p {
    padding: 0.25rem 0.55rem;
    border-radius: 999px;
    background: var(--vxcr-color-soft);
}

.vxcr-account-fields {
    margin: 1.5rem 0;
    padding: 0;
    border: 0;
}

.vxcr-account-sex {
    display: grid;
    gap: 0.45rem;
}

.vxcr-account-label {
    font-weight: 600;
}

.vxcr-account-options {
    display: inline-flex;
    align-items: center;
    gap: 1rem;
}

.vxcr-account-options label {
    display: inline-flex;
    align-items: center;
    gap: 0.35rem;
    margin: 0;
    line-height: 1;
}

.vxcr-account-options input[type="radio"] {
    margin: 0;
}

.woocommerce-MyAccount-navigation-link--vox-favorites a::before,
.woocommerce-MyAccount-navigation-link--vox-history a::before {
    display: inline-block;
    margin-right: 0.45rem;
    font-family: dashicons !important;
    vertical-align: -0.1em;
}

.woocommerce-MyAccount-navigation-link--vox-favorites a::before {
    content: "\f487" !important;
}

.woocommerce-MyAccount-navigation-link--vox-history a::before {
    content: "\f321" !important;
}

.vxcr-history {
    display: grid;
    gap: 1.25rem;
}

.vxcr-history__stats {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 1rem;
}

.vxcr-history-stat {
    display: grid;
    gap: 0.35rem;
    padding: 1rem;
    border: 1px solid var(--vxcr-color-border-soft);
    border-radius: 18px;
    background: var(--vxcr-color-surface-soft);
}

.vxcr-history-stat strong {
    font-size: clamp(1.6rem, 4vw, 2.4rem);
    line-height: 1;
}

.vxcr-history__filters {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
}

.vxcr-history__filter {
    display: inline-flex;
    padding: 0.45rem 0.8rem;
    border: 1px solid var(--vxcr-color-border);
    border-radius: 999px;
    text-decoration: none;
}

.vxcr-history__filter.is-active {
    font-weight: 700;
}

.vxcr-history__list {
    display: grid;
    gap: 0.75rem;
}

.vxcr-history-item {
    display: grid;
    grid-template-columns: 4rem 4.5rem minmax(0, 1fr);
    align-items: center;
    gap: 1rem;
    padding: 0.75rem;
    border: 1px solid var(--vxcr-color-border-soft);
    border-radius: 18px;
    background: var(--vxcr-color-surface-soft);
}

.vxcr-history-item__date {
    display: grid;
    place-items: center;
    padding: 0.5rem;
    border-radius: 14px;
    background: var(--vxcr-color-soft);
    text-decoration: none;
}

.vxcr-history-item__date strong {
    font-size: 1.5rem;
    line-height: 1;
}

.vxcr-history-item__date span {
    font-size: 0.8rem;
    text-transform: uppercase;
}

.vxcr-history-item__image {
    width: 4.5rem;
    height: 4.5rem;
    overflow: hidden;
    border-radius: 14px;
    background: var(--vxcr-color-soft);
}

.vxcr-history-item__image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
}

.vxcr-history-item__content h3,
.vxcr-history-item__content p {
    margin: 0;
}

.vxcr-history-item__content {
    display: grid;
    gap: 0.25rem;
}

@media (max-width: 640px) {
    .vxcr-player-controller {
        grid-template-columns: auto minmax(0, 1fr);
        gap: 0.75rem;
        padding: 0.75rem;
    }

    .vxcr-player__progress {
        grid-template-columns: auto minmax(0, 1fr) auto;
        gap: 0.5rem;
    }

    .vxcr-player__time {
        min-width: 2.4rem;
        font-size: 0.8rem;
    }

    .vxcr-player__track-item {
        grid-template-columns: 2ch auto minmax(0, 1fr);
    }

    .vxcr-player__track-duration {
        grid-column: 3;
    }

    .vxcr-history__stats,
    .vxcr-history-item {
        grid-template-columns: 1fr;
    }

    .vxcr-history-item__image {
        width: 100%;
        height: auto;
        aspect-ratio: 16 / 9;
    }
}

