/* ============================================
   LearnHub Community - Landing Page Styles
   Colors: #4F46E5 (Indigo), #10B981 (Emerald), #EEF2FF (Light Indigo)
   Font: Montserrat
   ============================================ */

/* CSS Variables */
:root {
    --color-primary: #4F46E5;
    --color-accent: #10B981;
    --color-bg: #EEF2FF;
    --color-dark: #1E1B4B;
    --color-light: #FFFFFF;
    --color-text: #334155;
    --color-text-light: #64748B;
    --color-success: #22C55E;
    --color-warning: #F59E0B;
    
    --font-main: 'Montserrat', sans-serif;
    
    --shadow-sm: 0 2px 8px rgba(79, 70, 229, 0.08);
    --shadow-md: 0 4px 20px rgba(79, 70, 229, 0.12);
    --shadow-lg: 0 10px 40px rgba(79, 70, 229, 0.16);
    
    --transition: all 0.3s ease;
}

/* Reset & Base */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
}

body {
    font-family: var(--font-main);
    color: var(--color-text);
    line-height: 1.6;
    background-color: var(--color-bg);
    overflow-x: hidden;
    padding-bottom: 80px;
}

.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
}

/* Typography */
h1, h2, h3, h4, h5, h6 {
    font-weight: 700;
    line-height: 1.2;
    color: var(--color-primary);
}

.text-accent {
    color: var(--color-accent);
}

/* ============================================
   Topic Ribbon
   ============================================ */
.topic-ribbon {
    background: linear-gradient(90deg, var(--color-dark), var(--color-primary));
    padding: 12px 0;
    overflow: hidden;
    position: relative;
}

.ribbon-wrap {
    width: 100%;
    overflow: hidden;
}

.ribbon-content {
    display: flex;
    animation: ribbonScroll 30s linear infinite;
    white-space: nowrap;
}

.ribbon-item {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 0 30px;
    font-size: 14px;
    font-weight: 600;
    color: rgba(255, 255, 255, 0.9);
}

.ribbon-item i {
    color: var(--color-accent);
    font-size: 16px;
}

@keyframes ribbonScroll {
    0% { transform: translateX(0); }
    100% { transform: translateX(-50%); }
}

/* ============================================
   Hero Section
   ============================================ */
.hero {
    background: url('../images/hero-bg.jpg') center / cover no-repeat;
    position: relative;
    overflow: hidden;
    padding-bottom: 0;
}

.hero::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: url('../images/hero-bg.jpg') center / cover no-repeat;
    opacity: 0.15;
    z-index: 0;
}

.hero::after {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: url('data:image/svg+xml,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 100 100"><circle cx="50" cy="50" r="1" fill="rgba(16,185,129,0.08)"/></svg>') repeat;
    background-size: 50px 50px;
    animation: dotFloat 20s ease-in-out infinite;
    z-index: 0;
}

@keyframes dotFloat {
    0%, 100% { transform: translateY(0); }
    50% { transform: translateY(-10px); }
}

.hero-container {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 60px;
    align-items: center;
    padding: 80px 20px 120px;
    max-width: 1200px;
    margin: 0 auto;
    position: relative;
    z-index: 1;
}

.hero-content {
    color: var(--color-light);
}

.hero-badge {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    background: rgba(16, 185, 129, 0.2);
    border: 1px solid var(--color-accent);
    color: var(--color-accent);
    padding: 8px 16px;
    border-radius: 50px;
    font-size: 14px;
    font-weight: 600;
    margin-bottom: 24px;
}

.hero h1 {
    font-size: 48px;
    font-weight: 800;
    color: var(--color-light);
    margin-bottom: 20px;
    line-height: 1.1;
}

.hero-subtitle {
    font-size: 18px;
    opacity: 0.9;
    margin-bottom: 30px;
    line-height: 1.7;
}

.hero-highlights {
    display: flex;
    flex-wrap: wrap;
    gap: 20px;
    margin-bottom: 30px;
}

.hero-highlight {
    display: flex;
    align-items: center;
    gap: 10px;
    font-size: 15px;
    font-weight: 500;
}

.hero-highlight i {
    color: var(--color-accent);
    font-size: 18px;
}

.hero-stats {
    display: flex;
    gap: 40px;
    margin-top: 40px;
    padding-top: 30px;
    border-top: 1px solid rgba(255, 255, 255, 0.2);
}

.stat-item {
    display: flex;
    flex-direction: column;
}

