/* Base Styles & Variables */
:root {
    /* Guinea's colors with accessible contrast */
    --guinea-red: #CE1126;        /* Slightly brighter red for better visibility */
    --guinea-yellow: #FCD116;     /* Standard yellow */
    --guinea-green: #009460;      /* Slightly darker green for better contrast */
    
    /* Derived colors */
    --red-light: #f8d7da;
    --yellow-light: #fff3cd;
    --green-light: #d1e7dd;
    
    /* Neutrals with good contrast */
    --black: #212529;
    --white: #ffffff;
    --gray-100: #f8f9fa;
    --gray-200: #e9ecef;
    --gray-500: #6c757d;
    --gray-800: #343a40;
    
    /* Spacing */
    --space-xs: 0.25rem;
    --space-sm: 0.5rem;
    --space-md: 1rem;
    --space-lg: 1.5rem;
    --space-xl: 2rem;
    
    /* Typography */
    --font-base: 1rem;
    --font-sm: 0.875rem;
    --font-lg: 1.25rem;
    --font-xl: 1.5rem;
    --font-xxl: 2rem;
    
    /* Borders */
    --border-radius: 0.25rem;
    --border-radius-lg: 0.5rem;
    
    /* Shadows */
    --shadow-sm: 0 0.125rem 0.25rem rgba(0, 0, 0, 0.075);
    --shadow: 0 0.5rem 1rem rgba(0, 0, 0, 0.15);
    
    /* Transitions */
    --transition: all 0.3s ease;
}

/* Reset & Base Styles */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
    font-size: 16px;
}

body {
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    line-height: 1.6;
    color: var(--black);
    background-color: var(--gray-100);
    min-height: 100vh;
    display: flex;
    flex-direction: column;
    padding-left: 3px;
    padding-right: 3px;
}

a {
    text-decoration: none;
    color: inherit;
    transition: var(--transition);
}

img {
    max-width: 100%;
    height: auto;
}

button, input, select, textarea {
    font-family: inherit;
    font-size: inherit;
}

/* Accessibility Focus Styles */
:focus-visible {
    outline: 2px solid var(--guinea-yellow);
    outline-offset: 2px;
}

.skip-link {
    position: absolute;
    top: -40px;
    left: 0;
    background: var(--guinea-red);
    color: var(--white);
    padding: var(--space-sm) var(--space-md);
    z-index: 100;
    transition: top 0.3s;
}

.skip-link:focus {
    top: 0;
}

/* Header Styles */
.header {
    background-color: var(--white);
    box-shadow: var(--shadow-sm);
    position: sticky;
    top: 0;
    z-index: 1000;
}

.header-content {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: var(--space-md) 0;
}

.logo {
    display: flex;
    align-items: center;
    gap: var(--space-sm);
    font-weight: 700;
    font-size: var(--font-lg);
    color: var(--guinea-red);
}

.logo img {
    height: 40px;
    width: auto;
}

/* Navigation */
.main-nav {
    display: flex;
    align-items: center;
}

.nav-list {
    display: flex;
    list-style: none;
    gap: var(--space-md);
    margin: 0;
    padding: 0;
}

.nav-link {
    padding: var(--space-sm) var(--space-md);
    border-radius: var(--border-radius);
    font-weight: 500;
    color: var(--gray-800);
    position: relative;
}

.nav-link:hover {
    color: var(--guinea-red);
}

.nav-link.active {
    color: var(--guinea-red);
    font-weight: 600;
}

.nav-link.active::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 50%;
    transform: translateX(-50%);
    width: 50%;
    height: 2px;
    background-color: var(--guinea-red);
}



/* Header Actions */
.header-actions {
    display: flex;
    align-items: center;
    gap: var(--space-md);
}

.language-switcher {
    display: flex;
    border: 1px solid var(--gray-200);
    border-radius: var(--border-radius);
    overflow: hidden;
}

.language-option {
    padding: var(--space-xs) var(--space-sm);
    cursor: pointer;
    font-size: var(--font-sm);
    background-color: var(--white);
    color: var(--gray-500);
}

