/* =============================================
   tutorials.css — Lunexo Tutorials & Templates
   ============================================= */

/* ── Channel Follow Section ─────────────────── */
.channel-follow-section {
    padding: 4rem 0 2rem;
}

.channel-cards {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 1.5rem;
    margin-top: 2.5rem;
    max-width: 860px;
    margin-left: auto;
    margin-right: auto;
}

.channel-card {
    display: flex;
    align-items: center;
    gap: 1.25rem;
    padding: 1.75rem 2rem;
    border-radius: 20px;
    border: 1px solid var(--cine-border-soft);
    background: var(--cine-glass-soft);
    backdrop-filter: blur(16px);
    -webkit-backdrop-filter: blur(16px);
    text-decoration: none;
    color: var(--cine-text);
    transition: all 0.3s ease;
    position: relative;
    overflow: hidden;
}

.channel-card::before {
    content: '';
    position: absolute;
    inset: 0;
    opacity: 0;
    transition: opacity 0.3s ease;
    border-radius: 20px;
}

.channel-card--instagram::before {
    background: linear-gradient(135deg, rgba(var(--brand-ig-rgb), 0.15), rgba(var(--brand-ig-purple-rgb), 0.15));
}

.channel-card--youtube::before {
    background: linear-gradient(135deg, rgba(var(--brand-yt-rgb), 0.12), rgba(var(--c-darkred-rgb), 0.08));
}

.channel-card:hover::before { opacity: 1; }

.channel-card:hover {
    border-color: var(--cine-border-soft);
    transform: translateY(-3px);
}

.channel-card--instagram:hover { box-shadow: 0 12px 40px rgba(var(--brand-ig-rgb), 0.2); }
.channel-card--youtube:hover   { box-shadow: 0 12px 40px rgba(var(--brand-yt-rgb), 0.15); }

.channel-card-icon {
    width: 56px;
    height: 56px;
    border-radius: 16px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.6rem;
    flex-shrink: 0;
}

.channel-card--instagram .channel-card-icon {
    background: linear-gradient(135deg, #f09433, #e6683c, #dc2743, #cc2366, #bc1888);
}

.channel-card--youtube .channel-card-icon {
    background: var(--brand-yt);
}

.channel-card-info {
    flex: 1;
}

.channel-platform {
    font-size: 0.72rem;
    font-weight: 600;
    letter-spacing: 0.1em;
    text-transform: uppercase;
    opacity: 0.5;
    display: block;
    margin-bottom: 0.2rem;
}

.channel-handle {
    font-size: 1.15rem;
    font-weight: 700;
    color: var(--cine-text);
    margin: 0 0 0.4rem;
}

.channel-desc {
    font-size: 0.82rem;
    color: rgba(255,255,255,0.55);
    line-height: 1.5;
    margin: 0;
}

.channel-card-cta {
    display: flex;
    align-items: center;
    gap: 0.4rem;
    font-size: 0.82rem;
    font-weight: 600;
    color: rgba(255,255,255,0.7);
    white-space: nowrap;
    flex-shrink: 0;
    transition: color 0.2s;
}

.channel-card:hover .channel-card-cta { color: var(--cine-text); }

/* ── Episodes Section ────────────────────────── */
.episodes-section {
    padding: 3rem 0 4rem;
}

.episodes-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 1.25rem;
    margin-top: 2.5rem;
}

.episode-card {
    position: relative;
    padding: 1.75rem 1.5rem;
    border-radius: 20px;
    border: 1px solid var(--cine-border-soft);
    background: var(--cine-glass-soft);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    transition: all 0.3s ease;
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
}

.episode-card:hover {
    border-color: rgba(var(--c-violet-rgb), 0.35);
    background: rgba(var(--c-violet-rgb), 0.06);
    transform: translateY(-4px);
    box-shadow: 0 16px 48px rgba(var(--c-violet-rgb), 0.12);
}

.episode-card--intro {
    border-color: rgba(var(--c-violet-rgb), 0.25);
    background: rgba(var(--c-violet-rgb), 0.06);
}

.episode-card--coming {
    opacity: 0.65;
}

.episode-card--coming:hover {
    transform: none;
    box-shadow: none;
}

