:root {
    --bg-color: #0b101a;
    --gold-light: #f3d9a2;
    --gold-dark: #a9844d;
    --font-serif: 'Cinzel', serif;
    --font-sans: 'Outfit', sans-serif;
}

* {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

html {
    scroll-behavior: smooth;
}

body {
    background: linear-gradient(135deg, #0f1523 0%, #06080d 50%, #0b101a 100%);
    background-size: 200% 200%;
    animation: gradientShift 15s ease infinite;
    color: var(--gold-light);
    font-family: var(--font-sans);
    display: flex;
    flex-direction: column;
    align-items: center;
    min-height: 100vh;
    overflow-x: hidden;
    position: relative;
    padding: 60px 20px;
}

@keyframes gradientShift {
    0% {
        background-position: 0% 50%;
    }

    50% {
        background-position: 100% 50%;
    }

    100% {
        background-position: 0% 50%;
    }
}

#starsCanvas {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 0;
    pointer-events: none;
}

.poster-container {
    position: relative;
    width: 600px;
    min-height: 850px;
    height: 850px;
    display: flex;
    margin-top: 10px;
    justify-content: center;
    box-shadow: 0 0 50px rgba(0, 0, 0, 0.9);
    border-radius: 300px 300px 0 0;
    z-index: 2;
}

.main-nav {
    width: 100%;
    margin-top: 25px;
    margin-bottom: 20px;
    display: flex;
    justify-content: center;
    gap: 40px;
    z-index: 10;
    position: relative;
}

.main-nav a {
    color: var(--gold-dark);
    text-decoration: none;
    font-size: 1.1rem;
    font-family: 'Cinzel', serif;
    letter-spacing: 0.1em;
    padding-bottom: 5px;
    border-bottom: 1px solid transparent;
    transition: all 0.3s ease;
    text-transform: uppercase;
}

.main-nav a:hover,
.main-nav a.active {
    color: var(--gold-light);
    border-bottom: 1px solid var(--gold-light);
    text-shadow: 0 0 10px rgba(243, 217, 162, 0.4);
}

.arch-frame {
    width: 100%;
    height: 100%;
    min-height: 850px;
    border: 2px solid var(--gold-dark);
    border-radius: 300px 300px 0 0;
    padding: 40px 30px 15px;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: space-between;
    position: relative;
    background: radial-gradient(circle at center, rgba(169, 132, 77, 0.05) 0%, transparent 60%);
    box-shadow: inset 0 0 50px rgba(169, 132, 77, 0.05), 0 0 40px rgba(11, 16, 26, 0.8);
    overflow: hidden;
}

.arch-header-group {
    width: 100%;
    display: flex;
    flex-direction: column;
    align-items: center;
}

.top-star {
    color: var(--gold-light);
    display: flex;
    justify-content: center;
    align-items: center;
    margin-bottom: 25px;
    margin-top: 10px;
    animation: pulse 3s infinite alternate;
    filter: drop-shadow(0 0 15px var(--gold-light));
}

@keyframes pulse {
    0% {
        transform: scale(0.95);
        opacity: 0.8;
        filter: drop-shadow(0 0 10px var(--gold-light));
    }

    100% {
        transform: scale(1.05);
        opacity: 1;
        filter: drop-shadow(0 0 25px var(--gold-light));
    }
}

.stars-crosses {
    position: absolute;
    width: 100%;
    height: 100%;
    pointer-events: none;
    z-index: 0;
}

.little-star {
    position: absolute;
    width: 12px;
    height: 12px;
    color: var(--gold-dark);
    opacity: 0.6;
}

.ls-1 {
    top: 120px;
    left: 15%;
}

.ls-2 {
    top: 180px;
    right: 10%;
    width: 16px;
    height: 16px;
}

header {
    text-align: center;
    margin-bottom: 45px;
    z-index: 1;
}

.title {
    font-family: var(--font-serif);
    font-size: 4.8rem;
    line-height: 1.05;
    color: var(--gold-light);
    font-weight: 700;
    letter-spacing: 0.02em;
    text-shadow: 0 0 15px rgba(243, 217, 162, 0.4);
}

.divider {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 15px;
    margin-top: 20px;
}

.divider h2 {
    font-size: 1.15rem;
    letter-spacing: 0.15em;
    font-weight: 600;
    color: var(--gold-dark);
}

.tabs {
    display: flex;
    gap: 15px;
    margin-bottom: 25px;
    z-index: 2;
}

.tab-btn {
    background: none;
    border: 1px solid var(--gold-dark);
    color: var(--gold-dark);
    padding: 6px 14px;
    border-radius: 20px;
    font-family: var(--font-sans);
    cursor: pointer;
    font-size: 0.9rem;
    transition: all 0.3s ease;
    letter-spacing: 0.05em;
}

.tab-btn.active,
.tab-btn:hover {
    background: rgba(169, 132, 77, 0.15);
    color: var(--gold-light);
    border-color: var(--gold-light);
    box-shadow: 0 0 10px rgba(243, 217, 162, 0.2);
}

.tab-content {
    width: 100%;
}

.talks {
    display: flex;
    flex-direction: column;
    gap: 30px;
    width: 100%;
    margin-bottom: 30px;
    z-index: 1;
}

.talk-link {
    text-decoration: none;
    display: block;
    width: 100%;
}

.talk {
    text-align: center;
    transition: transform 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275);
    cursor: pointer;
    padding: 15px;
    border-radius: 12px;
}

