:root {
    --primary: #0077b6;
    --primary-glow: rgba(0, 119, 182, 0.5);
    --dark: #003559;
    --darker: #001d3d;
    --text-dark: #001219;
    --text-accent: #00509d;
    --bg-light: #f5f5f5;
    --bg-lighter: #ffffff;
    --border-light: rgba(0, 119, 182, 0.2);
}

html {
    scroll-behavior: smooth;
}

/* Navbar Styles */
nav {
    background: linear-gradient(90deg, rgba(255,255,255,0.95) 0%, rgba(230,240,255,0.95) 100%);
    padding: 1rem 2rem;
    display: flex;
    justify-content: space-between;
    align-items: center;
    position: fixed;
    width: 100%;
    z-index: 100;
    box-shadow: 0px 4px 15px rgba(0, 119, 182, 0.2);
    backdrop-filter: blur(10px);
}

/* Logo Styles */
nav .logo {
    font-size: 1.8rem;
    font-weight: 700;
    color: var(--darker);
    text-decoration: none;
    letter-spacing: 1px;
    position: relative;
}

nav .logo::after {
    content: '';
    position: absolute;
    bottom: -5px;
    left: 0;
    width: 30%;
    height: 2px;
    background: var(--primary);
    transition: width 0.3s ease;
}

nav .logo:hover::after {
    width: 100%;
}

/* Add specific rules to keep logo color consistent */
nav .logo:hover,
nav .logo:visited,
nav .logo:active,
nav .logo:focus,
nav a.logo:hover,
nav a.logo:visited,
nav a.logo:active,
nav a.logo:focus {
    color: var(--darker);
    text-decoration: none;
}

/* Navbar Links */
nav .navbar-links {
    display: flex;
    gap: 30px;
    list-style: none;
    margin: 0;
    padding: 0;
}

nav .navbar-links a {
    color: var(--dark);
    text-decoration: none;
    font-size: 1rem;
    font-weight: 600;
    transition: all 0.3s ease-in-out;
    padding: 8px 0;
    position: relative;
    letter-spacing: 0.5px;
}

/* Add these styles to fix the link color issue */
nav .navbar-links a:visited,
nav .navbar-links a:active,
nav .navbar-links a.nav-link:visited,
nav .navbar-links a.nav-link:active {
    color: var(--dark);
}

nav .navbar-links a:hover {
    color: var(--primary);
}

nav .navbar-links a::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 0;
    height: 2px;
    background: var(--primary);
    transition: width 0.3s ease;
}

/* Logo Styles */
nav .logo img {
    height: 50px;
    width: auto;
    display: block;
}

body {
    font-family: 'Poppins', sans-serif;
    margin: 0;
    background: var(--bg-light);
    color: var(--text-dark);
    overflow-x: hidden;
    line-height: 1.6;
}

/* Hero Section */
#hero {
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    height: 100vh;
    background: linear-gradient(135deg, rgba(240,245,255,0.95) 0%, rgba(225,235,250,0.98) 100%), url('/media/background.avif') no-repeat center center;
    background-size: cover;
    text-align: center;
    color: var(--text-dark);
    padding: 2rem;
    position: relative;
    overflow: hidden;
}

/* Add futuristic elements to hero section */
#hero::before {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    width: 150vmax;
    height: 150vmax;
    border-radius: 50%;
    background: radial-gradient(circle, rgba(0,119,182,0.1) 0%, rgba(0,0,0,0) 70%);
    transform: translate(-50%, -50%);
    z-index: -1;
}

#hero::after {
    content: '';
    position: absolute;
    width: 100%;
    height: 100%;
    top: 0;
    left: 0;
    background: url('/D:/NEW PROJECTS/ptyped main site prototype/media/grid-overlay.png');
    opacity: 0.1;
    z-index: -1;
}

#hero h1 {
    font-size: 3.5rem;
    margin-bottom: 20px;
    font-weight: 700;
    letter-spacing: 2px;
    color: var(--darker);
}

#hero p {
    font-size: 1.5rem;
    max-width: 700px;
    margin: 0 auto 2rem auto;
    font-weight: 300;
    color: var (--text-dark);
}

