/* --- Global Reset & Variables --- */
:root {
    --primary-green: #2E7D32;
    /* Lush Dominica Green */
    --primary-blue: #00ACC1;
    /* Caribbean Sea Cyan */
    --dark-overlay: rgba(0, 30, 15, 0.6);
    /* Dark green tint overlay */
    --glass-bg: rgba(255, 255, 255, 0.1);
    /* For Glassmorphism */
    --glass-border: rgba(255, 255, 255, 0.2);
    --text-light: #ffffff;
    --font-stack: 'Poppins', sans-serif;
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: var(--font-stack);
    color: var(--text-light);
    overflow-x: hidden;
    min-height: 100vh;
    display: flex;
    flex-direction: column;
}

/* Note: .container width is handled by Bootstrap — no override needed */

/* -------------------------------------------------------
   Text Contrast Fixes for Glassmorphism Surfaces
   Bootstrap's text-white-50 (50% opacity) is unreadable on
   semi-transparent glass backgrounds — override to 80% in context.
------------------------------------------------------- */
.glass-card .text-white-50,
.glass-inner .text-white-50 {
    opacity: 0.95 !important;
    color: #fff !important;
}

/* Ensure headings inside glass stay fully white */
.glass-card h1,
.glass-card h2,
.glass-card h3,
.glass-card h4,
.glass-card h5,
.glass-card h6,
.glass-inner h1,
.glass-inner h2,
.glass-inner h3,
.glass-inner h4,
.glass-inner h5,
.glass-inner h6 {
    color: #ffffff !important;
}

/* Utility class for secondary text that's still readable on glass */
.text-muted-light {
    color: rgba(255, 255, 255, 0.95) !important;
}

/* Small / lead text on glass — minimum readable opacity */
.glass-card .small,
.glass-card .lead,
.glass-inner .small,
.glass-inner .lead {
    color: rgba(255, 255, 255, 0.95) !important;
}


a {
    text-decoration: none;
    color: var(--text-light);
    transition: all 0.3s ease;
}

/* --- Background Styles --- */
.video-background-container {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: -2;
    overflow: hidden;
}

#backgroundImage {
    position: absolute;
    top: 50%;
    left: 50%;
    min-width: 100%;
    min-height: 100%;
    width: auto;
    height: auto;
    z-index: -2;
    transform: translateX(-50%) translateY(-50%);
    object-fit: cover;
}

.video-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: var(--dark-overlay);
    /* Adds a subtle gradient to make top nav readable */
    background: linear-gradient(to bottom, rgba(0, 0, 0, 0.8) 0%, var(--dark-overlay) 30%, var(--dark-overlay) 100%);
    z-index: -1;
}

/* --- Header Navigation --- */
header {
    padding: 1.5rem 0;
    position: absolute;
    width: 100%;
    z-index: 10;
}

.header-content {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.logo-text {
    font-weight: 700;
    font-size: 1.8rem;
    letter-spacing: 2px;
}

nav ul {
    list-style: none;
    display: flex;
    gap: 2rem;
    margin-bottom: 0;
    padding-left: 0;
}

nav ul li a {
    font-weight: 400;
    font-size: 0.95rem;
    opacity: 0.8;
}

nav ul li a:hover,
nav ul li a.active {
    opacity: 1;
}

.login-btn {
    border: 2px solid var(--text-light);
    padding: 0.5rem 1.5rem;
    border-radius: 30px;
    font-weight: 600;
}

.login-btn:hover {
    background: var(--text-light);
    color: var(--primary-green);
}

.mobile-nav-toggle {
    background: none;
    border: 1px solid rgba(255,255,255,0.3);
    color: white;
    font-size: 1.5rem;
    padding: 5px 10px;
    border-radius: 8px;
    cursor: pointer;
    transition: all 0.3s ease;
}

.mobile-nav-toggle.active {
    background: rgba(255,255,255,0.1);
    border-color: white;
}

.nav-container {
    display: flex;
    align-items: center;
    gap: 3rem;
    flex-grow: 1;
    justify-content: flex-end;
}

.nav-actions {
    display: flex;
    align-items: center;
}

/* --- Hero Section --- */
.hero-section {
    flex: 1;
    /* Takes available space pushing footer down */
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 160px 0 100px 0;
    /* Top padding accounts for fixed header */
}

.text-center {
    text-align: center;
}

.sub-headline {
    text-transform: uppercase;
    letter-spacing: 3px;
    font-weight: 300;
    margin-bottom: 1rem;
    color: rgba(255, 255, 255, 0.8);
}

.main-headline {
    font-size: 3.5rem;
    font-weight: 700;
    line-height: 1.2;
    margin-bottom: 1.5rem;
    max-width: 1024px;
    margin-left: auto;
    margin-right: auto;
}

.hero-description {
    font-size: 1.2rem;
    max-width: 600px;
    margin: 0 auto 4rem auto;
    opacity: 0.9;
}

/* --- Glassmorphism Registration Cards --- */
.registration-cards-container {
    display: flex;
    gap: 3rem;
    justify-content: center;
    flex-wrap: wrap;
}

.glass-card {
    background: var(--glass-bg);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    border: 1px solid var(--glass-border);
    border-radius: 20px;
    padding: 2.5rem 2rem;
    flex: 1;
    min-width: 300px;
    transition: transform 0.3s ease, background 0.3s ease;
}

/* .glass-card-wide kept for backward compat — glass-card is now full-width by default */
.glass-card.glass-card-wide {
    max-width: 100%;
    text-align: left;
}

.glass-card:hover {
    transform: translateY(-10px);
    background: rgba(255, 255, 255, 0.15);
}

.icon-wrapper {
    margin-bottom: 1.5rem;
}

.icon-wrapper svg {
    stroke: var(--text-light);
    opacity: 0.9;
}

.glass-card h2 {
    font-size: 1.5rem;
    margin-bottom: 1rem;
}

.glass-card p {
    margin-bottom: 2rem;
    font-size: 0.95rem;
    opacity: 0.95;
    line-height: 1.6;
}

/* --- Buttons --- */
.btn {
    display: inline-block;
    padding: 0.8rem 2rem;
    border-radius: 50px;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 1px;
    font-size: 0.9rem;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.2);
}