.talk:hover {
    transform: translateY(-8px) scale(1.02);
    background: rgba(169, 132, 77, 0.05);
}

.talk h3 {
    font-size: 2.2rem;
    font-family: var(--font-sans);
    font-weight: 500;
    color: var(--gold-light);
    margin-bottom: 8px;
    letter-spacing: 0.03em;
    transition: text-shadow 0.3s ease;
}

.talk h3 sup {
    font-size: 0.85rem;
    vertical-align: top;
    margin-left: 6px;
    color: var(--gold-dark);
    font-weight: 500;
}

.talk p {
    font-size: 1.05rem;
    font-style: italic;
    color: var(--gold-dark);
    font-weight: 400;
    letter-spacing: 0.04em;
}

.talk:hover h3 {
    text-shadow: 0 0 15px rgba(243, 217, 162, 0.6);
}

.metadata {
    display: flex;
    justify-content: space-between;
    width: 85%;
    margin-bottom: 20px;
    font-family: var(--font-sans);
    font-size: 1.3rem;
    letter-spacing: 0.08em;
    color: var(--gold-light);
    z-index: 2;
    font-weight: 500;
}

.meta-col {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.left-align {
    text-align: left;
    align-items: flex-start;
}

.right-align {
    text-align: right;
    align-items: flex-end;
}

.location-link,
.calendar-link,
.calendar-block-link {
    color: var(--gold-light);
    text-decoration: none;
    transition: color 0.3s ease, text-shadow 0.3s ease;
}

.location-link,
.calendar-link {
    display: inline-flex;
    align-items: center;
    gap: 10px;
}

.calendar-block-link {
    display: flex;
}

.location-link:hover,
.calendar-link:hover,
.calendar-block-link:hover {
    color: #fff;
    text-shadow: 0 0 10px rgba(243, 217, 162, 0.8);
}

.meta-icon {
    width: 1.35em;
    height: 1.35em;
    stroke-width: 1.5;
    fill: none;
    flex-shrink: 0;
}

.date-row {
    display: flex;
    align-items: center;
    gap: 8px;
}

.footer-art {
    margin-top: auto;
    width: 120%;
    margin-left: -10%;
    transform: translateY(10px);
    z-index: 1;
    pointer-events: none;
    display: flex;
    justify-content: center;
    align-items: flex-end;
}

.city-silhouette {
    width: 100%;
    height: auto;
    object-fit: cover;
    mix-blend-mode: lighten;
    opacity: 0.95;
    filter: drop-shadow(0 0 10px rgba(243, 217, 162, 0.2)) sepia(0.2) hue-rotate(-10deg) saturate(1.2);
}

/* Floating Icons outside arch */
.floating-icons {
    position: absolute;
    top: 30px;
    bottom: 20px;
    display: flex;
    flex-direction: column;
    justify-content: space-evenly;
    z-index: 0;
    pointer-events: none;
}

.floating-icons.left {
    left: -55px;
}

.floating-icons.right {
    right: -55px;
    align-items: flex-end;
}



.icon {
    width: 36px;
    height: 36px;
    stroke: var(--gold-dark);
    opacity: 0.8;
    animation: floatIcon 6s ease-in-out infinite;
    filter: drop-shadow(0 0 5px rgba(169, 132, 77, 0.5));
}

.dna-icon {
    animation-delay: 0s;
    height: 60px;
    width: 24px;
}

.planet-icon {
    animation-delay: 1.5s;
    width: 45px;
    height: 45px;
}

.graph-icon {
    animation-delay: 0.5s;
    width: 40px;
}

.leaf-icon {
    animation-delay: 2s;
    width: 40px;
    height: 40px;
}

.atom-icon {
    animation-delay: 1s;
    width: 45px;
    height: 45px;
}

.neuron-icon {
    animation-delay: 2.5s;
    width: 42px;
    height: 42px;
}

@keyframes floatIcon {

    0%,
    100% {
        transform: translateY(0) rotate(0deg);
    }

    50% {
        transform: translateY(-15px) rotate(3deg);
    }
}

.event-description-box {
    margin-top: 40px;
    padding: 30px 40px;
    background: rgba(11, 16, 26, 0.1);
    border: 1px solid var(--gold-dark);
    border-radius: 20px;
    box-shadow: 0 0 20px rgba(0, 0, 0, 0.5);
    text-align: center;
    width: 100%;
    max-width: 650px;
    z-index: 2;
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
}

.event-description-box h3 {
    font-size: 1.5rem;
    color: var(--gold-light);
    margin-bottom: 15px;
    letter-spacing: 0.05em;
    font-family: var(--font-serif);
}

.event-description-box p {
    font-size: 1.05rem;
    color: var(--gold-dark);
    line-height: 1.6;
    letter-spacing: 0.02em;
}

/* Abstract Toggle & Sub-box */
.abstract-container {
    margin-top: 15px;
    position: relative;
    display: flex;
    flex-direction: column;
    align-items: center;
}

[id^="abstract-"].event-description-box {
    background: transparent;
    border: 1px solid var(--gold-dark);
    box-shadow: none;
}

.abstract-toggle {
    display: inline-flex;
    background: rgba(169, 132, 77, 0.08);
    border: 1px solid rgba(169, 132, 77, 0.4);
    border-radius: 25px;
    padding: 4px;
    margin-bottom: 5px;
    cursor: pointer;
    user-select: none;
    transition: all 0.3s ease;
    backdrop-filter: blur(5px);
}

.abstract-toggle:hover {
    border-color: var(--gold-light);
    background: rgba(169, 132, 77, 0.12);
}

.abstract-toggle-btn {
    padding: 6px 18px;
    font-size: 0.85rem;
    font-family: var(--font-sans);
    letter-spacing: 0.1em;
    color: var(--gold-dark);
    text-transform: uppercase;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    border-radius: 20px;
}

.abstract-toggle-btn.active {
    color: var(--bg-color);
    background: var(--gold-light);
    font-weight: 600;
    box-shadow: 0 0 15px rgba(243, 217, 162, 0.3);
}

.abstract-sub-box {
    width: 100%;
    background: rgba(169, 132, 77, 0.03);
    border: 1px solid rgba(169, 132, 77, 0.2);
    border-radius: 15px;
    padding: 22px;
    margin-top: 15px;
    position: relative;
    transition: all 0.3s ease;
    text-align: left;
}

.abstract-content {
    display: none;
    animation: abstractFadeIn 0.5s ease forwards;
}

.abstract-content.active {
    display: block;
}

@keyframes abstractFadeIn {
    from { 
        opacity: 0; 
        transform: translateY(10px); 
    }
    to { 
        opacity: 1; 
        transform: translateY(0); 
    }
}

.drinks-footer {
    position: relative;
    width: 100%;
    height: 80px;
    margin-top: 0;
    opacity: 0.7;
    z-index: 1;
}

.drink-icon {
    position: absolute;
    width: 40px;
    height: 40px;
    stroke: var(--gold-dark);
    fill: none;
    stroke-width: 1.5;
    transform-origin: bottom center;
    transform: translateY(0px) rotate(calc(var(--r) * 1deg)) scale(var(--s));
    animation: drift-drinks 3s ease-in-out infinite alternate;
}

@keyframes drift-drinks {
    0% {
        transform: translateY(0px) rotate(calc(var(--r) * 1deg)) scale(var(--s));
    }

    100% {
        transform: translateY(-7px) rotate(calc(var(--r) * 1deg + 5deg)) scale(var(--s));
    }
}

@media (max-width: 700px) {
    .main-nav {
        flex-wrap: wrap;
        gap: 15px;
        padding: 0 10px;
    }

    .main-nav a {
        font-size: 0.95rem;
    }

    .floating-icons {
        display: none;
    }

    .poster-container {
        max-width: 100%;
        border-radius: calc(50vw - 20px) calc(50vw - 20px) 0 0;
        overflow: visible;
        padding-top: 1px;
        height: auto;
    }

    .arch-frame {
        border-radius: calc(50vw - 20px) calc(50vw - 20px) 0 0;
        padding: 40px 15px 30px;
        border-width: 1px;
        min-height: 950px;
    }

    .title {
        font-size: 3.5rem;
    }

    .metadata {
        width: 95%;
        font-size: 1.1rem;
    }

@media (max-width: 350px) {
    .arch-frame {
        padding: 40px 15px 40px;
        min-height: 1050px;
    }
    .title {
        font-size: 2.8rem;
    }
}
}

/* Open Bottom Arch Frame for infinitely trailing pages */
.arch-frame.open-bottom {
    border: none;
}

.arch-frame.open-bottom::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    border: 2px solid var(--gold-dark);
    border-radius: inherit;
    border-bottom: none;
    pointer-events: none;
    -webkit-mask-image: linear-gradient(to bottom, black 80%, transparent 100%);
    mask-image: linear-gradient(to bottom, black 80%, transparent 100%);
    z-index: 1;
}

