/* ===========================
   CSS VARIABLES & GLOBAL RESET
   =========================== */

/* Color Variables */
:root {
    --old-gold: #D4AF37;
    --gold: #D4AF37;
    --dark-gold: #B8941F;
    --black: #000000;
    --off-black: #1a1a1a;
    --charcoal: #2d2d2d;
    --light-gold: #E8D99E;
    --cream: #FAF7F0;
    --white: #FFFFFF;
    --transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
}

/* Global Reset */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

/* Base Styles */
body {
    font-family: 'Montserrat', sans-serif;
    background: var(--cream);
    color: var(--off-black);
    line-height: 1.7;
    overflow-x: hidden;
}

h1, h2, h3, h4, h5, h6 {
    font-family: 'Cormorant Garamond', serif;
    font-weight: 600;
    line-height: 1.2;
}

/* ===========================
   NAVIGATION
   =========================== */

/* Main Navigation Bar */
nav {
    position: fixed;
    top: 0;
    width: 100%;
    background: transparent;
    z-index: 1000;
    padding: 0.9rem 5%;
    transition: var(--transition);
}

nav.scrolled {
    background: var(--black);
    padding: 0.8rem 5%;
    border-bottom: 1px solid rgba(207, 181, 59, 0.2);
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.3);
}

/* Navbar Container */
.nav-container {
    max-width: 4000px;
    margin: 0 auto;
    display: flex;
    justify-content: space-between;
    align-items: center
}

/* Logo Styling */
.logo {
    display: flex;
    align-items: center;
    gap: 15px;
    text-decoration: none;
    transition: var(--transition);
}

.logo img {
    height: 55px;
    width: auto;
    transition: var(--transition);
}

.logo-text {
    display: flex;
    flex-direction: column;
    line-height: 1.3;
}

.logo-text .fraternity-name {
    font-family: 'Cormorant Garamond', serif;
    font-size: 1.1rem;
    font-weight: 600;
    color: var(--gold);
    letter-spacing: 0.5px;
}

.logo-text .chapter-name {
    font-family: 'Cormorant Garamond', serif;
    font-size: 0.95rem;
    font-weight: 400;
    color: var(--gold);
    letter-spacing: 0.5px;
}

.logo:hover img {
    transform: scale(1.05);
}


/* Desktop Navigation Links */
.nav-links {
    display: flex;
    align-items: center;
    gap: 2rem;
    list-style: none;
    margin: 0;
    padding: 0;
}

.nav-links > li {
    position: relative;
}

.nav-links a {
    color: var(--cream);
    text-decoration: none;
    font-size: 0.9rem;
    font-weight: 500;
    letter-spacing: 0.5px;
    transition: var(--transition);
    position: relative;
    padding: 0.8rem 1.2rem;
    display: block;
}

.nav-links > li > a::after {
    content: '';
    position: absolute;
    bottom: 5px;
    left: 1.2rem;
    right: 1.2rem;
    width: calc(100% - 2.4rem);
    height: 2px;
    background: var(--gold);
    transform: scaleX(0);
    transition: var(--transition);
}

.nav-links > li > a:hover {
    color: var(--gold);
}

.nav-links > li > a:hover::after {
    transform: scaleX(1);
}

/* Dropdown Styles */
.nav-links li.has-dropdown > a {
    padding-right: 2rem;
}

.nav-links li.has-dropdown > a::before {
    content: '▼';
    position: absolute;
    right: 0.8rem;
    font-size: 0.7rem;
    transition: var(--transition);
}

.nav-links li.has-dropdown:hover > a::before {
    transform: rotate(180deg);
}

.dropdown {
    list-style: none;
    position: absolute;
    top: 100%;
    left: 0;
    background: rgba(0, 0, 0, 0.98);
    min-width: 220px;
    padding: 0.5rem 0;
    border: 1px solid rgba(207, 181, 59, 0.2);
    border-top: 2px solid var(--gold);
    opacity: 0;
    visibility: hidden;
    transform: translateY(-10px);
    transition: var(--transition);
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.5);
}

