/* ============================================
   CAPSWU - Main Stylesheet
   Colors: Dark Blue (#1a2744), Green (#2d8a4e),
           Gold (#c9a227), White (#ffffff),
           Light Gray (#f5f5f5)
   ============================================ */

/* CSS Variables */
:root {
    --dark-blue: #1a2744;
    --dark-blue-light: #243356;
    --dark-blue-dark: #111a30;
    --green: #2d8a4e;
    --green-light: #3ca55e;
    --green-dark: #1f6136;
    --gold: #c9a227;
    --gold-light: #dbb840;
    --gold-dark: #a0801f;
    --white: #ffffff;
    --off-white: #f8f9fa;
    --light-gray: #e9ecef;
    --medium-gray: #6c757d;
    --dark-gray: #343a40;
    --black: #212529;
    --red: #dc3545;
    --orange: #fd7e14;
    --blue: #0d6efd;
    
    --font-primary: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    --font-secondary: Georgia, 'Times New Roman', serif;
    
    --border-radius: 6px;
    --border-radius-lg: 10px;
    --box-shadow: 0 2px 8px rgba(0,0,0,0.1);
    --box-shadow-lg: 0 4px 16px rgba(0,0,0,0.15);
    --transition: all 0.3s ease;
    
    --navbar-height: 60px;
    --max-width: 1200px;
}

/* Reset */
*,
*::before,
*::after {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

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

body {
    font-family: var(--font-primary);
    line-height: 1.6;
    color: var(--dark-gray);
    background-color: var(--off-white);
    min-height: 100vh;
    display: flex;
    flex-direction: column;
}

/* Container */
.container {
    width: 100%;
    max-width: var(--max-width);
    margin: 0 auto;
    padding: 0 20px;
}

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

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

/* ============================================
   HEADER & LOGO
   ============================================ */
.site-header {
    background: var(--white);
    border-bottom: 3px solid var(--gold);
    padding: 15px 0;
    box-shadow: var(--box-shadow);
}

.site-header .container {
    display: flex;
    align-items: center;
    justify-content: center;
    flex-wrap: wrap;
    gap: 20px;
    text-align: center;
}

.logo-container {
    flex-shrink: 0;
}

.site-logo {
    max-height: 100px;
    width: auto;
    display: block;
}

.logo-fallback h1 {
    font-size: 2rem;
    color: var(--dark-blue);
    font-weight: 800;
    letter-spacing: 2px;
}

.union-title h2 {
    font-size: 1.1rem;
    color: var(--dark-blue);
    font-weight: 600;
    text-align: center;
    line-height: 1.4;
}

/* Language Switcher */
.lang-switcher {
    position: absolute;
    top: 10px;
    right: 20px;
    display: flex;
    gap: 5px;
}

.lang-switcher a {
    padding: 4px 10px;
    border: 1px solid var(--light-gray);
    border-radius: var(--border-radius);
    text-decoration: none;
    color: var(--medium-gray);
    font-size: 0.85rem;
    transition: var(--transition);
}

.lang-switcher a.active,
.lang-switcher a:hover {
    background: var(--dark-blue);
    color: var(--white);
    border-color: var(--dark-blue);
}

/* ============================================
   NAVIGATION BAR
   ============================================ */
.navbar {
    background: var(--dark-blue);
    position: sticky;
    top: 0;
    z-index: 1000;
    box-shadow: var(--box-shadow-lg);
}

.navbar .container {
    display: flex;
    align-items: center;
    justify-content: space-between;
    min-height: var(--navbar-height);
}

.nav-menu {
    display: flex;
    list-style: none;
    gap: 5px;
    flex-wrap: wrap;
}

.nav-menu li a {
    display: block;
    padding: 12px 16px;
    color: var(--white);
    text-decoration: none;
    font-size: 0.95rem;
    font-weight: 500;
    border-radius: var(--border-radius);
    transition: var(--transition);
    white-space: nowrap;
}

.nav-menu li a:hover,
.nav-menu li a.active {
    background: var(--green);
    color: var(--white);
}

.nav-menu li a.active {
    border-bottom: 3px solid var(--gold);
}

/* Nav toggle (mobile) */
.nav-toggle {
    display: none;
    background: none;
    border: none;
    color: var(--white);
    font-size: 1.5rem;
    cursor: pointer;
    padding: 10px;
}

.nav-user-info {
    display: flex;
    align-items: center;
    gap: 15px;
}

.user-greeting {
    color: var(--gold-light);
    font-size: 0.9rem;
    font-weight: 500;
}

.user-greeting i {
    margin-right: 5px;
}

/* ============================================
   HERO SECTION
   ============================================ */
.hero-section {
    background: linear-gradient(135deg, var(--dark-blue) 0%, var(--dark-blue-light) 100%);
    color: var(--white);
    padding: 80px 0;
    text-align: center;
    position: relative;
}

.hero-section::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    height: 5px;
    background: linear-gradient(90deg, var(--green), var(--gold), var(--green));
}

