/* Agenda CSS Styles - ALIGNED WITH PAGE LAYOUT */
.agenda-container {
    font-family: "Inter", sans-serif;
    background-color: #ffffff;
    color: #000000;
    margin: 0;
    padding: 0;
    min-height: 600px;
    font-size: 13px;
    line-height: 1.4;
    width: 100%;
    max-width: 100%;
}

.agenda-main-container {
    display: grid;
    grid-template-columns: 220px 1fr;
    gap: 1.5rem;
    width: 100%;
    max-width: 100%;
}

/* Left agenda column */
.agenda-column {
    position: sticky;
    width: 220px;
    top: 1.5rem;
    align-self: start;
    height: calc(100vh - 3rem);
    overflow-y: auto;
}


/* md breakpoint (≥768px) */
@media (min-width: 768px) {
  .apply-to-speak-title {
    font-size: 1.875rem;    /* text-3xl */
  }
}


/* Right content column */
.agenda-right-content {
    grid-column: 2;
    height: calc(100vh - 3rem);
    overflow-y: auto;
    padding-right: 0.75rem;
}

.gmt-info {
    font-size: 0.95rem;
    color: #333;
    margin-bottom: 3px;
    text-align: justify;
}

.current-time {
    font-size: 0.95rem;
    color: #555;
    margin-top: 0.25rem;
}

/* Day navigation tabs */
.day-nav-container {
    display: flex;
    position: relative;
    border-bottom: 2px solid #ccc;
    position: sticky;
    top: 0;
    background: white;
    z-index: 1;
    padding-top: 0.25rem;
    width: 100%;
}

.day-nav-item {
    cursor: pointer;
    padding: 0.75rem 0;
    position: relative;
    flex: 1;
    text-align: start;
    transition: color 0.3s ease-in-out;
}

.day-label {
    font-size: 1.1rem;
    font-weight: 800;
    color: #555;
}

.day-date-label {
    font-size: 0.85rem;
    color: #777;
}

.day-nav-item.active .day-label,
.day-nav-item.active .day-date-label {
    color: #000;
}

.day-nav-item:hover .day-label,
.day-nav-item:hover .day-date-label {
    color: #000;
}

.day-underline {
    position: absolute;
    bottom: -2px;
    left: 0;
    height: 3px;
    background-color: #4f7f38;
    width: 100%;
    opacity: 0;
    transition: opacity 0.3s ease-in-out;
}

.day-nav-item.active .day-underline,
.day-nav-item:hover .day-underline {
    opacity: 1;
}

/* Tab content for events */
.tab-content {
    display: none;
}

.tab-content.active {
    display: block;
}

/* Event card styling */
.event-card {
    padding: 0.875rem;
    border-top: 0.5px solid #ccc;
    border-bottom: 0.5px solid #ccc;
    border-left: 5px solid #eee;
    transition: all 0.3s ease-in-out;
    display: grid;
    grid-template-columns: 1fr 1.5fr;
    align-items: start;
    position: relative;
    cursor: pointer;
    color: #000000;
    margin: 0;
}

.event-card:hover {
    border-color: #4f7f38;
}

.time-duration-container {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    min-height: 100%;
    justify-content: space-between;
    gap: 0.25rem;
}

.event-time {
    font-weight: 700;
    font-size: 1rem;
    color: #000;
    line-height: 1.1;
}

.event-location-on-card {
    font-size: 0.85rem;
    color: #666;
    margin-top: 0.125rem;
}

.event-duration {
    font-size: 0.85rem;
    color: #444;
    margin-top: 0.25rem;
}

.event-details {
    display: flex;
    flex-direction: column;
    justify-content: flex-start;
    height: 100%;
}

.event-title {
    font-size: 1rem;
    font-weight: 800;
    color: #4f7f38;
    line-height: 1.2;
    margin-bottom: 0.125rem;
    word-wrap: break-word;
    overflow-wrap: break-word;
}

.event-speakers {
    font-size: 0.9rem;
    color: #333;
    margin-top: 0.125rem;
    word-wrap: break-word;
    overflow-wrap: break-word;
    line-height: 1.3;
}

/* Left vertical line and dot on hover */
.event-card::before {
    content: "";
    position: absolute;
    top: 0;
    left: 0;
    height: 100%;
    width: 1px;
    background-color: transparent;
    transition: background-color 0.3s ease-in-out;
}

.event-card:hover::before {
    background-color: #4f7f38;
}