.nav-links li.has-dropdown:hover .dropdown {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
}

.dropdown li {
    width: 100%;
}

.dropdown a {
    padding: 0.8rem 1.5rem;
    font-size: 0.85rem;
    border-left: 3px solid transparent;
    transition: var(--transition);
}

.dropdown a:hover {
    background: rgba(207, 181, 59, 0.1);
    border-left-color: var(--gold);
    color: var(--gold);
    padding-left: 2rem;
}

.dropdown a::after {
    display: none;
}

/* Mobile Menu Button */
.mobile-menu-btn {
    display: none;
    background: none;
    border: none;
    color: var(--gold);
    font-size: 1.8rem;
    cursor: pointer;
    padding: 0.5rem;
    transition: var(--transition);
}

.mobile-menu-btn:hover {
    transform: scale(1.1);
}

/* Mobile Navigation Panel */
.mobile-nav {
    display: none;
    position: fixed;
    top: 0;
    right: -100%;
    width: 80%;
    max-width: 400px;
    height: 100vh;
    background: rgba(0, 0, 0, 0.98);
    padding: 2rem;
    transition: var(--transition);
    z-index: 999;
    overflow-y: auto;
    border-left: 2px solid var(--gold);
}

.mobile-nav.active {
    right: 0;
}

.mobile-nav-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 2rem;
    padding-bottom: 1rem;
    border-bottom: 1px solid var(--gold);
}

.mobile-nav-close {
    background: none;
    border: none;
    color: var(--gold);
    font-size: 2rem;
    cursor: pointer;
}

.mobile-nav-links {
    list-style: none;
}

.mobile-nav-links li {
    margin-bottom: 0.5rem;
}

.mobile-nav-links a {
    color: var(--cream);
    text-decoration: none;
    padding: 1rem;
    display: block;
    font-size: 1rem;
    border-left: 3px solid transparent;
    transition: var(--transition);
}

.mobile-nav-links a:hover {
    color: var(--gold);
    border-left-color: var(--gold);
    padding-left: 1.5rem;
}

.mobile-nav-links .mobile-dropdown-toggle {
    display: flex;
    justify-content: space-between;
    align-items: center;
    cursor: pointer;
}

.mobile-nav-links .mobile-dropdown-toggle::after {
    content: '+';
    font-size: 1.5rem;
    transition: var(--transition);
}

.mobile-nav-links .mobile-dropdown-toggle.active::after {
    content: '−';
}

.mobile-nav-links .mobile-dropdown {
    max-height: 0;
    overflow: hidden;
    transition: max-height 0.3s ease;
}

.mobile-nav-links .mobile-dropdown.active {
    max-height: 500px;
}

.mobile-nav-links .mobile-dropdown a {
    padding-left: 2rem;
    font-size: 0.9rem;
    color: var(--light-gold);
}

/* Mobile Overlay */
.mobile-overlay {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.8);
    z-index: 998;
}

.mobile-overlay.active {
    display: block;
}

/* ===========================
   HERO SECTION
   =========================== */

.hero {
    min-height: 100vh;
    min-width: 100vw;
    position: relative;
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
    padding: 0;
    margin: 0;
    background-image: 
        linear-gradient(135deg, rgba(0, 0, 0, 0.7) 0%, rgba(35, 31, 32, 0.6) 50%, rgba(26, 24, 25, 0.7) 100%),
        url('/assets/images/backdrop.png');
    background-size: cover;
    background-position: center;
    background-repeat: no-repeat;
    background-attachment: fixed;
}

.hero::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: 
        radial-gradient(circle at 20% 50%, rgba(207, 181, 59, 0.1) 0%, transparent 50%),
        radial-gradient(circle at 80% 80%, rgba(207, 181, 59, 0.08) 0%, transparent 50%);
    animation: pulseGlow 8s ease-in-out infinite;
    z-index: 1;
}