.arch-frame.open-bottom::after {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    border: 2px solid var(--gold-light);
    border-radius: inherit;
    border-bottom: none;
    pointer-events: none;
    -webkit-mask-image: linear-gradient(to bottom, transparent, black, transparent);
    mask-image: linear-gradient(to bottom, transparent, black, transparent);
    -webkit-mask-size: 100% 300px;
    mask-size: 100% 300px;
    -webkit-mask-repeat: no-repeat;
    mask-repeat: no-repeat;
    animation: trickleDown 4s infinite linear;
    filter: drop-shadow(0 0 5px var(--gold-light));
    z-index: 2;
}

@keyframes trickleDown {
    0% {
        -webkit-mask-position: 0 -300px;
        mask-position: 0 -300px;
    }

    100% {
        -webkit-mask-position: 0 120%;
        mask-position: 0 120%;
    }
}

/* -------------------------------------
   Gallery Observatory Architecture 
   ------------------------------------- */

.gallery-container {
    max-width: 900px;
    width: 100%;
    box-shadow: none;
    /* No single container shadow — using two separate ones */
    border-radius: 0;
    min-height: auto;
}

.gallery-building {
    display: flex;
    flex-direction: column;
    align-items: center;
    width: 100%;
    margin-bottom: 0px;
    position: relative;
    padding-top: 50px;
    padding-bottom: 120px;
    /* Expansive padding for bottomless fade-out */
    -webkit-mask-image: linear-gradient(to bottom, black 80%, transparent 100%);
    mask-image: linear-gradient(to bottom, black 80%, transparent 100%);
}

