/* ContextCore Website Custom Theme over UIkit */

:root {
    --cc-bg-base: #111827;      /* Tailwind Gray 900 */
    --cc-bg-darker: #030712;    /* Tailwind Gray 950 */
    --cc-primary: #00d4ff;      /* Bright Cyan/Teal */
    --cc-primary-hover: #00b8e6;
    --cc-text-base: #e5e7eb;
    --cc-card-bg: #1f2937;      /* Tailwind Gray 800 */
    --cc-border: #374151;
}

body {
    background-color: var(--cc-bg-base);
    color: var(--cc-text-base);
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
}

/* Brand raster (replaces generic UIkit icons where requested) */
/* Tight flex lockup so the mark sits close to the wordmark (uk-navbar-item adds its own padding) */
.cc-logo-lockup {
    display: inline-flex;
    align-items: center;
    column-gap: 0.08rem;
    /*
     * 25% larger than UIkit’s .uk-logo (1.5rem). Do not use % here — percentage
     * font-size is relative to the parent .uk-navbar-left, not the logo’s 1.5rem,
     * so 125% was shrinking the wordmark instead of enlarging it.
     */
    font-size: calc(1.5rem * 1.25);
}

.cc-brand-logo {
    display: block;
    width: 65px;
    height: 65px;
    margin: 0;
    object-fit: contain;
    border-radius: 13px;
    /* Optical alignment: raster sits slightly high next to cap-height text; nudge down 2px. */
    transform: translateY(2px);
}

.cc-hero-art {
    display: block;
    max-width: 100%;
    height: auto;
    object-fit: contain;
}

/* Hero video: logo poster until first frame; static PNG hidden unless reduced-motion or error fallback */
.cc-hero-visual-col {
    overflow: visible;
    z-index: 2;
}

.cc-hero-bg .uk-grid {
    overflow: visible;
}

.cc-glass-panel--hero {
    overflow: visible;
    max-width: 100%;
}

/* Hero visual ~30% larger than the column slot (native clip is 1900×1134) */
.cc-hero-media-inner {
    width: 100%;
    display: block;
}

.cc-hero-media {
    position: relative;
    width: 100%;
}

.cc-hero-static {
    display: none;
}

.cc-hero-video {
    width: 100%;
    vertical-align: top;
    background-color: var(--cc-card-bg);
}

/* Placeholder keeps layout when the <video> is reparented to the fullscreen overlay */
.cc-hero-video-placeholder {
    width: 100%;
    box-sizing: border-box;
    pointer-events: none;
}

/* Fullscreen overlay: native video size capped by viewport (1900×1134 source) */
.cc-hero-overlay {
    position: fixed;
    inset: 0;
    z-index: 10050;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 1rem;
    box-sizing: border-box;
    background: rgba(3, 7, 18, 0.92);
    cursor: zoom-out;
}

.cc-hero-overlay .cc-hero-video,
.cc-hero-overlay .cc-hero-static {
    width: auto;
    height: auto;
    max-width: min(1900px, calc(100vw - 2rem));
    max-height: min(1134px, calc(100vh - 2rem));
    cursor: default;
    box-shadow: 0 24px 64px rgba(0, 0, 0, 0.55);
}

body.cc-hero-overlay-open {
    overflow: hidden;
}

@media (prefers-reduced-motion: reduce) {
    .cc-hero-media-inner {
        transform: none;
    }

    .cc-hero-video {
        display: none !important;
    }

    .cc-hero-static {
        display: block;
    }

    body.cc-force-motion .cc-hero-video {
        display: block !important;
    }

    body.cc-force-motion .cc-hero-static {
        display: none !important;
    }
}

.cc-footer-brand {
    display: inline-block;
    max-height: 88px;
    width: auto;
    object-fit: contain;
    border-radius: 10px;
}

/* Sticky chrome: match page background when fixed so scrolling content does not show through transparent bars */
body.cc-site [uk-sticky].uk-active {
    background-color: var(--cc-bg-base);
    box-shadow: 0 1px 0 var(--cc-border);
}

body.cc-site [uk-sticky].uk-active .site-toolbar {
    background: var(--cc-bg-base) !important;
    backdrop-filter: none;
    border-bottom-color: var(--cc-border);
}

body.cc-site [uk-sticky].uk-active .uk-navbar-container {
    background-color: var(--cc-bg-base) !important;
}