.hero-content {
    text-align: center;
    z-index: 2;
    position: relative;
    padding: 2rem;
    animation: fadeInUp 1.2s ease-out;
}

.hero-badge {
    display: inline-block;
    padding: 0.5rem 1.5rem;
    border: 1px solid var(--gold);
    color: var(--gold);
    font-size: 0.85rem;
    letter-spacing: 3px;
    text-transform: uppercase;
    margin-bottom: 2rem;
    animation: fadeIn 1s ease-out 0.3s both;
}

.hero h1 {
    font-size: clamp(3rem, 8vw, 6rem);
    color: var(--white);
    margin-bottom: 1rem;
    text-shadow: 0 4px 20px rgba(0, 0, 0, 0.8), 0 2px 10px rgba(207, 181, 59, 0.3);
    animation: fadeInUp 1s ease-out 0.5s both;
    line-height: 1.1;
}

.hero .motto {
    font-size: clamp(1.2rem, 2.5vw, 1.8rem);
    color: var(--gold);
    font-family: 'Cormorant Garamond', serif;
    font-style: italic;
    margin-bottom: 1rem;
    animation: fadeInUp 1s ease-out 0.7s both;
    text-shadow: 0 2px 10px rgba(0, 0, 0, 0.8);
}

.hero .tagline {
    font-size: clamp(1rem, 2vw, 1.3rem);
    color: var(--light-gold);
    margin-bottom: 3rem;
    animation: fadeInUp 1s ease-out 0.85s both;
    font-weight: 300;
    letter-spacing: 0.5px;
    text-shadow: 0 2px 8px rgba(0, 0, 0, 0.8);
}

/* ===========================
   PAGE HERO (Internal Pages)
   =========================== */

.page-hero {
    min-height: 50vh;
    background: linear-gradient(135deg, var(--black) 0%, var(--charcoal) 100%);
    display: flex;
    align-items: center;
    justify-content: center;
    padding-top: 100px;
    position: relative;
    overflow: hidden;
}

.page-hero::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: radial-gradient(circle at 50% 50%, rgba(207, 181, 59, 0.1) 0%, transparent 70%);
}

.page-hero-content {
    text-align: center;
    z-index: 2;
    padding: 2rem;
}

.page-hero h1 {
    font-size: clamp(2.5rem, 6vw, 4rem);
    color: var(--white);
    margin-bottom: 1rem;
}

.page-hero p {
    font-size: 1.2rem;
    color: var(--light-gold);
}

/* ===========================
   BUTTONS
   =========================== */

.cta-buttons {
    display: flex;
    gap: 1.5rem;
    justify-content: center;
    flex-wrap: wrap;
    animation: fadeInUp 1s ease-out 0.9s both;
}

.btn {
    padding: 1rem 2.5rem;
    text-decoration: none;
    font-weight: 600;
    letter-spacing: 1px;
    transition: var(--transition);
    border: 2px solid transparent;
    display: inline-block;
    font-size: 0.95rem;
    cursor: pointer;
}

.btn-primary {
    background: var(--gold);
    color: var(--black);
    border-color: var(--gold);
}

.btn-primary:hover {
    background: transparent;
    color: var(--gold);
    transform: translateY(-2px);
    box-shadow: 0 10px 30px rgba(207, 181, 59, 0.3);
}

.btn-secondary {
    background: transparent;
    color: var(--gold);
    border-color: var(--gold);
}

.btn-secondary:hover {
    background: var(--gold);
    color: var(--black);
    transform: translateY(-2px);
}

/* ===========================
   SECTIONS
   =========================== */

section {
    padding: 8rem 5%;
    max-width: 1400px;
    margin: 0 auto;
}

.section-header {
    text-align: center;
    margin-bottom: 5rem;
}

.section-label {
    display: inline-block;
    color: var(--dark-gold);
    font-size: 0.85rem;
    letter-spacing: 3px;
    text-transform: uppercase;
    margin-bottom: 1rem;
    font-weight: 600;
}

