/* 
 * PixelFLowConvertor - Global Styles
 * Theme: Dark Mode with Violet and Red accents, Glassmorphism 
 */

:root {
    /* Colors */
    --accent-violet: #8v2be2;
    --accent-violet: #8A2BE2;
    /* Primary Violet */
    --accent-red: #FF003C;
    /* Secondary Red/Pink */

    --bg-base: #0a0616;
    /* Very dark indigo/black */
    --bg-surface: #130c25;
    /* Slightly lighter surface */
    --bg-surface-elevated: #1e1338;

    --text-primary: #ffffff;
    --text-secondary: #a8a0bd;

    --glass-bg: rgba(255, 255, 255, 0.03);
    --glass-border: rgba(255, 255, 255, 0.08);

    /* Typography */
    --font-heading: 'Outfit', sans-serif;
    --font-body: 'Inter', sans-serif;

    /* Variables */
    --border-radius-sm: 8px;
    --border-radius-md: 16px;
    --border-radius-lg: 24px;

    --transition-fast: 0.2s ease;
    --transition-smooth: 0.4s cubic-bezier(0.16, 1, 0.3, 1);
}

/* Base Reset */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
}

body {
    font-family: var(--font-body);
    background-color: var(--bg-base);
    color: var(--text-primary);
    line-height: 1.6;
    overflow-x: hidden;
    position: relative;
    min-height: 100vh;
    display: flex;
    flex-direction: column;
}

/* Background Canvas */
#particles-bg {
    position: fixed;
    top: 0;
    left: 0;
    width: 100vw;
    height: 100vh;
    z-index: -1;
    pointer-events: none;
}

h1,
h2,
h3,
h4,
h5,
h6 {
    font-family: var(--font-heading);
    font-weight: 700;
    line-height: 1.2;
}

a {
    color: inherit;
    text-decoration: none;
    transition: var(--transition-fast);
}

ul {
    list-style: none;
}

.container {
    width: 100%;
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 24px;
}

/* Utilities */
.gradient-text {
    background: linear-gradient(135deg, var(--accent-violet), var(--accent-red));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.badge {
    display: inline-block;
    padding: 6px 14px;
    background: rgba(255, 0, 60, 0.1);
    color: var(--accent-red);
    border: 1px solid rgba(255, 0, 60, 0.2);
    border-radius: 100px;
    font-size: 0.85rem;
    font-weight: 600;
    margin-bottom: 20px;
}

/* Buttons */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    padding: 14px 28px;
    border-radius: var(--border-radius-md);
    font-weight: 600;
    font-family: var(--font-heading);
    cursor: pointer;
    transition: var(--transition-smooth);
    border: none;
    font-size: 1rem;
}

.btn-primary {
    background: linear-gradient(135deg, var(--accent-violet), var(--accent-red));
    color: white;
    box-shadow: 0 4px 20px rgba(138, 43, 226, 0.3);
}

.btn-primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 25px rgba(255, 0, 60, 0.4);
}

.btn-outline {
    background: var(--glass-bg);
    border: 1px solid var(--glass-border);
    color: var(--text-primary);
    backdrop-filter: blur(10px);
}

.btn-outline:hover {
    background: rgba(255, 255, 255, 0.1);
    border-color: rgba(255, 255, 255, 0.2);
}

/* Header & Navigation */
.header {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    z-index: 100;
    background: rgba(10, 6, 22, 0.7);
    backdrop-filter: blur(16px);
    -webkit-backdrop-filter: blur(16px);
    border-bottom: 1px solid var(--glass-border);
    transition: var(--transition-smooth);
}

.header.scrolled {
    padding: 10px 0;
    background: rgba(10, 6, 22, 0.9);
}

.header-inner {
    display: flex;
    justify-content: space-between;
    align-items: center;
    height: 80px;
}

.logo {
    display: flex;
    align-items: center;
    gap: 10px;
    font-family: var(--font-heading);
    font-size: 1.5rem;
    font-weight: 800;
}

.logo i {
    font-size: 2rem;
    background: linear-gradient(135deg, var(--accent-violet), var(--accent-red));
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
}

.logo .highlight {
    font-weight: 400;
    color: var(--text-secondary);
}

.main-nav ul {
    display: flex;
    gap: 32px;
    align-items: center;
}

.main-nav a {
    font-size: 0.95rem;
    font-weight: 500;
    color: var(--text-secondary);
}