.event-card::after {
    content: "";
    position: absolute;
    left: -7px;
    top: 50%;
    transform: translateY(-50%);
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background-color: #4f7f38;
    opacity: 0;
    transition: opacity 0.3s ease-in-out;
}

.event-card:hover::after {
    opacity: 1;
}

/* Right vertical line and dot */
.hover-right-line {
    position: absolute;
    top: 0;
    right: 0;
    height: 100%;
    width: 1px;
    background-color: transparent;
    transition: background-color 0.3s ease-in-out;
}

.event-card:hover .hover-right-line {
    background-color: #4f7f38;
}

.hover-right-dot {
    position: absolute;
    right: -5px;
    top: 50%;
    transform: translateY(-50%);
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background-color: #4f7f38;
    opacity: 0;
    transition: opacity 0.3s ease-in-out;
}

.event-card:hover .hover-right-dot {
    opacity: 1;
}

/* Info icon styling */
.info-icon {
    position: absolute;
    right: 0.875rem;
    top: 50%;
    transform: translateY(-50%);
    pointer-events: none;
    opacity: 0;
    transition: opacity 0.3s ease-in-out, background-color 0.3s ease-in-out;
    padding: 5px;
    border-radius: 50%;
    background-color: transparent;
    display: flex;
    align-items: center;
    justify-content: center;
    width: 32px;
    height: 32px;
}

.event-card:hover .info-icon {
    opacity: 1;
    background-color: #e9f2e3;
}

/* Filter dropdown */
.filter-container {
    margin-top: 1rem;
    padding-top: 1rem;
    border-top: 1px solid #eee;
}

.filter-label {
    font-weight: 600;
    margin-bottom: 0.5rem;
    display: block;
    font-size: 0.9rem;
}

.industry-select {
    width: 100%;
    padding: 0.5rem 0.75rem;
    border-radius: 4px;
    border: 1px solid #ccc;
    background-color: #f9f9f9;
    font-size: 0.85rem;
    cursor: pointer;
    transition: all 0.3s ease-in-out;
    appearance: none;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='16' height='16' viewBox='0 0 24 24' fill='none' stroke='%23333' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpolyline points='6 9 12 15 18 9'%3E%3C/polyline%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: right 0.8rem center;
    background-size: 16px;
    padding-right: 2.5rem;
}

/* Color coding for event highlights */
.highlight-nsssc {
    border-left-color: #009cff !important;
}

.highlight-sro {
    border-left-color: #232b38 !important;
}

.highlight-smh {
    border-left-color: #2e7d32 !important;
}

.highlight-asb {
    border-left-color: #ff6f00 !important;
}

.highlight-cscs {
    border-left-color: #c62828 !important;
}

.highlight-vendor {
    border-left-color: #8b4513 !important;
}

/* Styling for non-highlighted events */
.event-card-subdued {
    opacity: 0.8;
    filter: grayscale(10%);
    transition: all 0.3s ease-in-out;
}

/* Modal styles */
.modal-overlay {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.5);
    justify-content: center;
    align-items: center;
    z-index: 9999;
}

.modal-content {
    background-color: white;
    padding: 0;
    border-radius: 8px;
    box-shadow: 0 0 20px rgba(0, 0, 0, 0.3);
    position: relative;
    width: 85%;
    max-width: 450px;
    max-height: 90vh;
    overflow-y: auto;
    animation: modalSlideIn 0.3s ease-out;
}