#hero .hero-heading {
    font-size: 3.5rem;
    font-weight: 700;
    margin-bottom: 20px;
    background: linear-gradient(90deg, var(--darker), var(--primary));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
}

#hero .hero-subheading {
    margin-top: 10px;
    font-size: 1.5rem;
    font-weight: 400;
    margin-bottom: 30px;
    opacity: 0.9;
    color: var(--text-dark);
}

#hero .discover-more {
    display: inline-block;
    font-size: 1.1rem;
    font-weight: 600;
    background: linear-gradient(90deg, var(--primary), #005a8c);
    padding: 14px 32px;
    border-radius: 50px;
    color: white;
    text-decoration: none;
    margin-top: 20px;
    transition: all 0.3s ease;
    letter-spacing: 1px;
    position: relative;
    overflow: hidden;
}

#hero .discover-more:hover {
    transform: translateY(-3px);
    box-shadow: 0 8px 25px rgba(0, 119, 182, 0.2);
}

#hero .discover-more::after {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(255, 255, 255, 0.2);
    transform: translateX(-100%);
    transition: transform 0.6s ease;
}

#hero .discover-more:hover::after {
    transform: translateX(100%);
}

/* Style for the Discover More button */
.discover-more-btn {
    background: linear-gradient(90deg, var(--primary), #005a8c);
    color: #ffffff;
    border: none;
    border-radius: 50px;
    padding: 14px 32px;
    font-size: 16px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease-in-out;
    letter-spacing: 1px;
}

.discover-more-btn:hover {
    transform: translateY(-3px);
    box-shadow: 0 8px 25px rgba(0, 119, 182, 0.2);
}

/* Section Styling */
section {
    padding: 100px 5%;
    position: relative;
    overflow: hidden;
}

section h2 {
    text-align: center;
    font-size: 2.5rem;
    margin-bottom: 2.5rem;
    position: relative;
    display: inline-block;
    left: 50%;
    transform: translateX(-50%);
    color: var(--darker);
}

section h2::after {
    content: '';
    position: absolute;
    bottom: -10px;
    left: 50%;
    transform: translateX(-50%);
    width: 60%;
    height: 3px;
    background: var(--primary);
}

/* Features section improvements */
#features {
    background: linear-gradient(135deg, #e6f0f8 0%, #f0f5ff 100%);
    position: relative;
    overflow: hidden;
}

#features::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 1px;
    background: linear-gradient(90deg, transparent, var(--primary), transparent);
}

.feature {
    background: rgba(255, 255, 255, 0.8);
    border: 1px solid var(--border-light);
    border-radius: 10px;
    padding: 30px;
    transition: all 0.4s ease;
    backdrop-filter: blur(5px);
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.05);
    opacity: 0;
    transform: translateY(100px);
    transition: all 0.6s cubic-bezier(0.215, 0.61, 0.355, 1);
    color: var(--text-dark);
}

.feature:hover {
    transform: translateY(-10px);
    box-shadow: 0 10px 25px rgba(0, 119, 182, 0.2);
    border: 1px solid rgba(0, 119, 182, 0.3);
}

.feature.visible {
    opacity: 1;
    transform: translateY(0);
}

.feature:nth-child(1) { transition-delay: 0s; }
.feature:nth-child(2) { transition-delay: 0.2s; }
.feature:nth-child(3) { transition-delay: 0.4s; }
.feature:nth-child(4) { transition-delay: 0.6s; }

