/* ==========================================================================
   Variables & Font Definitions
   ========================================================================== */
:root {
    --primary-bg: #003569;
    --accent-color: #FdB916;
}

/* ==========================================================================
   Base Styles
   ========================================================================== */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    font-family: 'Geist Mono', monospace;
}

body {
    background-color: var(--primary-bg);
    color: white;
}

/* Basic Elements */
a {
    color: var(--accent-color);
    text-decoration: none;
}

section {
    margin-bottom: 2rem;
}

h1, h2 {
    margin-bottom: 1rem;
}

/* ==========================================================================
   Navigation
   ========================================================================== */
nav {
    background-color: var(--primary-bg);
    padding: 1rem;
    display: flex;
    justify-content: space-between;
    align-items: center;
    position: fixed;
    width: 100%;
    top: 0;
    z-index: 1000;
}

.logo {
    color: var(--accent-color);
    font-size: 1.5rem;
    font-weight: bold;
    text-decoration: none;
}

.nav-links {
    display: flex;
    gap: 2rem;
    list-style: none;
}

.nav-links a {
    color: var(--accent-color);
    text-decoration: none;
    transition: opacity 0.3s;
}

.nav-links a:hover {
    opacity: 0.8;
}

nav.scrolled {
    box-shadow: 0 2px 10px rgba(0,0,0,0.3);
}

/* Dropdown Menu */
.dropdown {
    position: relative;
}

.dropdown-content {
    display: none;
    position: absolute;
    background-color: var(--primary-bg);
    min-width: 160px;
    box-shadow: 0 8px 16px rgba(0,0,0,0.2);
    z-index: 1;
    border: 1px solid var(--accent-color);
}

.dropdown-content a {
    color: var(--accent-color);
    padding: 12px 16px;
    display: block;
    text-decoration: none;
}

.dropdown-content a:hover {
    background-color: #2a365a;
}

.dropdown:hover .dropdown-content {
    display: block;
}

/* Hamburger Menu */
.hamburger {
    display: none;
    flex-direction: column;
    cursor: pointer;
    padding: 10px;
}

.hamburger span {
    width: 25px;
    height: 3px;
    background-color: var(--accent-color);
    margin: 2px 0;
    transition: 0.4s;
}

/* ==========================================================================
   Layout Components
   ========================================================================== */
.content-wrapper {
    padding: 6rem 2rem 2rem;
    max-width: 1200px;
    margin: 0 auto;
}

.content {
    padding: 2rem;
    max-width: 1200px;
    margin: 0 auto;
}

/* Grid System */
.content-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 2rem;
    padding: 2rem;
    max-width: 1400px;
    margin: 0 auto;
}

/* Content Cards */
.content-card {
    background: var(--primary-bg);
    padding: 2rem;
    border-radius: 10px;
    border: 2px solid var(--accent-color);
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
    transition: transform 0.3s ease;
}

.content-card h2 {
    color: var(--accent-color);
    font-size: 2rem;
    margin-bottom: 1rem;
    text-align: center;
}

.content-card h3 {
    color: var(--accent-color);
    font-size: 1.8rem;
    margin-bottom: 1.5rem;
    text-align: center;
}

.content-card hr {
    border: none;
    height: 2px;
    background-color: var(--accent-color);
    margin: 1rem 0;
}

.content-card p {
    font-size: 1.1rem;
    line-height: 1.6;
    margin-bottom: 1rem;
    color: #ffffff;
}

.content-card ul {
    list-style-position: inside;
    margin: 1rem 0;
}

.content-card li {
    margin-bottom: 0.5rem;
    line-height: 1.6;
}

.content-card a {
    text-decoration: none;
    color: inherit;
    transition: opacity 0.2s;
}

.content-card a:hover {
    opacity: 0.8;
}

.content-card h3 a {
    color: var(--accent-color);
}

/* Section Titles */
.section-title {
    color: var(--accent-color);
    font-size: 3rem;
    text-align: center;
    margin-bottom: 3rem;
    padding-top: 2rem;
}

.section-subtitle {
    color: var(--accent-color);
    font-size: 2rem;
    margin: 3rem 0 1.5rem;
}

/* ==========================================================================
   Hero Section
   ========================================================================== */
.hero {
    height: 100vh;
    position: relative;
    display: flex;
    justify-content: center;
    align-items: center;
    text-align: center;
}

