/* AI FEATURES PRO MAX ULTRA - NEON SKILLS STYLE (STRICT MODE V4.2) */

:root {
    --glass-bg: rgba(10, 10, 20, 0.9);
    /* High opacity for cleaner look */
    --glass-border: rgba(255, 255, 255, 0.08);
    --primary-glow: rgba(99, 102, 241, 0.5);
    --success-glow: rgba(16, 185, 129, 0.4);
    --text-primary: #f8fafc;
    --text-secondary: #cbd5e1;
    --font-main: 'Plus Jakarta Sans', 'Inter', sans-serif;
}

/* Base Reset */
* {
    box-sizing: border-box;
}

/* === PLATFORM POLISH (V4.3) === */
.platform-card {
    background: rgba(17, 24, 39, 0.8);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 20px;
    padding: 24px;
    transition: all 0.3s ease;
    /* Dynamic Glow based on CSS var from JS */
    box-shadow: 0 0 0 rgba(0, 0, 0, 0);
}

.platform-card:hover {
    transform: translateY(-5px);
    border-color: var(--platform-color);
    box-shadow: 0 10px 30px -10px var(--platform-color);
}

.platform-header {
    display: flex;
    align-items: center;
    gap: 12px;
    margin-bottom: 20px;
    padding-bottom: 16px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}

.platform-header i {
    font-size: 24px;
    color: var(--platform-color);
}

.platform-header span {
    font-size: 18px;
    font-weight: 700;
    color: white;
    flex-grow: 1;
}

.platform-score {
    background: rgba(255, 255, 255, 0.1);
    padding: 4px 12px;
    border-radius: 8px;
    font-weight: 800;
    color: var(--platform-color);
}

/* Colored Bullets */
.strength-list,
.weakness-list {
    list-style: none;
    padding: 0;
    margin: 10px 0 20px 0;
}

.point-strength,
.point-weakness {
    position: relative;
    padding-left: 20px;
    margin-bottom: 8px;
    font-size: 14px;
    color: #e2e8f0;
    line-height: 1.5;
}

.point-strength::before,
.point-weakness::before {
    content: '';
    position: absolute;
    left: 0;
    top: 8px;
    width: 8px;
    height: 8px;
    border-radius: 50%;
}

.point-strength::before {
    background-color: #34d399;
    /* Green */
    box-shadow: 0 0 8px rgba(52, 211, 153, 0.6);
}

.point-weakness::before {
    background-color: #ef4444;
    /* Red */
    box-shadow: 0 0 8px rgba(239, 68, 68, 0.6);
}

/* Animation */
.fade-in {
    animation: fadeIn 0.6s cubic-bezier(0.2, 0.8, 0.2, 1);
}

