/* Events Container and Layout */
.events-container {
    max-width: 1200px;
    margin: 0 auto;
    font-family: 'IBM Plex Sans', Helvetica, Arial, Lucida, sans-serif;
    font-size: 15px;
}

.events-section {
    margin-bottom: 60px;
}

.events-section h2 {
    font-size: 2.25rem;
    font-weight: 500;
    text-align: center;
    margin: 40px 0 20px 0;
    color: #333;
    font-family: 'IBM Plex Sans Condensed', Helvetica, Arial, Lucida, sans-serif;
}

/* Event Table Styling */
.event-table {
    width: 100%;
    border-collapse: collapse;
    background: white;
    border-radius: 12px;
    overflow: hidden;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
    font-family: 'IBM Plex Sans', Helvetica, Arial, Lucida, sans-serif;
    font-size: 15px;
}

.event-table thead {
    background: #091A93;
    color: white;
}

.event-table th {
    padding: 20px 15px;
    text-align: left;
    font-weight: bold;
    font-size: 17px;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    font-family: 'IBM Plex Sans Condensed', Helvetica, Arial, Lucida, sans-serif;
}

/* Column width adjustments */
.when-header,
.when-column {
    width: 20%;
}

.where-header,
.where-column {
    width: 30%;
}

.models-header,
.models-cell {
    width: 25%;
}

.appointments-header,
.appointments-column {
    width: 25%;

    vertical-align: middle;
}

.event-table tbody tr {
    border-bottom: 1px solid #091A93;
    transition: background-color 0.2s ease;
    background-color: white;
}

.event-table tbody tr:nth-child(even) {
    background-color: #f8f9fa;
}

.event-table tbody tr:hover {
    background-color: #f0f0f0;
}

.event-table tbody tr:last-child {
    border-bottom: none;
}

.event-table td {
    padding: 35px 15px;
    font-size: 15px;
}

.event-table td strong {
    font-size: 15px;
    color: #1f2937;
}

/* Location styling */
.location-title {
    font-weight: bold;
    color: #1f2937;
    display: block;
}

.location-address {
    font-weight: normal;
    color: #4b5563;
}

/* Event Time Styling */
.event-time {
    color: #6b7280;
    font-size: 15px;
    margin-top: 4px;
    display: block;
}

/* Model List */
.models-cell {
    max-width: none;
}

.model-list {
    margin: 0;
    list-style-type: disc;
    padding: 15px 0 0 18px !important;
}

.model-list li {
    font-size: 15px;
    margin-bottom: 4px;
    color: #1f2937;
}

.model-list li:last-child {
    margin-bottom: 0;
}

.coming-soon {
    color: #6b7280;
    font-style: italic;
    font-size: 15px;
}

/* Booking TBD styling */
.booking-tbd {
    color: #6b7280;
    font-style: italic;
    font-size: 15px;
    text-align: left;
    display: block;
}

/* Book Button */
.book-btn {
    background-clip: border-box;
    background-color: #091A93;
    background-image: none;
    background-origin: padding-box;
    background-position: 50% 50%;
    background-repeat: no-repeat;
    background-size: cover;
    border: 0px solid rgb(255, 255, 255);
    border-radius: 100px;
    box-sizing: border-box;
    color: rgb(255, 255, 255);
    cursor: pointer;
    display: inline-block;
    font-family: 'IBM Plex Sans', Helvetica, Arial, Lucida, sans-serif;
    font-size: 14px;
    font-weight: 700;
    line-height: 23.8px;
    margin: 0;
    outline: none;
    padding: 12px 24px;
    position: relative;
    text-align: left;
    text-decoration: none;
    letter-spacing: 0.5px;
    transition: all 0.3s ease;
    vertical-align: baseline;
    -webkit-font-smoothing: antialiased;
}

.book-btn:hover {
    background-color: #0a1d9e;
    color: rgb(255, 255, 255);
    text-decoration: none;
}

/* No Events Message */
.no-events {
    text-align: center;
    color: #666;
    font-style: italic;
    padding: 40px;
    font-size: 15px;
}