.language-option.active {
    background-color: var(--guinea-green);
    color: var(--white);
}

.language-option:not(.active):hover {
    background-color: var(--gray-200);
}

.auth-buttons {
    display: flex;
    gap: var(--space-sm);
}

.btn {
    padding: var(--space-sm) var(--space-md);
    border-radius: var(--border-radius);
    font-weight: 500;
    cursor: pointer;
    transition: var(--transition);
    border: 1px solid transparent;
}

.btn-login {
    background-color: transparent;
    color: var(--guinea-red);
    border-color: var(--guinea-red);
}

.btn-login:hover {
    background-color: var(--guinea-red);
    color: var(--white);
}

.btn-signup {
    background-color: var(--guinea-red);
    color: var(--white);
}

.btn-signup:hover {
    background-color: #b30e20;
}

.btn-primary {
    background-color: var(--guinea-red);
    color: var(--white);
    padding: var(--space-md) var(--space-lg);
    font-size: var(--font-lg);
    font-weight: 600;
}

.btn-primary:hover {
    background-color: #b30e20;
    transform: translateY(-2px);
    box-shadow: var(--shadow);
}

.btn-outline {
    background-color: transparent;
    color: var(--guinea-green);
    border: 1px solid var(--guinea-green);
}

.btn-outline:hover {
    background-color: var(--guinea-green);
    color: var(--white);
}

/* Mobile Menu */
.mobile-menu-toggle {
    display: none;
    background: none;
    border: none;
    font-size: var(--font-xl);
    color: var(--guinea-red);
    cursor: pointer;
    padding: var(--space-sm);
}

/* Hero Section */
.hero-section {
    background: linear-gradient(135deg, var(--guinea-red) 0%, var(--guinea-yellow) 50%, var(--guinea-green) 100%);
    color: var(--white);
    padding: var(--space-xl) 0;
    text-align: center;
    margin-bottom: var(--space-xl);
    position: relative;
    overflow: hidden;
}

.hero-section::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.3);
    z-index: 1;
}

.hero-content {
    position: relative;
    z-index: 2;
    max-width: 800px;
    margin: 0 auto;
    padding: 0 var(--space-md);
}

.hero-title {
    font-size: var(--font-xxl);
    margin-bottom: var(--space-md);
    text-shadow: 2px 2px 4px rgba(0, 0, 0, 0.5);
}

.hero-subtitle {
    font-size: var(--font-lg);
    margin-bottom: var(--space-xl);
    text-shadow: 1px 1px 2px rgba(0, 0, 0, 0.5);
}

/* Features Section */
.features-section {
    padding: var(--space-xl) 0;
}

.features-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: var(--space-xl);
    margin-bottom: var(--space-xl);
}

.feature-card {
    background-color: var(--white);
    border-radius: var(--border-radius-lg);
    overflow: hidden;
    box-shadow: var(--shadow-sm);
    transition: var(--transition);
    border-top: 4px solid var(--guinea-red);
}

.feature-card:hover {
    transform: translateY(-5px);
    box-shadow: var(--shadow);
}

.feature-card:nth-child(2) {
    border-top-color: var(--guinea-yellow);
}

.feature-card:nth-child(3) {
    border-top-color: var(--guinea-green);
}

.card-body {
    padding: var(--space-xl);
    text-align: center;
}

.card-icon {
    color: var(--guinea-red);
    margin-bottom: var(--space-md);
}

.feature-card:nth-child(2) .card-icon {
    color: var(--guinea-yellow);
}

.feature-card:nth-child(3) .card-icon {
    color: var(--guinea-green);
}

.card-title {
    font-size: var(--font-lg);
    margin-bottom: var(--space-md);
    color: var(--gray-800);
}

.card-text {
    color: var(--gray-500);
    margin-bottom: var(--space-xl);
}

/* Footer */
.footer {
    background-color: var(--gray-800);
    color: var(--white);
    padding: var(--space-xl) 0 0;
    margin-top: auto;
    padding-left: 10px;
}

.footer-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: var(--space-xl);
    margin-bottom: var(--space-xl);
}