@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(20px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* 1. CONTAINER */
.analysis-result {
    font-family: var(--font-main);
    color: var(--text-primary);
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
}

/* 2. SECTION DIVIDERS */
.section-divider {
    display: flex;
    align-items: center;
    margin: 60px 0 32px;
    gap: 24px;
}

.section-divider::before,
.section-divider::after {
    content: '';
    height: 1px;
    flex: 1;
    background: linear-gradient(90deg, transparent, rgba(99, 102, 241, 0.4), transparent);
}

.section-divider span {
    font-size: 13px;
    font-weight: 800;
    text-transform: uppercase;
    letter-spacing: 2px;
    color: #a5b4fc;
    background: rgba(15, 23, 42, 0.95);
    padding: 8px 20px;
    border-radius: 30px;
    border: 1px solid rgba(99, 102, 241, 0.2);
    box-shadow: 0 0 15px rgba(99, 102, 241, 0.15);
}

/* 3. SCORE HEADER */
.score-header-pro {
    display: grid;
    grid-template-columns: 320px 1fr;
    gap: 40px;
    margin-bottom: 48px;
}

@media (max-width: 850px) {
    .score-header-pro {
        grid-template-columns: 1fr;
    }
}

.score-card-main {
    background: linear-gradient(180deg, rgba(15, 23, 42, 0.95), rgba(15, 15, 25, 0.98));
    border: 1px solid var(--glass-border);
    border-radius: 32px;
    padding: 40px;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    box-shadow: 0 20px 50px -10px rgba(0, 0, 0, 0.5);
    position: relative;
    overflow: hidden;
}

.score-ring-container {
    position: relative;
    width: 160px;
    height: 160px;
    margin-bottom: 24px;
    transition: filter 0.3s ease;
}

.score-svg {
    transform: rotate(-90deg);
    width: 100%;
    height: 100%;
}

.score-bg {
    fill: none;
    stroke: rgba(255, 255, 255, 0.05);
    stroke-width: 12;
}

.score-circle-bar {
    fill: none;
    stroke-width: 12;
    stroke-linecap: round;
    transition: stroke-dashoffset 1.5s cubic-bezier(0.4, 0, 0.2, 1);
    filter: drop-shadow(0 0 6px rgba(0, 0, 0, 0.5));
}

.score-inner {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    display: flex;
    flex-direction: column;
    align-items: center;
}

.score-big {
    font-size: 56px;
    font-weight: 800;
    line-height: 1;
    letter-spacing: -2px;
    background: linear-gradient(180deg, #fff, #94a3b8);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
}

.score-small {
    font-size: 14px;
    color: #64748b;
    font-weight: 700;
    text-transform: uppercase;
    margin-top: 6px;
    letter-spacing: 1px;
}

.viral-tier-badge {
    padding: 12px 28px;
    border-radius: 40px;
    font-size: 15px;
    font-weight: 700;
    display: flex;
    align-items: center;
    gap: 10px;
}

.tier-s,
.tier-a {
    background: rgba(250, 204, 21, 0.15);
    color: #facc15;
    border: 1px solid rgba(250, 204, 21, 0.3);
}

.tier-b {
    background: rgba(56, 189, 248, 0.15);
    color: #38bdf8;
    border: 1px solid rgba(56, 189, 248, 0.3);
}

.tier-c,
.tier-d {
    background: rgba(148, 163, 184, 0.1);
    color: #cbd5e1;
    border: 1px solid rgba(148, 163, 184, 0.2);
}

/* Critique Box */
.critique-box {
    background: rgba(30, 41, 59, 0.5);
    border: 1px solid var(--glass-border);
    border-radius: 32px;
    padding: 40px;
    display: flex;
    flex-direction: column;
    justify-content: flex-start;
}

.critique-header {
    font-size: 15px;
    font-weight: 800;
    text-transform: uppercase;
    letter-spacing: 1px;
    background: linear-gradient(90deg, #818cf8, #c7d2fe);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    margin-bottom: 24px;
    display: flex;
    align-items: center;
    gap: 12px;
}

.critique-content {
    font-size: 16px;
    line-height: 1.8;
    color: #e2e8f0;
    font-weight: 400;
}

/* 4. LAYERS GRID */
.layers-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 32px;
}

@media (max-width: 900px) {
    .layers-grid {
        grid-template-columns: 1fr;
    }
}

.layer-card {
    background: rgba(17, 24, 39, 0.75);
    border: 1px solid var(--glass-border);
    border-radius: 24px;
    padding: 36px;
    transition: transform 0.3s ease, border 0.3s ease;
    display: flex;
    flex-direction: column;
}

.layer-card:hover {
    transform: translateY(-3px);
    border-color: rgba(99, 102, 241, 0.4);
}

.layer-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 28px;
}

.layer-header h5 {
    font-size: 18px;
    font-weight: 700;
    color: #f8fafc;
    margin: 0;
    display: flex;
    align-items: center;
    gap: 12px;
    flex: 1;
}

.layer-icon {
    width: 44px;
    height: 44px;
    background: rgba(99, 102, 241, 0.1);
    border-radius: 14px;
    border: 1px solid rgba(99, 102, 241, 0.2);
    display: flex;
    align-items: center;
    justify-content: center;
    color: #818cf8;
    font-size: 22px;
    flex-shrink: 0;
}

.layer-score {
    font-size: 14px;
    font-weight: 800;
    background: #4f46e5;
    color: white;
    padding: 8px 16px;
    border-radius: 20px;
    box-shadow: 0 4px 10px rgba(79, 70, 229, 0.3);
    flex-shrink: 0;
    margin-left: 16px;
}

/* NEW: STRUCTURAL CLASSES (Strict Mode) */
.analysis-section {
    margin-bottom: 28px;
}

.analysis-section:last-child {
    margin-bottom: 0;
}

.analysis-label {
    font-size: 11px;
    font-weight: 800;
    letter-spacing: 1px;
    text-transform: uppercase;
    margin-bottom: 10px;
    color: #94a3b8;
    display: flex;
    align-items: center;
    gap: 8px;
}

.analysis-section p {
    font-size: 15px;
    color: #e2e8f0;
    line-height: 1.8;
    margin: 0;
}

.dual-score-container {
    display: flex;
    gap: 16px;
    margin-bottom: 28px;
}

.mini-score {
    flex: 1;
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 16px;
    padding: 12px 16px;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 4px;
}

.mini-score .label {
    font-size: 11px;
    font-weight: 700;
    color: #94a3b8;
    text-transform: uppercase;
}

.mini-score .value {
    font-size: 18px;
    font-weight: 800;
    color: #fff;
}

/* Text Utils */
.text-accent {
    color: #818cf8 !important;
}

.text-success {
    color: #34d399 !important;
}

.warning-text {
    color: #facc15 !important;
}

/* Improvements List */
.improvements {
    list-style: none;
    padding: 0;
    margin: 0;
}

.improvements li {
    position: relative;
    font-size: 14px;
    color: #e2e8f0;
    margin-bottom: 12px;
    padding: 14px 14px 14px 24px;
    background: linear-gradient(90deg, rgba(16, 185, 129, 0.05), transparent);
    border-radius: 0 12px 12px 0;
    border-left: 3px solid #10b981;
    line-height: 1.6;
}

.improvements li::before {
    content: '';
    position: absolute;
    left: -4.5px;
    top: 50%;
    transform: translateY(-50%);
    width: 6px;
    height: 6px;
    border-radius: 50%;
    background: #34d399;
    box-shadow: 0 0 8px #34d399;
}

/* 5. PLATFORMS */
.platform-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 20px;
}

