/*
Theme Name: Xotlist
Theme URI: https://xotlist.com
Author: Xotlist
Description: Clean, fast media theme built with CSS Grid and native WordPress templates.
Version: 1.0.2
License: GNU General Public License v2 or later
Text Domain: xotlist
*/

/* =========================================
   RESET & BASE
========================================= */

*, *::before, *::after {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

/* Kill WordPress admin bar offset and any body gap */
html { margin-top: 0 !important; }
body { margin-top: 0 !important; }
#wpadminbar { display: none !important; }

.site-content { padding: 0 !important; margin: 0 !important; }

/* Global focus reset — prevent browser default outlines on pagination etc */
.page-numbers:focus,
.page-numbers:focus-visible,
a.page-numbers:focus,
a.page-numbers:focus-visible,
span.page-numbers:focus,
span.page-numbers:focus-visible {
    outline: none !important;
    box-shadow: none !important;
}

:root {
    --color-bg:         #ffffff;
    --color-surface:    #f5f5f5;
    --color-border:     #e0e0e0;
    --color-text:       #111111;
    --color-muted:      #666666;
    --color-accent:     #e63946;
    --color-accent-hover: #c1121f;

    --font-primary:     'Inter', system-ui, sans-serif;
    --font-size-base:   16px;
    --line-height-base: 1.6;

    --spacing-xs:  0.25rem;
    --spacing-sm:  0.5rem;
    --spacing-md:  1rem;
    --spacing-lg:  2rem;
    --spacing-xl:  4rem;

    --max-width:   1200px;
    --gap:         1.5rem;
}

html {
    font-size: var(--font-size-base);
    scroll-behavior: smooth;
}

body {
    font-family: var(--font-primary);
    background-color: #ffffff;
    color: var(--color-text);
    line-height: var(--line-height-base);
    -webkit-font-smoothing: antialiased;
}

img, video {
    max-width: 100%;
    height: auto;
    display: block;
}

a {
    color: inherit;
    text-decoration: none;
}

a:hover {
    color: var(--color-accent);
}

/* =========================================
   SITE LAYOUT — CSS GRID
========================================= */

.site {
    display: block;
    min-height: 100vh;
}

.container {
    width: 100%;
    max-width: var(--max-width);
    margin-inline: auto;
    padding-inline: var(--spacing-lg);
}

/* Main content + optional sidebar */
.site-content {
    padding-block: 0;
}

.content-area {
    display: block;
    max-width: var(--max-width);
    margin-inline: auto;
    padding-inline: var(--spacing-lg);
}

/* Full width — no sidebar */
.content-area.full-width {
    display: block;
}

/* Always hide WordPress sidebar on single posts */
body.single #secondary,
body.single .widget-area,
body.single aside.sidebar {
    display: none !important;
}

/* Header styling is owned entirely by header.php inline styles */

.site-branding a:hover {
    color: var(--color-accent);
}

/* =========================================
   NAVIGATION
========================================= */

.main-navigation ul {
    list-style: none;
    display: flex;
    gap: var(--spacing-lg);
}

.main-navigation a {
    font-size: 0.9rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    color: var(--color-text);
    transition: color 0.2s;
}

.main-navigation a:hover,
.main-navigation .current-menu-item a {
    color: var(--color-accent);
}

/* =========================================
   POST CARDS — CSS GRID
========================================= */

.post-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
    gap: var(--gap);
}

/* Featured / hero — spans full width */
.post-grid .post-card--featured {
    grid-column: 1 / -1;
}

.post-card {
    background: #ffffff;
    border: 1px solid var(--color-border);
    border-radius: 6px;
    overflow: hidden;
    transition: box-shadow 0.2s;
}

.post-card:hover {
    box-shadow: 0 4px 16px rgba(0,0,0,0.08);
}

.post-card__title a {
    color: var(--color-text);
}

.post-card__meta {
    font-size: 0.8rem;
    color: var(--color-muted);
}

.post-card__thumbnail img {
    width: 100%;
    aspect-ratio: 16 / 9;
    object-fit: cover;
}

.post-card__body {
    padding: var(--spacing-md);
}