.ep-badge {
    display: inline-flex;
    align-items: center;
    padding: 0.2rem 0.65rem;
    background: rgba(var(--c-violet-rgb), 0.2);
    border: 1px solid rgba(var(--c-violet-rgb), 0.4);
    border-radius: 100px;
    font-size: 0.7rem;
    font-weight: 700;
    color: var(--c-purple);
    letter-spacing: 0.05em;
    width: fit-content;
}

.ep-badge--coming {
    background: var(--cine-glass-soft);
    border-color: var(--cine-border);
    color: rgba(255,255,255,0.4);
}

.ep-platform-badges {
    display: flex;
    gap: 0.4rem;
    flex-wrap: wrap;
}

.ep-platform {
    display: inline-flex;
    align-items: center;
    gap: 0.3rem;
    font-size: 0.67rem;
    font-weight: 600;
    padding: 0.15rem 0.5rem;
    border-radius: 100px;
    letter-spacing: 0.03em;
}

.ep-platform--ig {
    background: rgba(var(--brand-ig-rgb), 0.15);
    color: var(--c-pink400);
    border: 1px solid rgba(var(--brand-ig-rgb), 0.25);
}

.ep-platform--yt {
    background: rgba(var(--brand-yt-rgb), 0.12);
    color: var(--c-red400);
    border: 1px solid rgba(var(--brand-yt-rgb), 0.2);
}

.ep-icon {
    font-size: 1.75rem;
    color: rgba(var(--c-violet-rgb), 0.7);
    margin: 0.25rem 0;
}

.ep-title {
    font-size: 1rem;
    font-weight: 700;
    color: var(--cine-text);
    margin: 0;
    line-height: 1.3;
}

.ep-desc {
    font-size: 0.82rem;
    color: rgba(255,255,255,0.5);
    line-height: 1.6;
    margin: 0;
    flex: 1;
}

.ep-links {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
    margin-top: 0.5rem;
}

.ep-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 0.4rem;
    padding: 0.5rem 1rem;
    border-radius: 10px;
    font-size: 0.78rem;
    font-weight: 600;
    text-decoration: none;
    transition: all 0.2s ease;
}

.ep-btn--ig {
    background: linear-gradient(135deg, rgba(var(--brand-ig-rgb), 0.15), rgba(var(--brand-ig-purple-rgb), 0.15));
    border: 1px solid rgba(var(--brand-ig-rgb), 0.3);
    color: var(--c-pink400);
}

.ep-btn--ig:hover {
    background: linear-gradient(135deg, rgba(var(--brand-ig-rgb), 0.28), rgba(var(--brand-ig-purple-rgb), 0.28));
    color: var(--cine-text);
}

.ep-btn--yt {
    background: rgba(var(--brand-yt-rgb), 0.1);
    border: 1px solid rgba(var(--brand-yt-rgb), 0.25);
    color: var(--c-red400);
}

.ep-btn--yt:hover {
    background: rgba(var(--brand-yt-rgb), 0.22);
    color: var(--cine-text);
}

.ep-coming-badge {
    text-align: center;
    font-size: 0.78rem;
    font-weight: 600;
    color: rgba(255,255,255,0.3);
    padding: 0.5rem;
    border: 1px dashed var(--cine-border);
    border-radius: 10px;
    margin-top: 0.5rem;
}

