/* ============================================================
   Amelia Future Events — Card styles
   ============================================================ */

.afe-wrapper {
  --afe-card-bg: #fff;
  --afe-text: #1e2430;
  --afe-muted: #8a93a0;
  --afe-price: #127d6a;
  --afe-btn: #128a76;
  --afe-btn-hover: #0e6f5f;
  --afe-radius: 14px;
  --afe-shadow: 0 1px 2px rgba(16, 24, 40, .04), 0 4px 12px rgba(16, 24, 40, .06);

  display: flex;
  flex-direction: column;
  gap: 16px;
  box-sizing: border-box;
}

.afe-wrapper *,
.afe-wrapper *::before,
.afe-wrapper *::after {
  box-sizing: border-box;
}

/* ---- Card shell ---- */
.afe-card {
  position: relative;
  display: grid;
  grid-template-columns: 90px 120px 1fr auto;
  align-items: center;
  gap: 20px;
  background: var(--afe-card-bg);
  border-radius: var(--afe-radius);
  box-shadow: var(--afe-shadow);
  padding: 18px 22px 18px 26px;
  overflow: hidden;
  transition: box-shadow .2s ease, transform .2s ease;
}

.afe-card:hover {
  box-shadow: 0 6px 20px rgba(16, 24, 40, .10);
  transform: translateY(-1px);
}

@media (prefers-reduced-motion: reduce) {

  .afe-card,
  .afe-card:hover {
    transition: none;
    transform: none;
  }
}

/* Colored left accent */
.afe-card::before {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  bottom: 0;
  width: 8px;
  background: var(--afe-accent, #128a76);
}

/* ---- Date block ---- */
.afe-date {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  line-height: 1.15;
  padding-left: 6px;
}

.afe-date-day {
  font-size: 30px;
  font-weight: 700;
  color: var(--afe-text);
  letter-spacing: -.5px;
}

.afe-date-month {
  font-size: 14px;
  color: var(--afe-muted);
  margin-top: 2px;
}

.afe-date-time {
  font-size: 14px;
  color: var(--afe-muted);
  margin-top: 4px;
}

/* ---- Image ---- */
.afe-thumb {
  width: 120px;
  height: 100px;
  border-radius: 10px;
  overflow: hidden;
  background: #eef1f5;
  position: relative;
  flex-shrink: 0;
}

.afe-wrapper .afe-thumb img {
  position: absolute;
  inset: 0;
  width: 100% !important;
  height: 100% !important;
  max-width: none !important;
  max-height: none !important;
  margin: 0 !important;
  padding: 0 !important;
  border: 0 !important;
  border-radius: 0 !important;
  object-fit: cover;
  object-position: center;
  display: block;
}

.afe-thumb-placeholder {
  width: 100%;
  height: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
  color: #fff;
  font-weight: 700;
  font-size: 26px;
}

/* ---- Body ---- */
.afe-body {
  display: flex;
  flex-direction: column;
  gap: 6px;
  min-width: 0;
}

.afe-title {
  margin: 0;
  font-size: 20px;
  font-weight: 700;
  color: var(--afe-text);
  line-height: 1.25;
}

.afe-title a {
  color: inherit;
  text-decoration: none;
}

.afe-title a:hover {
  text-decoration: underline;
}

.afe-sub {
  font-size: 15px;
  color: var(--afe-muted);
  line-height: 1.35;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.afe-slots {
  font-size: 16px;
  color: var(--afe-text);
  font-weight: 600;
  margin-top: 4px;
}

/* ---- Right column ---- */
.afe-right {
  display: flex;
  flex-direction: column;
  align-items: flex-end;
  gap: 12px;
  min-width: 130px;
}

.afe-price {
  font-size: 20px;
  font-weight: 700;
  color: var(--afe-price);
  white-space: nowrap;
}

.afe-price--free {
  color: var(--afe-price);
}

.afe-btn {
  display: inline-block;
  padding: 12px 28px;
  background: var(--afe-btn);
  color: #fff !important;
  text-decoration: none !important;
  font-weight: 700;
  font-size: 15px;
  border-radius: 999px;
  transition: background-color .15s ease;
  border: none;
  cursor: pointer;
  text-align: center;
  white-space: nowrap;
}

.afe-btn:hover,
.afe-btn:focus-visible {
  background: var(--afe-btn-hover);
  color: #fff;
}

.afe-btn--disabled {
  background: #c7ccd4;
  cursor: not-allowed;
  pointer-events: none;
}

.afe-empty {
  padding: 24px;
  text-align: center;
  color: var(--afe-muted);
  background: #fff;
  border-radius: var(--afe-radius);
  box-shadow: var(--afe-shadow);
}

/* ---- Responsive ---- */
@media (max-width: 720px) {
  .afe-card {
    grid-template-columns: 70px 1fr;
    grid-template-areas:
      "date body"
      "thumb body"
      "right right";
    gap: 14px;
    padding: 16px 16px 16px 22px;
  }

  .afe-date {
    grid-area: date;
  }

  .afe-thumb {
    grid-area: thumb;
    width: 70px;
    height: 60px;
  }

  .afe-body {
    grid-area: body;
  }

  .afe-right {
    grid-area: right;
    flex-direction: row;
    justify-content: space-between;
    align-items: center;
    width: 100%;
    margin-top: 4px;
    border-top: 1px solid #eef1f5;
    padding-top: 12px;
  }

  .afe-date-day {
    font-size: 24px;
  }

  .afe-title {
    font-size: 17px;
  }
}

@media (max-width: 420px) {
  .afe-card {
    grid-template-columns: 1fr;
    grid-template-areas: "date" "thumb" "body" "right";
  }

  .afe-date {
    flex-direction: row;
    gap: 8px;
    align-items: baseline;
  }

  .afe-date-month,
  .afe-date-time {
    margin-top: 0;
  }

  .afe-thumb {
    width: 100%;
    height: 160px;
  }
}