.feature i {
    font-size: 3rem;
    margin-bottom: 20px;
    color: var(--primary);
    background: linear-gradient(135deg, var(--primary), #005a8c);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
}

.feature h3 {
    font-size: 1.5rem;
    margin-bottom: 15px;
    font-weight: 600;
    color: var(--darker);
}

.feature p {
    color: var(--text-dark);
}

/* Footer */
footer {
    background: linear-gradient(180deg, #e0e8f0 0%, #c5d5e5 100%);
    padding: 40px 5%;
    text-align: center;
    color: var(--dark);
    position: relative;
}

footer::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 1px;
    background: linear-gradient(90deg, transparent, var(--primary), transparent);
}

footer p, 
footer .copyright,
footer .footer-links {
    color: var(--text-dark);
}

footer h3,
footer h4,
footer .footer-heading {
    color: var(--darker);
}

/* Social media links */
footer .social-links {
    margin-top: 20px;
}

footer .social-links a {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 40px;
    height: 40px;
    margin: 0 10px;
    border-radius: 50%;
    background: rgba(0, 29, 61, 0.1);
    color: var(--primary);
    transition: all 0.3s ease;
}

footer .social-links a:hover {
    background: var(--primary);
    color: #fff;
    transform: translateY(-3px);
}

/* Footer quicklinks text color */
footer .quicklinks a,
footer .footer-links a,
footer .footer-nav a,
footer ul.quicklinks li a {
    color: var(--text-dark);
    transition: all 0.3s ease;
}

footer .quicklinks a:hover,
footer .footer-links a:hover,
footer .footer-nav a:hover,
footer ul.quicklinks li a:hover {
    color: var(--primary);
    text-decoration: none;
}

/* Ensure all footer text elements are properly visible */
footer .widget-title,
footer .column-title,
footer .footer-title {
    color: var(--darker);
    font-weight: 600;
}

/* Specifically target the Quick Links navigation in footer */
footer .quick-links-section h4 + ul li a,
footer h4:contains("QUICK LINKS") + ul li a,
footer .quick-links h4 + ul li a,
footer .footer-links h4:contains("QUICK LINKS") + ul li a,
footer .widget-title + ul.footer-nav li a,
footer .footer-menu li a,
footer .footer-column ul li a {
    color: var(--text-dark);
    font-weight: 500;
    transition: color 0.3s ease;
}

footer .quick-links-section h4 + ul li a:hover,
footer h4:contains("QUICK LINKS") + ul li a:hover,
footer .quick-links h4 + ul li a:hover,
footer .footer-links h4:contains("QUICK LINKS") + ul li a:hover,
footer .widget-title + ul.footer-nav li a:hover,
footer .footer-menu li a:hover,
footer .footer-column ul li a:hover {
    color: var(--primary);
}

/* Additional selector for direct footer nav links */
footer nav ul li a,
footer .footer-nav-links a {
    color: var(--text-dark) !important;
}

footer nav ul li a:hover,
footer .footer-nav-links a:hover {
    color: var(--primary) !important;
}

/* Fix Quick Links in footer to be black */
footer .footer-section ul li a {
    color: var(--text-dark) !important;
    transition: color 0.3s ease;
}

footer .footer-section ul li a:hover {
    color: var(--primary) !important;
}

/* Animations */
.reveal {
    opacity: 0;
    transform: translateY(30px);
    transition: all 0.8s cubic-bezier(0.215, 0.61, 0.355, 1);
}

.reveal.visible {
    opacity: 1;
    transform: translateY(0);
}

/* Cursor */
#cursor {
    position: fixed;
    width: 12px;
    height: 12px;
    border-radius: 50%;
    background: var(--primary);
    pointer-events: none;
    z-index: 9999;
    transform: translate(-50%, -50%);
    transition: width 0.2s, height 0.2s;
}

/* Cursor Trail */
#cursor-trail {
    position: fixed;
    width: 40px;
    height: 40px;
    border-radius: 50%;
    background: transparent;
    border: 1px solid var(--primary);
    pointer-events: none;
    z-index: 9998;
    transform: translate(-50%, -50%);
    transition: all 0.15s ease;
    opacity: 0.5;
}

/* Chatbot Icon and Panel */
.chatbot-container {
    position: fixed;
    bottom: 30px;
    right: 30px;
    z-index: 1000;
}

