/* ==========================================================================
   DESIGN SYSTEM & VARIABLES
   ========================================================================== */
:root {
    /* Color Palette */
    --color-bg: #0b0c10;
    --color-surface: rgba(255, 255, 255, 0.03);
    --color-surface-hover: rgba(255, 255, 255, 0.06);
    --color-border: rgba(255, 255, 255, 0.08);
    --color-border-hover: rgba(255, 255, 255, 0.15);
    
    --color-text-primary: #f5f6fa;
    --color-text-secondary: #a0aec0;
    --color-text-muted: #718096;
    
    /* Brand Colors */
    --color-facebook: #1877f2;
    --color-facebook-hover: #166fe5;
    --color-instagram-start: #833ab4;
    --color-instagram-mid: #fd1d1d;
    --color-instagram-end: #fcaf45;
    
    /* Neon Accents */
    --accent-orange: #ff7e5f;
    --accent-pink: #feb47b;
    --accent-purple: #8e2de2;
    --accent-violet: #4a00e0;
    
    /* Typography */
    --font-heading: 'Fredoka', sans-serif;
    --font-body: 'Outfit', sans-serif;
    
    /* Sizing & Transitions */
    --radius-sm: 8px;
    --radius-md: 16px;
    --radius-lg: 24px;
    --radius-full: 9999px;
    --transition-smooth: all 0.4s cubic-bezier(0.16, 1, 0.3, 1);
    --transition-quick: all 0.2s ease;
}

/* ==========================================================================
   RESET & BASE STYLES
   ========================================================================== */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
    font-size: 16px;
}

body {
    background-color: var(--color-bg);
    color: var(--color-text-primary);
    font-family: var(--font-body);
    line-height: 1.6;
    overflow-x: hidden;
    position: relative;
    min-height: 100vh;
}

/* Custom Scrollbar */
::-webkit-scrollbar {
    width: 10px;
}
::-webkit-scrollbar-track {
    background: var(--color-bg);
}
::-webkit-scrollbar-thumb {
    background: rgba(255, 255, 255, 0.1);
    border-radius: var(--radius-full);
    border: 2px solid var(--color-bg);
}
::-webkit-scrollbar-thumb:hover {
    background: rgba(255, 255, 255, 0.2);
}

/* ==========================================================================
   BACKGROUND EFFECTS (Decorative)
   ========================================================================== */
.blob-wrapper {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: -1;
    overflow: hidden;
    pointer-events: none;
}

.blob {
    position: absolute;
    border-radius: var(--radius-full);
    filter: blur(100px);
    opacity: 0.25;
    mix-blend-mode: screen;
    animation: pulse 12s infinite alternate;
}

.blob-1 {
    top: -10%;
    left: -10%;
    width: 50vw;
    height: 50vw;
    background: radial-gradient(circle, var(--accent-purple) 0%, rgba(0,0,0,0) 70%);
}

.blob-2 {
    bottom: -10%;
    right: -10%;
    width: 60vw;
    height: 60vw;
    background: radial-gradient(circle, var(--accent-orange) 0%, rgba(0,0,0,0) 70%);
    animation-delay: -4s;
}

.blob-3 {
    top: 40%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: 40vw;
    height: 40vw;
    background: radial-gradient(circle, var(--accent-violet) 0%, rgba(0,0,0,0) 70%);
    animation-delay: -8s;
}

@keyframes pulse {
    0% { transform: scale(1) translate(0, 0); }
    100% { transform: scale(1.15) translate(3%, 5%); }
}

/* ==========================================================================
   TYPOGRAPHY UTILITIES
   ========================================================================== */
.gradient-text {
    background: linear-gradient(135deg, var(--accent-orange) 0%, #ff5252 50%, var(--accent-purple) 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    display: inline-block;
}

.accent-text {
    color: var(--accent-orange);
}

/* ==========================================================================
   GLASSMORPHIC CARDS
   ========================================================================== */
.glass-panel {
    background: var(--color-surface);
    backdrop-filter: blur(16px);
    -webkit-backdrop-filter: blur(16px);
    border: 1px solid var(--color-border);
    border-radius: var(--radius-md);
    transition: var(--transition-smooth);
}

.glass-panel:hover {
    background: var(--color-surface-hover);
    border-color: var(--color-border-hover);
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.3);
}

