/* ==========================================================================
   base.css — project-level styles (replaces Canvas theme CSS where possible)
   ========================================================================== */

/* Design System
   Shared CSS custom properties used across all pages
   ========================================================================== */

:root {
    --uv-gold: #0D6EFD;
    --uv-gold-light: #6C757D;
    --uv-gold-dark: #0a58ca;
    --uv-dark: #1a1a2e;
    --uv-dark-soft: #2d2d44;
    --uv-text: #2c2c2c;
    --uv-text-muted: #6C757D;
    --uv-bg-warm: #f8f9fa;
    --uv-border: #dee2e6;
    --uv-shadow-sm: 0 2px 8px rgba(0, 0, 0, 0.06);
    --uv-shadow-md: 0 4px 20px rgba(0, 0, 0, 0.1);
    --uv-shadow-lg: 0 8px 32px rgba(0, 0, 0, 0.14);
    --uv-radius: 6px;
    --uv-transition: 0.3s cubic-bezier(0.25, 0.46, 0.45, 0.94);

    /* Typography scale */
    --uv-fs-h1: 1.6rem;
    --uv-fs-h2: 1.25rem;
    --uv-fs-h3: 1.1rem;
    --uv-fs-h4: 1rem;
    --uv-fs-h5: .92rem;
    --uv-fs-body: .92rem;
    --uv-fs-small: .82rem;
    --uv-fs-xs: .75rem;
    --uv-fs-h1-mobile: 1.4rem;
    --uv-fs-h2-mobile: 1.15rem;
}

/* Ticker / Marquee (was: quotes.css)
   ========================================================================== */

#TickerLineMarquee {
    position: relative;
    width: 100%;
    height: 24px;
    margin: 0 auto;
    white-space: nowrap;
    overflow: hidden;
    box-sizing: border-box;
}

#TickerLineMarquee > div {
    position: absolute;
    top: 0;
    bottom: 0;
    padding-top: 4px;
    padding-bottom: 4px;
    padding-left: 100%;
    animation: marquee 40s linear infinite;
    font-size: .7rem;
}

#TickerLineMarquee > div:hover {
    animation-play-state: paused;
}

@keyframes marquee {
    0%   { opacity: 0; }
    1%   { opacity: 1; transform: translate(0, 0); }
    100% { transform: translate(-100%, 0); }
}

@media (prefers-reduced-motion: reduce) {
    #TickerLineMarquee {
        white-space: normal;
    }

    #TickerLineMarquee > div {
        animation: none;
        padding-left: 0;
    }
}

/* Breadcrumbs — Refined Gold
   ========================================================================== */

.uv-breadcrumb {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: .15rem;
    list-style: none;
    padding: .55rem .85rem;
    margin: 0 0 1.1rem;
    background: #f8f9fa;
    border: 1px solid #dee2e6;
    border-radius: 8px;
    font-size: .8rem;
    font-weight: 500;
    color: #6C757D;
}

.uv-breadcrumb-item a {
    color: #495057;
    text-decoration: none;
    transition: color .2s;
}

.uv-breadcrumb-item a:hover {
    color: #0D6EFD;
}

.uv-breadcrumb-item + .uv-breadcrumb-item::before {
    content: "\203A";
    padding: 0 .35rem;
    color: #0D6EFD;
    font-weight: 600;
    font-size: .875rem;
}

.uv-breadcrumb-item.active {
    color: #1a1a1a;
    font-weight: 600;
}

/* Events Sidebar Cards — used on homepage and expo/org-detail
   ========================================================================== */

.uv-event-card {
    border: 1px solid var(--uv-border);
    border-left: 3px solid var(--uv-gold);
    border-radius: var(--uv-radius);
    padding: .85rem;
    margin-bottom: .75rem;
    transition: all var(--uv-transition);
    background: #fff;
}

.uv-event-card:hover {
    border-left-color: var(--uv-gold-dark);
    box-shadow: var(--uv-shadow-sm);
    transform: translateX(2px);
}

.uv-event-card .uv-event-banner {
    text-align: center;
    margin-bottom: .6rem;
    padding: .5rem;
    background: #fff;
    border-radius: 4px;
}

.uv-event-card .uv-event-banner img {
    max-height: 100px;
    width: auto;
}

.uv-event-card h3 {
    font-size: 1rem;
    font-weight: 600;
    line-height: 1.2;
    margin-bottom: .5rem;
}

.uv-event-card h3 a {
    color: var(--uv-text);
    text-decoration: none;
    transition: color var(--uv-transition);
}

.uv-event-card h3 a:hover {
    color: var(--uv-gold-dark);
}

.uv-event-detail {
    font-size: .875rem;
    color: var(--uv-text-muted);
    display: flex;
    align-items: center;
    gap: .4rem;
    margin-bottom: .3rem;
}

.uv-event-detail i {
    color: var(--uv-gold);
    width: 1rem;
    text-align: center;
}

/* Branding Header (creative advertising background)
   ========================================================================== */