/* ── Responsive ──────────────────────────────── */
@media (max-width: 1024px) {
    .episodes-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (max-width: 768px) {
    .channel-cards {
        grid-template-columns: 1fr;
    }

    .channel-card {
        padding: 1.25rem 1.5rem;
    }

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

    .channel-card-icon {
        width: 48px;
        height: 48px;
        font-size: 1.3rem;
    }
}

/* ── GitHub Banner ────────────────────────────── */
.github-banner {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 1rem;
    padding: 1.25rem 2rem;
    border-radius: 16px;
    border: 1px solid var(--cine-border-soft);
    background: var(--cine-glass-soft);
    backdrop-filter: blur(12px);
    text-decoration: none;
    color: var(--cine-text);
    margin: 2.5rem auto 2rem;
    max-width: 720px;
    transition: all 0.3s ease;
}

.github-banner:hover {
    border-color: rgba(255,255,255,0.22);
    background: var(--cine-border-soft);
    transform: translateY(-2px);
    box-shadow: 0 8px 32px var(--media-scrim-soft);
}

.github-banner-left {
    display: flex;
    align-items: center;
    gap: 1rem;
}

.github-banner-icon {
    font-size: 2rem;
    color: rgba(255,255,255,0.85);
}

.github-banner-title {
    display: block;
    font-size: 0.95rem;
    font-weight: 700;
    color: var(--cine-text);
}

.github-banner-sub {
    display: block;
    font-size: 0.76rem;
    color: rgba(255,255,255,0.45);
    font-family: 'Courier New', monospace;
    margin-top: 0.1rem;
}

.github-banner-right {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    color: rgba(255,255,255,0.6);
    font-size: 0.85rem;
    font-weight: 600;
}

.github-banner-star {
    display: flex;
    align-items: center;
    gap: 0.3rem;
    padding: 0.3rem 0.75rem;
    border: 1px solid var(--cine-border-soft);
    border-radius: 8px;
    font-size: 0.8rem;
    transition: all 0.2s;
}

.github-banner:hover .github-banner-star {
    border-color: rgba(255,255,255,0.35);
    color: var(--cine-text);
}

/* ── Template card GitHub link ───────────────── */
.template-github-link {
    display: inline-flex;
    align-items: center;
    gap: 0.35rem;
    font-size: 0.74rem;
    color: rgba(255,255,255,0.35);
    text-decoration: none;
    margin-top: 0.5rem;
    transition: color 0.2s;
}

.template-github-link:hover {
    color: rgba(255,255,255,0.7);
}

/* ── Articles Grid ───────────────────────────── */
.articles-grid {
    display: flex;
    flex-direction: column;
    gap: 2rem;
    margin-top: 2rem;
}

.article-card {
    background: var(--cine-glass-soft);
    border: 1px solid var(--cine-border-soft);
    border-radius: 20px;
    padding: 2rem;
    transition: border-color 0.3s;
}

.article-card:hover {
    border-color: var(--cine-border-soft);
}

.article-card--featured {
    border-color: rgba(var(--c-teal-rgb), 0.2);
    background: rgba(var(--c-teal-rgb), 0.03);
}

.article-meta {
    display: flex;
    align-items: center;
    gap: 1rem;
    margin-bottom: 1rem;
}

.article-tag {
    display: inline-flex;
    align-items: center;
    gap: 0.35rem;
    padding: 0.3rem 0.75rem;
    border-radius: 99px;
    font-size: 0.75rem;
    font-weight: 600;
    letter-spacing: 0.04em;
}

.article-tag--leak {
    background: rgba(var(--c-red500-rgb), 0.12);
    color: var(--c-red400);
    border: 1px solid rgba(var(--c-red500-rgb), 0.2);
}

.article-date {
    font-size: 0.78rem;
    color: rgba(255,255,255,0.35);
}

.article-title {
    font-size: 1.6rem;
    font-weight: 700;
    color: var(--cine-text);
    margin-bottom: 0.6rem;
    line-height: 1.3;
}

.article-subtitle {
    font-size: 1rem;
    color: rgba(255,255,255,0.55);
    line-height: 1.6;
    margin-bottom: 1.75rem;
}

.article-subtitle code {
    background: var(--cine-border-soft);
    padding: 0.1em 0.4em;
    border-radius: 4px;
    font-family: monospace;
    font-size: 0.9em;
    color: rgba(255,255,255,0.8);
}

.article-highlights {
    display: flex;
    flex-direction: column;
    gap: 1rem;
    margin-bottom: 1.75rem;
}

.article-highlight {
    display: flex;
    align-items: flex-start;
    gap: 1rem;
    padding: 1rem 1.25rem;
    background: var(--cine-glass-soft);
    border: 1px solid var(--cine-glass-soft);
    border-radius: 12px;
}

.article-highlight > i {
    font-size: 1.3rem;
    color: rgba(255,255,255,0.4);
    flex-shrink: 0;
    margin-top: 0.1rem;
}

.article-highlight > div {
    display: flex;
    flex-direction: column;
    gap: 0.2rem;
}

.article-highlight strong {
    font-size: 0.9rem;
    color: rgba(255,255,255,0.85);
    font-weight: 600;
}

.article-highlight span {
    font-size: 0.83rem;
    color: rgba(255,255,255,0.45);
    line-height: 1.5;
}

.article-highlight span code {
    background: var(--cine-border-soft);
    padding: 0.1em 0.35em;
    border-radius: 4px;
    font-family: monospace;
    font-size: 0.88em;
    color: rgba(255,255,255,0.7);
}

.article-footer {
    display: flex;
    align-items: center;
    justify-content: space-between;
    flex-wrap: wrap;
    gap: 1rem;
    padding-top: 1.25rem;
    border-top: 1px solid var(--cine-glass-soft);
}

.article-stats {
    display: flex;
    flex-wrap: wrap;
    gap: 1rem;
}

.article-stats span {
    display: inline-flex;
    align-items: center;
    gap: 0.35rem;
    font-size: 0.78rem;
    color: rgba(255,255,255,0.35);
}

.article-watch-btn {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.6rem 1.2rem;
    border-radius: 99px;
    background: linear-gradient(135deg, #833ab4, #fd1d1d, #fcb045);
    color: var(--cine-text);
    font-size: 0.85rem;
    font-weight: 600;
    text-decoration: none;
    transition: opacity 0.2s;
}

.article-watch-btn:hover {
    opacity: 0.85;
}

/* ── Articles coming soon ────────────────────── */
.articles-coming {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 0.75rem;
    padding: 3rem 1rem;
    color: rgba(255,255,255,0.2);
    text-align: center;
}

.articles-coming i {
    font-size: 2rem;
}

.articles-coming p {
    font-size: 0.9rem;
}

/* ===== LIGHT MODE — channel / episode / github / template cards (2026-06-23)
   Shared by tutorials.html and the automation page. Authored dark-first
   (cine-glass-soft bg ≈ 4% white + white text → invisible on a light page).
   Frost them white with dark text in light mode. ===== */
[data-theme="light"] .channel-card,
[data-theme="light"] .episode-card,
[data-theme="light"] .github-banner,
[data-theme="light"] .template-card {
    background: rgba(255, 255, 255, 0.72);
    border-color: rgba(20, 24, 40, 0.10);
    box-shadow: 0 18px 50px -30px rgba(20, 24, 40, 0.22);
}
[data-theme="light"] .channel-handle,
[data-theme="light"] .ep-title,
[data-theme="light"] .github-banner-title,
[data-theme="light"] .template-card h3 {
    color: #181d2b;
}
[data-theme="light"] .channel-desc,
[data-theme="light"] .channel-platform,
[data-theme="light"] .ep-desc,
[data-theme="light"] .github-banner-sub,
[data-theme="light"] .template-desc {
    color: #3b4252;
}

/* Templates section is a full-height dark scrim (rgba(0,0,0,.55)) meant to sit
   over a video that isn't present here → in light mode it was a giant grey
   block. Let the light page show through. */
[data-theme="light"] .templates-section { background: transparent; }

/* Article cards: near-transparent teal bg + white text → frost + darken. */
[data-theme="light"] .article-card {
    background: rgba(255, 255, 255, 0.72);
    border-color: rgba(20, 24, 40, 0.10);
}
[data-theme="light"] .article-title,
[data-theme="light"] .article-highlight strong {
    color: #181d2b;
}
[data-theme="light"] .article-subtitle,
[data-theme="light"] .article-date,
[data-theme="light"] .article-highlight span,
[data-theme="light"] .article-stats span,
[data-theme="light"] .channel-card,
[data-theme="light"] .channel-card-cta {
    color: #3b4252;
}

/* tutorials.html has no .page-auto class, so the page-auto-scoped light fixes
   (auto-modern.css) never reach the shared CTA / section subtitles here.
   Re-declare them unscoped (also harmless on the automation page). */
[data-theme="light"] .auto-cta-card {
    background: rgba(255, 255, 255, 0.72);
    border-color: rgba(20, 24, 40, 0.10);
    box-shadow: 0 24px 60px -28px rgba(20, 24, 40, 0.28);
}
[data-theme="light"] .auto-cta-card h2 { color: #181d2b; }
[data-theme="light"] .auto-cta-card p,
[data-theme="light"] .section-subtitle { color: #3b4252; }
[data-theme="light"] .articles-coming p { color: rgba(20, 24, 40, 0.45); }