/* Custom Text Classes */
.cc-text-primary {
    color: var(--cc-primary) !important;
}

/* Section Backgrounds */
.cc-section-base {
    background-color: var(--cc-bg-base);
}

.cc-section-darker {
    background-color: var(--cc-bg-darker);
}

/* Hero Gradient */
.cc-hero-bg {
    background: radial-gradient(circle at top right, #1f2937, var(--cc-bg-darker));
}

/* Tighter hero under sticky chrome — avoids a tall empty band (was uk-height-viewport + uk-flex-middle + section-xlarge) */
.cc-hero-compact {
    padding-top: 0.5rem !important;
    padding-bottom: max(0px, calc(2.75rem - 50px));
}

@media (min-width: 960px) {
    .cc-hero-compact {
        padding-top: 0.85rem !important;
        padding-bottom: 2.75rem;
    }
}

/* Borders */
.cc-border-top {
    border-top: 1px solid var(--cc-border);
}

/* Buttons */
.uk-button-primary {
    background-color: var(--cc-primary);
    color: #000;
    font-weight: 600;
    border: none;
    transition: all 0.2s ease-in-out;
}

.uk-button-primary:hover {
    background-color: var(--cc-primary-hover);
    color: #000;
}

.cc-btn-glow {
    box-shadow: 0 0 15px rgba(0, 212, 255, 0.4);
}

.cc-btn-glow:hover {
    box-shadow: 0 0 25px rgba(0, 212, 255, 0.6);
    transform: translateY(-2px);
}

/* Cards */
.uk-card-secondary {
    background-color: var(--cc-card-bg);
    border: 1px solid var(--cc-border);
}

.cc-card-hover {
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.cc-card-hover:hover {
    transform: translateY(-5px);
    box-shadow: 0 10px 20px rgba(0, 0, 0, 0.5);
    border-color: var(--cc-primary);
}

/* Glass Panels */
.cc-glass-panel {
    background: rgba(31, 41, 55, 0.6);
    backdrop-filter: blur(10px);
    border: 1px solid var(--cc-border);
    border-radius: 8px;
}

/* Code Blocks */
.cc-code-block {
    background-color: var(--cc-bg-darker) !important;
    border: 1px solid var(--cc-border);
    border-radius: 6px;
    padding: 1rem;
    color: #a8b2d1;
}

/* Overlays */
.cc-overlay-dark {
    background: linear-gradient(to top, rgba(3, 7, 18, 0.9) 0%, rgba(3, 7, 18, 0.3) 100%);
}

.cc-slideshow-nav-absolute {
    position: absolute;
    bottom: 20px;
    left: 50%;
    transform: translateX(-50%);
    z-index: 10;
}

/* Icon Buttons */
.cc-icon-button {
    background-color: var(--cc-card-bg);
    color: var(--cc-text-base);
    border: 1px solid var(--cc-border);
    transition: all 0.2s ease;
}

.cc-icon-button:hover {
    background-color: var(--cc-primary);
    color: #000;
    border-color: var(--cc-primary);
}

/* List large */
.cc-list-large li {
    font-size: 1.1rem;
    margin-top: 10px;
}

/* Keep hero CTA labels intact and stack actions on very narrow phones */
.cc-hero-actions .uk-button {
    white-space: nowrap;
}

@media (max-width: 380px) {
    .cc-hero-actions {
        flex-direction: column;
        align-items: stretch;
        gap: 0.6rem !important;
        width: 100%;
    }

    .cc-hero-actions .uk-button {
        width: 100%;
        text-align: center;
    }
}

/* Navbar: drop Quick Start button below logo on narrow screens */
@media (max-width: 639px) {
    .cc-site .uk-navbar-container {
        flex-wrap: wrap;
    }

    .cc-site .uk-navbar-container .uk-navbar-right {
        flex: 1 0 100%;
        justify-content: flex-start;
        padding: 0 0 0 1rem;
        margin-top: -1.35rem;
    }
}

/* Deep purple background tightly wrapping slide text */
.cc-slide-caption {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 0.5rem;
}

.cc-slide-caption > h2,
.cc-slide-caption > p {
    background-color: rgba(45, 15, 80, 0.95);
    padding: 0.4rem 1rem;
    border-radius: 8px;
    max-width: 100%;
    margin: 0 !important; /* ensures our gap property handles spacing */
}