@keyframes modalSlideIn {
    from {
        opacity: 0;
        transform: translateY(-20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.modal-close-button {
    position: absolute;
    top: 8px;
    right: 8px;
    font-size: 1.25rem;
    cursor: pointer;
    border: none;
    background: none;
    padding: 0;
    z-index: 11;
    color: #fff;
}

.modal-header-section {
    background-color: #232b38;
    padding: 0.75rem 1.5rem;
    border-bottom: 1px solid #eee;
    position: sticky;
    top: 0;
    z-index: 5;
}

.modal-header-section h3 {
    color: #fff;
    margin-bottom: 0;
    font-size: 1.1rem;
}

.modal-body-content {
    padding: 0 1.5rem 1.5rem 1.5rem;
}

.modal-title-and-calendar-container {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    margin-top: 1rem;
    gap: 0.5rem;
}

.modal-main-title {
    font-size: 1.1rem;
    font-weight: 700;
    color: #000;
    line-height: 1.2;
    flex-grow: 1;
}

.modal-sub-info {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    font-size: 0.9rem;
    color: #666;
    margin-top: 0.25rem;
    font-weight: 500;
}

.modal-description {
    margin-top: 1rem;
    line-height: 1.5;
    color: #333;
    text-align: justify;
    margin-bottom: 1.5rem;
    padding-bottom: 1rem;
    border-bottom: 1px solid #eee;
    font-size: 0.9rem;
}

.add-to-calendar-heading-button {
    font-size: 0.75rem;
    font-weight: 600;
    color: #777;
    text-transform: uppercase;
    padding: 0.4rem 0.75rem;
    border: 1px solid #ccc;
    border-radius: 6px;
    display: flex;
    align-items: center;
    gap: 0.5rem;
    cursor: pointer;
    transition: all 0.3s ease;
    background-color: #f9f9f9;
    flex-shrink: 0;
}

.add-to-calendar-heading-button:hover {
    color: #4f7f38;
    border-color: #4f7f38;
    background-color: #e9f2e3;
}

.add-to-calendar-heading-button .add-to-calendar-icon {
    width: 16px;
    height: 16px;
    stroke: #777;
    fill: none;
    transition: stroke 0.3s ease;
}

.add-to-calendar-heading-button:hover .add-to-calendar-icon {
    stroke: #4f7f38;
}

.modal-speaker-card {
    display: flex;
    align-items: center;
    margin-bottom: 0.75rem;
    gap: 0.75rem;
    padding: 0.75rem;
    border-radius: 8px;
    border: 1px solid #eee;
    background-color: #f9f9f9;
}

.modal-speaker-image {
    width: 45px;
    height: 45px;
    border-radius: 50%;
    object-fit: cover;
}

.modal-speaker-details {
    display: flex;
    flex-direction: column;
}

.modal-speaker-name {
    font-weight: 600;
    color: #000;
    font-size: 0.95rem;
}

.modal-speaker-title-company {
    margin: 0;
    font-size: 0.8rem;
    line-height: 1.3;
}

.speaker-title {
    color: #000;
}

.speaker-company {
    color: #01675f;
}

.modal-section-heading {
    font-size: 0.75rem;
    font-weight: 600;
    color: #777;
    text-transform: uppercase;
    margin-bottom: 0.75rem;
    padding-top: 1rem;
    border-top: 1px solid #eee;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.modal-moderator-section .modal-section-heading {
    margin-top: 1.5rem;
}

.add-to-calendar-buttons-container {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 0.5rem;
    margin-top: 0.75rem;
}

.add-to-calendar-button {
    display: inline-flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 0.25rem;
    background-color: #f0f0f0;
    color: #333;
    padding: 0.5rem 0.25rem;
    border-radius: 6px;
    font-weight: 600;
    font-size: 0.75rem;
    cursor: pointer;
    border: 1px solid #ddd;
    transition: background-color 0.3s ease, border-color 0.3s ease;
}

.add-to-calendar-button:hover {
    background-color: #e0e0e0;
    border-color: #ccc;
}

.add-to-calendar-button img {
    width: 22px;
    height: 22px;
    object-fit: contain;
}

.action-buttons-container {
    margin-top: 1rem;
    padding-top: 1rem;
    border-top: 1px solid #eee;
    display: flex;
    justify-content: start;
}

.action-button {
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 0.5rem 1rem;
    border-radius: 6px;
    border: 1px solid #ccc;
    background-color: #f9f9f9;
    color: #333;
    font-weight: 600;
    font-size: 0.85rem;
    cursor: pointer;
    transition: background-color 0.3s ease, border-color 0.3s ease,
        color 0.3s ease;
    gap: 0.5rem;
    width: auto;
}

.action-button:hover {
    background-color: #e9f2e3;
    border-color: #4f7f38;
    color: #4f7f38;
}

.action-button svg {
    width: 16px;
    height: 16px;
    stroke: currentColor;
    fill: none;
}

/* Mobile responsiveness */
@media (max-width: 1024px) {
    .agenda-main-container {
        grid-template-columns: 1fr;
        gap: 1rem;
        width: 100%;
    }

    .agenda-column {
        position: static;
        width: 100%;
        height: auto;
    }

    .agenda-right-content {
        grid-column: 1;
        height: auto;
        overflow-y: visible;
        padding-right: 0;
    }
}

@media (max-width: 768px) {
    .agenda-container {
        font-size: 12px;
    }
    
    .agenda-title {
        font-size: 1.5rem;
    }
    
    .day-label {
        font-size: 1rem;
    }
    
    .day-date-label {
        font-size: 0.8rem;
    }
    
    .modal-content {
        width: 90%;
        max-width: 90%;
    }
    
    .modal-body-content {
        padding: 0 1rem 1rem;
    }
}

@media (max-width: 640px) {
    .agenda-container {
        font-size: 11px;
    }
    
    .agenda-main-container {
        gap: 0.75rem;
    }

    .agenda-header {
        padding-top: 0.5rem;
    }

    .agenda-title {
        font-size: 1.25rem;
    }

    .day-nav-container {
        flex-direction: row;
        justify-content: space-around;
        gap: 0;
        margin-bottom: 0.75rem;
    }

    .day-nav-item {
        padding: 0.75rem 0.25rem;
        text-align: center;
        min-width: 33.33%;
    }

    .day-label {
        font-size: 0.9rem;
    }

    .day-date-label {
        font-size: 0.75rem;
    }

    .event-card {
        grid-template-columns: 1fr;
        gap: 0.75rem;
        padding: 0.875rem 0.75rem;
        margin: 0.5rem 0;
        border-radius: 8px;
        box-shadow: 0 2px 8px rgba(0,0,0,0.05);
    }
    @media (max-width: 767px) {
    .time-duration-container {
        flex-direction: row;
        align-items: center;
        flex-wrap: wrap;
        gap: 0.75rem;
        margin-bottom: 0.5rem;
    }

    .event-time {
        font-size: 0.95rem;
        font-weight: 700;
        color: #000;
    }

    .event-location-on-card {
        margin-top: 0;
        margin-left: 0.5rem;
        font-size: 0.8rem;
        color: #666;
    }

    .event-duration {
        margin-top: 0;
        margin-left: auto;
        font-size: 0.8rem;
        color: #444;
    }

    .event-title {
        font-size: 0.95rem;
    }

    .event-speakers {
        font-size: 0.85rem;
        line-height: 1.4;
    }

    .info-icon {
        right: 0.75rem;
        transform: translateY(-50%);
        width: 28px;
        height: 28px;
        padding: 4px;
    }

    .modal-content {
        width: 95%;
        max-width: 95%;
        margin: 0.5rem;
        max-height: 85vh;
    }

    .modal-body-content {
        padding: 0 0.875rem 0.875rem;
    }

    .modal-main-title {
        font-size: 1rem;
    }
    
    .modal-description {
        font-size: 0.85rem;
    }

    .add-to-calendar-buttons-container {
        grid-template-columns: 1fr 1fr;
        gap: 0.5rem;
    }

    .modal-title-and-calendar-container {
        flex-direction: column;
        align-items: flex-start;
    }

    .add-to-calendar-heading-button {
        width: 100%;
        justify-content: center;
        font-size: 0.7rem;
        padding: 0.35rem 0.5rem;
    }

    .modal-speaker-card {
        padding: 0.5rem;
        gap: 0.5rem;
    }

    .modal-speaker-image {
        width: 40px;
        height: 40px;
    }

    .modal-speaker-name {
        font-size: 0.9rem;
    }

    .modal-speaker-title-company {
        font-size: 0.75rem;
    }
    
    /* Filter dropdown */
    .filter-label {
        font-size: 0.85rem;
    }
    
    .industry-select {
        font-size: 0.85rem;
        padding: 0.6rem 0.75rem;
    }
    .agenda-modal h2 { 
        font-size: 1.25rem; /* Modal primary title */
    }
    .agenda-modal h3 { 
        font-size: 1.1rem;  /* Modal session title */
    }
    .agenda-modal p,
    .agenda-modal li,
    .agenda-modal div:not(.modal-speaker-card) { 
        font-size: 0.8rem; /* General text and body content */
    }
}

/* Landscape mobile optimization */
@media (max-height: 600px) and (orientation: landscape) {
    .agenda-column {
        height: auto;
        position: static;
    }
    
    .agenda-right-content {
        height: auto;
        max-height: 70vh;
    }
    
    .modal-content {
        max-height: 80vh;
    }
}

/* Improve hover effects for touch devices */
@media (hover: none) and (pointer: coarse) {
    .event-card:hover {
        border-color: #eee;
    }
    
    .event-card:hover::before,
    .event-card:hover::after,
    .event-card:hover .hover-right-line,
    .event-card:hover .hover-right-dot {
        opacity: 0;
    }
    
    .info-icon {
        opacity: 0.5;
        background-color: #f0f0f0;
    }
}