.hero-content h1 {
    font-size: 2.5rem;
    font-weight: 800;
    margin-bottom: 15px;
    color: var(--white);
}

.hero-content p {
    font-size: 1.2rem;
    margin-bottom: 30px;
    color: rgba(255,255,255,0.9);
}

/* ============================================
   BUTTONS
   ============================================ */
.btn {
    display: inline-block;
    padding: 12px 28px;
    font-size: 1rem;
    font-weight: 600;
    text-decoration: none;
    border: none;
    border-radius: var(--border-radius);
    cursor: pointer;
    transition: var(--transition);
    text-align: center;
    line-height: 1.4;
}

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

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

.btn-secondary {
    background: var(--dark-blue);
    color: var(--white);
}

.btn-secondary:hover {
    background: var(--dark-blue-dark);
    transform: translateY(-2px);
}

.btn-gold {
    background: var(--gold);
    color: var(--dark-blue);
}

.btn-gold:hover {
    background: var(--gold-dark);
    color: var(--white);
}

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

.btn-danger:hover {
    background: #c82333;
}

.btn-warning {
    background: var(--orange);
    color: var(--white);
}

.btn-sm {
    padding: 6px 14px;
    font-size: 0.85rem;
}

.btn-lg {
    padding: 16px 36px;
    font-size: 1.1rem;
}

.btn-block {
    display: block;
    width: 100%;
}

.btn:disabled {
    opacity: 0.6;
    cursor: not-allowed;
}

/* ============================================
   CARDS
   ============================================ */
.card {
    background: var(--white);
    border-radius: var(--border-radius-lg);
    padding: 25px;
    box-shadow: var(--box-shadow);
    transition: var(--transition);
    border: 1px solid var(--light-gray);
}

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

.card-header {
    border-bottom: 2px solid var(--light-gray);
    padding-bottom: 15px;
    margin-bottom: 15px;
}

.card-header h3 {
    color: var(--dark-blue);
    font-size: 1.3rem;
}

.card-footer {
    border-top: 1px solid var(--light-gray);
    padding-top: 15px;
    margin-top: 15px;
}

/* ============================================
   FORMS
   ============================================ */
.form-group {
    margin-bottom: 20px;
}

.form-group label {
    display: block;
    margin-bottom: 6px;
    font-weight: 600;
    color: var(--dark-gray);
    font-size: 0.95rem;
}

.form-group label .required {
    color: var(--red);
}

.form-control {
    width: 100%;
    padding: 10px 14px;
    border: 2px solid var(--light-gray);
    border-radius: var(--border-radius);
    font-size: 1rem;
    font-family: var(--font-primary);
    transition: var(--transition);
    background: var(--white);
}

.form-control:focus {
    outline: none;
    border-color: var(--green);
    box-shadow: 0 0 0 3px rgba(45, 138, 78, 0.15);
}

.form-control.error {
    border-color: var(--red);
}

textarea.form-control {
    min-height: 120px;
    resize: vertical;
}

select.form-control {
    cursor: pointer;
    appearance: auto;
}

.form-check {
    display: flex;
    align-items: flex-start;
    gap: 10px;
}

.form-check input[type="checkbox"],
.form-check input[type="radio"] {
    margin-top: 4px;
    width: 18px;
    height: 18px;
    accent-color: var(--green);
}

.form-text {
    font-size: 0.85rem;
    color: var(--medium-gray);
    margin-top: 4px;
}

.form-section {
    background: var(--white);
    border-radius: var(--border-radius-lg);
    padding: 30px;
    margin-bottom: 25px;
    border-left: 4px solid var(--dark-blue);
    box-shadow: var(--box-shadow);
}

