@import url("https://fonts.googleapis.com/css2?family=Inter:ital,opsz,wght@0,14..32,300;1,14..32,300&display=swap");

/* ===========================
    GLOBAL VARIABLES & BASE
    =========================== */
:root {
    --inter-font: "Inter", sans-serif;
    --inter-optical-sizing: auto;
    --inter-weight: 300;
    --inter-style: normal;
    --tedx-logo-primary-color: #eb0028;
    --tedx-logo-secondary-color: #000;
    --background-primary-color: #fff;
}

html,
body {
    width: 100%;
    margin: 0;
    padding: 0;
    overflow-x: hidden;
    font-family: var(--inter-font);
    font-optical-sizing: var(--inter-optical-sizing);
    font-weight: var(--inter-weight);
    font-style: var(--inter-style);
}

.action-button {
    align-self: center;
    padding: 0.7rem 2.2rem;
    font-size: 1.1rem;
    border-radius: 6px;
    border: none;
    background: #e62b1e;
    color: #fff;
    cursor: pointer;
    margin-top: 0.5rem;
    transition: background 0.2s;
    text-decoration: none;
}

.action-button:hover {
    background: #b71c12;
}

/* ===========================
    NAVIGATION
    =========================== */
nav {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    min-height: 85px;
    z-index: 9999;
    background-color: var(--background-primary-color);
    display: flex;
    align-items: center;
    color: var(--tedx-logo-secondary-color);
    font-size: 1.1rem;
    padding: 1rem;
}
#nav-left-icon {
    height: 50px;
}
.nav-links {
    display: flex;
    flex-direction: row;
    gap: 1rem;
    list-style: none;
    margin-left: auto;
    margin-right: 2rem;
    padding: 1rem;
    align-items: center;
}
.nav-menu-icon {
    display: none;
    cursor: pointer;
    margin-left: auto;
    margin-right: 2.5rem;
    z-index: 10001;
}
.nav-links li {
    margin: 0;
    padding: 0;
}
.nav-links a {
    text-decoration: none;
    color: var(--tedx-logo-secondary-color);
    padding: 0.5rem 0.75rem;
    border-radius: 4px;
    display: block;
}
.nav-links a.active {
    font-weight: 800;
}

/* --- Dropdown --- */
.dropdown {
    position: relative;
}
.dropbtn {
    cursor: pointer;
}
.dropdown-content {
    display: none;
    position: absolute;
    background: var(--background-primary-color);
    min-width: 180px;
    z-index: 1000;
    padding: 0.5rem 0;
}
.dropdown-content a {
    color: var(--tedx-logo-secondary-color);
    padding: 0.5rem 1rem;
    display: block;
    text-decoration: none;
    white-space: nowrap;
}
.dropdown.open .dropdown-content {
    display: block;
}

/* ===========================
    HOME
    =========================== */
#TEDxTruro-logo-image {
    display: block;
    margin-left: auto;
    margin-right: auto;
    height: 100%;
    width: 82%;
    object-fit: contain;
}
#home-screen-landing-page {
    height: 100dvh;
    position: relative;
}
#hero-image {
    background-image: url("../images/scraped-images-TEMP/tedx-hero-image.webp");
    min-height: 100dvh;
    width: 100%;
    margin: 0;
    padding: 0;
    border: none;
    outline: none;
    box-sizing: border-box;
    position: relative;
}
#hero-image h1 {
    color: var(--background-primary-color);
    position: absolute;
    top: 30%;
    margin-left: 10%;
    margin-right: 10%;
    width: calc(100% - 100px);
    font-size: 8vw;
    font-weight: 600;
    transform: translateY(-50%);
    text-shadow: 0 2px 8px rgba(0, 0, 0, 0.18);
}

#hero-image h2 {
    color: var(--background-primary-color);
    position: absolute;
    top: 50%;
    margin-left: 11%;
    margin-right: 10%;
    width: calc(100% - 100px);
    font-size: 4.2vw;
    transform: translateY(-50%);
    text-shadow: 0 2px 8px rgba(0, 0, 0, 0.08);
}

#find-out-more-div {
    position: absolute;
    top: 85%;
    margin-left: 11%;
    margin-right: 10%;
}

