@font-face {
    font-family: 'Blinker';
    src: url('https://static.igem.wiki/teams/5836/fonts/blinker/blinker-regular.ttf') format('truetype');
    font-weight: normal;
    font-style: normal;
    font-display: swap;
}

@font-face {
    font-family: 'Raleway';
    src: url('https://static.igem.wiki/teams/5836/fonts/raleway/raleway-regular.ttf') format('truetype');
    font-weight: normal;
    font-style: normal;
    font-display: swap;
}

@font-face {
    font-family: 'Nixie One';
    src: url('') format('truetype');
    font-weight: normal;
    font-style: normal;
    font-display: swap;
}

@font-face {
    font-family: 'Fraunces';
    src: url('https://static.igem.wiki/teams/5836/fonts/fraunces/fraunces-72pt-regular.ttf') format('truetype');
    font-weight: normal;
    font-style: normal;
    font-display: swap;
}

/* Background color for the entire page */
body {
    background-color: #0b1320 !important;
}

/* Alternative: If the above doesn't work, target the page content wrapper */
#page_content {
    background-color: #0b1320 !important;
}

/* Also ensure the main container has the background */
.main-content,
.container-fluid,
main {
    background-color: #0b1320 !important;
}

/* Hero Section */
.awards-hero {
    display: flex;
    align-items: center;
    justify-content: center;
    min-height: 60vh;
    background-color: #0b1320;
    position: relative;
    overflow: hidden;
}



.hero-content {
    text-align: center;
    z-index: 2;
    position: relative;
}

.hero-title {
    font-family: 'Fraunces', serif;
    font-size: clamp(2.5rem, 6vw, 8rem);
    font-weight: bold;
    color: #D7AF6B;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    margin: 0;
    line-height: 1.1;
    opacity: 0;
    transform: translateY(50px);
    animation: fadeInUp 1.5s ease-out forwards;
    text-shadow: 3px 3px 6px rgba(0, 0, 0, 0.9);
    text-align: center;
    display: block;
}