.form-section h3 {
    color: var(--dark-blue);
    margin-bottom: 20px;
    padding-bottom: 10px;
    border-bottom: 2px solid var(--light-gray);
    font-size: 1.2rem;
}

.form-row {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 20px;
}

.form-row-3 {
    display: grid;
    grid-template-columns: 1fr 1fr 1fr;
    gap: 20px;
}

/* ============================================
   ALERTS / MESSAGES
   ============================================ */
.alert {
    padding: 15px 20px;
    border-radius: var(--border-radius);
    margin-bottom: 20px;
    display: flex;
    align-items: center;
    gap: 12px;
    font-weight: 500;
    position: relative;
    border-left: 5px solid;
}

.alert i {
    font-size: 1.2rem;
}

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

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

.alert-warning {
    background: #fff3cd;
    color: #856404;
    border-left-color: #ffc107;
}

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

.alert-close {
    margin-left: auto;
    background: none;
    border: none;
    font-size: 1.4rem;
    cursor: pointer;
    color: inherit;
    opacity: 0.6;
}

.alert-close:hover {
    opacity: 1;
}

/* ============================================
   TABLES
   ============================================ */
.table-container {
    overflow-x: auto;
    background: var(--white);
    border-radius: var(--border-radius-lg);
    box-shadow: var(--box-shadow);
}

table {
    width: 100%;
    border-collapse: collapse;
}

table th,
table td {
    padding: 14px 16px;
    text-align: left;
    border-bottom: 1px solid var(--light-gray);
}

table th {
    background: var(--dark-blue);
    color: var(--white);
    font-weight: 600;
    font-size: 0.9rem;
    white-space: nowrap;
}

table tr:hover {
    background: #f8f9fa;
}

table tr:nth-child(even) {
    background: #fafafa;
}

table tr:nth-child(even):hover {
    background: #f0f0f0;
}

/* ============================================
   BADGES
   ============================================ */
