/* Modern Homepage Styles */

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

:root {
    --primary: #6366f1;
    --primary-dark: #4f46e5;
    --secondary: #8b5cf6;
    --accent: #ec4899;
    --bg-dark: #0f172a;
    --bg-darker: #020617;
    --card-bg: rgba(30, 41, 59, 0.6);
    --text-primary: #f1f5f9;
    --text-secondary: #94a3b8;
    --border: rgba(148, 163, 184, 0.1);
    --success: #10b981;
    --danger: #ef4444;
}

body {
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
    background: var(--bg-darker);
    color: var(--text-primary);
    line-height: 1.6;
    overflow-x: hidden;
}

/* Animated Background */
.bg-animation {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: -1;
    background:
        radial-gradient(ellipse at 20% 30%, rgba(99, 102, 241, 0.15) 0%, transparent 50%),
        radial-gradient(ellipse at 80% 70%, rgba(139, 92, 246, 0.15) 0%, transparent 50%),
        radial-gradient(ellipse at 50% 50%, rgba(236, 72, 153, 0.1) 0%, transparent 50%);
    animation: bgShift 15s ease-in-out infinite;
}

@keyframes bgShift {
    0%, 100% { transform: scale(1) rotate(0deg); }
    50% { transform: scale(1.1) rotate(5deg); }
}

/* Modern Header */
.modern-header {
    position: sticky;
    top: 0;
    z-index: 1000;
    backdrop-filter: blur(20px);
    background: rgba(15, 23, 42, 0.8);
    border-bottom: 1px solid var(--border);
}

.header-content {
    max-width: 1400px;
    margin: 0 auto;
    padding: 1rem 2rem;
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 2rem;
    flex-wrap: wrap;
}

.logo-modern {
    display: flex;
    align-items: center;
    text-decoration: none;
}

.logo-modern img {
    height: 50px;
    width: auto;
}

.search-bar-modern {
    flex: 1;
    max-width: 500px;
    position: relative;
    min-width: 250px;
}

.search-bar-modern input {
    width: 100%;
    padding: 0.75rem 3rem 0.75rem 1.25rem;
    background: var(--card-bg);
    border: 1px solid var(--border);
    border-radius: 50px;
    color: var(--text-primary);
    font-size: 0.95rem;
    transition: all 0.3s ease;
}

.search-bar-modern input:focus {
    outline: none;
    border-color: var(--primary);
    box-shadow: 0 0 0 3px rgba(99, 102, 241, 0.1);
}

.search-bar-modern::after {
    content: "🔍";
    position: absolute;
    right: 1.25rem;
    top: 50%;
    transform: translateY(-50%);
}

/* Navigation */
.nav-modern {
    display: flex;
    gap: 0.5rem;
    align-items: center;
}

.nav-modern a {
    padding: 0.75rem 1.5rem;
    color: var(--text-secondary);
    text-decoration: none;
    font-weight: 600;
    font-size: 0.9rem;
    white-space: nowrap;
    transition: all 0.3s ease;
    border-radius: 20px;
}

.nav-modern a:hover,
.nav-modern a.active {
    color: var(--text-primary);
    background: var(--card-bg);
}

.nav-modern a.cta {
    background: linear-gradient(135deg, var(--primary), var(--secondary));
    color: white;
}

.nav-modern a.cta:hover {
    transform: translateY(-2px);
    box-shadow: 0 5px 15px rgba(99, 102, 241, 0.4);
}

/* Mobile menu toggle */
.menu-toggle {
    display: none;
    background: var(--card-bg);
    border: 1px solid var(--border);
    color: var(--text-primary);
    padding: 0.75rem 1rem;
    border-radius: 8px;
    cursor: pointer;
    font-size: 1.2rem;
}

/* Main Container */
.container-modern {
    max-width: 1400px;
    margin: 0 auto;
    padding: 2rem;
}

/* Hero Section */
.hero-section {
    display: grid;
    grid-template-columns: 2fr 1fr;
    gap: 2rem;
    margin-bottom: 3rem;
}

.featured-card {
    background: var(--card-bg);
    backdrop-filter: blur(10px);
    border-radius: 24px;
    padding: 2rem;
    border: 1px solid var(--border);
    transition: all 0.4s ease;
    position: relative;
    overflow: hidden;
}

.featured-card::before {
    content: "";
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: linear-gradient(135deg, rgba(99, 102, 241, 0.1), transparent);
    opacity: 0;
    transition: opacity 0.4s ease;
    pointer-events: none;
}

.featured-card:hover::before {
    opacity: 1;
}

.featured-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.3);
    border-color: var(--primary);
}

.featured-image {
    width: 100%;
    height: 300px;
    object-fit: cover;
    border-radius: 16px;
    margin-bottom: 1.5rem;
}

.card-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 1rem;
    padding: 0 ;
}