.hero-background img {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
    filter: blur(8px);
    -webkit-filter: blur(8px);
    z-index: -1;
}

.hero-content {
    z-index: 1;
    padding: 2rem;
}

.hero-title {
    font-size: 4.5rem;
    color: white;
    margin-bottom: 1.5rem;
    font-weight: bold;
}

.hero-subtitle {
    font-size: 1.5rem;
    color: white;
    max-width: 800px;
    line-height: 1.6;
}

.hero-logo {
    max-width: 500px;
    width: 100%;
    height: auto;
    margin-bottom: 2rem;
}

/* Scroll Arrow */
.scroll-arrow {
    position: absolute;
    bottom: 2rem;
    left: 50%;
    transform: translateX(-50%);
    color: white;
    font-size: 2rem;
    animation: bounce 2s infinite;
    cursor: pointer;
    transition: opacity 0.3s ease;
    opacity: 1;
    display: flex;
    align-items: center;
    justify-content: center;
    width: 40px;
    height: 40px;
    z-index: 10;
}

.arrow-fallback {
    display: none;
}

/* If Phosphor icon fails to load, show fallback */
.ph-arrow-down-bold:not(:before) + .arrow-fallback {
    display: inline-block;
}

@keyframes bounce {
    0%, 20%, 50%, 80%, 100% {
        transform: translateY(0) translateX(-50%);
    }
    40% {
        transform: translateY(-30px) translateX(-50%);
    }
    60% {
        transform: translateY(-15px) translateX(-50%);
    }
}

.scroll-arrow.hidden {
    opacity: 0;
}

/* ==========================================================================
   Content Sections
   ========================================================================== */
/* Text Boxes */
.text-box {
    padding: 4rem 2rem;
    max-width: 1200px;
    margin: 0 auto;
}

.content-box, .leadership-content {
    background-color: rgba(255, 255, 255, 0.05);
    padding: 2rem;
    border-radius: 8px;
    margin: 2rem 0;
}

.content-box p, .leadership-content p {
    margin-bottom: 1.5rem;
    line-height: 1.8;
    font-size: 1.1rem;
}

.content-box p:last-child, .leadership-content p:last-child {
    margin-bottom: 0;
}

/* Team Components */
.team-box {
    display: flex;
    flex-direction: column;
}

/* Sponsor Components */
.sponsor-logo {
    background: #ffffff;
    padding: 1rem;
    border-radius: 4px;
    margin-bottom: 1.5rem;
    display: flex;
    justify-content: center;
    align-items: center;
    position: relative;
}

.sponsor-logo::after {
    content: "ph arrow-square-out";
    position: absolute;
    top: 0.5rem;
    right: 0.5rem;
    width: 20px;
    height: 20px;
    background-size: contain;
    background-repeat: no-repeat;
    opacity: 0;
    transition: opacity 0.2s;
}

.sponsor-logo:hover::after {
    opacity: 1;
}

.sponsor-logo img {
    max-width: 200px;
    height: auto;
    display: block;
}

/* Alert Components */
.alert-box {
    background: rgba(255, 255, 255, 0.05);
    padding: 1.5rem;
    margin-bottom: 1.5rem;
    border-radius: 8px;
    border: 1px solid rgba(255, 255, 255, 0.1);
}

.alert-box h2 {
    margin: 0 0 0.5rem 0;
    color: #ffffff;
}

.alert-date {
    font-size: 0.9rem;
    color: #888;
    margin-bottom: 1rem;
}

.alert-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 0.5rem;
}

.alert-header h2 {
    margin: 0;
}

.alert-date {
    color: #666;
    font-size: 0.9em;
}

.alert-box p {
    margin: 0;
    line-height: 1.5;
}

/* ==========================================================================
   Form Elements
   ========================================================================== */
.form-group {
    margin-bottom: 1rem;
}

input, select, textarea {
    width: 100%;
    padding: 0.5rem;
    margin-top: 0.5rem;
    background: #2a365a;
    border: 1px solid var(--accent-color);
    color: white;
}

button {
    background: var(--accent-color);
    color: var(--primary-bg);
    padding: 0.5rem 1rem;
    border: none;
    cursor: pointer;
}

.google-form-container {
    width: 100%;
    max-width: 640px;
    margin: 0 auto;
    padding: 20px 0;
}

.google-form-container iframe {
    width: 100%;
    max-width: 640px;
    margin: 0 auto;
    display: block;
}