.btn-farmer {
    background-color: var(--primary-green);
}

.btn-farmer:hover {
    background-color: #388E3C;
    box-shadow: 0 6px 20px rgba(46, 125, 50, 0.4);
}

.btn-fisher {
    background-color: var(--primary-blue);
}

.btn-fisher:hover {
    background-color: #00BCD4;
    box-shadow: 0 6px 20px rgba(0, 172, 193, 0.4);
}

/* --- Footer --- */
footer {
    padding: 2rem 0;
    text-align: center;
    font-size: 0.9rem;
    opacity: 0.7;
}

.footer-content {
    display: flex;
    justify-content: center;
    gap: 2rem;
}

/* --- Responsive Design --- */
@media (max-width: 991px) {
    header {
        padding: 0.8rem 0;
        position: fixed;
        background: rgba(0, 30, 15, 0.95);
        backdrop-filter: blur(15px);
        -webkit-backdrop-filter: blur(15px);
        border-bottom: 1px solid rgba(255, 255, 255, 0.1);
        z-index: 1050;
    }

    .header-content {
        flex-direction: row;
        justify-content: space-between;
        align-items: center;
        width: 100%;
    }

    .nav-container {
        display: none !important; /* Force hide by default */
        position: fixed;
        top: 70px; /* Below header */
        left: 0;
        width: 100%;
        background: rgba(0, 30, 15, 0.98);
        backdrop-filter: blur(20px);
        -webkit-backdrop-filter: blur(20px);
        flex-direction: column;
        padding: 2.5rem 1rem;
        gap: 2rem;
        z-index: 1040;
        border-bottom: 1px solid rgba(255, 255, 255, 0.1);
        text-align: center;
        max-height: calc(100vh - 70px);
        overflow-y: auto;
    }

    .nav-container.active {
        display: flex !important; /* Show when active */
        animation: slideDownFade 0.3s cubic-bezier(0.4, 0, 0.2, 1) forwards;
    }

    @keyframes slideDownFade {
        from { opacity: 0; transform: translateY(-20px); }
        to { opacity: 1; transform: translateY(0); }
    }

    nav {
        width: 100%;
    }

    nav ul {
        flex-direction: column;
        gap: 2rem;
        width: 100%;
    }

    nav ul li a {
        font-size: 1.5rem;
        font-weight: 500;
        padding: 10px;
        opacity: 1;
    }

    .nav-actions {
        width: 100%;
        justify-content: center;
        margin-top: 1rem;
    }

    .login-btn {
        width: 90%;
        max-width: 300px;
        text-align: center;
        padding: 1rem;
        display: block;
        margin: 0 auto;
    }

    .hero-section {
        padding-top: 140px;
    }

    .registration-cards-container {
        flex-direction: column;
        align-items: stretch;
        gap: 2rem;
    }

    .glass-card {
        width: 100%;
    }

    .footer-content {
        flex-direction: column-reverse;
        gap: 1rem;
    }
}