.gallery-dome {
    width: 50%;
    max-width: 400px;
    aspect-ratio: 2 / 1;
    border-radius: 50% 50% 0 0 / 100% 100% 0 0;
    border: 2px solid var(--gold-dark);
    border-bottom: none;
    position: relative;
    overflow: visible;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: flex-end;
    padding-bottom: 20px;
    background: var(--bg-color);
    /* Shadow 1: Hugs the dome's semicircular golden border */
    box-shadow: 0 0 40px rgba(0, 0, 0, 0.85), inset 0 0 12px rgba(169, 132, 77, 0.12);
}

.gallery-dome .title {
    font-size: 2.2rem;
    line-height: 1;
    margin: 0;
}

.gallery-cornice {
    width: calc(100% + 40px);
    margin-left: -20px;
    margin-right: -20px;
    height: 10px;
    background: var(--gold-dark);
    position: relative;
    border-radius: 6px;
    box-shadow: inset 0 2px 5px rgba(243, 217, 162, 0.4);
    z-index: 2;
    margin-top: -2px;
    margin-bottom: -2px;
}

.gallery-body {
    width: 100%;
    border: 1px solid var(--gold-dark);
    /* Thin line all around */
    border-bottom: none;
    border-radius: 12px 12px 12px 12px;
    padding: 30px 20px 40px;
    background: transparent;
    /* Shadow 2: Hugs the body's rectangular golden borders */
    box-shadow: 0 0 40px rgba(0, 0, 0, 0.85), inset 4px 0 10px -4px rgba(169, 132, 77, 0.15), inset -4px 0 10px -4px rgba(169, 132, 77, 0.15);
}

.gallery-date-section {
    margin-bottom: 40px;
}

.gallery-date-section:last-child {
    margin-bottom: 0;
}

.gallery-date {
    color: var(--text-color);
    font-family: 'Outfit', sans-serif;
    font-weight: 300;
    font-size: 1.1rem;
    text-align: left;
    text-transform: uppercase;
    letter-spacing: 2px;
    border-bottom: 1px dotted var(--gold-dark);
    padding-bottom: 5px;
    margin-bottom: 20px;
}

