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

:root {
    --primary-color: #f97316;
    --primary-hover: #ea580c;
    --text-primary: #1e293b;
    --text-secondary: #475569;
    --text-muted: #64748b;
    --background: #f8fafc;
    --background-secondary: #e2e8f0;
    --border: #cbd5e1;
    --card-background: #ffffff;
    --accent-bg: #fef3c7;
    --accent-border: #fbbf24;
    --shadow: 0 1px 3px 0 rgba(0, 0, 0, 0.1), 0 1px 2px 0 rgba(0, 0, 0, 0.06);
    --shadow-lg: 0 10px 15px -3px rgba(0, 0, 0, 0.1), 0 4px 6px -2px rgba(0, 0, 0, 0.05);
    --gradient-bg: linear-gradient(135deg, #f8fafc 0%, #e2e8f0 100%);
}

[data-theme="dark"] {
    --text-primary: #f9fafb;
    --text-secondary: #d1d5db;
    --text-muted: #9ca3af;
    --background: #111827;
    --background-secondary: #1f2937;
    --border: rgba(255, 255, 255, 0.1);
    --card-background: #374151;
    --accent-bg: #374151;
    --accent-border: #f97316;
    --shadow: 0 1px 3px 0 rgba(0, 0, 0, 0.3), 0 1px 2px 0 rgba(0, 0, 0, 0.2);
    --shadow-lg: 0 10px 15px -3px rgba(0, 0, 0, 0.3), 0 4px 6px -2px rgba(0, 0, 0, 0.2);
    --gradient-bg: linear-gradient(135deg, #111827 0%, #1f2937 100%);
}

body {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, 'Helvetica Neue', Arial, sans-serif;
    line-height: 1.6;
    color: var(--text-primary);
    background: var(--gradient-bg);
    transition: background-color 0.3s ease, color 0.3s ease;
    min-height: 100vh;
}

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

/* Header */
.header {
    background: linear-gradient(135deg, var(--primary-color) 0%, var(--primary-hover) 100%);
    color: white;
    box-shadow: var(--shadow-lg);
    position: sticky;
    top: 0;
    z-index: 100;
    backdrop-filter: blur(10px);
}

.nav {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 0.75rem 0;
}

.nav-brand {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    font-size: 1.25rem;
    font-weight: bold;
}

.nav-icon {
    font-size: 1.5rem;
    filter: drop-shadow(0 2px 4px rgba(0, 0, 0, 0.2));
}

.nav-links {
    display: flex;
    align-items: center;
    gap: 1.5rem;
}

.nav-link {
    color: white;
    text-decoration: none;
    transition: all 0.3s ease;
    padding: 0.5rem 1rem;
    border-radius: 0.375rem;
    font-weight: 500;
}

.nav-link:hover {
    background-color: rgba(255, 255, 255, 0.1);
    transform: translateY(-1px);
}

.theme-toggle {
    background: rgba(255, 255, 255, 0.1);
    border: 1px solid rgba(255, 255, 255, 0.2);
    color: white;
    cursor: pointer;
    padding: 0.5rem;
    border-radius: 0.5rem;
    transition: all 0.3s ease;
    backdrop-filter: blur(10px);
}

.theme-toggle:hover {
    background-color: rgba(255, 255, 255, 0.2);
    transform: scale(1.05);
}

.theme-icon {
    font-size: 1.25rem;
}

/* Main Content */
.main {
    min-height: calc(100vh - 80px);
}

/* Hero Section */
.hero {
    text-align: center;
    padding: 2rem 0;
    background: var(--gradient-bg);
    position: relative;
    overflow: hidden;
}

.hero::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: radial-gradient(circle at 50% 50%, rgba(249, 115, 22, 0.1) 0%, transparent 50%);
    pointer-events: none;
}

.hero-title {
    font-size: 2.5rem;
    font-weight: 800;
    margin-bottom: 0.75rem;
    color: var(--text-primary);
    background: linear-gradient(135deg, var(--primary-color), var(--primary-hover));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    position: relative;
}

.hero-subtitle {
    font-size: 1.125rem;
    color: var(--text-secondary);
    margin-bottom: 1.5rem;
    font-weight: 500;
}

.download-form {
    max-width: 32rem;
    margin: 0 auto;
    position: relative;
    z-index: 1;
}

.input-group {
    display: flex;
    gap: 0.5rem;
    margin-bottom: 1rem;
    background: var(--card-background);
    padding: 0.25rem;
    border-radius: 0.75rem;
    box-shadow: var(--shadow-lg);
    border: 2px solid var(--border);
}

.url-input {
    flex: 1;
    padding: 0.75rem 1rem;
    border: none;
    border-radius: 0.5rem;
    font-size: 1rem;
    background: transparent;
    color: var(--text-primary);
    transition: all 0.3s ease;
}

.url-input:focus {
    outline: none;
    background: var(--accent-bg);
}

.url-input::placeholder {
    color: var(--text-muted);
}

.paste-btn {
    padding: 0.75rem;
    background: var(--background-secondary);
    border: none;
    border-radius: 0.5rem;
    cursor: pointer;
    font-size: 1rem;
    transition: all 0.3s ease;
    color: var(--text-primary);
}

.paste-btn:hover {
    background: var(--accent-bg);
    transform: scale(1.05);
}

.download-btn {
    padding: 0.75rem 1.5rem;
    background: linear-gradient(135deg, var(--primary-color), var(--primary-hover));
    color: white;
    border: none;
    border-radius: 0.5rem;
    font-size: 1rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    box-shadow: 0 4px 12px rgba(249, 115, 22, 0.3);
}

.download-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(249, 115, 22, 0.4);
}

