body {
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
    line-height: 1.6;
    background-color: #f4f4f4;
    color: #333;
    margin: 0;
    padding: 0;
}

.container {
    max-width: 800px;
    margin: 5px auto;
    padding: 20px;
    background: #fff;
    border-radius: 8px;
    box-shadow: 0 2px 4px rgba(0,0,0,0.1);
}

h1 {
    color: #023020; 
    text-align: center;
    margin-bottom: 20px;
}


/* Buttons */
.btn {
    display: inline-block;
    width: auto;
    padding: 8px 14px;
    border-radius: 6px;
    border: 1px solid transparent;
    font-size: 14px;
    line-height: 1.2;
    text-decoration: none;
    text-align: center;
    cursor: pointer;
    background-color: #6c757d;
    border-color: #6c757d;
    color: #fff;
    white-space: nowrap;
    transition: background-color 0.15s ease, color 0.15s ease, border-color 0.15s ease, box-shadow 0.15s ease;
}

.btn:hover {
    background-color: #5c636a;
    border-color: #565b64;
    color: #fff;
}

.btn-primary {
    background-color: #11998e;
    border-color: #11998e;
    color: #fff;
}

.btn-primary:hover {
    background-color: #0e7c6b;
    border-color: #0d7060;
    color: #fff;
}

/* Navbar layout */
.navbar {
    display: flex;
    align-items: center;
    gap: 20px;
}

.navbar .container {
    display: flex;
    align-items: center;
    width: 100%;
    max-width: 800px;
    margin: 0 auto;
    padding: 5px 20px;
}

.navbar-brand {
    display: flex;
    align-items: center;
    gap: 15px;
    text-decoration: none;
    color: inherit;
    font-size: 20px;
    font-weight: bold;
    margin-right: 30px;
}

.nav-links {
    display: flex;
    align-items: center;
    gap: 20px;
    flex: 1;
}

/* Navbar logo styling */
.navbar-logo {
    height: 30px;
    width: auto;
    vertical-align: middle;
}


/* Optional spacing for buttons/links in the navbar - handled by gap property */

/* Inline debug label */
.debug {
    font-size: 12px;
    color: #6c757d; /* muted gray */
    margin-left: 8px;
}

/* Nav spacer to push items to far right */
.nav-spacer {
    flex-grow: 1;
}

/* Discover Groups button in header */
.btn-discover-groups {
    background-color: #007bff !important;
    border-color: #007bff !important;
    color: white !important;
    padding: 8px 14px !important;
    font-size: 14px !important;
    white-space: nowrap;
}

.btn-discover-groups:hover {
    background-color: #0056b3 !important;
    border-color: #004085 !important;
}

/* Create New Group button in header */
.btn-create-group {
    background-color: #28a745 !important;
    border-color: #28a745 !important;
    color: white !important;
    padding: 8px 14px !important;
    font-size: 14px !important;
    white-space: nowrap;
}

.btn-create-group:hover {
    background-color: #218838 !important;
    border-color: #1e7e34 !important;
}

/* Login and Sign up buttons in header */
.nav-links .btn-login {
    width: 80px !important;
    background-color: #1e40af !important;
    border-color: #1e40af !important;
    color: white !important;
    padding: 8px 14px !important;
    font-size: 14px !important;
    text-decoration: none !important;
    text-align: center !important;
    white-space: nowrap;
}

.nav-links .btn-login:hover {
    background-color: #1e3a8a !important;
    border-color: #1e3a8a !important;
}

.nav-links .btn-signup {
    width: 80px !important;
    background-color: #28a745 !important;
    border-color: #28a745 !important;
    color: white !important;
    padding: 8px 14px !important;
    font-size: 14px !important;
    text-decoration: none !important;
    text-align: center !important;
    white-space: nowrap;
}

.nav-links .btn-signup:hover {
    background-color: #218838 !important;
    border-color: #1e7e34 !important;
}

/* User Avatar Dropdown */
.user-dropdown {
    position: relative;
    display: inline-block;
}

