* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

:root {
    --bg-primary: #0a0a0f;
    --bg-secondary: #12121a;
    --bg-card: rgba(255, 255, 255, 0.03);
    --text-primary: #ffffff;
    --text-secondary: #a0a0b0;
    --accent-cyan: #25F4EE;
    --accent-pink: #FE2C55;
    --accent-gradient: linear-gradient(135deg, #25F4EE 0%, #FE2C55 100%);
    --glass-bg: rgba(255, 255, 255, 0.05);
    --glass-border: rgba(255, 255, 255, 0.1);
    --shadow-glow: 0 0 60px rgba(37, 244, 238, 0.15);
}

html {
    scroll-behavior: smooth;
}

body {
    font-family: 'Outfit', -apple-system, BlinkMacSystemFont, sans-serif;
    background: var(--bg-primary);
    color: var(--text-primary);
    min-height: 100vh;
    overflow-x: hidden;
    position: relative;
    line-height: 1.5;
    letter-spacing: -0.01em;
}

/* Background Effects */
.background-effects {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    pointer-events: none;
    z-index: 0;
    overflow: hidden;
}

.gradient-orb {
    position: absolute;
    border-radius: 50%;
    filter: blur(80px);
    opacity: 0.4;
    animation: float 20s ease-in-out infinite;
}

.orb-1 {
    width: 600px;
    height: 600px;
    background: var(--accent-cyan);
    top: -200px;
    left: -200px;
    animation-delay: 0s;
}

.orb-2 {
    width: 500px;
    height: 500px;
    background: var(--accent-pink);
    top: 50%;
    right: -150px;
    animation-delay: -7s;
}

.orb-3 {
    width: 400px;
    height: 400px;
    background: linear-gradient(135deg, var(--accent-cyan), var(--accent-pink));
    bottom: -100px;
    left: 30%;
    animation-delay: -14s;
}

@keyframes float {

    0%,
    100% {
        transform: translate(0, 0) rotate(0deg);
    }

    25% {
        transform: translate(30px, -30px) rotate(5deg);
    }

    50% {
        transform: translate(-20px, 20px) rotate(-5deg);
    }

    75% {
        transform: translate(20px, 10px) rotate(3deg);
    }
}

/* Container */
.container {
    max-width: 800px;
    margin: 0 auto;
    padding: 60px 20px;
    position: relative;
    z-index: 1;
}

/* Hero Section */
.hero {
    text-align: center;
    margin-bottom: 50px;
}

.logo {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 16px;
    margin-bottom: 16px;
}

.tiktok-icon {
    width: 48px;
    height: 48px;
    animation: pulse 2s ease-in-out infinite;
}

@keyframes pulse {

    0%,
    100% {
        transform: scale(1);
    }

    50% {
        transform: scale(1.05);
    }
}

.logo h1 {
    font-size: 2.5rem;
    font-weight: 800;
    background: var(--accent-gradient);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.tagline {
    font-size: 1.1rem;
    color: var(--text-secondary);
    font-weight: 400;
}

/* Download Section */
.download-section {
    margin-bottom: 40px;
}

.input-wrapper {
    background: var(--glass-bg);
    border: 1px solid var(--glass-border);
    border-radius: 20px;
    padding: 8px;
    backdrop-filter: blur(20px);
    box-shadow: var(--shadow-glow);
    transition: all 0.3s ease;
}

.input-wrapper:focus-within {
    border-color: var(--accent-cyan);
    box-shadow: 0 0 40px rgba(37, 244, 238, 0.2);
}

.input-container {
    display: flex;
    align-items: center;
    gap: 12px;
    background: var(--bg-secondary);
    border-radius: 14px;
    padding: 8px 12px 8px 20px;
}

.link-icon {
    width: 24px;
    height: 24px;
    color: var(--text-secondary);
    flex-shrink: 0;
}

#videoUrl {
    flex: 1;
    background: transparent;
    border: none;
    color: var(--text-primary);
    font-size: 1rem;
    padding: 12px 0;
    outline: none;
}

#videoUrl::placeholder {
    color: var(--text-secondary);
}

.fetch-btn {
    background: var(--accent-gradient);
    border: none;
    border-radius: 12px;
    color: white;
    font-size: 1rem;
    font-weight: 600;
    padding: 14px 28px;
    cursor: pointer;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    gap: 8px;
    white-space: nowrap;
}

.fetch-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 10px 30px rgba(254, 44, 85, 0.3);
}

.fetch-btn:active {
    transform: translateY(0);
}

.fetch-btn:disabled {
    opacity: 0.7;
    cursor: not-allowed;
    transform: none;
}

