/* CSS custom design for SAD landing page - Premium Glassmorphism Theme (Light default) */

:root {
    --primary: #58cc02;
    --primary-hover: #46a302;
    --primary-active: #3b8a01;
    --secondary: #1cb0f6;
    --secondary-hover: #189edc;
    --accent-yellow: #ffc800;
    --accent-orange: #ff9600;
    --accent-red: #ff4b4b;
    --accent-purple: #7853e8;
    
    /* Default: Light Theme (Glassmorphism) */
    --bg: #f3f4f6;
    --bg-gradient: linear-gradient(135deg, #f3f4f6 0%, #e5e7eb 100%);
    --card-bg: rgba(255, 255, 255, 0.45);
    --text: #0f172a;
    --text-muted: #4b5563;
    --border: rgba(255, 255, 255, 0.45);
    --border-solid: rgba(0, 0, 0, 0.08);
    --header-bg: rgba(243, 244, 246, 0.45);
    --mockup-bg: rgba(255, 255, 255, 0.3);
    --mockup-border: rgba(0, 0, 0, 0.08);
    --mockup-header: rgba(0, 0, 0, 0.04);
    
    --transition-speed: 0.25s;
    --glass-blur: blur(16px) saturate(180%);
    --glass-shadow: 0 8px 32px 0 rgba(31, 38, 135, 0.04);
}

body.dark-theme {
    /* Dark Theme (Glassmorphism) */
    --bg: #060814;
    --bg-gradient: linear-gradient(135deg, #060814 0%, #0d111d 100%);
    --card-bg: rgba(15, 23, 42, 0.45);
    --text: #f3f4f6;
    --text-muted: #9ca3af;
    --border: rgba(255, 255, 255, 0.06);
    --border-solid: rgba(255, 255, 255, 0.1);
    --header-bg: rgba(6, 8, 20, 0.45);
    --mockup-bg: rgba(15, 23, 42, 0.3);
    --mockup-border: rgba(255, 255, 255, 0.05);
    --mockup-header: rgba(255, 255, 255, 0.03);
}

@font-face {
    font-family: 'IRANYekanX';
    src: url('fonts/IRANYekanX-Regular-FaNum.ttf') format('truetype');
    font-weight: normal;
    font-style: normal;
}
@font-face {
    font-family: 'IRANYekanX';
    src: url('fonts/IRANYekanX-Medium-FaNum.ttf') format('truetype');
    font-weight: 500;
    font-style: normal;
}
@font-face {
    font-family: 'IRANYekanX';
    src: url('fonts/IRANYekanX-Bold-FaNum.ttf') format('truetype');
    font-weight: bold;
    font-style: normal;
}

* {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
    font-family: 'IRANYekanX', Tahoma, Arial, sans-serif;
    user-select: text;
}

body {
    direction: rtl;
    text-align: right;
    background-color: var(--bg);
    color: var(--text);
    overflow-x: hidden;
    background: var(--bg-gradient);
    background-size: 400% 400%;
    animation: gradientBG 15s ease infinite;
    transition: background-color var(--transition-speed), color var(--transition-speed);
}

/* Scrollbar */
::-webkit-scrollbar {
    width: 10px;
}
::-webkit-scrollbar-track {
    background: var(--bg);
}
::-webkit-scrollbar-thumb {
    background: var(--card-bg);
    border-radius: 5px;
    border: 2px solid var(--bg);
}
::-webkit-scrollbar-thumb:hover {
    background: var(--border-solid);
}

/* Main Layout */
.container {
    max-width: 1300px;
    margin: 0 auto;
    padding: 0 24px;
}

/* Background Animated Blobs */
.ambient-blobs {
    position: fixed;
    top: 0;
    left: 0;
    width: 100vw;
    height: 100vh;
    z-index: -2;
    overflow: hidden;
    pointer-events: none;
}

.blob {
    position: absolute;
    border-radius: 50%;
    filter: blur(140px);
    opacity: 0.12;
    animation: drift 25s infinite ease-in-out;
}

body.dark-theme .blob {
    opacity: 0.18;
}

.blob-1 {
    width: 500px;
    height: 500px;
    background-color: var(--primary);
    top: -10%;
    right: -10%;
    animation-delay: 0s;
}

.blob-2 {
    width: 600px;
    height: 600px;
    background-color: var(--secondary);
    bottom: -15%;
    left: -15%;
    animation-delay: -5s;
}

.blob-3 {
    width: 350px;
    height: 350px;
    background-color: var(--accent-purple);
    top: 40%;
    left: 20%;
    animation-delay: -10s;
}

/* Header & Navigation */
header {
    background: var(--header-bg);
    backdrop-filter: var(--glass-blur);
    -webkit-backdrop-filter: var(--glass-blur);
    position: sticky;
    top: 0;
    z-index: 100;
    border-bottom: 1px solid var(--border);
    transition: background var(--transition-speed), border-color var(--transition-speed);
}

.nav-wrapper {
    display: flex;
    justify-content: space-between;
    align-items: center;
    height: 80px;
}

.logo-section {
    display: flex;
    align-items: center;
    gap: 12px;
}

.site-logo {
    width: 52px;
    height: 52px;
    object-fit: contain;
    animation: rotateLogo 8s infinite linear;
}

.logo-title {
    font-size: 24px;
    font-weight: bold;
    color: var(--text);
    letter-spacing: 0.5px;
}

.header-auth-btn {
    padding: 6px 16px;
    font-size: 0.88rem;
    border-radius: 20px;
    white-space: nowrap;
}

@media (max-width: 576px) {
    .header-auth-btn {
        padding: 5px 10px;
        font-size: 0.78rem;
        border-radius: 16px;
    }
}

/* Desktop Navigation Styles */
@media (min-width: 992px) {
    .nav-menu-wrapper {
        display: flex !important;
        align-items: center !important;
        gap: 24px !important;
        position: static !important;
        background: transparent !important;
        box-shadow: none !important;
        height: auto !important;
        width: auto !important;
        padding: 0 !important;
    }

    .nav-menu {
        display: flex !important;
        flex-direction: row !important;
        gap: 24px !important;
        list-style: none !important;
        margin: 0 !important;
        padding: 0 !important;
    }

    .nav-menu a {
        color: var(--text-muted) !important;
        text-decoration: none !important;
        font-weight: 500 !important;
        font-size: 15px !important;
        padding: 0 !important;
        border: none !important;
        background: transparent !important;
        transition: color var(--transition-speed) !important;
    }

    .nav-menu a:hover, .nav-menu a.active {
        color: var(--text) !important;
        background: transparent !important;
    }
}

/* Mobile Navigation Toggle & Drawer Styles */
.navbar-toggler {
    display: none;
    background: transparent;
    border: none;
    cursor: pointer;
    padding: 6px;
    outline: none;
    z-index: 110;
}

.navbar-toggler .toggler-icon {
    width: 24px;
    height: 2px;
    background-color: var(--text);
    display: block;
    margin: 5px 0;
    transition: all 0.3s ease;
}

.navbar-toggler.active .toggler-icon:nth-child(1) {
    transform: rotate(45deg) translate(5px, 5px);
}

.navbar-toggler.active .toggler-icon:nth-child(2) {
    opacity: 0;
}

.navbar-toggler.active .toggler-icon:nth-child(3) {
    transform: rotate(-45deg) translate(5px, -5px);
}

@media (max-width: 991px) {
    .navbar-toggler {
        display: block;
    }

    .nav-menu-wrapper {
        position: fixed !important;
        top: 80px !important;
        right: -100% !important;
        width: 280px !important;
        max-width: 85vw !important;
        height: calc(100vh - 80px) !important;
        backdrop-filter: blur(25px) !important;
        -webkit-backdrop-filter: blur(25px) !important;
        border-left: 1px solid var(--border-solid) !important;
        box-shadow: -10px 10px 40px rgba(0, 0, 0, 0.4) !important;
        flex-direction: column !important;
        align-items: flex-start !important;
        padding: 24px 20px !important;
        gap: 16px !important;
        transition: right 0.35s cubic-bezier(0.16, 1, 0.3, 1) !important;
        z-index: 99999 !important;
        overflow-y: auto !important;
        display: flex !important;
    }

    /* Force override any template display:none rules on mobile nav elements */
    .nav-menu-wrapper nav,
    .nav-menu-wrapper .navbar-collapse,
    .nav-menu-wrapper .navbar-nav {
        display: block !important;
        visibility: visible !important;
        opacity: 1 !important;
        width: 100% !important;
        position: static !important;
        box-shadow: none !important;
        background: transparent !important;
        padding: 0 !important;
    }

    body.dark-theme .nav-menu-wrapper {
        background-color: rgba(15, 23, 42, 0.98) !important;
    }

    body:not(.dark-theme) .nav-menu-wrapper {
        background-color: rgba(255, 255, 255, 0.98) !important;
    }

    .nav-menu-wrapper.show {
        right: 0 !important;
    }

    .nav-menu {
        flex-direction: column !important;
        width: 100% !important;
        gap: 10px !important;
        list-style: none !important;
        padding: 0 !important;
        margin: 0 !important;
    }

    .nav-menu li {
        width: 100% !important;
        margin: 0 !important;
        padding: 0 !important;
    }

    .nav-menu a {
        display: block !important;
        padding: 12px 14px !important;
        font-size: 16px !important;
        font-weight: 700 !important;
        border-bottom: 1px solid var(--border-solid) !important;
        border-radius: 10px !important;
        transition: all 0.2s ease !important;
        text-decoration: none !important;
    }

    body.dark-theme .nav-menu a {
        color: #f3f4f6 !important;
    }

    body:not(.dark-theme) .nav-menu a {
        color: #0f172a !important;
    }

    .nav-menu a:hover, .nav-menu a.active {
        color: #58cc02 !important;
        background-color: rgba(88, 204, 2, 0.12) !important;
    }
}

/* Theme Toggle Button */
.theme-toggle-btn {
    background: var(--card-bg);
    border: 1px solid var(--border);
    backdrop-filter: var(--glass-blur);
    -webkit-backdrop-filter: var(--glass-blur);
    border-radius: 12px;
    width: 44px;
    height: 44px;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: all var(--transition-speed) ease;
    outline: none;
}

.theme-toggle-btn:hover {
    transform: scale(1.05);
    border-color: var(--primary);
}

.theme-toggle-btn svg {
    width: 22px;
    height: 22px;
    fill: var(--text-muted);
    transition: fill var(--transition-speed);
}

.theme-toggle-btn:hover svg {
    fill: var(--primary);
}

/* Hero Section */
.hero {
    height: 100vh;
    min-height: 600px;
    position: relative;
    overflow: hidden;
    text-align: center;
    display: flex;
    align-items: center;
    justify-content: center;
}

/* Constellation Canvas Background */
#constellation-canvas {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: -1;
    pointer-events: auto; /* Allow mouse movement interaction */
}

.hero-content {
    max-width: 800px;
    margin: 0 auto;
    z-index: 2;
    position: relative;
}

.hero-content h1 {
    font-size: 42px;
    line-height: 1.5;
    color: var(--text);
    margin-bottom: 24px;
    text-align: center;
}

.hero-content h1 span.highlight {
    color: var(--primary);
    white-space: nowrap;
    display: inline-block;
    min-height: 58px;
    vertical-align: middle;
}

/* Typing cursor animation */
.typing-cursor {
    display: inline-block;
    width: 3px;
    background-color: var(--primary);
    margin-right: 4px;
    animation: blink 0.75s step-end infinite;
}

.hero-content p {
    font-size: 17px;
    color: var(--text-muted);
    line-height: 1.9;
    margin-bottom: 40px;
}

.hero-buttons {
    display: flex;
    justify-content: center;
    gap: 16px;
}

.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 14px 32px;
    border-radius: 16px;
    font-size: 16px;
    font-weight: bold;
    cursor: pointer;
    text-decoration: none;
    transition: all var(--transition-speed) ease;
    border: none;
    outline: none;
}

