/* ==========================================================================
   Landing Page Styles (SaaS Modern UI - Seneasy Style)
   ========================================================================== */
@import url('https://fonts.googleapis.com/css2?family=Inter:wght@400;500;600;700;800&display=swap');

:root {
    --primary: #4f46e5;
    --primary-hover: #4338ca;
    --bg-main: #fafafa;
    --bg-slate: #f8fafc;
    --text-main: #0f172a;
    --text-secondary: #334155;
    --text-muted: #64748b;
    --border: #e2e8f0;
    --radius-lg: 16px;
    --radius-xl: 24px;
}

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

body {
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
    background-color: var(--bg-main);
    color: var(--text-main);
    line-height: 1.6;
    -webkit-font-smoothing: antialiased;
}

.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 24px;
}

/* --- Utilities --- */
.text-primary { color: var(--primary); }
.bg-white { background-color: #ffffff; }
.bg-slate { background-color: var(--bg-slate); }
.text-center { text-align: center; }
.mb-4 { margin-bottom: 1rem; }
.mb-12 { margin-bottom: 3rem; }
.mt-4 { margin-top: 1rem; }
.relative { position: relative; }
.z-10 { z-index: 10; }
.text-4xl { font-size: 2.5rem; }
.font-bold { font-weight: bold; }
.tracking-tight { letter-spacing: -0.025em; }

.text-gradient {
    background: linear-gradient(135deg, var(--primary) 0%, #ec4899 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
}

/* --- Buttons --- */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    padding: 10px 20px;
    border-radius: 8px;
    font-weight: 600;
    text-decoration: none;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    cursor: pointer;
    border: none;
}

.btn-primary {
    background: var(--primary);
    color: white;
}
.btn-primary:hover {
    background: var(--primary-hover);
    transform: translateY(-2px);
    box-shadow: 0 8px 15px rgba(79, 70, 229, 0.3);
}

.btn-secondary {
    background: white;
    color: var(--text-main);
    border: 1px solid var(--border);
}
.btn-secondary:hover {
    border-color: var(--primary);
    color: var(--primary);
    transform: translateY(-2px);
}

.btn-large {
    padding: 14px 28px;
    font-size: 1.1rem;
    border-radius: 12px;
}

.shadow-glow {
    box-shadow: 0 4px 14px 0 rgba(79, 70, 229, 0.39);
}

/* --- Navbar --- */
.navbar {
    position: sticky;
    top: 0;
    z-index: 100;
    background: rgba(255, 255, 255, 0.8);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    border-bottom: 1px solid rgba(226, 232, 240, 0.6);
}

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

.brand-logo {
    display: flex;
    align-items: center;
    gap: 10px;
    font-size: 1.25rem;
    font-weight: 800;
    color: var(--text-main);
    text-decoration: none;
    letter-spacing: -0.5px;
}

.nav-links {
    display: flex;
    gap: 32px;
}
.nav-links a {
    text-decoration: none;
    color: var(--text-secondary);
    font-weight: 500;
    font-size: 0.95rem;
    transition: color 0.2s;
}
.nav-links a:hover {
    color: var(--primary);
}

.nav-actions {
    display: flex;
    align-items: center;
    gap: 20px;
}
.nav-link-sub {
    text-decoration: none;
    color: var(--text-muted);
    font-size: 0.9rem;
    font-weight: 500;
}
.nav-link-sub:hover {
    color: var(--text-main);
}

/* --- Hero Section --- */
.hero {
    text-align: center;
    padding: 80px 20px 40px;
    position: relative;
    overflow: hidden;
}

.hero-bg-effect {
    position: absolute;
    top: -10%;
    left: 50%;
    transform: translateX(-50%);
    width: 800px;
    height: 600px;
    background: radial-gradient(circle, rgba(79,70,229,0.1) 0%, rgba(255,255,255,0) 60%);
    z-index: -1;
}

.hero-badge {
    display: inline-flex;
    align-items: center;
    padding: 6px 16px;
    background: #e0e7ff;
    color: var(--primary);
    border-radius: 50px;
    font-size: 0.85rem;
    font-weight: 600;
    margin-bottom: 24px;
    border: 1px solid rgba(79, 70, 229, 0.2);
}

.hero h1 {
    font-size: 4rem;
    font-weight: 800;
    line-height: 1.15;
    margin-bottom: 24px;
    letter-spacing: -1.5px;
}

.hero-subtitle {
    font-size: 1.25rem;
    color: var(--text-secondary);
    margin-bottom: 40px;
    max-width: 700px;
    margin-left: auto;
    margin-right: auto;
}

.hero-actions {
    display: flex;
    justify-content: center;
    gap: 16px;
    margin-bottom: 60px;
}

/* --- Hero Mockup (Seneasy 1:1) --- */
.hero-mockup-wrapper {
    max-width: 1100px;
    margin: 40px auto 0;
    padding: 0 20px;
    perspective: 1200px;
}

.hero-mac-window {
    position: relative;
    background: white;
    border-radius: 16px;
    border: 1px solid var(--border);
    box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.25);
    transform: scaleX(0.9) scaleY(0.9) rotateX(15deg);
    transform-origin: top center;
    transition: transform 0.6s cubic-bezier(0.16, 1, 0.3, 1);
    overflow: hidden;
}