.user-dropdown-toggle {
    display: flex;
    align-items: center;
    gap: 6px;
    padding: 4px 8px;
    background: transparent;
    border: none;
    cursor: pointer;
    border-radius: 6px;
    transition: background-color 0.15s ease;
}

.user-dropdown-toggle:hover {
    background-color: rgba(0, 0, 0, 0.05);
}

.user-avatar {
    width: 32px;
    height: 32px;
    border-radius: 50%;
    object-fit: cover;
    border: 2px solid #e9ecef;
}

.user-avatar-placeholder {
    display: flex;
    align-items: center;
    justify-content: center;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    font-weight: 600;
    font-size: 14px;
}

.dropdown-arrow {
    color: #6c757d;
    transition: transform 0.2s ease;
}

.user-dropdown.open .dropdown-arrow {
    transform: rotate(180deg);
}

.user-dropdown-menu {
    position: absolute;
    top: calc(100% + 8px);
    right: 0;
    min-width: 200px;
    background: white;
    border-radius: 8px;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.15);
    border: 1px solid #e9ecef;
    opacity: 0;
    visibility: hidden;
    transform: translateY(-10px);
    transition: opacity 0.2s ease, transform 0.2s ease, visibility 0.2s;
    z-index: 1000;
    padding: 8px 0;
}

.user-dropdown.open .user-dropdown-menu {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
}

.dropdown-item {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 10px 16px;
    color: #333;
    text-decoration: none;
    font-size: 14px;
    transition: background-color 0.15s ease;
}

.dropdown-item:hover {
    background-color: #f8f9fa;
}

.dropdown-item svg {
    flex-shrink: 0;
    color: #6c757d;
}

.dropdown-item:hover svg {
    color: #333;
}

.dropdown-item-danger {
    color: #dc3545;
}

.dropdown-item-danger svg {
    color: #dc3545;
}

.dropdown-item-danger:hover {
    background-color: #fff5f5;
}

.dropdown-divider {
    height: 1px;
    background-color: #e9ecef;
    margin: 8px 0;
}

/* Group Management Dropdown */
.group-dropdown {
    position: relative;
    display: inline-block;
}

.group-dropdown-menu {
    position: absolute;
    top: 100%;
    left: 0;
    background-color: white;
    border: 1px solid #ccc;
    border-radius: 4px;
    box-shadow: 0 2px 5px rgba(0,0,0,0.2);
    z-index: 1000;
    min-width: 200px;
    display: none;
}

.group-dropdown-menu.show {
    display: block;
}

.group-dropdown-menu .dropdown-item {
    display: block;
    width: 100%;
    padding: 8px 16px;
    color: #333;
    text-decoration: none;
    border: none;
    background: none;
    text-align: left;
    cursor: pointer;
    font-family: inherit;
    font-size: 14px;
    line-height: 1.5;
    border-bottom: 1px solid #eee;
    box-sizing: border-box;
}

.group-dropdown-menu .dropdown-item:last-child {
    border-bottom: none;
}

.group-dropdown-menu .dropdown-item:hover {
    background-color: #f8f9fa;
}

/* Hide mobile dropdown items on desktop */
.dropdown-item-mobile,
.dropdown-divider-mobile {
    display: none;
}

/* Responsive Design */
/* Responsive button sizing */
@media (max-width: 1200px) {
    .btn-login, .btn-signup {
        padding: 7px 12px !important;
        font-size: 13px !important;
    }
}

@media (max-width: 992px) {
    .btn-login, .btn-signup {
        padding: 6px 10px !important;
        font-size: 12px !important;
    }
}

@media (max-width: 768px) {
    /* Show mobile dropdown items on mobile */
    .dropdown-item-mobile {
        display: flex;
    }
    
    .dropdown-divider-mobile {
        display: block;
    }
    
    /* Hide Discover Groups button on mobile */
    .btn-discover-groups {
        display: none;
    }
    
    /* Hide Create New Group button on mobile */
    .btn-create-group {
        display: none;
    }
    
    /* Adjust navbar spacing for mobile */
    .navbar-brand {
        margin-right: 15px;
    }
    
    
    .nav-links {
        gap: 10px;
    }
    
    /* Adjust avatar dropdown for mobile */
    .user-dropdown-toggle {
        padding: 4px 6px;
    }
    
    .user-avatar {
        width: 28px;
        height: 28px;
    }
}

