/* SpiderFoot OSINT Tools - Terminal Style */

/* Base Styles */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
}

body {
    font-family: 'JetBrains Mono', 'Fira Code', monospace;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
    background-color: #121212;
}

/* Custom Scrollbar */
::-webkit-scrollbar {
    width: 10px;
}

::-webkit-scrollbar-track {
    background: #121212;
}

::-webkit-scrollbar-thumb {
    background: #00FF41;
    border-radius: 0;
}

::-webkit-scrollbar-thumb:hover {
    background: #00cc34;
}

/* Grid Pattern Background */
.bg-grid-pattern {
    background-image: 
        linear-gradient(rgba(0, 255, 65, 0.05) 1px, transparent 1px),
        linear-gradient(90deg, rgba(0, 255, 65, 0.05) 1px, transparent 1px);
    background-size: 50px 50px;
}

/* Animations */
@keyframes blob {
    0%, 100% {
        transform: translate(0, 0) scale(1);
    }
    33% {
        transform: translate(30px, -50px) scale(1.1);
    }
    66% {
        transform: translate(-20px, 20px) scale(0.9);
    }
}

.animate-blob {
    animation: blob 7s infinite;
}

.animation-delay-2000 {
    animation-delay: 2s;
}

.animation-delay-4000 {
    animation-delay: 4s;
}

@keyframes float {
    0%, 100% {
        transform: translateY(0px);
    }
    50% {
        transform: translateY(-20px);
    }
}

.animate-float {
    animation: float 3s ease-in-out infinite;
}

@keyframes pulse-glow {
    0%, 100% {
        box-shadow: 0 0 20px rgba(14, 165, 233, 0.3);
    }
    50% {
        box-shadow: 0 0 40px rgba(14, 165, 233, 0.5);
    }
}

.animate-pulse-glow {
    animation: pulse-glow 2s ease-in-out infinite;
}

/* Navigation Styles */
.nav-link {
    position: relative;
    font-weight: 600;
    letter-spacing: 0.05em;
}

.nav-link::after {
    content: '';
    position: absolute;
    bottom: -2px;
    left: 0;
    width: 0;
    height: 2px;
    background: #00FF41;
    transition: width 0.3s ease;
}

.nav-link:hover::after {
    width: 100%;
}

/* Button Styles */
.btn-primary {
    background: #00FF41;
    color: #121212;
    padding: 12px 24px;
    border-radius: 2px;
    font-weight: 700;
    transition: all 0.3s ease;
    border: 1px solid #00FF41;
    cursor: pointer;
    box-shadow: 0 0 20px rgba(0, 255, 65, 0.3);
    text-transform: uppercase;
    letter-spacing: 0.1em;
}

.btn-primary:hover {
    background: transparent;
    color: #00FF41;
    box-shadow: 0 0 30px rgba(0, 255, 65, 0.5);
}

.btn-primary:active {
    transform: scale(0.98);
}

/* Search Type Tabs */
.search-type-tab {
    cursor: pointer;
    user-select: none;
}

.search-type-tab:active {
    transform: scale(0.98);
}

/* Card Hover Effects */
.feature-card {
    transition: all 0.3s ease;
}

.feature-card:hover {
    transform: translateY(-5px);
}

/* Terminal Effect */
.terminal-effect {
    background: rgba(18, 18, 18, 0.8);
    backdrop-filter: blur(5px);
    -webkit-backdrop-filter: blur(5px);
    border: 1px solid rgba(0, 255, 65, 0.2);
}

/* Input Focus Glow */
input:focus,
textarea:focus,
select:focus {
    box-shadow: 0 0 0 2px rgba(0, 255, 65, 0.3);
    border-color: #00FF41;
}

/* Smooth Transitions */
a,
button,
input,
textarea,
select {
    transition: all 0.2s ease;
}

/* Loading Spinner */
.spinner {
    border: 3px solid rgba(0, 255, 65, 0.1);
    border-top-color: #00FF41;
    border-radius: 0;
    width: 40px;
    height: 40px;
    animation: spin 1s linear infinite;
}

@keyframes spin {
    to {
        transform: rotate(360deg);
    }
}

/* Text Selection */
::selection {
    background-color: rgba(0, 255, 65, 0.3);
    color: #121212;
}

::-moz-selection {
    background-color: rgba(0, 255, 65, 0.3);
    color: #121212;
}

/* Code Blocks */
code,
pre {
    font-family: 'JetBrains Mono', monospace;
    background: rgba(18, 18, 18, 0.9);
    padding: 2px 6px;
    border-radius: 0;
    font-size: 0.9em;
    border: 1px solid rgba(0, 255, 65, 0.2);
}