.chatbot-icon {
    display: flex;
    align-items: center;
    justify-content: center;
    background: linear-gradient(135deg, var(--primary), #005a8c);
    color: white;
    border-radius: 50px;
    padding: 15px 25px;
    cursor: pointer;
    transition: all 0.3s ease;
    text-decoration: none;
}

.chatbot-icon:hover {
    transform: translateY(-3px);
    box-shadow: 0 8px 25px rgba(0, 119, 182, 0.2);
}

.chatbot-icon i {
    font-size: 1.5rem;
    margin-right: 10px;
}

.chatbot-icon span {
    font-size: 1rem;
    font-weight: 600;
    letter-spacing: 0.5px;
}

/* Founders section */
#founders {
    background: linear-gradient(135deg, #e6f0f8 0%, #f0f5ff 100%);
}

#founders .founder-card {
    background: rgba(255, 255, 255, 0.8);
    border: 1px solid var(--border-light);
    border-radius: 10px;
    padding: 30px;
    transition: all 0.4s ease;
    backdrop-filter: blur(5px);
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.05);
    position: relative;
    overflow: hidden;
    color: var(--text-dark);
}

#founders .founder-card:hover {
    transform: translateY(-10px);
    box-shadow: 0 10px 25px rgba(0, 119, 182, 0.2);
    border: 1px solid rgba(0, 119, 182, 0.3);
}

#founders .founder-card::after {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255,255,255,0.3), transparent);
    transition: all 0.8s ease;
}

#founders .founder-card:hover::after {
    left: 100%;
}

#founders img {
    border: 2px solid var(--primary);
    padding: 5px;
    transition: all 0.3s ease;
    width: 80px;
    height: 80px;
    object-fit: cover; /* This ensures the image maintains its aspect ratio */
    border-radius: 50%; /* Make the image itself a circle */
}

#founders .founder-card:hover img {
    transform: scale(1.05);
    box-shadow: 0 0 15px var(--primary-glow);
}

#founders .founder-image-container {
    position: relative;
    width: 80px;
    height: 80px;
    margin: 0 auto 20px;
    border-radius: 50%;
    overflow: hidden; /* Ensures content stays within the circle */
    display: flex;
    justify-content: center;
    align-items: center;
}

#founders .founder-image-glow {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: 100%;
    height: 100%;
    border-radius: 50%;
    background: var(--primary-glow);
    filter: blur(10px);
    opacity: 0;
    transition: opacity 0.3s ease;
}

#founders .founder-card:hover .founder-image-glow {
    opacity: 0.7;
}

#founders .founder-social a {
    opacity: 0.7;
    transition: all 0.3s ease;
}

#founders .founder-social a:hover {
    opacity: 1;
    transform: translateY(-3px);
}

#founders .founder-status {
    font-size: 0.9rem;
    color: var(--text-dark);
}

#founders .founder-card h3 {
    color: var(--darker);
}

#founders .founder-card p {
    color: var(--text-dark);
}

#founders .status-indicator {
    display: inline-block;
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background: #0077b6;
    margin-right: 5px;
    animation: statusPulse 2s infinite;
}

@keyframes statusPulse {
    0%, 100% {
        opacity: 1;
        transform: scale(1);
    }
    50% {
        opacity: 0.5;
        transform: scale(1.2);
    }
}

/* AI-themed decorative elements */
.ai-circuit {
    position: absolute;
    width: 300px;
    height: 300px;
    background: url('/D:/NEW PROJECTS/ptyped main site prototype/media/circuit-pattern.png');
    opacity: 0.05;
    z-index: -1;
}

.ai-circuit.top-left {
    top: 0;
    left: 0;
}

.ai-circuit.bottom-right {
    bottom: 0;
    right: 0;
    transform: rotate(180deg);
}

.data-particles {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    overflow: hidden;
    z-index: -1;
}

.data-particle {
    position: absolute;
    width: 2px;
    height: 2px;
    background: var(--primary);
    border-radius: 50%;
    opacity: 0.3;
}

/* Feature section modernization */
.feature {
    opacity: 0;
    transform: translateY(100px);
    transition: all 0.6s cubic-bezier(0.215, 0.61, 0.355, 1);
    color: var(--text-dark);
}

.feature.visible {
    opacity: 1;
    transform: translateY(0);
}

.feature:nth-child(1) { transition-delay: 0s; }
.feature:nth-child(2) { transition-delay: 0.2s; }
.feature:nth-child(3) { transition-delay: 0.4s; }
.feature:nth-child(4) { transition-delay: 0.6s; }