@media (max-width: 1024px) {
    .platform-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (max-width: 600px) {
    .platform-grid {
        grid-template-columns: 1fr;
    }
}

.platform-card {
    background: rgba(30, 41, 59, 0.5);
    border: 1px solid var(--glass-border);
    border-top: 3px solid var(--platform-color, #fff);
    border-radius: 20px;
    padding: 24px;
    transition: transform 0.2s;
}

.platform-card:hover {
    transform: translateY(-3px);
}

.platform-header {
    display: flex;
    align-items: center;
    gap: 10px;
    margin-bottom: 16px;
    font-weight: 700;
    color: #fff;
}

.platform-score {
    margin-left: auto;
    font-size: 13px;
    font-weight: 800;
    background: rgba(255, 255, 255, 0.1);
    padding: 4px 10px;
    border-radius: 8px;
}

.p-sec {
    margin-top: 12px;
}

.p-sec li {
    font-size: 13px;
    color: #cbd5e1;
    margin-bottom: 8px;
    padding-left: 16px;
    position: relative;
    line-height: 1.5;
}

.p-sec li::before {
    content: '•';
    position: absolute;
    left: 0;
    color: var(--platform-color);
    font-weight: bold;
}

/* 6. SCRIPTS & HOOKS */
.script-card,
.hook-item {
    background: rgba(30, 41, 59, 0.7);
    border: 1px solid var(--glass-border);
    border-radius: 20px;
    padding: 32px;
    margin-bottom: 24px;
}

.script-card.best-pick {
    background: linear-gradient(135deg, rgba(79, 70, 229, 0.1), rgba(15, 23, 42, 0.9));
    border: 1px solid #6366f1;
}

.script-header,
.hook-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 24px;
    padding-bottom: 16px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.05);
}

.script-content,
.hook-text {
    font-size: 16px;
    line-height: 1.8;
    color: #f1f5f9;
    white-space: pre-wrap;
}

/* 7. ACTION PLAN */
.action-box {
    background: linear-gradient(135deg, rgba(6, 78, 59, 0.15), rgba(15, 23, 42, 0.9));
    border: 1px solid rgba(16, 185, 129, 0.3);
    border-radius: 30px;
    padding: 40px;
}

.action-list li {
    background: rgba(15, 23, 42, 0.5);
    border: 1px solid var(--glass-border);
    padding: 18px 24px;
    border-radius: 16px;
    margin-bottom: 16px;
    font-size: 15px;
    color: #e2e8f0;
    line-height: 1.6;
    display: flex;
    gap: 16px;
}

.action-list li i {
    color: #34d399;
    font-size: 22px;
    margin-top: 2px;
    flex-shrink: 0;
}

/* 8. POLICY RESULT PRO (ADDED V4.3) */
.policy-card-pro {
    background: linear-gradient(135deg, rgba(15, 23, 42, 0.95), rgba(0, 0, 0, 0.9));
    border: 1px solid var(--glass-border);
    border-radius: 32px;
    padding: 40px;
    margin-bottom: 40px;
    box-shadow: 0 20px 60px -10px rgba(0, 0, 0, 0.6);
    position: relative;
    overflow: hidden;
}

.policy-card-pro.safe {
    border-color: rgba(16, 185, 129, 0.3);
    box-shadow: 0 0 40px rgba(16, 185, 129, 0.1);
}

.policy-card-pro.violation {
    border-color: rgba(239, 68, 68, 0.3);
    box-shadow: 0 0 40px rgba(239, 68, 68, 0.1);
}

.policy-card-pro.warning {
    border-color: rgba(245, 158, 11, 0.3);
    box-shadow: 0 0 40px rgba(245, 158, 11, 0.1);
}

.policy-header-pro {
    display: flex;
    align-items: center;
    gap: 24px;
    margin-bottom: 32px;
    padding-bottom: 24px;
    border-bottom: 1px solid var(--glass-border);
}

.policy-icon-wrapper {
    width: 64px;
    height: 64px;
    border-radius: 20px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 32px;
}

.safe .policy-icon-wrapper {
    background: rgba(16, 185, 129, 0.15);
    color: #34d399;
    border: 1px solid rgba(16, 185, 129, 0.2);
}

.violation .policy-icon-wrapper {
    background: rgba(239, 68, 68, 0.15);
    color: #ef4444;
    border: 1px solid rgba(239, 68, 68, 0.2);
}

.warning .policy-icon-wrapper {
    background: rgba(245, 158, 11, 0.15);
    color: #f59e0b;
    border: 1px solid rgba(245, 158, 11, 0.2);
}

.policy-label-small {
    font-size: 11px;
    font-weight: 800;
    letter-spacing: 2px;
    text-transform: uppercase;
    color: #94a3b8;
    display: block;
    margin-bottom: 4px;
}

.policy-status-text {
    font-size: 28px;
    font-weight: 800;
    margin: 0;
    letter-spacing: -1px;
}