.section-title {
    font-size: clamp(2.5rem, 5vw, 4rem);
    color: var(--black);
    margin-bottom: 1.5rem;
}

.section-description {
    font-size: 1.15rem;
    color: var(--charcoal);
    max-width: 700px;
    margin: 0 auto;
    line-height: 1.8;
}

/* ===========================
   CARDS
   =========================== */

.card {
    background: var(--white);
    padding: 2rem;
    border: 1px solid rgba(0, 0, 0, 0.08);
    transition: var(--transition);
}

.card:hover {
    transform: translateY(-8px);
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.1);
    border-color: var(--gold);
}

/* ===========================
   GRID LAYOUTS
   =========================== */

.grid-2 {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(400px, 1fr));
    gap: 3rem;
    margin-top: 4rem;
}

.grid-3 {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 2.5rem;
    margin-top: 4rem;
}

.grid-4 {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 2rem;
    margin-top: 4rem;
}

/* ===========================
   MEMBER SECTION
   =========================== */

#members-container {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 320px));
    gap: 2rem;
    justify-content: center;
    max-width: 1400px;
    margin: 0 auto;
}

/* ===========================
   GALLERY
   =========================== */

.gallery-item {
    height: 300px;
    background: linear-gradient(135deg, var(--charcoal), var(--black));
    position: relative;
    overflow: hidden;
    cursor: pointer;
    border: 1px solid rgba(207, 181, 59, 0.2);
    transition: var(--transition);
}

.gallery-item:hover {
    transform: scale(1.05);
    border-color: 1px solid black;
}

.gallery-item::before {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    font-size: 3rem;
    opacity: 0.5;
}

.gallery-overlay {
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    background: linear-gradient(to top, rgba(0,0,0,0.9), transparent);
    padding: 1.5rem;
    transform: translateY(100%);
    transition: var(--transition);
}

.gallery-item:hover .gallery-overlay {
    transform: translateY(0);
}

.gallery-overlay h4 {
    color: var(--white);
    font-size: 1.1rem;
    margin-bottom: 0.3rem;
}

.gallery-overlay p {
    color: var(--light-gold);
    font-size: 0.85rem;
}

/* ===========================
   LIGHTBOX
   =========================== */

.lightbox {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.95);
    z-index: 9999;
    justify-content: center;
    align-items: center;
}

.lightbox.active {
    display: flex;
}

.lightbox-content {
    position: relative;
    max-width: 90%;
    max-height: 90%;
    display: flex;
    flex-direction: column;
    align-items: center;
}

.lightbox-image {
    max-width: 100%;
    max-height: 80vh;
    object-fit: contain;
    border: 2px solid var(--gold);
}

.lightbox-info {
    text-align: center;
    margin-top: 1rem;
    color: var(--white);
}

.lightbox-info h3 {
    color: var(--gold);
    font-size: 1.5rem;
    margin-bottom: 0.5rem;
}

.lightbox-info p {
    color: var(--light-gold);
    font-size: 1rem;
}

.lightbox-close {
    position: absolute;
    top: 20px;
    right: 40px;
    font-size: 3rem;
    color: var(--white);
    cursor: pointer;
    background: none;
    border: none;
    transition: var(--transition);
    z-index: 10000;
}

.lightbox-close:hover {
    color: var(--gold);
    transform: scale(1.1);
}

.lightbox-nav {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    font-size: 3rem;
    color: var(--white);
    cursor: pointer;
    background: rgba(0, 0, 0, 0.5);
    border: none;
    padding: 1rem 1.5rem;
    transition: var(--transition);
    user-select: none;
}

.lightbox-nav:hover {
    color: var(--gold);
    background: rgba(0, 0, 0, 0.8);
}

.lightbox-prev {
    left: 20px;
}

.lightbox-next {
    right: 20px;
}