/* Mobile banner image — visible only on small screens */
#BrandHeader {
    text-align: center;
    overflow: hidden;
}

/* Spacer image — desktop only, creates room for background-image on body */
.uv-brand-img-1 {
    display: none;
}

/* Mobile banner — hidden on desktop where body background is used */
.uv-brand-img-2 {
    display: inline-block;
    max-width: 480px;
    width: 100%;
    height: auto;
}

@media (min-width: 1200px) {
    /* On desktop: show spacer to push content down, hide mobile image */
    .uv-brand-img-1 {
        display: block;
        width: 100%;
        height: 200px;
        pointer-events: none;
    }

    .uv-brand-img-2 {
        display: none;
    }

    /* Brand creative: pointer only on body background margins, not content */
    body.uv-brand-active {
        cursor: pointer;
    }

    body.uv-brand-active #wrapper {
        cursor: default;
    }

    /* Wrapper width — matches original Canvas layout */
    #wrapper {
        max-width: 1080px;
        margin: 0 auto;
    }

    /* Override Bootstrap container to match wrapper */
    .container {
        max-width: 1080px;
    }
}

/* CKEditor 5 content styles (was: ck-style.css)
   Used in editor (CKEDITOR_5_CUSTOM_CSS) and on public pages for rendered content
   ========================================================================== */

.ck-style-title {
    font-size: 50px;
    font-weight: 700;
    border: 0;
}

.ck-style-callout {
    --border-color: #e91e1e;
    padding: 1.2em 2em;
    border: 1px solid var(--border-color);
    border-left: 10px solid var(--border-color);
    background: #fff9fb;
    border-radius: 5px;
    margin: 1.5em 2em;
    box-shadow: 5px 5px 0 #ffe6ef;
}

.ck-style-needs-clarification {
    outline: 1px dashed #0D6EFD;
    background: #ffe19c;
    border-radius: 2px;
    position: relative;
}

.ck-style-wide-spacing {
    letter-spacing: .3em;
}

/* Article / Publication — shared detail page components
   Used across: articles, news, digest, press, blogs, videos, books,
   albums, brands, franchises, seminars, regulations, job
   ========================================================================== */

.uv-article-title {
    font-size: 1.65rem;
    font-weight: 700;
    color: #1a1a1a;
    line-height: 1.3;
    margin-bottom: .75rem;
}

