:root {
    --bg-color: #f8f9fa;
    /* Light body bg for non-hero parts if needed, or keeping it dark? User said "blue is black". I'll make the hero black and body white/light like SnapTik or fully dark. "Blue is black" implies hero is black. */
    --hero-bg: #3e87ec;
    --text-main: #333;
    --primary-btn: #ad0000;
    /* Red paste? or Blue. SnapTik uses Blue Paste, Green Download */
    --accent-btn: #3e87ec;
    /* Blue */
    --green-btn: #00a000;
}

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

body {
    font-family: 'Roboto', sans-serif;
    background-color: #fff;
    color: #333;
    overflow-x: hidden;
}

/* Navbar */
header {
    background: #fff;
    padding: 15px 5%;
    display: flex;
    justify-content: space-between;
    align-items: center;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.05);
    position: relative;
    z-index: 100;
}

.logo {
    font-size: 1.8rem;
    font-weight: 700;
    color: #000;
    text-decoration: none;
    font-family: 'Outfit', sans-serif;
}

.highlight {
    color: var(--accent-btn);
}

.nav-right a {
    text-decoration: none;
    color: #333;
    margin-left: 20px;
    font-weight: 500;
    font-size: 1rem;
}

.nav-right a:hover {
    color: var(--accent-btn);
}

/* Mobile Menu */
.menu-toggle {
    display: none;
    flex-direction: column;
    cursor: pointer;
}

.bar {
    width: 25px;
    height: 3px;
    background-color: #333;
    margin: 4px 0;
    transition: 0.4s;
    border-radius: 2px;
}

/* Mobile Only Utility */
.mobile-only {
    display: none;
}

@media (max-width: 768px) {
    .mobile-only {
        display: block;
        margin-top: 0;
        /* Let gap handle spacing */
    }

}

/* Hero Section */
.hero-section {
    position: relative;
    width: 100%;
    min-height: 65vh;
    /* Reduced from 550px to 50vh */
    background: var(--hero-bg);
    display: flex;
    justify-content: center;
    align-items: center;
    flex-direction: column;
    padding: 40px 20px;
    /* Added padding for better spacing */
    overflow: hidden;
}

#particle-canvas {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 1;
    pointer-events: none;
}

.hero-content {
    position: relative;
    z-index: 2;
    text-align: center;
    width: 100%;
    max-width: 800px;
    color: #fff;
}

.hero-content h1 {
    font-size: 3rem;
    font-weight: 700;
    margin-bottom: 10px;
    font-family: 'Outfit', sans-serif;
}

.hero-content .subtitle {
    font-size: 1.2rem;
    opacity: 0.8;
    margin-bottom: 30px;
}

/* Input Area */
.input-area {
    display: flex;
    gap: 15px;
    width: 100%;
    max-width: 800px;
    margin: 0 auto;
}

.input-group {
    background: #fff;
    border-radius: 30px;
    /* Rounded pill look */
    display: flex;
    align-items: center;
    flex: 1;
    padding: 5px 15px;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.2);
    position: relative;
    border: 1px solid transparent;
    transition: border-color 0.3s;
}

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

.input-group input {
    border: none;
    font-size: 1rem;
    padding: 15px;
    flex: 1;
    outline: none;
    background: transparent;
    color: #333;
}

.paste-btn {
    background: transparent;
    /* Clear background to blend in input */
    color: var(--accent-btn);
    border: none;
    font-weight: 600;
    cursor: pointer;
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 8px 15px;
    border-left: 1px solid #eee;
    /* Separator */
    margin-left: 5px;
    border-radius: 0;
    font-size: 0.95rem;
}

.paste-btn:hover {
    background: transparent;
    color: #2b6cb0;
}

.download-btn-main {
    background: var(--green-btn);
    color: #fff;
    border: none;
    border-radius: 30px;
    padding: 0 40px;
    font-size: 1.1rem;
    font-weight: 700;
    cursor: pointer;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.3);
    transition: transform 0.2s, opacity 0.2s;
    display: flex;
    align-items: center;
    gap: 10px;
}

.download-btn-main:hover {
    transform: translateY(-2px);
    opacity: 0.95;
}

