@import url('https://fonts.googleapis.com/css2?family=Montserrat:ital,wght@0,100..900;1,100..900&display=swap');

/* General Reset */
* {
    border: 0;
    font: inherit;
    font-size: 1em;
    font-family: "Montserrat", sans-serif;
    box-sizing: border-box; /* Better box model control */
}

/* Body Styling */
body {
    color: #505050;
    text-align: left;
    margin: 2em auto; /* Center the body horizontally */
    max-width: 1200px; /* Set a maximum width for content */
    padding: 0 2em; /* Add padding for spacing on smaller screens */
    background: #fff; /* Optional: Add a background color */
}

/* Links */
a {
    color: #b8860b;
    text-decoration: none;
}
a.current {
    color: #52739e;
}
a.current:hover {
    color: #e82945;
}
a:hover {
    color: #b2132e;
}
a:active {
    color: #e82945;
}

/* Headings */
h1, h2, h3, h4 {
    clear: left;
    color: #813c54;
    margin: 1.5em 0em 1em 0em;
    font-family: "Montserrat", sans-serif;
    line-height: 1.2; /* Ensure better readability */
}
h1 {
    font-size: 2.5em; /* Scaled slightly for better adaptability */
}
h2 {
    font-size: 2em;
}
h3 {
    font-size: 1.5em;
}
h4 {
    font-size: 1.25em;
}

/* Paragraphs and Lists */
p {
    list-style: none;
    text-align: left;
    margin: 1em 0; /* Added margin for spacing */
}
li a, p a {
    text-decoration: underline;
    text-decoration-color: #b8860b;
}
ul {
    text-align: left;
    margin: 1em 0; /* Added spacing */
    padding: 0; /* Removed default padding */
}
ul li {
    text-align: left;
    margin-left: 1em; /* Indented list items */
}
i, em {
    font-style: italic;
}
b, strong {
    font-weight: bold;
}

/* Tables */
table {
    width: 100%; /* Full-width for responsiveness */
    margin: 1em auto; /* Centered and responsive spacing */
    border-collapse: collapse; /* Improve table aesthetics */
}
th, td {
    text-align: left;
    padding: 0.5em; /* Add padding for better readability */
    word-wrap: break-word; /* Handle overflow text */
}

/* Responsive Adjustments */
@media (max-width: 768px) {
    body {
        margin: 3em 5%; /* Reduce margin for smaller screens */
    }

    h1 {
        font-size: 2em; /* Scale headings down for smaller screens */
    }
    h2 {
        font-size: 1.75em;
    }
    h3 {
        font-size: 1.5em;
    }
    h4 {
        font-size: 1.25em;
    }

    table {
        font-size: 0.9em; /* Adjust table font size */
    }
}

@media (max-width: 480px) {
    body {
        margin: 2em 3%; /* Further reduce margins for mobile */
    }

    h1 {
        font-size: 1.75em; /* Further scale down headings */
    }
    h2 {
        font-size: 1.5em;
    }
    h3 {
        font-size: 1.25em;
    }
    h4 {
        font-size: 1em;
    }

    table {
        font-size: 0.8em; /* Further adjust table font size */
    }

    p, ul, li {
        margin: 0.5em 0; /* Reduce spacing for compactness */
    }
}


/* Website Banner */
.banner { 
    display: block; 
    padding: 1em;
}

.banner .title {
    font-size: 5em; 
    color: #1b1b1b; 
    text-align: center; 
    font-weight: 900;
}

.banner .subtitle {
    font-size: 3em; 
    padding: 0 1em;
    color: #1b1b1b; 
    text-align: center; 
}

.banner .date {
    font-size: 1.5em; 
    color: #505050; 
    text-align: center; 
    font-weight: 300;
    margin-bottom: 1em;
}

.banner img {
    display: block; 
    margin: auto; 
    width: 70%; 
    height: auto;
}

/* Responsive Styles */
@media (max-width: 1200px) {
    .banner .title {
        font-size: 3em;
    }
    .banner .subtitle {
        font-size: 2.5em;
    }
    .banner .date {
        font-size: 1.2em;
    }
    .banner img {
        width: 85%;
    }
}

@media (max-width: 768px) {
    .banner .title {
        font-size: 2em;
    }
    .banner .subtitle {
        font-size: 2em;
    }
    .banner .date {
        font-size: 1em;
    }
    .banner img {
        width: 100%;
    }
}

@media (max-width: 480px) {
    .banner .title {
        font-size: 2em;
    }
    .banner .subtitle {
        font-size: 1.5em;
    }
    .banner .date {
        font-size: 0.9em;
    }
    .banner img {
        width: 100%;
    }
}

/* Navigation Links (Home, Registration, etc) */
table.navigation {
    width: 100%; /* Full-width to adapt to the container */
    max-width: 800px; /* Limit maximum width for larger screens */
    margin: 0 auto; /* Center the table */
    border-collapse: collapse; /* Improve table aesthetics */
}

