/*
Theme Name: DNH
Theme URI: https://dorsetnaturalheritage.com/
Template: hello-elementor
Author: E.G. Web Design
Author URI: https://elliottgreenman.com/
Version: 3.3.18
Updated: 2025-09-02 08:21:30
*/
/* Events table */
.events-table-wrap {
  width: 100%;
  overflow-x: auto;
}

a {text-underline-offset: 2px;}

h1 a, h2 a, h3 a, .elementor-icon-list-item a {text-decoration:none!important;}

.events-table {
  border-collapse: collapse;
  table-layout: fixed; /* respect colgroup widths */
  min-width: 1100px; /* room for 5 columns incl. controls */
  width: 100%;
}

.events-table th,
.events-table td {
  border-bottom: 1px solid #e5e7eb;
  padding: 0.75rem 0.75rem;
  vertical-align: top;
}

.events-table th {
  text-align: left;
  font-weight: 600;
}

.events-table tbody tr:nth-child(even) td {
  background: #fafafa;
}

.events-table .events-empty {
  text-align: center;
  color: #6b7280;
}

/* Contact cell links wrap nicely */
.events-table td a {
  word-break: break-word;
}

/* Calendar column */
.cal-cell {
  position: relative;
}

.cal-anchor {
  position: relative; /* anchor for absolute popover */
  display: inline-block;
}

.cal-anchor button.cal-btn {
  display: inline-block;
  padding: 0.1rem 0.1rem;
  border: none;
  border-radius: 0.5rem;
  background: none;
  cursor: pointer;
  line-height: 1;
  white-space: nowrap;
}

.cal-anchor button.cal-btn:hover {
  background: #f9fafb;
}

/* Absolute popover directly under the button */
.cal-menu {
  position: absolute;
  top: calc(100% + 6px); /* just under the button */
  left: 0;
  min-width: 220px;
  padding: 0.5rem;
  background: #ffffff;
  border: 1px solid #e5e7eb;
  border-radius: 0.5rem;
  box-shadow: 0 10px 20px rgba(0,0,0,0.08);
  z-index: 999;
  display: none; /* hidden by default */
}

.cal-menu[aria-hidden="false"] {
  display: block;
}

.cal-menu a {
  display: block;
  padding: 0.35rem 0.5rem;
  text-decoration: none;
}

.cal-menu a:hover {
  background: #f3f4f6;
  border-radius: 0.375rem;
}

/* Swipe hint (hidden on desktop, shown on tablet/mobile) */
.events-scroll-hint {
  display: none;
  font-size: 0.95rem;
  color: #374151;
  margin: 0 0 0.5rem 0;
  padding: 0.5rem 0.75rem;
  background: #f9fafb;
  border: 1px dashed #e5e7eb;
  border-radius: 0.5rem;
  width: fit-content;
  max-width: 100%;
}

/* Tablet & below */
@media (max-width: 1120px) {
  .events-scroll-hint {
    display: inline-block;
  }
}

/* Optional: subtle nudge animation to catch the eye */
@media (max-width: 1120px) {
  .events-scroll-hint {
    animation: hint-pulse 2.5s ease-in-out infinite;
  }
  @keyframes hint-pulse {
    0%, 100% { background-color: #f9fafb; }
    50%      { background-color: #ffffff; }
  }
}



/* Downloads grid */
.downloads-grid {
  display: grid;
  gap: 1.25rem;
}

/* 1 col mobile, 2 cols tablet, 3 cols desktop */
@media (min-width: 640px) {
  .downloads-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}
@media (min-width: 1024px) {
  .downloads-grid { grid-template-columns: repeat(3, minmax(0, 1fr)); }
}

.download-card {
  background: #fff;
  display: flex;
  flex-direction: column;
  height: 100%;
  /* removed border & radius */
  box-shadow: none; /* ensure flat style */
}

.download-card-thumb-wrap {
  display: block;
  aspect-ratio: 3 / 4;
  background: #f3f4f6;
  overflow: hidden;
}

.download-card-thumb {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

.download-card-fallback {
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 600;
  letter-spacing: 0.03em;
  color: #374151;
}

.download-card-body {
  padding: 0.875rem 0;
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
  flex: 1;
}

.download-card-title {
  margin: 0;
  font-size: 1.05rem;
  line-height: 1.35;
}

.download-card-desc {
  color: #4b5563;
  font-size: 0.95rem;
  line-height: 1.5;
  display: -webkit-box;
  -webkit-line-clamp: 3;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.download-card-cta {
  margin-top: auto;
}

.download-card-button {
  display: inline-block;
  padding: 0.55rem 0;
  border: none;           /* no border */
  background: transparent;/* flat minimal */
  text-decoration: underline;
  line-height: 1;
  cursor: pointer;
}

/* Empty state */
.downloads-empty {
  color: #6b7280;
  text-align: center;
}

/* Keep existing downloads grid/card styles ... */

/* CTA row holds Download + Share */
.download-card-cta {
  margin-top: auto;
  display: flex;
  align-items: center;
  gap: 0.75rem;
  flex-wrap: wrap;
}

/* Download button (unchanged visual style) */
.download-card-button {
  display: inline-block;
  padding: 0.55rem 0;
  border: none;
  background: transparent;
  text-decoration: underline;
  line-height: 1;
  cursor: pointer;
}

/* Share wrapper */
.download-card-share {
  position: relative;
  display: inline-block;
}

/* Share button */
.share-btn {
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
  padding: 0.4rem 0.1rem;
  border: none;
  background: var( --e-global-color-primary );
  cursor: pointer;
  line-height: 1;
}

.share-icon {
  display: inline-block;
}

/* Absolute popover directly under the share button */
.share-menu {
  position: absolute;
  top: calc(100% + 2px);
  left: 0;
  min-width: 180px;
  padding: 0.5rem;
  background: #ffffff;
  border: 1px solid #e5e7eb;
  box-shadow: 0 10px 20px rgba(0,0,0,0.08);
  z-index: 999;
  display: none;
}

.share-menu[aria-hidden="false"] {
  display: block;
}

.share-menu a {
  display: block;
  padding: 0.35rem 0.5rem;
  text-decoration: none;
}

.share-menu a:hover {
  background: #f3f4f6;
}