.safe .policy-status-text {
    background: linear-gradient(90deg, #34d399, #10b981);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
}

.violation .policy-status-text {
    background: linear-gradient(90deg, #f87171, #ef4444);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
}

.warning .policy-status-text {
    background: linear-gradient(90deg, #fbbf24, #f59e0b);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
}

/* Safe Badge */
.safe-badge-pro {
    background: rgba(16, 185, 129, 0.1);
    border: 1px solid rgba(16, 185, 129, 0.2);
    padding: 16px 24px;
    border-radius: 16px;
    display: flex;
    align-items: center;
    gap: 12px;
    color: #34d399;
    font-weight: 700;
}

.safe-badge-pro i {
    font-size: 24px;
}

/* Violations Grid */
.violations-grid {
    display: grid;
    gap: 16px;
    margin-top: 16px;
}

.violation-card {
    background: rgba(239, 68, 68, 0.1);
    border-left: 4px solid #ef4444 !important;
    padding: 16px 20px;
    border-radius: 0 12px 12px 0;
}

/* SCRIPT SELECTION MODAL */
.script-selection-modal {
    position: fixed;
    top: 0;
    left: 0;
    width: 100vw;
    height: 100vh;
    background: rgba(10, 10, 20, 0.95);
    backdrop-filter: blur(10px);
    z-index: 9999;
    display: flex;
    justify-content: center;
    align-items: center;
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.3s ease;
}

.script-selection-modal.active {
    opacity: 1;
    pointer-events: all;
}

/* WAITING STATE - NEON ORB */
.waiting-container {
    text-align: center;
    position: relative;
    z-index: 10;
}

.neon-orb {
    width: 120px;
    height: 120px;
    margin: 0 auto 30px;
    background: radial-gradient(circle at 30% 30%, rgba(6, 182, 212, 0.8), rgba(59, 130, 246, 0.4));
    border-radius: 50%;
    box-shadow:
        0 0 60px rgba(6, 182, 212, 0.6),
        inset 0 0 40px rgba(6, 182, 212, 0.8);
    animation: orbPulse 2s infinite ease-in-out, orbSpin 10s linear infinite;
    position: relative;
}

.neon-orb::before {
    content: '';
    position: absolute;
    top: -10%;
    left: -10%;
    width: 120%;
    height: 120%;
    border-radius: 50%;
    border-top: 2px solid rgba(255, 255, 255, 0.8);
    border-right: 2px solid transparent;
    animation: orbSpin 3s linear infinite reverse;
    filter: drop-shadow(0 0 10px #06b6d4);
}

.neon-orb::after {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: 60%;
    height: 60%;
    background: radial-gradient(circle, #fff, rgba(6, 182, 212, 0));
    opacity: 0.8;
    filter: blur(10px);
    animation: corePulse 1.5s infinite alternate;
}

@keyframes orbPulse {

    0%,
    100% {
        transform: scale(1);
        box-shadow: 0 0 60px rgba(6, 182, 212, 0.6);
    }

    50% {
        transform: scale(1.1);
        box-shadow: 0 0 100px rgba(6, 182, 212, 0.8), 0 0 20px rgba(255, 255, 255, 0.5);
    }
}

@keyframes orbSpin {
    0% {
        transform: rotate(0deg);
    }

    100% {
        transform: rotate(360deg);
    }
}

@keyframes corePulse {
    0% {
        opacity: 0.5;
        transform: translate(-50%, -50%) scale(0.8);
    }

    100% {
        opacity: 1;
        transform: translate(-50%, -50%) scale(1.2);
    }
}

.scanning-title {
    font-size: 24px;
    font-weight: 700;
    color: #fff;
    margin: 0;
    background: linear-gradient(to right, #fff, #a5f3fc);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    text-shadow: 0 0 30px rgba(6, 182, 212, 0.5);
}


.selection-content {
    background: rgba(30, 41, 59, 0.5);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 24px;
    padding: 40px;
    max-width: 900px;
    width: 90%;
    box-shadow: 0 20px 50px rgba(0, 0, 0, 0.5);
}

.selection-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 20px;
    max-height: 70vh;
    overflow-y: auto;
    padding-right: 10px;
}

.framework-card {
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 16px;
    padding: 24px;
    cursor: pointer;
    transition: all 0.2s ease;
    position: relative;
    overflow: hidden;
}

.framework-card:hover {
    background: rgba(255, 255, 255, 0.1);
    border-color: rgba(99, 102, 241, 0.5);
    transform: translateY(-2px);
}

.framework-card.featured {
    border: 1px solid rgba(244, 63, 94, 0.5);
    background: linear-gradient(135deg, rgba(244, 63, 94, 0.1), rgba(10, 10, 20, 0.5));
}

.framework-icon {
    font-size: 32px;
    margin-bottom: 16px;
    display: block;
}

/* Scrollbar for grid */
.selection-grid::-webkit-scrollbar {
    width: 6px;
}

.selection-grid::-webkit-scrollbar-thumb {
    background: rgba(255, 255, 255, 0.2);
    border-radius: 3px;
}

@media (max-width: 600px) {
    .selection-content {
        padding: 24px 16px;
        width: 95%;
    }

    .selection-grid {
        grid-template-columns: 1fr;
        gap: 12px;
    }

    .framework-card {
        padding: 16px;
    }

    .scanning-title {
        font-size: 20px;
        line-height: 1.4;
        padding: 0 20px;
    }

    .neon-orb {
        width: 80px;
        height: 80px;
    }
}

/* === FUTURISTIC WARNING CARD (V5.3) === */
.ai-warning-card {
    position: relative;
    background: rgba(15, 23, 42, 0.6);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    border: 1px solid rgba(239, 68, 68, 0.2);
    border-radius: 24px;
    padding: 40px;
    text-align: center;
    overflow: hidden;
    box-shadow: 0 0 40px rgba(239, 68, 68, 0.05), inset 0 0 20px rgba(239, 68, 68, 0.05);
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 24px;
    max-width: 600px;
    margin: 40px auto;
}

.ai-warning-card::before {
    content: '';
    position: absolute;
    inset: 0;
    border-radius: 24px;
    padding: 1px;
    background: linear-gradient(135deg, rgba(239, 68, 68, 0.5), transparent 40%, transparent 60%, rgba(239, 68, 68, 0.5));
    -webkit-mask: linear-gradient(#fff 0 0) content-box, linear-gradient(#fff 0 0);
    -webkit-mask-composite: xor;
    mask-composite: exclude;
    pointer-events: none;
    opacity: 0.8;
}

.warning-icon-wrapper {
    position: relative;
    width: 80px;
    height: 80px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    background: rgba(239, 68, 68, 0.1);
    border: 1px solid rgba(239, 68, 68, 0.3);
    color: #ef4444;
    font-size: 32px;
    z-index: 2;
}

.warning-icon-wrapper i {
    animation: icon-float 3s ease-in-out infinite;
}

.pulse-ring {
    position: absolute;
    width: 100%;
    height: 100%;
    border-radius: 50%;
    border: 2px solid #ef4444;
    opacity: 0;
    animation: pulse-red 2s infinite;
}

@keyframes pulse-red {
    0% {
        transform: scale(1);
        opacity: 0.5;
    }

    100% {
        transform: scale(2);
        opacity: 0;
    }
}

@keyframes icon-float {

    0%,
    100% {
        transform: translateY(0);
    }

    50% {
        transform: translateY(-5px);
    }
}

.warning-content h3 {
    font-size: 24px;
    font-weight: 700;
    color: white;
    margin: 0 0 8px 0;
    letter-spacing: -0.5px;
}

.text-gradient-red {
    background: linear-gradient(135deg, #ef4444, #fca5a5);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    font-family: 'Plus Jakarta Sans', sans-serif;
    letter-spacing: 1px;
}

.warning-content p {
    color: #cbd5e1;
    font-size: 16px;
    line-height: 1.6;
    margin: 0;
}

.warning-content .sub-text {
    font-size: 13px;
    color: #94a3b8;
    opacity: 0.8;
}


.tech-divider {
    height: 1px;
    width: 100px;
    background: linear-gradient(90deg, transparent, rgba(239, 68, 68, 0.5), transparent);
    margin: 16px auto;
}

.btn-cyberbox {
    position: relative;
    background: linear-gradient(135deg, #ef4444, #dc2626);
    border: none;
    border-radius: 12px;
    padding: 14px 28px;
    color: white;
    font-weight: 600;
    font-size: 15px;
    cursor: pointer;
    overflow: hidden;
    transition: all 0.3s ease;
    box-shadow: 0 4px 15px rgba(239, 68, 68, 0.3);
}

.btn-cyberbox:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 25px rgba(239, 68, 68, 0.5);
    letter-spacing: 0.5px;
}

.btn-cyberbox .btn-content {
    position: relative;
    z-index: 2;
    display: flex;
    align-items: center;
    gap: 8px;
}

.glitch-effect {
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.4), transparent);
    transform: skewX(-20deg);
    transition: 0.5s;
    z-index: 1;
}

.btn-cyberbox:hover .glitch-effect {
    left: 200%;
    transition: 0.5s;
}

.corner-accents span {
    position: absolute;
    width: 10px;
    height: 10px;
    border: 2px solid rgba(239, 68, 68, 0.4);
    transition: all 0.3s ease;
}

.corner-accents span:nth-child(1) {
    top: 10px;
    left: 10px;
    border-bottom: 0;
    border-right: 0;
}

.corner-accents span:nth-child(2) {
    top: 10px;
    right: 10px;
    border-bottom: 0;
    border-left: 0;
}

.corner-accents span:nth-child(3) {
    bottom: 10px;
    left: 10px;
    border-top: 0;
    border-right: 0;
}

.corner-accents span:nth-child(4) {
    bottom: 10px;
    right: 10px;
    border-top: 0;
    border-left: 0;
}

.ai-warning-card:hover .corner-accents span {
    width: 15px;
    height: 15px;
    border-color: #ef4444;
}



/* VIDEO PREVIEW CARD (Fix Layout & Click) */
.video-preview-card {
    background: rgba(17, 24, 39, 0.95);
    border: 1px solid var(--glass-border);
    border-radius: 20px;
    padding: 24px;
    margin-top: 24px;
    position: relative;
    max-width: 100%;
    overflow: hidden;
}

.preview-layout {
    display: flex;
    gap: 24px;
    align-items: flex-start;
}

@media (max-width: 768px) {
    .preview-layout {
        flex-direction: column;
    }
}

.preview-thumbnail-wrap {
    width: 200px;
    flex-shrink: 0;
    aspect-ratio: 9/16;
    background: #000;
    border-radius: 12px;
    overflow: hidden;
    position: relative;
    cursor: pointer;
    border: 2px solid rgba(255, 255, 255, 0.1);
    transition: all 0.3s ease;
}

.preview-thumbnail-wrap:hover {
    border-color: var(--primary-glow);
    transform: scale(1.02);
}

.preview-thumbnail-wrap.playing {
    border-color: #ef4444;
    cursor: default;
}

.preview-thumbnail,
.preview-poster {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

video.preview-thumbnail {
    display: none;
    z-index: 20;
    position: relative;
}

.video-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.3);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 10;
    pointer-events: none;
}

.video-overlay i {
    font-size: 48px;
    color: white;
    filter: drop-shadow(0 4px 10px rgba(0, 0, 0, 0.5));
    opacity: 0.9;
    transition: transform 0.2s;
}

.preview-thumbnail-wrap:hover .video-overlay i {
    transform: scale(1.1);
}

.preview-info {
    flex: 1;
    min-width: 0;
}

.preview-title {
    font-size: 18px;
    font-weight: 700;
    color: #fff;
    margin: 0 0 16px 0;
    line-height: 1.4;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.preview-meta-row {
    display: flex;
    gap: 20px;
    margin-bottom: 16px;
    flex-wrap: wrap;
}

.preview-meta-item {
    display: flex;
    flex-direction: column;
    gap: 4px;
}

.meta-label {
    font-size: 10px;
    font-weight: 700;
    color: #94a3b8;
    text-transform: uppercase;
}

.meta-value {
    display: flex;
    align-items: center;
    gap: 8px;
    color: #e2e8f0;
    font-size: 14px;
    font-weight: 600;
}

.creator-avatar {
    width: 24px;
    height: 24px;
    border-radius: 50%;
    background: linear-gradient(135deg, #6366f1, #a855f7);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 10px;
    font-weight: bold;
    color: white;
}

.preview-stats {
    display: flex;
    gap: 16px;
    margin-top: 16px;
    background: rgba(255, 255, 255, 0.05);
    padding: 12px;
    border-radius: 12px;
    flex-wrap: wrap;
}

.stat-item {
    display: flex;
    align-items: center;
    gap: 6px;
    font-size: 13px;
    color: #cbd5e1;
}

.stat-item i {
    color: #94a3b8;
}

.preview-download-section {
    display: flex;
    gap: 10px;
    margin-top: 20px;
    flex-wrap: wrap;
}

.btn-download-link {
    background: rgba(30, 41, 59, 1);
    border: 1px solid rgba(255, 255, 255, 0.2);
    color: white;
    padding: 10px 20px;
    border-radius: 10px;
    font-size: 13px;
    font-weight: 600;
    display: flex;
    align-items: center;
    gap: 8px;
    cursor: pointer;
    transition: all 0.2s;
    flex: 1;
    justify-content: center;
    white-space: nowrap;
}

.btn-download-link.primary {
    background: #2563eb;
    border-color: #3b82f6;
}

.btn-download-link:hover {
    filter: brightness(1.1);
    transform: translateY(-2px);
}

.btn-close-preview {
    position: absolute;
    top: 12px;
    right: 12px;
    background: rgba(0, 0, 0, 0.5);
    border: none;
    color: #fff;
    width: 32px;
    height: 32px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    z-index: 30;
    transition: background 0.2s;
}

.btn-close-preview:hover {
    background: rgba(239, 68, 68, 0.8);
}

/* === UPGRADED SCRIPT FORMULAS SELECTION (V6.0) === */
.script-selection-modal {
    position: fixed;
    top: 0;
    left: 0;
    width: 100vw;
    height: 100vh;
    background: rgba(10, 10, 20, 0.95);
    backdrop-filter: blur(15px);
    z-index: 9999;
    display: flex;
    justify-content: center;
    align-items: center;
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.3s ease;
}

.script-selection-modal.active {
    opacity: 1;
    pointer-events: all;
}

.selection-content {
    background: rgba(30, 41, 59, 0.5);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 24px;
    padding: 32px;
    max-width: 1000px;
    width: 95%;
    box-shadow: 0 20px 50px rgba(0, 0, 0, 0.5);
}

.selection-grid-container {
    padding-right: 8px;
}

.selection-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 12px;
}

.framework-card {
    background: rgba(255, 255, 255, 0.03);
    border: 1px solid rgba(255, 255, 255, 0.08);
    border-radius: 16px;
    padding: 16px;
    cursor: pointer;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    position: relative;
    overflow: hidden;
    display: flex;
    gap: 12px;
    align-items: flex-start;
}

.framework-card:hover {
    background: rgba(255, 255, 255, 0.08);
    border-color: rgba(255, 255, 255, 0.2);
    transform: translateY(-4px);
    box-shadow: 0 10px 30px -10px rgba(0, 0, 0, 0.5);
}

.framework-card.featured {
    border: 1px solid rgba(52, 211, 153, 0.3);
    background: linear-gradient(135deg, rgba(52, 211, 153, 0.05), rgba(15, 23, 42, 0.4));
}

.framework-icon-wrapper {
    width: 40px;
    height: 40px;
    border-radius: 10px;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
}

.framework-icon {
    font-size: 20px;
    margin: 0 !important;
}

.framework-info {
    flex: 1;
    min-width: 0;
}

.featured-tag {
    position: absolute;
    top: 0;
    right: 0;
    background: #34d399;
    color: #020617;
    font-size: 8px;
    font-weight: 800;
    padding: 2px 8px;
    border-radius: 0 0 0 8px;
    letter-spacing: 0.5px;
}

/* Scrollbar for grid */
.selection-grid-container::-webkit-scrollbar {
    width: 4px;
}

.selection-grid-container::-webkit-scrollbar-thumb {
    background: rgba(255, 255, 255, 0.1);
    border-radius: 2px;
}

@media (max-width: 900px) {
    .selection-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (max-width: 600px) {
    .selection-content {
        padding: 20px 12px;
    }

    .selection-grid {
        grid-template-columns: 1fr;
    }

    .framework-card {
        padding: 12px;
    }
}

/* VIDEO PREVIEW CARD (AI Analysis) */
.video-preview-ai {
    margin-top: 16px;
    background: rgba(17, 24, 39, 0.9);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 16px;
    padding: 16px;
    animation: slideDown 0.3s ease-out;
}

.video-preview-ai .preview-loading {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 12px;
    padding: 20px;
    color: var(--text-muted);
}

.video-preview-ai .preview-loading i {
    font-size: 20px;
    color: var(--primary);
}

.video-preview-ai .preview-content {
    display: flex;
    align-items: center;
    gap: 16px;
}

.video-preview-ai .preview-thumb-container {
    position: relative;
    width: 100px;
    height: 130px;
    border-radius: 12px;
    overflow: hidden;
    flex-shrink: 0;
    background: rgba(0, 0, 0, 0.3);
}

.video-preview-ai .preview-thumb-container img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.video-preview-ai .preview-play-icon {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    font-size: 32px;
    color: white;
    opacity: 0.9;
    text-shadow: 0 2px 8px rgba(0, 0, 0, 0.5);
}

.video-preview-ai .preview-duration {
    position: absolute;
    bottom: 6px;
    right: 6px;
    background: rgba(0, 0, 0, 0.8);
    color: white;
    padding: 2px 6px;
    border-radius: 4px;
    font-size: 11px;
    font-weight: 600;
}

.video-preview-ai .preview-info-container {
    flex: 1;
    min-width: 0;
}

.video-preview-ai .preview-info-container h4 {
    font-size: 15px;
    font-weight: 700;
    color: white;
    margin: 0 0 8px 0;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.video-preview-ai .preview-meta {
    display: flex;
    align-items: center;
    gap: 10px;
    margin-bottom: 10px;
}

.video-preview-ai .platform-badge {
    background: rgba(99, 102, 241, 0.15);
    color: #818cf8;
    padding: 4px 10px;
    border-radius: 6px;
    font-size: 11px;
    font-weight: 600;
    display: inline-flex;
    align-items: center;
    gap: 4px;
}

.video-preview-ai .preview-meta span:last-child {
    color: var(--text-muted);
    font-size: 13px;
}

.video-preview-ai .preview-stats-mini {
    display: flex;
    gap: 16px;
}

.video-preview-ai .preview-stats-mini span {
    display: flex;
    align-items: center;
    gap: 4px;
    font-size: 12px;
    color: var(--text-muted);
}

.video-preview-ai .preview-stats-mini i {
    font-size: 14px;
}

.video-preview-ai .btn-close-preview-mini {
    background: rgba(239, 68, 68, 0.1);
    border: none;
    color: #ef4444;
    width: 32px;
    height: 32px;
    border-radius: 8px;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
    transition: background 0.2s;
}

.video-preview-ai .btn-close-preview-mini:hover {
    background: rgba(239, 68, 68, 0.2);
}

@keyframes slideDown {
    from {
        opacity: 0;
        transform: translateY(-10px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* Mobile: Video Preview Card Fixes */
@media (max-width: 600px) {
    .video-preview-ai {
        padding: 12px;
    }

    .video-preview-ai .preview-content {
        flex-direction: column;
        align-items: stretch;
        gap: 12px;
    }

    .video-preview-ai .preview-thumb-container {
        width: 100%;
        height: 180px;
        max-width: 200px;
        margin: 0 auto;
    }

    .video-preview-ai .preview-info-container {
        text-align: center;
    }

    .video-preview-ai .preview-info-container h4 {
        font-size: 14px;
        white-space: normal;
        -webkit-line-clamp: 2;
        display: -webkit-box;
        -webkit-box-orient: vertical;
        overflow: hidden;
    }

    .video-preview-ai .preview-meta {
        justify-content: center;
        flex-wrap: wrap;
    }

    .video-preview-ai .preview-stats-mini {
        justify-content: center;
        flex-wrap: wrap;
        gap: 12px;
    }

    .video-preview-ai .btn-close-preview-mini {
        position: absolute;
        top: 8px;
        right: 8px;
    }

    /* Video Preview Card (detailed) */
    .video-preview-card {
        padding: 16px;
    }

    .preview-thumbnail-wrap {
        width: 100%;
        max-width: 180px;
        margin: 0 auto;
    }

    .preview-title {
        font-size: 15px;
        text-align: center;
    }

    .preview-meta-row {
        justify-content: center;
    }

    .preview-stats {
        justify-content: center;
    }

    .preview-download-section {
        flex-direction: column;
    }

    .btn-download-link {
        width: 100%;
    }
}

/* ============================================ */
/* PREMIUM VIRAL HOOKS RESULT STYLES (V5.0)    */
/* ============================================ */

.hooks-result {
    animation: fadeInUp 0.5s ease-out;
}

.hooks-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 24px;
    padding-bottom: 16px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.06);
}

.hooks-header h4 {
    font-size: 20px;
    font-weight: 700;
    color: white;
    margin: 0;
    display: flex;
    align-items: center;
    gap: 12px;
}

.hooks-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(340px, 1fr));
    gap: 20px;
    margin-bottom: 32px;
}

@media (max-width: 768px) {
    .hooks-grid {
        grid-template-columns: 1fr;
    }
}

.hook-card {
    background: linear-gradient(135deg, rgba(15, 23, 42, 0.9) 0%, rgba(30, 41, 59, 0.7) 100%);
    border: 1px solid rgba(255, 255, 255, 0.08);
    border-radius: 20px;
    padding: 24px;
    position: relative;
    overflow: hidden;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

.hook-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 3px;
    background: linear-gradient(90deg, #6366f1, #8b5cf6);
    opacity: 0;
    transition: opacity 0.3s ease;
}

.hook-card:hover {
    transform: translateY(-4px);
    border-color: rgba(99, 102, 241, 0.4);
    box-shadow: 0 12px 40px -10px rgba(99, 102, 241, 0.25);
}

.hook-card:hover::before {
    opacity: 1;
}

.hook-card.top-recommended {
    background: linear-gradient(135deg, rgba(99, 102, 241, 0.15) 0%, rgba(15, 23, 42, 0.95) 100%);
    border-color: rgba(99, 102, 241, 0.4);
}

.hook-card.top-recommended::before {
    opacity: 1;
    background: linear-gradient(90deg, #facc15, #f59e0b);
}

.hook-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 16px;
    gap: 12px;
}

.hook-type {
    font-size: 11px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 1.5px;
    color: #a5b4fc;
    background: rgba(99, 102, 241, 0.15);
    padding: 6px 12px;
    border-radius: 8px;
    border: 1px solid rgba(99, 102, 241, 0.2);
}

.top-badge {
    font-size: 11px;
    font-weight: 800;
    color: #facc15;
    background: rgba(250, 204, 21, 0.15);
    padding: 6px 12px;
    border-radius: 8px;
    border: 1px solid rgba(250, 204, 21, 0.3);
    display: flex;
    align-items: center;
    gap: 6px;
    animation: pulse 2s infinite;
}

@keyframes pulse {

    0%,
    100% {
        box-shadow: 0 0 0 0 rgba(250, 204, 21, 0.4);
    }

    50% {
        box-shadow: 0 0 0 8px rgba(250, 204, 21, 0);
    }
}

.hook-text {
    font-size: 17px;
    font-weight: 600;
    line-height: 1.6;
    color: #f1f5f9;
    margin: 0 0 16px 0;
    padding: 16px;
    background: rgba(0, 0, 0, 0.2);
    border-radius: 12px;
    border-left: 3px solid #6366f1;
    font-style: italic;
}

.hook-meta {
    font-size: 13px;
    line-height: 1.7;
    color: #94a3b8;
    margin-bottom: 12px;
    padding: 12px 16px;
    background: rgba(255, 255, 255, 0.03);
    border-radius: 10px;
}

.hook-meta strong {
    color: #e2e8f0;
    font-weight: 600;
    display: block;
    margin-bottom: 4px;
}

.btn-copy-hook {
    width: 100%;
    margin-top: 16px;
    padding: 12px 20px;
    background: rgba(99, 102, 241, 0.1);
    border: 1px solid rgba(99, 102, 241, 0.3);
    border-radius: 10px;
    color: #a5b4fc;
    font-size: 13px;
    font-weight: 600;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    transition: all 0.2s ease;
}

.btn-copy-hook:hover {
    background: rgba(99, 102, 241, 0.2);
    border-color: rgba(99, 102, 241, 0.5);
    color: white;
    transform: translateY(-2px);
}

.btn-copy-hook i {
    font-size: 15px;
}

/* Tips Section */
.ai-result-section {
    background: rgba(15, 23, 42, 0.6);
    border: 1px solid rgba(255, 255, 255, 0.06);
    border-radius: 16px;
    padding: 24px;
}

.ai-result-section h4 {
    font-size: 16px;
    font-weight: 700;
    color: white;
    margin: 0 0 16px 0;
    display: flex;
    align-items: center;
    gap: 10px;
}

.tips-list {
    list-style: none;
    padding: 0;
    margin: 0;
}

.tips-list li {
    position: relative;
    padding: 12px 12px 12px 24px;
    margin-bottom: 8px;
    font-size: 14px;
    line-height: 1.6;
    color: #e2e8f0;
    background: rgba(255, 255, 255, 0.03);
    border-radius: 8px;
    border-left: 2px solid #22d3ee;
}

.tips-list li::before {
    content: '💡';
    position: absolute;
    left: 10px;
    top: 12px;
    font-size: 12px;
}

@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(20px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}