/**
 * ASANAM — Events Manager brand styling (archive + single)
 * Matches the homepage: EB Garamond headings, Roboto Flex body, gold accents, cards.
 * Loaded only on event / events-page views (see includes/eventsStyle.php).
 */

.em-view-container {
    --asa-gold: #ffb43a;
    --asa-gold-d: #ffab14;
    --asa-terra: #cd8973;
    --asa-sage: #dece87;
    --asa-cream: #f4f0ed;
    --asa-cream2: #f3f0ed;
    --asa-dark: #24211f;
    --asa-gray: #727272;
    --asa-line: #e0dcd3;
    font-family: 'Roboto Flex', -apple-system, sans-serif;
    color: var(--asa-gray);
    max-width: 1180px;
    margin: 0 auto;
    padding: 0 20px;
}

/* ---- Page heading (events archive / single title) ---- */
.single-event .entry-title,
.page-id-90132 .entry-title,
.post-type-archive-event .entry-title {
    font-family: 'EB Garamond', Georgia, serif !important;
    color: var(--asa-dark) !important;
    font-weight: 500;
    letter-spacing: -0.01em;
}

/* ---- Headings inside EM ---- */
.em-view-container h1,
.em-view-container h2,
.em-view-container h3,
.em-item-title,
.em-event .em-item-title a,
.em-item-header h1,
.em-item-header h2 {
    font-family: 'EB Garamond', Georgia, serif;
    color: var(--asa-dark);
    font-weight: 600;
}

.em-view-container a { color: var(--asa-terra); text-decoration: none; }
.em-view-container a:hover { color: var(--asa-gold-d); }

/* ---- Icons → gold ---- */
.em-view-container .em-icon:before,
.em-view-container [class*="em-icon-"]:before { color: var(--asa-gold); }

/* ================= EVENT LIST (archive) ================= */
.em-events-list.em-list,
.em-events-list {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(320px, 1fr));
    gap: 30px;
    list-style: none;
    margin: 10px 0 0;
    padding: 0;
}

.em-events-list .em-item.em-event,
.em-events-list > li,
.em-events-list .em-item {
    background: #fff;
    border-radius: 18px;
    box-shadow: 0 18px 45px -8px rgba(36, 33, 31, 0.10);
    overflow: hidden;
    list-style: none;
    margin: 0;
    display: flex;
    flex-direction: column;
    transition: transform .3s ease, box-shadow .3s ease;
    border: 1px solid rgba(36,33,31,0.04);
}
.em-events-list .em-item.em-event:hover,
.em-events-list > li:hover {
    transform: translateY(-5px);
    box-shadow: 0 30px 60px -10px rgba(36, 33, 31, 0.18);
}

/* card image */
.em-events-list .em-item img,
.em-events-list .em-item-image img {
    width: 100%;
    height: 210px;
    object-fit: cover;
    display: block;
}

/* card body spacing */
.em-events-list .em-item-header,
.em-events-list .em-item-content,
.em-events-list .em-item-meta {
    padding: 0 26px;
}
.em-events-list .em-item-header { padding-top: 24px; }
.em-events-list .em-item > *:last-child { padding-bottom: 26px; }

.em-events-list .em-item-title,
.em-events-list .em-item .em-item-title a {
    font-size: 24px;
    line-height: 1.2;
    display: block;
    margin: 0 0 6px;
    color: var(--asa-dark);
}

/* date/time/price meta */
.em-item-meta,
.em-item-meta-column { display: flex; flex-direction: column; gap: 8px; }
.em-item-meta-line {
    display: flex;
    align-items: center;
    gap: 10px;
    font-size: 15px;
    color: var(--asa-gray);
    margin: 0;
}
.em-item-meta-line.em-event-prices,
.em-event-prices { color: var(--asa-gold-d); font-weight: 600; }

/* ================= SINGLE EVENT ================= */
.em-item-single {
    background: transparent;
    padding: 0;
}
.em-item-single .em-item-header {
    margin-bottom: 26px;
    padding-bottom: 22px;
    border-bottom: 1px solid var(--asa-line);
}
.em-item-single .em-item-title,
.em-item-single .em-item-header h1 {
    font-size: 46px;
    line-height: 1.1;
    margin: 0 0 14px;
}
.em-item-single .em-item-image img,
.single-event .wp-post-image {
    width: 100%;
    max-height: 460px;
    object-fit: cover;
    border-radius: 20px;
    box-shadow: 0 26px 60px -12px rgba(36, 33, 31, 0.20);
    margin-bottom: 30px;
}

/* meta chips row on single */
.em-item-single .em-item-meta { flex-direction: row; flex-wrap: wrap; gap: 14px; margin-bottom: 8px; }
.em-item-single .em-item-meta-line {
    background: var(--asa-cream);
    border-radius: 30px;
    padding: 10px 18px;
    font-size: 15px;
    font-weight: 500;
    color: var(--asa-dark);
}