.stat-number {
    font-size: 28px;
    font-weight: 800;
    color: var(--color-accent);
}

.stat-label {
    font-size: 14px;
    opacity: 0.8;
}

/* Hero Image */
.hero-image {
    position: relative;
}

.hero-visual-wrapper {
    position: relative;
    width: 100%;
    height: 450px;
    background: linear-gradient(135deg, rgba(16, 185, 129, 0.1), rgba(79, 70, 229, 0.3));
    border-radius: 20px;
    border: 2px solid rgba(16, 185, 129, 0.3);
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
}

.hero-visual-wrapper img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.hero-visual-wrapper::before {
    content: '';
    position: absolute;
    inset: 0;
    background: radial-gradient(circle at center, transparent 0%, rgba(30, 27, 75, 0.3) 100%);
    z-index: 1;
}

/* Floating Cards */
.float-card {
    position: absolute;
    background: var(--color-light);
    padding: 15px 20px;
    border-radius: 12px;
    box-shadow: var(--shadow-lg);
    display: flex;
    align-items: center;
    gap: 12px;
    z-index: 10;
    animation: cardBob 3s ease-in-out infinite;
}

.float-card i {
    font-size: 24px;
    color: var(--color-accent);
}

.float-card .float-card-title {
    display: block;
    font-size: 12px;
    color: var(--color-text-light);
}

.float-card .float-card-value {
    display: block;
    font-size: 18px;
    font-weight: 700;
    color: var(--color-primary);
}

.float-card-left {
    top: 20%;
    left: -20px;
    animation-delay: 0s;
}

.float-card-right {
    bottom: 20%;
    right: -20px;
    animation-delay: 1.5s;
}

@keyframes cardBob {
    0%, 100% { transform: translateY(0); }
    50% { transform: translateY(-10px); }
}

.hero-wave {
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    z-index: 2;
}

.hero-wave svg {
    display: block;
    width: 100%;
    height: 80px;
}

/* ============================================
   CTA Button
   ============================================ */
.cta-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 12px;
    background: linear-gradient(135deg, var(--color-accent), #059669);
    color: var(--color-light);
    font-family: var(--font-main);
    font-size: 16px;
    font-weight: 700;
    padding: 16px 32px;
    border: none;
    border-radius: 50px;
    cursor: pointer;
    transition: var(--transition);
    box-shadow: 0 4px 15px rgba(16, 185, 129, 0.4);
}

.cta-btn:hover {
    transform: translateY(-2px) scale(1.02);
    box-shadow: 0 8px 25px rgba(16, 185, 129, 0.5);
}

.cta-btn .btn-icon {
    width: 24px;
    height: 24px;
    object-fit: contain;
}

.cta-lg {
    font-size: 18px;
    padding: 20px 40px;
}

/* Pulse Animation */
.pulse-animation {
    animation: btnPulse 1.5s ease-in-out infinite;
}

@keyframes btnPulse {
    0%, 100% {
        transform: scale(1);
        box-shadow: 0 4px 15px rgba(16, 185, 129, 0.4);
    }
    50% {
        transform: scale(1.05);
        box-shadow: 0 8px 30px rgba(16, 185, 129, 0.6);
    }
}

.pulse-animation:hover {
    animation: btnPulseHover 0.3s ease forwards;
}

@keyframes btnPulseHover {
    to {
        transform: scale(1.08);
        box-shadow: 0 10px 35px rgba(16, 185, 129, 0.7);
    }
}

/* ============================================
   Top Banner
   ============================================ */