.main-nav a:hover,
.main-nav a.active {
    color: var(--text-primary);
}

.dropdown-trigger {
    position: relative;
}

.dropdown-trigger i {
    font-size: 0.8rem;
    vertical-align: middle;
}

.dropdown {
    position: absolute;
    top: 100%;
    left: 50%;
    transform: translateX(-50%) translateY(10px);
    background: var(--bg-surface-elevated);
    border: 1px solid var(--glass-border);
    border-radius: var(--border-radius-md);
    padding: 12px 0;
    min-width: 200px;
    opacity: 0;
    visibility: hidden;
    transition: var(--transition-fast);
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.5);
    flex-direction: column !important;
    gap: 0 !important;
}

.dropdown-trigger:hover .dropdown {
    opacity: 1;
    visibility: visible;
    transform: translateX(-50%) translateY(0);
}

.dropdown li {
    width: 100%;
}

.dropdown a {
    display: block;
    padding: 10px 20px;
    width: 100%;
}

.dropdown a:hover {
    background: rgba(255, 255, 255, 0.05);
}

.mobile-menu-btn {
    display: none;
    background: none;
    border: none;
    color: var(--text-primary);
    font-size: 1.8rem;
    cursor: pointer;
}

/* Sections */
main {
    flex: 1;
}

.section-header {
    text-align: center;
    margin-bottom: 60px;
    max-width: 600px;
    margin-inline: auto;
}

.section-header h2 {
    font-size: 2.5rem;
    margin-bottom: 16px;
}

.section-header p {
    color: var(--text-secondary);
    font-size: 1.1rem;
}

/* Hero Section */
.hero {
    min-height: 100vh;
    display: flex;
    align-items: center;
    padding-top: 80px;
    position: relative;
    overflow: hidden;
}

.hero::before {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: 600px;
    height: 600px;
    background: radial-gradient(circle, rgba(138, 43, 226, 0.15) 0%, rgba(10, 6, 22, 0) 70%);
    z-index: -1;
    border-radius: 50%;
}

.hero-text {
    max-width: 800px;
    margin: 0 auto;
    text-align: center;
}

.hero h1 {
    font-size: clamp(3rem, 5vw, 4.5rem);
    margin-bottom: 24px;
    letter-spacing: -1px;
}

.hero p {
    font-size: 1.2rem;
    color: var(--text-secondary);
    margin-bottom: 40px;
    max-width: 600px;
    margin-inline: auto;
}

.hero-actions {
    display: flex;
    gap: 16px;
    justify-content: center;
}

/* Tools Grid */
.tools-section {
    padding: 100px 0;
    position: relative;
}

.tools-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
    gap: 24px;
}

.tool-card {
    background: var(--bg-surface);
    border: 1px solid var(--glass-border);
    border-radius: var(--border-radius-lg);
    padding: 32px;
    transition: var(--transition-smooth);
    position: relative;
    overflow: hidden;
    z-index: 1;
}

.tool-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(135deg, rgba(138, 43, 226, 0.1), rgba(255, 0, 60, 0.1));
    opacity: 0;
    transition: var(--transition-smooth);
    z-index: -1;
}

.tool-card:hover {
    transform: translateY(-8px);
    border-color: rgba(138, 43, 226, 0.3);
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.3);
}

.tool-card:hover::before {
    opacity: 1;
}

.tool-icon {
    width: 60px;
    height: 60px;
    background: var(--bg-surface-elevated);
    border-radius: var(--border-radius-md);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.8rem;
    color: var(--accent-violet);
    margin-bottom: 24px;
    border: 1px solid var(--glass-border);
    transition: var(--transition-fast);
}

.tool-card:hover .tool-icon {
    background: linear-gradient(135deg, var(--accent-violet), var(--accent-red));
    color: white;
    border-color: transparent;
}

.tool-card h3 {
    font-size: 1.3rem;
    margin-bottom: 12px;
}

.tool-card p {
    color: var(--text-secondary);
    font-size: 0.95rem;
}

/* Features Section */
.features-section {
    padding: 80px 0 120px;
    border-top: 1px solid var(--glass-border);
}

.features-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 40px;
}

.feature-item {
    display: flex;
    gap: 20px;
}

.feature-icon {
    font-size: 2rem;
    color: var(--accent-red);
    flex-shrink: 0;
}

.feature-text h4 {
    font-size: 1.2rem;
    margin-bottom: 8px;
}