.download-btn:disabled {
    opacity: 0.5;
    cursor: not-allowed;
    transform: none;
}

.example-text {
    font-size: 0.875rem;
    color: var(--text-muted);
    background: var(--accent-bg);
    padding: 0.75rem 1rem;
    border-radius: 0.5rem;
    border: 1px solid var(--accent-border);
}

.example-link {
    background: none;
    border: none;
    color: var(--primary-color);
    text-decoration: underline;
    cursor: pointer;
    font-size: inherit;
    font-weight: 600;
}

.example-link:hover {
    color: var(--primary-hover);
}

/* Sections */
.features,
.about,
.how-to-use,
.faq,
.contact {
    padding: 2.5rem 0;
}

.features {
    background: var(--card-background);
    border-top: 1px solid var(--border);
    border-bottom: 1px solid var(--border);
}

.section-title {
    font-size: 1.875rem;
    font-weight: 700;
    text-align: center;
    margin-bottom: 2rem;
    color: var(--text-primary);
}

/* Features Grid */
.features-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 1.5rem;
}

.feature-card {
    background: var(--background);
    padding: 1.5rem;
    border-radius: 0.75rem;
    text-align: center;
    box-shadow: var(--shadow);
    transition: all 0.3s ease;
    border: 1px solid var(--border);
    position: relative;
    overflow: hidden;
}

.feature-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 3px;
    background: linear-gradient(90deg, var(--primary-color), var(--primary-hover));
}

.feature-card:hover {
    transform: translateY(-4px);
    box-shadow: var(--shadow-lg);
    border-color: var(--primary-color);
}

.feature-icon {
    font-size: 2.5rem;
    margin-bottom: 1rem;
    background: linear-gradient(135deg, var(--primary-color), var(--primary-hover));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.feature-title {
    font-size: 1.125rem;
    font-weight: 600;
    margin-bottom: 0.5rem;
    color: var(--text-primary);
}

.feature-description {
    color: var(--text-secondary);
    font-size: 0.9rem;
    line-height: 1.5;
}

/* Content Cards */
.content-card {
    background: var(--card-background);
    padding: 2rem;
    border-radius: 0.75rem;
    box-shadow: var(--shadow);
    border: 1px solid var(--border);
    position: relative;
}

.content-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 3px;
    background: linear-gradient(90deg, var(--primary-color), var(--primary-hover));
    border-radius: 0.75rem 0.75rem 0 0;
}

.card-title {
    font-size: 1.5rem;
    font-weight: 600;
    margin-bottom: 1rem;
    color: var(--text-primary);
}

.card-subtitle {
    color: var(--text-secondary);
    margin-bottom: 1.5rem;
    font-weight: 500;
}

.card-content {
    color: var(--text-secondary);
    line-height: 1.7;
}

/* Steps */
.steps {
    margin: 1.5rem 0;
}

.step {
    display: flex;
    gap: 1rem;
    margin-bottom: 1.25rem;
    padding: 1rem;
    background: var(--background);
    border-radius: 0.5rem;
    border: 1px solid var(--border);
    transition: all 0.3s ease;
}

.step:hover {
    border-color: var(--primary-color);
    transform: translateX(4px);
}

.step-number {
    background: linear-gradient(135deg, var(--primary-color), var(--primary-hover));
    color: white;
    width: 1.75rem;
    height: 1.75rem;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 600;
    flex-shrink: 0;
    font-size: 0.875rem;
    box-shadow: 0 2px 8px rgba(249, 115, 22, 0.3);
}