/* Fade in from below animation */
@keyframes fadeInUp {
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* Gold Medal in Hero Section */
.gold-medal-container {
    margin: 2rem 0 1.5rem 0;
    display: flex;
    justify-content: center;
    align-items: center;
}

.hero-gold-medal {
    width: 120px;
    height: 120px;
    object-fit: contain;
    filter: drop-shadow(0 0 15px rgba(215, 175, 107, 0.5));
    animation: flyToPosition 3s ease-in-out forwards;
}

@keyframes flyToPosition {
    0% {
        opacity: 0;
        transform: translateX(-100vw) translateY(-30vh) scale(0.3) rotate(0deg);
    }
    10% {
        opacity: 1;
    }
    70% {
        transform: translateX(10%) translateY(0) scale(1.1) rotate(360deg);
    }
    85% {
        transform: translateX(-5%) translateY(0) scale(0.95) rotate(380deg);
    }
    100% {
        opacity: 1;
        transform: translateX(0) translateY(0) scale(1) rotate(360deg);
    }
}

/* Hero Description Paragraph */
.hero-description {
    font-family: 'Raleway', sans-serif;
    font-size: clamp(1rem, 2vw, 1.25rem);
    color: #e8e8e8;
    max-width: 800px;
    margin: 0 auto;
    line-height: 1.6;
    opacity: 0;
    transform: translateY(30px);
    animation: fadeInUp 1.5s ease-out 1s forwards;
    text-align: center;
    padding: 0 1rem;
}

/* Main Content Section */
.awards-content {
    background-color: #0b1320;
    padding: 4rem 0;
    min-height: 40vh;
}

/* Roadmap Graph Container */
.roadmap-graph {
    max-width: 1200px;
    margin: 0 auto;
    padding: 2rem;
    position: relative;
}

/* Graph Level Styling */
.graph-level {
    margin: 6rem 0;
    position: relative;
    z-index: 10;
}

.node-row {
    display: grid;
    align-items: center;
    gap: 2rem;
    justify-items: center;
}

/* Level-specific grid layouts */
.level-0 .node-row {
    grid-template-columns: 1fr;
    justify-content: center;
}

.level-1 .node-row {
    grid-template-columns: repeat(6, 1fr);
    max-width: 100%;
}

.level-2 .node-row,
.level-4 .node-row,
.level-6 .node-row {
    grid-template-columns: 1fr;
    justify-content: center;
}

.level-3 .node-row {
    grid-template-columns: repeat(2, 1fr);
    max-width: 50%;
    margin: 0 auto;
}

.level-5 .node-row {
    grid-template-columns: repeat(3, 1fr);
    max-width: 60%;
    margin: 0 auto;
}

/* Individual Node Styling */
.node {
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
    max-width: 150px;
    position: relative;
    z-index: 10;
}

.node-link {
    display: flex;
    flex-direction: column;
    align-items: center;
    text-decoration: none;
    transition: transform 0.3s ease;
}

.node-link:hover {
    transform: scale(1.5);
    z-index: 10;
    position: relative;
}

.node-image {
    width: 80px;
    height: 80px;
    object-fit: contain;
    margin-bottom: 0.5rem;
    transition: transform 0.3s ease;
}

.node-name {
    font-family: 'Fraunces', serif;
    font-size: 0.9rem;
    font-weight: 600;
    color: #D7AF6B;
    text-align: center;
    line-height: 1.2;
    max-width: 120px;
}

/* Project Logo Special Styling */
.project-logo .node-image {
    width: 100px;
    height: 100px;
}

.project-logo .node-name {
    font-size: 1.2rem;
    font-weight: bold;
    color: #fff;
}

/* Medal Node Special Styling */
.medal-node {
    position: relative;
}

.medal-link {
    cursor: default;
}

.medal-rays {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: 120px;
    height: 120px;
    border-radius: 50%;
    background: conic-gradient(
        transparent 0deg,
        #d7af6b 30deg,
        transparent 60deg,
        #d7af6b 90deg,
        transparent 120deg,
        #d7af6b 150deg,
        transparent 180deg,
        #d7af6b 210deg,
        transparent 240deg,
        #d7af6b 270deg,
        transparent 300deg,
        #d7af6b 330deg,
        transparent 360deg
    );
    opacity: 0;
    transition: opacity 0.3s ease;
    animation: spin 3s linear infinite;
    pointer-events: none;
    z-index: -1;
}

.medal-node:hover .medal-rays {
    opacity: 0.6;
}

@keyframes spin {
    from { transform: translate(-50%, -50%) rotate(0deg); }
    to { transform: translate(-50%, -50%) rotate(360deg); }
}

/* Connection Lines */
.connection-lines {
    position: absolute;
    top: 100%;
    left: 0;
    width: 100%;
    height: 6rem;
    z-index: 1;
    pointer-events: none;
    overflow: visible;
}

.level-0 {
    position: relative;
}

.level-1, .level-2, .level-3 {
    position: relative;
}

.connection-line {
    stroke: #d7af6b;
    stroke-width: 2;
    opacity: 0.4;
}

/* Mobile Responsiveness */
@media (max-width: 768px) {
    .roadmap-graph {
        padding: 1rem;
    }
    
    .graph-level {
        margin: 3rem 0;
    }
    
    .node-row {
        gap: 1.5rem;
    }
    
    .level-1 .node-row {
        grid-template-columns: repeat(3, 1fr);
        gap: 2rem;
        max-width: 100%;
    }
    
    .level-2 .node-row,
    .level-4 .node-row,
    .level-6 .node-row {
        grid-template-columns: 1fr;
        max-width: 100%;
    }
    
    .level-3 .node-row {
        grid-template-columns: repeat(2, 1fr);
        max-width: 100%;
        gap: 2rem;
    }
    
    .level-5 .node-row {
        grid-template-columns: repeat(3, 1fr);
        max-width: 100%;
        gap: 2rem;
    }
    
    .node {
        max-width: 140px;
    }
    
    .node-image {
        width: 70px;
        height: 70px;
    }
    
    .project-logo .node-image {
        width: 90px;
        height: 90px;
    }
    
    .node-name {
        font-size: 0.85rem;
        max-width: 100px;
    }
    
    .project-logo .node-name {
        font-size: 1rem;
    }
    
    .medal-rays {
        width: 100px;
        height: 100px;
    }
    
    .connection-lines {
        height: 3rem;
    }
}

@media (max-width: 480px) {
    .awards-hero {
        min-height: 40vh;
        padding: 1rem;
    }
    
    .roadmap-graph {
        padding: 0.5rem;
    }
    
    .graph-level {
        margin: 2.5rem 0;
    }
    
    .node-row {
        gap: 1.5rem;
    }
    
    .level-1 .node-row {
        grid-template-columns: repeat(3, 1fr);
        gap: 1.5rem;
    }
    
    .level-2 .node-row,
    .level-4 .node-row,
    .level-6 .node-row {
        grid-template-columns: 1fr;
    }
    
    .level-3 .node-row {
        grid-template-columns: repeat(2, 1fr);
        gap: 1.5rem;
    }
    
    .level-5 .node-row {
        grid-template-columns: repeat(3, 1fr);
        gap: 1.5rem;
    }
    
    .node {
        max-width: 120px;
    }
    
    .node-image {
        width: 65px;
        height: 65px;
    }
    
    .project-logo .node-image {
        width: 85px;
        height: 85px;
    }
    
    .node-name {
        font-size: 0.8rem;
        max-width: 90px;
        line-height: 1.1;
    }
    
    .medal-rays {
        width: 90px;
        height: 90px;
    }
    
    .connection-lines {
        height: 2.5rem;
    }
    
    /* Ensure nodes are visible and properly spaced */
    .node-link:hover {
        transform: scale(1.3);
    }
}

/* Mobile Responsiveness */
@media (max-width: 768px) {
    .awards-hero {
        min-height: 50vh;
        padding: 2rem 1rem;
    }
    
    .awards-content {
        padding: 2rem 0;
    }
}

@media (max-width: 480px) {
    .awards-hero {
        min-height: 40vh;
        padding: 1rem;
    }
}