@import url('https://fonts.googleapis.com/css2?family=Inter:wght@400;500;600;700&family=JetBrains+Mono:wght@400;500&display=swap');

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

:root {
    --bg: #0f0f13;
    --card: #1a1a2e;
    --card-hover: #222240;
    --border: #2a2a4a;
    --text: #e0e0e0;
    --text-muted: #8888aa;
    --accent-1: #25f4ee;
    --accent-2: #fe2c55;
    --gradient: linear-gradient(135deg, #25f4ee, #fe2c55);
    --gradient-soft: linear-gradient(135deg, rgba(37,244,238,0.1), rgba(254,44,85,0.1));
    --radius: 12px;
    --radius-sm: 8px;
}

body {
    font-family: 'Inter', sans-serif;
    background: var(--bg);
    color: var(--text);
    line-height: 1.6;
    min-height: 100vh;
}

.container {
    width: 100%;
    max-width: 900px;
    margin: 0 auto;
    padding: 0 16px;
}

/* Navbar */
.navbar {
    background: rgba(15, 15, 19, 0.9);
    backdrop-filter: blur(12px);
    border-bottom: 1px solid var(--border);
    position: sticky;
    top: 0;
    z-index: 100;
    padding: 14px 0;
}

.navbar .container {
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.logo {
    font-size: 1.25rem;
    font-weight: 700;
    background: var(--gradient);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    text-decoration: none;
}

.nav-links {
    display: flex;
    gap: 24px;
}

.nav-links a {
    color: var(--text-muted);
    text-decoration: none;
    font-size: 0.9rem;
    font-weight: 500;
    transition: color 0.2s;
}

.nav-links a:hover,
.nav-links a.active {
    color: var(--accent-1);
}

.menu-toggle {
    display: none;
    background: none;
    border: 1px solid var(--border);
    color: var(--text);
    font-size: 1.4rem;
    padding: 6px 10px;
    border-radius: var(--radius-sm);
    cursor: pointer;
}

/* Hero */
.hero {
    text-align: center;
    padding: 48px 0 24px;
}

.hero h1 {
    font-size: 2.2rem;
    font-weight: 700;
    background: var(--gradient);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    margin-bottom: 12px;
}

.subtitle {
    color: var(--text-muted);
    font-size: 1.1rem;
    max-width: 500px;
    margin: 0 auto;
}

/* Tool Card */
.tool-card {
    background: var(--card);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    padding: 32px;
    margin-bottom: 32px;
}

.input-group {
    display: flex;
    gap: 8px;
    margin-bottom: 20px;
}

.input-group input {
    flex: 1;
    background: var(--bg);
    border: 1px solid var(--border);
    color: var(--text);
    padding: 14px 16px;
    border-radius: var(--radius-sm);
    font-family: 'JetBrains Mono', monospace;
    font-size: 0.9rem;
    outline: none;
    transition: border-color 0.2s;
    min-height: 48px;
}

.input-group input:focus {
    border-color: var(--accent-1);
}

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

.btn-secondary {
    background: var(--bg);
    border: 1px solid var(--border);
    color: var(--text);
    padding: 14px 16px;
    border-radius: var(--radius-sm);
    cursor: pointer;
    font-size: 1.1rem;
    transition: border-color 0.2s, background 0.2s;
    min-height: 48px;
    min-width: 48px;
}

.btn-secondary:hover {
    border-color: var(--accent-1);
    background: var(--card);
}

/* Options */
.options-row {
    margin-bottom: 20px;
}

.option-group label:first-child {
    display: block;
    font-size: 0.85rem;
    color: var(--text-muted);
    margin-bottom: 8px;
    font-weight: 500;
}

.radio-group {
    display: flex;
    gap: 16px;
    flex-wrap: wrap;
}

.radio-label {
    display: flex;
    align-items: center;
    gap: 6px;
    cursor: pointer;
    font-size: 0.9rem;
    color: var(--text);
    padding: 8px 14px;
    background: var(--bg);
    border: 1px solid var(--border);
    border-radius: var(--radius-sm);
    transition: border-color 0.2s;
    min-height: 44px;
}

.radio-label:hover {
    border-color: var(--accent-1);
}

.radio-label input[type="radio"] {
    accent-color: var(--accent-1);
}

/* Buttons */
.btn-primary {
    width: 100%;
    padding: 16px;
    background: var(--gradient);
    border: none;
    border-radius: var(--radius-sm);
    color: #000;
    font-family: 'Inter', sans-serif;
    font-size: 1rem;
    font-weight: 600;
    cursor: pointer;
    transition: opacity 0.2s, transform 0.1s;
    min-height: 52px;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
}

.btn-primary:hover {
    opacity: 0.9;
}

.btn-primary:active {
    transform: scale(0.98);
}

.btn-primary:disabled {
    opacity: 0.5;
    cursor: not-allowed;
}

/* Spinner */
.spinner {
    width: 20px;
    height: 20px;
    border: 3px solid rgba(0,0,0,0.2);
    border-top-color: #000;
    border-radius: 50%;
    animation: spin 0.8s linear infinite;
}

@keyframes spin {
    to { transform: rotate(360deg); }
}

.hidden { display: none !important; }

/* Status */
.status {
    margin-top: 16px;
    padding: 12px 16px;
    border-radius: var(--radius-sm);
    font-size: 0.9rem;
    text-align: center;
}

.status.error {
    background: rgba(254, 44, 85, 0.15);
    border: 1px solid rgba(254, 44, 85, 0.3);
    color: #fe2c55;
}

.status.success {
    background: rgba(37, 244, 238, 0.1);
    border: 1px solid rgba(37, 244, 238, 0.3);
    color: var(--accent-1);
}

.status.loading {
    background: rgba(37, 244, 238, 0.05);
    border: 1px solid var(--border);
    color: var(--text-muted);
}

/* Result */
.result {
    margin-top: 20px;
    padding: 20px;
    background: var(--bg);
    border: 1px solid var(--border);
    border-radius: var(--radius-sm);
}

.result-preview {
    margin-bottom: 16px;
}

.result-info h3 {
    font-size: 1rem;
    color: var(--accent-1);
    margin-bottom: 4px;
}

.result-info p {
    font-size: 0.85rem;
    color: var(--text-muted);
}

.btn-download {
    display: block;
    width: 100%;
    padding: 14px;
    background: var(--gradient);
    border: none;
    border-radius: var(--radius-sm);
    color: #000;
    font-family: 'Inter', sans-serif;
    font-size: 1rem;
    font-weight: 600;
    text-align: center;
    text-decoration: none;
    cursor: pointer;
    min-height: 48px;
    line-height: 1;
    display: flex;
    align-items: center;
    justify-content: center;
}

.btn-download:hover {
    opacity: 0.9;
}

/* Features */
.features {
    margin-bottom: 48px;
}

.features h2,
.how-to h2,
.faq h2 {
    text-align: center;
    font-size: 1.6rem;
    margin-bottom: 32px;
    background: var(--gradient);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.features-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 20px;
}

.feature-card {
    background: var(--card);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    padding: 24px;
    text-align: center;
    transition: border-color 0.2s, transform 0.2s;
}

.feature-card:hover {
    border-color: var(--accent-1);
    transform: translateY(-2px);
}

.feature-icon {
    font-size: 2rem;
    margin-bottom: 12px;
}

.feature-card h3 {
    font-size: 1rem;
    margin-bottom: 8px;
    color: var(--text);
}

.feature-card p {
    font-size: 0.85rem;
    color: var(--text-muted);
    line-height: 1.5;
}

/* How To */
.how-to {
    margin-bottom: 48px;
}

.steps {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 24px;
}

.step {
    text-align: center;
    padding: 24px;
}

.step-number {
    width: 48px;
    height: 48px;
    background: var(--gradient);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.2rem;
    font-weight: 700;
    color: #000;
    margin: 0 auto 16px;
}

.step h3 {
    font-size: 1rem;
    margin-bottom: 8px;
}

.step p {
    font-size: 0.85rem;
    color: var(--text-muted);
}

/* FAQ */
.faq {
    margin-bottom: 48px;
}

.faq-list {
    max-width: 700px;
    margin: 0 auto;
}

.faq-item {
    background: var(--card);
    border: 1px solid var(--border);
    border-radius: var(--radius-sm);
    margin-bottom: 12px;
    overflow: hidden;
}

.faq-item summary {
    padding: 16px 20px;
    cursor: pointer;
    font-weight: 500;
    font-size: 0.95rem;
    list-style: none;
    display: flex;
    justify-content: space-between;
    align-items: center;
    min-height: 48px;
}

.faq-item summary::-webkit-details-marker { display: none; }

.faq-item summary::after {
    content: '+';
    font-size: 1.2rem;
    color: var(--accent-1);
    transition: transform 0.2s;
}

.faq-item[open] summary::after {
    content: '−';
}

.faq-item p {
    padding: 0 20px 16px;
    font-size: 0.9rem;
    color: var(--text-muted);
    line-height: 1.6;
}

/* Ad Slots */
.ad-slot {
    background: var(--card);
    border: 1px solid var(--border);
    border-radius: var(--radius-sm);
    min-height: 90px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--text-muted);
    font-size: 0.8rem;
    margin: 24px 0;
}

/* Footer */
.footer {
    background: var(--card);
    border-top: 1px solid var(--border);
    padding: 40px 0 24px;
    margin-top: 48px;
}

.footer-content {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    margin-bottom: 24px;
}

.footer-brand p {
    color: var(--text-muted);
    font-size: 0.85rem;
    margin-top: 8px;
    max-width: 300px;
}

.footer-links {
    display: flex;
    gap: 20px;
}

.footer-links a {
    color: var(--text-muted);
    text-decoration: none;
    font-size: 0.9rem;
    transition: color 0.2s;
}

.footer-links a:hover {
    color: var(--accent-1);
}

.footer-copy {
    color: var(--text-muted);
    font-size: 0.8rem;
    text-align: center;
    padding-top: 20px;
    border-top: 1px solid var(--border);
}

/* Preview Card */
.preview-card {
    background: var(--bg);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    padding: 16px;
    margin-bottom: 20px;
    display: flex;
    gap: 16px;
    align-items: center;
    animation: fadeIn 0.3s ease;
}

@keyframes fadeIn {
    from { opacity: 0; transform: translateY(-8px); }
    to { opacity: 1; transform: translateY(0); }
}

.preview-thumb {
    width: 120px;
    height: auto;
    border-radius: var(--radius-sm);
    object-fit: cover;
    flex-shrink: 0;
}

.preview-info {
    flex: 1;
    min-width: 0;
}

.preview-title {
    font-weight: 600;
    font-size: 0.95rem;
    color: var(--text);
    margin-bottom: 6px;
    display: -webkit-box;
    -webkit-line-clamp: 3;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.preview-author {
    color: var(--text-muted);
    font-size: 0.85rem;
}

.preview-loading {
    text-align: center;
    padding: 16px;
    color: var(--text-muted);
    font-size: 0.85rem;
}

/* ===== RESPONSIVE ===== */

/* Tablet */
@media (max-width: 768px) {
    .nav-links { display: none; }
    .nav-links.open {
        display: flex;
        flex-direction: column;
        position: absolute;
        top: 100%;
        left: 0;
        right: 0;
        background: var(--bg);
        border-bottom: 1px solid var(--border);
        padding: 16px;
        gap: 12px;
    }
    .menu-toggle { display: block; }

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

    .tool-card { padding: 24px; }

    .features-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 16px;
    }

    .steps {
        grid-template-columns: 1fr;
        gap: 16px;
    }

    .footer-content {
        flex-direction: column;
        gap: 20px;
    }

    .footer-links {
        flex-wrap: wrap;
    }
}

/* Mobile */
@media (max-width: 480px) {
    .preview-card {
        flex-direction: column;
        text-align: center;
    }

    .preview-thumb {
        width: 100%;
        max-width: 200px;
    }

    .container { padding: 0 12px; }

    .hero { padding: 32px 0 16px; }
    .hero h1 { font-size: 1.5rem; }
    .subtitle { font-size: 0.9rem; }

    .tool-card { padding: 16px; }

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

    .input-group input {
        width: 100%;
    }

    .btn-secondary {
        width: 100%;
    }

    .radio-group {
        flex-direction: column;
        gap: 8px;
    }

    .radio-label {
        width: 100%;
        justify-content: center;
    }

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

    .features h2,
    .how-to h2,
    .faq h2 {
        font-size: 1.3rem;
    }

    .feature-card { padding: 20px; }

    .faq-item summary {
        font-size: 0.88rem;
        padding: 14px 16px;
    }

    .faq-item p {
        padding: 0 16px 14px;
        font-size: 0.85rem;
    }

    .footer { padding: 28px 0 16px; }
}

/* Large screens */
@media (min-width: 1024px) {
    .container { max-width: 960px; }
}
