/* Hyper-Modern Industrial PeerWeb Design */
:root {
    --bg-core: #050505;
    --bg-surface: #0a0a0a;
    --bg-card: #111111;
    --accent: #ccff00;
    /* Acid Lime */
    --accent-glow: rgba(204, 255, 0, 0.4);
    --text-main: #ffffff;
    --text-muted: #666666;
    --border: #333333;
    --border-hover: #555555;
    --font-display: 'Outfit', -apple-system, BlinkMacSystemFont, sans-serif;
    --font-mono: 'JetBrains Mono', 'Fira Code', monospace;
    --radius-lg: 24px;
    --radius-md: 12px;
    --radius-sm: 4px;
    --easing: cubic-bezier(0.16, 1, 0.3, 1);
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    -webkit-font-smoothing: antialiased;
}

::selection {
    background: var(--accent);
    color: black;
}

body {
    background-color: var(--bg-core);
    color: var(--text-main);
    font-family: var(--font-display);
    line-height: 1.5;
    overflow-x: hidden;
    min-height: 100vh;
}

/* Background Noise Texture */
body::before {
    content: "";
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 200 200' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='noiseFilter'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.65' numOctaves='3' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23noiseFilter)' opacity='0.05'/%3E%3C/svg%3E");
    pointer-events: none;
    z-index: 9999;
}

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

::-webkit-scrollbar-track {
    background: var(--bg-core);
}

::-webkit-scrollbar-thumb {
    background: var(--border);
    border-radius: 99px;
}

::-webkit-scrollbar-thumb:hover {
    background: var(--accent);
}

.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 2rem 4rem;
}

/* Header / Hero */
.hero {
    padding: 8rem 0 6rem;
    text-align: center;
    position: relative;
}

.hero h1 {
    font-size: clamp(3rem, 10vw, 8rem);
    font-weight: 800;
    line-height: 0.9;
    letter-spacing: -0.04em;
    margin-bottom: 2rem;
    text-transform: uppercase;
}

.maintitle {
    color: var(--text-main);
    text-decoration: none;
    display: inline-flex;
    align-items: center;
    gap: 1rem;
    position: relative;
    transition: color 0.3s var(--easing);
}

.maintitle i {
    color: var(--accent);
    font-size: 0.8em;
    animation: float 6s ease-in-out infinite;
}

.maintitle:hover {
    text-shadow: 0 0 30px rgba(255, 255, 255, 0.2);
}

.hero h2 {
    font-family: var(--font-mono);
    color: var(--accent);
    text-transform: uppercase;
    letter-spacing: 0.1em;
    font-size: 1rem;
    margin-top: 1rem;
    opacity: 0.8;
}

/* Sections & Cards */
section {
    position: relative;
    margin-bottom: 4rem;
}

section h3 {
    font-size: 2.5rem;
    font-weight: 700;
    margin-bottom: 2rem;
    letter-spacing: -0.02em;
    display: flex;
    align-items: center;
    gap: 1rem;
}

section h3 i {
    color: var(--accent);
    font-size: 0.8em;
}

/* Quick Upload Area */
.quick-upload {
    background: var(--bg-surface);
    border: 1px solid var(--border);
    border-radius: var(--radius-lg);
    padding: 3rem;
    position: relative;
    overflow: hidden;
}

.drop-zone {
    border: 2px dashed var(--border);
    padding: 4rem 2rem;
    text-align: center;
    border-radius: var(--radius-md);
    transition: all 0.3s var(--easing);
    background: rgba(255, 255, 255, 0.01);
}

.drop-zone:hover,
.drop-zone.drag-over {
    border-color: var(--accent);
    background: rgba(204, 255, 0, 0.05);
    transform: scale(1.005);
}

.drop-icon {
    font-size: 4rem;
    margin-bottom: 1.5rem;
    color: var(--text-muted);
}

.drop-zone:hover .drop-icon {
    color: var(--accent);
    transform: translateY(-10px);
    transition: transform 0.3s var(--easing);
}

.drop-content h4 {
    font-size: 1.5rem;
    font-weight: 600;
    margin-bottom: 0.5rem;
}

.drop-content p {
    color: var(--text-muted);
    font-family: var(--font-mono);
    margin-bottom: 2rem;
}

/* Buttons */
.btn {
    display: inline-flex;
    align-items: center;
    gap: 0.8rem;
    padding: 1rem 2rem;
    border-radius: var(--radius-sm);
    /* Sharp/Small radius for industrial look */
    font-family: var(--font-mono);
    font-weight: 700;
    text-transform: uppercase;
    font-size: 0.9rem;
    cursor: pointer;
    border: 1px solid transparent;
    transition: all 0.2s var(--easing);
}

