/* ═══════════════════════════════════════════════════════════
   Security Toolkit — unified page styles
   ═══════════════════════════════════════════════════════════ */

/* ── Hero ───────────────────────────────────────────────── */
.tk-hero {
    padding: 4.5rem 0 2rem;
    text-align: center;
}
.tk-badge {
    display: inline-block;
    background: rgba(13,202,240,0.08);
    border: 1px solid rgba(13,202,240,0.2);
    border-radius: 20px;
    padding: 0.3rem 1rem;
    font-size: 0.8rem;
    font-weight: 600;
    color: #0dcaf0;
    margin-bottom: 1.25rem;
    letter-spacing: 0.3px;
}
.tk-hero h1 {
    font-family: 'Sora', sans-serif;
    font-size: 2.8rem;
    font-weight: 800;
    letter-spacing: -0.5px;
    margin-bottom: 1rem;
}
.tk-lead {
    font-size: 1.1rem;
    color: rgba(255,255,255,0.55);
    max-width: 620px;
    margin: 0 auto;
    line-height: 1.65;
}

/* ── Step tabs ──────────────────────────────────────────── */
.tk-steps {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0;
    margin: 2.5rem auto 3rem;
    max-width: 540px;
}
.tk-step {
    display: flex;
    align-items: center;
    gap: 0.6rem;
    padding: 0.75rem 1.5rem;
    border: 1px solid rgba(255,255,255,0.08);
    background: rgba(255,255,255,0.02);
    border-radius: 10px;
    cursor: pointer;
    transition: all 0.25s;
    color: rgba(255,255,255,0.45);
    font-size: 0.95rem;
    font-weight: 500;
}
.tk-step:hover {
    border-color: rgba(13,202,240,0.25);
    color: rgba(255,255,255,0.7);
}
.tk-step.active {
    background: rgba(13,202,240,0.06);
    border-color: rgba(13,202,240,0.35);
    color: #0dcaf0;
}
.tk-step-num {
    width: 28px;
    height: 28px;
    border-radius: 50%;
    background: rgba(255,255,255,0.06);
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 700;
    font-size: 0.85rem;
    flex-shrink: 0;
    transition: background 0.25s, color 0.25s;
}
.tk-step.active .tk-step-num {
    background: rgba(13,202,240,0.18);
    color: #0dcaf0;
}
.tk-step-connector {
    width: 40px;
    height: 2px;
    background: rgba(255,255,255,0.08);
    flex-shrink: 0;
}

/* ── Panels ─────────────────────────────────────────────── */
.tk-panel {
    animation: tkFadeIn 0.3s ease;
}
@keyframes tkFadeIn {
    from { opacity: 0; transform: translateY(8px); }
    to   { opacity: 1; transform: translateY(0); }
}

/* ── Sections ───────────────────────────────────────────── */
.tk-section {
    margin-bottom: 3.5rem;
}
.tk-section-title {
    font-family: 'Sora', sans-serif;
    font-size: 1.35rem;
    font-weight: 700;
    margin-bottom: 1.5rem;
    padding-bottom: 0.75rem;
    border-bottom: 1px solid rgba(255,255,255,0.06);
    color: rgba(255,255,255,0.85);
}
.tk-section-title i {
    color: #0dcaf0;
    margin-right: 0.4rem;
    font-size: 1.1rem;
}

/* ── Install block ──────────────────────────────────────── */
.tk-install {
    max-width: 640px;
}
.tk-install-cmd {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    background: rgba(0,0,0,0.5);
    border: 1px solid rgba(255,255,255,0.08);
    border-radius: 10px;
    padding: 1rem 1.25rem;
}
.tk-install-cmd code {
    flex: 1;
    font-family: 'JetBrains Mono', monospace;
    font-size: 0.9rem;
    color: #0dcaf0;
    user-select: all;
    background: none;
}
.tk-copy-btn {
    background: rgba(255,255,255,0.06);
    border: 1px solid rgba(255,255,255,0.1);
    border-radius: 6px;
    color: rgba(255,255,255,0.45);
    padding: 0.35rem 0.6rem;
    cursor: pointer;
    font-size: 0.8rem;
    transition: all 0.2s;
    flex-shrink: 0;
}
.tk-copy-btn:hover {
    color: #0dcaf0;
    border-color: rgba(13,202,240,0.3);
    background: rgba(13,202,240,0.06);
}
.tk-copy-btn.copied {
    color: #2ecc71;
    border-color: rgba(46,204,113,0.3);
}
.tk-install-note {
    font-size: 0.8rem;
    color: rgba(255,255,255,0.35);
    margin-top: 0.6rem;
}