td.navigation {
    font-size: 1.5em; /* Slightly smaller base font size */
    white-space: nowrap; /* Prevent text wrapping */
    width: auto; /* Allow cells to adjust dynamically */
    text-align: center;
    vertical-align: middle;
    padding: 0.5rem; /* Add padding for better spacing */
}

/* Responsive Adjustments */
@media (max-width: 768px) {
    table.navigation {
        width: 100%; /* Ensure full-width on smaller screens */
        margin: 0 auto; /* Keep it centered */
    }

    td.navigation {
        font-size: 1.2em; /* Reduce font size for smaller screens */
        padding: 0.25rem; /* Reduce padding */
    }
}

@media (max-width: 480px) {
    table.navigation {
        display: block; /* Switch to block layout for very small screens */
        width: 100%; /* Full-width on mobile */
    }

    td.navigation {
        display: block; /* Stack navigation items vertically */
        font-size: 1em; /* Further reduce font size */
        padding: 0.5rem 0; /* Adjust spacing for stacked layout */
        text-align: center; /* Ensure text remains centered */
        width: 100%; /* Allow full width for each item */
        border-bottom: 1px solid #ddd; /* Optional: Add a separator */
    }

    td.navigation:last-child {
        border-bottom: none; /* Remove border from the last item */
    }
}

/* The Table on the Program Page */
td.room,
td.date,
td.title,
td.title-special,
td.speaker-program,
td.abstract {
    vertical-align: top; /* Ensure all cells align at the top */
    padding: 0.25rem 0.75rem; /* Consistent padding */
    word-wrap: break-word; /* Prevent overflow */
}

td.room {
    font-size: 1.5rem;
    color: #52739e;
    width: 90%; /* Dynamic width for room */
}

td.date {
    white-space: nowrap; /* Keep date on one line */
    width: 100px; /* Enforce a fixed width */
    text-align: right;
    font-size: 1rem;
    vertical-align: top; /* Align date text to the top */
}

td.title {
    font-size: 1.2rem;
    color: #813c54;
    font-family: "Montserrat", sans-serif;
}

td.title-special {
    font-size: 1.5rem;
    color: #52739e;
    font-family: "Montserrat", sans-serif;
}

td.speaker-program {
    font-style: italic;
    font-size: 1rem;
}

td.abstract {
    font-size: 1rem;
    min-height: 60px;
    display: flex; /* Use flexbox for better content alignment */
    flex-direction: column;
    justify-content: flex-start;
}

td.abstract img {
    display: block;
    max-width: 100%;
    height: auto;
    margin: 0.25rem auto;
}

table.plenary {
    padding-top: 0.5rem;
    background: #ffffff;
    width: 100%;
    border-collapse: collapse;
}

/* Responsive Adjustments */
@media (max-width: 768px) {
    td.room,
    td.date,
    td.title,
    td.title-special,
    td.speaker-program,
    td.abstract {
        font-size: 1rem;
        padding: 0.5rem;
    }

    td.date {
        width: auto; /* Allow flexible width on smaller screens */
        text-align: left;
    }

    td.abstract img {
        max-width: 90%;
    }
}

@media (max-width: 480px) {
    td.room,
    td.date,
    td.title,
    td.title-special,
    td.speaker-program,
    td.abstract {
        font-size: 0.9rem;
        padding: 0.25rem;
    }

    td.date {
        width: auto;
        text-align: center;
    }

    table.plenary {
        font-size: 0.9rem;
    }
}




/* Registration and Directions iframes and Images */
iframe.directions {
    display: block;
    margin: 1em auto 2em auto;
    width: 100%; /* Full width for responsiveness */
    max-width: 800px; /* Limit maximum width */
    height: 50vw; /* Dynamically adjust height based on viewport width */
    max-height: 400px; /* Limit maximum height */
    border: none;
}

/* Responsive Adjustments */
@media (max-width: 768px) {
    iframe.directions {
        height: 60vw; /* Increase height proportion for smaller screens */
        max-height: 300px; /* Adjust maximum height for better layout */
    }
}

@media (max-width: 480px) {
    iframe.directions {
        height: 70vw; /* Increase height proportion further for very small screens */
        max-height: 250px; /* Adjust maximum height for smaller devices */
    }
}

 /* Form Container */
form {
    max-width: 90%; /* Adjust to fit smaller screens */
    width: 400px; /* Default width for larger screens */
    margin: 20px auto; /* Center the form */
    padding: 20px;
    border: 1px solid #ddd;
    border-radius: 10px;
    background-color: #f9f9f9;
}

/* Labels */
label {
    font-size: 14px;
    font-weight: bold;
    color: #333;
    display: block;
    margin-bottom: 5px;
}

/* Inputs */
input[type="text"],
input[type="email"] {
    width: 100%;
    padding: 10px;
    margin-bottom: 15px;
    border: 1px solid #ccc;
    border-radius: 5px;
    font-size: 14px;
    box-sizing: border-box; /* Ensure padding is included in width */
}

input[type="text"]:focus,
input[type="email"]:focus {
    border-color: #007bff;
    outline: none;
}