/* ==========================================================================
   HEADER NAVIGATION
   ========================================================================== */
.navbar {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    z-index: 100;
    background: rgba(11, 12, 16, 0.7);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    border-bottom: 1px solid var(--color-border);
}

.nav-container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 1rem 2rem;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.logo-area {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    text-decoration: none;
    color: var(--color-text-primary);
}

.nav-logo {
    width: 42px;
    height: 42px;
    border-radius: var(--radius-sm);
    object-fit: cover;
}

.logo-text {
    font-family: var(--font-heading);
    font-size: 1.35rem;
    font-weight: 700;
    letter-spacing: -0.5px;
}

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

.nav-link {
    color: var(--color-text-secondary);
    text-decoration: none;
    font-size: 0.95rem;
    font-weight: 500;
    transition: var(--transition-quick);
}

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

.social-icon-link {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 38px;
    height: 38px;
    border-radius: var(--radius-full);
    border: 1px solid var(--color-border);
    color: var(--color-text-secondary);
    transition: var(--transition-quick);
}

.social-icon-link:hover {
    color: var(--color-text-primary);
    transform: translateY(-2px);
    border-color: var(--color-border-hover);
}

.fb-color:hover {
    background-color: var(--color-facebook);
    border-color: var(--color-facebook);
}

.ig-color:hover {
    background: linear-gradient(45deg, var(--color-instagram-start), var(--color-instagram-mid), var(--color-instagram-end));
    border-color: transparent;
}

/* ==========================================================================
   HERO SECTION
   ========================================================================== */
.hero-section {
    padding: 10rem 2rem 5rem;
    position: relative;
    display: flex;
    justify-content: center;
    text-align: center;
}

.hero-container {
    max-width: 800px;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 1.5rem;
}

.hero-badge {
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid rgba(255, 255, 255, 0.1);
    color: var(--accent-orange);
    padding: 0.5rem 1.25rem;
    border-radius: var(--radius-full);
    font-size: 0.85rem;
    font-weight: 600;
    letter-spacing: 0.5px;
    text-transform: uppercase;
}

.logo-wrapper {
    position: relative;
    width: 140px;
    height: 140px;
    margin-bottom: 0.5rem;
}

.hero-logo {
    width: 100%;
    height: 100%;
    border-radius: 32px;
    object-fit: cover;
    z-index: 2;
    position: relative;
    box-shadow: 0 15px 35px rgba(0, 0, 0, 0.4);
}

.logo-glow {
    position: absolute;
    top: -5px;
    left: -5px;
    right: -5px;
    bottom: -5px;
    border-radius: 36px;
    background: linear-gradient(135deg, var(--accent-orange), var(--accent-purple));
    z-index: 1;
    filter: blur(15px);
    opacity: 0.6;
    animation: rotateGlow 8s infinite linear;
}

@keyframes rotateGlow {
    0% { filter: blur(15px); opacity: 0.6; }
    50% { filter: blur(25px); opacity: 0.8; }
    100% { filter: blur(15px); opacity: 0.6; }
}

.animate-float {
    animation: float 5s ease-in-out infinite;
}

@keyframes float {
    0% { transform: translateY(0px); }
    50% { transform: translateY(-10px); }
    100% { transform: translateY(0px); }
}

.hero-title {
    font-family: var(--font-heading);
    font-size: 3.5rem;
    line-height: 1.15;
    font-weight: 800;
    letter-spacing: -1.5px;
}

.hero-subtitle {
    font-size: 1.2rem;
    color: var(--color-text-secondary);
    max-width: 650px;
    font-weight: 350;
    margin-bottom: 1rem;
}

/* CTA Buttons */
.cta-group {
    display: flex;
    gap: 1.5rem;
    width: 100%;
    justify-content: center;
    flex-wrap: wrap;
    margin-bottom: 2rem;
}

.cta-btn {
    display: flex;
    align-items: center;
    padding: 1rem 2rem;
    border-radius: var(--radius-md);
    text-decoration: none;
    color: white;
    font-weight: 600;
    position: relative;
    overflow: hidden;
    transition: var(--transition-smooth);
    min-width: 280px;
    border: 1px solid rgba(255, 255, 255, 0.1);
}