.feature-text p {
    color: var(--text-secondary);
    font-size: 0.95rem;
}

/* Footer */
.footer {
    background: var(--bg-surface);
    border-top: 1px solid var(--glass-border);
    padding-top: 80px;
}

.footer-grid {
    display: grid;
    grid-template-columns: 2fr 1fr 1fr 1fr;
    gap: 40px;
    margin-bottom: 60px;
}

.brand-col p {
    color: var(--text-secondary);
    margin: 20px 0;
    max-width: 300px;
}

.social-links {
    display: flex;
    gap: 16px;
}

.social-links a {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    background: var(--bg-surface-elevated);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.2rem;
    color: var(--text-secondary);
    border: 1px solid var(--glass-border);
}

.social-links a:hover {
    background: var(--accent-violet);
    color: white;
    transform: translateY(-3px);
}

.footer-col h4 {
    font-size: 1.1rem;
    margin-bottom: 24px;
}

.footer-col ul {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.footer-col a {
    color: var(--text-secondary);
}

.footer-col a:hover {
    color: var(--accent-red);
}

.footer-bottom {
    padding: 24px 0;
    border-top: 1px solid var(--glass-border);
    text-align: center;
    color: var(--text-secondary);
    font-size: 0.9rem;
}

/* Responsive */
@media (max-width: 900px) {
    .footer-grid {
        grid-template-columns: 1fr 1fr;
    }
}

@media (max-width: 768px) {
    .mobile-menu-btn {
        display: block;
    }

    .main-nav {
        position: fixed;
        top: 80px;
        left: -100%;
        width: 100%;
        height: calc(100vh - 80px);
        background: var(--bg-base);
        padding: 40px 24px;
        transition: var(--transition-smooth);
    }

    .main-nav.active {
        left: 0;
    }

    .main-nav ul {
        flex-direction: column;
        align-items: flex-start;
        gap: 24px;
    }

    .dropdown {
        position: static;
        opacity: 1;
        visibility: visible;
        transform: none;
        box-shadow: none;
        border: none;
        background: rgba(255, 255, 255, 0.02);
        margin-top: 10px;
        display: none;
    }

    .dropdown-trigger.active .dropdown {
        display: flex;
    }

    .hero h1 {
        font-size: 2.5rem;
    }

    .hero-actions {
        flex-direction: column;
    }
}

/* --------------------------------------
 * Internal Pages CSS 
 * -------------------------------------- */

.page-container {
    padding-top: 100px;
    /* Offset for fixed header */
    padding-bottom: 60px;
    min-height: calc(100vh - 350px);
}

.page-header {
    padding: 60px 0 40px;
    position: relative;
}

.text-center {
    text-align: center;
}

.page-header h1 {
    font-size: 3rem;
    margin-bottom: 16px;
}

.page-header p {
    font-size: 1.2rem;
    color: var(--text-secondary);
}

.glass-panel {
    background: var(--bg-surface);
    border: 1px solid var(--glass-border);
    border-radius: var(--border-radius-lg);
    padding: 40px;
    position: relative;
    z-index: 1;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.2);
}

.text-content h2 {
    font-size: 1.8rem;
    margin: 32px 0 16px;
    color: var(--text-primary);
}

.text-content p {
    margin-bottom: 20px;
    color: var(--text-secondary);
    font-size: 1.05rem;
    line-height: 1.7;
}

.text-content ul {
    margin-bottom: 24px;
    padding-left: 20px;
}

.text-content li {
    margin-bottom: 10px;
    color: var(--text-secondary);
    list-style-type: disc;
}

.feature-list {
    list-style: none !important;
    padding-left: 0 !important;
}

.feature-list li {
    display: flex;
    align-items: flex-start;
    gap: 12px;
    margin-bottom: 16px;
}

.feature-list i {
    color: var(--accent-violet);
    font-size: 1.4rem;
    margin-top: 3px;
}

/* Contact Page specifics */
.contact-grid {
    display: grid;
    grid-template-columns: 1fr 1.5fr;
    gap: 40px;
}

.contact-info .info-item {
    display: flex;
    align-items: center;
    gap: 20px;
    margin-top: 30px;
}

.info-item i {
    width: 50px;
    height: 50px;
    background: rgba(138, 43, 226, 0.1);
    color: var(--accent-violet);
    border-radius: var(--border-radius-sm);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.5rem;
}

.info-item h4 {
    margin-bottom: 4px;
    font-size: 1.1rem;
}

