/**
 * Toolkit - Global CSS
 * Styles applied to all pages
 * Includes: CSS variables, Promo banner
 */

/* ===========================================
   CSS VARIABLES (shared across all files)
   =========================================== */
:root {
    /* Stock colors */
    --tk-stock-green: #33b48c;
    --tk-stock-red: #f73959;
    
    /* Plugin colors */
    --tk-color-primary: #000;
    --tk-color-secondary: #2673ea;
    --tk-color-accent: var(--theme-palette-color-2, #2673ea);
    --tk-color-text: #111;
    --tk-color-text-muted: #666;
    --tk-color-bg: #fff;
    --tk-color-bg-light: #f8f8f8;
    --tk-color-bg-hover: #f7f7f7;
    --tk-color-border: var(--theme-border-color, #e0e0e0);
    --tk-color-border-light: rgba(0, 0, 0, 0.1);
    
    /* Sizing */
    --tk-font-xs: 0.7rem;
    --tk-font-sm: 0.8rem;
    --tk-font-base: 0.875rem;
    --tk-font-md: 0.9375rem;
    --tk-radius-sm: 4px;
    --tk-radius-md: 6px;
    --tk-radius-lg: 8px;
    --tk-radius-full: 50px;
    
    /* Transitions */
    --tk-transition: 0.3s ease;
    --tk-transition-fast: 0.4s ease;
}

/* ===========================================
   PROMO BANNER
   =========================================== */
.cross-dissolve-slider-container {
    --cycle: 12s;
    --step: 4s;
    flex: 1;
    height: 100%;
    min-height: 30px;
    position: relative;
    font-size: clamp(0.85rem, 2vw, 1rem);
    color: #fff;
    font-weight: 700;
    display: flex;
    align-items: center;
    justify-content: center;
}

/* Remove Blocksy HTML element margins */
.ct-header-html:has(.cross-dissolve-slider-container) {
    flex: 1;
    margin: 0 !important;
    padding: 0 !important;
}

.cross-dissolve-slider {
    position: relative;
    width: 100%;
    height: 100%;
}

.cross-dissolve-slider .slide {
    position: absolute;
    inset: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    text-align: center;
    white-space: nowrap;
    opacity: 0;
    will-change: opacity;
    animation: tk-fade var(--cycle) linear infinite both;
    animation-delay: calc(var(--i) * var(--step));
}

.cross-dissolve-slider-container:hover .slide {
    animation-play-state: paused;
}

@keyframes tk-fade {
    0%   { opacity: 0; }
    5%   { opacity: 1; }
    25%  { opacity: 1; }
    33%  { opacity: 0; }
    100% { opacity: 0; }
}

@media (prefers-reduced-motion: reduce) {
    .cross-dissolve-slider .slide {
        animation: none;
        opacity: 1;
    }
    .cross-dissolve-slider .slide:not(:first-child) {
        display: none;
    }
}


/* ============================================
   NEWSLETTER (Fluent Forms)
   ============================================ */
.ff-el-form-control {
    border-radius: 50px !important;
}

.fluentform .ff-el-group {
    margin-bottom: 10px;
}

form.fluent_form_5 .wpf_has_custom_css.ff-btn-submit {
    font-size: 18px;
}