:root {
    --bg-dark: #0f172a;
    --bg-darker: #020617;
    --bg-nav: rgba(15, 23, 42, 0.8);
    --text: #f8fafc;
    --text-light: #94a3b8;
    --primary: #3b82f6;
    --border: #334155;
    --primary-hover: #60a5fa;
    --accent: #00e5ff;
}

body {
    margin: 0;
    font-family: "Inter", -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
    background: linear-gradient(135deg, var(--bg-darker) 0%, #1e1b4b 100%);
    color: var(--text);
    overflow-x: hidden;
    min-height: 100vh;
    position: relative;
}
body::before {
    content: '';
    position: absolute;
    top: -200px;
    left: -200px;
    width: 600px;
    height: 600px;
    background: radial-gradient(circle, rgba(59,130,246,0.15) 0%, transparent 70%);
    border-radius: 50%;
    z-index: -1;
    pointer-events: none;
}

/* Landing Page Structure */
.landing-page {
    display: block;
}

/* Top Nav */
.top-nav {
    background: var(--bg-nav);
    backdrop-filter: blur(12px);
    padding: 0 24px;
    height: 60px;
    display: flex;
    align-items: center;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
    position: relative;
    z-index: 10;
}
.logo {
    font-weight: 700;
    font-size: 18px;
    display: flex;
    align-items: center;
    gap: 8px;
    margin-right: 40px;
    color: var(--text);
}
.logo-icon {
    background: linear-gradient(45deg, var(--primary), #00e5ff);
    color: white;
    padding: 2px 6px;
    border-radius: 4px;
    font-family: monospace;
    font-weight: bold;
}
.nav-links {
    display: flex;
    gap: 24px;
}
.nav-links a {
    color: var(--text-light);
    text-decoration: none;
    font-size: 14px;
    transition: color 0.2s;
}
.nav-links a:hover {
    color: var(--primary);
}

/* Sub Nav */
.sub-nav {
    background: rgba(2, 6, 23, 0.7);
    backdrop-filter: blur(12px);
    padding: 0 24px;
    height: 60px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    border-bottom: 1px solid rgba(255, 255, 255, 0.05);
    position: relative;
    z-index: 10;
}
.sub-logo {
    font-size: 20px;
    font-weight: bold;
    color: var(--text);
}
.sub-links {
    display: flex;
    gap: 24px;
    margin-left: 40px;
    flex-grow: 1;
}
.sub-links a {
    color: var(--text-light);
    text-decoration: none;
    font-size: 14px;
}
.sub-links a:hover {
    color: var(--primary);
}
.sub-actions {
    display: flex;
    align-items: center;
    gap: 16px;
}
.nav-login-btn {
    background: transparent;
    border: 1px solid #cbd5e1;
    color: var(--text);
    padding: 8px 16px;
    border-radius: 20px;
    cursor: pointer;
    font-weight: 500;
}
.nav-login-btn:hover {
    background: #e2e8f0;
}
.nav-download-btn {
    background: var(--primary);
    border: none;
    color: white;
    padding: 8px 24px;
    border-radius: 20px;
    cursor: pointer;
    font-weight: 600;
}
.nav-download-btn:hover {
    background: var(--primary-hover);
}

/* Banner */
.banner {
    background: #0f172a;
    color: white;
    text-align: center;
    padding: 12px;
    font-size: 14px;
    position: relative;
    display: flex;
    justify-content: center;
    align-items: center;
}
.banner button {
    position: absolute;
    right: 20px;
    background: transparent;
    border: none;
    color: white;
    font-size: 20px;
    cursor: pointer;
}

/* Hero */
.hero {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 40px;
    padding: 80px 10%;
    position: relative;
    overflow: hidden;
    background: linear-gradient(135deg, #f8fafc 0%, #f1f5f9 100%);
}

@media (max-width: 768px) {
    .hero {
        flex-direction: column;
        text-align: center;
        padding: 40px 5%;
    }
}

.hero-content {
    flex: 1;
    z-index: 2;
    align-self: flex-start;
    margin-top: 40px;
}
.hero-tag {
    color: #888;
    font-size: 24px;
    margin-bottom: 20px;
    font-weight: 600;
}
.hero h1 {
    font-size: 64px;
    line-height: 1.1;
    margin: 0 0 20px 0;
    font-weight: 800;
    color: var(--text);
}
.hero p {
    font-size: 28px;
    color: #888;
    margin: 0;
}
.hero-visual {
    flex: 1;
    position: relative;
    display: flex;
    align-items: center;
    justify-content: center;
}
.abstract-shape {
    position: absolute;
    width: 500px;
    height: 500px;
    background: radial-gradient(circle, rgba(236,72,153,0.3) 0%, rgba(99,102,241,0.2) 40%, transparent 70%);
    border-radius: 50%;
    z-index: 1;
}
.logo-box {
    position: relative;
    z-index: 2;
    background: black;
    width: 150px;
    height: 150px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 48px;
    font-family: monospace;
    font-weight: bold;
    color: white;
    border: 1px solid #333;
    text-align: center;
}

/* Modern Cookie Banner */
.cookie-overlay {
    position: fixed;
    bottom: 20px;
    left: 20px;
    right: 20px;
    max-width: 1200px;
    margin: 0 auto;
    background-color: white;
    border: 1px solid var(--border);
    border-radius: 12px;
    box-shadow: 0 10px 15px -3px rgba(0, 0, 0, 0.1), 0 4px 6px -2px rgba(0, 0, 0, 0.05);
    z-index: 2000;
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 20px 30px;
}
.cookie-popup {
    display: flex;
    width: 100%;
    align-items: center;
    justify-content: space-between;
}
.cookie-content {
    flex: 1;
    color: var(--text);
    font-size: 14px;
    line-height: 1.5;
    margin-right: 40px;
}
.cookie-content p {
    margin: 0;
}
.cookie-actions {
    display: flex;
    gap: 12px;
}
.cookie-btn {
    padding: 10px 20px;
    border-radius: 6px;
    font-weight: bold;
    cursor: pointer;
    border: none;
    transition: background 0.2s;
}
.cookie-btn.primary {
    background: var(--primary);
    color: white;
}
.cookie-btn.primary:hover {
    background: var(--primary-hover);
}
.cookie-btn.secondary {
    background: transparent;
    border: 1px solid #555;
    color: #ccc;
}
.cookie-btn.secondary:hover {
    background: #333;
    color: white;
}

/* Auth Modal (Restyled for dark theme) */
.auth-overlay {
    position: fixed;
    top: 0; left: 0; width: 100%; height: 100%;
    background: rgba(0,0,0,0.8);
    backdrop-filter: blur(8px);
    display: none;
    align-items: center;
    justify-content: center;
    z-index: 1000;
}
.auth-modal {
    background: var(--bg-dark);
    border-radius: 12px;
    padding: 40px;
    border: 1px solid #333;
    box-shadow: 0 20px 40px rgba(0,0,0,0.5);
    text-align: center;
    max-width: 350px;
    width: 90%;
}
.auth-input {
    width: 100%;
    padding: 12px;
    margin-bottom: 15px;
    border-radius: 8px;
    border: 1px solid rgba(255,255,255,0.2);
    box-sizing: border-box;
    font-family: inherit;
    background: rgba(0,0,0,0.2);
    color: var(--text);
}
.auth-btn {
    width: 100%;
    padding: 12px;
    border: none;
    border-radius: 8px;
    background: linear-gradient(135deg, var(--primary) 0%, var(--accent) 100%);
    color: white;
    font-weight: bold;
    cursor: pointer;
    margin-bottom: 10px;
    box-shadow: 0 4px 15px rgba(37, 99, 235, 0.2);
    transition: transform 0.2s ease, box-shadow 0.2s ease;
}
.auth-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(37, 99, 235, 0.3);
}
.auth-btn.secondary { background: #333; color: var(--text); box-shadow: none; }
.auth-btn.secondary:hover { background: #444; transform: translateY(-2px); }

/* Main App Container */
.dashboard-page {
    min-height: 100vh;
    background: transparent;
    position: relative;
    overflow: hidden;
}
.dashboard-page::before {
    display: none;
}
.container {
    background: rgba(15, 23, 42, 0.6);
    backdrop-filter: blur(16px);
    -webkit-backdrop-filter: blur(16px);
    border: 1px solid rgba(255, 255, 255, 0.1);
    box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.5);
    border-radius: 20px;
    padding: 40px;
    text-align: center;
    max-width: 500px;
    margin: 0 auto;
    position: relative;
    z-index: 1;
}
.dropzone { 
    background: rgba(255, 255, 255, 0.03); 
    border: 2px dashed rgba(255, 255, 255, 0.2); 
    border-radius: 12px; 
    padding: 60px 40px; 
    transition: all 0.3s ease; 
    cursor: pointer; 
}
.dropzone:hover {
    border-color: var(--primary);
    background: rgba(59, 130, 246, 0.1);
    box-shadow: 0 0 20px rgba(59, 130, 246, 0.2);
    transform: translateY(-2px);
}
@keyframes fileDropPop {
    0% { transform: scale(1); border-color: var(--primary); box-shadow: 0 0 0 0 rgba(37, 99, 235, 0.4); }
    50% { transform: scale(1.02); border-color: var(--accent); box-shadow: 0 0 0 15px rgba(37, 99, 235, 0); }
    100% { transform: scale(1); border-color: var(--primary); box-shadow: 0 0 0 0 rgba(37, 99, 235, 0); }
}
.dropzone.file-added {
    animation: fileDropPop 0.5s ease-out;
    background: #eff6ff;
    border-color: var(--primary);
}
.icon { font-size: 48px; margin-bottom: 15px; }
.hidden-input { display: none; }
.status { margin-top: 20px; font-weight: 500; min-height: 24px; }
.status.error { color: #ef4444; }
.status.success { color: #10b981; }
.status.loading { color: var(--primary); animation: pulse 1.5s infinite; }
@keyframes pulse { 0%, 100% { opacity: 1; } 50% { opacity: 0.5; } }

/* Auth Page Styles */
.auth-page-bg {
    /* Inherits from body */
}
.auth-box {
    background: rgba(15, 23, 42, 0.6);
    backdrop-filter: blur(16px);
    -webkit-backdrop-filter: blur(16px);
    border-radius: 16px;
    padding: 40px;
    border: 1px solid rgba(255, 255, 255, 0.1);
    box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.5);
    width: 100%;
    max-width: 400px;
}
.auth-box h2 {
    margin-top: 0;
    margin-bottom: 10px;
    text-align: center;
    color: var(--text);
}

/* Footer Styles */
.site-footer {
    width: 100%;
    background: linear-gradient(180deg, #131313 0%, #0a0a0a 100%);
    padding: 4rem 2rem;
    border-top: 1px solid rgba(255, 255, 255, 0.05);
    display: flex;
    flex-wrap: wrap;
    justify-content: space-between;
    align-items: flex-start;
    box-sizing: border-box;
    gap: 2rem;
    position: relative;
    overflow: hidden;
}

.site-footer::before {
    content: "";
    position: absolute;
    top: 0; left: 0; right: 0; height: 1px;
    background: linear-gradient(90deg, transparent, var(--primary), var(--accent), transparent);
    opacity: 0.5;
}

.security-badge {
    flex: 1;
    min-width: 300px;
    max-width: 600px;
    position: relative;
    z-index: 1;
}

.security-badge h4 {
    margin: 0 0 10px 0;
    color: var(--text);
    font-size: 1.1rem;
    font-weight: 600;
    letter-spacing: 0.5px;
    background: linear-gradient(90deg, #ffffff, #a3a3a3);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
}

.security-badge p {
    margin: 0;
    color: var(--text-light);
    font-size: 0.9rem;
    line-height: 1.6;
}

.footer-links {
    display: flex;
    gap: 1.5rem;
    position: relative;
    z-index: 1;
}

.footer-links a {
    color: var(--text-light);
    text-decoration: none;
    font-size: 0.95rem;
    transition: all 0.3s ease;
    position: relative;
    padding-bottom: 2px;
}

.footer-links a::after {
    content: '';
    position: absolute;
    width: 0;
    height: 2px;
    bottom: 0;
    left: 0;
    background: linear-gradient(90deg, var(--primary), var(--accent));
    transition: width 0.3s ease;
    border-radius: 2px;
}

.footer-links a:hover {
    color: #ffffff;
    transform: translateY(-2px);
    text-shadow: 0 0 8px rgba(0, 229, 255, 0.4);
}

.footer-links a:hover::after {
    width: 100%;
}

@media (max-width: 768px) {
    .site-footer {
        flex-direction: column;
        padding: 2rem 1rem;
        gap: 1.5rem;
    }
    .security-badge {
        min-width: 100%;
    }
    .footer-links {
        width: 100%;
        flex-direction: column;
        gap: 1rem;
    }
}

/* FAQ Section */
.faq-section {
    padding: 60px 10%;
    color: white;
}
.faq-section h2 {
    font-size: 32px;
    margin-bottom: 30px;
    text-align: center;
}
.faq-item {
    margin-bottom: 20px;
    background: #181818;
    border-radius: 8px;
    border: 1px solid #333;
    transition: all 0.3s ease;
    overflow: hidden;
}
.faq-item summary {
    padding: 20px;
    font-size: 20px;
    color: #4da6ff;
    font-weight: bold;
    cursor: pointer;
    list-style: none;
    display: flex;
    justify-content: space-between;
    align-items: center;
}
.faq-item summary::-webkit-details-marker {
    display: none;
}
.faq-item summary::after {
    content: '+';
    font-size: 24px;
    color: #4da6ff;
    transition: transform 0.3s ease;
}
.faq-item[open] summary::after {
    content: '\2212';
    transform: rotate(180deg);
}
.faq-item p {
    margin: 0;
    padding: 0 20px 20px 20px;
    color: #ccc;
    line-height: 1.5;
}

/* Legal Content */
.legal-content {
    padding: 60px 10%;
    color: var(--text);
    max-width: 800px;
    margin: 0 auto;
    min-height: 60vh;
}
.legal-content h1 {
    font-size: 36px;
    margin-bottom: 20px;
}
.legal-content p, .legal-content ul, .legal-content li {
    line-height: 1.6;
    color: var(--text-light);
    margin-bottom: 15px;
}
.legal-content h2 {
    margin-top: 30px;
    margin-bottom: 15px;
    color: var(--text);
}

/* Refactored Styles */
.primary-cta {
    display: inline-block;
    background-color: var(--primary);
    color: #ffffff;
    font-size: 1.25rem;
    font-weight: bold;
    padding: 16px 32px;
    border-radius: 8px;
    text-decoration: none;
    margin-top: 24px;
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
    transition: background-color 0.3s, transform 0.2s, box-shadow 0.2s, filter 0.2s;
}
.primary-cta:hover {
    background-color: #1d4ed8;
    transform: translateY(-2px) scale(1.02);
    box-shadow: 0 8px 15px rgba(37, 99, 235, 0.3);
    color: #ffffff;
    filter: brightness(1.1);
}

.sandbox-container {
    background: rgba(15, 23, 42, 0.6);
    backdrop-filter: blur(16px);
    -webkit-backdrop-filter: blur(16px);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 12px;
    padding: 20px;
    box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.5);
    width: 100%;
    max-width: 500px;
    text-align: center;
}



.btn-primary {
    background: linear-gradient(135deg, var(--primary) 0%, var(--accent) 100%);
    color: white;
    padding: 12px 24px;
    border: none;
    border-radius: 8px;
    font-weight: 600;
    cursor: pointer;
    font-size: 1rem;
    transition: all 0.3s ease;
    box-shadow: 0 4px 15px rgba(0, 229, 255, 0.3);
}

.btn-primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 25px rgba(0, 229, 255, 0.5);
    filter: brightness(1.1);
}

.landing-page {
    background: transparent;
    min-height: 100vh;
}

.hero {
    text-align: center;
    padding: 80px 20px;
    background: transparent;
    margin: 40px auto;
    max-width: 900px;
    border-radius: 16px;
}

.sandbox-table {
    width: 100%;
    border-collapse: collapse;
    font-size: 0.875rem;
    text-align: left;
}
.sandbox-table th, .sandbox-table td {
    padding: 12px 8px;
    border-bottom: 1px solid #e2e8f0;
}
.sandbox-table th {
    font-weight: 600;
    color: #64748b;
}

@keyframes anomalyPulse {
    0% { background-color: rgba(239, 68, 68, 0.05); transform: scale(0.98); }
    50% { background-color: rgba(239, 68, 68, 0.25); transform: scale(1.01); }
    100% { background-color: rgba(239, 68, 68, 0.15); transform: scale(1); }
}

.row-exception {
    background-color: rgba(239, 68, 68, 0.15) !important;
    color: #fca5a5 !important;
    font-weight: 500;
    animation: anomalyPulse 0.6s ease-out forwards;
}
.row-exception td:first-child {
    box-shadow: inset 4px 0 0 0 #ef4444;
}

/* Cookie Banner Styles */
.cookie-banner {
    position: fixed;
    bottom: 24px;
    left: 50%;
    transform: translateX(-50%);
    background: rgba(15, 23, 42, 0.95);
    backdrop-filter: blur(16px);
    border: 1px solid rgba(255, 255, 255, 0.1);
    padding: 20px 24px;
    border-radius: 12px;
    box-shadow: 0 10px 40px -10px rgba(0, 0, 0, 0.5);
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 30px;
    width: 90%;
    max-width: 800px;
    z-index: 9999;
}
.cookie-content {
    font-size: 0.9rem;
    color: var(--text-light);
    flex: 1;
    line-height: 1.5;
}

.cookie-content strong {
    color: var(--text);
    font-size: 1rem;
    display: inline-block;
    margin-bottom: 4px;
}

.cookie-btn {
    background: linear-gradient(135deg, var(--primary) 0%, #1a365d 100%);
    color: white;
    border: none;
    padding: 10px 24px;
    border-radius: 8px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.2s ease;
    white-space: nowrap;
    box-shadow: 0 4px 6px -1px rgba(37, 99, 235, 0.2);
}

.cookie-btn:hover {
    transform: translateY(-1px);
    box-shadow: 0 6px 12px -2px rgba(37, 99, 235, 0.3);
}

/* Adjustments for light theme visibility */
.faq-section h2 {
    color: var(--text);
}
.faq-item {
    background: #ffffff;
    border: 1px solid #e2e8f0;
}
.faq-item summary {
    color: var(--text);
}
.faq-item p {
    color: #475569;
}
.banner {
    background: #0f172a;
}

/* Sandbox Button Styles */
.sandbox-btn {
    background: var(--primary);
    color: #fff;
    border: none;
    padding: 10px 24px; /* py-2.5 equivalent */
    border-radius: 6px;
    font-weight: 500;
    font-size: 15px; /* text-sm/base */
    cursor: pointer;
    margin-bottom: 20px;
    width: 100%;
    transition: all 0.2s ease;
    display: flex;
    align-items: center;
    justify-content: center;
}
.sandbox-btn:hover {
    background: var(--primary-hover);
    transform: translateY(-2px);
}

/* Sandbox Table Styles */
.sandbox-table {
    width: 100%;
    border-collapse: collapse;
    text-align: left;
    font-size: 14px;
    margin-top: 10px;
}
.sandbox-table thead tr {
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
    color: var(--text-light);
    font-size: 12px;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    font-weight: 500;
}
.sandbox-table tbody tr {
    border-bottom: 1px solid rgba(255, 255, 255, 0.05); /* subtle border */
}
.sandbox-table th, .sandbox-table td {
    padding: 16px 12px;
    white-space: nowrap; /* prevent wrapping */
}
.sandbox-table th:nth-child(1) { width: 20%; }
.sandbox-table th:nth-child(2) { width: 40%; }
.sandbox-table th:nth-child(3) { width: 20%; text-align: right; }
.sandbox-table td:nth-child(3) { text-align: right; }
.sandbox-table th:nth-child(4) { width: 20%; }
.sandbox-table th:nth-child(4), .sandbox-table td:nth-child(4) {
    white-space: normal;
    line-height: 1.4;
    min-width: 150px;
}

.premium-select {
    padding: 8px 12px;
    border: 1px solid #cbd5e1;
    border-radius: 8px;
    font-size: 13px;
    font-weight: 500;
    background: #ffffff;
    color: #0f172a;
    outline: none;
    cursor: pointer;
    transition: all 0.2s ease;
}
.premium-select:hover {
    border-color: #94a3b8;
}
.premium-select:focus {
    border-color: #3b82f6;
    box-shadow: 0 0 0 3px rgba(59, 130, 246, 0.1);
}

/* Logout Button Refinement */
.logout-btn {
    background: transparent;
    border: none;
    color: #64748b;
    font-weight: 500;
    cursor: pointer;
    font-size: 13px;
    padding: 6px 12px;
    transition: color 0.2s ease;
}
.logout-btn:hover {
    color: #0f172a;
}

/* Floating SVG Animation */
@keyframes float {
    0% { transform: translateY(0px); }
    50% { transform: translateY(-6px); }
    100% { transform: translateY(0px); }
}
.dropzone .icon svg {
    animation: float 3s ease-in-out infinite;
    color: #3b82f6;
}