.download-btn-main:active {
    transform: translateY(0);
}


/* Loading & Results */
.loading {
    margin-top: 20px;
    display: flex;
    flex-direction: column;
    align-items: center;
    color: #fff;
}

.spinner {
    border: 4px solid rgba(255, 255, 255, 0.3);
    border-top: 4px solid #fff;
    border-radius: 50%;
    width: 30px;
    height: 30px;
    animation: spin 1s linear infinite;
    margin-bottom: 10px;
}

@keyframes spin {
    0% {
        transform: rotate(0deg);
    }

    100% {
        transform: rotate(360deg);
    }
}

.error-msg {
    background: #ffecb3;
    color: #e65100;
    padding: 10px;
    border-radius: 5px;
    margin-top: 20px;
}

/* Result Container Placement */
.result-container {
    padding: 0 20px;
    max-width: 800px;
    margin: 40px auto 0;
    /* Top margin to separate from hero */
    position: relative;
    z-index: 10;
}

.result-card {
    background: #fff;
    color: #333;
    border-radius: 16px;
    /* Slightly larger radius */
    padding: 40px;
    /* Increased padding from 24px */
    display: flex;
    justify-content: space-between;
    align-items: center;
    text-align: left;
    box-shadow: 0 15px 40px rgba(0, 0, 0, 0.12);
    /* Stronger shadow */
    border: 1px solid #efefef;
    display: none;
    /* Hidden by default */
    min-height: 500px;
    /* Ensure it has some bulk */
}

/* Secondary Button (Download Another) */
.download-btn.secondary {
    background: #6c757d;
    /* Keep grey */
    opacity: 0.8;
}

.download-btn.secondary:hover {
    opacity: 1;
}

.result-thumb-wrapper img {
    width: 120px;
    height: 120px;
    object-fit: cover;
    border-radius: 8px;
    margin-right: 20px;
}

.result-info {
    flex: 1;
}

.result-info h3 {
    font-size: 1.1rem;
    margin-bottom: 5px;
}

.result-info p {
    font-size: 0.9rem;
    color: #666;
    margin-bottom: 15px;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.action-buttons {
    display: flex;
    gap: 10px;
    flex-wrap: wrap;
}

.download-btn {
    background: var(--accent-btn);
    color: #fff;
    padding: 10px 15px;
    text-decoration: none;
    border-radius: 4px;
    font-size: 0.9rem;
    border: none;
    cursor: pointer;
}

.download-btn.secondary {
    background: #6c757d;
}

.reset-btn {
    background: transparent;
    color: #999;
    border: 1px solid #ddd;
}

/* Content Sections (SEO) */
.content-section {
    max-width: 900px;
    margin: 60px auto;
    color: #333;
    line-height: 1.7;
}

.content-section h2 {
    color: #000;
    font-size: 2rem;
    margin: 50px 0 25px;
    font-weight: 700;
    text-align: center;
}

.content-section p {
    margin-bottom: 20px;
    color: #555;
    font-size: 1.05rem;
}

/* Step-by-Step Guide */
.content-section ol {
    counter-reset: step-counter;
    list-style: none;
    margin: 30px 0;
    padding: 0;
}

.content-section ol li {
    position: relative;
    padding-left: 50px;
    margin-bottom: 25px;
}

.content-section ol li::before {
    counter-increment: step-counter;
    content: counter(step-counter);
    position: absolute;
    left: 0;
    top: -2px;
    width: 35px;
    height: 35px;
    background: var(--accent-btn);
    color: #fff;
    border-radius: 50%;
    text-align: center;
    line-height: 35px;
    font-weight: bold;
    font-size: 1rem;
}

.content-section ol li strong {
    display: block;
    color: #000;
    font-size: 1.1rem;
    margin-bottom: 5px;
}

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

.feature-item {
    background: #fff;
    padding: 30px;
    border-radius: 12px;
    border: 1px solid #e1e1e1;
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.02);
    transition: transform 0.2s, box-shadow 0.2s;
}

.feature-item:hover {
    transform: translateY(-5px);
    box-shadow: 0 10px 20px rgba(0, 0, 0, 0.08);
}

.feature-item h3 {
    color: #000;
    font-size: 1.25rem;
    margin-bottom: 12px;
    font-weight: 600;
}