/* --- Home About --- */
#home-about {
    position: relative;
    width: 100%;
    margin: 0;
    padding: 0;
}
#home-about h2 {
    text-align: center;
    font-size: 2.6rem;
    margin-top: 5rem;
}
#home-about-h2-logo {
    width: 6em;
    height: auto;
    display: inline-block;
    vertical-align: middle;
    margin-bottom: 0.5rem;
}
.home-about {
    display: flex;
    flex-direction: row;
    gap: 2rem;
    justify-content: space-between;
    margin-left: 10%;
    margin-right: 10%;
    border-collapse: separate;
    border-spacing: 2rem 0;
    width: 80%;
    height: auto;
    font-size: 1.8rem;
}
.home-about-item {
    flex: 1 1 0;
    min-width: 0;
}

/* --- Home Announcements --- */
#home-announcements {
    background-color: #e0e0e0;
}
#home-announcements-sub {
    text-align: center;
    margin-left: 10%;
    margin-right: 10%;
    width: 80%;
    padding-bottom: 1.8rem;
    height: auto;
    font-size: 1.8rem;
}
#home-announcements h2 {
    text-align: center;
    font-size: 2.6rem;
    margin-top: 5rem;
    margin-bottom: 5rem;
    padding-top: 1rem;
}
#home-announcements-h2-logo {
    width: 6em;
    height: auto;
    display: inline-block;
    vertical-align: middle;
    margin-bottom: 0.5rem;
}

/* --- Home Memorable Moments --- */
#home-memorable-moments {
    text-align: center;
    width: 100%;
    height: auto;
}
#home-memorable-moments h2 {
    text-align: center;
    font-size: 2.6rem;
    margin-top: 7rem;
    margin-bottom: 5rem;
}
#home-memorable-moments-h2-logo {
    width: 6em;
    height: auto;
    display: inline-block;
    vertical-align: middle;
    margin-bottom: 0.5rem;
}
#home-memorable-moments-photos img {
    width: 100%;
    line-height: 1em;
}
#home-memorable-moments-photos {
    line-height: 0;
    column-count: 4;
    column-gap: 0;
}

/* ===========================
    SPEAKERS 2025
    =========================== */
#speakers-landing-page {
    text-align: center;
    margin-top: 10rem;
    font-size: 2rem;
}
#speakers-landing-page h1 {
    text-align: center;
}
.speaker-row {
    display: flex;
    align-items: center;
    gap: 2rem;
    margin-bottom: 3rem;
}
.speaker-row .speaker-img {
    flex: 0 0 500px;
    max-width: 500px;
}
.speaker-row .speaker-img img {
    width: 100vw;
    max-width: 100%;
    height: auto;
    object-fit: contain;
    display: block;
}
.speaker-row .speaker-info {
    flex: 1;
    font-size: 1.8rem;
    line-height: 1.6;
    display: flex;
    flex-direction: column;
    justify-content: center;
    height: 100%;
}
.speaker-row .speaker-info h2 {
    font-size: 1.8rem;
    margin-bottom: 0.5rem;
}
.speaker-row.reverse {
    flex-direction: row-reverse;
    align-items: center;
}

/* ===========================
    PARTNERS 2025
    =========================== */
#partners-landing-page {
    text-align: center;
    margin-top: 10rem;
    font-size: 2rem;
}

#partners-landing-page h2 a {
    text-decoration: none;
    color: var(--tedx-logo-secondary-color);
}

.partner-row {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 1.3rem;
    justify-items: center;
    align-items: center;
    width: 50%;
    margin: 0 auto 3rem auto;
    box-sizing: border-box;
}
.partner-img {
    width: 100%;
    max-width: 100%;
    display: flex;
    justify-content: center;
    align-items: center;
}
.partner-img img {
    width: 100%;
    max-width: 220px;
    height: auto;
    object-fit: contain;
    display: block;
    box-sizing: border-box;
}

/* ===========================
    APPLY TO BE A PARTNER 2026
    =========================== */
#apply-to-be-a-partner-landing-page #hero-image {
    width: 100%;
    margin-left: 0;
    margin-right: 0;
    background-image: url("../images/scraped-images-TEMP/memorable-moments-9.webp");
}

#hero-image h3 {
    color: var(--background-primary-color);
    position: absolute;
    top: 10%;
    margin-left: 10%;
    margin-right: 10%;
    width: calc(100% - 100px);
    font-size: 4vw;
    font-weight: 600;
    transform: translateY(-50%);
    text-shadow: 0 2px 8px rgba(0, 0, 0, 0.08);
}

#apply-to-be-a-partner-landing-page {
    text-align: center;
    margin-top: 10rem;
    font-size: 2rem;
}