.step-text {
    color: var(--text-secondary);
    line-height: 1.6;
    font-size: 0.95rem;
}

.separator {
    height: 1px;
    background: linear-gradient(90deg, transparent, var(--border), transparent);
    margin: 1.5rem 0;
}

.conclusion {
    text-align: center;
    color: var(--text-primary);
    font-weight: 600;
    background: var(--accent-bg);
    padding: 1rem;
    border-radius: 0.5rem;
    border: 1px solid var(--accent-border);
}

/* FAQ */
.faq-items {
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

.faq-item {
    background: var(--background);
    border: 1px solid var(--border);
    border-radius: 0.5rem;
    padding: 1.25rem;
    transition: all 0.3s ease;
}

.faq-item:hover {
    border-color: var(--primary-color);
    box-shadow: var(--shadow);
}

.faq-question {
    font-size: 1.125rem;
    font-weight: 600;
    margin-bottom: 0.75rem;
    color: var(--text-primary);
}

.faq-answer {
    color: var(--text-secondary);
    line-height: 1.6;
    font-size: 0.95rem;
}

/* Contact */
.contact-text {
    color: var(--text-secondary);
    margin-bottom: 1rem;
    line-height: 1.6;
}

.contact-link {
    color: var(--primary-color);
    text-decoration: underline;
    font-weight: 600;
    transition: color 0.3s ease;
}

.contact-link:hover {
    color: var(--primary-hover);
}

/* Footer */
.footer {
    background: var(--card-background);
    border-top: 1px solid var(--border);
    padding: 1.5rem 0;
    margin-top: 2rem;
}

.footer-content {
    text-align: center;
}

.footer-text {
    color: var(--text-secondary);
    margin-bottom: 1rem;
    font-size: 0.9rem;
}

.footer-brand {
    color: var(--primary-color);
    font-weight: 600;
}

.footer-badge {
    background-color: #dc2626;
    color: white;
    padding: 0.25rem 0.5rem;
    border-radius: 0.25rem;
    font-size: 0.75rem;
    margin-left: 0.5rem;
    font-weight: 500;
}

.footer-links {
    display: flex;
    justify-content: center;
    gap: 1.5rem;
}

.footer-link {
    color: var(--primary-color);
    text-decoration: underline;
    font-weight: 500;
    transition: color 0.3s ease;
}

.footer-link:hover {
    color: var(--primary-hover);
}

/* Responsive Design */
@media (max-width: 768px) {
    .nav {
        flex-direction: column;
        gap: 1rem;
        padding: 1rem 0;
    }

    .nav-links {
        gap: 1rem;
        flex-wrap: wrap;
        justify-content: center;
    }

    .hero-title {
        font-size: 2rem;
    }

    .hero-subtitle {
        font-size: 1rem;
    }

    .input-group {
        flex-direction: column;
        gap: 0.75rem;
        padding: 0.75rem;
    }

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

    .step {
        flex-direction: column;
        align-items: flex-start;
        gap: 0.75rem;
    }

    .footer-links {
        flex-direction: column;
        gap: 0.5rem;
    }

    .hero,
    .features,
    .about,
    .how-to-use,
    .faq,
    .contact {
        padding: 1.5rem 0;
    }
}

@media (max-width: 480px) {
    .container {
        padding: 0 0.75rem;
    }

    .content-card {
        padding: 1.5rem;
    }

    .hero {
        padding: 1.25rem 0;
    }

    .section-title {
        font-size: 1.5rem;
    }

    .nav-brand {
        font-size: 1.125rem;
    }
}

/* Smooth scrolling */
html {
    scroll-behavior: smooth;
}

/* Loading animation */
@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(30px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes pulse {
    0%, 100% {
        transform: scale(1);
    }
    50% {
        transform: scale(1.05);
    }
}

.content-card,
.feature-card {
    animation: fadeInUp 0.6s ease-out;
}

.download-btn:hover {
    animation: pulse 2s infinite;
}

/* Notification styles */
.notification {
    position: fixed;
    top: 20px;
    right: 20px;
    padding: 12px 20px;
    border-radius: 8px;
    color: white;
    font-weight: 500;
    z-index: 1000;
    max-width: 300px;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
    transform: translateX(100%);
    transition: transform 0.3s ease;
    backdrop-filter: blur(10px);
}

.notification.show {
    transform: translateX(0);
}

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

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

::-webkit-scrollbar-thumb {
    background: var(--primary-color);
    border-radius: 4px;
}

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