.feature-item p {
    color: #666;
    font-size: 0.95rem;
    margin-bottom: 0;
    line-height: 1.6;
}

/* FAQ Styling */
.content-section h3 {
    color: #000;
    font-size: 1.3rem;
    margin: 35px 0 15px;
    font-weight: 600;
}

.content-section h3+p {
    margin-bottom: 20px;
}

/* Content Sections (SEO) */
.container {
    max-width: 1000px;
    margin: 40px auto;
    padding: 0 20px;
}

/* Footer */
footer {
    background: #fff;
    border-top: 1px solid #eee;
    padding: 40px 20px;
    margin-top: 50px;
}

.footer-content {
    max-width: 1200px;
    margin: 0 auto;
    display: flex;
    justify-content: space-between;
    flex-wrap: wrap;
    gap: 30px;
}

.footer-col h3 {
    font-size: 1.2rem;
    margin-bottom: 15px;
    color: #000;
}

.footer-col ul {
    list-style: none;
}

.footer-col ul li {
    margin-bottom: 8px;
}

.footer-col a {
    text-decoration: none;
    color: #666;
    font-size: 0.95rem;
}

.footer-col a:hover {
    text-decoration: underline;
}

.copyright {
    text-align: center;
    color: #999;
    font-size: 0.85rem;
    margin-top: 40px;
}

/* Scroll Top */
#scrollTopBtn {
    position: fixed;
    bottom: 30px;
    right: 30px;
    background: var(--accent-btn);
    color: white;
    width: 45px;
    height: 45px;
    border-radius: 5px;
    border: none;
    cursor: pointer;
    display: none;
    align-items: center;
    justify-content: center;
    box-shadow: 0 4px 10px rgba(0, 0, 0, 0.2);
    z-index: 99;
}

#scrollTopBtn.show {
    display: flex;
}

/* Responsive */
@media (max-width: 768px) {
    .hero-content h1 {
        font-size: 2.2rem;
    }

    .hero-content h1 {
        font-size: 2.2rem;
    }

    .input-area {
        flex-direction: column;
        gap: 15px;
    }

    .input-group {
        width: 100%;
        border-radius: 8px;
    }

    .download-btn-main {
        width: 100%;
        justify-content: center;
        padding: 15px;
        border-radius: 8px;
    }

    .result-card {
        flex-direction: column;
        text-align: center;
    }

    .result-thumb-wrapper img {
        margin: 0 0 15px 0;
    }

    .action-buttons {
        justify-content: center;
    }

    /* Mobile Nav */
    .menu-toggle {
        display: flex;
        z-index: 1001;
        /* Ensure toggle is above nav */
    }

    .nav-right {
        position: fixed;
        top: 0;
        right: -100%;
        width: 100%;
        height: 100vh;
        background: #fff;
        display: flex;
        /* Required for flex-direction to work */
        flex-direction: column;
        /* Vertical */
        align-items: center;
        /* Center horizontally */
        justify-content: center;
        /* Center vertically */
        padding-top: 0;
        transition: 0.3s cubic-bezier(0.4, 0, 0.2, 1);
        box-shadow: -5px 0 15px rgba(0, 0, 0, 0.1);
        z-index: 1000;
        gap: 40px;
        /* Space between links */
    }

    .nav-right.active {
        right: 0;
    }

    .nav-right a {
        font-family: 'Outfit', sans-serif;
        /* Premium font */
        font-size: 1.8rem;
        /* Larger and clearer */
        margin: 0;
        color: #333;
        font-weight: 600;
        transition: color 0.3s ease;
        padding: 5px 0;
    }

    .nav-right a:hover {
        color: var(--accent-btn);
        /* Blue hover */
    }

    /* Change class for hamburger animation */
    .menu-toggle.change .bar:nth-child(1) {
        transform: rotate(-45deg) translate(-5px, 6px);
        background-color: var(--accent-btn);
    }

    .menu-toggle.change .bar:nth-child(2) {
        opacity: 0;
    }

    .menu-toggle.change .bar:nth-child(3) {
        transform: rotate(45deg) translate(-5px, -6px);
        background-color: var(--accent-btn);
    }

    .footer-content {
        flex-direction: column;
    }
}