/* Futuristic section transitions */
section {
    position: relative;
    overflow: hidden;
}

section::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 100%;
    height: 100px;
    /*background: linear-gradient(to top, rgba(245, 245, 245, 1), transparent);*/
    pointer-events: none;
    z-index: 2;
}

/* CGFM Section styling */
#cgfm {
    background: linear-gradient(135deg, #f0f5ff 0%, #e6f0f8 100%);
}

/* Transmute section styling */
#transmute {
    background: linear-gradient(135deg, #e6f0f8 0%, #f0f5ff 100%);
    position: relative;
}

#transmute::before {
    content: '';
    position: absolute;
    top: 0;
    left: 50%;
    transform: translateX(-50%);
    width: 150px;
    height: 1px;
    background: var(--primary);
}

/* New hero particles effect */
.hero-particles {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    overflow: hidden;
    z-index: -1;
}

/* ALFIE Neural Network Visualization */
.alfie-visual {
    background: rgba(240, 245, 255, 0.8);
    border-radius: 15px;
    padding: 30px;
    border: 1px solid rgba(0, 119, 182, 0.2);
    overflow: hidden;
    position: relative;
}

.alfie-visual::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 1px;
    background: linear-gradient(90deg, transparent, var(--primary), transparent);
}

.alfie-visual::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    height: 1px;
    background: linear-gradient(90deg, transparent, var(--primary), transparent);
}

.brain-visualization {
    margin-bottom: 20px;
}

.brain-visualization .node {
    fill: var(--primary);
    opacity: 0.7;
    transition: all 0.5s ease;
}

.brain-visualization .node:hover {
    fill: var(--text-accent);
    opacity: 1;
    r: 10;
}

.brain-visualization .node.input-node {
    fill: #0077b6;
}

.brain-visualization .node.output-node {
    fill: #003559;
}

.brain-visualization .connection {
    stroke: var(--primary);
    stroke-width: 1;
    stroke-opacity: 0.2;
    animation: pulse 3s infinite;
}

@keyframes pulse {
    0%, 100% {
        stroke-opacity: 0.2;
    }
    50% {
        stroke-opacity: 0.8;
    }
}

.data-flow-labels {
    display: flex;
    justify-content: space-between;
    font-size: 0.9rem;
    color: var(--primary);
    opacity: 0.8;
}

/* Feature icon improvements */
.feature-icon-wrapper {
    position: relative;
    width: 80px;
    height: 80px;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 20px;
}

.icon-glow {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: 60px;
    height: 60px;
    border-radius: 50%;
    background: var(--primary-glow);
    filter: blur(15px);
    opacity: 0.5;
    z-index: -1;
}

/* Technology Matrix Background */
.tech-matrix {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    pointer-events: none;
    opacity: 0.05;
    background-image: repeating-linear-gradient(0deg, var(--primary), var(--primary) 1px, transparent 1px, transparent 30px),
                      repeating-linear-gradient(90deg, var(--primary), var(--primary) 1px, transparent 1px, transparent 30px);
    z-index: -1;
}

/* Founder card improvements */
.founder-card {
    background: rgba(255, 255, 255, 0.8);
    border: 1px solid var(--border-light);
    border-radius: 10px;
    padding: 30px;
    transition: all 0.4s ease;
    backdrop-filter: blur(5px);
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.05);
    position: relative;
    overflow: hidden;
    color: var (--text-dark);
}

.founder-card::after {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255,255,255,0.3), transparent);
    transition: all 0.8s ease;
}

.founder-card:hover {
    transform: translateY(-10px);
    box-shadow: 0 10px 25px rgba(0, 119, 182, 0.2);
    border: 1px solid rgba(0, 119, 182, 0.3);
}

.founder-card:hover::after {
    left: 100%;
}

.founder-image-container {
    position: relative;
    width: 80px;
    height: 80px;
    margin: 0 auto 20px;
    border-radius: 50%;
    overflow: hidden;
    display: flex;
    justify-content: center;
    align-items: center;
}