.btn-primary {
    background-color: var(--primary);
    color: #fff;
    border: 1px solid var(--primary);
}

.btn-primary:hover {
    background-color: var(--primary-hover);
    border-color: var(--primary-hover);
    transform: translateY(-2px);
}

/* Showcase Section */
.features-section {
    padding: 100px 0 60px;
    border-top: 1px solid var(--border);
}

.section-header {
    text-align: center;
    margin-bottom: 80px;
}

.section-header h2 {
    font-size: 34px;
    color: var(--text);
    margin-bottom: 12px;
}

.section-header p {
    font-size: 16px;
    color: var(--text-muted);
}

/* Step-by-Step Alternating Grid Chasis */
.steps-flow-container {
    display: flex;
    flex-direction: column;
    gap: 100px;
    margin-top: 40px;
}

.flow-step {
    display: grid;
    grid-template-columns: 1.1fr 1fr; /* Left: Mockup Showcase, Right: Details text */
    gap: 70px;
    align-items: center;
}

/* Alternate order for even items to swap positions cleanly in RTL */
.flow-step:nth-child(even) .flow-mockup-side {
    order: 2; /* Moves mockup to left (logical right in RTL grid) */
}

.flow-step:nth-child(even) .flow-content-side {
    order: 1; /* Moves info text to right (logical left in RTL grid) */
}