.category-badge {
    display: inline-block;
    padding: 0.4rem 1rem;
    background: linear-gradient(135deg, var(--primary), var(--secondary));
    color: white;
    border-radius: 20px;
    font-size: 0.75rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.time-ago {
    color: var(--text-secondary);
    font-size: 0.85rem;
    font-weight: 500;
}

.featured-card h2 {
    font-size: 1.8rem;
    margin-bottom: 1rem;
    line-height: 1.3;
    font-weight: 800;
    color: var(--text-primary);
}

.featured-card p {
    color: var(--text-secondary);
    margin-bottom: 1.5rem;
    font-size: 1.05rem;
}

.read-more {
    padding: 0.6rem 1.5rem;
    background: linear-gradient(135deg, var(--primary), var(--secondary));
    color: white;
    text-decoration: none;
    border-radius: 20px;
    font-weight: 600;
    font-size: 0.9rem;
    transition: all 0.3s ease;
    display: inline-block;
}

.read-more:hover {
    transform: translateX(5px);
    box-shadow: 0 5px 15px rgba(99, 102, 241, 0.4);
    color: white;
}

/* App Promo Sidebar */
.app-promo-sidebar {
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

.app-promo-card {
    background: linear-gradient(135deg, var(--primary), var(--secondary));
    backdrop-filter: blur(10px);
    border-radius: 24px;
    padding: 2rem;
    border: 1px solid var(--border);
    text-align: center;
    color: white;
}

.app-promo-card h3 {
    font-size: 1.4rem;
    margin-bottom: 1rem;
    font-weight: 800;
}

.app-promo-card p {
    margin-bottom: 1.5rem;
    font-size: 0.95rem;
    opacity: 0.9;
}

.app-download-btn {
    display: inline-block;
    padding: 0.75rem 1.5rem;
    background: white;
    color: var(--primary);
    text-decoration: none;
    border-radius: 20px;
    font-weight: 700;
    font-size: 0.9rem;
    transition: all 0.3s ease;
}

.app-download-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 5px 15px rgba(255, 255, 255, 0.3);
    color: var(--primary);
}

/* News Grid */
.section-title {
    font-size: 2rem;
    font-weight: 800;
    margin-bottom: 2rem;
    display: flex;
    align-items: center;
    gap: 1rem;
}

.section-title::after {
    content: "";
    flex: 1;
    height: 2px;
    background: linear-gradient(90deg, var(--primary), transparent);
}

/* News Section Component */
.news-section-component {
    margin-bottom: 4rem;
}

.news-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(350px, 1fr));
    gap: 2rem;
    margin-bottom: 3rem;
}

.news-card {
    background: var(--card-bg);
    backdrop-filter: blur(10px);
    border-radius: 20px;
    padding: 0;
    border: 1px solid var(--border);
    transition: all 0.4s ease;
    display: flex;
    flex-direction: column;
    overflow: hidden;
}

.news-card:hover {
    transform: translateY(-8px);
    box-shadow: 0 15px 30px rgba(0, 0, 0, 0.3);
    border-color: var(--primary);
}

.news-card-image {
    width: 100%;
    height: 200px;
    object-fit: cover;
}

.news-card-content {
    padding: 1.5rem;
    flex: 1;
    display: flex;
    flex-direction: column;
}

.news-card h3 {
    font-size: 1.2rem;
    margin-bottom: 0.75rem;
    line-height: 1.4;
    font-weight: 700;
    color: var(--text-primary);
}

.news-card h3 a {
    color: var(--text-primary);
    text-decoration: none;
    transition: color 0.3s ease;
}

.news-card h3 a:hover {
    color: var(--primary);
}

.news-excerpt {
    color: var(--text-secondary);
    font-size: 0.95rem;
    margin-bottom: 1rem;
    flex: 1;
}

.news-meta {
    display: flex;
    justify-content: space-between;
    align-items: center;
    font-size: 0.85rem;
    padding-top: 1rem;
    border-top: 1px solid var(--border);
}

/* View All Button */
.view-all-section {
    text-align: center;
    margin: 3rem 0;
}

.view-all-btn {
    padding: 1rem 3rem;
    background: linear-gradient(135deg, var(--primary), var(--secondary));
    color: white;
    text-decoration: none;
    border-radius: 50px;
    font-weight: 700;
    font-size: 1rem;
    display: inline-block;
    transition: all 0.3s ease;
}

.view-all-btn:hover {
    transform: scale(1.05);
    box-shadow: 0 10px 25px rgba(99, 102, 241, 0.4);
    color: white;
}

/* Responsive */
@media (max-width: 1024px) {
    .hero-section {
        grid-template-columns: 1fr;
    }

    .news-grid {
        grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
    }
}