.founder-image-glow {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: 100%;
    height: 100%;
    border-radius: 50%;
    background: var(--primary-glow);
    filter: blur(10px);
    opacity: 0;
    transition: opacity 0.3s ease;
}

.founder-card:hover .founder-image-glow {
    opacity: 0.7;
}

.founder-social a {
    opacity: 0.7;
    transition: all 0.3s ease;
}

.founder-social a:hover {
    opacity: 1;
    transform: translateY(-3px);
}

.founder-status {
    font-size: 0.9rem;
    color: var(--text-dark);
}

.status-indicator {
    display: inline-block;
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background: #0077b6;
    margin-right: 5px;
    animation: statusPulse 2s infinite;
}

@keyframes statusPulse {
    0%, 100% {
        opacity: 1;
        transform: scale(1);
    }
    50% {
        opacity: 0.5;
        transform: scale(1.2);
    }
}

/* Ensure images inside are perfect circles */
.founder-image-container img {
    width: 100%;
    height: 100%;
    object-fit: cover; /* This keeps the aspect ratio while filling the container */
    border-radius: 50%;
}

/* Vision metrics styling */
.vision-metrics {
    margin-top: 40px;
}

.metric-card {
    background: rgba(255, 255, 255, 0.8);
    border: 1px solid var(--border-light);
    border-radius: 10px;
    padding: 20px;
    transition: all 0.4s ease;
    color: var(--text-dark);
}

.metric-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 10px 25px rgba(0, 119, 182, 0.2);
    border: 1px solid rgba(0, 119, 182, 0.3);
}

.metric-value {
    font-size: 2.5rem;
    font-weight: 700;
    color: var(--primary);
    margin-bottom: 5px;
}

.metric-label {
    font-size: 1rem;
    opacity: 0.8;
    color: var(--text-dark);
}

/* Call to action button */
.cta-button {
    display: inline-block;
    background: linear-gradient(135deg, var(--primary), #005a8c);
    color: white;
    font-size: 1.1rem;
    font-weight: 600;
    padding: 15px 35px;
    border-radius: 50px;
    text-decoration: none;
    transition: all 0.3s ease;
    letter-spacing: 1px;
    position: relative;
    overflow: hidden;
}

.cta-button::after {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(255, 255, 255, 0.2);
    transform: translateX(-100%);
    transition: transform 0.6s ease;
}

.cta-button:hover {
    transform: translateY(-5px);
    box-shadow: 0 8px 25px rgba(0, 119, 182, 0.2);
}

.cta-button:hover::after {
    transform: translateX(100%);
}

/* Mobile Navigation */
.mobile-menu-toggle {
    display: none;
    cursor: pointer;
    font-size: 1.5rem;
    color: var(--text-dark);
}

/* Custom Scrollbar */
::-webkit-scrollbar {
    width: 8px;
}

::-webkit-scrollbar-track {
    background: #f0f5ff;
}

::-webkit-scrollbar-thumb {
    background: var(--primary);
    border-radius: 4px;
}

::-webkit-scrollbar-thumb:hover {
    background: #005a8c;
}

/* Animated Background Grid */
.grid-background {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-size: 50px 50px;
    background-image: 
        linear-gradient(to right, rgba(0, 119, 182, 0.05) 1px, transparent 1px),
        linear-gradient(to bottom, rgba(0, 119, 182, 0.05) 1px, transparent 1px);
    z-index: -2;
    animation: gridMove 15s linear infinite;
}

@keyframes gridMove {
    0% {
        background-position: 0 0;
    }
    100% {
        background-position: 50px 50px;
    }
}

/* Accessibility Improvements */
.sr-only {
    position: absolute;
    width: 1px;
    height: 1px;
    padding: 0;
    margin: -1px;
    overflow: hidden;
    clip: rect(0, 0, 0, 0);
    white-space: nowrap;
    border: 0;
}

/* Focus states */
a:focus, button:focus, input:focus, textarea:focus, select:focus {
    outline: 2px solid var(--primary);
    outline-offset: 2px;
}

/* Better text selection */
::selection {
    background: var(--primary);
    color: white;
    text-shadow: none;
}

/* Loading animation */
.loader {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: var(--bg-lighter);
    display: flex;
    justify-content: center;
    align-items: center;
    z-index: 9999;
    transition: opacity 0.5s ease, visibility 0.5s ease;
}

.loader.hidden {
    opacity: 0;
    visibility: hidden;
}

.loader-circle {
    width: 50px;
    height: 50px;
    border: 4px solid rgba(0, 119, 182, 0.1);
    border-radius: 50%;
    border-top-color: var(--primary);
    animation: spin 1s ease-in-out infinite;
}

@keyframes spin {
    to { transform: rotate(360deg); }
}

/* Responsive Design */
@media (max-width: 992px) {
    #hero h1 {
        font-size: 2.8rem;
    }
    
    #hero p {
        font-size: 1.2rem;
    }
    
    section {
        padding: 80px 5%;
    }
}