.photo-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(130px, 1fr));
    gap: 15px;
}

.photo-placeholder {
    width: 100%;
    aspect-ratio: 1;
    border: 1px solid rgba(169, 132, 77, 0.3);
    border-radius: 8px;
    /* Rounded image corners */
    background: radial-gradient(circle at center, rgba(169, 132, 77, 0.1), transparent);
    display: flex;
    align-items: center;
    justify-content: center;
    text-align: center;
    line-height: 1.4;
    color: var(--gold-dark);
    font-size: 0.8rem;
    font-family: 'Outfit';
    transition: all 0.3s ease;
}

.coming-soon {
    color: var(--gold-dark);
    font-family: 'Outfit', sans-serif;
    font-size: 1.1rem;
    font-style: italic;
    text-align: center;
    padding: 40px 0;
    opacity: 0.7;
    letter-spacing: 2px;
}

.photo-placeholder:hover {
    border-color: var(--gold-light);
    box-shadow: 0 0 10px rgba(243, 217, 162, 0.2);
    transform: scale(1.03);
    cursor: pointer;
    color: var(--gold-light);
}

.gallery-foundation {
    width: calc(100% + 60px);
    margin-left: -30px;
    margin-right: -30px;
    height: 20px;
    background: var(--gold-dark);
    border-radius: 4px 4px 2px 2px;
    margin-top: -2px;
    box-shadow: none;
}

/* Mobile responsive collapse for the observatory */
@media (max-width: 700px) {
    .gallery-dome {
        width: 100%;
        max-width: 100%;
    }

    .gallery-body {
        border-radius: 0;
    }

    .gallery-cornice {
        width: 100%;
        margin-left: 0;
        margin-right: 0;
    }

    .gallery-foundation {
        width: 100%;
        margin-left: 0;
        margin-right: 0;
    }
}

/* Telescope protruding out from gallery dome */
.telescope-svg {
    position: absolute;
    top: -30px;
    right: 12%;
    width: 140px;
    height: 140px;
    z-index: -1;
    /* Behind the opaque dome — base is naturally hidden */
    pointer-events: none;
    overflow: visible;
    filter: drop-shadow(0 0 3px rgba(243, 217, 162, 0.4));
}

.scanning-telescope {
    animation: scanSky 15s infinite ease-in-out alternate;
}

@keyframes scanSky {
    0% {
        transform: rotate(15deg);
    }

    100% {
        transform: rotate(65deg);
    }
}

/* ── Sign-up Button ───────────────────────────────────────────── */
@property --glow-angle {
    syntax: '<angle>';
    initial-value: 0deg;
    inherits: false;
}

@keyframes borderGlow {
    to { --glow-angle: 360deg; }
}

.signup-btn {
    /* Layout */
    display: block;
    width: fit-content;
    margin: 0 auto 18px;
    padding: 11px 36px;
    text-decoration: none;
    font-family: var(--font-serif);
    font-size: 1.1rem;
    letter-spacing: 0.15em;
    text-transform: uppercase;
    color: var(--gold-light);
    text-align: center;
    z-index: 3;
    position: relative;

    /* Transparent interior */
    background: transparent;
    border-radius: 40px;

    /* Animated travelling-glow border via conic-gradient pseudo */
    /* We use a pseudo-element background approach so it stays transparent inside */
}

.signup-btn::before {
    content: '';
    position: absolute;
    inset: -2px;
    border-radius: inherit;
    padding: 2px;          /* border thickness */
    background: conic-gradient(
        from var(--glow-angle),
        /* bright glow spot — travels the border */
        #fff9e6 0deg,
        #f3d9a2 30deg,
        #a9844d 90deg,
        #4a3a1d 160deg,
        #a9844d 230deg,
        #f3d9a2 290deg,
        #fff9e6 360deg
    );
    -webkit-mask:
        linear-gradient(#fff 0 0) content-box,
        linear-gradient(#fff 0 0);
    -webkit-mask-composite: xor;
    mask-composite: exclude;
    animation: borderGlow 6s linear infinite;
    filter: drop-shadow(0 0 5px rgba(243, 217, 162, 0.55));
}

.signup-btn:hover {
    color: #fff;
    letter-spacing: 0.2em;
    transition: color 0.3s ease, letter-spacing 0.3s ease;
}

.signup-btn:hover::before {
    filter: drop-shadow(0 0 9px rgba(243, 217, 162, 0.85));
    animation-duration: 2.5s;   /* speeds up slightly on hover */
    transition: filter 0.3s ease, animation-duration 0.3s ease;
}