/* Nav Logo */
.nav-logo {
    width: 32px;
    height: 32px;
    vertical-align: middle;
    margin-right: 10px;
    border-radius: 5px;
}

/* Footer App Button */
/* Footer App Button */
.footer-app-btn {
    display: inline-flex;
    align-items: center;
    background: var(--accent-btn);
    /* Blue */
    color: #fff !important;
    padding: 12px 25px;
    border-radius: 30px;
    text-decoration: none;
    font-weight: 600;
    margin-top: 20px;
    border: none;
    transition: all 0.3s;
    font-size: 1rem;
    box-shadow: 0 4px 15px rgba(37, 244, 238, 0.3);
}

.footer-app-btn:hover {
    transform: translateY(-2px);
    opacity: 0.95;
    box-shadow: 0 6px 20px rgba(37, 244, 238, 0.4);
}

/* Result Page Styles */
.download-page {
    background: #f8f9fa;
    min-height: 80vh;
    padding: 60px 20px;
    display: flex;
    justify-content: center;
    align-items: center;
}

.result-container-full {
    width: 100%;
    max-width: 900px;
}

.full-page-card {
    display: flex;
    /* Flex row by default */
    background: #fff;
    border-radius: 20px;
    overflow: hidden;
    box-shadow: 0 20px 50px rgba(0, 0, 0, 0.1);
    min-height: 500px;
    /* As requested */
}

.result-thumb-wrapper {
    flex: 1;
    position: relative;
    min-height: 500px;
    /* Match card height */
}

.result-thumb-wrapper img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    border-radius: 0;
    /* Flush with card */
    margin: 0;
}

.result-info {
    flex: 0.8;
    padding: 40px;
    display: flex;
    flex-direction: column;
    justify-content: center;
}

.author-info {
    display: flex;
    align-items: center;
    gap: 15px;
    margin-bottom: 20px;
}

.avatar-small {
    width: 50px;
    height: 50px;
    border-radius: 50%;
    object-fit: cover;
    background: #eee;
}

.result-info h3 {
    font-size: 1.5rem;
    color: #000;
    margin: 0;
}