.btn-primary {
    background: var(--accent);
    color: black;
    border-color: var(--accent);
    box-shadow: 0 4px 20px rgba(204, 255, 0, 0.2);
}

.btn-primary:hover {
    background: #e5ff00;
    transform: translateY(-2px);
    box-shadow: 0 6px 30px rgba(204, 255, 0, 0.3);
}

.btn-secondary {
    background: transparent;
    border-color: var(--border);
    color: var(--text-main);
}

.btn-secondary:hover {
    border-color: var(--text-main);
    background: rgba(255, 255, 255, 0.05);
}

.btn-ghost {
    background: transparent;
    color: var(--text-muted);
}

.btn-ghost:hover {
    color: var(--text-main);
}

/* Inputs */
.hash-input-group {
    display: flex;
    gap: 1rem;
    margin-top: 1.5rem;
}

.hash-input {
    flex: 1;
    background: var(--bg-card);
    border: 1px solid var(--border);
    padding: 1rem 1.5rem;
    border-radius: var(--radius-sm);
    color: var(--text-main);
    font-family: var(--font-mono);
    transition: all 0.3s var(--easing);
}

.hash-input:focus {
    outline: none;
    border-color: var(--accent);
    box-shadow: 0 0 0 2px var(--accent-glow);
}

/* Bento Grid System for Features */
.feature-grid,
.benefit-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 1.5rem;
    margin-top: 2rem;
}

.feature,
.benefit {
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: var(--radius-md);
    padding: 2rem;
    display: flex;
    flex-direction: column;
    justify-content: flex-start;
    gap: 1rem;
    transition: all 0.3s var(--easing);
    height: 100%;
}

.feature:hover,
.benefit:hover {
    transform: translateY(-5px);
    border-color: var(--accent);
    box-shadow: 0 10px 40px -10px rgba(0, 0, 0, 0.5);
}

/* Ensure icons are on top line */
.feature i,
.benefit i {
    font-size: 1.5rem;
    color: var(--accent);
    margin-bottom: 0.5rem;
    width: fit-content;
}

/* Usage Steps - Numbered List Style */
.steps {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 1.5rem;
}

.step {
    background: var(--bg-surface);
    border-left: 3px solid var(--border);
    padding: 2rem;
    transition: border-color 0.3s;
}

.step:hover {
    border-left-color: var(--accent);
    background: linear-gradient(90deg, rgba(204, 255, 0, 0.02), transparent);
}

/* Footer */
footer {
    border-top: 1px solid var(--border);
    padding: 4rem 2rem;
    text-align: center;
    color: var(--text-muted);
    font-family: var(--font-mono);
    font-size: 0.8rem;
    background: var(--bg-surface);
    margin-top: 4rem;
}

/* Dynamic Elements & Modals - Keeping core functionality logic */
.hidden {
    display: none !important;
}

/* Install PWA Button */
#install-pwa {
    margin-top: 1rem;
    font-weight: 700;
}

/* Modals */
.modal {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.8);
    backdrop-filter: blur(10px);
    display: flex;
    justify-content: center;
    align-items: center;
    z-index: 1000;
}

.modal-content {
    background: var(--bg-core);
    border: 1px solid var(--accent);
    padding: 2.5rem;
    border-radius: var(--radius-lg);
    width: 90%;
    max-width: 600px;
    box-shadow: 0 0 100px rgba(204, 255, 0, 0.1);
}

.progress-bar {
    height: 6px;
    background: var(--bg-card);
    border-radius: 99px;
    overflow: hidden;
    margin-top: 1rem;
}

.progress-bar::after {
    content: '';
    display: block;
    height: 100%;
    width: 0%;
    background: var(--accent);
    box-shadow: 0 0 20px var(--accent);
    transition: width 0.3s ease;
}

/* Animations */
@keyframes float {

    0%,
    100% {
        transform: translateY(0);
    }

    50% {
        transform: translateY(-10px);
    }
}

/* Demo Cards */
.demo-card {
    text-decoration: none;
    color: var(--text-main);
    display: flex;
    flex-direction: row;
    align-items: center;
    gap: 1.5rem;
    cursor: pointer;
}

.demo-card:hover {
    background: rgba(204, 255, 0, 0.05);
    /* Acid tint on hover */
    border-color: var(--accent);
}

.demo-card p {
    color: var(--text-muted);
    font-size: 0.9rem;
    margin-top: 0.2rem;
}

.demo-card i {
    font-size: 2rem;
}

/* Ensure no blue links globally unless specified */
a {
    color: inherit;
    text-decoration: none;
}

a:hover {
    color: var(--accent);
}

