/* =============================================================
   ZeroDataUpload Tools - Shared Stylesheet
   Follows same design patterns as blog/blog.css
   ============================================================= */


/* Nav/Footer styles are in /libs/shared-nav.css */

/* ----- Section A: Base Theme ----- */

:root {
    --primary: #8B5CF6;
    --primary-dark: #7C3AED;
    --secondary: #EC4899;
    --success: #51cf66;
    --warning: #ff9f43;
    --danger: #ff6b6b;
    --dark: #0a0a14;
    --light: #f8f9fa;
    --glass-bg: rgba(255, 255, 255, 0.05);
    --glass-border: rgba(255, 255, 255, 0.1);
    --text-primary: #ffffff;
    --text-secondary: #a8a8b3;
    --gradient-1: linear-gradient(135deg, #8B5CF6 0%, #7C3AED 100%);
    --gradient-2: linear-gradient(135deg, #EC4899 0%, #F472B6 100%);
    --gradient-3: linear-gradient(135deg, #3B82F6 0%, #60A5FA 100%);
    --neon-blue: #3B82F6;
}

[data-theme="light"] {
    --dark: #f8f9fa;
    --light: #0a0a14;
    --glass-bg: rgba(0, 0, 0, 0.05);
    --glass-border: rgba(0, 0, 0, 0.1);
    --text-primary: #0a0a14;
    --text-secondary: #6c757d;
}

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

body {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, 'Helvetica Neue', Arial, sans-serif;
    background: var(--dark);
    color: var(--text-primary);
    min-height: 100vh;
    overflow-x: hidden;
    position: relative;
    line-height: 1.6;
    padding: 0;
    padding-top: 80px;
}

body::before {
    content: '';
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background:
        radial-gradient(circle at 20% 50%, rgba(139, 92, 246, 0.15) 0%, transparent 50%),
        radial-gradient(circle at 80% 80%, rgba(236, 72, 153, 0.1) 0%, transparent 50%),
        radial-gradient(circle at 40% 20%, rgba(59, 130, 246, 0.1) 0%, transparent 50%);
    pointer-events: none;
    z-index: -1;
}

html {
    scroll-behavior: smooth;
}

/* ----- Section B: Container ----- */

.container {
    max-width: 900px;
    margin: 20px auto;
    background: var(--glass-bg);
    -webkit-backdrop-filter: blur(20px);
    backdrop-filter: blur(20px);
    border: 1px solid var(--glass-border);
    border-radius: 20px;
    padding: 40px;
    box-shadow:
        0 20px 40px rgba(0, 0, 0, 0.1),
        0 0 80px rgba(139, 92, 246, 0.05);
}

.container.tool-container {
    max-width: 1000px;
}

.container.tools-index-container {
    max-width: 1600px;
    margin-left: 24px;
    margin-right: 24px;
}

/* ----- Section C: Typography ----- */

h1 {
    background: var(--gradient-1);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    font-size: 2.5rem;
    font-weight: 700;
    margin-bottom: 1rem;
    text-align: center;
    position: relative;
}

h1::after {
    content: '';
    position: absolute;
    bottom: -10px;
    left: 50%;
    transform: translateX(-50%);
    width: 80px;
    height: 3px;
    background: var(--gradient-1);
    border-radius: 2px;
}

h2 {
    color: var(--text-primary);
    font-size: 1.5rem;
    font-weight: 600;
    margin: 2rem 0 1rem 0;
    position: relative;
    padding-left: 20px;
}

h2::before {
    content: '';
    position: absolute;
    left: 0;
    top: 50%;
    transform: translateY(-50%);
    width: 4px;
    height: 20px;
    background: var(--gradient-1);
    border-radius: 2px;
}

h3 {
    color: var(--text-secondary);
    font-size: 1.2rem;
    font-weight: 500;
    margin: 1.5rem 0 0.8rem 0;
}

p {
    color: var(--text-primary);
    margin-bottom: 1rem;
    line-height: 1.7;
}

ul, ol {
    padding-left: 25px;
    margin-bottom: 1.5rem;
}

li {
    color: var(--text-primary);
    margin-bottom: 8px;
    line-height: 1.6;
}

li strong {
    color: var(--primary);
}

a {
    color: var(--primary);
    text-decoration: none;
    transition: all 0.3s ease;
    position: relative;
}

a::after {
    content: '';
    position: absolute;
    bottom: -2px;
    left: 0;
    width: 0;
    height: 2px;
    background: var(--gradient-1);
    transition: width 0.3s ease;
}

a:hover::after {
    width: 100%;
}

a:hover {
    color: var(--primary-dark);
}

code {
    background: rgba(139, 92, 246, 0.15);
    color: #a78bfa;
    padding: 2px 8px;
    border-radius: 4px;
    font-size: 0.9em;
    font-family: 'Courier New', Courier, monospace;
}

/* ----- Section D: Navigation ----- */

.tool-nav {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 2rem;
}

.tool-nav a {
    color: var(--text-secondary);
    font-size: 0.9rem;
    display: flex;
    align-items: center;
    gap: 6px;
}

.tool-nav a:hover {
    color: var(--primary);
}

.tool-nav a::after {
    display: none;
}

/* ----- Section E: Theme Toggle ----- */

.theme-toggle {
    position: fixed;
    top: 90px;
    right: 20px;
    width: 50px;
    height: 50px;
    border-radius: 50%;
    background: var(--glass-bg);
    -webkit-backdrop-filter: blur(10px);
    backdrop-filter: blur(10px);
    border: 1px solid var(--glass-border);
    color: var(--text-primary);
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.2rem;
    transition: all 0.3s ease;
    z-index: 40;
}

.theme-toggle:hover {
    transform: translateY(-2px);
    box-shadow: 0 10px 20px rgba(139, 92, 246, 0.2);
}

/* ----- Section F: Tool Header ----- */

.tool-header {
    text-align: center;
    margin-bottom: 2rem;
}

.tool-header .tool-icon {
    width: 80px;
    height: 80px;
    border-radius: 20px;
    margin: 0 auto 1rem;
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
}

.tool-header .tool-icon img {
    width: 64px;
    height: 64px;
    object-fit: contain;
}

.tool-header .tool-tagline {
    color: var(--text-secondary);
    font-size: 1.1rem;
    margin-bottom: 1.5rem;
}

/* ----- Section G: Launch Button ----- */

.tool-launch-btn {
    display: inline-block;
    background: var(--gradient-1);
    color: #ffffff;
    padding: 14px 36px;
    border-radius: 12px;
    font-size: 1rem;
    font-weight: 600;
    text-decoration: none;
    transition: all 0.3s ease;
    box-shadow: 0 4px 15px rgba(139, 92, 246, 0.3);
}

.tool-launch-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 25px rgba(139, 92, 246, 0.4);
    color: #ffffff;
}

.tool-launch-btn::after {
    display: none;
}

/* ----- Section H: Feature Grid ----- */

.feature-grid {
    display: grid;
    grid-template-columns: 1fr;
    gap: 16px;
    margin: 1.5rem 0;
}

@media (min-width: 640px) {
    .feature-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

.feature-card {
    background: var(--glass-bg);
    -webkit-backdrop-filter: blur(10px);
    backdrop-filter: blur(10px);
    border: 1px solid var(--glass-border);
    border-radius: 12px;
    padding: 20px;
    transition: all 0.3s ease;
}

.feature-card:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 25px rgba(139, 92, 246, 0.1);
    border-color: rgba(139, 92, 246, 0.3);
}

.feature-card h3 {
    color: var(--primary);
    font-size: 1.05rem;
    font-weight: 600;
    margin: 0 0 8px 0;
}

.feature-card p {
    color: var(--text-secondary);
    font-size: 0.9rem;
    margin-bottom: 0;
    line-height: 1.5;
}

/* ----- Section I: Step Guide ----- */

.step-list {
    counter-reset: step-counter;
    list-style: none;
    padding-left: 0;
}

.step-list li {
    counter-increment: step-counter;
    position: relative;
    padding-left: 50px;
    margin-bottom: 1.5rem;
}

.step-list li::before {
    content: counter(step-counter);
    position: absolute;
    left: 0;
    top: 0;
    width: 36px;
    height: 36px;
    background: var(--gradient-1);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 700;
    font-size: 0.9rem;
    color: #ffffff;
}

/* ----- Section J: FAQ Section ----- */

.faq-item {
    background: var(--glass-bg);
    -webkit-backdrop-filter: blur(10px);
    backdrop-filter: blur(10px);
    border: 1px solid var(--glass-border);
    border-left: 4px solid var(--primary);
    padding: 20px 25px;
    border-radius: 0 12px 12px 0;
    margin-bottom: 16px;
    transition: all 0.3s ease;
}

.faq-item:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 25px rgba(139, 92, 246, 0.1);
}

.faq-item .question {
    font-weight: 700;
    color: var(--primary);
    margin-bottom: 0.5rem;
    font-size: 1.05rem;
}

.faq-item .answer {
    color: var(--text-primary);
    line-height: 1.7;
}

.faq-item .answer ul {
    margin-top: 0.5rem;
    margin-bottom: 0;
}

/* ----- Section K: Callout Box ----- */

.callout {
    background: rgba(139, 92, 246, 0.1);
    border: 1px solid rgba(139, 92, 246, 0.3);
    border-radius: 12px;
    padding: 20px;
    margin: 1.5rem 0;
}

.callout-title {
    font-weight: 700;
    color: var(--primary);
    margin-bottom: 8px;
}

.callout-privacy {
    background: rgba(52, 211, 153, 0.1);
    border-color: rgba(52, 211, 153, 0.3);
}

.callout-privacy .callout-title {
    color: #34d399;
}

/* ----- Section L: CTA Section ----- */

.tool-cta {
    text-align: center;
    padding: 30px;
    margin: 2rem 0;
    background: var(--glass-bg);
    border: 1px solid var(--glass-border);
    border-radius: 15px;
}

.tool-cta p {
    color: var(--text-secondary);
    margin-bottom: 1.5rem;
    font-size: 1.1rem;
}

/* ----- Section M: Table of Contents ----- */

.toc {
    background: var(--glass-bg);
    border: 1px solid var(--glass-border);
    border-radius: 12px;
    padding: 20px 25px;
    margin: 2rem 0;
}

.toc h3 {
    color: var(--primary);
    font-size: 1rem;
    font-weight: 600;
    margin-bottom: 12px;
    text-transform: uppercase;
    letter-spacing: 1px;
}

.toc ol {
    padding-left: 20px;
    margin-bottom: 0;
}

.toc li {
    margin-bottom: 6px;
    font-size: 0.9rem;
}

.toc a {
    color: var(--text-secondary);
}

.toc a:hover {
    color: var(--primary);
}

.toc a::after {
    display: none;
}

/* ----- Section N: Tools Index Grid ----- */

.tools-subtitle {
    text-align: center;
    color: var(--text-secondary);
    margin-bottom: 2rem;
    font-size: 1.1rem;
}

.tools-grid {
    display: grid;
    grid-template-columns: 1fr;
    gap: 20px;
    margin-top: 2rem;
}

@media (min-width: 640px) {
    .tools-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (min-width: 1024px) {
    .tools-grid {
        grid-template-columns: repeat(3, 1fr);
    }
}

.tool-card {
    background: var(--glass-bg);
    -webkit-backdrop-filter: blur(10px);
    backdrop-filter: blur(10px);
    border: 1px solid var(--glass-border);
    border-radius: 15px;
    padding: 25px;
    transition: all 0.3s ease;
    text-decoration: none;
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
}

.tool-card:hover {
    transform: translateY(-4px);
    box-shadow: 0 15px 40px rgba(139, 92, 246, 0.15);
    border-color: rgba(139, 92, 246, 0.3);
}

.tool-card::after {
    display: none;
}

.tool-card .card-icon {
    width: 60px;
    height: 60px;
    border-radius: 15px;
    display: flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 1rem;
    overflow: hidden;
}

.tool-card .card-icon img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transform: scale(1.1);
}

.tool-card h3 {
    color: var(--text-primary);
    font-size: 1.1rem;
    font-weight: 600;
    margin: 0 0 0.5rem 0;
}

.tool-card p {
    color: var(--text-secondary);
    font-size: 0.85rem;
    margin-bottom: 1rem;
    flex-grow: 1;
}

.tool-card .card-links {
    display: flex;
    gap: 10px;
    width: 100%;
}

.tool-card .card-links a {
    flex: 1;
    text-align: center;
    padding: 8px 12px;
    border-radius: 8px;
    font-size: 0.8rem;
    font-weight: 600;
    transition: all 0.3s ease;
}

.tool-card .card-links a::after {
    display: none;
}

.tool-card .card-links .btn-learn {
    background: var(--glass-bg);
    border: 1px solid var(--glass-border);
    color: var(--text-primary);
}

.tool-card .card-links .btn-learn:hover {
    background: rgba(139, 92, 246, 0.1);
    border-color: rgba(139, 92, 246, 0.3);
    color: var(--primary);
}

.tool-card .card-links .btn-launch {
    background: var(--gradient-1);
    color: #ffffff;
}

.tool-card .card-links .btn-launch:hover {
    box-shadow: 0 4px 15px rgba(139, 92, 246, 0.3);
}

/* ----- Section O: Related Tools ----- */

.related-tools {
    display: grid;
    grid-template-columns: 1fr;
    gap: 16px;
    margin-top: 1rem;
}

@media (min-width: 640px) {
    .related-tools {
        grid-template-columns: repeat(2, 1fr);
    }
}

.related-tool-card {
    background: var(--glass-bg);
    border: 1px solid var(--glass-border);
    border-radius: 12px;
    padding: 20px;
    transition: all 0.3s ease;
    text-decoration: none;
    display: block;
}

.related-tool-card:hover {
    transform: translateY(-2px);
    box-shadow: 0 10px 25px rgba(139, 92, 246, 0.1);
    border-color: rgba(139, 92, 246, 0.3);
}

.related-tool-card::after {
    display: none;
}

.related-tool-card h3 {
    font-size: 1.1rem;
    color: var(--text-primary);
    margin: 0 0 0.5rem 0;
}

.related-tool-card p {
    font-size: 0.9rem;
    color: var(--text-secondary);
    margin-bottom: 0;
}

/* ----- Section P1b: Tool Hero Image ----- */

.tool-hero-img {
    width: 100%;
    max-height: 400px;
    object-fit: cover;
    border-radius: 16px;
    border: 1px solid var(--glass-border);
    margin-bottom: 2rem;
}

/* ----- Section P2: Author Bio ----- */

.author-bio {
    display: flex;
    gap: 20px;
    align-items: flex-start;
    background: var(--glass-bg);
    border: 1px solid var(--glass-border);
    border-radius: 15px;
    padding: 25px;
    margin: 2.5rem 0;
}

.author-bio .author-avatar {
    width: 64px;
    height: 64px;
    border-radius: 50%;
    object-fit: cover;
    flex-shrink: 0;
    border: 2px solid rgba(139, 92, 246, 0.4);
}

.author-bio .author-info h3 {
    color: var(--text-primary);
    font-size: 1.1rem;
    font-weight: 600;
    margin: 0 0 4px 0;
}

.author-bio .author-info .author-role {
    color: var(--primary);
    font-size: 0.85rem;
    font-weight: 500;
    margin-bottom: 8px;
}

.author-bio .author-info p {
    color: var(--text-secondary);
    font-size: 0.9rem;
    line-height: 1.6;
    margin-bottom: 0;
}

.author-bio .author-info a {
    color: #c4b5fd;
    text-decoration: underline;
    text-underline-offset: 2px;
}

.author-bio .author-info a:hover {
    color: #e9d5ff;
}

.author-bio .author-info a::after {
    display: none;
}

@media (max-width: 768px) {
    .author-bio {
        flex-direction: column;
        align-items: center;
        text-align: center;
    }
}

/* ----- Section P: Last Updated ----- */

.last-updated {
    text-align: center;
    margin-top: 3rem;
    padding: 20px;
    background: var(--glass-bg);
    border-radius: 10px;
    color: var(--text-secondary);
    font-style: italic;
    border: 1px solid var(--glass-border);
}

/* ----- Section Q: Responsive ----- */

@media (max-width: 768px) {
    body {
        padding: 0;
        padding-top: 70px;
    }

    .container {
        padding: 20px;
        border-radius: 15px;
        margin: 15px;
    }

    .theme-toggle {
        top: 75px;
        right: 15px;
    }

    h1 {
        font-size: 2rem;
    }

    h2 {
        font-size: 1.3rem;
    }

    .theme-toggle {
        width: 45px;
        height: 45px;
        top: 15px;
        right: 15px;
        font-size: 1.1rem;
    }

    .tool-nav {
        flex-direction: column;
        gap: 8px;
        align-items: flex-start;
    }

    .tool-header .tool-icon {
        width: 64px;
        height: 64px;
    }

    .tool-header .tool-icon img {
        width: 48px;
        height: 48px;
    }

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

    .related-tools {
        grid-template-columns: 1fr;
    }

    .tool-card .card-links {
        flex-direction: column;
    }
}