.info-item p {
    color: var(--text-secondary);
    margin: 0;
}

/* Forms */
.form-group {
    margin-bottom: 24px;
}

.form-group label {
    display: block;
    margin-bottom: 8px;
    font-weight: 500;
    color: var(--text-secondary);
}

.form-group input,
.form-group textarea,
.form-group select {
    width: 100%;
    padding: 14px 16px;
    background: var(--bg-surface-elevated);
    border: 1px solid var(--glass-border);
    border-radius: var(--border-radius-sm);
    color: var(--text-primary);
    font-family: var(--font-body);
    font-size: 1rem;
    transition: var(--transition-fast);
}

.form-group input:focus,
.form-group textarea:focus,
.form-group select:focus {
    outline: none;
    border-color: var(--accent-violet);
    box-shadow: 0 0 0 2px rgba(138, 43, 226, 0.2);
}

@media (max-width: 768px) {
    .contact-grid {
        grid-template-columns: 1fr;
    }

    .glass-panel {
        padding: 24px;
    }
}

/* --------------------------------------
 * Tool Pages CSS 
 * -------------------------------------- */

.tool-workspace {
    margin-bottom: 60px;
}

.workspace-grid {
    display: grid;
    grid-template-columns: 1fr 350px;
    gap: 30px;
    align-items: start;
}

.upload-area {
    border: 2px dashed rgba(138, 43, 226, 0.5);
    border-radius: var(--border-radius-lg);
    background: rgba(138, 43, 226, 0.05);
    min-height: 400px;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    text-align: center;
    padding: 40px;
    transition: var(--transition-fast);
    cursor: pointer;
    position: relative;
    overflow: hidden;
}

.upload-area:hover,
.upload-area.dragover {
    background: rgba(138, 43, 226, 0.1);
    border-color: var(--accent-violet);
}

.upload-area i {
    font-size: 4rem;
    color: var(--accent-violet);
    margin-bottom: 20px;
}

.upload-area h3 {
    margin-bottom: 10px;
}

.upload-area p {
    color: var(--text-secondary);
    margin-bottom: 20px;
}

.tool-settings {
    padding: 30px;
}

.tool-settings h3 {
    margin-bottom: 24px;
    padding-bottom: 12px;
    border-bottom: 1px solid var(--glass-border);
}

.setting-group {
    margin-bottom: 20px;
}

.setting-group label {
    display: block;
    margin-bottom: 8px;
    font-weight: 500;
    color: var(--text-secondary);
    font-size: 0.9rem;
}

.setting-row {
    display: flex;
    gap: 15px;
}

.setting-row .form-group {
    flex: 1;
    margin-bottom: 0;
}

.checkbox-group {
    display: flex;
    align-items: center;
    gap: 10px;
    cursor: pointer;
}

.checkbox-group input {
    width: auto;
    cursor: pointer;
}

.preview-container {
    width: 100%;
    margin-top: 20px;
    border-radius: var(--border-radius-md);
    overflow: hidden;
    background: #000;
    display: none;
    /* hidden initially */
    justify-content: center;
    align-items: center;
    position: relative;
    min-height: 200px;
}

.preview-container img,
.preview-container canvas {
    max-width: 100%;
    max-height: 60vh;
    object-fit: contain;
}

.action-buttons {
    margin-top: 30px;
    display: flex;
    flex-direction: column;
    gap: 15px;
}

.action-buttons .btn {
    width: 100%;
}

.info-text {
    font-size: 0.85rem;
    color: var(--text-secondary);
    margin-top: 8px;
}

/* Tool Content SEO sections */
.tool-content-section {
    margin: 60px 0;
}

.faq-item {
    margin-bottom: 20px;
    border: 1px solid var(--glass-border);
    border-radius: var(--border-radius-md);
    background: var(--bg-surface);
    overflow: hidden;
}

.faq-question {
    padding: 20px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    cursor: pointer;
    font-weight: 600;
}

.faq-question i {
    transition: transform 0.3s ease;
}

.faq-item.active .faq-question i {
    transform: rotate(180deg);
}

.faq-answer {
    padding: 0 20px 20px;
    color: var(--text-secondary);
    display: none;
}

@media (max-width: 900px) {
    .workspace-grid {
        grid-template-columns: 1fr;
    }
}

@media (max-width: 600px) {
    .footer-grid {
        grid-template-columns: 1fr;
    }
}