.uv-article-content {
    font-size: 1rem;
    line-height: 1.75;
    color: #333;
}
.uv-article-content p { margin-bottom: 1rem; }
.uv-article-content img { border-radius: 6px; }
.uv-article-content blockquote {
    border-left: 4px solid var(--uv-gold);
    padding: .75rem 1.25rem;
    margin: 1.25rem 0;
    background: var(--uv-bg-warm, #faf8f5);
    border-radius: 0 6px 6px 0;
    color: #555;
    font-style: italic;
}

/* Article meta bar */
.uv-article-meta {
    display: flex;
    align-items: center;
    flex-wrap: wrap;
    gap: .6rem;
    padding: .75rem 0;
    border-top: 1px solid #f0ece4;
    border-bottom: 1px solid #f0ece4;
    margin-bottom: 1.25rem;
    font-size: var(--uv-fs-small);
    color: var(--uv-text-muted);
}
.uv-article-meta i { font-size: var(--uv-fs-xs); opacity: .6; }
.uv-article-meta__author {
    display: inline-flex;
    align-items: center;
    gap: .4rem;
    text-decoration: none;
    color: #1a1a1a;
    font-weight: 600;
    transition: color .2s;
}
.uv-article-meta__author:hover { color: var(--uv-gold); }
.uv-article-meta__author img {
    width: 28px; height: 28px;
    border-radius: 50%;
    object-fit: cover;
}
.uv-article-meta__author-avatar {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 28px; height: 28px;
    border-radius: 50%;
    background: linear-gradient(135deg, var(--uv-gold), var(--uv-gold-dark));
    color: #fff;
    font-size: var(--uv-fs-xs);
    font-weight: 700;
    flex-shrink: 0;
}
.uv-article-meta__category {
    display: inline-block;
    padding: .15rem .5rem;
    border-radius: 4px;
    background: var(--uv-bg-warm);
    border: 1px solid var(--uv-border);
    font-size: var(--uv-fs-xs);
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: .03em;
    color: var(--uv-text-muted);
    text-decoration: none;
    transition: all .2s;
}
.uv-article-meta__category:hover { border-color: var(--uv-gold); color: var(--uv-text); }
.uv-article-meta__company a {
    color: #1a1a1a;
    font-weight: 600;
    text-decoration: none;
    transition: color .2s;
}
.uv-article-meta__company a:hover { color: var(--uv-gold); }

/* Comments */
.uv-comment {
    display: flex;
    gap: .75rem;
    padding: .85rem 0;
    border-bottom: 1px solid #f0ece4;
}
.uv-comment:last-child { border-bottom: none; }
.uv-comment__avatar {
    width: 42px; height: 42px;
    border-radius: 50%;
    object-fit: cover;
    flex-shrink: 0;
    border: 1px solid var(--uv-border);
}
.uv-comment__avatar--placeholder {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 42px; height: 42px;
    border-radius: 50%;
    flex-shrink: 0;
    background: linear-gradient(135deg, var(--uv-gold), var(--uv-gold-dark));
    color: #fff;
    font-size: .85rem;
    font-weight: 700;
    border: 1px solid var(--uv-border);
}
.uv-comment__body { flex: 1; min-width: 0; }
.uv-comment__header {
    display: flex;
    align-items: center;
    gap: .5rem;
    margin-bottom: .3rem;
}
.uv-comment__author {
    font-size: .88rem;
    font-weight: 600;
    color: #1a1a1a;
    text-decoration: none;
    transition: color .2s;
}
.uv-comment__author:hover { color: var(--uv-gold); }
.uv-comment__date { font-size: var(--uv-fs-xs); color: #b0a898; }
.uv-comment__text { font-size: .88rem; line-height: 1.55; color: #444; }
.uv-comment__text p { margin-bottom: .3rem; }
.uv-comment__text p:last-child { margin-bottom: 0; }

/* Comment form */
.uv-comment-form {
    padding: 1.25rem;
    border-radius: 10px;
    background: var(--uv-bg-warm);
    border: 1px solid var(--uv-border);
    margin-top: 1rem;
}
.uv-comment-form h2 {
    font-size: var(--uv-fs-h2-mobile);
    font-weight: 600;
    color: #1a1a1a;
    margin-bottom: .75rem;
}
.uv-comment-form p a { color: var(--uv-gold); }

/* Related posts */
.uv-related-section {
    margin-top: 2rem;
    padding-top: 1.5rem;
    border-top: 2px solid #f0ece4;
}
.uv-related-title {
    font-size: var(--uv-fs-h4);
    font-weight: 600;
    color: #1a1a1a;
    margin-bottom: 1rem;
}
.uv-related-title span { color: var(--uv-gold); }
.uv-related-card {
    display: flex;
    gap: .75rem;
    padding: .65rem 0;
    border-bottom: 1px solid #f0ece4;
    transition: background .15s;
}
.uv-related-card:last-child { border-bottom: none; }
.uv-related-card:hover { background: #fdfcfa; }
.uv-related-card__thumb {
    flex-shrink: 0;
    width: 140px; height: 80px;
    border-radius: 6px;
    overflow: hidden;
    background: var(--uv-bg-warm);
}
.uv-related-card__thumb img { width: 100%; height: 100%; object-fit: cover; }
.uv-related-card__body { flex: 1; min-width: 0; }
.uv-related-card__body h3 {
    font-size: var(--uv-fs-h5);
    font-weight: 600;
    line-height: 1.35;
    margin: 0 0 .25rem;
}
.uv-related-card__body h3 a { color: #333; text-decoration: none; transition: color .2s; }
.uv-related-card__body h3 a:hover { color: var(--uv-gold); }
.uv-related-card__meta { font-size: var(--uv-fs-xs); color: var(--uv-text-muted); }
@media (max-width: 575px) {
    .uv-related-card__thumb { width: 100px; height: 60px; }
}

/* Sidebar — shared across detail + list pages
   ========================================================================== */

.uv-sidebar-section { margin-bottom: 1.25rem; }
.uv-sidebar-title {
    font-size: .78rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: .06em;
    color: #1a1a1a;
    padding-bottom: .5rem;
    border-bottom: 2px solid var(--uv-gold);
    margin-bottom: .75rem;
}

/* Category cloud — shared across detail + list pages
   ========================================================================== */

.uv-cat-cloud { display: flex; flex-wrap: wrap; gap: .35rem; }
.uv-cat-cloud a {
    display: inline-flex;
    align-items: center;
    gap: .25rem;
    padding: .3rem .6rem;
    border-radius: 6px;
    font-size: .78rem;
    font-weight: 500;
    text-decoration: none;
    color: var(--uv-text);
    background: var(--uv-bg-warm);
    border: 1px solid var(--uv-border);
    transition: all .2s;
}
.uv-cat-cloud a:hover {
    border-color: var(--uv-gold);
    color: var(--uv-text-muted);
    background: #fff;
}
.uv-cat-cloud a sup { font-size: var(--uv-fs-xs); color: var(--uv-gold); font-weight: 700; }

/* GoToTop button (was: Canvas SEMICOLON.initialize.goToTop)
   ========================================================================== */

#gotoTop {
    display: none;
    position: fixed;
    bottom: 1.5rem;
    right: 1.5rem;
    z-index: 1040;
    width: 2.5rem;
    height: 2.5rem;
    line-height: 2.5rem;
    text-align: center;
    font-size: 1rem;
    color: #fff;
    background: rgba(0, 0, 0, .35);
    border-radius: 50%;
    cursor: pointer;
    transition: background .2s, opacity .3s;
}

#gotoTop:hover {
    background: rgba(0, 0, 0, .6);
}