#apply-to-be-a-partner-landing-page h3 {
    margin-top: 6rem;
    margin-bottom: 6rem;
}

#apply-to-be-a-partner-landing-page h3,
#apply-to-be-a-partner-landing-page h4,
#apply-to-be-a-partner-landing-page p,
#apply-to-be-a-partner-landing-page #partner-apply-div {
    text-align: left;
    margin-left: 3vw;
    margin-right: 3vw;
}

#partner-apply-div {
    margin-top: 2.8rem;
}

#apply-to-be-a-partner-form h2 {
    text-align: center;
    margin-top: 6rem;
    font-size: 2rem;
}

#pdf-download-div {
    margin-top: 4.1rem;
    display: flex;
    justify-content: center;
    align-items: center;
    width: 100%;
}

#download-tedx-pdf a {
    text-decoration: none;
    color: var(--background-primary-color);
}

/* ===========================
    FORM SUCCESS - - REDIRECT
    =========================== */
#form-success-landing-page {
    text-align: center;
    margin-top: 10rem;
    font-size: 2rem;
    margin-left: 2rem;
    margin-right: 2rem;
}

#form-success-body {
    min-height: 100vh;
    display: flex;
    flex-direction: column;
}
#form-success-footer {
    margin-top: auto;
    width: 100%;
    text-align: center;
    padding: 20px 0;
}

/* ===========================
    EVENTS
    =========================== */

#events-landing-page {
    text-align: center;
    margin-top: 10rem;
    font-size: 2rem;
}

#events {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    width: 100vw;
    max-width: 100vw;
    margin-left: 1rem;
    margin-right: 1rem;
    overflow-x: hidden;
    box-sizing: border-box;
}

.event-link {
    display: flex;
    align-items: center;
    gap: 1rem;
    justify-content: flex-start;
    width: 100%;
    max-width: 600px;
    margin: 1rem auto;
    box-sizing: border-box;
}

.event-link a {
    text-decoration: none;
    color: var(--tedx-logo-secondary-color);
}

#event-img {
    width: 40vw;
    max-width: 40vh;
    height: auto;
    object-fit: contain;
    margin: 0;
    display: inline-block;
    vertical-align: middle;
}

#event-link-future {
    margin-top: 3rem;
    margin-bottom: 3rem;
}

/* ===========================
    EVENTS - FUTURE
    =========================== */

#events-image {
    background-image: url("../images/scraped-images-TEMP/memorable-moments-11.webp");
    min-height: 100dvh;
    width: 100%;
    margin: 0;
    padding: 0;
    border: none;
    outline: none;
    box-sizing: border-box;
    position: relative;
}
#events-image h1 {
    color: var(--background-primary-color);
    position: absolute;
    top: 40%;
    margin-left: 10%;
    margin-right: 10%;
    width: calc(100% - 100px);
    font-size: 8vw;
    font-weight: 600;
    transform: translateY(-50%);
    text-shadow: 0 2px 8px rgba(0, 0, 0, 0.08);
}

#events-image h2 {
    color: var(--background-primary-color);
    position: absolute;
    top: 60%;
    margin-left: 11%;
    margin-right: 10%;
    width: calc(100% - 100px);
    font-size: 3vw;
    font-weight: 600;
    transform: translateY(-50%);
    text-shadow: 0 2px 8px rgba(0, 0, 0, 0.08);
}

#events-about {
    position: relative;
    width: 100%;
    margin: 0;
    padding: 0;
}
#events-about h2 {
    text-align: center;
    font-size: 2.6rem;
    margin-top: 5rem;
}
.events-about {
    margin-left: 10%;
    margin-right: 10%;
    width: 80%;
    height: auto;
    font-size: 1.8rem;
}

.events-about-item strong {
    font-weight: 600;
}

#events-booking,
#events-speakers {
    text-align: center;
    font-size: 1.6rem;
    margin-top: 5rem;
}
#events-booking h2,
#events-speakers h2 {
    font-size: 3rem;
}

#events-map {
    width: 100%;
    max-width: 700px;
    margin: 2rem auto;
    box-sizing: border-box;
    display: flex;
    justify-content: center;
    align-items: center;
}
#events-map iframe {
    width: 100%;
    height: 350px;
    border: 0;
    display: block;
}

/* ===========================
    TALKS 2025
    =========================== */
#talks-2025-landing-page {
    text-align: center;
    margin-top: 10rem;
    font-size: 2rem;
}

