@import url('https://fonts.googleapis.com/css2?family=Outfit:wght@300;400;500;600;700&display=swap');

:root {
    --primary-color: #e31e24;
    /* Technavious Red */
    --primary-gradient: linear-gradient(135deg, #e31e24 0%, #ff4d4d 100%);
    --primary-hover: #c41217;
    --bg-color: #f8fafc;
    --text-color: #111827;
    /* Darker for better contrast */
    --text-muted: #4b5563;
    --card-bg: #ffffff;
    --card-shadow: 0 10px 15px -3px rgba(0, 0, 0, 0.05), 0 4px 6px -2px rgba(0, 0, 0, 0.02);
    --border-color: #e5e7eb;
    /* Darker border for light theme */
    --header-bg: rgba(255, 255, 255, 0.95);
    --footer-bg: #f9fafb;
    /* Light theme footer */
    --footer-text: #1f2937;
    --transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

[data-theme="dark"] {
    --primary-color: #2dd4bf;
    /* Teal for dark mode */
    --primary-gradient: linear-gradient(135deg, #2dd4bf 0%, #38bdf8 100%);
    --bg-color: #020617;
    --text-color: #f8fafc;
    --text-muted: #94a3b8;
    --card-bg: #1e293b;
    --card-shadow: 0 10px 15px -3px rgb(0 0 0 / 0.5);
    --border-color: #334155;
    --header-bg: rgba(2, 6, 23, 0.8);
    --footer-bg: #0f172a;
    /* Dark theme footer */
    --footer-text: #f9fafb;
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Outfit', sans-serif;
    background-color: var(--bg-color);
    color: var(--text-color);
    line-height: 1.6;
    transition: background-color 0.5s ease, color 0.5s ease;
    overflow-x: hidden;
}

.container {
    max-width: 1280px;
    margin: 0 auto;
    padding: 0 24px;
}

/* Header & Glassmorphism */
header {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    background: var(--header-bg);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    z-index: 1000;
    border-bottom: 1px solid var(--border-color);
}

nav {
    display: flex;
    justify-content: space-between;
    align-items: center;
    height: 80px;
}

.logo img {
    height: 42px;
    /* Reduced from 54px for a sleeker look */
    transition: transform 0.3s ease;
    display: block;
}

.logo:hover img {
    transform: scale(1.05);
}

.nav-links {
    display: flex;
    gap: 32px;
    align-items: center;
    list-style: none;
}

.nav-item {
    position: relative;
    padding: 30px 0;
}

.nav-links a {
    font-weight: 500;
    font-size: 0.95rem;
    color: var(--text-color);
    transition: var(--transition);
    display: flex;
    align-items: center;
    gap: 4px;
}

.nav-links a:hover {
    color: var(--primary-color);
}

.dropdown-icon {
    width: 12px;
    height: 12px;
    transition: transform 0.3s ease;
}

.nav-item:hover .dropdown-icon {
    transform: rotate(180deg);
}

/* Dropdown Menu */
.dropdown-menu {
    position: absolute;
    top: 100%;
    left: 50%;
    transform: translateX(-50%) translateY(10px);
    background: var(--card-bg);
    min-width: 250px;
    box-shadow: 0 10px 25px -5px rgba(0, 0, 0, 0.1), 0 8px 10px -6px rgba(0, 0, 0, 0.1);
    border-radius: 12px;
    padding: 10px 0;
    opacity: 0;
    visibility: hidden;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    border: 1px solid var(--border-color);
    list-style: none;
    z-index: 1001;
}

.nav-item:hover .dropdown-menu {
    opacity: 1;
    visibility: visible;
    transform: translateX(-50%) translateY(0);
}

.dropdown-menu li a {
    padding: 12px 20px;
    font-size: 0.9rem;
    color: var(--text-color);
    display: block;
    width: 100%;
}

.dropdown-menu li a:hover {
    background: var(--bg-color);
    color: var(--primary-color);
    padding-left: 25px;
}

.theme-toggle {
    background: var(--card-bg);
    border: 1px solid var(--border-color);
    padding: 8px 16px;
    border-radius: 9999px;
    cursor: pointer;
    color: var(--text-color);
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 0.85rem;
    font-weight: 600;
    box-shadow: var(--card-shadow);
    transition: var(--transition);
}

.theme-toggle:hover {
    transform: translateY(-2px);
    border-color: var(--primary-color);
}

/* Hero Section */
.hero {
    padding: 200px 0 160px;
    /* Refined padding for better focus */
    text-align: left;
    /* Aligned left as per image */
    position: relative;
    background: linear-gradient(rgba(0, 0, 0, 0.6), rgba(0, 0, 0, 0.4)), url('../assets/hero_dc.png');
    background-size: cover;
    background-position: center;
    color: white;
}

.hero h1 {
    font-size: clamp(2.5rem, 6vw, 4.5rem);
    font-weight: 700;
    line-height: 1.1;
    margin-bottom: 24px;
    max-width: 800px;
    color: white;
    letter-spacing: -0.02em;
}

.hero p {
    font-size: 1.25rem;
    color: #f1f5f9;
    max-width: 600px;
    margin: 0 0 40px;
    font-weight: 300;
}

.hero-content {
    animation: fadeIn 1s ease-out;
}

.cta-button {
    display: inline-flex;
    align-items: center;
    background: var(--primary-gradient);
    color: white;
    padding: 16px 36px;
    border-radius: 12px;
    font-weight: 600;
    font-size: 1.05rem;
    transition: var(--transition);
    box-shadow: 0 10px 15px -3px rgba(0, 128, 128, 0.3);
}

.cta-button:hover {
    transform: translateY(-4px) scale(1.02);
    box-shadow: 0 20px 25px -5px rgba(0, 128, 128, 0.4);
}

/* Cards & Information */
section {
    padding: 100px 0;
}

.section-title {
    text-align: center;
    margin-bottom: 64px;
}

.section-title h2 {
    font-size: 2.5rem;
    font-weight: 700;
    margin-bottom: 16px;
}

.section-title p {
    color: var(--text-muted);
}

.grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
    gap: 32px;
}

.card {
    background: var(--card-bg);
    padding: 48px;
    border-radius: 24px;
    border: 1px solid var(--border-color);
    transition: var(--transition);
    box-shadow: var(--card-shadow);
    display: flex;
    flex-direction: column;
}

.card:hover {
    transform: translateY(-8px);
    border-color: var(--primary-color);
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.1);
}

.card h3 {
    font-size: 1.5rem;
    margin-bottom: 20px;
    font-weight: 600;
}

.card p {
    color: var(--text-muted);
    margin-bottom: 24px;
    flex-grow: 1;
}

.text-link {
    color: var(--primary-color);
    font-weight: 600;
    display: flex;
    align-items: center;
    gap: 8px;
}

.text-link:hover {
    gap: 12px;
}

/* Animations */
@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(20px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.reveal {
    animation: fadeIn 0.8s ease forwards;
}

/* Footer Styling */
footer {
    background: var(--footer-bg);
    color: var(--footer-text);
    padding: 80px 0 40px;
    border-top: 1px solid var(--border-color);
}

.footer-grid {
    display: grid;
    grid-template-columns: 2fr 1fr 1.5fr;
    gap: 64px;
    margin-bottom: 64px;
}

.footer-col h4 {
    font-size: 1.125rem;
    margin-bottom: 24px;
    font-weight: 600;
}

.footer-col ul li {
    margin-bottom: 12px;
}

.footer-col ul li a {
    color: var(--text-muted);
    transition: var(--transition);
}

.footer-col ul li a:hover {
    color: var(--primary-color);
    padding-left: 4px;
}

.footer-bottom {
    text-align: center;
    padding-top: 40px;
    border-top: 1px solid var(--border-color);
    color: var(--text-muted);
    font-size: 0.875rem;
}

/* Mobile Adjustments */
@media (max-width: 968px) {
    .footer-grid {
        grid-template-columns: 1fr;
        gap: 40px;
    }

    .nav-links {
        display: none;
        flex-direction: column;
        position: absolute;
        top: 80px;
        left: 0;
        right: 0;
        background: var(--header-bg);
        backdrop-filter: blur(20px);
        padding: 40px;
        border-bottom: 1px solid var(--border-color);
    }

    .nav-links.active {
        display: flex;
    }
}

/* Dark Mode Logo Adjustment - Converting Red to Blue/Cyan and Black tagline to White */
[data-theme="dark"] .logo img,
[data-theme="dark"] footer img {
    filter: invert(1) brightness(1.2);
    /* Red turns into Cyan/Blue, Black turns into White */
}

/* Mobile Menu Toggle */
.menu-btn {
    display: none;
    background: none;
    border: none;
    color: var(--text-color);
    font-size: 1.5rem;
    cursor: pointer;
}

@media (max-width: 968px) {
    .menu-btn {
        display: block;
    }
}