/* Buttons */
button {
    width: 100%;
    padding: 10px;
    background-color: #007bff;
    color: #fff;
    border: none;
    border-radius: 5px;
    font-size: 16px;
    font-weight: bold;
    cursor: pointer;
    transition: background-color 0.3s ease; /* Smooth hover transition */
}

button:hover {
    background-color: #0056b3;
}

/* Responsive Adjustments */
@media (max-width: 768px) {
    form {
        max-width: 95%; /* Reduce maximum width for smaller screens */
        padding: 15px; /* Adjust padding */
    }

    button {
        font-size: 14px; /* Adjust button font size for smaller screens */
        padding: 8px; /* Adjust button padding */
    }
}

@media (max-width: 480px) {
    form {
        max-width: 100%; /* Full-width for very small screens */
        margin: 10px auto; /* Adjust margin for compact layout */
        padding: 10px; /* Reduce padding */
    }

    label {
        font-size: 12px; /* Reduce label font size */
    }

    input[type="text"],
    input[type="email"] {
        padding: 8px; /* Adjust input padding */
        font-size: 12px; /* Reduce input font size */
    }

    button {
        font-size: 14px; /* Further reduce button font size */
        padding: 8px; /* Adjust button padding */
    }
}

/* Ponentes Section */
.organizers {
    display: block;
    margin: 2rem 0;
}

.organizer {
    display: flex;
    flex-wrap: wrap; /* Allow wrapping for smaller screens */
    align-items: flex-start;
    margin-bottom: 2rem;
    gap: 1rem; /* Space between image and content */
}

.organizer-image {
    flex: 1 1 300px; /* Flexible width with a base of 250px */
    max-width: 300px; /* Prevent growing beyond this size */
    aspect-ratio: 1 / 1; /* Ensure square aspect ratio */
    object-fit: cover; /* Crop image if necessary */
    overflow: hidden; /* Hide overflow */
    border-radius: 8px; /* Optional: Rounded corners */
}

.organizer-content {
    flex: 2 1 300px; /* Flexible width with a base of 300px */
    max-width: 100%; /* Ensure it adjusts to screen size */
}

.organizer-content h3 {
    font-size: 1.5rem;
    margin: 0 0 0.5rem;
    color: #333;
}

.organizer-content p {
    font-size: 1rem;
    color: #555;
    margin: 0 0 0.5rem;
}

.organizer-links {
    margin-top: 0.5rem;
    font-size: 0.9rem;
}

.organizer-links a {
    color: #007bff;
    text-decoration: none;
    margin-right: 0.5rem;
}

.organizer-links a:hover {
    text-decoration: underline;
}

.speakers {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr)); /* Adjust columns dynamically */
    gap: 1.25rem; /* Space between cells */
    margin: 2rem 0;
}

.speaker {
    text-align: center;
    padding: 1rem; /* Add padding */
    margin: 0 auto;
}

.speaker-image {
    width: 100%; /* Take full container width */
    max-width: 300px; /* Limit max size */
    aspect-ratio: 1 / 1; /* Maintain square shape */
    object-fit: cover; /* Crop to fit */
    overflow: hidden; /* Hide overflow */
    margin: 0 auto 0.5rem; /* Center image and add space below */
    border-radius: 8px; /* Optional: Rounded corners */
}

.speaker h3 {
    margin: 0;
    font-size: 1rem;
    color: #333;
}

.speaker p {
    margin: 0;
    font-size: 0.9rem;
    color: #555;
    text-align: center;
}

.speaker-links {
    font-size: 0.9rem;
    margin-top: 0.5rem;
}

.speaker-links a {
    color: #007bff;
    text-decoration: none;
}

.speaker-links a:hover {
    text-decoration: underline;
}

/* Media Queries for further responsiveness */
@media (max-width: 768px) {
    .organizer {
        flex-direction: column; /* Stack image and content */
        align-items: center; /* Center align */
    }

    .organizer-image {
        margin-bottom: 1rem; /* Add spacing when stacked */
    }

    .speaker {
        max-width: 100%; /* Ensure speakers take full width */
    }
}

.gva {
    display: block; 
    margin: auto; 
    width: 40%; 
    height: auto;
}



/* Responsive Styles */
@media (max-width: 1200px) {
    .gva {
        width: 50%;
    }
}

@media (max-width: 768px) {
    .gva {
        width: 100%;
    }
}

@media (max-width: 480px) {
    .gva {
        width: 100%;
    }
}

/* Center the video */
.video-container {
    display: flex;
    justify-content: center;
    align-items: center;
    margin: 2em auto;
    max-width: 100%;
}

/* Make the video fully responsive */
.video-js {
    width: 100%;
    height: auto;
    max-width: 800px; /* Matches your content layout */
    border-radius: 10px;
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.2);
}

/* Ensuring the video scales properly */
.vjs-fluid {
    padding-top: 56.25% !important; /* 16:9 Aspect Ratio */
    position: relative;
}

.vjs-fluid video {
    position: absolute;
    width: 100% !important;
    height: 100% !important;
}

@media (max-width: 1200px) {
    .video-js {
        max-width: 85%;
    }
}

@media (max-width: 768px) {
    .video-js {
        max-width: 100%;
    }
}