/* Responsive */
@media (max-width: 900px) {

    .feature-grid,
    .benefit-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (max-width: 600px) {
    .hero h1 {
        font-size: 3.5rem;
    }

    .feature-grid,
    .benefit-grid {
        grid-template-columns: 1fr;
    }

    .hash-input-group {
        flex-direction: column;
    }

    .container {
        padding: 0 1rem 2rem;
    }
}

/* Toast Overrides for new theme */
.toast-container {
    position: fixed;
    bottom: 20px;
    right: 20px;
    z-index: 10000;
    display: flex;
    flex-direction: column;
    gap: 10px;
}

/* Site Database Styles */
.sites-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
    gap: 1.5rem;
    margin-top: 1.5rem;
}

.site-card {
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: var(--radius-md);
    padding: 1.5rem;
    transition: all 0.3s var(--easing);
    position: relative;
    overflow: hidden;
}

.site-card:hover {
    border-color: var(--accent);
    transform: translateY(-5px);
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.3);
}

.site-card h4 {
    color: var(--text-main);
    font-size: 1.2rem;
    margin-bottom: 0.5rem;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.site-card h4 i {
    color: var(--accent);
    font-size: 0.8em;
}

.site-card .hash {
    font-family: var(--font-mono);
    font-size: 0.8rem;
    color: var(--text-muted);
    background: rgba(255, 255, 255, 0.05);
    padding: 2px 6px;
    border-radius: 4px;
    word-break: break-all;
    margin-bottom: 1rem;
    display: block;
}

.site-card .actions {
    display: flex;
    gap: 0.5rem;
    margin-top: 1rem;
}

.site-card .btn-sm {
    padding: 0.5rem 1rem;
    font-size: 0.8rem;
}

.no-sites {
    text-align: center;
    padding: 3rem;
    color: var(--text-muted);
    background: var(--bg-surface);
    border-radius: var(--radius-md);
    border: 1px dashed var(--border);
}

.no-sites i {
    font-size: 3rem;
    margin-bottom: 1rem;
    opacity: 0.5;
}

.toast {
    background: var(--bg-surface);
    border: 1px solid var(--border);
    color: var(--text-main);
    border-radius: var(--radius-sm);
    padding: 1rem;
    min-width: 300px;
    display: flex;
    align-items: center;
    gap: 1rem;
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.5);
    font-family: var(--font-mono);
}

.toast-success {
    border-color: var(--accent);
    box-shadow: 0 0 20px rgba(204, 255, 0, 0.1);
}

.toast-error {
    border-color: #ff3333;
}

/* Code Blocks */
code,
.code-block {
    font-family: var(--font-mono);
    background: rgba(255, 255, 255, 0.05);
    color: var(--accent);
    padding: 0.2em 0.4em;
    border-radius: 4px;
}

/* Desktop Promo Section */
.desktop-promo {
    margin-top: 4rem;
}

.promo-card {
    background: linear-gradient(135deg, var(--bg-surface) 0%, var(--bg-card) 100%);
    border: 1px solid var(--accent);
    border-radius: var(--radius-lg);
    padding: 3rem;
    display: flex;
    align-items: center;
    gap: 3rem;
    position: relative;
    overflow: hidden;
    box-shadow: 0 0 50px rgba(204, 255, 0, 0.05);
}

.promo-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: radial-gradient(circle at 70% 30%, rgba(204, 255, 0, 0.05), transparent 50%);
    pointer-events: none;
}

.promo-icon {
    font-size: 5rem;
    color: var(--accent);
    background: rgba(204, 255, 0, 0.1);
    width: 120px;
    height: 120px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    box-shadow: 0 0 30px rgba(204, 255, 0, 0.2);
    flex-shrink: 0;
}

.promo-content h4 {
    font-size: 2rem;
    margin-bottom: 1rem;
    color: var(--text-main);
}

.promo-features {
    list-style: none;
    margin: 1.5rem 0;
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 1rem;
}

.promo-features li {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    color: var(--text-muted);
}

.promo-features i {
    color: var(--accent);
}

.command-box {
    background: #000;
    border: 1px solid var(--border);
    padding: 1rem;
    border-radius: var(--radius-sm);
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-top: 1.5rem;
    font-family: var(--font-mono);
    max-width: 400px;
}

.command-box code {
    color: var(--accent);
    background: transparent;
}

.btn-copy {
    background: transparent;
    border: none;
    color: var(--text-muted);
    cursor: pointer;
    transition: color 0.2s;
}

.btn-copy:hover {
    color: var(--text-main);
}

@media (max-width: 768px) {
    .promo-card {
        flex-direction: column;
        text-align: center;
        gap: 2rem;
    }

    .command-box {
        margin: 1.5rem auto 0;
    }

    .promo-features {
        justify-items: center;
    }
}