.footer-col h5 {
    font-size: var(--font-lg);
    margin-bottom: var(--space-md);
    color: var(--guinea-yellow);
    padding-left: 10px;
}

.footer-links {
    list-style: none;
}

.footer-links li {
    margin-bottom: var(--space-sm);
}

.footer-links a {
    color: var(--gray-200);
}

.footer-links a:hover {
    color: var(--guinea-yellow);
}

address {
    font-style: normal;
    margin-bottom: var(--space-md);
}

address i {
    margin-right: var(--space-sm);
    color: var(--guinea-yellow);
    width: 1.25rem;
    text-align: center;
}

.social-icons {
    display: flex;
    gap: var(--space-md);
    margin-top: var(--space-md);
}

.social-icons a {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 2.5rem;
    height: 2.5rem;
    background-color: rgba(255, 255, 255, 0.1);
    border-radius: 50%;
    color: var(--white);
    transition: var(--transition);
}

.social-icons a:hover {
    background-color: var(--guinea-yellow);
    color: var(--gray-800);
    transform: translateY(-2px);
}

.footer-bottom {
    text-align: center;
    padding: var(--space-md) 0;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
}

/* Chatbot */
#cgp-chatbot {
    position: fixed;
    bottom: var(--space-xl);
    right: var(--space-xl);
    width: 375px;
    background-color: var(--white);
    border-radius: var(--border-radius-lg);
    box-shadow: var(--shadow);
    z-index: 1000;
    display: none;
    flex-direction: column;
    overflow: hidden;
}

.chatbot-card {
    display: flex;
    flex-direction: column;
    height: 100%;
}

.chatbot-header {
    background-color: var(--guinea-green);
    color: var(--white);
    padding: var(--space-md);
    display: flex;
    justify-content: space-between;
    align-items: center;
    font-weight: 600;
}

.close-btn {
    background: none;
    border: none;
    color: var(--white);
    font-size: var(--font-lg);
    cursor: pointer;
    padding: 0 var(--space-sm);
}

.chatbot-body {
    padding: var(--space-md);
    flex-grow: 1;
    overflow-y: auto;
    max-height: 400px;
    background-color: var(--gray-100);
}

.chatbot-footer {
    padding: var(--space-md);
    background-color: var(--white);
    border-top: 1px solid var(--gray-200);
   
}

.chat-input-group {
    display: flex;
    gap: var(--space-sm);
}

.language-select {
    padding: var(--space-sm);
    border: 1px solid var(--gray-200);
    border-radius: var(--border-radius);
    background-color: var(--white);
}

.chat-input {
    flex-grow: 1;
    padding: var(--space-sm);
    border: 1px solid var(--gray-200);
    border-radius: var(--border-radius);
}

.send-btn {
    background-color: var(--guinea-green);
    color: var(--white);
    border: none;
    border-radius: var(--border-radius);
    padding: var(--space-sm) var(--space-md);
    cursor: pointer;
    min-width: 80px;
    height: 40px;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: var(--transition);
    font-weight: 600;
}

.send-btn:hover {
    background-color: #007a4d;
}

#chat-toggle {
    position: fixed;
    bottom: var(--space-md);
    right: var(--space-md);
    width: 60px;
    height: 60px;
    border-radius: 50%;
    background-color: var(--guinea-red);
    color: var(--white);
    border: none;
    box-shadow: var(--shadow);
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: var(--font-xl);
    z-index: 999;
    transition: var(--transition);
}

#chat-toggle:hover {
    background-color: #b30e20;
    transform: scale(1.1);
}



/* Responsive Design */
@media (max-width: 992px) {
    .header-content {
        flex-wrap: wrap;
    }
    
    .main-nav {
        order: 3;
        width: 100%;
        margin-top: var(--space-md);
        display: none;
    }
    
    .main-nav.active {
        display: block;
    }
    
    .nav-list {
        flex-direction: column;
        gap: var(--space-sm);
    }
    
    .search-item {
        margin-top: var(--space-md);
        width: 100%;
    }
    
    .search-container {
        width: 100%;
        border: #008000;
        
    }
    
    .mobile-menu-toggle {
        display: block;
    }
    
    .header-actions {
        margin-left: auto;
    }
}