#talks-2025-container {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: space-around;
    margin: 0 auto;
    width: 50vw;
    max-width: 50vw;
    box-sizing: border-box;
    font-size: 1.3rem;
}

.talks-2025-row {
    display: flex;
    align-items: center;
    justify-content: flex-start;
    gap: 2rem;
    margin-bottom: 1.6rem;
    margin-top: 1.6rem;
    width: 100%;
}

.talks-2025-info {
    align-items: start;
}

.talks-2025-row h2,
.talks-2025-row p {
    display: flex;
    align-items: start;
    justify-content: space-between;
    gap: 2rem;
    margin-bottom: 1.6rem;
    margin-top: 1.6rem;
    margin-left: 2rem;
    text-align: start;
    width: 100%;
}

/* ===========================
    ABOUT
    =========================== */
#about-contact-form h2 {
    text-align: center;
    margin-top: 6rem;
    font-size: 2rem;
}

#about-landing-page {
    text-align: center;
    margin-top: 10rem;
    font-size: 2rem;
    margin-left: 10vw;
    margin-right: 10vw;
}

#about-landing-page h4,
#about-landing-page p,
#about-landing-page ul > li {
    text-align: start;
}

#about-landing-page p {
    margin-bottom: 2.6rem;
}

/* ===========================
    CONTACT
    =========================== */
#contact-landing-page {
    text-align: center;
    margin-top: 10rem;
    font-size: 2rem;
    margin-left: 10vw;
    margin-right: 10vw;
}

/* ===========================
    PARALLAX
    =========================== */
.parallax {
    background-attachment: fixed;
    background-position: center;
    background-repeat: no-repeat;
    background-size: cover;
}

/* ===========================
    FOOTER
    =========================== */
footer {
    left: 0;
    bottom: 0;
    width: 100%;
    background: var(--background-primary-color);
    text-align: center;
    padding: 2em 0;
    z-index: 999;
}
footer a {
    text-decoration: none;
    color: var(--tedx-logo-secondary-color);
    margin: 0 1.4rem;
}

/* ===========================
    SLIDESHOW MODAL
    =========================== */
.slideshow-modal {
    display: none;
    position: fixed;
    z-index: 10001;
    left: 0;
    top: 0;
    width: 100vw;
    height: 100vh;
    background: rgba(0, 0, 0, 0.9);
    justify-content: center;
    align-items: center;
}
.slideshow-modal.active {
    display: flex;
}
.slideshow-content {
    max-width: 90vw;
    max-height: 80vh;
    margin: auto;
    box-shadow: 0 2px 16px rgba(0, 0, 0, 0.4);
}
.slideshow-close,
.slideshow-prev,
.slideshow-next {
    position: absolute;
    color: #fff;
    font-size: 2.5rem;
    cursor: pointer;
    user-select: none;
    top: 50%;
    transform: translateY(-50%);
    z-index: 10002;
}
.slideshow-close {
    top: 2rem;
    right: 2rem;
    font-size: 3rem;
    transform: none;
}
.slideshow-prev {
    left: 2vw;
}
.slideshow-next {
    right: 2vw;
}
.slideshow-counter {
    position: absolute;
    bottom: 2rem;
    left: 50%;
    transform: translateX(-50%);
    color: var(--background-primary-color);
    font-size: 1.3rem;
    background: rgba(0, 0, 0, 0.4);
    padding: 0.4em 1em;
    border-radius: 1em;
    z-index: 10003;
}

/* ===========================
    CONTACT FORM
    =========================== */
.contact-form {
    display: flex;
    flex-direction: column;
    align-items: stretch;
    gap: 1.2rem;
    max-width: 400px;
    margin: 0 auto;
}

.contact-form label {
    text-align: left;
    margin-bottom: 0.2rem;
    font-size: 1.3rem;
    font-weight: 100;
}

.contact-form input,
.contact-form textarea {
    width: 100%;
    padding: 0.7rem;
    border: 1px solid #ccc;
    border-radius: 6px;
    font-size: 1rem;
    box-sizing: border-box;
}

/* ===========================
    MEDIA QUERIES
    =========================== */

/* --- Desktop Speaker Layout --- */
@media (min-width: 901px) {
    #speakers-landing-page {
        margin-left: 8vw;
        margin-right: 8vw;
        text-align: left;
    }
    .speaker-row {
        margin-left: 0;
        margin-right: 0;
    }
}