.hero-mockup-wrapper:hover .hero-mac-window {
    transform: scaleX(1) scaleY(1) rotateX(0deg);
}

.mac-header {
    background: #f8fafc;
    border-bottom: 1px solid var(--border);
    padding: 12px 20px;
    display: flex;
    align-items: center;
    gap: 8px;
    position: relative;
    z-index: 20;
}

.mac-header span {
    width: 12px;
    height: 12px;
    border-radius: 50%;
}
.mac-header span:nth-child(1) { background: #ff5f57; }
.mac-header span:nth-child(2) { background: #ffbd2e; }
.mac-header span:nth-child(3) { background: #28ca42; }

.mac-url-bar {
    position: absolute;
    left: 50%;
    transform: translateX(-50%);
    font-size: 11px;
    color: var(--text-muted);
    background: white;
    padding: 4px 20px;
    border-radius: 6px;
    border: 1px solid var(--border);
    font-family: monospace;
}

.mac-body {
    position: relative;
    width: 100%;
    background: #f1f5f9;
}
.mac-body img, .mac-body video {
    width: 100%;
    height: auto;
    display: block;
}

/* Hover popup card */
.hover-popup-card {
    position: absolute;
    bottom: 40px;
    left: 40px;
    background: rgba(255, 255, 255, 0.9);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    border: 1px solid var(--border);
    border-radius: 12px;
    padding: 16px;
    box-shadow: 0 20px 25px -5px rgba(0, 0, 0, 0.1), 0 10px 10px -5px rgba(0, 0, 0, 0.04);
    display: flex;
    align-items: center;
    gap: 16px;
    transform: translateY(20px);
    opacity: 0;
    transition: all 0.5s cubic-bezier(0.16, 1, 0.3, 1);
}

.hero-mac-window:hover .hover-popup-card {
    transform: translateY(0);
    opacity: 1;
}

.hover-icon {
    width: 40px;
    height: 40px;
    background: #eef2ff;
    color: var(--primary);
    border-radius: 10px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.2rem;
    border: 1px solid #e0e7ff;
}

.hover-text h4 {
    font-size: 14px;
    font-weight: 700;
    color: var(--text-main);
    margin-bottom: 2px;
}
.hover-text p {
    font-size: 12px;
    color: var(--text-muted);
}

/* --- Sections Common --- */
.section {
    padding: 100px 0;
}
.section-header {
    text-align: center;
    margin-bottom: 60px;
}
.section-badge {
    display: inline-block;
    padding: 4px 12px;
    background: #f1f5f9;
    color: var(--text-muted);
    border-radius: 50px;
    font-size: 0.8rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 1px;
    margin-bottom: 16px;
    border: 1px solid var(--border);
}
.section-header h2 {
    font-size: 2.5rem;
    font-weight: 800;
    margin-bottom: 16px;
    letter-spacing: -0.5px;
}
.section-header p {
    font-size: 1.1rem;
    color: var(--text-secondary);
}

/* --- Core Features Section (Seneasy Alternating Layout) --- */
.feature-showcase {
    padding: 100px 0;
    background: #ffffff;
}
.feature-showcase .section-header {
    margin-bottom: 80px;
}
.feature-row {
    display: flex;
    align-items: center;
    gap: 80px;
    margin-bottom: 120px;
}
.feature-row:last-child {
    margin-bottom: 0;
}
.feature-row.reverse {
    flex-direction: row-reverse;
}
.feature-text {
    flex: 1;
    max-width: 480px;
}
.feature-text h3 {
    font-size: 2rem;
    font-weight: 800;
    margin-bottom: 16px;
    color: var(--text-main);
    line-height: 1.3;
}
.feature-text p {
    font-size: 1.1rem;
    color: var(--text-secondary);
    line-height: 1.7;
    margin-bottom: 24px;
}
.feature-list {
    list-style: none;
    padding: 0;
    margin: 0;
}
.feature-list li {
    position: relative;
    padding-left: 28px;
    margin-bottom: 12px;
    font-size: 1rem;
    color: var(--text-main);
}
.feature-list li::before {
    content: '\f00c';
    font-family: 'Font Awesome 6 Free';
    font-weight: 900;
    position: absolute;
    left: 0;
    top: 2px;
    color: var(--primary);
}

.feature-image-wrapper {
    flex: 1.2;
    position: relative;
}
.feature-image-card {
    background: white;
    border-radius: 24px;
    padding: 12px;
    box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.1);
    border: 1px solid var(--border);
    position: relative;
    z-index: 2;
    overflow: hidden;
}
.feature-image-card img {
    width: 100%;
    height: auto;
    border-radius: 16px;
    display: block;
}
.feature-decoration-bg {
    position: absolute;
    top: -20px;
    right: -20px;
    bottom: -20px;
    left: -20px;
    background: linear-gradient(135deg, #e0e7ff, #fce7f3);
    border-radius: 32px;
    z-index: 1;
    transform: rotate(3deg);
    opacity: 0.5;
}
.feature-row.reverse .feature-decoration-bg {
    transform: rotate(-3deg);
    background: linear-gradient(135deg, #dcfce7, #e0e7ff);
}

@media (max-width: 992px) {
    .feature-row, .feature-row.reverse {
        flex-direction: column;
        gap: 40px;
        text-align: center;
        margin-bottom: 80px;
    }
    .feature-text {
        max-width: 100%;
    }
    .feature-list li {
        text-align: left;
        display: inline-block;
        width: 100%;
    }
}

/* --- Themes Section (#themes) Carousel Seneasy Style --- */
.themes-section {
    padding: 100px 0;
    background: var(--bg-slate);
    overflow: hidden;
}

.carousel-container {
    position: relative;
    max-width: 1000px;
    margin: 0 auto;
    height: 550px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.carousel-track {
    position: relative;
    width: 100%;
    height: 100%;
    perspective: 1500px;
    transform-style: preserve-3d;
}

.carousel-slide {
    position: absolute;
    top: 50%;
    left: 50%;
    width: 300px;
    height: 440px;
    border-radius: 24px;
    background: white;
    box-shadow: 0 20px 40px -10px rgba(0,0,0,0.15);
    border: 1px solid var(--border);
    transition: all 0.6s cubic-bezier(0.25, 1, 0.5, 1);
    transform-origin: center center;
    overflow: hidden;
    cursor: pointer;
    /* Default state (hidden) */
    opacity: 0;
    transform: translate(-50%, -50%) scale(0.8) translateX(200px) rotateY(-20deg);
    z-index: 1;
}

/* Active Slide (Center) */
.carousel-slide.active {
    opacity: 1;
    transform: translate(-50%, -50%) scale(1.05) translateX(0) rotateY(0);
    z-index: 10;
    box-shadow: 0 30px 60px -12px rgba(79, 70, 229, 0.25);
    border-color: var(--primary);
}

/* Prev Slide (Left) */
.carousel-slide.prev {
    opacity: 0.7;
    transform: translate(-50%, -50%) scale(0.85) translateX(-200px) rotateY(15deg);
    z-index: 5;
}

/* Next Slide (Right) */
.carousel-slide.next {
    opacity: 0.7;
    transform: translate(-50%, -50%) scale(0.85) translateX(200px) rotateY(-15deg);
    z-index: 5;
}

.carousel-slide:hover {
    opacity: 1;
}

.slide-content {
    height: 100%;
    display: flex;
    flex-direction: column;
}
.slide-img-placeholder {
    height: 220px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--primary);
    font-size: 3rem;
}
.slide-text {
    padding: 24px;
    flex: 1;
    background: white;
}
.slide-text h3 {
    font-size: 1.25rem;
    font-weight: 800;
    margin-bottom: 8px;
    color: var(--text-main);
}
.slide-text p {
    font-size: 0.9rem;
    color: var(--text-secondary);
    line-height: 1.6;
}

.carousel-controls {
    display: flex;
    justify-content: center;
    gap: 16px;
    margin-top: 40px;
}
.control-btn {
    width: 48px;
    height: 48px;
    border-radius: 50%;
    background: white;
    border: 1px solid var(--border);
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--text-main);
    cursor: pointer;
    transition: all 0.2s;
    box-shadow: 0 4px 6px rgba(0,0,0,0.05);
}
.control-btn:hover {
    background: var(--primary);
    color: white;
    border-color: var(--primary);
    transform: scale(1.1);
}

/* --- Marquee / News Section --- */
.bg-grid-pattern {
    position: absolute;
    inset: 0;
    background-image: radial-gradient(#e2e8f0 1px, transparent 1px);
    background-size: 24px 24px;
    opacity: 0.4;
}

.marquee-wrapper {
    position: relative;
    width: 100%;
    overflow: hidden;
    padding: 20px 0;
}
.marquee-wrapper::before,
.marquee-wrapper::after {
    content: "";
    position: absolute;
    top: 0;
    width: 15%;
    height: 100%;
    z-index: 2;
    pointer-events: none;
}
.marquee-wrapper::before {
    left: 0;
    background: linear-gradient(to right, white, transparent);
}
.marquee-wrapper::after {
    right: 0;
    background: linear-gradient(to left, white, transparent);
}

.marquee-content {
    display: flex;
    gap: 24px;
    width: max-content;
    animation: marquee 20s linear infinite;
}
.marquee-wrapper:hover .marquee-content {
    animation-play-state: paused;
}

@keyframes marquee {
    0% { transform: translateX(0); }
    100% { transform: translateX(calc(-50% - 12px)); }
}

.news-card {
    display: block;
    width: 400px;
    padding: 24px;
    background: white;
    border-radius: var(--radius-lg);
    border: 1px solid var(--border);
    text-decoration: none;
    color: var(--text-main);
    transition: all 0.3s;
}
.news-card:hover {
    border-color: var(--primary);
    box-shadow: 0 10px 25px -5px rgba(79, 70, 229, 0.1);
}
.news-meta {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 16px;
}
.news-tag {
    font-size: 0.75rem;
    font-weight: 700;
    padding: 4px 8px;
    border-radius: 4px;
    background: #e0e7ff;
    color: var(--primary);
}
.news-tag.text-pink { background: #fce7f3; color: #db2777; }
.news-tag.text-green { background: #dcfce7; color: #059669; }
.news-date {
    font-size: 0.8rem;
    color: var(--text-muted);
}
.news-title {
    font-size: 1.15rem;
    font-weight: 700;
    margin-bottom: 12px;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}
.news-desc {
    font-size: 0.9rem;
    color: var(--text-secondary);
    margin-bottom: 16px;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}
.news-link {
    font-size: 0.9rem;
    font-weight: 600;
    color: var(--text-main);
    display: flex;
    align-items: center;
    gap: 8px;
}
.news-card:hover .news-link {
    color: var(--primary);
}
.news-link i {
    transition: transform 0.2s;
}
.news-card:hover .news-link i {
    transform: translateX(4px);
}

/* --- FAQ Section --- */
.max-w-3xl { max-width: 800px; margin: 0 auto; }
.faq-list {
    display: flex;
    flex-direction: column;
    gap: 16px;
}
.faq-item {
    background: white;
    border: 1px solid var(--border);
    border-radius: 12px;
    overflow: hidden;
}
.faq-question {
    width: 100%;
    text-align: left;
    padding: 20px 24px;
    background: none;
    border: none;
    font-size: 1.1rem;
    font-weight: 600;
    color: var(--text-main);
    cursor: pointer;
    display: flex;
    justify-content: space-between;
    align-items: center;
}
.faq-question i {
    color: var(--text-muted);
    transition: transform 0.3s;
}
.faq-answer {
    padding: 0 24px;
    max-height: 0;
    overflow: hidden;
    transition: all 0.3s ease;
    color: var(--text-secondary);
}
.faq-item.active .faq-question i {
    transform: rotate(180deg);
}
.faq-item.active .faq-answer {
    padding: 0 24px 24px;
    max-height: 500px;
}

/* --- CTA Section --- */
.cta-section {
    background: #0f172a;
    color: white;
    text-align: center;
    padding: 100px 20px;
    margin: 60px 24px;
    border-radius: var(--radius-xl);
}
.cta-section h2 {
    font-size: 2.5rem;
    font-weight: 800;
    margin-bottom: 20px;
}
.cta-section p {
    font-size: 1.2rem;
    color: #94a3b8;
    margin-bottom: 40px;
}

/* --- Footer --- */
.footer {
    background: white;
    padding: 80px 0 40px;
    border-top: 1px solid var(--border);
}
.footer-content {
    display: flex;
    justify-content: space-between;
    flex-wrap: wrap;
    gap: 60px;
    margin-bottom: 60px;
}
.footer-links-group {
    display: flex;
    gap: 80px;
}
.footer-col h4 {
    font-size: 1rem;
    font-weight: 700;
    margin-bottom: 24px;
}
.footer-col a {
    display: block;
    text-decoration: none;
    color: var(--text-secondary);
    margin-bottom: 12px;
    transition: color 0.2s;
}
.footer-col a:hover {
    color: var(--primary);
}
.footer-bottom {
    border-top: 1px solid var(--border);
    padding-top: 24px;
    text-align: center;
    color: var(--text-muted);
    font-size: 0.9rem;
}

/* Responsive */
@media (max-width: 768px) {
    .nav-container { flex-wrap: wrap; padding: 12px 16px; }
    .nav-links { 
        display: flex; 
        order: 3; 
        width: 100%; 
        justify-content: center; 
        gap: 15px; 
        margin-top: 12px; 
        padding-top: 12px;
        border-top: 1px solid rgba(226, 232, 240, 0.6);
    }
    .nav-links a { font-size: 0.85rem; }
    .hero h1 { font-size: 2.5rem; }
    .hero p { font-size: 1rem; padding: 0 10px; }
    .mockup-body { flex-direction: column; height: auto; }
    .mockup-sidebar { width: 100%; border-right: none; border-bottom: 1px solid var(--border); }
    .phone-frame { width: 100%; border-radius: 20px; box-shadow: none; border: 4px solid #0f172a; }
    .cta-section { margin: 40px 16px; padding: 60px 20px; }
    .footer-links-group { flex-direction: column; gap: 40px; }
    
    /* Navbar tweaks for mobile */
    .nav-actions { gap: 10px; }
    .btn-secondary { display: none; } /* Hide login button, keep register or vice versa to save space */
    .brand-logo { font-size: 1rem; }
    
    /* Pricing Page Mobile Adaptation */
    .pricing-hero { padding: 100px 16px 40px; }
    .pricing-hero h1 { font-size: 2.2rem; }
    .pricing-container { padding: 0 16px; gap: 20px; }
    .pricing-card { width: 100%; padding: 30px 20px; }
    .pricing-card.featured { transform: scale(1); border-width: 2px; }
    .pricing-card.featured:hover { transform: translateY(-4px); }
    .plan-price { font-size: 2.8rem; }
    
    /* Carousel mobile fix */
    .carousel-slide { width: 260px; height: 400px; }
    .carousel-slide.prev { transform: translate(-50%, -50%) scale(0.85) translateX(-120px) rotateY(15deg); }
    .carousel-slide.next { transform: translate(-50%, -50%) scale(0.85) translateX(120px) rotateY(-15deg); }
}

/* --- Animations & Effects --- */
.reveal {
    opacity: 0;
    transform: translateY(40px);
    transition: opacity 0.8s cubic-bezier(0.16, 1, 0.3, 1), transform 0.8s cubic-bezier(0.16, 1, 0.3, 1);
}
.reveal.active {
    opacity: 1;
    transform: translateY(0);
}
.delay-100 { transition-delay: 100ms; }
.delay-200 { transition-delay: 200ms; }
.delay-300 { transition-delay: 300ms; }
.delay-400 { transition-delay: 400ms; }
.delay-500 { transition-delay: 500ms; }
.delay-600 { transition-delay: 600ms; }

@keyframes float {
    0% { transform: translateY(0px); }
    50% { transform: translateY(-15px); }
    100% { transform: translateY(0px); }
}
.floating {
    animation: float 6s ease-in-out infinite;
}

@keyframes shimmer {
    0% { background-position: 200% 0; }
    100% { background-position: -200% 0; }
}
.skeleton-shimmer {
    background: linear-gradient(90deg, #f1f5f9 25%, #e2e8f0 50%, #f1f5f9 75%);
    background-size: 200% 100%;
    animation: shimmer 2s infinite linear;
}

.mockup-btn {
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    cursor: pointer;
}
.mockup-btn:hover {
    transform: scale(1.02);
    box-shadow: 0 8px 20px rgba(236, 72, 153, 0.4);
}

.preview-img i {
    animation: float 4s ease-in-out infinite;
}