pre {
    padding: 16px;
    overflow-x: auto;
    border: 1px solid rgba(0, 255, 65, 0.3);
}

/* Terminal Text */
.terminal-text {
    color: #00FF41;
    font-family: 'JetBrains Mono', monospace;
    text-shadow: 0 0 5px rgba(0, 255, 65, 0.5);
}

/* Badge Styles */
.badge {
    display: inline-flex;
    align-items: center;
    padding: 4px 12px;
    border-radius: 2px;
    font-size: 0.875rem;
    font-weight: 700;
    letter-spacing: 0.05em;
}

.badge-primary {
    background: rgba(0, 255, 65, 0.1);
    color: #00FF41;
    border: 1px solid rgba(0, 255, 65, 0.3);
}

.badge-success {
    background: rgba(34, 197, 94, 0.1);
    color: #4ade80;
    border: 1px solid rgba(34, 197, 94, 0.2);
}

.badge-warning {
    background: rgba(251, 191, 36, 0.1);
    color: #fbbf24;
    border: 1px solid rgba(251, 191, 36, 0.2);
}

.badge-danger {
    background: rgba(239, 68, 68, 0.1);
    color: #f87171;
    border: 1px solid rgba(239, 68, 68, 0.2);
}

/* Tooltip */
.tooltip {
    position: relative;
}

.tooltip::before {
    content: attr(data-tooltip);
    position: absolute;
    bottom: 100%;
    left: 50%;
    transform: translateX(-50%);
    padding: 8px 12px;
    background: #1e293b;
    color: white;
    border-radius: 6px;
    font-size: 0.875rem;
    white-space: nowrap;
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.2s;
    margin-bottom: 8px;
    border: 1px solid #334155;
}

.tooltip:hover::before {
    opacity: 1;
}

/* Email result link explanation */
.email-profile-link-help {
    position: relative;
    flex-shrink: 0;
}

.email-profile-link-help__trigger {
    display: flex;
    width: 1.25rem;
    height: 1.25rem;
    padding: 0;
    cursor: help;
    appearance: none;
    align-items: center;
    justify-content: center;
    border: 1px solid rgba(0, 255, 65, 0.35);
    border-radius: 9999px;
    background: rgba(0, 255, 65, 0.06);
    color: #00FF41;
    font-size: 0.6875rem;
    font-weight: 700;
    line-height: 1;
    transition: border-color 0.2s, background-color 0.2s, color 0.2s;
}

.email-profile-link-help__trigger:hover,
.email-profile-link-help__trigger:focus-visible,
.email-profile-link-help.is-open .email-profile-link-help__trigger {
    border-color: #00FF41;
    background: rgba(0, 255, 65, 0.14);
    color: #66ffb2;
    outline: none;
}

.email-profile-link-help__trigger:focus-visible {
    box-shadow: 0 0 0 2px rgba(0, 255, 65, 0.25);
}

.email-profile-link-help__panel {
    display: block;
    position: absolute;
    right: 0;
    bottom: calc(100% + 0.625rem);
    z-index: 60;
    width: min(18rem, calc(100vw - 2rem));
    padding: 0.875rem;
    border: 1px solid rgba(0, 255, 65, 0.3);
    border-radius: 0.375rem;
    background: rgba(10, 10, 10, 0.98);
    color: #d1d5db;
    font-family: 'Inter', system-ui, sans-serif;
    font-size: 0.75rem;
    line-height: 1.25rem;
    text-align: left;
    box-shadow: 0 18px 45px rgba(0, 0, 0, 0.55);
    opacity: 0;
    visibility: hidden;
    pointer-events: none;
    transform: translateY(0.25rem);
    transition: opacity 0.18s, visibility 0.18s, transform 0.18s;
}

.email-profile-link-help__panel strong {
    display: block;
    margin-bottom: 0.375rem;
    color: #f3f4f6;
    font-family: 'JetBrains Mono', monospace;
    font-size: 0.75rem;
}

.email-profile-link-help__panel p {
    margin: 0;
}

.email-profile-link-help:hover .email-profile-link-help__panel,
.email-profile-link-help:focus-within .email-profile-link-help__panel,
.email-profile-link-help.is-open .email-profile-link-help__panel {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
}

.result-card:has(.email-profile-link-help:hover),
.result-card:has(.email-profile-link-help:focus-within),
.result-card:has(.email-profile-link-help.is-open) {
    z-index: 60;
}