@media (max-width: 768px) {
    nav .navbar-links {
        position: fixed;
        top: 80px;
        left: 0;
        width: 100%;
        background: rgba(255, 255, 255, 0.95);
        backdrop-filter: blur(10px);
        flex-direction: column;
        align-items: center;
        padding: 20px 0;
        gap: 20px;
        transform: translateY(-100%);
        opacity: 0;
        transition: all 0.3s ease;
        z-index: 99;
        box-shadow: 0 4px 15px rgba(0, 0, 0, 0.05);
        overflow: hidden;
        max-height: 0;
    }
    
    nav .navbar-links.active {
        transform: translateY(0);
        opacity: 1;
        max-height: 300px;
    }
    
    .mobile-menu-toggle {
        display: block;
    }
    
    #hero h1 {
        font-size: 2.2rem;
    }
    
    #hero p {
        font-size: 1rem;
    }
    
    section h2 {
        font-size: 2rem;
    }
    
    .feature {
        margin-bottom: 30px;
    }
}

@media (max-width: 576px) {
    nav {
        padding: 1rem;
    }
    
    nav .logo {
        font-size: 1.5rem;
    }
    
    #hero h1 {
        font-size: 1.8rem;
    }
    
    #hero .discover-more {
        padding: 10px 20px;
        font-size: 0.9rem;
    }
    
    section {
        padding: 60px 5%;
    }
    
    section h2 {
        font-size: 1.8rem;
    }
    
    footer {
        padding: 30px 5%;
    }
}

/* Dark mode toggle */
.theme-toggle {
    position: relative;
    width: 60px;
    height: 30px;
    border-radius: 15px;
    background: rgba(0, 29, 61, 0.2);
    cursor: pointer;
    display: flex;
    align-items: center;
    padding: 0 5px;
    transition: all 0.3s ease;
}

.theme-toggle::before {
    content: '☀️';
    position: absolute;
    left: 5px;
    font-size: 1rem;
}

.theme-toggle::after {
    content: '🌙';
    position: absolute;
    right: 5px;
    font-size: 1rem;
}

.theme-toggle-slider {
    position: absolute;
    left: 35px;
    width: 20px;
    height: 20px;
    border-radius: 50%;
    background: var(--primary);
    transition: all 0.3s ease;
}

.theme-toggle.active .theme-toggle-slider {
    left: 5px;
}

/* Contact form styling */
.contact-form input, 
.contact-form textarea {
    width: 100%;
    padding: 12px 15px;
    margin-bottom: 15px;
    background: rgba(255, 255, 255, 0.8);
    border: 1px solid var(--border-light);
    border-radius: 5px;
    color: var(--text-dark);
    font-family: 'Poppins', sans-serif;
    transition: all 0.3s ease;
}

.contact-form input:focus, 
.contact-form textarea:focus {
    border-color: var(--primary);
    box-shadow: 0 0 10px rgba(0, 119, 182, 0.3);
}