@media (max-width: 768px) {
    .hero-title {
        font-size: var(--font-xl);
    }
    
    .hero-subtitle {
        font-size: var(--font-lg);
    }
    
    .features-grid {
        grid-template-columns: 1fr;
    }
    
    #cgp-chatbot {
        width: 100%;
        bottom: 0;
        right: 20px;
        border-radius: 0;
    }
    
    #chat-toggle {
        bottom: var(--space-sm);
        right: var(--space-sm);
        width: 50px;
        height: 50px;
    }
}

/* Print Styles */
@media print {
    .header, .footer, #chat-toggle, #cgp-chatbot {
        display: none !important;
    }
    
    body {
        background-color: var(--white);
        color: var(--black);
        font-size: 12pt;
        padding-left: 12px;
        padding-right: 12px;
    }
    
    .hero-section {
        background: var(--white) !important;
        color: var(--black) !important;
        padding: 0 !important;
    }
    
    .hero-section::before {
        display: none;
    }
    
    .hero-title, .hero-subtitle {
        text-shadow: none !important;
        color: var(--black) !important;
    }
    
    .btn-primary {
        display: none;
    }
}

/* Security Enhancements */
img {
    /* Prevent image hotlinking */
    pointer-events: none;
}

/* Disable text selection for non-content elements */
.header, .footer, .btn, .nav-link {
    user-select: none;
    -webkit-user-select: none;
}

/* Performance optimizations */
.feature-card, .btn {
    will-change: transform;
    backface-visibility: hidden;
}

/* Accessibility improvements */
@media (prefers-reduced-motion: reduce) {
    * {
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: 0.01ms !important;
        scroll-behavior: auto !important;
    }
}



/* Search Component Styles */
.nav-item.search-item {
    margin: 0 15px;
    position: relative;
}

.search-container {
    display: flex;
    align-items: center;
    background-color: #ffffff; /* Different from main bg */
    border: 2px solid #e0e6ed; /* Border color */
    border-radius: 30px; /* Rounded corners */
    padding: 5px 15px;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.05);
    transition: all 0.3s ease;
}

.search-container:focus-within {
    border-color: #1b9a63; /* Highlight color when focused */
    box-shadow: 0 2px 12px rgba(108, 92, 231, 0.2);
}

.search-input {
    flex: 1;
    border: none;
    background: transparent;
    padding: 8px 10px;
    font-size: 14px;
    color: #2d3436;
    outline: none;
    min-width: 300px;
}

.search-input::placeholder {
    color: #b2bec3;
}

.search-btn {
    background: transparent;
    border: none;
    color: #636e72;
    cursor: pointer;
    padding: 5px;
    transition: color 0.2s ease;
}

.search-btn:hover {
    color: #6c5ce7;
}

/* Responsive Adjustments */
@media (max-width: 768px) {
    .nav-item.search-item {
        margin: 10px 0;
        width: 100%;
    }
    
    .search-container {
        width: 100%;
        border-radius: 25px;
    }
}

@media (max-width: 576px) {
    .search-input {
        padding: 6px 8px;
        font-size: 13px;
    }
    
    .search-container {
        padding: 3px 10px;
    }
}



/* .faq-results-container {
    display: none;
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    background: white;
    border: 1px solid #ddd;
    border-radius: 4px;
    box-shadow: 0 2px 4px rgba(0,0,0,0.1);
    z-index: 1000;
    max-height: 400px;
    overflow-y: auto;
}

.faq-result-item {
    padding: 10px;
    border-bottom: 1px solid #eee;
    cursor: pointer;
}

.faq-result-item:hover {
    background-color: #f5f5f5;
}

.faq-result-item h4 {
    margin: 0 0 5px 0;
    color: #333;
}

.faq-result-item p {
    margin: 0;
    color: #666;
    font-size: 0.9em;
} */



/* search function */