/* Mobile Menu Animation */
#mobile-menu {
    max-height: 0;
    overflow: hidden;
    transition: max-height 0.3s ease;
}

#mobile-menu.active {
    max-height: 500px;
}

/* Results Animation */
@keyframes slideInUp {
    from {
        opacity: 0;
        transform: translateY(20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.result-item {
    animation: slideInUp 0.3s ease forwards;
}

.result-item:nth-child(2) { animation-delay: 0.1s; }
.result-item:nth-child(3) { animation-delay: 0.2s; }
.result-item:nth-child(4) { animation-delay: 0.3s; }
.result-item:nth-child(5) { animation-delay: 0.4s; }

/* Responsive Typography */
@media (max-width: 768px) {
    h1 {
        font-size: 2.5rem;
    }
    
    h2 {
        font-size: 2rem;
    }
    
    h3 {
        font-size: 1.5rem;
    }
}

/* Print Styles */
@media print {
    nav,
    footer,
    .no-print {
        display: none;
    }
    
    body {
        background: white;
        color: black;
    }
}

/* Accessibility */
.sr-only {
    position: absolute;
    width: 1px;
    height: 1px;
    padding: 0;
    margin: -1px;
    overflow: hidden;
    clip: rect(0, 0, 0, 0);
    white-space: nowrap;
    border-width: 0;
}

/* Focus Visible (for keyboard navigation) */
*:focus-visible {
    outline: 2px solid #00FF41;
    outline-offset: 2px;
}

/* Terminal Cursor Animation */
@keyframes cursor-blink {
    0%, 50% { opacity: 1; }
    51%, 100% { opacity: 0; }
}

.cursor-blink {
    animation: cursor-blink 1s infinite;
}

/* Scan Line Effect */
@keyframes scanline {
    0% {
        transform: translateY(-100%);
    }
    100% {
        transform: translateY(100vh);
    }
}

.scanline {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 2px;
    background: linear-gradient(transparent, rgba(0, 255, 65, 0.3), transparent);
    animation: scanline 8s linear infinite;
    pointer-events: none;
    z-index: 9999;
}

/* Reduced Motion */
@media (prefers-reduced-motion: reduce) {
    *,
    *::before,
    *::after {
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: 0.01ms !important;
        scroll-behavior: auto !important;
    }
}
@keyframes slideIn {
    from {
        opacity: 0;
        transform: translateY(10px) scale(0.95);
    }
    to {
        opacity: 1;
        transform: translateY(0) scale(1);
    }
}
.animate-slideIn {
    animation: slideIn 0.4s ease-out forwards;
    opacity: 0;
}
.result-card {
    position: relative;
}
.card-inner {
    position: relative;
    height: 100%;
}
.card-inner:hover {
    transform: translateY(-2px);
}
#results-list {
    animation: fadeIn 0.5s ease-out;
}
@keyframes fadeIn {
    from { opacity: 0; }
    to { opacity: 1; }
}
.favicon-container {
    width: 20px;
    height: 20px;
    display: flex;
    align-items: center;
    justify-content: center;
}
.favicon-img {
    width: 20px;
    height: 20px;
    border-radius: 3px;
    object-fit: contain;
    background: rgba(255, 255, 255, 0.05);
    padding: 2px;
}
.default-favicon-icon {
    font-size: 16px;
    color: #4EC9B0;
    opacity: 0.7;
}

.scan-name-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
}

.scan-name-viewport {
    max-height: 18rem;
    overflow: hidden;
}

.scan-name-viewport.is-expanded {
    max-height: none;
}

.scan-name-fade {
    position: absolute;
    right: 0;
    bottom: 0;
    left: 0;
    height: 4rem;
    pointer-events: none;
    background: linear-gradient(to bottom, rgba(31, 31, 31, 0), #1f1f1f 82%);
}

@media (min-width: 640px) {
    .scan-name-grid {
        grid-template-columns: repeat(auto-fit, minmax(16rem, 1fr));
    }

    .scan-name-viewport {
        max-height: 22rem;
    }
}

/* Home footer directory badges */
.footer-featured-strip {
    display: none;
}

@media (min-width: 768px) {
    .footer-featured-strip {
        display: block;
        margin-top: 1.1rem;
        overflow: hidden;
    }

    .footer-featured-viewport {
        width: 100%;
        overflow: hidden;
    }

    .footer-featured-track,
    .footer-featured-set {
        display: flex;
        align-items: center;
        width: max-content;
    }

    .footer-featured-set {
        flex: 0 0 auto;
        gap: 1.25rem;
        padding-right: 1.25rem;
        white-space: nowrap;
    }

    .footer-featured-set[aria-hidden="true"] {
        pointer-events: none;
    }

    .footer-featured-badge {
        display: block;
        flex: 0 0 auto;
        line-height: 0;
        opacity: 0.82;
        transition: opacity 180ms ease, transform 180ms ease;
    }

    .footer-featured-badge:hover,
    .footer-featured-badge:focus-visible {
        opacity: 1;
        transform: translateY(-1px);
    }

    .footer-featured-badge img {
        display: block;
        width: auto;
        height: 48px;
        max-width: none;
        object-fit: contain;
    }

    .footer-featured-strip.is-scrolling .footer-featured-track {
        animation: footer-featured-marquee var(--footer-featured-duration, 30s) linear infinite;
        will-change: transform;
    }
}

@keyframes footer-featured-marquee {
    to {
        transform: translateX(calc(-1 * var(--footer-featured-shift)));
    }
}

/* Each scan category has its own bounded preview and scan status. */
.osint-log-preview {
    --scan-log-preview-height: 224px;
    max-height: var(--scan-log-preview-height);
    overflow-y: auto;
    overscroll-behavior: contain;
    scrollbar-gutter: stable;
    padding-right: 0.375rem;
}

.osint-log-preview.is-expanded {
    max-height: none;
    overflow: visible;
    scrollbar-gutter: auto;
    padding-right: 0;
}

.osint-log-preview:focus-visible {
    outline: 1px solid rgba(0, 255, 65, 0.35);
    outline-offset: 3px;
}

.osint-log-wave {
    display: inline-flex;
    align-items: center;
    gap: 2px;
    width: 23px;
    height: 16px;
}

.osint-log-wave > span {
    width: 3px;
    height: 100%;
    border-radius: 2px;
    background: currentColor;
    animation: osint-log-wave 0.9s ease-in-out infinite;
}

.osint-log-wave > span:nth-child(2) { animation-delay: -0.72s; }
.osint-log-wave > span:nth-child(3) { animation-delay: -0.54s; }
.osint-log-wave > span:nth-child(4) { animation-delay: -0.36s; }
.osint-log-wave > span:nth-child(5) { animation-delay: -0.18s; }

@keyframes osint-log-wave {
    0%, 100% { transform: scaleY(0.3); opacity: 0.45; }
    50% { transform: scaleY(1); opacity: 1; }
}

@media (min-width: 768px) {
    .osint-log-preview { --scan-log-preview-height: 288px; }
}

@media (prefers-reduced-motion: reduce) {
    .osint-log-wave > span {
        animation: none;
        transform: scaleY(0.65);
    }
}

@media (prefers-reduced-motion: reduce) {
    .footer-featured-strip.is-scrolling .footer-featured-track {
        animation: none;
    }
}

/* Manual search shortcuts within the search-engine results section. */
.google-dorks {
    min-width: 0;
    margin-top: 1.5rem;
    border-top: 1px solid rgba(0, 255, 65, 0.15);
    padding-top: 1.25rem;
    font-family: 'Inter', sans-serif;
    text-align: left;
}

.dorks-heading {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 1rem;
}

.dorks-heading .dorks-kicker {
    color: #9ca3af;
    font: 600 0.625rem/1.7 'JetBrains Mono', ui-monospace, monospace;
    letter-spacing: 0.16em;
    text-transform: uppercase;
}

.dorks-heading h4 {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 0.625rem;
    color: #d1d5db;
    font: 600 0.8125rem/1.7 'JetBrains Mono', ui-monospace, monospace;
    letter-spacing: 0.06em;
    text-transform: uppercase;
}

.dorks-target {
    max-width: 48%;
    border: 1px solid rgba(0, 255, 65, 0.25);
    padding: 0.3rem 0.5rem;
    color: #00ff41;
    background: rgba(0, 255, 65, 0.05);
    font: 0.75rem/1.7 'JetBrains Mono', ui-monospace, monospace;
    white-space: pre-wrap;
    overflow-wrap: anywhere;
}

.dorks-intro {
    margin: 1rem 0;
    color: #9ca3af;
    font-size: 0.8125rem;
    line-height: 1.75;
}

.google-dorks-ip {
    --dork-grid-columns: 2;
}

.dork-grid {
    display: grid;
    grid-template-columns: repeat(var(--dork-grid-columns, 3), minmax(0, 1fr));
    align-items: start;
    gap: 0.625rem;
}

.dork-item {
    min-width: 0;
    border: 1px solid rgba(0, 255, 65, 0.15);
    background: #1a1a1a;
}

.dork-link-row {
    display: flex;
    min-width: 0;
    align-items: stretch;
}

.dork-link {
    display: flex;
    min-width: 0;
    flex: 1;
    align-items: center;
    justify-content: space-between;
    gap: 0.625rem;
    padding: 0.875rem 0.75rem;
    color: #e5e7eb;
    font-size: 0.8125rem;
    font-weight: 600;
    line-height: 1.6;
    text-decoration: none;
}

.dork-link > span:first-child {
    overflow-wrap: anywhere;
}

.dork-link > i {
    flex: none;
    color: #00ff41;
    font-size: 0.625rem;
}

.dork-link:hover {
    color: #00ff41;
    background: rgba(0, 255, 65, 0.05);
}

.dork-help {
    display: flex;
    width: 2rem;
    height: 2rem;
    flex: none;
    align-self: center;
    align-items: center;
    justify-content: center;
    margin-right: 0.375rem;
    border: 1px solid rgba(0, 255, 65, 0.15);
    color: #9ca3af;
    background: transparent;
    font: 500 0.75rem 'JetBrains Mono', ui-monospace, monospace;
    cursor: pointer;
}

.dork-help:hover,
.dork-help[aria-expanded="true"] {
    border-color: #00ff41;
    color: #121212;
    background: #00ff41;
}

.dork-tip {
    margin: 0;
    border-top: 1px solid rgba(0, 255, 65, 0.25);
    padding: 0.75rem;
    color: #00ff41;
    background: rgba(0, 255, 65, 0.05);
    font-size: 0.75rem;
    line-height: 1.8;
}

.dork-tip[hidden] {
    display: none;
}

.dork-disclosure {
    margin-top: 1rem;
    border-top: 1px solid rgba(0, 255, 65, 0.15);
    padding-top: 0.875rem;
}

.dork-disclosure > summary {
    width: fit-content;
    color: #00ff41;
    font-size: 0.75rem;
    font-weight: 600;
    line-height: 1.8;
    cursor: pointer;
}

.dork-disclosure > summary > span {
    margin-left: 0.375rem;
    color: #9ca3af;
    font: 0.6875rem 'JetBrains Mono', ui-monospace, monospace;
}

.dork-disclosure[open] > .dork-grid,
.dork-query-list {
    margin-top: 0.875rem;
}

.dork-query-row {
    display: flex;
    min-width: 0;
    align-items: flex-start;
    gap: 0.75rem;
    border-top: 1px solid rgba(0, 255, 65, 0.15);
    padding: 0.875rem 0;
}

.dork-query-row:first-child {
    border-top: 0;
    padding-top: 0;
}

.dork-query-row > div {
    min-width: 0;
    flex: 1;
}

.dork-query-row strong {
    display: block;
    color: #e5e7eb;
    font-size: 0.75rem;
    font-weight: 600;
}

.dork-query-row code {
    display: block;
    margin-top: 0.375rem;
    color: #00ff41;
    font: 0.75rem/1.8 'JetBrains Mono', ui-monospace, monospace;
    white-space: pre-wrap;
    overflow-wrap: anywhere;
    user-select: all;
}

.dork-copy {
    flex: none;
    border: 1px solid rgba(0, 255, 65, 0.25);
    padding: 0.375rem 0.625rem;
    color: #00ff41;
    background: #1a1a1a;
    font-size: 0.75rem;
    font-weight: 600;
    cursor: pointer;
}

.dork-copy:hover {
    background: rgba(0, 255, 65, 0.05);
}

.dork-copy:disabled {
    opacity: 0.6;
    cursor: wait;
}

.dork-copy-status {
    margin: 0;
    color: #00ff41;
    font-size: 0.75rem;
    line-height: 1.8;
}

.dork-copy-status:not(:empty) {
    padding-top: 0.75rem;
}

.dorks-footer {
    margin: 1rem 0 0;
    color: #9ca3af;
    font-size: 0.6875rem;
    line-height: 1.8;
}

@media (max-width: 767px) {
    .dork-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }
}

@media (max-width: 480px) {
    .google-dorks {
        padding-top: 1rem;
    }

    .dorks-heading {
        flex-wrap: wrap;
        gap: 0.75rem;
    }

    .dorks-target {
        max-width: 100%;
    }

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

    .dork-help {
        width: 2.5rem;
        height: 2.5rem;
    }

    .dork-query-row {
        gap: 0.5rem;
    }
}