.post-card__category {
    display: inline-block;
    font-size: 0.7rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 1px;
    color: var(--color-accent);
    margin-bottom: var(--spacing-xs);
}

.post-card__title {
    font-size: 1.05rem;
    font-weight: 700;
    line-height: 1.3;
    margin-bottom: var(--spacing-sm);
}

.post-card__title a:hover {
    color: var(--color-accent);
}

.post-card__meta {
    font-size: 0.8rem;
    color: var(--color-muted);
}

/* =========================================
   SINGLE POST
========================================= */

.entry-header {
    margin-bottom: var(--spacing-lg);
}

.entry-title {
    font-size: clamp(1.6rem, 4vw, 2.4rem);
    font-weight: 800;
    line-height: 1.2;
    margin-bottom: var(--spacing-sm);
}

.entry-meta {
    font-size: 0.85rem;
    color: var(--color-muted);
}

.entry-thumbnail {
    margin-bottom: var(--spacing-lg);
    border-radius: 6px;
    overflow: hidden;
}

.entry-content {
    max-width: 720px;
}

.entry-content p {
    margin-bottom: var(--spacing-md);
}

.entry-content h2,
.entry-content h3,
.entry-content h4 {
    font-weight: 700;
    line-height: 1.3;
    margin-block: var(--spacing-lg) var(--spacing-sm);
}

.entry-content h2 { font-size: 1.6rem; }
.entry-content h3 { font-size: 1.3rem; }
.entry-content h4 { font-size: 1.1rem; }

/* =========================================
   SIDEBAR
========================================= */

.widget-area {
    display: flex;
    flex-direction: column;
    gap: var(--spacing-lg);
}

.widget {
    background: var(--color-surface);
    border-radius: 6px;
    padding: var(--spacing-md);
}

.widget-title {
    font-size: 0.75rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 1px;
    margin-bottom: var(--spacing-md);
    padding-bottom: var(--spacing-sm);
    border-bottom: 2px solid var(--color-accent);
}

/* =========================================
   FOOTER
========================================= */

.site-footer {
    background-color: var(--color-text);
    color: #cccccc;
    padding-block: var(--spacing-lg);
    margin-top: var(--spacing-xl);
    font-size: 0.85rem;
}

.site-footer .container {
    display: flex;
    align-items: center;
    justify-content: space-between;
    flex-wrap: wrap;
    gap: var(--spacing-md);
}

.site-footer a {
    color: #cccccc;
}

.site-footer a:hover {
    color: var(--color-accent);
}

.footer-nav ul {
    list-style: none;
    display: flex;
    gap: var(--spacing-lg);
}

/* =========================================
   HERO — Homepage featured post
========================================= */

.hero {
    background-color: #111111;
    color: #ffffff;
    padding: 3rem 0 0;
}

.hero__inner {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: var(--spacing-xl);
    align-items: center;
    max-width: var(--max-width);
    margin-inline: auto;
    padding-inline: var(--spacing-lg);
}

.hero__image {
    border-radius: 8px;
    overflow: hidden;
}

.hero__image img {
    width: 100%;
    aspect-ratio: 16 / 9;
    object-fit: cover;
    transition: transform 0.3s ease;
}

.hero__image:hover img {
    transform: scale(1.02);
}

.hero__category {
    display: inline-block;
    font-size: 0.7rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 1.5px;
    color: var(--color-accent);
    margin-bottom: var(--spacing-sm);
}

.hero__title {
    font-size: clamp(1.6rem, 3vw, 2.4rem);
    font-weight: 800;
    line-height: 1.2;
    margin-bottom: var(--spacing-md);
}

.hero__title a {
    color: #ffffff;
}

.hero__title a:hover {
    color: var(--color-accent);
}

.hero__excerpt {
    font-size: 1rem;
    color: #cccccc;
    line-height: 1.6;
    margin-bottom: var(--spacing-md);
}

.hero__meta {
    font-size: 0.8rem;
    color: #999999;
}

/* =========================================
   HOME GRID SECTION
========================================= */

.home-grid {
    background-color: #ffffff;
    padding: 2rem 0 3rem;
}

/* =========================================
   UTILITY
========================================= */