/* Search Results Styling */
.faq-results-container {
    display: none;
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    background: var(--white);
    border: 1px solid var(--gray-200);
    border-radius: var(--border-radius);
    box-shadow: var(--shadow);
    z-index: 1000;
    max-height: 400px;
    overflow-y: auto;
    margin-top: var(--space-xs);
    padding-left: 1.3rem; /* Added consistent left padding */
    padding-bottom: 1.1rem; 
}

.faq-result-item {
    padding: var(--space-md);
    border-bottom: 1px solid var(--gray-200);
    cursor: pointer;
    transition: var(--transition);
}

.faq-result-item:last-child {
    border-bottom: none;
}

.faq-result-item:hover {
    background-color: var(--gray-100);
}

.faq-result-item h4 {
    margin: 0 0 var(--space-xs) 0;
    color: var(--guinea-green);
    font-size: var(--font-base);
    font-weight: 600;
}

.faq-result-item p {
    margin: 0;
    color: var(--gray-800);
    font-size: var(--font-sm);
    line-height: 1.5;
}

/* Highlight matching text */
.faq-result-item .highlight {
    background-color: var(--guinea-yellow);
    padding: 0 var(--space-xs);
    border-radius: 2px;
    font-weight: 600;
}

/* Helpful buttons section */
.faq-helpful-section {
    display: flex;
    align-items: center;
    gap: var(--space-md);
    margin-top: var(--space-sm);
    padding-top: var(--space-sm);
    border-top: 1px dashed var(--gray-200);
}

.faq-helpful-btn {
    background: none;
    border: none;
    color: var(--gray-500);
    font-size: var(--font-sm);
    cursor: pointer;
    display: flex;
    align-items: center;
    gap: var(--space-xs);
    transition: var(--transition);
}

.faq-helpful-btn:hover {
    color: var(--guinea-red);
}

.faq-helpful-btn i {
    font-size: var(--font-sm);
}

/* Responsive Design */
@media (max-width: 768px) {
    .faq-results-container {
        position: fixed;
        top: auto;
        bottom: 0;
        left: 0;
        right: 0;
        max-height: 60vh;
        border-radius: var(--border-radius-lg) var(--border-radius-lg) 0 0;
        box-shadow: 0 -2px 10px rgba(0, 0, 0, 0.1);
        padding-right: 5px;
    }

    .faq-result-item {
        padding: var(--space-md) var(--space-lg);
    }
}

/* Accessibility Focus */
.faq-result-item:focus {
    outline: 2px solid var(--guinea-yellow);
    outline-offset: -2px;
}

/* Loading State */
.faq-loading {
    padding: var(--space-md);
    text-align: center;
    color: var(--gray-500);
}

.faq-loading i {
    animation: spin 1s linear infinite;
    margin-right: var(--space-xs);
}

@keyframes spin {
    from { transform: rotate(0deg); }
    to { transform: rotate(360deg); }
}

/* No Results State */
.faq-no-results {
    padding: var(--space-md);
    text-align: center;
    color: var(--gray-500);
}

/* Category Labels */
.faq-category-label {
    display: inline-block;
    padding: var(--space-xs) var(--space-sm);
    background-color: var(--guinea-red);
    color: var(--white);
    font-size: var(--font-xs);
    border-radius: var(--border-radius);
    margin-bottom: var(--space-sm);
    text-transform: uppercase;
    letter-spacing: 0.5px;
}


/* Chatbot Width Adjustments */
#cgp-chatbot {
    /* Default mobile size (unchanged) */
    width: 100%;
    max-width: 100%;
}

/* Desktop/Laptop sizing */
@media (min-width: 769px) {
    #cgp-chatbot {
        width: 450px; /* Wider on desktop */
        max-width: 460px;
        right: 30px; /* Adjust position from right edge */
        bottom: 30px;
        
    }
    
    /* Optional: Make the chat messages area taller */
    .chatbot-body {
        min-height: 300px;
        max-height: 500px;
    }
    
    /* Make input area more spacious */
    .chat-input-group {
        gap: 8px;
    }
    
    .chat-input {
        padding: 8px 8px;
    }
    
    .send-btn {
        padding: 12px 20px;
        min-width: 80px;
    }
}



