/* ── Tutor Trial Manager — Trial Ticker Styles ──────────────────────────── */

.ttm-ticker {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 8px 16px;
    border-radius: 40px;
    font-size: 14px;
    font-weight: 600;
    line-height: 1.4;
    box-shadow: 0 2px 8px rgba(0,0,0,0.08);
    transition: box-shadow 0.2s;
    max-width: 100%;
}
.ttm-ticker:hover { box-shadow: 0 4px 14px rgba(0,0,0,0.13); }

/* Alignment helpers */
.ttm-ticker--center { display: flex; margin: 0 auto; }
.ttm-ticker--right  { display: flex; margin-left: auto; }
.ttm-ticker--left   { display: inline-flex; }

/* Trial state — amber/yellow */
.ttm-ticker--trial {
    background: linear-gradient(135deg, #fffbeb 0%, #fef3c7 100%);
    border: 1.5px solid #f59e0b;
    color: #92400e;
}

/* Pulse animation on the icon when days ≤ 3 */
.ttm-ticker--trial .ttm-ticker__icon {
    display: inline-block;
    animation: ttm-pulse 1.6s ease-in-out infinite;
}

/* Expired state — red */
.ttm-ticker--expired {
    background: linear-gradient(135deg, #fff1f2 0%, #ffe4e6 100%);
    border: 1.5px solid #f43f5e;
    color: #9f1239;
}
.ttm-ticker--expired .ttm-ticker__icon {
    display: inline-block;
    animation: ttm-shake 2.5s ease-in-out infinite;
}

/* Paid state — green */
.ttm-ticker--paid {
    background: linear-gradient(135deg, #f0fdf4 0%, #dcfce7 100%);
    border: 1.5px solid #22c55e;
    color: #14532d;
}

/* Icon */
.ttm-ticker__icon {
    font-size: 16px;
    flex-shrink: 0;
    line-height: 1;
}

/* Text */
.ttm-ticker__text {
    flex: 1;
}
.ttm-ticker__text strong {
    font-weight: 800;
}

/* CTA pill button */
.ttm-ticker__cta {
    display: inline-block;
    padding: 4px 14px;
    border-radius: 20px;
    font-size: 12px;
    font-weight: 700;
    text-decoration: none;
    white-space: nowrap;
    background: #f59e0b;
    color: #fff;
    transition: background 0.15s, transform 0.1s;
    flex-shrink: 0;
}
.ttm-ticker__cta:hover {
    background: #d97706;
    color: #fff;
    transform: translateY(-1px);
}

.ttm-ticker__cta--urgent {
    background: #f43f5e;
    animation: ttm-cta-glow 2s ease-in-out infinite;
}
.ttm-ticker__cta--urgent:hover { background: #e11d48; }

/* ── Keyframes ─────────────────────────────────────────────────────────── */

@keyframes ttm-pulse {
    0%, 100% { transform: scale(1); }
    50%       { transform: scale(1.25); }
}

@keyframes ttm-shake {
    0%, 100% { transform: rotate(0deg); }
    10%       { transform: rotate(-8deg); }
    20%       { transform: rotate(8deg); }
    30%       { transform: rotate(-6deg); }
    40%       { transform: rotate(6deg); }
    50%, 90%  { transform: rotate(0deg); }
}

@keyframes ttm-cta-glow {
    0%, 100% { box-shadow: 0 0 0 0 rgba(244,63,94,0.4); }
    50%       { box-shadow: 0 0 0 6px rgba(244,63,94,0); }
}

/* Responsive */
@media (max-width: 480px) {
    .ttm-ticker {
        font-size: 13px;
        padding: 7px 12px;
        gap: 6px;
        border-radius: 10px;
    }
    .ttm-ticker--center,
    .ttm-ticker--right { width: 100%; }
}

/* ── Banner (used by [ttm_trial_banner]) ───────────────────────────────── */

.ttm-banner {
    padding: 14px 20px;
    border-radius: 8px;
    margin-bottom: 24px;
    font-size: 15px;
    line-height: 1.5;
}
.ttm-banner--trial {
    background: #fffbe6;
    border: 1px solid #ffe58f;
    color: #7c5a00;
}
.ttm-banner--expired {
    background: #fff2f0;
    border: 1px solid #ffccc7;
    color: #a8071a;
}
.ttm-banner a { color: inherit; font-weight: 600; }

/* ── Status badge ───────────────────────────────────────────────────────── */

.ttm-status {
    display: inline-block;
    padding: 2px 10px;
    border-radius: 20px;
    font-size: 12px;
    font-weight: 600;
}
.ttm-status--trial        { background: #e6f7ff; color: #0050b3; }
.ttm-status--expired      { background: #fff1f0; color: #cf1322; }
.ttm-status--paid,
[class*="ttm-status--paid-"] { background: #f0f0ff; color: #4040b0; }
.ttm-status--no-access    { background: #f5f5f5; color: #888; }