@media (max-width: 480px) {
    /* Further adjustments for very small screens */
    .navbar-brand {
        margin-right: 10px;
        gap: 10px;
        font-size: 18px;
    }
    
    .navbar-logo {
        height: 24px;
    }
    
    
    .nav-links {
        gap: 8px;
    }
    
    /* Make login/signup buttons smaller on mobile */
    .btn-login, .btn-signup {
        padding: 5px 10px !important;
        font-size: 12px !important;
    }
}

/* ========================================
   Site Footer
   ======================================== */
.site-footer {
    background-color: #2c3e50;
    color: #ecf0f1;
    padding: 10px 0;
    margin-top: 20px;
}

.site-footer .container {
    background: transparent;
    box-shadow: none;
    max-width: 1200px;
}

.footer-content {
    display: flex;
    flex-wrap: wrap;
    justify-content: space-between;
    align-items: center;
    gap: 20px;
}

.footer-copyright {
    font-size: 14px;
    color: #bdc3c7;
}

.footer-links {
    display: flex;
    gap: 20px;
}

.footer-links a {
    color: #ecf0f1;
    text-decoration: none;
    font-size: 14px;
    transition: color 0.2s ease;
}

.footer-links a:hover {
    color: #3498db;
}

.footer-social {
    display: flex;
    gap: 15px;
}

.footer-social a {
    color: #bdc3c7;
    transition: color 0.2s ease, transform 0.2s ease;
    display: flex;
    align-items: center;
    justify-content: center;
}

.footer-social a:hover {
    color: #3498db;
    transform: translateY(-2px);
}

@media (max-width: 768px) {
    .footer-content {
        flex-direction: column;
        text-align: center;
    }
    
    .footer-links {
        flex-wrap: wrap;
        justify-content: center;
    }
    
    .footer-social {
        justify-content: center;
    }
}

/* ========================================
   Cookie Consent Banner
   ======================================== */
.cookie-consent {
    position: fixed;
    bottom: 0;
    left: 0;
    right: 0;
    background-color: #2c3e50;
    color: #ecf0f1;
    padding: 15px 20px;
    z-index: 9999;
    box-shadow: 0 -2px 10px rgba(0, 0, 0, 0.2);
}

.cookie-consent-content {
    max-width: 1200px;
    margin: 0 auto;
    display: flex;
    flex-wrap: wrap;
    justify-content: space-between;
    align-items: center;
    gap: 15px;
}

.cookie-consent-content p {
    margin: 0;
    font-size: 14px;
    flex: 1;
    min-width: 200px;
}

.cookie-consent-buttons {
    display: flex;
    gap: 15px;
    align-items: center;
}

.cookie-learn-more {
    color: #3498db;
    text-decoration: none;
    font-size: 14px;
}

.cookie-learn-more:hover {
    text-decoration: underline;
}

.cookie-accept-btn {
    background-color: #27ae60;
    color: white;
    border: none;
    padding: 10px 25px;
    border-radius: 5px;
    cursor: pointer;
    font-size: 14px;
    font-weight: 600;
    transition: background-color 0.2s ease;
}

.cookie-accept-btn:hover {
    background-color: #2ecc71;
}

@media (max-width: 600px) {
    .cookie-consent-content {
        flex-direction: column;
        text-align: center;
    }
    
    .cookie-consent-buttons {
        width: 100%;
        justify-content: center;
    }
}

/* ========================================
   Form Input Styles
   ======================================== */
.form-input-standard {
    border-radius: .35rem;
    padding-top: .425rem;
    padding-bottom: .425rem;
}

.flex-label {
  /* Optional: Adds some space between label and input */
  margin-right: 5px;
  /* Ensures the label takes only its needed space */
  flex-shrink: 0;
}

.flex-input {
  /* The core flex property for the input */
  flex-grow: 1;
  /* Prevents the input from growing beyond its container */
  min-width: 0;
  box-sizing: border-box;
}