.lightbox-counter {
    position: absolute;
    top: 20px;
    left: 50%;
    transform: translateX(-50%);
    color: var(--white);
    font-size: 1.2rem;
    background: rgba(0, 0, 0, 0.5);
    padding: 0.5rem 1.5rem;
    border-radius: 20px;
}

/* ===========================
   FOOTER
   =========================== */

footer {
    background: var(--black);
    color: var(--cream);
    padding: 4rem 5%;
    border-top: 1px solid var(--gold);
}

.footer-content {
    max-width: 1400px;
    margin: 0 auto;
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 3rem;
}

.footer-section h3 {
    color: var(--gold);
    font-size: 1.5rem;
    margin-bottom: 1.5rem;
}

.footer-section p,
.footer-section a {
    color: var(--cream);
    line-height: 1.8;
    text-decoration: none;
    font-size: 0.95rem;
}

.footer-section a:hover {
    color: var(--gold);
}

.footer-links {
    list-style: none;
}

.footer-links li {
    margin-bottom: 0.8rem;
}

.footer-motto {
    margin-top: 1rem;
    font-style: italic;
}

.footer-bottom {
    max-width: 1400px;
    margin: 3rem auto 0;
    padding-top: 2rem;
    border-top: 1px solid rgba(207, 181, 59, 0.2);
    text-align: center;
    color: var(--cream);
    font-size: 0.9rem;
}

.social-links {
    display: flex;
    gap: 1.5rem;
    margin-top: 1.5rem;
}

.social-links a {
    width: 50px;
    height: 50px;
    background: var(--black);
    color: var(--gold);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.3rem;
    text-decoration: none;
    transition: var(--transition);
    border: 1px solid var(--gold);
}

.social-links a:hover {
    background: var(--gold);
    color: var(--black);
    transform: translateY(-5px);
}

/* ===========================
   ANIMATIONS
   =========================== */

@keyframes pulseGlow {
    0%, 100% { opacity: 0.5; }
    50% { opacity: 1; }
}

@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(40px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes fadeIn {
    from { opacity: 0; }
    to { opacity: 1; }
}

.fade-in-section {
    opacity: 0;
    transform: translateY(30px);
    transition: opacity 0.8s ease-out, transform 0.8s ease-out;
}

.fade-in-section.visible {
    opacity: 1;
    transform: translateY(0);
}

/* ===========================
   RESPONSIVE DESIGN
   =========================== */

/* Tablets and Small Desktops */
@media (max-width: 1024px) {
    section {
        padding: 6rem 5%;
    }
}

/* Tablets */
@media (max-width: 768px) {
    /* Navigation */
    .nav-links {
        display: none;
    }

    .mobile-menu-btn {
        display: block;
    }

    .mobile-nav {
        display: block;
    }

    /* Logo */
    .logo {
        gap: 10px;
    }
    
    .logo img {
        height: 45px;
    }
    
    .logo-text .fraternity-name {
        font-size: 1rem;
    }
    
    .logo-text .chapter-name {
        font-size: 0.85rem;
    }

    /* Hero */
    .hero {
        background-attachment: scroll;
        margin-left: 0;
        width: 100%;
        padding-top: 60px;
    }

    .hero h1 {
        font-size: 2.5rem;
    }

    .hero .motto {
        font-size: 1.2rem;
    }

    /* Sections */
    section {
        padding: 4rem 5%;
    }

    /* Grids */
    .grid-2,
    .grid-3,
    .grid-4 {
        grid-template-columns: 1fr;
    }

    /* Member Container */
    #members-container {
        grid-template-columns: 1fr;
        max-width: 400px;
    }

    /* Buttons */
    .cta-buttons {
        flex-direction: column;
    }
}

/* Mobile Phones */
@media (max-width: 480px) {
    /* Logo */
    .logo img {
        height: 38px;
    }
    
    .logo-text .fraternity-name {
        font-size: 0.9rem;
    }
    
    .logo-text .chapter-name {
        font-size: 0.75rem;
    }

    /* Mobile Menu */
    .mobile-nav {
        width: 90%;
    }
}