@media (max-width: 768px) {
    .header-content {
        display: flex;
        flex-wrap: wrap;
        padding: 1rem;
        gap: 1rem;
        align-items: center;
    }

    /* Row 1: Logo centered, full width */
    .logo-modern {
        order: 1;
        flex: 1 1 100%;
        text-align: center;
        display: flex;
        justify-content: center;
    }

    /* Row 2: Search bar (left, full width minus hamburger space) */
    .search-bar-modern {
        order: 2;
        flex: 1 1 auto;
        max-width: calc(100% - 60px);
        min-width: 0;
        margin-top: 0;
    }

    /* Row 2: Hamburger menu (right side) */
    .menu-toggle {
        display: block;
        order: 3;
        flex: 0 0 auto;
        width: 50px;
        margin-left: 0;
        padding: 0.75rem 1rem;
    }

    /* Row 3: Navigation menu (toggles, hidden by default) */
    .nav-modern {
        order: 4;
        display: none;
        flex-direction: column;
        width: 100%;
        flex: 1 1 100%;
        gap: 0.5rem;
        margin-top: 0;
    }

    .nav-modern.active {
        display: flex;
    }

    .nav-modern a {
        width: 100%;
        text-align: center;
    }

    .news-grid {
        grid-template-columns: 1fr;
    }

    /* Featured Card Mobile Layout */
    .featured-card {
        padding: 0 !important;
        border-radius: 16px;
    }

    /* Image: Full width, no bottom radius */
    .featured-card .featured-image {
        width: 100%;
        height: 250px;
        border-radius: 16px 16px 0 0 !important;
        margin-bottom: 0 !important;
    }

    /* Card Header: Full width with minimal padding */
    .featured-card .card-header {
        padding: 0.75rem;
        margin-bottom: 0.5rem;
    }

    /* Title: 0.75rem horizontal padding */
    .featured-card h2 {
        padding: 0 0.75rem;
        margin-bottom: 0.75rem;
        font-size: 1.5rem;
    }

    /* Excerpt: 0.75rem horizontal padding */
    .featured-card p {
        padding: 0 0.75rem;
        margin-bottom: 1rem;
    }

    /* Read More Button: 0.75rem horizontal padding */
    .featured-card .read-more {
        margin: 0 0.75rem 0.75rem 0.75rem;
    }
}

@media (max-width: 480px) {
    .header-content {
        padding: 0.75rem;
        gap: 0.75rem;
    }

    .logo-modern img {
        height: 40px;
    }

    .search-bar-modern {
        max-width: calc(100% - 55px);
    }

    .search-bar-modern input {
        padding: 0.6rem 2.5rem 0.6rem 1rem;
        font-size: 0.9rem;
    }

    .menu-toggle {
        width: 45px;
        padding: 0.6rem 0.85rem;
        font-size: 1rem;
    }
}

/* Legacy compatibility - hide old sections */
.header-area,
.main-banner,
.services,
.the-clients {
    display: none;
}

/* Footer Styling */
#footer {
    display: block;
    background: rgba(15, 23, 42, 0.8);
    backdrop-filter: blur(20px);
    border-top: 1px solid var(--border);
    padding: 3rem 0 2rem;
    margin-top: 5rem;
}

#footer .section-heading h4 {
    color: var(--text-primary);
    font-size: 1.5rem;
    font-weight: 700;
    margin-bottom: 2rem;
    text-align: center;
}

#footer #search {
    margin-bottom: 3rem;
}

#footer #search .email {
    background: var(--card-bg);
    border: 1px solid var(--border);
    border-radius: 12px;
    padding: 1rem 1.25rem;
    color: var(--text-primary);
    font-size: 0.95rem;
    width: 100%;
    transition: all 0.3s ease;
}

#footer #search .email:focus {
    outline: none;
    border-color: var(--primary);
    box-shadow: 0 0 0 3px rgba(99, 102, 241, 0.1);
}

#footer #search .main-button {
    width: 100%;
    padding: 1rem 1.5rem;
    background: linear-gradient(135deg, var(--primary), var(--secondary));
    color: white;
    border: none;
    border-radius: 12px;
    font-weight: 600;
    font-size: 0.95rem;
    cursor: pointer;
    transition: all 0.3s ease;
}

#footer #search .main-button:hover {
    transform: translateY(-2px);
    box-shadow: 0 5px 15px rgba(99, 102, 241, 0.4);
}

#footer .footer-widget {
    margin-bottom: 2rem;
}

#footer .footer-widget h4 {
    color: var(--primary);
    font-size: 1.2rem;
    font-weight: 700;
    margin-bottom: 1.5rem;
}

#footer .footer-widget ul {
    list-style: none;
    padding: 0;
    margin: 0;
}

#footer .footer-widget ul li {
    margin-bottom: 0.75rem;
}

#footer .footer-widget ul li a {
    color: var(--text-secondary);
    text-decoration: none;
    font-size: 0.95rem;
    transition: all 0.3s ease;
    display: inline-block;
}

#footer .footer-widget ul li a:hover {
    color: var(--primary);
    padding-left: 0.5rem;
}

#footer .footer-widget .logo {
    margin-bottom: 1rem;
}

#footer .footer-widget .logo img {
    max-width: 100px;
    height: auto;
}

#footer .footer-widget p {
    color: var(--text-secondary);
    font-size: 0.9rem;
    line-height: 1.6;
}

#footer .copyright-text {
    text-align: center;
    padding-top: 2rem;
    border-top: 1px solid var(--border);
}

#footer .copyright-text p {
    color: var(--text-secondary);
    font-size: 0.85rem;
    margin: 0;
}

#footer .copyright-text a {
    color: var(--text-primary);
    transition: color 0.3s ease;
}

#footer .copyright-text a:hover {
    color: var(--primary);
}