/* Mockup Column side styles */
.flow-mockup-side {
    position: relative;
    width: 100%;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 16px;
}

.mockup-ambient-glow {
    position: absolute;
    width: 320px;
    height: 320px;
    background: radial-gradient(circle, var(--mockup-glow, rgba(88, 204, 2, 0.12)) 0%, rgba(0,0,0,0) 70%);
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    z-index: -1;
    pointer-events: none;
}

/* Slideshow Container */
.slides-container {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
}

.slide-img {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    opacity: 0;
    object-fit: cover;
    transition: opacity 0.5s ease-in-out;
    z-index: 1;
}

.slide-img.active {
    opacity: 1;
    z-index: 2;
}

.slide-dots {
    position: absolute;
    bottom: 12px;
    left: 50%;
    transform: translateX(-50%);
    display: flex;
    gap: 8px;
    z-index: 15;
}

.dot {
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background-color: rgba(255, 255, 255, 0.4);
    border: 1px solid rgba(0, 0, 0, 0.15);
    cursor: pointer;
    transition: all 0.25s ease;
}

.dot.active, .dot:hover {
    background-color: var(--secondary);
    transform: scale(1.2);
    box-shadow: 0 0 8px var(--secondary);
}

/* Info Column side styles */
.flow-content-side {
    display: flex;
    flex-direction: column;
    gap: 20px;
    text-align: right;
}

