/*
Theme Name: Cultera Child
Theme URI: https://themnific.com/themes/cultera/
Description: Child theme for Cultera with custom styles.
Author: Label-Madeleine
Author URI: https://label-madeleine.ch
Template: cultera
Version: 1.1
*/

@import url("../cultera/style.css");  /* legacy support if needed */

/* === Global Button Design Tokens === */
:root {
  --lm-btn-font: 'Jost', sans-serif;
  --lm-btn-size: 0.8rem;
  --lm-btn-pad: 20px 30px;
  --lm-btn-radius: 5px;
  --lm-btn-lh: 1.1;
}

/* === Modern Event List Styling (Cultera-aligned) === */
.modern-event {
  display: flex;
  gap: 2rem;
  margin-bottom: 2rem;
  padding-bottom: 1rem;
  border-bottom: 1px solid #eee;
  align-items: flex-start;
}

.event-image img {
  border-radius: 0px;
  width: 150px;
  height: auto;
  object-fit: cover;
  max-height: 150px;
}

.event-info {
  max-width: 600px;
}

.event-title {
  font-family: 'Jost', sans-serif;
  font-size: 1.4rem;
  margin-bottom: 0.1rem;
  color: #111;
}

.event-date {
  font-family: 'Lora', serif;
  color: #29abe2;
  font-size: 0.95rem;
  margin-bottom: 0.1rem;
  display: block;
}

.event-time {
  font-family: 'Lora', serif;
  font-size: 0.9rem;
  color: #666;
  margin-bottom: 0.1rem;
}

.event-excerpt {
  font-family: 'Lora', serif;
  font-size: 1rem;
  color: #333;
  line-height: 1.6;
}

/* === Responsive (Mobile & Tablet) === */
@media (max-width: 768px) {
  .modern-event {
    flex-direction: column;
    align-items: center;
    text-align: center;
  }

  .event-image img {
    margin-bottom: 1rem;
  }

  .event-info {
    max-width: 100%;
  }

  .event-title {
    font-size: 1.2rem;
  }
}

/* === Fixed Global Button Styling (using tokens) === */
a.button, 
button, 
input[type="submit"], 
.wp-block-button__link, 
.elementor-button,
.elementor-button.elementor-size-sm, 
.elementor-button.elementor-size-md, 
.elementor-button.elementor-size-lg {
  background-color: #fc1370 !important;
  color: #ffffff !important;
  text-transform: uppercase !important;
  font-family: var(--lm-btn-font) !important;
  border-radius: var(--lm-btn-radius) !important;
  padding: var(--lm-btn-pad) !important;
  font-weight: 500 !important;
  font-size: var(--lm-btn-size) !important;
  letter-spacing: 1.5px !important;
  text-decoration: none !important;
  display: inline-block !important;
  border: none !important;
  line-height: var(--lm-btn-lh) !important;
  transition: all 0.3s ease !important;
}

/* === Hover State === */
a.button:hover, 
button:hover, 
input[type="submit"]:hover, 
.wp-block-button__link:hover, 
.elementor-button:hover {
  background-color: #29abe2 !important;
  color: #ffffff !important;
}

/* === Ensure Event Page Buttons Use Global Tokens === */
.single-event .em-button,
.single-event a.em-bookings-button,
.single-event .wpem-button,
.single-event .wp-block-button__link {
  font-family: var(--lm-btn-font) !important;
  font-size: var(--lm-btn-size) !important;
  padding: var(--lm-btn-pad) !important;
  border-radius: var(--lm-btn-radius) !important;
  line-height: var(--lm-btn-lh) !important;
  text-transform: uppercase !important;
}

/* SEND Button Style Corrections in the Contact Form */
.wpcf7 form .sixcol.last {
  width: 100% !important;
  display: block;
}
form.wpcf7-form input.wpcf7-submit {
  padding: var(--lm-btn-pad) !important;
  width: auto !important;
  max-width: 100% !important;
  box-sizing: border-box !important;
}

/* === Fix Events Pagination on LABEL-MADELEINE site === */
.em-pagination {
  text-align: center;
  margin: 2rem 0;
  font-family: 'Jost', sans-serif;
}

.em-pagination a,
.em-pagination span {
  display: inline-block;
  padding: 10px 16px;
  margin: 0 4px;
  border: 1px solid #fc1370;
  border-radius: 5px;
  font-size: 0.8rem;
  text-transform: uppercase;
  letter-spacing: 1px;
  text-decoration: none;
  transition: all 0.3s ease;
}

/* Default link (inactive) */
.em-pagination a {
  background-color: transparent;
  color: #fc1370;
}

/* Hover effect */
.em-pagination a:hover {
  background-color: #fc1370;
  color: #ffffff;
}

/* Active page (current) */
.em-pagination span {
  background-color: #fc1370;
  color: #ffffff;
  border: 1px solid #fc1370;
}

/* Back to Agenda button */
a.button.back-to-agenda {
  padding: var(--lm-btn-pad) !important;
  line-height: var(--lm-btn-lh) !important;
  display: inline-block !important;
  font-size: var(--lm-btn-size);
  margin: 20px auto 0 auto;
  text-align: center;
}

/* Prevent Elementor’s inner wrapper from re-adding padding */
.single-event .elementor .elementor-button .elementor-button-content-wrapper {
  padding: 0 !important;
}

/* Highlight active top menu item */
.nav .current-menu-item > a,
.nav .current_page_item > a,
.nav .current_page_parent > a {
  color: #fc1370 !important;
  font-weight: bold;
}

/* Prevent global button styling from affecting admin bar's search button */
#wpadminbar #adminbarsearch .adminbar-button {
  all: unset !important;
  display: none !important;
}