.contact-form button {
    background: linear-gradient(135deg, var(--primary), #005a8c);
    color: white;
    border: none;
    padding: 12px 25px;
    border-radius: 5px;
    cursor: pointer;
    transition: all 0.3s ease;
    font-weight: 600;
}

.contact-form button:hover {
    transform: translateY(-3px);
    box-shadow: 0 5px 15px rgba(0, 119, 182, 0.2);
}

.contact-form label {
    color: var(--text-dark);
}

.contact-section {
    color: var(--text-dark);
}

.contact-section h2, 
.contact-section h3, 
.contact-section h4 {
    color: var(--darker);
}

.contact-section p {
    color: var(--text-dark);
}

/* Animated background dots */
.background-animation {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: -3;
}

.background-dot {
    position: absolute;
    border-radius: 50%;
    background: var(--primary);
    opacity: 0.15;
    animation: float 8s infinite ease-in-out;
}

@keyframes float {
    0%, 100% {
        transform: translateY(0) translateX(0);
    }
    50% {
        transform: translateY(-20px) translateX(10px);
    }
}

/* Skip to content link for accessibility */
.skip-to-content {
    position: absolute;
    top: -50px;
    left: 0;
    background: var(--primary);
    color: white;
    padding: 10px 15px;
    z-index: 1001;
    transition: top 0.3s ease;
    text-decoration: none;
}

.skip-to-content:focus {
    top: 0;
}

/* Also update these styles later in the file if they exist */
.nav-link:visited,
.nav-link:active,
.navbar-nav .nav-link:visited,
.navbar-nav .nav-link:active {
    color: var(--dark) !important;
}

.nav-link.interactive:visited,
.nav-link.interactive:active {
    color: var(--dark) !important;
}

/* Remove any potential additional underlines for specific pages */
#cgfm h2::before,
#alfie h2::before {
    display: none;
}

/* Ensure a single underline in CGFM and ALFIE sections */
#cgfm h2::after,
#alfie h2::after {
    content: '';
    position: absolute;
    bottom: -10px;
    left: 50%;
    transform: translateX(-50%);
    width: 60%;
    height: 3px;
    background: var(--primary);
    /* No additional styling for double underline */
}

/* General white section text color enforcement */
.bg-white,
.bg-light,
section.white-bg,
.card,
.white-section {
    color: var(--text-dark);
}

.bg-white h1, .bg-white h2, .bg-white h3, .bg-white h4, .bg-white h5, .bg-white h6,
.bg-light h1, .bg-light h2, .bg-light h3, .bg-light h4, .bg-light h5, .bg-light h6,
section.white-bg h1, section.white-bg h2, section.white-bg h3, section.white-bg h4, section.white-bg h5, section.white-bg h6,
.card h1, .card h2, .card h3, .card h4, .card h5, .card h6,
.white-section h1, .white-section h2, .white-section h3, .white-section h4, .white-section h5, .white-section h6 {
    color: var(--darker);
}

/* ALFIE section specific styling */
#alfie h2 {
    color: white;
}

/* Scroll to Top Button */
.scroll-to-top {
    position: fixed;
    bottom: 30px;
    left: 30px;
    width: 50px;
    height: 50px;
    background: linear-gradient(135deg, var(--primary), #005a8c);
    color: white;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    z-index: 1000;
    opacity: 0;
    visibility: hidden;
    transform: translateY(20px);
    transition: all 0.3s ease;
    box-shadow: 0 4px 15px rgba(0, 119, 182, 0.3);
}

.scroll-to-top.show {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
}

.scroll-to-top:hover {
    transform: translateY(-5px);
    box-shadow: 0 8px 25px rgba(0, 119, 182, 0.4);
}

.scroll-to-top::before {
    content: '';
    position: absolute;
    width: 100%;
    height: 100%;
    border-radius: 50%;
    background: var(--primary);
    opacity: 0.2;
    animation: pulse 2s infinite;
}

.scroll-to-top i {
    font-size: 1.2rem;
}

@keyframes pulse {
    0% {
        transform: scale(1);
        opacity: 0.2;
    }
    50% {
        transform: scale(1.2);
        opacity: 0.1;
    }
    100% {
        transform: scale(1);
        opacity: 0.2;
    }
}

/* Fix for Bootstrap navbar toggler outline */
.navbar-toggler:focus {
    box-shadow: none;
    outline: none;
}

/* Ensure hamburger icon is visible in light theme */
.navbar-toggler .fas {
    color: var(--dark);
    font-size: 1.5rem;
}