.screen-reader-text {
    position: absolute;
    width: 1px;
    height: 1px;
    overflow: hidden;
    clip: rect(0,0,0,0);
    white-space: nowrap;
}

/* =========================================
   RESPONSIVE
========================================= */

@media (max-width: 768px) {
    .content-area {
        display: block;
    }

    .main-navigation {
        display: none; /* swap for mobile menu later */
    }

    .site-footer .container {
        flex-direction: column;
        text-align: center;
    }

    .hero__inner {
        grid-template-columns: 1fr;
    }

    .hero__image {
        order: -1;
    }
}

/* ═══ Single page - force article full width on all breakpoints ═══ */
body.single .site-content {
    display: block !important;
    padding: 0 !important;
}

/* Kill the floating author/widget card that WordPress injects */
body.single .wp-block-columns,
body.single .elementor-widget-author-box,
body.single .elementor-column:not(:first-child),
body.single .author-box,
body.single [class*="author-box"],
body.single [class*="author-card"] {
    display: none !important;
}

/* =========================================
   SINGLE ARTICLE PAGE — xot-single-page
   All single post styles live here.
   single.php has ZERO inline CSS.
========================================= */

/* ── Page wrapper: full width, no sidebar ── */
#xot-single-page {
    width: 100%;
}

/* ── Main container ── */
.xot-main {
    width: 100%;
    max-width: 100%;
}

/* ── Article: centred reading column ── */
.xot-article {
    max-width: 720px;
    width: 100%;
    margin: 0 auto;
    padding: 1.5rem 1.5rem 3rem;
    box-sizing: border-box;
}

/* ── Scroll progress bar ── */
#read-progress {
    position: fixed;
    top: 0;
    left: 0;
    height: 3px;
    width: 0%;
    background: #e63946;
    z-index: 9999;
    transition: width 0.1s linear;
    pointer-events: none;
}