.top-banner {
    background: linear-gradient(90deg, var(--color-primary), #7C3AED);
    padding: 12px 20px;
    text-align: center;
    animation: bannerGlow 2s ease-in-out infinite;
}

@keyframes bannerGlow {
    0%, 100% { background: linear-gradient(90deg, var(--color-primary), #7C3AED); }
    50% { background: linear-gradient(90deg, #7C3AED, var(--color-primary)); }
}

.banner-content {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 15px;
    color: var(--color-light);
    font-size: 15px;
    font-weight: 600;
}

.banner-content i {
    color: var(--color-warning);
    animation: fireFlicker 0.5s ease-in-out infinite alternate;
}

@keyframes fireFlicker {
    from { opacity: 0.7; transform: scale(1); }
    to { opacity: 1; transform: scale(1.2); }
}

/* Hero Activity Counter */
.hero-activity {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    background: rgba(34, 197, 94, 0.2);
    border: 1px solid var(--color-success);
    color: var(--color-success);
    padding: 10px 20px;
    border-radius: 50px;
    font-size: 14px;
    font-weight: 600;
    margin-top: 25px;
}

.hero-activity i {
    animation: blink 1s ease-in-out infinite;
}

@keyframes blink {
    0%, 100% { opacity: 1; }
    50% { opacity: 0.5; }
}

/* Action Section Urgency */
.action-urgency {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    background: linear-gradient(90deg, var(--color-primary), #7C3AED);
    color: var(--color-light);
    padding: 12px 25px;
    border-radius: 50px;
    font-size: 15px;
    font-weight: 700;
    margin-bottom: 25px;
    animation: gentleShake 3s ease-in-out infinite;
}

@keyframes gentleShake {
    0%, 100% { transform: translateX(0); }
    5%, 15% { transform: translateX(-3px); }
    10%, 20% { transform: translateX(3px); }
    25% { transform: translateX(0); }
}

/* ============================================
   Perks Section
   ============================================ */
.perks {
    padding: 100px 0;
    background: var(--color-bg);
}

.section-header {
    text-align: center;
    max-width: 700px;
    margin: 0 auto 60px;
}

.section-tag {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    background: var(--color-primary);
    color: var(--color-light);
    padding: 8px 20px;
    border-radius: 50px;
    font-size: 13px;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 1px;
    margin-bottom: 20px;
}

.section-header h2 {
    font-size: 40px;
    margin-bottom: 15px;
}

.section-header p {
    color: var(--color-text-light);
    font-size: 17px;
}

.perks-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 30px;
}

.perk-card {
    background: var(--color-light);
    padding: 40px 30px;
    border-radius: 16px;
    text-align: center;
    transition: var(--transition);
    border: 2px solid transparent;
}

.perk-card:hover {
    transform: translateY(-5px);
    box-shadow: var(--shadow-lg);
    border-color: var(--color-accent);
}

.perk-icon {
    width: 70px;
    height: 70px;
    background: linear-gradient(135deg, var(--color-primary), var(--color-dark));
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 25px;
}

.perk-icon i {
    font-size: 28px;
    color: var(--color-accent);
}

.perk-card h3 {
    font-size: 20px;
    margin-bottom: 12px;
}

.perk-card p {
    color: var(--color-text-light);
    font-size: 15px;
    line-height: 1.7;
}

/* ============================================
   Showcase Sections
   ============================================ */
.showcase-section {
    padding: 100px 0;
    background: var(--color-bg);
}

.showcase-section.alt-bg {
    background: var(--color-light);
}

.showcase-row {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 80px;
    align-items: center;
}

.showcase-row.reverse {
    direction: rtl;
}

.showcase-row.reverse > * {
    direction: ltr;
}

.showcase-image {
    position: relative;
}

.showcase-image img {
    width: 100%;
    height: 400px;
    object-fit: cover;
    border-radius: 20px;
    box-shadow: var(--shadow-lg);
}

.showcase-image.placeholder {
    background: linear-gradient(135deg, var(--color-primary), var(--color-dark));
    height: 400px;
    border-radius: 20px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.showcase-image.placeholder::after {
    content: 'Image placeholder';
    color: rgba(255, 255, 255, 0.5);
    font-size: 14px;
}

.image-accent {
    position: absolute;
    width: 100%;
    height: 100%;
    background: var(--color-accent);
    border-radius: 20px;
    top: 20px;
    left: 20px;
    z-index: -1;
    opacity: 0.2;
}

.showcase-content h2 {
    font-size: 36px;
    margin-bottom: 20px;
}

.showcase-content > p {
    color: var(--color-text-light);
    font-size: 16px;
    margin-bottom: 25px;
}

.showcase-list {
    list-style: none;
    margin-bottom: 30px;
}

.showcase-list li {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 10px 0;
    font-size: 15px;
    color: var(--color-text);
}

.showcase-list i {
    color: var(--color-accent);
    font-size: 18px;
}

/* ============================================
   Reviews Section
   ============================================ */
.reviews {
    padding: 100px 0;
    background: linear-gradient(135deg, var(--color-primary), var(--color-dark));
}

.reviews .section-header h2,
.reviews .section-header p {
    color: var(--color-light);
}

.reviews .section-tag {
    background: rgba(16, 185, 129, 0.2);
    border: 1px solid var(--color-accent);
    color: var(--color-accent);
}

.reviews-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 30px;
}

.review-card {
    background: var(--color-light);
    padding: 35px;
    border-radius: 16px;
    transition: var(--transition);
}

.review-card:hover {
    transform: translateY(-5px);
    box-shadow: var(--shadow-lg);
}

.review-rating {
    margin-bottom: 15px;
}

.review-rating i {
    color: var(--color-warning);
    font-size: 16px;
}

.review-text {
    font-size: 15px;
    line-height: 1.8;
    color: var(--color-text);
    margin-bottom: 25px;
    font-style: italic;
}

.review-author {
    display: flex;
    align-items: center;
    gap: 15px;
}

.author-avatar {
    width: 50px;
    height: 50px;
    background: var(--color-primary);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
}

.author-avatar i {
    color: var(--color-accent);
    font-size: 20px;
}

.author-name {
    display: block;
    font-weight: 600;
    color: var(--color-primary);
}

.author-role {
    font-size: 13px;
    color: var(--color-text-light);
}

/* ============================================
   Action Section
   ============================================ */
.action-section {
    padding: 100px 0;
    background: var(--color-bg);
}

.action-content {
    text-align: center;
    max-width: 700px;
    margin: 0 auto;
}

.action-content h2 {
    font-size: 40px;
    margin-bottom: 20px;
}

.action-content p {
    font-size: 17px;
    color: var(--color-text-light);
    margin-bottom: 30px;
}

.action-note {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    margin-top: 20px;
    font-size: 14px;
    color: var(--color-text-light);
}

.action-note i {
    color: var(--color-success);
}

/* ============================================
   Footer
   ============================================ */
.site-footer {
    background: var(--color-dark);
    color: var(--color-light);
    padding: 60px 0 40px;
}

.footer-content {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding-bottom: 30px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
    margin-bottom: 30px;
}

.footer-brand h3 {
    color: var(--color-light);
    font-size: 22px;
    margin-bottom: 10px;
}

.footer-brand h3 i {
    color: var(--color-accent);
    margin-right: 10px;
}

.footer-brand p {
    font-size: 14px;
    opacity: 0.7;
}

.footer-links {
    display: flex;
    gap: 30px;
}

.footer-links a {
    color: var(--color-light);
    text-decoration: none;
    font-size: 14px;
    opacity: 0.7;
    transition: var(--transition);
}

.footer-links a:hover {
    opacity: 1;
    color: var(--color-accent);
}

.footer-bottom {
    text-align: center;
}

.footer-bottom p {
    font-size: 14px;
    opacity: 0.7;
}

.footer-note {
    font-size: 12px;
    margin-top: 15px;
    opacity: 0.5;
    max-width: 800px;
    margin-left: auto;
    margin-right: auto;
}

/* ============================================
   Fixed Bottom CTA
   ============================================ */
.fixed-cta {
    position: fixed;
    bottom: 0;
    left: 0;
    right: 0;
    background: rgba(30, 27, 75, 0.95);
    backdrop-filter: blur(10px);
    padding: 15px 20px;
    z-index: 1000;
    display: flex;
    justify-content: center;
    box-shadow: 0 -4px 20px rgba(0, 0, 0, 0.2);
}

.fixed-cta-btn {
    max-width: 350px;
    width: 100%;
}

/* ============================================
   Notification Bubbles
   ============================================ */
#notification-container {
    position: fixed;
    bottom: 100px;
    left: 20px;
    z-index: 999;
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.notification {
    background: var(--color-light);
    padding: 12px 20px;
    border-radius: 50px;
    box-shadow: var(--shadow-md);
    display: flex;
    align-items: center;
    gap: 12px;
    animation: notifSlideIn 0.5s ease, notifFadeOut 0.5s ease 4s forwards;
    max-width: 300px;
}

.notification-avatar {
    width: 35px;
    height: 35px;
    background: var(--color-primary);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
}

.notification-avatar i {
    color: var(--color-accent);
    font-size: 14px;
}

.notification-text {
    font-size: 13px;
    color: var(--color-text);
}

.notification-text strong {
    color: var(--color-primary);
}

@keyframes notifSlideIn {
    from {
        opacity: 0;
        transform: translateX(-100px);
    }
    to {
        opacity: 1;
        transform: translateX(0);
    }
}

@keyframes notifFadeOut {
    to {
        opacity: 0;
        transform: translateX(-50px);
    }
}

/* ============================================
   Responsive Design
   ============================================ */
@media (max-width: 1024px) {
    .hero-container {
        grid-template-columns: 1fr;
        text-align: center;
        padding: 60px 20px 100px;
    }
    
    .hero-highlights {
        justify-content: center;
    }
    
    .hero-stats {
        justify-content: center;
    }
    
    .hero-image {
        display: none;
    }
    
    .perks-grid {
        grid-template-columns: repeat(2, 1fr);
    }
    
    .showcase-row,
    .showcase-row.reverse {
        grid-template-columns: 1fr;
        gap: 40px;
        direction: ltr;
    }
    
    .reviews-grid {
        grid-template-columns: 1fr;
    }
}

@media (max-width: 768px) {
    .hero h1 {
        font-size: 32px;
    }
    
    .hero-subtitle {
        font-size: 16px;
    }
    
    .hero-highlights {
        flex-direction: column;
        align-items: center;
        gap: 15px;
    }
    
    .hero-stats {
        flex-direction: column;
        gap: 20px;
        align-items: center;
    }
    
    .perks-grid {
        grid-template-columns: 1fr;
    }
    
    .section-header h2 {
        font-size: 28px;
    }
    
    .showcase-content h2 {
        font-size: 28px;
    }
    
    .action-content h2 {
        font-size: 28px;
    }
    
    .footer-content {
        flex-direction: column;
        text-align: center;
        gap: 30px;
    }
    
    .footer-links {
        flex-direction: column;
        gap: 15px;
    }
    
    #notification-container {
        left: 10px;
        right: 10px;
        bottom: 90px;
    }
    
    .notification {
        max-width: 100%;
    }
    
    .ribbon-item {
        font-size: 12px;
        padding: 0 20px;
    }
}

@media (max-width: 480px) {
    .cta-btn {
        padding: 14px 24px;
        font-size: 14px;
    }
    
    .fixed-cta-btn {
        font-size: 14px;
        padding: 14px 24px;
    }
    
    .banner-content {
        font-size: 13px;
        gap: 10px;
    }
}

/* ============================================
   Modal Styles
   ============================================ */
.modal {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(30, 27, 75, 0.9);
    z-index: 2000;
    align-items: center;
    justify-content: center;
    padding: 20px;
    overflow-y: auto;
}

.modal.active {
    display: flex;
}

.modal-content {
    background: var(--color-light);
    border-radius: 20px;
    max-width: 700px;
    width: 100%;
    max-height: 90vh;
    overflow-y: auto;
    position: relative;
    animation: modalSlideIn 0.3s ease;
}

@keyframes modalSlideIn {
    from {
        opacity: 0;
        transform: translateY(-50px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.modal-content h2 {
    padding: 25px 30px;
    margin: 0;
    border-bottom: 2px solid var(--color-bg);
    display: flex;
    align-items: center;
    gap: 12px;
    font-size: 24px;
}

.modal-content h2 i {
    color: var(--color-accent);
}

.modal-close {
    position: absolute;
    top: 20px;
    right: 25px;
    font-size: 30px;
    color: var(--color-text-light);
    cursor: pointer;
    transition: var(--transition);
    line-height: 1;
}

.modal-close:hover {
    color: var(--color-primary);
    transform: rotate(90deg);
}

.modal-body {
    padding: 30px;
}

.modal-body h3 {
    font-size: 18px;
    margin-bottom: 12px;
    color: var(--color-primary);
    border-left: 4px solid var(--color-accent);
    padding-left: 15px;
}

.modal-body h3:not(:first-child) {
    margin-top: 30px;
}

.modal-body p {
    color: var(--color-text);
    line-height: 1.8;
    margin-bottom: 15px;
}

.modal-body ul {
    list-style: none;
    margin-bottom: 20px;
}

.modal-body ul li {
    position: relative;
    padding-left: 25px;
    margin-bottom: 10px;
    color: var(--color-text);
    line-height: 1.7;
}

.modal-body ul li::before {
    content: '';
    position: absolute;
    left: 0;
    top: 10px;
    width: 8px;
    height: 8px;
    background: var(--color-accent);
    border-radius: 50%;
}

@media (max-width: 768px) {
    .modal-content {
        border-radius: 15px;
    }
    
    .modal-content h2 {
        font-size: 20px;
        padding: 20px;
    }
    
    .modal-body {
        padding: 20px;
    }
    
    .modal-body h3 {
        font-size: 16px;
    }
}