/* ==========================================================================
   Status Components
   ========================================================================== */
.loading {
    text-align: center;
    padding: 2rem;
    color: #888;
}

.error {
    color: #ff6b6b;
    text-align: center;
    padding: 1rem;
}

/* ==========================================================================
   Media Queries
   ========================================================================== */
@media screen and (max-width: 768px) {
    .hamburger {
        display: flex;
    }

    .nav-links {
        display: none;
        position: absolute;
        top: 100%;
        left: 0;
        right: 0;
        flex-direction: column;
        background-color: var(--primary-bg);
        padding: 1rem;
        gap: 1rem;
        border-top: 1px solid var(--accent-color);
    }

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

    /* Adjust dropdown positioning for mobile */
    .dropdown-content {
        position: static;
        width: 100%;
        box-shadow: none;
        border: none;
        background-color: transparent;
        padding-left: 1rem;
    }

    .dropdown-content a {
        padding: 0.5rem 1rem;
    }

    /* Hamburger animation classes */
    .hamburger.active span:nth-child(1) {
        transform: rotate(-45deg) translate(-5px, 6px);
    }

    .hamburger.active span:nth-child(2) {
        opacity: 0;
    }

    .hamburger.active span:nth-child(3) {
        transform: rotate(45deg) translate(-5px, -6px);
    }
}

@media (min-width: 992px) {
    .content-grid.sponsors {
        justify-content: center;
    }
    
    .content-grid.sponsors:has(.content-card:nth-child(1):last-child),
    .content-grid.sponsors:has(.content-card:nth-child(2):last-child) {
        grid-template-columns: repeat(auto-fit, 300px);
    }
}

/* ==========================================================================
   Admin Page Styles
   ========================================================================== */
.admin-container {
    max-width: 1000px;
    margin: 40px auto;
    padding: 20px;
}

.admin-form {
    padding: 20px;
    border-radius: 8px;
    margin-bottom: 30px;
}

.form-group {
    margin-bottom: 15px;
}

.admin-form label {
    display: block;
    margin-bottom: 5px;
    font-weight: bold;
}

.admin-form input[type="text"], .admin-form textarea {
    width: 100%;
    padding: 8px;
    border: 1px solid #ddd;
    border-radius: 4px;
    font-family: 'Geist Mono', monospace;
}

.admin-form textarea {
    min-height: 100px;
}

.admin-form button {
    padding: 10px 20px;
    background-color: #0a5688;
    color: white;
    border: none;
    border-radius: 4px;
    cursor: pointer;
    font-family: 'Geist Mono', monospace;
}

.admin-form button:hover {
    background-color: #083f66;
}

.cancel-btn {
    background-color: #777 !important;
}

.cancel-btn:hover {
    background-color: #555 !important;
}

.notice-list {
    padding: 20px;
    border-radius: 8px;
}

.notice-item {
    padding: 15px;
    border-bottom: 1px solid #ddd;
    position: relative;
}

.notice-item:last-child {
    border-bottom: none;
}

.notice-actions {
    position: absolute;
    right: 15px;
    top: 15px;
}

.action-button {
    background: none;
    border: none;
    cursor: pointer;
    margin-left: 10px;
    color: #0a5688;
    font-size: 14px;
}

.action-button:hover {
    text-decoration: underline;
}

.admin-notes {
    margin-top: 30px;
    padding: 15px;
    border-radius: 8px;
    font-size: 14px;
}

/* ==========================================================================
   Robot Timeline
   ========================================================================== */
.robot-image {
    width: 100%;
    border-radius: 8px;
    margin-bottom: 1rem;
    border: 2px solid var(--accent-color);
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.2);
    transition: transform 0.3s ease;
}

.robot-image:hover {
    transform: scale(1.02);
}

.content-card .robot-year {
    font-size: 1.2rem;
    color: var(--accent-color);
    margin-bottom: 0.5rem;
}

.robot-awards {
    margin-top: 1.5rem;
    padding-top: 1rem;
    border-top: 1px solid rgba(255, 255, 255, 0.2);
}

.robot-awards h3 {
    color: var(--accent-color);
    font-size: 1.3rem;
    margin-bottom: 0.5rem;
}

.robot-awards ul {
    list-style-type: disc;
    padding-left: 1.5rem;
}

.robot-awards li {
    margin-bottom: 0.5rem;
}