/* --- Talks 2025 Responsive --- */
@media (max-width: 1650px) {
    #talks-2025-container {
        width: 100vw;
        max-width: 100vw;
        padding-left: 0;
        padding-right: 0;
    }
    .talks-2025-row {
        flex-direction: column !important;
        align-items: center;
        justify-content: center;
        gap: 1.6rem;
    }
    .talks-2025-row .talks-2025-info {
        order: 1;
        width: 95%;
        max-width: 592px;
    }
    .talks-2025-row .talks-2025-video {
        order: 2;
        width: 100%;
        max-width: 592px;
    }
    .talks-2025-row .talks-2025-video iframe {
        width: 100%;
        max-width: 592px;
        height: 305px;
        display: block;
        margin: 0 auto;
    }

    .talks-2025-info {
        align-items: center;
        justify-content: center;
    }

    .talks-2025-info h2,
    .talks-2025-info p {
        text-align: start;
        margin-left: 0;
    }

    #talks-2025-h2 {
        width: 95vw;
    }
}

/* --- Navigation Responsive --- */
@media (max-width: 1240px) {
    .nav-links {
        display: none !important;
    }
    .nav-links.open {
        display: flex !important;
        position: absolute;
        top: 85px;
        right: 0;
        background: var(--background-primary-color);
        flex-direction: column;
        align-items: flex-end;
        width: 100%;
        gap: 0;
        padding: 1rem 2rem;
    }
    .nav-menu-icon {
        display: block;
    }
    .nav-links li {
        width: 100%;
        text-align: right;
        margin: 0.5rem 0;
    }
    .nav-links a {
        font-size: 1.2rem;
        width: 100%;
        display: block;
        padding: 0.75rem 0;
    }
}

/* --- Speaker Image/Info Responsive --- */
@media (max-width: 1240px) and (min-width: 901px),
    (max-width: 1440px) and (min-width: 901px) {
    .speaker-row .speaker-img {
        flex: 0 0 380px;
        max-width: 380px;
    }
    .speaker-row .speaker-info {
        font-size: 0.9rem;
    }
}

/* --- Tablet/Mobile Layouts --- */
@media (max-width: 900px) {
    .home-about {
        flex-direction: column;
        gap: 2rem;
        max-width: 100%;
        margin-left: 0;
        margin-right: 0;
        padding: 0 1.6rem;
    }
    .home-about-item {
        width: 100%;
    }
    #home-memorable-moments-photos {
        column-count: 2;
    }
    .dropdown-content {
        position: static;
        box-shadow: none;
        min-width: 100%;
    }
    .speaker-row,
    .speaker-row.reverse {
        flex-direction: column;
        gap: 1.5rem;
    }
    .speaker-row .speaker-img,
    .speaker-row.reverse .speaker-img {
        max-width: 100%;
        flex-basis: 100%;
        width: 100%;
    }
    .speaker-row .speaker-info {
        font-size: 1.05rem;
        margin-left: 2.6vw;
        margin-right: 2.6vw;
    }
    .speaker-row .speaker-info h2 {
        font-size: 1.1rem;
    }
    .speaker-row .speaker-img img {
        width: 100vw;
        max-width: 100vw;
        height: auto;
        object-fit: contain;
    }
    #event-details {
        font-size: 1.6rem;
    }
}

/* --- Small Mobile --- */
@media (max-width: 767px) {
    #home-memorable-moments-photos {
        column-count: 1;
    }
    #event-details {
        font-size: 1.2rem;
    }
    .event-link a {
        margin-right: 2rem;
        font-size: 1.4rem;
    }
}

/* --- Extra Small Mobile --- */
@media (max-width: 500px) {
    #speakers-landing-page h1 img,
    #partners-landing-page h1 img,
    #apply-to-be-a-partner-landing-page img,
    #events-landing-page img,
    #home-about-h2-logo {
        height: auto;
        vertical-align: middle;
    }
    #home-about-h2-logo {
        max-width: 80vw;
    }
    #speakers-landing-page h1,
    #partners-landing-page h1,
    #apply-to-be-a-partner-landing-page h1,
    #events-landing-page h1 {
        word-break: break-word;
    }
    #speakers-landing-page h2,
    #partners-landing-page h2,
    #partner-contact-form,
    #pdf-download-div {
        max-width: 85vw;
        margin-left: auto;
        margin-right: auto;
    }
    .event-link a {
        font-size: 1rem;
    }
}

/* --- to show all nav links on small height screens --- */
@media (max-height: 800px) {
    .nav-links.open {
        overflow-y: auto;
        max-height: 75dvh;
    }
}