.step-badge {
    display: inline-block;
    padding: 6px 16px;
    background-color: var(--card-bg);
    border: 1px solid var(--border);
    border-radius: 30px;
    font-size: 14px;
    font-weight: bold;
    color: var(--primary);
    width: fit-content;
    backdrop-filter: var(--glass-blur);
    -webkit-backdrop-filter: var(--glass-blur);
}

.flow-step:nth-child(2) .step-badge { color: var(--secondary); }
.flow-step:nth-child(3) .step-badge { color: var(--accent-orange); }
.flow-step:nth-child(4) .step-badge { color: var(--accent-purple); }

.flow-content-side h2 {
    font-size: 26px;
    color: var(--text);
    font-weight: bold;
}

.flow-content-side p {
    font-size: 15px;
    color: var(--text-muted);
    line-height: 1.8;
}

.flow-bullets {
    list-style: none;
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.flow-bullets li {
    font-size: 14px;
    color: var(--text-muted);
    line-height: 1.7;
    position: relative;
    padding-right: 20px;
}

.flow-bullets li::before {
    content: '✦';
    position: absolute;
    right: 0;
    color: var(--primary);
    font-weight: bold;
}

.flow-step:nth-child(2) .flow-bullets li::before { color: var(--secondary); }
.flow-step:nth-child(3) .flow-bullets li::before { color: var(--accent-orange); }
.flow-step:nth-child(4) .flow-bullets li::before { color: var(--accent-purple); }

.panel-action-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 12px 28px;
    background-color: var(--card-bg);
    border: 1px solid var(--border);
    backdrop-filter: var(--glass-blur);
    -webkit-backdrop-filter: var(--glass-blur);
    box-shadow: var(--glass-shadow);
    color: var(--text);
    border-radius: 14px;
    font-size: 14px;
    font-weight: bold;
    text-decoration: none;
    width: fit-content;
    margin-top: 10px;
    transition: all var(--transition-speed) ease;
}

.panel-action-btn:hover {
    transform: translateY(-2px);
    border-color: var(--primary);
    background-color: var(--primary);
    color: #fff;
}

.flow-step:nth-child(2) .panel-action-btn:hover {
    border-color: var(--secondary);
    background-color: var(--secondary);
}

.flow-step:nth-child(3) .panel-action-btn:hover {
    border-color: var(--accent-orange);
    background-color: var(--accent-orange);
}