/* ── Breadcrumbs ── */
.xot-breadcrumbs {
    font-size: 0.78rem;
    color: #999;
    margin-bottom: 1rem;
    display: flex;
    align-items: center;
    gap: 0.35rem;
    flex-wrap: wrap;
}
.xot-breadcrumbs a { color: #999; text-decoration: none; }
.xot-breadcrumbs a:hover { color: #e63946; }
.xot-breadcrumbs__sep { color: #ccc; }

/* ── Title ── */
.xot-article__title {
    font-size: clamp(1.6rem, 4vw, 2.4rem);
    font-weight: 900;
    line-height: 1.2;
    color: #111;
    letter-spacing: -0.03em;
    margin: 0 0 1.1rem;
}

/* ── Meta row ── */
.xot-article__meta {
    display: flex;
    align-items: center;
    justify-content: space-between;
    flex-wrap: wrap;
    gap: 0.75rem;
    margin-bottom: 1.25rem;
    padding-bottom: 1rem;
    border-bottom: 1px solid #f0f0f0;
}
.xot-article__meta-left {
    display: flex;
    align-items: center;
    flex-wrap: wrap;
    gap: 0.4rem;
    font-size: 0.78rem;
    color: #888;
    min-width: 0;
}
.xot-author-avatar {
    width: 30px;
    height: 30px;
    border-radius: 50%;
    background: #111;
    color: #fff;
    font-size: 0.8rem;
    font-weight: 800;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
}
.xot-author-name { font-weight: 600; color: #333; }
.xot-meta-sep { color: #ddd; }
.xot-updated-label { color: #aaa; font-style: italic; }
.xot-read-time { display: flex; align-items: center; gap: 3px; }
.xot-live-readers { display: flex; align-items: center; gap: 4px; }
.xot-live-readers__dot {
    width: 6px; height: 6px;
    border-radius: 50%;
    background: #22c55e;
    display: inline-block;
    animation: xot-pulse 2s ease-in-out infinite;
}
@keyframes xot-pulse {
    0%, 100% { opacity: 1; }
    50%       { opacity: 0.4; }
}

/* ── Action buttons ── */
.xot-article__actions {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    flex-shrink: 0;
}
.xot-btn {
    display: inline-flex;
    align-items: center;
    gap: 0.35rem;
    cursor: pointer;
    border: none;
    font-family: inherit;
}
.xot-btn--listen {
    padding: 0.38rem 0.8rem;
    border-radius: 999px;
    font-size: 0.72rem;
    font-weight: 700;
    letter-spacing: 0.4px;
    text-transform: uppercase;
    color: #222;
}
.xot-btn--listen.playing {
    background: rgba(230,57,70,0.1) !important;
    border-color: rgba(230,57,70,0.3) !important;
    color: #e63946;
}
.xot-btn--share {
    width: 36px;
    height: 36px;
    border-radius: 50%;
    justify-content: center;
    color: #333;
    padding: 0;
}

/* Clean pill button — replaces glass morphism */
.xot-glass {
    background: #f2f2f2;
    border: 1px solid #e0e0e0;
    transition: background 0.15s, border-color 0.15s, transform 0.15s;
}
.xot-glass:hover {
    background: #e8e8e8;
    border-color: #cccccc;
    transform: translateY(-1px);
}
.xot-glass:active { transform: scale(0.97); }

/* ── Share dropdown ── */
.xot-share-wrap { position: relative; }
.xot-share-menu {
    display: none;
    position: absolute;
    right: 0;
    top: calc(100% + 8px);
    background: #ffffff;
    border: 1px solid #e8e8e8;
    border-radius: 10px;
    box-shadow: 0 8px 32px rgba(0,0,0,.12);
    min-width: 165px;
    z-index: 9999;
    overflow: hidden;
    transform-origin: top right;
    animation: xot-menu-pop 0.18s ease;
}
.xot-share-menu.open { display: block; }
@keyframes xot-menu-pop {
    from { opacity: 0; transform: scale(0.94) translateY(-4px); }
    to   { opacity: 1; transform: scale(1) translateY(0); }
}
.xot-share-backdrop {
    position: fixed;
    inset: 0;
    z-index: 9998;
    background: rgba(0,0,0,.3);
}
.xot-share-item {
    display: flex;
    align-items: center;
    gap: 0.55rem;
    width: 100%;
    padding: 0.65rem 1rem;
    font-size: 0.8rem;
    font-weight: 600;
    color: #222;
    background: none;
    border: none;
    border-bottom: 1px solid rgba(0,0,0,.05);
    cursor: pointer;
    text-decoration: none;
    font-family: inherit;
    transition: background 0.1s;
}
.xot-share-item:last-child { border-bottom: none; }
.xot-share-item:hover { background: rgba(0,0,0,.04); }
.xot-share-item--x   svg { color: #000; }
.xot-share-item--fb  svg { color: #1877f2; }
.xot-share-item--wa  svg { color: #25d366; }
.xot-share-item--copy svg { color: #666; }

/* Mobile: bottom sheet */
@media (max-width: 600px) {
    .xot-share-menu {
        position: fixed;
        right: 0; left: 0; bottom: 0; top: auto;
        border-radius: 16px 16px 0 0;
        min-width: 0; width: 100%;
        box-shadow: 0 -4px 32px rgba(0,0,0,.15);
        border-top: 1px solid rgba(255,255,255,.7);
        padding-bottom: env(safe-area-inset-bottom, 12px);
        z-index: 99999;
    }
    .xot-share-menu::before {
        content: '';
        display: block;
        width: 36px; height: 4px;
        background: #ddd; border-radius: 2px;
        margin: 10px auto 4px;
    }
    .xot-share-item { padding: 0.9rem 1.25rem; font-size: 0.9rem; }
}

/* ── Hero image ── */
.xot-article__hero {
    margin: 1.25rem 0 1.75rem;
    border-radius: 10px;
    overflow: hidden;
    width: 100%;
    max-height: 440px;
}
.xot-article__hero img {
    width: 100%;
    height: 100%;
    max-height: 440px;
    object-fit: cover;
    object-position: center top;
    display: block;
}
.xot-article__hero-caption {
    font-size: 0.75rem;
    color: #999;
    text-align: center;
    padding: 0.5rem 0 0;
    font-style: italic;
}

/* ── Article body ── */
.xot-article__body {
    font-size: 1.05rem;
    line-height: 1.75;
    color: #1a1a1a;
    word-wrap: break-word;
    overflow-wrap: break-word;
    /* Critical: prevents one-word-per-line */
    min-width: 0;
    width: 100%;
}
.xot-article__body p  { margin-bottom: 1.4rem; }
.xot-article__body h2 { font-size: 1.4rem; font-weight: 800; color: #111; margin: 2.5rem 0 0.85rem; line-height: 1.3; }
.xot-article__body h3 { font-size: 1.2rem; font-weight: 700; color: #111; margin: 2rem 0 0.75rem; }
.xot-article__body a  { color: #e63946; text-decoration: underline; }
.xot-article__body img { max-width: 100%; height: auto; border-radius: 6px; margin: 1.5rem 0; display: block; }
.xot-article__body blockquote {
    border-left: 3px solid #e63946;
    margin: 2rem 0;
    padding: 0.75rem 1.25rem;
    background: #fafafa;
    font-style: italic;
    color: #555;
    border-radius: 0 6px 6px 0;
}

/* ── Tags ── */
.xot-article__tags {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
    margin: 2rem 0;
    padding-top: 1.5rem;
    border-top: 1px solid #f0f0f0;
}
.xot-tag {
    display: inline-flex;
    align-items: center;
    padding: 0.25rem 0.7rem;
    background: #f5f5f5;
    border-radius: 999px;
    font-size: 0.75rem;
    font-weight: 600;
    color: #555;
    text-decoration: none;
    transition: all 0.15s;
}
.xot-tag:hover { background: #e63946; color: #fff; }

/* ── Author bio ── */
.xot-author-bio {
    display: flex;
    align-items: flex-start;
    gap: 1rem;
    margin-top: 2rem;
    padding: 1.25rem;
    background: #f9f9f9;
    border: 1px solid #eee;
    border-radius: 10px;
}
.xot-author-bio__avatar {
    width: 48px; height: 48px;
    border-radius: 50%;
    background: #111; color: #fff;
    font-size: 1rem; font-weight: 800;
    display: flex; align-items: center; justify-content: center;
    flex-shrink: 0;
}
.xot-author-bio__name { font-weight: 700; font-size: 0.9rem; color: #111; margin-bottom: 2px; }
.xot-author-bio__role { font-size: 0.72rem; color: #e63946; font-weight: 600; text-transform: uppercase; letter-spacing: 0.5px; margin-bottom: 0.4rem; }
.xot-author-bio__desc { font-size: 0.82rem; color: #666; line-height: 1.55; margin: 0; }

/* ── Related Stories ── */
.xot-related {
    background: #f8f8f8;
    padding: 2.5rem 0 3rem;
}
.xot-related__inner {
    max-width: 1100px;
    margin: 0 auto;
    padding: 0 1.5rem;
}
.xot-related__header {
    display: flex;
    align-items: center;
    gap: 1rem;
    margin-bottom: 1.75rem;
    justify-content: center;
}
.xot-related__rule { flex: 1; height: 1px; background: #e0e0e0; max-width: 100px; }
.xot-related__title {
    font-size: 0.7rem;
    font-weight: 800;
    text-transform: uppercase;
    letter-spacing: 2px;
    color: #111;
    white-space: nowrap;
}
.xot-related__grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 1.25rem;
}
.xot-related-card {
    text-decoration: none;
    display: block;
    border-radius: 8px;
    overflow: hidden;
    background: #fff;
    border: 1px solid #eee;
    transition: transform 0.2s, box-shadow 0.2s;
}
.xot-related-card:hover { transform: translateY(-3px); box-shadow: 0 8px 24px rgba(0,0,0,.1); }
.xot-related-card__img img { width: 100%; height: 160px; object-fit: cover; display: block; }
.xot-related-card__body { padding: 0.9rem; }
.xot-related-card__cat {
    display: inline-block;
    font-size: 0.6rem;
    font-weight: 800;
    text-transform: uppercase;
    letter-spacing: 1px;
    color: #e63946;
    margin-bottom: 0.4rem;
}
.xot-related-card__title { font-size: 0.88rem; font-weight: 700; color: #111; line-height: 1.4; }

/* ── You May Also Like ── */
.xot-ymal { background: #f8f8f8; padding: 3rem 0 3.5rem; overflow: hidden; }
.xot-ymal__inner { max-width: 1100px; margin: 0 auto; padding: 0 2rem; position: relative; }
.xot-ymal__header { display: flex; align-items: center; gap: 1rem; margin-bottom: 2rem; justify-content: center; }
.xot-ymal__rule { flex: 1; height: 1px; background: #ddd; max-width: 120px; }
.xot-ymal__title { font-size: 0.72rem; font-weight: 800; text-transform: uppercase; letter-spacing: 2px; color: #111; white-space: nowrap; }
.xot-ymal__track { display: flex; gap: 1.25rem; overflow-x: auto; scroll-snap-type: x mandatory; -webkit-overflow-scrolling: touch; scrollbar-width: none; scroll-behavior: smooth; padding-bottom: 0.5rem; }
.xot-ymal__track::-webkit-scrollbar { display: none; }
.xot-ymal__card { flex: 0 0 calc(33.333% - 0.85rem); scroll-snap-align: start; text-decoration: none; display: block; transition: opacity 0.2s; }
.xot-ymal__card:hover { opacity: 0.82; }
.xot-ymal__img-wrap { position: relative; aspect-ratio: 16/9; overflow: hidden; border-radius: 4px; background: #e0e0e0; margin-bottom: 0.75rem; }
.xot-ymal__img { width: 100%; height: 100%; object-fit: cover; display: block; transition: transform 0.4s; }
.xot-ymal__card:hover .xot-ymal__img { transform: scale(1.04); }
.xot-ymal__img--placeholder { background: #ccc; width: 100%; height: 100%; }
.xot-ymal__cat { position: absolute; top: .6rem; left: .6rem; background: #e63946; color: #fff; font-size: .6rem; font-weight: 800; text-transform: uppercase; letter-spacing: 1px; padding: .2rem .5rem; border-radius: 2px; }
.xot-ymal__body { padding: 0 0.1rem; }
.xot-ymal__card-title { font-size: .92rem; font-weight: 700; color: #111; line-height: 1.35; margin-bottom: .35rem; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.xot-ymal__date { font-size: .72rem; color: #999; }
.xot-ymal__arrow { position: absolute; top: 50%; transform: translateY(-20%); background: #fff; border: 1px solid #e0e0e0; width: 36px; height: 36px; border-radius: 50%; display: flex; align-items: center; justify-content: center; cursor: pointer; z-index: 10; transition: all .2s; box-shadow: 0 2px 8px rgba(0,0,0,.1); }
.xot-ymal__arrow:hover { background: #e63946; border-color: #e63946; color: #fff; }
.xot-ymal__arrow--prev { left: .25rem; }
.xot-ymal__arrow--next { right: .25rem; }

/* ── Back to top ── */
#back-to-top {
    position: fixed;
    bottom: calc(60px + env(safe-area-inset-bottom, 0px) + 56px);
    right: 1rem;
    width: 40px; height: 40px;
    border-radius: 50%;
    background: rgba(17,17,17,0.85);
    color: #fff;
    border: none; cursor: pointer;
    display: flex; align-items: center; justify-content: center;
    opacity: 0; transform: translateY(8px);
    transition: opacity 0.25s, transform 0.25s;
    z-index: 9000;
    pointer-events: none;
}
#back-to-top.visible { opacity: 1; transform: translateY(0); pointer-events: auto; }
#back-to-top:hover { background: #e63946; }

/* ── Reading progress ring ──
   Sits bottom-right, above the mobile nav bar (64px) + safe area */
.xot-progress-ring {
    position: fixed;
    bottom: calc(60px + env(safe-area-inset-bottom, 0px) + 8px);
    right: 1rem;
    z-index: 9100;
    width: 44px; height: 44px;
    opacity: 0; transform: scale(0.8);
    transition: opacity 0.3s, transform 0.3s;
    pointer-events: none;
}
.xot-progress-ring.visible { opacity: 1; transform: scale(1); }
.xot-progress-ring__svg { transform: rotate(-90deg); }
.xot-progress-ring__track { fill: rgba(17,17,17,0.85); stroke: none; }
.xot-progress-ring__bg { fill: none; stroke: rgba(255,255,255,0.12); stroke-width: 3; }
.xot-progress-ring__fill { fill: none; stroke: #e63946; stroke-width: 3; stroke-linecap: round; stroke-dasharray: 113.1; stroke-dashoffset: 113.1; transition: stroke-dashoffset 0.3s ease; }
.xot-progress-ring__pct { position: absolute; inset: 0; display: flex; align-items: center; justify-content: center; font-size: 0.52rem; font-weight: 900; color: #fff; }

/* ── Advanced Audio player bar ── */
.xot-audio-player {
    position: fixed;
    bottom: calc(60px + env(safe-area-inset-bottom, 0px));
    left: 0; right: 0;
    z-index: 9200; /* below cookie banner */
    background: #1a1a1a;
    color: #fff;
    display: none;
    flex-direction: column;
    box-shadow: 0 -4px 32px rgba(0,0,0,0.5);
    border-top: 2px solid #e63946;
}
.xot-audio-player.active { display: flex; }

/* Row 1: title + close */
.xot-audio-player__top {
    display: flex;
    align-items: center;
    gap: 0.6rem;
    padding: 0.55rem 0.85rem 0.25rem;
    min-width: 0;
}
.xot-audio-player__info { flex: 1; min-width: 0; overflow: hidden; }
.xot-audio-player__label { font-size: 0.55rem; font-weight: 700; text-transform: uppercase; letter-spacing: 0.8px; color: rgba(255,255,255,.35); display: block; margin-bottom: 1px; }
.xot-audio-player__title { font-size: 0.78rem; font-weight: 600; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; color: #fff; display: block; }
.xot-audio-player__close {
    background: none; border: none;
    color: rgba(255,255,255,.4); cursor: pointer;
    padding: 4px; border-radius: 4px; flex-shrink: 0;
    display: flex; align-items: center; justify-content: center;
    transition: color 0.15s;
}
.xot-audio-player__close:hover { color: #fff; }

/* Row 2: controls in one tight line */
.xot-audio-player__controls {
    display: flex;
    align-items: center;
    gap: 0.3rem;
    padding: 0 0.85rem 0.25rem;
    flex-wrap: nowrap;
    min-width: 0;
}
.xot-audio-player__play {
    background: #e63946; border: none; border-radius: 50%;
    width: 32px; height: 32px; flex-shrink: 0;
    display: flex; align-items: center; justify-content: center;
    cursor: pointer;
    transition: background 0.15s, transform 0.1s;
}
.xot-audio-player__play:hover  { background: #cc2f3b; }
.xot-audio-player__play:active { transform: scale(0.93); }
.xot-audio-player__ctrl {
    background: none; border: none;
    color: rgba(255,255,255,.55); cursor: pointer;
    padding: 3px; border-radius: 4px; flex-shrink: 0;
    display: flex; align-items: center; justify-content: center;
    transition: color 0.15s;
    line-height: 1;
}
.xot-audio-player__ctrl:hover { color: #fff; }
.xot-audio-player__speed {
    background: rgba(255,255,255,.08);
    border: 1px solid rgba(255,255,255,.12);
    color: rgba(255,255,255,.7);
    font-size: 0.65rem; font-weight: 700;
    cursor: pointer; padding: 2px 6px;
    border-radius: 4px; font-family: inherit;
    white-space: nowrap; flex-shrink: 0;
    transition: all 0.15s;
}
.xot-audio-player__speed:hover { background: rgba(255,255,255,.15); color: #fff; }
.xot-audio-player__vol-wrap {
    display: flex; align-items: center; gap: 4px;
    color: rgba(255,255,255,.4); flex-shrink: 0; margin-left: auto;
}
.xot-audio-player__vol {
    -webkit-appearance: none; appearance: none;
    width: 55px; height: 3px;
    background: rgba(255,255,255,.2);
    border-radius: 2px; cursor: pointer; outline: none;
}
.xot-audio-player__vol::-webkit-slider-thumb {
    -webkit-appearance: none;
    width: 11px; height: 11px;
    border-radius: 50%; background: #fff; cursor: pointer;
}
.xot-audio-player__vol::-moz-range-thumb {
    width: 11px; height: 11px; border: none;
    border-radius: 50%; background: #fff; cursor: pointer;
}

/* Row 3: seek bar */
.xot-audio-player__bottom {
    display: flex; align-items: center; gap: 0.5rem;
    padding: 0 0.85rem 0.55rem;
}
.xot-audio-player__seek {
    flex: 1; height: 3px;
    background: rgba(255,255,255,.15);
    border-radius: 2px; cursor: pointer;
    position: relative; transition: height 0.15s;
}
.xot-audio-player__seek:hover { height: 5px; }
.xot-audio-player__seek-fill {
    height: 100%; width: 0%;
    background: #e63946; border-radius: 2px;
    pointer-events: none;
}
.xot-audio-player__seek-thumb {
    position: absolute; top: 50%;
    transform: translate(-50%, -50%);
    width: 11px; height: 11px;
    border-radius: 50%; background: #fff;
    opacity: 0; pointer-events: none;
    transition: opacity 0.15s;
}
.xot-audio-player__seek:hover .xot-audio-player__seek-thumb { opacity: 1; }
.xot-audio-player__time-cur,
.xot-audio-player__time {
    font-size: 0.62rem; color: rgba(255,255,255,.4);
    flex-shrink: 0; font-variant-numeric: tabular-nums;
    min-width: 28px;
}
.xot-audio-player__time { text-align: right; }

/* Desktop: centered pill */
@media (min-width: 1025px) {
    .xot-audio-player {
        bottom: 0;
        left: 50%; right: auto;
        transform: translateX(-50%);
        width: 100%; max-width: 680px;
        border-radius: 12px 12px 0 0;
        border-left: 1px solid rgba(255,255,255,0.06);
        border-right: 1px solid rgba(255,255,255,0.06);
        z-index: 9200;
    }
}

/* Hide vol on small phones */
@media (max-width: 420px) {
    .xot-audio-player__vol-wrap { display: none; }
}

/* ── Cookie banner — always above everything ── */
.xot-cookie-banner,
#xot-cookie-banner,
.cookie-banner,
.xot-cb {
    z-index: 999999 !important;
}

/* On mobile: lift cookie banner above audio player when active */
@media (max-width: 1024px) {
    body:has(.xot-audio-player.active) .xot-cb {
        bottom: calc(60px + env(safe-area-inset-bottom, 0px) + 115px) !important;
    }
}

/* ── Single page: force full-width, kill any WordPress sidebar ── */
body.single .site-content,
body.single #content,
body.single #primary,
body.single .content-area,
body.single #main,
body.single .site-main {
    width: 100% !important;
    max-width: 100% !important;
    float: none !important;
    display: block !important;
    padding: 0 !important;
    margin: 0 !important;
    box-sizing: border-box !important;
}
body.single #secondary,
body.single .widget-area,
body.single aside,
body.single [class*="sidebar"],
body.single [id*="sidebar"] {
    display: none !important;
    width: 0 !important;
    visibility: hidden !important;
    overflow: hidden !important;
}

/* ── Responsive ── */
@media (max-width: 1024px) {
    .xot-related__grid { grid-template-columns: repeat(3, 1fr); }
}
@media (max-width: 768px) {
    .xot-article { padding: 1rem 1rem 2.5rem; }
    .xot-related__grid { grid-template-columns: repeat(2, 1fr); }
    .xot-ymal__card { flex: 0 0 78vw; }
    .xot-ymal__arrow { display: none; }
    .xot-author-bio { flex-direction: column; align-items: center; text-align: center; }
}
@media (max-width: 480px) {
    .xot-article { padding: 0.75rem 0.85rem 2rem; }
    .xot-article__meta-left { font-size: 0.72rem; }
    .xot-related__grid { grid-template-columns: 1fr; }
    .xot-ymal__card { flex: 0 0 88vw; }
    .xot-progress-ring { bottom: 5rem; right: 3.25rem; }
    #back-to-top { bottom: 5rem; right: 0.75rem; }
}