.btn-icon {
    display: flex;
    align-items: center;
    justify-content: center;
    margin-right: 1rem;
    transition: var(--transition-smooth);
}

.btn-text-wrapper {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    flex-grow: 1;
}

.btn-subtext {
    font-size: 0.75rem;
    opacity: 0.8;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    font-weight: 500;
}

.btn-maintext {
    font-size: 1.05rem;
    font-weight: 700;
}

.btn-arrow {
    font-size: 1.1rem;
    transition: var(--transition-smooth);
    transform: translateX(-5px);
    opacity: 0;
}

/* Facebook CTA Styling */
.cta-facebook {
    background: linear-gradient(135deg, var(--color-facebook) 0%, #0052b4 100%);
    box-shadow: 0 10px 25px rgba(24, 119, 242, 0.3);
}

.cta-facebook:hover {
    transform: translateY(-4px);
    box-shadow: 0 15px 35px rgba(24, 119, 242, 0.5);
    border-color: rgba(255, 255, 255, 0.2);
}

/* Instagram CTA Styling */
.cta-instagram {
    background: linear-gradient(135deg, var(--color-instagram-start) 0%, var(--color-instagram-mid) 50%, var(--color-instagram-end) 100%);
    box-shadow: 0 10px 25px rgba(253, 29, 29, 0.25);
}

.cta-instagram:hover {
    transform: translateY(-4px);
    box-shadow: 0 15px 35px rgba(253, 29, 29, 0.45);
    border-color: rgba(255, 255, 255, 0.25);
}

.cta-btn:hover .btn-icon {
    transform: scale(1.15) rotate(-5deg);
}

.cta-btn:hover .btn-arrow {
    transform: translateX(0);
    opacity: 1;
}

/* ==========================================================================
   TRENDING CLIPS (GALLERY) SECTION
   ========================================================================== */
.trending-section {
    max-width: 1200px;
    margin: 0 auto;
    padding: 5rem 2rem;
}

.section-header {
    text-align: center;
    margin-bottom: 3.5rem;
}

.section-title {
    font-family: var(--font-heading);
    font-size: 2.5rem;
    font-weight: 800;
    letter-spacing: -1px;
    margin-bottom: 0.5rem;
}

.section-subtitle {
    color: var(--color-text-secondary);
    font-size: 1.1rem;
    font-weight: 300;
}

.video-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
    gap: 2.5rem;
}

.video-card {
    background: var(--color-surface);
    border: 1px solid var(--color-border);
    border-radius: var(--radius-md);
    overflow: hidden;
    transition: var(--transition-smooth);
    display: flex;
    flex-direction: column;
    cursor: pointer;
}

.video-card:hover {
    transform: translateY(-8px);
    background: rgba(255, 255, 255, 0.05);
    border-color: var(--color-border-hover);
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.4);
}

.video-thumbnail-wrapper {
    position: relative;
    width: 100%;
    padding-top: 56.25%; /* 16:9 Aspect Ratio */
    overflow: hidden;
    background: #000;
}

.video-thumbnail {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.8s cubic-bezier(0.16, 1, 0.3, 1);
}

.video-card:hover .video-thumbnail {
    transform: scale(1.08);
}

.thumbnail-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.25);
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 1;
    transition: var(--transition-smooth);
}

.video-card:hover .thumbnail-overlay {
    background: rgba(0, 0, 0, 0.4);
}

.play-btn-circle {
    width: 54px;
    height: 54px;
    background: rgba(255, 255, 255, 0.9);
    border-radius: var(--radius-full);
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--color-bg);
    box-shadow: 0 10px 20px rgba(0, 0, 0, 0.3);
    transition: var(--transition-smooth);
}

.play-btn-circle svg {
    margin-left: 3px; /* visual center adjustment */
    transition: var(--transition-smooth);
}

.video-card:hover .play-btn-circle {
    transform: scale(1.18);
    background: var(--accent-orange);
    color: white;
    box-shadow: 0 15px 25px rgba(255, 126, 95, 0.4);
}

.video-badge {
    position: absolute;
    top: 1rem;
    left: 1rem;
    padding: 0.3rem 0.8rem;
    border-radius: var(--radius-full);
    font-size: 0.75rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    box-shadow: 0 4px 10px rgba(0, 0, 0, 0.25);
}