/* ── Check grid ─────────────────────────────────────────── */
.tk-check-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 1rem;
}
@media (max-width: 640px) {
    .tk-check-grid { grid-template-columns: 1fr; }
}
.tk-check-card {
    display: flex;
    gap: 1rem;
    align-items: flex-start;
    background: rgba(255,255,255,0.02);
    border: 1px solid rgba(255,255,255,0.05);
    border-radius: 10px;
    padding: 1.25rem;
    transition: border-color 0.2s;
}
.tk-check-card:hover {
    border-color: rgba(255,255,255,0.12);
}
.tk-check-icon {
    width: 38px;
    height: 38px;
    border-radius: 9px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1rem;
    flex-shrink: 0;
}
.tk-check-icon.blue   { background: rgba(52,152,219,0.12);  color: #3498db; }
.tk-check-icon.red    { background: rgba(231,76,60,0.12);   color: #e74c3c; }
.tk-check-icon.amber  { background: rgba(243,156,18,0.12);  color: #f39c12; }
.tk-check-icon.purple { background: rgba(155,89,182,0.12);  color: #9b59b6; }
.tk-check-card h4 {
    font-size: 0.95rem;
    font-weight: 600;
    margin-bottom: 0.25rem;
}
.tk-check-card p {
    font-size: 0.82rem;
    color: rgba(255,255,255,0.45);
    margin: 0;
    line-height: 1.5;
}

/* ── Usage grid ─────────────────────────────────────────── */
.tk-usage-grid {
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
    max-width: 640px;
}
.tk-usage-item {
    display: flex;
    align-items: center;
    gap: 1rem;
    flex-wrap: wrap;
}
.tk-usage-cmd {
    display: flex;
    align-items: center;
    gap: 0.4rem;
    background: rgba(0,0,0,0.4);
    border: 1px solid rgba(255,255,255,0.06);
    border-radius: 8px;
    padding: 0.6rem 0.9rem;
    flex-shrink: 0;
}
.tk-usage-cmd code {
    font-family: 'JetBrains Mono', monospace;
    font-size: 0.82rem;
    color: #0dcaf0;
    background: none;
}
.tk-usage-desc {
    font-size: 0.82rem;
    color: rgba(255,255,255,0.4);
}

/* ── Terminal preview ───────────────────────────────────── */
.tk-terminal {
    background: #0d1117;
    border: 1px solid rgba(255,255,255,0.08);
    border-radius: 10px;
    overflow: hidden;
    max-width: 640px;
}
.tk-terminal-bar {
    display: flex;
    gap: 6px;
    padding: 10px 14px;
    background: rgba(255,255,255,0.04);
    border-bottom: 1px solid rgba(255,255,255,0.06);
}
.tk-terminal-bar span {
    width: 10px;
    height: 10px;
    border-radius: 50%;
    background: rgba(255,255,255,0.1);
}
.tk-terminal-bar span:first-child { background: #ff5f57; }
.tk-terminal-bar span:nth-child(2) { background: #febc2e; }
.tk-terminal-bar span:nth-child(3) { background: #28c840; }
.tk-terminal pre {
    padding: 1.25rem;
    margin: 0;
    font-family: 'JetBrains Mono', monospace;
    font-size: 0.75rem;
    line-height: 1.65;
    color: rgba(255,255,255,0.7);
    overflow-x: auto;
}
.tk-terminal .pass { color: #2ecc71; }
.tk-terminal .warn { color: #f39c12; }
.tk-terminal .crit { color: #e74c3c; }
.tk-terminal .dim  { color: rgba(255,255,255,0.3); }
.tk-terminal .cyan { color: #0dcaf0; }

/* ── Next-step nudge ────────────────────────────────────── */
.tk-next-step {
    margin-top: 1.5rem;
    padding: 1.25rem 1.5rem;
    background: rgba(13,202,240,0.04);
    border: 1px solid rgba(13,202,240,0.12);
    border-radius: 10px;
    display: flex;
    align-items: center;
    gap: 1rem;
    max-width: 640px;
}
.tk-next-step p {
    margin: 0;
    font-size: 0.88rem;
    color: rgba(255,255,255,0.5);
    flex: 1;
}

/* ── FAQ (accordion) ────────────────────────────────────── */
.tk-faq {
    max-width: 640px;
}
.tk-faq details {
    border-bottom: 1px solid rgba(255,255,255,0.05);
}
.tk-faq details:last-child { border-bottom: none; }
.tk-faq summary {
    padding: 1rem 0;
    font-size: 0.95rem;
    font-weight: 600;
    cursor: pointer;
    color: rgba(255,255,255,0.75);
    list-style: none;
    display: flex;
    align-items: center;
    justify-content: space-between;
}
.tk-faq summary::-webkit-details-marker { display: none; }
.tk-faq summary::after {
    content: "\f078";
    font-family: "Font Awesome 5 Free";
    font-weight: 900;
    font-size: 0.7rem;
    color: rgba(255,255,255,0.25);
    transition: transform 0.25s;
}
.tk-faq details[open] summary::after {
    transform: rotate(180deg);
}
.tk-faq details p {
    padding: 0 0 1rem;
    margin: 0;
    font-size: 0.88rem;
    color: rgba(255,255,255,0.5);
    line-height: 1.6;
}

/* ── Privacy note ───────────────────────────────────────── */
.tk-privacy-note {
    text-align: center;
    margin-top: 1rem;
    font-size: 0.78rem;
    color: rgba(255,255,255,0.3);
}
.tk-privacy-note i {
    margin-right: 0.3rem;
    color: #2ecc71;
}

/* ── Bottom CTA ─────────────────────────────────────────── */
.tk-bottom-cta {
    text-align: center;
    padding: 3rem 2rem;
    border-radius: 14px;
    background: linear-gradient(135deg, rgba(13,202,240,0.05), rgba(13,110,253,0.05));
    border: 1px solid rgba(13,202,240,0.12);
    margin: 1rem 0 4rem;
}
.tk-bottom-cta-inner {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 2.5rem;
    flex-wrap: wrap;
    text-align: left;
}
.tk-bottom-cta-inner h3 {
    font-family: 'Sora', sans-serif;
    font-size: 1.35rem;
    font-weight: 700;
    margin-bottom: 0.3rem;
}
.tk-bottom-cta-inner p {
    color: rgba(255,255,255,0.45);
    margin: 0;
    font-size: 0.9rem;
    max-width: 380px;
}
.tk-bottom-cta-actions {
    display: flex;
    gap: 0.75rem;
    flex-shrink: 0;
}
.tk-trust-row {
    display: flex;
    gap: 1.5rem;
    justify-content: center;
    flex-wrap: wrap;
    margin-top: 1.5rem;
    padding-top: 1.25rem;
    border-top: 1px solid rgba(255,255,255,0.05);
}
.tk-trust-row span {
    font-size: 0.78rem;
    color: rgba(255,255,255,0.35);
}
.tk-trust-row i {
    color: #2ecc71;
    margin-right: 0.25rem;
}


/* ═══════════════════════════════════════════════════════════
   Report viewer styles (Step 2)
   ═══════════════════════════════════════════════════════════ */

/* Upload / paste area */
.scan-input-area {
    max-width: 640px;
    margin: 0 auto;
}
.scan-drop-zone {
    border: 2px dashed rgba(255,255,255,0.12);
    border-radius: 12px;
    padding: 2.5rem 2rem;
    text-align: center;
    cursor: pointer;
    transition: border-color 0.2s, background 0.2s;
    background: rgba(255,255,255,0.015);
}
.scan-drop-zone:hover,
.scan-drop-zone.drag-over {
    border-color: #0dcaf0;
    background: rgba(13,202,240,0.03);
}
.scan-drop-zone .drop-icon {
    font-size: 2.2rem;
    color: rgba(255,255,255,0.2);
    margin-bottom: 0.75rem;
}
.scan-drop-zone .drop-text {
    font-size: 1rem;
    color: rgba(255,255,255,0.6);
    margin-bottom: 0.35rem;
}
.scan-drop-zone .drop-text code {
    font-size: 0.85rem;
    color: #0dcaf0;
    background: rgba(13,202,240,0.08);
    padding: 0.15rem 0.4rem;
    border-radius: 4px;
}
.scan-drop-zone .drop-hint {
    font-size: 0.8rem;
    color: rgba(255,255,255,0.3);
}
.scan-or-divider {
    text-align: center;
    color: rgba(255,255,255,0.25);
    margin: 1rem 0;
    font-size: 0.82rem;
}
.scan-paste-area textarea {
    width: 100%;
    min-height: 100px;
    background: rgba(255,255,255,0.03);
    border: 1px solid rgba(255,255,255,0.08);
    border-radius: 8px;
    color: #e0e0e0;
    font-family: 'JetBrains Mono', monospace;
    font-size: 0.78rem;
    padding: 0.9rem;
    resize: vertical;
}
.scan-paste-area textarea::placeholder {
    color: rgba(255,255,255,0.2);
}
.scan-paste-area textarea:focus {
    border-color: #0dcaf0;
    outline: none;
    box-shadow: 0 0 0 2px rgba(13,202,240,0.12);
}
.scan-analyze-btn {
    display: block;
    width: 100%;
    margin-top: 0.75rem;
    padding: 0.7rem;
    font-size: 0.95rem;
    font-weight: 600;
}
.scan-error {
    color: #e74c3c;
    background: rgba(231,76,60,0.06);
    border: 1px solid rgba(231,76,60,0.15);
    border-radius: 8px;
    padding: 0.7rem 0.9rem;
    margin-top: 0.75rem;
    font-size: 0.85rem;
    display: none;
}

/* Report section */
.scan-report {
    display: none;
    max-width: 900px;
    margin: 0 auto;
}
.scan-report.visible {
    display: block;
}

/* Score card */
.score-card {
    text-align: center;
    padding: 2.5rem 2rem;
    border-radius: 12px;
    background: rgba(255,255,255,0.025);
    border: 1px solid rgba(255,255,255,0.06);
    margin-bottom: 2rem;
}
.score-ring {
    position: relative;
    width: 140px;
    height: 140px;
    margin: 0 auto 1.5rem;
}
.score-ring svg {
    transform: rotate(-90deg);
}
.score-ring .score-bg {
    fill: none;
    stroke: rgba(255,255,255,0.06);
    stroke-width: 8;
}
.score-ring .score-fg {
    fill: none;
    stroke-width: 8;
    stroke-linecap: round;
    transition: stroke-dashoffset 1s ease-out, stroke 0.3s;
}
.score-ring .score-value {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    font-family: 'Sora', sans-serif;
    font-size: 2rem;
    font-weight: 700;
}
.score-ring .score-value small {
    font-size: 0.9rem;
    font-weight: 400;
    color: rgba(255,255,255,0.4);
}
.score-label {
    font-size: 1.15rem;
    font-weight: 600;
    margin-bottom: 0.4rem;
}
.score-meta {
    color: rgba(255,255,255,0.4);
    font-size: 0.82rem;
}

/* Severity pills */
.severity-pills {
    display: flex;
    justify-content: center;
    gap: 0.75rem;
    margin-top: 1.25rem;
    flex-wrap: wrap;
}
.severity-pill {
    display: flex;
    align-items: center;
    gap: 0.35rem;
    padding: 0.35rem 0.75rem;
    border-radius: 20px;
    font-size: 0.8rem;
    font-weight: 600;
    background: rgba(255,255,255,0.03);
    border: 1px solid rgba(255,255,255,0.06);
}
.severity-pill .pill-count { font-size: 0.95rem; }
.severity-pill.critical { color: #e74c3c; border-color: rgba(231,76,60,0.25); }
.severity-pill.warning  { color: #f39c12; border-color: rgba(243,156,18,0.25); }
.severity-pill.info     { color: #3498db; border-color: rgba(52,152,219,0.25); }
.severity-pill.pass     { color: #2ecc71; border-color: rgba(46,204,113,0.25); }

/* Category sections */
.category-section { margin-bottom: 2rem; }
.category-header {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    margin-bottom: 0.75rem;
    padding-bottom: 0.5rem;
    border-bottom: 1px solid rgba(255,255,255,0.06);
}
.category-header .cat-icon {
    width: 34px;
    height: 34px;
    border-radius: 8px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 0.9rem;
}
.category-header .cat-icon.access  { background: rgba(52,152,219,0.12); color: #3498db; }
.category-header .cat-icon.secrets { background: rgba(231,76,60,0.12);  color: #e74c3c; }
.category-header .cat-icon.config  { background: rgba(243,156,18,0.12); color: #f39c12; }
.category-header .cat-icon.risks   { background: rgba(155,89,182,0.12); color: #9b59b6; }
.category-header h3 {
    font-size: 1.1rem;
    font-weight: 600;
    margin: 0;
}
.category-header .cat-count {
    margin-left: auto;
    font-size: 0.78rem;
    color: rgba(255,255,255,0.4);
}

/* Finding cards */
.finding-card {
    background: rgba(255,255,255,0.02);
    border: 1px solid rgba(255,255,255,0.05);
    border-radius: 8px;
    padding: 0.9rem 1.1rem;
    margin-bottom: 0.5rem;
    display: flex;
    gap: 0.7rem;
    align-items: flex-start;
}
.finding-card .finding-icon {
    flex-shrink: 0;
    width: 22px;
    text-align: center;
    margin-top: 2px;
    font-size: 0.85rem;
}
.finding-card .finding-icon.critical { color: #e74c3c; }
.finding-card .finding-icon.warning  { color: #f39c12; }
.finding-card .finding-icon.info     { color: #3498db; }
.finding-card .finding-icon.pass     { color: #2ecc71; }
.finding-body { flex: 1; min-width: 0; }
.finding-body .finding-check {
    font-weight: 600;
    font-size: 0.9rem;
    margin-bottom: 0.1rem;
}
.finding-body .finding-desc {
    font-size: 0.82rem;
    color: rgba(255,255,255,0.5);
    margin-bottom: 0.25rem;
}
.finding-body .finding-remediation {
    font-size: 0.78rem;
    color: rgba(13,202,240,0.75);
    background: rgba(13,202,240,0.05);
    border-radius: 4px;
    padding: 0.35rem 0.55rem;
    margin-top: 0.35rem;
}
.finding-body .finding-remediation::before {
    content: "\f0ad";
    font-family: "Font Awesome 5 Free";
    font-weight: 900;
    margin-right: 0.35rem;
    font-size: 0.7rem;
}
.finding-severity {
    flex-shrink: 0;
    font-size: 0.65rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    padding: 0.18rem 0.45rem;
    border-radius: 4px;
}
.finding-severity.critical { background: rgba(231,76,60,0.12); color: #e74c3c; }
.finding-severity.warning  { background: rgba(243,156,18,0.12); color: #f39c12; }
.finding-severity.info     { background: rgba(52,152,219,0.12); color: #3498db; }
.finding-severity.pass     { background: rgba(46,204,113,0.12); color: #2ecc71; }

/* Actions bar */
.report-actions {
    display: flex;
    gap: 0.75rem;
    margin-bottom: 1.5rem;
    flex-wrap: wrap;
}
.report-actions .btn { font-weight: 600; }

/* Report CTA */
.scan-cta {
    text-align: center;
    padding: 2.5rem 2rem;
    border-radius: 12px;
    background: linear-gradient(135deg, rgba(13,202,240,0.06), rgba(13,110,253,0.06));
    border: 1px solid rgba(13,202,240,0.12);
    margin-top: 2rem;
}
.scan-cta h3 {
    font-family: 'Sora', sans-serif;
    font-size: 1.35rem;
    font-weight: 700;
    margin-bottom: 0.6rem;
}
.scan-cta p {
    color: rgba(255,255,255,0.5);
    max-width: 460px;
    margin: 0 auto 1.25rem;
    font-size: 0.9rem;
}

/* Print / PDF */
@media print {
    .navbar-main, .site-footer, .scan-input-area, .report-actions,
    .scan-cta, .tk-hero, .tk-steps, .tk-bottom-cta, .tk-privacy-note,
    #panel-download { display: none !important; }
    .scan-report { display: block !important; max-width: 100%; }
    .score-card { border: 1px solid #ccc; }
    .finding-card { border: 1px solid #ddd; break-inside: avoid; }
    body { background: #fff !important; color: #222 !important; }
    .score-ring .score-value, .category-header h3, .finding-body .finding-check {
        color: #222 !important;
    }
}