/* Responsive Design - Tablet */
@media (max-width: 768px) {
    .events-section h2 {
        font-size: 2rem;
    }
    
    .event-table th,
    .event-table td {
        padding: 15px 10px;
    }
    
    .event-table th {
        font-size: 17px;
    }
    
    .model-list {
        gap: 4px;
    }
    
    .model-list li {
        font-size: 15px;
        margin-bottom: 2px;
    }
    
    .book-btn {
        padding: 10px 16px;
        font-size: 14px;
    }
}

/* Mobile Responsive - Card Layout */
@media (max-width: 1000px) {
    .event-table,
    .event-table thead,
    .event-table tbody,
    .event-table th,
    .event-table td,
    .event-table tr {
        display: block;
    }
    .event-table tbody tr:last-child {
    border-bottom: 1px solid #091A93;
}

    
    .event-table {
        background: transparent;
        box-shadow: none;
        border-radius: 0;
        overflow: visible;
    }
    
    /* Hide table headers (but not display: none for accessibility) */
    .event-table thead tr {
        position: absolute;
        top: -9999px;
        left: -9999px;
    }
    
    .event-table tbody {
        display: block;
    }
    
    .event-table tr {
        border: 1px solid #091A93;
        border-radius: 12px;
        margin-bottom: 30px;
        padding: 15px;
        background: transparent;
        box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
        display: block;
        position: relative;
    }
    
    .event-table tr:hover {
        background-color: transparent;
        box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
    }
    
    .event-table td {
        border: none;
        border-bottom: 1px solid #091A93;
        position: relative;
        padding: 12px 0;
        text-align: left;
        display: block;
        width: 100%;
        min-height: auto;
    }
    
    .event-table td:last-child {
        border-bottom: none;
        padding-bottom: 0;
    }
    
    .event-table td:first-child {
        padding-top: 0;
        border-top: none;
    }
    
    /* Add labels before each cell */
    .event-table td:before {
        content: "";
        display: block;
        font-weight: bold;
        color: #1e3a8a;
        font-size: 17px;
        text-transform: uppercase;
        letter-spacing: 0.3px;
        margin-bottom: 5px;
        font-family: 'IBM Plex Sans Condensed', Helvetica, Arial, Lucida, sans-serif;
    }
    
    .event-table td:nth-of-type(1):before { content: "WHEN"; padding-bottom: 20px}
    .event-table td:nth-of-type(2):before { content: "WHERE"; }
    .event-table td:nth-of-type(3):before { content: "AVAILABLE MODELS"; }
    .event-table td:nth-of-type(4):before { content: "APPOINTMENTS"; }

    .when-column .cell-content{
        padding-top: 20px !important;
    }
    
    /* Adjust specific cell styling for mobile */
    .event-table .models-cell {
        max-width: none;
    }
    
    .model-list {
        justify-content: flex-start;
        margin-top: 5px;
        padding-left: 18px;
    }
    
    .model-list li {
        font-size: 15px;
        margin-bottom: 2px;
    }
    
    .coming-soon {
        font-size: 15px;
        margin-top: 5px;
        display: block;
    }
    
    .book-btn {
        width: 100%;
        text-align: center;
        margin-top: 8px;
        padding: 14px;
        font-size: 14px;
        display: block;
        box-sizing: border-box;
    }
    
    /* Style the date/time cell */
    .event-table td:nth-of-type(1) strong {
        display: block;
        margin-bottom: 5px;
        font-size: 15px;
    }
    
    .event-time {
        font-size: 15px;
        margin-top: 3px;
        display: block;
    }
    
    /* Ensure proper spacing for location */
    .event-table td:nth-of-type(2) {
        line-height: 1.4;
    }
}

/* Very small screens */
@media (max-width: 400px) {
    .events-container {
    }
    
    .events-section h2 {
        font-size: 1.8rem;
        margin-bottom: 10px;
    }
    
    .event-table td {
        padding: 12px 15px 12px 40%;
        font-size: 15px;
    }
    
    .event-table td:before {
        width: 35%;
        font-size: 17px;
        top: 12px;
    }
    
    .model-list li {
        font-size: 15px;
        margin-bottom: 1px;
    }
}

/* WordPress specific overrides */
.entry-content thead th,
.entry-content tr th {
    color: white !important;
}

/* Override WordPress default table styling */
.entry-content .event-table {
    border: none !important;
    margin: 20px 0;
}

/* Ensure proper spacing in WordPress */
.entry-content .events-section {
    margin-bottom: 40px;
}