.spinner {
    width: 20px;
    height: 20px;
    border: 2px solid rgba(255, 255, 255, 0.3);
    border-top-color: white;
    border-radius: 50%;
    animation: spin 0.8s linear infinite;
}

@keyframes spin {
    to {
        transform: rotate(360deg);
    }
}

.hint {
    text-align: center;
    color: var(--text-secondary);
    font-size: 0.875rem;
    margin-top: 16px;
}

/* Result Section */
.result-section {
    animation: slideUp 0.5s ease;
}

@keyframes slideUp {
    from {
        opacity: 0;
        transform: translateY(20px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.video-card {
    background: var(--glass-bg);
    border: 1px solid var(--glass-border);
    border-radius: 24px;
    padding: 24px;
    backdrop-filter: blur(20px);
    display: flex;
    gap: 24px;
}

.video-preview {
    position: relative;
    width: 200px;
    flex-shrink: 0;
}

.video-preview img {
    width: 100%;
    height: 280px;
    object-fit: cover;
    border-radius: 16px;
}

.duration-badge {
    position: absolute;
    bottom: 12px;
    right: 12px;
    background: rgba(0, 0, 0, 0.7);
    color: white;
    padding: 4px 10px;
    border-radius: 8px;
    font-size: 0.875rem;
    font-weight: 500;
}

.video-info {
    flex: 1;
    display: flex;
    flex-direction: column;
    gap: 16px;
}

.author-info {
    display: flex;
    align-items: center;
    gap: 12px;
}

.author-avatar {
    width: 44px;
    height: 44px;
    border-radius: 50%;
    object-fit: cover;
    border: 2px solid var(--glass-border);
}

.author-name {
    font-weight: 600;
    color: var(--text-primary);
}

.video-title {
    font-size: 1rem;
    font-weight: 400;
    color: var(--text-secondary);
    line-height: 1.5;
    display: -webkit-box;
    -webkit-line-clamp: 3;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.download-options {
    display: flex;
    flex-direction: column;
    gap: 12px;
    margin-top: auto;
}

.download-btn {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    padding: 14px 24px;
    border-radius: 12px;
    font-size: 1rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    border: none;
}

.download-btn svg {
    width: 20px;
    height: 20px;
}

.video-btn {
    background: var(--accent-gradient);
    color: white;
}

.video-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 10px 30px rgba(254, 44, 85, 0.3);
}

.audio-btn {
    background: transparent;
    border: 2px solid var(--accent-cyan) !important;
    color: var(--accent-cyan);
}

.audio-btn:hover {
    background: rgba(37, 244, 238, 0.1);
    transform: translateY(-2px);
}

/* Error Section */
.error-section {
    animation: slideUp 0.5s ease;
}

.error-card {
    background: rgba(254, 44, 85, 0.1);
    border: 1px solid rgba(254, 44, 85, 0.3);
    border-radius: 16px;
    padding: 24px;
    display: flex;
    align-items: center;
    gap: 16px;
}

.error-icon {
    width: 32px;
    height: 32px;
    color: var(--accent-pink);
    flex-shrink: 0;
}

.error-card p {
    color: var(--accent-pink);
    font-weight: 500;
}

/* Features Section */
.features {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 20px;
    margin-top: 60px;
}

.feature-card {
    background: var(--glass-bg);
    border: 1px solid var(--glass-border);
    border-radius: 20px;
    padding: 28px;
    text-align: center;
    backdrop-filter: blur(10px);
    transition: all 0.3s ease;
}

.feature-card:hover {
    transform: translateY(-5px);
    border-color: var(--accent-cyan);
}

.feature-icon {
    width: 56px;
    height: 56px;
    background: var(--accent-gradient);
    border-radius: 16px;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 16px;
}

.feature-icon svg {
    width: 28px;
    height: 28px;
    color: white;
}

.feature-card h3 {
    font-size: 1.1rem;
    font-weight: 600;
    margin-bottom: 8px;
}

.feature-card p {
    font-size: 0.9rem;
    color: var(--text-secondary);
    line-height: 1.5;
}

/* Footer */
.footer {
    text-align: center;
    padding: 40px 20px;
    color: var(--text-secondary);
    font-size: 0.9rem;
    position: relative;
    z-index: 1;
}

/* Responsive */
@media (max-width: 768px) {
    .container {
        padding: 40px 16px;
    }

    .logo h1 {
        font-size: 1.8rem;
    }

    .video-card {
        flex-direction: column;
    }

    .video-preview {
        width: 100%;
    }

    .video-preview img {
        height: 300px;
    }

    .features {
        grid-template-columns: 1fr;
    }

    .fetch-btn {
        padding: 14px 20px;
    }

    .input-container {
        flex-wrap: wrap;
    }

    #videoUrl {
        width: 100%;
    }
}

/* Legal Pages */
.legal-content {
    background: var(--glass-bg);
    border: 1px solid var(--glass-border);
    border-radius: 24px;
    padding: 40px;
    backdrop-filter: blur(20px);
    margin-bottom: 40px;
}

.legal-content h2 {
    font-size: 2rem;
    margin-bottom: 20px;
    background: var(--accent-gradient);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.legal-content h3 {
    font-size: 1.3rem;
    margin: 25px 0 12px;
    color: var(--text-primary);
}

.legal-content p {
    color: var(--text-secondary);
    line-height: 1.7;
    margin-bottom: 12px;
}

.legal-content ul,
.legal-content ol {
    color: var(--text-secondary);
    margin-left: 24px;
    margin-bottom: 16px;
    line-height: 1.8;
}

.legal-content li {
    margin-bottom: 8px;
}

.legal-content strong {
    color: var(--text-primary);
}

/* Header Navigation */
header nav {
    margin-top: 15px;
    color: var(--text-secondary);
}

header nav a {
    color: var(--accent-cyan);
    text-decoration: none;
    transition: color 0.3s ease;
}

header nav a:hover {
    color: var(--accent-pink);
}

/* Footer Navigation */
.footer-nav {
    margin: 15px 0;
}

.footer-nav a {
    color: var(--accent-cyan);
    text-decoration: none;
    transition: color 0.3s ease;
}

.footer-nav a:hover {
    color: var(--accent-pink);
}

.disclaimer {
    font-size: 0.8rem;
    color: var(--text-secondary);
    opacity: 0.7;
    margin-top: 10px;
}

/* Static page footer */
/* SEO Content Section */
.seo-content {
    margin-top: 80px;
    display: flex;
    flex-direction: column;
    gap: 40px;
}

.info-block,
.faq-block {
    background: var(--glass-bg);
    border: 1px solid var(--glass-border);
    border-radius: 24px;
    padding: 32px;
    backdrop-filter: blur(10px);
}

.info-block h2,
.faq-block h2 {
    font-size: 1.8rem;
    margin-bottom: 24px;
    background: var(--accent-gradient);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.info-block p {
    color: var(--text-secondary);
    line-height: 1.6;
    margin-bottom: 16px;
}

.info-block ul {
    list-style: none;
    margin-top: 16px;
}

.info-block ul li {
    color: var(--text-secondary);
    margin-bottom: 12px;
    padding-left: 24px;
    position: relative;
    line-height: 1.6;
}

.info-block ul li:before {
    content: "•";
    color: var(--accent-cyan);
    position: absolute;
    left: 0;
    font-weight: bold;
}

.info-block strong {
    color: var(--text-primary);
}

/* Steps Styling */
.steps-container {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 24px;
    margin-top: 24px;
}

.step-item {
    background: rgba(255, 255, 255, 0.03);
    border-radius: 16px;
    padding: 20px;
    transition: transform 0.3s ease;
}

.step-item:hover {
    transform: translateY(-5px);
    background: rgba(255, 255, 255, 0.05);
}

.step-number {
    width: 32px;
    height: 32px;
    background: var(--accent-gradient);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: bold;
    color: white;
    margin-bottom: 16px;
}

.step-text h3 {
    font-size: 1.1rem;
    margin-bottom: 8px;
    color: var(--text-primary);
}

.step-text p {
    font-size: 0.9rem;
    margin-bottom: 0;
}

/* FAQ Styling */
.faq-item {
    margin-bottom: 24px;
    border-bottom: 1px solid var(--glass-border);
    padding-bottom: 24px;
}

.faq-item:last-child {
    border-bottom: none;
    margin-bottom: 0;
    padding-bottom: 0;
}

.faq-item h3 {
    font-size: 1.2rem;
    color: var(--text-primary);
    margin-bottom: 12px;
}

.faq-item p {
    color: var(--text-secondary);
    line-height: 1.6;
}

@media (max-width: 768px) {
    .steps-container {
        grid-template-columns: 1fr;
    }
}

/* Static page footer */
footer {
    text-align: center;
    padding: 30px 20px;
    color: var(--text-secondary);
    font-size: 0.9rem;
    border-top: 1px solid var(--glass-border);
    margin-top: 40px;
}

footer p {
    margin: 5px 0;
}