.badge {
    display: inline-block;
    padding: 4px 12px;
    border-radius: 20px;
    font-size: 0.8rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.badge-success { background: #d4edda; color: #155724; }
.badge-danger { background: #f8d7da; color: #721c24; }
.badge-warning { background: #fff3cd; color: #856404; }
.badge-info { background: #d1ecf1; color: #0c5460; }
.badge-primary { background: #cce5ff; color: #004085; }
.badge-secondary { background: #e2e3e5; color: #383d41; }
.badge-dark { background: #d6d8d9; color: #1b1e21; }

/* ============================================
   PAGINATION
   ============================================ */
.pagination {
    display: flex;
    justify-content: center;
    gap: 5px;
    margin-top: 25px;
    flex-wrap: wrap;
}

.page-link {
    display: inline-block;
    padding: 8px 14px;
    border: 1px solid var(--light-gray);
    border-radius: var(--border-radius);
    color: var(--dark-blue);
    text-decoration: none;
    transition: var(--transition);
    font-weight: 500;
}

.page-link:hover {
    background: var(--dark-blue);
    color: var(--white);
    border-color: var(--dark-blue);
}

.page-link.active {
    background: var(--green);
    color: var(--white);
    border-color: var(--green);
}

/* ============================================
   SECTIONS
   ============================================ */
.section {
    padding: 60px 0;
}

.section-title {
    text-align: center;
    margin-bottom: 40px;
}

.section-title h2 {
    font-size: 2rem;
    color: var(--dark-blue);
    position: relative;
    display: inline-block;
    padding-bottom: 10px;
}

.section-title h2::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 50%;
    transform: translateX(-50%);
    width: 60px;
    height: 3px;
    background: var(--gold);
}

/* Grid layouts */
.grid-2 {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 25px;
}

.grid-3 {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 25px;
}

.grid-4 {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 25px;
}

/* ============================================
   STATS CARDS
   ============================================ */
.stats-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 20px;
    margin-bottom: 30px;
}

.stat-card {
    background: var(--white);
    border-radius: var(--border-radius-lg);
    padding: 25px;
    text-align: center;
    box-shadow: var(--box-shadow);
    border-top: 4px solid var(--dark-blue);
    transition: var(--transition);
}

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

.stat-card.primary { border-top-color: var(--dark-blue); }
.stat-card.success { border-top-color: var(--green); }
.stat-card.warning { border-top-color: var(--gold); }
.stat-card.danger { border-top-color: var(--red); }

.stat-number {
    font-size: 2.5rem;
    font-weight: 800;
    color: var(--dark-blue);
}

.stat-label {
    color: var(--medium-gray);
    font-size: 0.95rem;
    margin-top: 5px;
}

.stat-icon {
    font-size: 2rem;
    color: var(--green);
    margin-bottom: 10px;
}

/* ============================================
   FOOTER
   ============================================ */
.site-footer {
    background: var(--dark-blue);
    color: var(--white);
    padding: 50px 0 0;
    margin-top: auto;
}

.footer-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 40px;
    padding-bottom: 40px;
}

.footer-col h3 {
    color: var(--gold);
    margin-bottom: 20px;
    font-size: 1.2rem;
    position: relative;
    padding-bottom: 10px;
}

.footer-col h3::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 40px;
    height: 2px;
    background: var(--green);
}

.footer-col ul {
    list-style: none;
}

.footer-col ul li {
    margin-bottom: 10px;
}

.footer-col ul li a {
    color: rgba(255,255,255,0.8);
    text-decoration: none;
    transition: var(--transition);
}

.footer-col ul li a:hover {
    color: var(--gold);
    padding-left: 5px;
}

.footer-motto {
    color: var(--gold-light);
    font-style: italic;
    margin-top: 10px;
}

.contact-info li {
    display: flex;
    align-items: center;
    gap: 10px;
    color: rgba(255,255,255,0.8);
}

.contact-info li i {
    color: var(--gold);
    width: 20px;
}

.footer-bottom {
    text-align: center;
    padding: 20px 0;
    border-top: 1px solid rgba(255,255,255,0.1);
    color: rgba(255,255,255,0.6);
    font-size: 0.9rem;
}

/* ============================================
   AUTH PAGES (Login, Register)
   ============================================ */
.auth-container {
    min-height: 70vh;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 40px 20px;
    background: var(--off-white);
}

.auth-box {
    background: var(--white);
    border-radius: var(--border-radius-lg);
    padding: 40px;
    max-width: 500px;
    width: 100%;
    box-shadow: var(--box-shadow-lg);
    border-top: 5px solid var(--dark-blue);
}

.auth-box h2 {
    text-align: center;
    color: var(--dark-blue);
    margin-bottom: 10px;
    font-size: 1.6rem;
}

.auth-box .auth-logo {
    text-align: center;
    margin-bottom: 25px;
}

.auth-box .auth-logo img {
    max-height: 80px;
}

.auth-links {
    text-align: center;
    margin-top: 20px;
    font-size: 0.9rem;
}

.auth-links a {
    color: var(--green);
    text-decoration: none;
    font-weight: 600;
}

.auth-links a:hover {
    text-decoration: underline;
}

/* ============================================
   PROFILE PAGE
   ============================================ */
.profile-header {
    display: flex;
    align-items: center;
    gap: 30px;
    background: var(--white);
    border-radius: var(--border-radius-lg);
    padding: 30px;
    box-shadow: var(--box-shadow);
    margin-bottom: 30px;
}

.profile-photo {
    width: 120px;
    height: 120px;
    border-radius: 50%;
    object-fit: cover;
    border: 4px solid var(--green);
}

.profile-photo-placeholder {
    width: 120px;
    height: 120px;
    border-radius: 50%;
    background: var(--light-gray);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 3rem;
    color: var(--medium-gray);
}

/* ============================================
   DASHBOARD
   ============================================ */
.dashboard-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 25px;
}

/* ============================================
   NEWS & EVENTS GRID
   ============================================ */
.news-grid,
.events-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 25px;
}

.news-card img,
.event-card img {
    width: 100%;
    height: 200px;
    object-fit: cover;
    border-radius: var(--border-radius) var(--border-radius) 0 0;
}

.news-card .card-body,
.event-card .card-body {
    padding: 20px;
}

.news-card .date,
.event-card .date {
    color: var(--medium-gray);
    font-size: 0.85rem;
}

/* ============================================
   PRIORITY INDICATORS
   ============================================ */
.priority {
    display: inline-block;
    padding: 3px 10px;
    border-radius: 3px;
    font-size: 0.75rem;
    font-weight: 700;
    text-transform: uppercase;
    margin-bottom: 10px;
}

.priority-low { background: #d4edda; color: #155724; }
.priority-medium { background: #fff3cd; color: #856404; }
.priority-high { background: #f8d7da; color: #721c24; }
.priority-urgent { background: #dc3545; color: #fff; }

/* ============================================
   SEARCH & FILTER
   ============================================ */
.search-filter-bar {
    display: flex;
    gap: 15px;
    align-items: center;
    flex-wrap: wrap;
    margin-bottom: 25px;
    padding: 20px;
    background: var(--white);
    border-radius: var(--border-radius-lg);
    box-shadow: var(--box-shadow);
}

.search-input {
    flex: 1;
    min-width: 250px;
}

/* ============================================
   MODAL
   ============================================ */
.modal-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0,0,0,0.6);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 2000;
}

.modal-content {
    background: var(--white);
    border-radius: var(--border-radius-lg);
    padding: 30px;
    max-width: 600px;
    width: 90%;
    max-height: 80vh;
    overflow-y: auto;
}

/* ============================================
   UTILITY CLASSES
   ============================================ */
.text-center { text-align: center; }
.text-right { text-align: right; }
.text-left { text-align: left; }
.text-success { color: var(--green); }
.text-danger { color: var(--red); }
.text-warning { color: var(--gold-dark); }
.text-muted { color: var(--medium-gray); }

.mt-0 { margin-top: 0; }
.mt-1 { margin-top: 10px; }
.mt-2 { margin-top: 20px; }
.mt-3 { margin-top: 30px; }
.mb-1 { margin-bottom: 10px; }
.mb-2 { margin-bottom: 20px; }
.mb-3 { margin-bottom: 30px; }
.my-2 { margin-top: 20px; margin-bottom: 20px; }
.py-2 { padding-top: 20px; padding-bottom: 20px; }

.d-none { display: none; }
.d-flex { display: flex; }
.d-grid { display: grid; }
.align-center { align-items: center; }
.justify-between { justify-content: space-between; }
.flex-wrap { flex-wrap: wrap; }
.gap-10 { gap: 10px; }
.gap-15 { gap: 15px; }
.gap-20 { gap: 20px; }

.w-full { width: 100%; }

/* ============================================
   RESPONSIVE DESIGN
   ============================================ */
@media (max-width: 1024px) {
    .grid-3, .news-grid, .events-grid {
        grid-template-columns: repeat(2, 1fr);
    }
    .grid-4 {
        grid-template-columns: repeat(2, 1fr);
    }
    .stats-grid {
        grid-template-columns: repeat(2, 1fr);
    }
    .dashboard-grid {
        grid-template-columns: 1fr;
    }
    .form-row-3 {
        grid-template-columns: 1fr 1fr;
    }
}

@media (max-width: 768px) {
    .nav-toggle {
        display: block;
    }
    
    .nav-menu {
        display: none;
        flex-direction: column;
        width: 100%;
        position: absolute;
        top: var(--navbar-height);
        left: 0;
        background: var(--dark-blue);
        padding: 10px 0;
    }
    
    .nav-menu.active {
        display: flex;
    }
    
    .nav-menu li a {
        border-radius: 0;
        padding: 12px 20px;
    }
    
    .grid-2, .grid-3, .grid-4,
    .news-grid, .events-grid,
    .stats-grid, .footer-grid,
    .form-row, .form-row-3 {
        grid-template-columns: 1fr;
    }
    
    .hero-content h1 {
        font-size: 1.8rem;
    }
    
    .site-header .container {
        flex-direction: column;
        text-align: center;
    }
    
    .lang-switcher {
        position: static;
    }
    
    .profile-header {
        flex-direction: column;
        text-align: center;
    }
    
    .search-filter-bar {
        flex-direction: column;
    }
    
    .table-container {
        font-size: 0.9rem;
    }
    
    table th, table td {
        padding: 10px;
    }
}

@media (max-width: 480px) {
    .auth-box {
        padding: 25px;
    }
    
    .section {
        padding: 40px 0;
    }
    
    .form-section {
        padding: 20px;
    }
    
    .btn {
        padding: 10px 20px;
    }
}

/* Print styles */
@media print {
    .navbar, .site-footer, .nav-toggle,
    .lang-switcher, .alert, .btn {
        display: none !important;
    }
    
    body {
        background: white;
        color: black;
    }
    
    .container {
        max-width: 100%;
    }
    
    .card, .form-section {
        box-shadow: none;
        border: 1px solid #ddd;
    }
}
```