.flow-step:nth-child(4) .panel-action-btn:hover {
    border-color: var(--accent-purple);
    background-color: var(--accent-purple);
}

/* Mockup Frames Styling */
.browser-mockup {
    width: 100%;
    background-color: var(--mockup-bg);
    border: 1px solid var(--mockup-border);
    border-radius: 16px;
    overflow: hidden;
    box-shadow: var(--glass-shadow);
}

.browser-header {
    background-color: var(--mockup-header);
    padding: 10px 16px;
    display: flex;
    align-items: center;
    gap: 8px;
    border-bottom: 1px solid var(--mockup-border);
}

.browser-dot {
    width: 10px;
    height: 10px;
    border-radius: 50%;
}

.dot-red { background-color: #ef4444; }
.dot-yellow { background-color: #eab308; }
.dot-green { background-color: #22c55e; }

.browser-address {
    background-color: var(--card-bg);
    border-radius: 8px;
    flex-grow: 1;
    height: 30px;
    margin: 0 16px;
    color: var(--text-muted);
    font-size: 13px;
    display: flex;
    align-items: center;
    padding-left: 12px;
    font-family: monospace;
    direction: ltr;
    text-align: left;
    border: 1px solid var(--border);
    text-decoration: none;
}

.browser-body {
    position: relative;
    padding-bottom: 56.25%; /* 16:9 Aspect Ratio */
    height: 0;
    overflow: hidden;
    cursor: zoom-in;
    background: linear-gradient(135deg, rgba(88, 204, 2, 0.08) 0%, rgba(28, 176, 246, 0.12) 50%, rgba(88, 204, 2, 0.08) 100%);
    background-size: 200% 200%;
    animation: shimmerBg 3s ease infinite;
}

.browser-body::after, .phone-screen::after {
    content: '🔍';
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%) scale(0.8);
    font-size: 32px;
    color: #fff;
    background: rgba(0, 0, 0, 0.4);
    width: 60px;
    height: 60px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0;
    transition: all 0.3s ease;
    pointer-events: none;
    z-index: 5;
}

.browser-body:hover::after, .phone-screen:hover::after {
    opacity: 1;
    transform: translate(-50%, -50%) scale(1);
}

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

.browser-body:hover img {
    transform: scale(1.03);
}

/* High Fidelity phone mockup */
.phone-mockup {
    width: 290px;
    height: 580px;
    border: 12px solid #1e293b;
    border-radius: 40px;
    background-color: #000;
    overflow: hidden;
    position: relative;
    box-shadow: inset 0 0 10px rgba(0,0,0,0.8);
}

body.dark-theme .phone-mockup {
    border-color: #0f172a;
}

.phone-mockup::after {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(135deg, rgba(255,255,255,0.06) 0%, rgba(255,255,255,0) 60%);
    pointer-events: none;
    z-index: 4;
}

.phone-notch {
    position: absolute;
    top: 0;
    left: 50%;
    transform: translateX(-50%);
    width: 110px;
    height: 22px;
    background-color: #1e293b;
    border-bottom-left-radius: 14px;
    border-bottom-right-radius: 14px;
    z-index: 10;
}

body.dark-theme .phone-notch {
    background-color: #0f172a;
}

.phone-screen {
    width: 100%;
    height: 100%;
    position: relative;
    overflow: hidden;
    border-radius: 28px;
    cursor: zoom-in;
    background: linear-gradient(135deg, rgba(255, 150, 0, 0.08) 0%, rgba(120, 83, 232, 0.12) 50%, rgba(255, 150, 0, 0.08) 100%);
    background-size: 200% 200%;
    animation: shimmerBg 3s ease infinite;
}

@keyframes shimmerBg {
    0% { background-position: 0% 50%; }
    50% { background-position: 100% 50%; }
    100% { background-position: 0% 50%; }
}

.phone-screen img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

/* Lightbox Modal */
.lightbox {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(5, 7, 12, 0.95);
    z-index: 1000;
    display: none;
    justify-content: center;
    align-items: center;
    padding: 24px;
}

.lightbox-close {
    position: absolute;
    top: 24px;
    right: 24px;
    color: #fff;
    font-size: 40px;
    cursor: pointer;
    background: none;
    border: none;
    outline: none;
}

.lightbox-content {
    max-width: 95%;
    max-height: 90vh;
    border-radius: 12px;
    box-shadow: 0 10px 40px rgba(0,0,0,0.8);
}

/* Footer */
.footer-waves-container {
    position: relative;
    width: 100%;
    height: 70px;
    margin-top: -70px;
    overflow: hidden;
    pointer-events: none;
}

.footer-wave {
    position: absolute;
    width: 100%;
    height: 70px;
    min-height: 70px;
    max-height: 70px;
    bottom: -1px;
    left: 0;
}

/* Wave Animations */
.parallax-waves > use {
    animation: move-wave 30s cubic-bezier(.55,.5,.45,.5) infinite;
}
.parallax-waves > use:nth-child(1) {
    animation-delay: -2s;
    animation-duration: 6s;
}
.parallax-waves > use:nth-child(2) {
    animation-delay: -3s;
    animation-duration: 9s;
}
.parallax-waves > use:nth-child(3) {
    animation-delay: -4s;
    animation-duration: 12s;
}
.parallax-waves > use:nth-child(4) {
    animation-delay: -5s;
    animation-duration: 18s;
}

/* Dedicated Live Notifications Section */
.notifications-showcase-section {
    padding: 80px 0;
    border-top: 1px solid var(--border);
    position: relative;
    overflow: hidden;
    background-image: radial-gradient(var(--border-solid) 1.5px, transparent 1.5px);
    background-size: 24px 24px;
}

.notifications-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 30px;
    margin-top: 40px;
    position: relative;
    z-index: 5;
}

.notification-column {
    display: flex;
    flex-direction: column;
    gap: 20px;
    align-items: center;
}

.column-header {
    display: flex;
    align-items: center;
    gap: 10px;
    margin-bottom: 5px;
    width: 290px;
    padding-bottom: 10px;
    border-bottom: 2px dotted var(--primary);
}

.column-header h3 {
    font-size: 16px;
    font-weight: bold;
    color: var(--text);
}

.column-icon {
    font-size: 18px;
}

.dialog-wrapper {
    width: 290px;
    filter: drop-shadow(0 10px 25px rgba(0,0,0,0.06));
    transition: transform var(--transition-speed);
}

.dialog-wrapper.dialog-1 {
    animation: floatSlow 6s ease-in-out infinite;
}

.dialog-wrapper.dialog-2 {
    animation: floatMedium 8s ease-in-out infinite;
    animation-delay: -2s;
}

.dialog-wrapper.dialog-3 {
    animation: floatFast 7s ease-in-out infinite;
    animation-delay: -4s;
}

.dialog-wrapper.dialog-4 {
    animation: floatSlow 7s ease-in-out infinite;
    animation-delay: -1s;
}

.dialog-wrapper.dialog-5 {
    animation: floatMedium 6s ease-in-out infinite;
    animation-delay: -3s;
}

.dialog-wrapper.dialog-6 {
    animation: floatFast 8s ease-in-out infinite;
    animation-delay: -5s;
}

.dialog-svg {
    width: 100%;
    height: auto;
    display: block;
}

.dialog-svg path {
    fill: var(--card-bg);
    stroke: var(--border);
    backdrop-filter: var(--glass-blur);
}

.dialog-1 .dialog-svg path { stroke: var(--secondary); }
.dialog-2 .dialog-svg path { stroke: var(--secondary); }
.dialog-3 .dialog-svg path { stroke: var(--primary); }
.dialog-4 .dialog-svg path { stroke: var(--primary); }
.dialog-5 .dialog-svg path { stroke: var(--accent-orange); }
.dialog-6 .dialog-svg path { stroke: var(--accent-purple); }

.dialog-content {
    direction: rtl;
    text-align: right;
    display: flex;
    flex-direction: column;
    gap: 6px;
    padding: 4px 6px;
}

.dialog-header {
    display: flex;
    align-items: center;
    gap: 8px;
    width: 100%;
}

.dialog-icon {
    font-size: 16px;
}

.dialog-title {
    font-size: 13px;
    font-weight: bold;
    color: var(--text);
}

.dialog-time {
    font-size: 11px;
    color: var(--text-muted);
    margin-right: auto;
}

.dialog-body {
    font-size: 12px;
    color: var(--text-muted);
    line-height: 1.5;
}

@keyframes floatSlow {
    0%, 100% { transform: translateY(0) rotate(0deg); }
    50% { transform: translateY(-12px) rotate(0.8deg); }
}

@keyframes floatMedium {
    0%, 100% { transform: translateY(0) rotate(0deg); }
    50% { transform: translateY(-16px) rotate(-1deg); }
}

@keyframes floatFast {
    0%, 100% { transform: translateY(0) rotate(0deg); }
    50% { transform: translateY(-10px) rotate(0.5deg); }
}

@keyframes move-wave {
    0% { transform: translate3d(-90px, 0, 0); }
    100% { transform: translate3d(85px, 0, 0); }
}

footer {
    padding: 30px 0 24px;
    background: var(--card-bg);
    backdrop-filter: var(--glass-blur);
    -webkit-backdrop-filter: var(--glass-blur);
    position: relative;
    z-index: 10;
}

body.dark-theme footer {
    background: rgba(15, 23, 42, 0.45);
}

.footer-content {
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
    gap: 30px;
    margin-bottom: 30px;
}

.footer-brand {
    display: flex;
    align-items: center;
    gap: 12px;
}

.footer-brand h3 {
    font-size: 20px;
    color: var(--text);
    font-weight: bold;
}

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

.footer-links a {
    color: var(--text-muted);
    text-decoration: none;
    font-size: 14px;
    font-weight: 500;
    transition: color var(--transition-speed);
}

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

.footer-bottom {
    text-align: center;
    padding-top: 24px;
    border-top: 1px solid var(--border);
    font-size: 13px;
    color: var(--text-muted);
}

/* Animations */
@keyframes gradientBG {
    0% { background-position: 0% 50%; }
    50% { background-position: 100% 50%; }
    100% { background-position: 0% 50%; }
}

@keyframes rotateLogo {
    from { transform: rotate(0deg); }
    to { transform: rotate(360deg); }
}

@keyframes slideUp {
    from { transform: translateY(40px); opacity: 0; }
    to { transform: translateY(0); opacity: 1; }
}

@keyframes blink {
    from, to { color: transparent }
    50% { color: var(--primary); }
}

/* Responsive Design - Heavily Optimized for Mobile */
@media (max-width: 1024px) {
    .hero {
        padding: 80px 0 60px;
    }
    
    .hero-content h1 {
        font-size: 32px;
    }

    .hero-content p {
        font-size: 15px;
    }

    .flow-step {
        grid-template-columns: 1fr;
        gap: 45px;
    }

    .flow-step:nth-child(even) .flow-mockup-side {
        order: initial; /* Reset alternating layout columns order on mobile */
    }

    .flow-step:nth-child(even) .flow-content-side {
        order: initial;
    }
}

@media (max-width: 768px) {
    .nav-wrapper {
        height: 70px;
    }

    /* .nav-menu is inside mobile drawer .nav-menu-wrapper */
    .nav-menu-wrapper .nav-menu {
        display: flex !important;
        flex-direction: column !important;
    }

    .hero {
        height: auto;
        min-height: 100vh;
        padding: 100px 0 60px;
    }

    .hero-content h1 {
        font-size: 26px;
    }

    .hero-content h1 span.highlight {
        min-height: 38px;
    }

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

    .notifications-grid {
        grid-template-columns: 1fr;
        gap: 40px;
    }
}

/* Instagram Style News Cards */
.insta-card {
    background-color: var(--card-bg);
    border: 1px solid var(--border);
    border-radius: 12px;
    margin-bottom: 30px;
    overflow: hidden;
    transition: transform 0.2s ease, box-shadow 0.2s ease;
    direction: rtl;
    text-align: right;
}

.insta-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 10px 25px rgba(0,0,0,0.1);
}

