/* ============================================
   UNIFIED LEXILAB DESIGN SYSTEM
   ============================================ */

:root {
    --primary-green: #4a9d6f;
    --dark-green: #2d5a3d;
    --light-green: #e5f4ec;
    --very-light-green: #f0f7f4;
    --accent-blue: #0066cc;
    --accent-blue-dark: #0052a3;
    --text-dark: #2d5a3d;
    --text-muted: #495057;
    --text-light: #6c757d;
    --white: #ffffff;
    --light-bg: #f8f9fa;
    --border: #dee2e6;
    --shadow-sm: 0 2px 8px rgba(0, 0, 0, 0.08);
    --shadow-md: 0 4px 16px rgba(0, 0, 0, 0.12);
    --shadow-lg: 0 8px 24px rgba(0, 0, 0, 0.15);
}

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

html {
    scroll-behavior: smooth;
}

body {
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
    line-height: 1.6;
    font-size: 1.05rem;
    color: var(--text-dark);
    background: var(--white);
    min-height: 100vh;
    overflow-x: hidden;
    display: flex;
    flex-direction: column;
}

.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
}

/* ============================================
   NAVIGATION
   ============================================ */

.top-nav {
    background: var(--white);
    box-shadow: var(--shadow-sm);
    position: sticky;
    top: 0;
    z-index: 1000;
    padding: 1rem 2rem;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.nav-left {
    display: flex;
    align-items: center;
    gap: 2rem;
}

.nav-right {
    display: flex;
    gap: 1.5rem;
    align-items: center;
}

.nav-link {
    text-decoration: none;
    color: var(--text-muted);
    font-weight: 600;
    font-size: 1rem;
    transition: all 0.2s ease;
    padding: 0.5rem 1rem;
    border-radius: 6px;
    font-family: 'Inter', sans-serif;
}

.nav-link:hover {
    color: var(--dark-green);
    background: var(--light-green);
}

.nav-link.active {
    color: var(--primary-green);
    background: var(--light-green);
}

.nav-left .nav-link {
    font-family: 'Inter', sans-serif;
    font-size: 1.5rem;
    font-weight: 900;
    color: var(--primary-green);
    padding: 0;
    margin: 0;
}

.nav-brand {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
}

.nav-logo {
    width: 56px;
    height: 56px;
    object-fit: contain;
}

.nav-left .nav-link:hover {
    background: none;
    color: var(--dark-green);
}

.mobile-menu-toggle {
    display: none;
    background: var(--primary-green);
    color: var(--white);
    border: none;
    padding: 0.5rem 0.75rem;
    border-radius: 6px;
    font-size: 1.1rem;
    cursor: pointer;
    font-weight: 700;
    margin-left: auto;
}

.mobile-menu-toggle:hover {
    background: var(--dark-green);
}

@media (max-width: 768px) {
    .top-nav {
        position: relative;
    }

    .mobile-menu-toggle {
        display: block;
    }

    .nav-right {
        display: none;
        position: absolute;
        top: 100%;
        right: 1rem;
        left: auto;
        flex-direction: column;
        align-items: flex-end;
        text-align: right;
        background: var(--white);
        padding: 0.85rem 1rem;
        box-shadow: var(--shadow-md);
        border-radius: 10px;
        min-width: 220px;
        z-index: 1001;
    }

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

/* ============================================
   FOOTER
   ============================================ */

footer {
    background: var(--dark-green);
    color: var(--white);
    text-align: center;
    padding: 2rem 0;
    margin-top: auto;
    border-top: 2px solid var(--primary-green);
    width: 100%;
}

footer p {
    font-size: 1rem;
    opacity: 0.95;
}

footer a {
    color: var(--light-green);
    text-decoration: none;
    font-weight: 600;
}

footer a:hover {
    text-decoration: underline;
}

/* ============================================
   BUTTONS
   ============================================ */

.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    padding: 0.85rem 1.75rem;
    border-radius: 6px;
    border: none;
    cursor: pointer;
    font-weight: 700;
    font-family: 'Inter', sans-serif;
    font-size: 1rem;
    transition: all 0.2s ease;
    text-decoration: none;
}

.btn-primary {
    background: var(--primary-green);
    color: var(--white);
}

.btn-primary:hover {
    background: var(--dark-green);
    transform: translateY(-2px);
    box-shadow: var(--shadow-lg);
}

.btn-secondary {
    background: transparent;
    color: var(--primary-green);
    border: 2px solid var(--primary-green);
}

.btn-secondary:hover {
    background: var(--light-green);
    transform: translateY(-2px);
    box-shadow: var(--shadow-md);
}

.btn-danger {
    background: #dc3545;
    color: var(--white);
}

.btn-danger:hover {
    background: #c82333;
    transform: translateY(-2px);
    box-shadow: var(--shadow-lg);
}

/* ============================================
   FORM ELEMENTS
   ============================================ */

input[type="text"],
input[type="email"],
input[type="password"],
input[type="number"],
input[type="date"],
select,
textarea {
    background: var(--white);
    color: var(--text-dark);
    border: 2px solid var(--border);
    border-radius: 8px;
    padding: 0.8rem 0.9rem;
    outline: none;
    transition: border-color 0.2s ease, box-shadow 0.2s ease;
    font-family: 'Inter', sans-serif;
    font-size: 1rem;
    width: 100%;
}

input::placeholder,
textarea::placeholder {
    color: var(--text-light);
}

input:focus,
select:focus,
textarea:focus {
    border-color: var(--primary-green);
    box-shadow: 0 0 0 3px rgba(74, 157, 111, 0.15);
}

select {
    appearance: none;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 12 12'%3E%3Cpath fill='%232d5a3d' d='M6 9L1 4h10z'/%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: right 12px center;
    padding-right: 36px;
}

/* ============================================
   ALERTS & MESSAGES
   ============================================ */

.alert {
    padding: 0.85rem 1rem;
    border-radius: 8px;
    font-weight: 700;
    margin-bottom: 1rem;
    border: 2px solid transparent;
}

.alert-success {
    background: #d4edda;
    border-color: #28a745;
    color: #155724;
}

.alert-error {
    background: #f8d7da;
    border-color: #dc3545;
    color: #721c24;
}

.alert-info {
    background: #d1ecf1;
    border-color: #17a2b8;
    color: #0c5460;
}

/* ============================================
   HEADINGS & TEXT
   ============================================ */

h1, h2, h3, h4, h5, h6 {
    font-family: 'Inter', sans-serif;
    font-weight: 900;
    line-height: 1.2;
    color: var(--text-dark);
}

h1 {
    font-size: 2.5rem;
}

h2 {
    font-size: 2rem;
}

h3 {
    font-size: 1.5rem;
}

p {
    margin-bottom: 1rem;
    color: var(--text-muted);
    line-height: 1.7;
    font-size: 1.05rem;
}

small,
.small {
    font-size: 0.95rem;
}

a {
    color: var(--primary-green);
    text-decoration: none;
    font-weight: 600;
    transition: all 0.2s ease;
}

a:hover {
    color: var(--dark-green);
    text-decoration: underline;
}

/* ============================================
   RESPONSIVE
   ============================================ */

@media (max-width: 768px) {
    .top-nav {
        padding: 1rem;
    }

    .nav-right {
        position: absolute;
        top: 100%;
        left: 0;
        right: 0;
        background: var(--white);
        flex-direction: column;
        padding: 1rem 2rem;
        box-shadow: var(--shadow-md);
        transform: translateY(-100%);
        opacity: 0;
        pointer-events: none;
        transition: all 0.3s ease;
    }

    .nav-right.active {
        transform: translateY(0);
        opacity: 1;
        pointer-events: all;
    }

    .mobile-menu-toggle {
        display: block;
    }

    h1 {
        font-size: 2rem;
    }

    h2 {
        font-size: 1.5rem;
    }

    h3 {
        font-size: 1.25rem;
    }
}

/* ============================================
   BLUE ACCENT WAVES & DIVIDERS
   ============================================ */

.wave-divider {
    position: relative;
    height: 100px;
    background: linear-gradient(to bottom, 
        var(--white) 0%, 
        rgba(0, 102, 204, 0.05) 100%);
    overflow: hidden;
}

.wave-divider::before {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: url('data:image/svg+xml,<svg viewBox="0 0 1200 80" xmlns="http://www.w3.org/2000/svg" preserveAspectRatio="none"><path d="M0,40 Q300,10 600,40 T1200,40 L1200,80 L0,80 Z" fill="%230066cc" opacity="0.08"/></svg>') no-repeat bottom center;
    background-size: cover;
}

.blue-accent-border {
    border-left: 4px solid var(--accent-blue);
    border-radius: 0 4px 4px 0;
    padding-left: 1rem;
}

.blue-accent-header {
    position: relative;
    padding-bottom: 1rem;
}

.blue-accent-header::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 60px;
    height: 3px;
    background: linear-gradient(to right, var(--accent-blue), rgba(0, 102, 204, 0));
    border-radius: 2px;
}