.em-event-content { font-size: 17px; line-height: 1.75; color: #4f4b47; }
.em-event-content h2, .em-event-content h3 { margin-top: 1.4em; }

/* ---- Booking / calendar buttons ---- */
.em button,
.em .button,
.em input[type="submit"],
.em-booking-form input[type="submit"],
.em-event-booking-form button,
.em-add-to-calendar-tooltip,
.em .em-search-submit,
.em button.button-primary,
.em-view-container .button-primary,
.em-view-container .em-button {
    background: var(--asa-gold) !important;
    color: var(--asa-dark) !important;
    border: 0 !important;
    border-radius: 40px !important;
    padding: 13px 30px !important;
    font-family: 'Roboto Flex', sans-serif !important;
    font-weight: 600 !important;
    font-size: 15px !important;
    cursor: pointer;
    box-shadow: 0 12px 26px -8px rgba(255, 180, 58, 0.5);
    transition: background .25s ease, transform .2s ease;
}
.em button:hover,
.em input[type="submit"]:hover,
.em-add-to-calendar-tooltip:hover,
.em-event-booking-form button:hover { background: var(--asa-gold-d) !important; transform: translateY(-2px); }

/* form fields */
.em input[type="text"], .em input[type="email"], .em input[type="tel"],
.em input[type="number"], .em select, .em textarea,
.em-events-search input, .em-events-search select {
    border: 1px solid var(--asa-line) !important;
    border-radius: 10px !important;
    padding: 11px 14px !important;
    font-family: 'Roboto Flex', sans-serif !important;
    color: var(--asa-dark);
    background: #fff;
}
.em input:focus, .em select:focus, .em textarea:focus,
.em-events-search input:focus { outline: none; border-color: var(--asa-gold) !important; box-shadow: 0 0 0 3px rgba(255,180,58,0.18) !important; }

/* ---- Search / filter bar ---- */
.em-events-search {
    background: var(--asa-cream2);
    border-radius: 18px;
    padding: 22px 24px !important;
    margin-bottom: 34px;
    border: 1px solid rgba(36,33,31,0.05);
}

/* booking table */
.em-booking-form table, .em-bookings table { border-collapse: collapse; width: 100%; }
.em-booking-form th, .em-bookings th { color: var(--asa-dark); font-family: 'EB Garamond', serif; }
.em-booking-form td, .em-bookings td { border-color: var(--asa-line); }

/* ---- Override Divi blue (#2EA3F2) on EM links & submit ---- */
.em-view-container .em-item-title a,
.em-events-list .em-item .em-item-title a,
.em-events-list .em-item h2 a,
.em-events-list .em-item h3 a,
.em-item-single .em-item-title a { color: var(--asa-dark) !important; }
.em-events-list .em-item .em-item-title a:hover,
.em-item-single .em-item-title a:hover { color: var(--asa-gold-d) !important; }

.em-view-container .em-search-submit,
.em-view-container button.em-search-submit,
.em-view-container .em-search-submit.button-primary {
    background: var(--asa-gold) !important;
    background-image: none !important;
    color: var(--asa-dark) !important;
    text-shadow: none !important;
    box-shadow: 0 12px 26px -8px rgba(255, 180, 58, 0.5) !important;
}
.em-view-container .em-search-submit:hover { background: var(--asa-gold-d) !important; }

/* ================= SINGLE EVENT HERO (title + date over image) ================= */
/* full-bleed hero, matched to the homepage hero */
.asa-event-hero {
    position: relative;
    width: 100vw;
    left: 50%;
    right: 50%;
    margin-left: -50vw;
    margin-right: -50vw;
    min-height: 66vh;
    background: #24211f;
    background-size: cover;
    background-position: center;
    display: flex;
    align-items: flex-end;
    overflow: hidden;
}
.asa-event-hero.has-img::before {
    content: "";
    position: absolute;
    inset: 0;
    background: linear-gradient(105deg, rgba(36,33,31,0.90) 0%, rgba(36,33,31,0.48) 55%, rgba(36,33,31,0.80) 100%);
}
.asa-event-hero__inner {
    position: relative;
    z-index: 2;
    width: 100%;
    max-width: 1180px;
    margin: 0 auto;
    padding: 0 40px 11vh;
}
.asa-event-hero__eyebrow {
    display: inline-block;
    font-family: 'Roboto Flex', sans-serif;
    font-weight: 600;
    letter-spacing: 3px;
    font-size: 14px;
    text-transform: uppercase;
    color: #ffb43a;
    margin-bottom: 16px;
}
.asa-event-hero__title {
    font-family: 'EB Garamond', Georgia, serif !important;
    color: #ffffff !important;
    font-size: clamp(40px, 6vw, 92px);
    line-height: 0.98;
    font-weight: 500;
    letter-spacing: -0.01em;
    margin: 0 0 16px;
    max-width: 900px;
    text-shadow: 0 2px 24px rgba(0,0,0,0.28);
}
.asa-event-hero__date {
    font-family: 'Roboto Flex', sans-serif;
    color: rgba(255, 255, 255, 0.92);
    font-size: 19px;
    margin: 0;
}

/* content below the hero breathes like a homepage section */
.em-item-single { padding-top: 4px; }
.em-view-container { padding-top: 70px; padding-bottom: 90px; }
/* the hero shows the image now — hide EM's duplicate featured image on single */
.em-item-single .em-item-image { display: none; }

/* header over the event hero — match the homepage (logo hidden + white burger; solid on scroll) */
.single-event #main-header #logo { transition: opacity .35s ease; }
.single-event #main-header:not(.et-fixed-header) #logo { opacity: 0; visibility: hidden; }
.single-event #main-header:not(.et-fixed-header) .mobile_menu_bar:before { color: #ffffff !important; }
.single-event #main-header.et-fixed-header { background-color: #ffffff !important; box-shadow: 0 1px 14px rgba(36,33,31,0.08); }
.single-event #main-header.et-fixed-header .mobile_menu_bar:before { color: #24211f !important; }

/* responsive */
@media (max-width: 782px) {
    .em-events-list { grid-template-columns: 1fr; gap: 22px; }
    .em-item-single .em-item-title,
    .em-item-single .em-item-header h1 { font-size: 34px; }
    .asa-event-hero__inner { padding: 0 24px 8vh; }
    .asa-event-hero { min-height: 54vh; }
    .em-view-container { padding-top: 48px; padding-bottom: 64px; }
}