.insta-header {
    display: flex;
    align-items: center;
    padding: 14px;
    gap: 12px;
    border-bottom: 1px solid var(--border);
}

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

.insta-header-text {
    display: flex;
    flex-direction: column;
}

.insta-author {
    font-size: 14px;
    font-weight: bold;
    color: var(--text);
    margin: 0;
}

.insta-date {
    font-size: 12px;
    color: var(--text-muted);
    margin: 0;
}

.insta-image-wrapper {
    width: 100%;
    position: relative;
    padding-top: 100%; /* 1:1 Aspect Ratio (Square) */
    background-color: #f8f9fa;
}

.insta-image-wrapper img {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.insta-footer {
    padding: 14px;
}

.insta-actions {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 10px;
}

.insta-icons {
    display: flex;
    gap: 15px;
}

.insta-icon {
    font-size: 24px;
    color: var(--text);
    cursor: pointer;
    transition: color 0.2s;
}

.insta-icon:hover {
    color: var(--primary);
}

.insta-views {
    font-size: 14px;
    font-weight: bold;
    color: var(--text);
}

.insta-content h3 {
    font-size: 16px;
    font-weight: bold;
    margin-bottom: 8px;
    color: var(--text);
}

.insta-content p {
    font-size: 14px;
    color: var(--text-muted);
    line-height: 1.5;
    margin-bottom: 12px;
}

.insta-read-more {
    font-size: 14px;
    color: var(--primary);
    font-weight: bold;
    text-decoration: none;
}

.insta-read-more:hover {
    text-decoration: underline;
}

/* Instagram Style Detail Page */
.insta-detail-layout {
    display: flex;
    background-color: var(--card-bg);
    border: 1px solid var(--border);
    border-radius: 12px;
    overflow: hidden;
    min-height: 500px;
    max-width: 1000px;
    margin: 50px auto;
    direction: rtl;
}

.insta-detail-image-side {
    flex: 1.5;
    background-color: #000;
    display: flex;
    align-items: center;
    justify-content: center;
    border-left: 1px solid var(--border);
}

.insta-detail-image-side img {
    max-width: 100%;
    max-height: 600px;
    object-fit: contain;
}

.insta-detail-content-side {
    flex: 1;
    display: flex;
    flex-direction: column;
}

.insta-detail-body {
    padding: 20px;
    flex-grow: 1;
    overflow-y: auto;
}

.insta-detail-body h2 {
    font-size: 20px;
    font-weight: bold;
    margin-bottom: 15px;
    color: var(--text);
}

.insta-detail-body p {
    font-size: 15px;
    color: var(--text-muted);
    line-height: 1.8;
    white-space: pre-line;
}

@media (max-width: 768px) {
    .insta-detail-layout {
        flex-direction: column;
        margin: 20px 10px;
    }
    .insta-detail-image-side {
        border-left: none;
        border-bottom: 1px solid var(--border);
    }
    .insta-detail-image-side img {
        width: 100%;
        max-height: 400px;
        object-fit: cover;
    }
}

/* Sidebar & Lazy Loading Items for News Details */
.news-detail-container {
    padding-top: 100px;
    padding-bottom: 60px;
}

.news-sidebar-card {
    background: var(--card-bg);
    border: 1px solid var(--border);
    border-radius: 16px;
    padding: 20px;
    margin-bottom: 24px;
    backdrop-filter: var(--glass-blur);
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.1);
}