.entry-content .events-section:first-of-type{
    margin-bottom: 60px;
}


/* Mobile Responsive - Card Layout */
@media (max-width: 1000px) {
    .events-container {
    }
    
    .event-table,
    .event-table thead,
    .event-table tbody,
    .event-table th,
    .event-table td,
    .event-table tr {
        display: block;
    }
    
    .event-table {
        background: transparent;
        box-shadow: none;
        border-radius: 0;
        overflow: visible;
    }
    
    /* Hide table headers (but not display: none for accessibility) */
    .event-table thead tr {
        position: absolute;
        top: -9999px;
        left: -9999px;
    }
    
    .event-table tbody {
        display: block;
    }
    
    .event-table tr {
        border: 1px solid #091A93;
        border-radius: 12px;
        margin-bottom: 20px;
        padding: 0;
        background: white;
        box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
        display: block;
        position: relative;
        overflow: hidden;
    }
    
    .event-table tr:hover {
        background-color: white;
        box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
    }
    
    .event-table td {
        border: none;
        border-bottom: 1px solid #091A93;
        position: relative;
        padding: 0;
        text-align: left;
        display: block;
        width: 100%;
        min-height: auto;
        box-sizing: border-box;
        word-wrap: break-word;
        overflow-wrap: break-word;
    }
    
    .event-table td:last-child {
        border-bottom: none;
    }
    
    .event-table td:first-child {
        border-top: none;
        border-radius: 12px 12px 0 0;
        overflow: hidden;
    }
    
    /* Add blue header labels before each cell */
    .event-table td:before {
        content: "";
        display: block;
        font-weight: bold;
        color: #091A93;
        background-color: #091A93;
        font-size: 14px;
        text-transform: uppercase;
        letter-spacing: 0.5px;
        margin: 0;
        padding: 20px 20px 0 20px;
        font-family: 'IBM Plex Sans Condensed', Helvetica, Arial, Lucida, sans-serif;
        width: 100%;
        box-sizing: border-box;
    }
    
    /* First cell header gets rounded top corners */
    .event-table td:first-child:before {
        border-radius: 12px 12px 0 0;
        color: white;
    }
    
    /* Content area with proper spacing */
    .event-table td > * {
        padding: 15px 0;
        display: block;
        margin: 0;
    }
    
    /* Handle line breaks in mobile - convert to block display */
    .event-table td br {
        display: block;
        margin: 4px 0;
        content: "";
    }
    
    .event-table td br::after {
        content: "";
        display: block;
        margin: 4px 0;
    }
    
    .event-table td:nth-of-type(1):before { content: "WHEN"; background-color: #091A93; }
    .event-table td:nth-of-type(2):before { content: "WHERE"; background-color: #f1f3f500; }
    .event-table td:nth-of-type(3):before { content: "AVAILABLE MODELS"; background-color: #f1f3f500; }
    .event-table td:nth-of-type(4):before { content: "APPOINTMENTS"; background-color: #f1f3f500; }
    
    /* Adjust specific cell styling for mobile */
    .event-table .models-cell {
        max-width: none;
    }
    
    .model-list {
        justify-content: flex-start;
        margin-top: 8px;
        padding-left: 18px;
        margin-bottom: 0;
    }
    
    .model-list li {
        font-size: 15px;
        margin-bottom: 4px;
        line-height: 1.4;
        word-wrap: break-word;
    }
    
    .model-list li:last-child {
        margin-bottom: 0;
    }
    
    .coming-soon {
        font-size: 15px;
        margin-top: 0;
        display: block;
        line-height: 1.4;
    }
    
    .book-btn {
        width: 100%;
        text-align: center;
        margin-top: 10px;
        padding: 14px 20px;
        font-size: 14px;
        display: block;
        box-sizing: border-box;
        white-space: nowrap;
    }
    
    /* Style the date/time cell */
    .event-table td:nth-of-type(2) strong {
        display: block;
        font-size: 16px;
        line-height: 1.3;
        word-wrap: break-word;
        margin: 0;
        padding: 0;
    }
    
    .event-time {
        font-size: 15px;
        margin: 4px 0 0 0;
        padding: 0;
        display: block;
        line-height: 1.3;
    }
    
    /* Ensure proper spacing and wrapping for location */
    .event-table td:nth-of-type(1) {
        line-height: 1.4;
    }
    
    .location-title {
        display: block;
        margin: 0 0 4px 0;
        padding: 0;
        word-wrap: break-word;
        overflow-wrap: break-word;
        hyphens: auto;
    }
    
    .location-address {
        display: block;
        margin: 0;
        padding: 0;
        word-wrap: break-word;
        overflow-wrap: break-word;
        hyphens: auto;
        line-height: 1.4;
    }
    
    /* Booking TBD styling for mobile */
    .booking-tbd {
        color: #6b7280;
        font-style: italic;
        font-size: 15px;
        text-align: left;
        display: block;
        line-height: 1.4;
        margin-top: 0;
    }
}

/* Very small screens */
@media (max-width: 400px) {
    .events-container {
    }
    
    .events-section h2 {
        font-size: 1.8rem;
        margin-bottom: 10px;
    }
    
    .event-table td {
        padding: 0;
        font-size: 15px;
    }
    
    .event-table td > * {
        padding: 12px 15px;
    }
    
    .event-table td:nth-of-type(1):before { content: "WHEN"; background-color: #091A93; }
    .event-table td:nth-of-type(2):before { content: "WHERE"; background-color: #f1f3f500; }
    .event-table td:nth-of-type(3):before { content: "AVAILABLE MODELS"; background-color: #f1f3f500; }
    .event-table td:nth-of-type(4):before { content: "APPOINTMENTS"; background-color: #f1f3f500; }
    
    .event-table td:nth-of-type(2) strong {
        font-size: 15px;
        margin: 0;
        padding: 0;
    }
    
    .event-time {
        font-size: 14px;
        margin: 4px 0 0 0;
        padding: 0;
    }
    
    .event-table td:first-child {
        padding-top: 0;
    }
    
    .event-table td:last-child {
        padding-bottom: 15px;
    }
    
    .model-list li {
        font-size: 14px;
        margin-bottom: 3px;
    }
    
    .book-btn {
        padding: 12px 16px;
        font-size: 13px;
    }
    
    .location-title,
    .location-address {
        font-size: 14px;
    }
    
    .event-table td:nth-of-type(1) strong {
        font-size: 15px;
    }
    
    .event-time {
        font-size: 14px;
    }
}

.entry-content tr td{
    padding: 0 !important;
}

/* Add padding to content only, not headers */
.event-table td .cell-content {
    padding: 0 20px 20px 20px; /* or whatever padding you want */
}

/* Headers remain unaffected */
.event-table th {
    /* Your header styles here */
}

/* Event Section Description Styling */
.event-section-description {
    width: 80%;
    margin: 30px auto 20px auto;
    border-radius: 8px;
    font-family: 'IBM Plex Sans', Helvetica, Arial, Lucida, sans-serif;
    font-size: 16px;
    line-height: 1.6;
    color: #333;
    text-align: center;
}

.event-section-description h2 {
    font-size: 2.25rem;
    font-weight: 500;
    margin: 0;
    color: #333;
    font-family: 'IBM Plex Sans Condensed', Helvetica, Arial, Lucida, sans-serif;
    text-align: center;
}

.event-section-description p {
    margin: 0 0 15px 0;
}

.event-section-description p:last-child {
    margin-bottom: 0;
}

/* Responsive adjustments for descriptions */
@media (max-width: 768px) {
    .event-section-description {
        width: 90%;
        margin: 0 auto 20px auto;
        padding: 15px 15px 0 15px;
        font-size: 18px;
    }
    
    .event-section-description h2 {
        font-size: 2rem;
        margin: 0 0 15px 0;
    }
}

@media (max-width: 400px) {
    .event-section-description {
        width: 95%;
        padding: 12px 12px 0 12px;
        font-size: 16px;
        margin: 0 auto 15px auto;
    }
    
    .event-section-description h2 {
        font-size: 1.8rem;
        margin: 0 0 12px 0;
    }
}

.btn-tertiary-underline {
    text-decoration: underline;
    color: inherit;
    background: none;
    border: none;
    padding: 0;
    font: inherit;
    cursor: pointer;
}

.section-button-wrapper{
    display: flex;
    justify-content: center;
    align-items: center;
}