.badge-red { background: linear-gradient(135deg, #ff416c, #ff4b2b); color: white; }
.badge-blue { background: linear-gradient(135deg, #2193b0, #6dd5ed); color: white; }
.badge-purple { background: linear-gradient(135deg, #b92b27, #1565c0); color: white; }

.video-duration {
    position: absolute;
    bottom: 1rem;
    right: 1rem;
    background: rgba(0, 0, 0, 0.75);
    padding: 0.25rem 0.6rem;
    border-radius: 4px;
    font-size: 0.75rem;
    font-weight: 600;
}

.video-info {
    padding: 1.5rem;
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
}

.video-tag {
    font-size: 0.8rem;
    color: var(--accent-orange);
    font-weight: 700;
    letter-spacing: 0.5px;
}

.video-title {
    font-size: 1.15rem;
    font-weight: 700;
    line-height: 1.4;
    color: var(--color-text-primary);
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
    height: 2.8rem;
}

.video-stats {
    display: flex;
    gap: 1rem;
    margin-top: 0.5rem;
}

.stat-item {
    font-size: 0.85rem;
    color: var(--color-text-secondary);
    font-weight: 400;
}

/* ==========================================================================
   INTERACTIVE SMILE GENERATOR SECTION
   ========================================================================== */
.generator-section {
    padding: 5rem 2rem;
    position: relative;
}

.generator-container {
    max-width: 680px;
    margin: 0 auto;
}

.generator-card {
    padding: 3rem 2rem;
    text-align: center;
    border-radius: var(--radius-lg);
    box-shadow: 0 15px 35px rgba(0, 0, 0, 0.25);
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 2rem;
    position: relative;
    overflow: hidden;
}

.generator-header {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 0.5rem;
}

.generator-emoji {
    font-size: 3.5rem;
    line-height: 1;
    cursor: default;
    display: inline-block;
}

.animate-wiggle:hover {
    animation: wiggle 0.5s ease-in-out infinite;
}

@keyframes wiggle {
    0%, 100% { transform: rotate(0); }
    25% { transform: rotate(-8deg); }
    75% { transform: rotate(8deg); }
}

.generator-title {
    font-family: var(--font-heading);
    font-size: 2.2rem;
    font-weight: 800;
    letter-spacing: -0.5px;
    margin-top: 0.5rem;
}

.generator-desc {
    color: var(--color-text-secondary);
    font-size: 0.95rem;
    max-width: 480px;
}

.joke-display-box {
    width: 100%;
    background: rgba(0, 0, 0, 0.2);
    border: 1px solid var(--color-border);
    border-radius: var(--radius-md);
    padding: 2rem;
    min-height: 140px;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    gap: 0.75rem;
    position: relative;
}

.joke-text {
    font-size: 1.25rem;
    font-weight: 500;
    line-height: 1.5;
    color: var(--color-text-primary);
    font-style: italic;
    opacity: 0;
    transform: translateY(10px);
    animation: textFadeIn 0.5s forwards cubic-bezier(0.16, 1, 0.3, 1);
}

.joke-author {
    font-size: 0.85rem;
    color: var(--accent-orange);
    font-weight: 700;
    letter-spacing: 0.5px;
    text-transform: uppercase;
    opacity: 0;
    animation: textFadeIn 0.5s forwards 0.2s cubic-bezier(0.16, 1, 0.3, 1);
}

@keyframes textFadeIn {
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.generator-btn {
    background: linear-gradient(135deg, var(--accent-orange) 0%, var(--accent-purple) 100%);
    border: none;
    outline: none;
    cursor: pointer;
    padding: 1rem 2.2rem;
    border-radius: var(--radius-full);
    font-size: 1.05rem;
    font-weight: 700;
    color: white;
    display: flex;
    align-items: center;
    gap: 0.75rem;
    transition: var(--transition-smooth);
    box-shadow: 0 10px 20px rgba(255, 126, 95, 0.25);
    border: 1px solid rgba(255, 255, 255, 0.1);
}

.generator-btn:hover {
    transform: translateY(-3px) scale(1.03);
    box-shadow: 0 15px 30px rgba(255, 126, 95, 0.45);
    border-color: rgba(255, 255, 255, 0.25);
}

.generator-btn:active {
    transform: translateY(-1px) scale(0.98);
}

/* ==========================================================================
   FOOTER
   ========================================================================== */
.footer {
    border-top: 1px solid var(--color-border);
    background: rgba(11, 12, 16, 0.85);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    padding: 4rem 2rem 2rem;
}

.footer-container {
    max-width: 1200px;
    margin: 0 auto;
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    gap: 3rem;
    flex-wrap: wrap;
    margin-bottom: 3rem;
}

.footer-brand {
    display: flex;
    align-items: center;
    gap: 1rem;
    max-width: 400px;
}

.footer-logo {
    width: 60px;
    height: 60px;
    border-radius: var(--radius-md);
    object-fit: cover;
}

.brand-text {
    display: flex;
    flex-direction: column;
}

.footer-brand-name {
    font-family: var(--font-heading);
    font-size: 1.5rem;
    font-weight: 700;
}

.footer-tagline {
    font-size: 0.85rem;
    color: var(--color-text-secondary);
    margin-top: 0.25rem;
}

.footer-links {
    display: flex;
    gap: 4rem;
}

.footer-column {
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

.footer-column h4 {
    font-family: var(--font-heading);
    font-size: 1.1rem;
    font-weight: 700;
    color: var(--color-text-primary);
}

.footer-column ul {
    list-style: none;
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
}

.footer-column ul a {
    color: var(--color-text-secondary);
    text-decoration: none;
    font-size: 0.9rem;
    transition: var(--transition-quick);
}

.footer-column ul a:hover {
    color: var(--color-text-primary);
    padding-left: 2px;
}

.footer-bottom {
    max-width: 1200px;
    margin: 0 auto;
    padding-top: 2rem;
    border-top: 1px solid var(--color-border);
    display: flex;
    justify-content: center;
    text-align: center;
}

.footer-bottom p {
    font-size: 0.8rem;
    color: var(--color-text-muted);
}

/* ==========================================================================
   SCROLL REVEAL ANIMATIONS (Triggered via JS)
   ========================================================================== */
.scroll-reveal {
    opacity: 0;
    transform: translateY(30px);
    transition: opacity 0.8s cubic-bezier(0.16, 1, 0.3, 1), transform 0.8s cubic-bezier(0.16, 1, 0.3, 1);
}

.scroll-reveal.active {
    opacity: 1;
    transform: translateY(0);
}

/* ==========================================================================
   RESPONSIVE DESIGN (Media Queries)
   ========================================================================== */
@media (max-width: 900px) {
    .nav-links {
        gap: 1rem;
    }
    
    .nav-link {
        display: none; /* Hide standard links on tablet/mobile header to save space */
    }
    
    .hero-title {
        font-size: 2.8rem;
    }
    
    .hero-subtitle {
        font-size: 1.1rem;
    }
    
    .footer-links {
        gap: 2.5rem;
    }
}

@media (max-width: 600px) {
    .navbar {
        padding: 0.5rem 1rem;
    }
    
    .nav-container {
        padding: 0.5rem 0.5rem;
    }

    .hero-section {
        padding: 8rem 1rem 4rem;
    }
    
    .hero-title {
        font-size: 2.2rem;
    }
    
    .hero-subtitle {
        font-size: 0.95rem;
    }
    
    .cta-group {
        flex-direction: column;
        align-items: center;
        gap: 1rem;
        width: 100%;
    }
    
    .cta-btn {
        width: 100%;
        min-width: 0;
    }

    
    .trending-section {
        padding: 3rem 1rem;
    }
    
    .section-title {
        font-size: 2rem;
    }
    
    .video-grid {
        grid-template-columns: 1fr;
        gap: 1.5rem;
    }
    
    .generator-section {
        padding: 3rem 1rem;
    }
    
    .generator-card {
        padding: 2rem 1.25rem;
    }
    
    .generator-title {
        font-size: 1.8rem;
    }
    
    .joke-text {
        font-size: 1.1rem;
    }
    
    .footer {
        padding: 3rem 1rem 1.5rem;
    }
    
    .footer-container {
        flex-direction: column;
        gap: 2rem;
    }
    
    .footer-links {
        width: 100%;
        justify-content: space-between;
    }
}