.news-sidebar-title {
    font-size: 18px;
    font-weight: 700;
    margin-bottom: 18px;
    padding-bottom: 10px;
    border-bottom: 2px solid var(--primary);
    color: var(--text);
    display: flex;
    align-items: center;
    gap: 8px;
}

.sidebar-news-item {
    display: flex;
    gap: 12px;
    margin-bottom: 16px;
    padding-bottom: 14px;
    border-bottom: 1px dashed var(--border);
    text-decoration: none;
    transition: transform 0.2s ease;
}

.sidebar-news-item:hover {
    transform: translateX(-4px);
}

.sidebar-news-item:last-child {
    margin-bottom: 0;
    padding-bottom: 0;
    border-bottom: none;
}

.sidebar-news-thumb {
    width: 70px;
    height: 70px;
    border-radius: 10px;
    object-fit: cover;
    flex-shrink: 0;
}

.sidebar-news-info {
    display: flex;
    flex-direction: column;
    justify-content: center;
}

.sidebar-news-info h5 {
    font-size: 14px;
    font-weight: 600;
    line-height: 1.4;
    color: var(--text);
    margin-bottom: 6px;
}

.sidebar-news-info span {
    font-size: 12px;
    color: var(--text-muted);
    display: flex;
    align-items: center;
    gap: 10px;
}

.news-annotation-box {
    background: rgba(28, 176, 246, 0.08);
    border-right: 4px solid var(--primary);
    border-radius: 8px;
    padding: 16px;
    margin: 24px 0;
    font-size: 14px;
    line-height: 1.7;
    color: var(--text);
}

.lazy-load-sentinel {
    text-align: center;
    padding: 20px;
    color: var(--text-muted);
}