.result-info p {
    font-size: 1.1rem;
    color: #555;
    margin-bottom: 30px;
    display: -webkit-box;
    -webkit-line-clamp: 4;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.action-buttons.vertical {
    display: flex;
    flex-direction: column;
    gap: 15px;
}

.download-btn.large {
    font-size: 1.2rem;
    padding: 18px;
    text-align: center;
    justify-content: center;
}

/* TikTok Loader */
.tiktok-loader {
    width: 40px;
    height: 20px;
    position: relative;
    margin: 0 10px;
}

.tiktok-loader::before,
.tiktok-loader::after {
    content: "";
    position: absolute;
    width: 20px;
    height: 20px;
    border-radius: 50%;
    background-color: #FE2C55;
    /* TikTok Red */
    animation: tiktok-move 0.8s infinite ease-in-out alternate;
}

.tiktok-loader::after {
    background-color: #25F4EE;
    /* TikTok Cyan */
    animation-delay: 0.4s;
    left: 20px;
}

@keyframes tiktok-move {
    0% {
        transform: scale(1);
    }

    100% {
        transform: scale(0.6);
    }
}

@media (max-width: 768px) {
    .full-page-card {
        flex-direction: column;
        min-height: auto;
    }

    .result-thumb-wrapper {
        height: 300px;
        min-height: auto;
    }

    .download-btn.large,
    .download-btn.secondary.large {
        width: 100%;
        padding: 12px 5px;
        /* Thinner vertically */
        font-size: 0.95rem;
        /* Ensure text fits */
        white-space: nowrap;
        /* Force single line */
        display: flex;
        justify-content: center;
        align-items: center;
    }
}

/* Blog Styles */
/* Blog Styles */
.article-card {
    background: #fff;
    border-radius: 16px;
    margin-bottom: 20px;
    border: 1px solid #eee;
    transition: transform 0.2s;
    overflow: hidden;
    display: flex;
    align-items: center;
    box-shadow: 0 4px 10px rgba(0, 0, 0, 0.05);
}

.article-card:hover {
    transform: translateY(-3px);
    border-color: var(--accent-btn);
}

.thumb {
    width: 220px;
    height: 160px;
    object-fit: cover;
    flex-shrink: 0;
}

.card-content {
    padding: 30px;
}

.article-card h2 {
    margin-top: 0;
    color: #000;
    font-size: 1.5rem;
}

.article-card p {
    color: #555;
    line-height: 1.6;
}

.read-more {
    display: inline-block;
    margin-top: 15px;
    color: var(--accent-btn);
    text-decoration: none;
    font-weight: 600;
}

@media (max-width: 600px) {
    .article-card {
        flex-direction: column;
    }

    .thumb {
        width: 100%;
        height: 200px;
    }

    .card-content {
        padding: 20px;
    }
}

/* Contact Styles */
.contact-box {
    background: #fff;
    padding: 40px;
    border-radius: 20px;
    border: 1px solid #1c1c1c;
    /* Kept slight contrast border or removing? User wants light. Let's use simple border */
    border: 1px solid #eee;
    box-shadow: 0 5px 20px rgba(0, 0, 0, 0.05);
    margin-top: 20px;
}

.email {
    font-size: 1.5rem;
    color: var(--accent-btn);
    font-weight: 600;
    text-decoration: none;
    border-bottom: 2px solid var(--accent-btn);
}

/* Blog Post Specifics */
main.blog-post {
    display: block;
    max-width: 800px;
    margin: 40px auto;
    padding: 20px;
    line-height: 1.8;
    color: #333;
}

main.blog-post h1 {
    color: #000;
    font-size: 2.2rem;
    margin-bottom: 30px;
    text-align: left;
    margin-left: 0;
}

main.blog-post h2 {
    color: #000;
    margin-top: 30px;
    font-size: 1.5rem;
}

main.blog-post h3 {
    color: #000;
    margin-top: 20px;
    font-size: 1.3rem;
}

main.blog-post p {
    margin-bottom: 20px;
    color: #333;
}

main.blog-post ul,
main.blog-post ol {
    margin-bottom: 20px;
    padding-left: 20px;
    color: #333;
}

main.blog-post .hero-img {
    width: 100%;
    height: auto;
    border-radius: 12px;
    margin-bottom: 30px;
    border: 1px solid #eee;
}

a.cta {
    display: inline-block;
    background: var(--accent-btn);
    color: #fff;
    padding: 10px 20px;
    border-radius: 8px;
    text-decoration: none;
    font-weight: 600;
    margin-top: 10px;
    transition: background 0.2s;
}

a.cta:hover {
    opacity: 0.9;
}

/* Blog Listing Grid */
main.blog-listing {
    display: grid;
    grid-template-columns: repeat(2, minmax(300px, 1fr));
    gap: 30px;
    max-width: 1000px;
    margin: 40px auto;
    align-items: stretch;
}

main.blog-listing h1 {
    grid-column: 1 / -1;
    text-align: center;
    width: 100%;
    margin-bottom: 20px;
    color: #000;
}

main.blog-listing .article-card {
    flex-direction: column;
    margin-bottom: 0;
    height: 100%;
    align-items: stretch;
}

main.blog-listing .thumb {
    width: 100%;
    height: 220px;
}

main.blog-listing .card-content {
    width: 100%;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    flex: 1;
}

@media (max-width: 768px) {
    main.blog-listing {
        grid-template-columns: 1fr;
    }
}

/* About Page Two Column Layout */
.about-container {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 50px;
    align-items: center;
    max-width: 1100px;
    margin: 40px auto;
}

.about-image img {
    width: 100%;
    border-radius: 20px;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.1);
    border: 1px solid #eee;
}

.about-text {
    text-align: left;
}

.about-text h1 {
    font-size: 2.5rem;
    margin-bottom: 25px;
    color: #000;
}

.about-text p {
    margin-bottom: 20px;
    font-size: 1.1rem;
    color: #444;
    line-height: 1.7;
}

@media (max-width: 768px) {
    .about-container {
        grid-template-columns: 1fr;
        gap: 30px;
    }

    .about-text {
        text-align: center;
    }
}