/* === Center Align the Search Button Text in Search Curtain Popup === */
#curtain .searchSubmit {
  display: flex !important;
  align-items: center !important;
  justify-content: center !important;
  font-family: var(--lm-btn-font) !important;
  font-weight: 500 !important;
  letter-spacing: 1.5px;
  text-transform: uppercase;
  font-size: var(--lm-btn-size);
  padding: var(--lm-btn-pad);
  background-color: #fc1370 !important;
  color: #ffffff !important;
  border-radius: var(--lm-btn-radius);
  border: none !important;
  transition: all 0.3s ease;
  cursor: pointer;
}

/* Hover Effect */
#curtain .searchSubmit:hover {
  background-color: #29abe2 !important;
}

/* Force visible link color and remove underline in Elementor text widgets */
.elementor-widget-text-editor a {
  color: #29abe2 !important;
  text-decoration: none !important;
}

/* Hover state: pink and still no underline */
.elementor-widget-text-editor a:hover {
  color: #fc1370 !important;
  text-decoration: none !important;
}

/* Style "Lire la suite" links in blog/articles previews */
.meta_more a {
  color: #29abe2 !important;
  text-decoration: none !important;
  font-weight: 500;
}

.meta_more a:hover {
  color: #fc1370 !important;
}

/* BEGIN SIDEBAR - ARTICLES LIST - STYLES */
.wp-block-latest-posts__list {
  list-style: none;
  margin-left: 0;
  padding-left: 0;
}

.wp-block-latest-posts__post-title {
  text-decoration: none;
  transition: color 0.3s ease;
}

.wp-block-latest-posts__post-title:hover {
  color: #fc1370 !important;
}
/* END SIDEBAR - ARTICLES LIST - STYLES */

/* HOME PAGE: Label Madeleine – 3-column event grid for Events Manager lists */
.lm-events-grid {
  display: grid;
  gap: 2rem;
  grid-template-columns: repeat(3, 1fr);
}
@media (max-width:1024px) {
  .lm-events-grid { grid-template-columns: repeat(2,1fr); }
}
@media (max-width:640px) {
  .lm-events-grid { grid-template-columns: 1fr; }
}

.lm-events-grid .item {
  background:#fff;
  border:1px solid #eee;
  border-radius:12px;
  padding:1rem;
  box-shadow:0 6px 18px rgba(0,0,0,.05);
}

.lm-events-grid .lm-event-thumb {
  display:block;
  width:100%;
  aspect-ratio:4/3;
  overflow:hidden;
  border-radius:10px;
  background:#f4f4f4;
}
.lm-events-grid .lm-event-thumb img {
  width:100%;
  height:100%;
  object-fit:cover;
  display:block;
}

.lm-events-grid .meta_full {
  font-size:14px;
  line-height:1.4;
  opacity:.9;
  margin:14px 0 6px;
}
.lm-events-grid .meta_full .divider { margin:0 10px; opacity:.4; font-weight:bold; }
.lm-events-grid .meta_cat a,
.lm-events-grid .meta_loc a,
.lm-events-grid .meta_type {
  text-decoration:none; opacity:.9;
}
.lm-events-grid .meta_cat a:hover,
.lm-events-grid .meta_loc a:hover { text-decoration:underline; }

.lm-events-grid .posttitle h2 {
  font-size:clamp(26px,2.2vw,30px);
  line-height:1.15;
  font-weight:700;
  letter-spacing:-.03em;
  margin:0 0 8px;
}
.lm-events-grid .posttitle h2 a { color:inherit; text-decoration:none; }
.lm-events-grid .posttitle h2 a:hover { text-decoration:underline; }

.lm-events-grid .extra_era {
  font-size:16px;
  line-height:1.65;
  margin:0 0 10px;
  color:#222;
}

.lm-events-grid .read_more a {
  font-size:14px;
  text-decoration:underline;
  text-underline-offset:2px;
}

.em-item, .em-item-info, .em-item-image, .em-item-meta, .em-item-actions, .em-icon {
  all: unset;
  display: revert;
}

/* === FINAL: make Elementor buttons on SINGLE EVENT pages match global button size === */

/* 1) Override Elementor Kit variables (whatever kit ID) only on event pages */
body.single-event :is(.elementor, [class*="elementor-kit"]) {
  --e-button-min-height: 0 !important;
  --e-button-padding-vertical: 20px !important;
  --e-button-padding-horizontal: 30px !important;
  --e-button-border-radius: 5px !important;
  --e-button-typography-font-size: 0.8rem !important;
}

/* 2) Force the actual anchor to use your global tokens */
body.single-event a.elementor-button.elementor-button-link {
  font-family: var(--lm-btn-font) !important;
  font-size: var(--lm-btn-size) !important;
  line-height: var(--lm-btn-lh) !important;
  padding: var(--lm-btn-pad) !important;
  border-radius: var(--lm-btn-radius) !important;
  text-transform: uppercase !important;
  letter-spacing: 1.5px !important;
  font-weight: 500 !important;
  min-height: 0 !important;
  height: auto !important;
  box-sizing: border-box !important;
  transform: none !important;
}

/* 3) Remove extra inner padding/margins that inflate height */
body.single-event a.elementor-button .elementor-button-content-wrapper,
body.single-event a.elementor-button .elementor-button-text,
body.single-event a.elementor-button .elementor-button-icon {
  padding: 0 !important;
  margin: 0 !important;
}

/* 4) Neutralize “size” modifiers Elementor may add */
body.single-event a.elementor-button.elementor-size-sm,
body.single-event a.elementor-button.elementor-size-md,
body.single-event a.elementor-button.elementor-size-lg {
  font-size: var(--lm-btn-size) !important;
  padding: var(--lm-btn-pad) !important;
  min-height: 0 !important;
}