/**
 * letsrocc – Global Custom Styles
 * Supplements theme.json for rules it cannot handle
 */

/* ─── SECTION SPACING ─── */
.entry-content > *,
.wp-block-group > * {
  margin-block-start: 0;
  margin-block-end: 0;
}

.entry-content > * + * {
  margin-block-start: var(--wp--preset--spacing--30);
}

.entry-content > .wp-block-group + .wp-block-group,
.entry-content > .wp-block-separator + * {
  margin-block-start: var(--wp--preset--spacing--50);
}

/* ─── BODY TEXT MAX WIDTH (readability) ─── */
.entry-content > p,
.entry-content > ul,
.entry-content > ol {
  max-width: 680px;
}

/* ─── FOCUS STATES (WCAG) ─── */
a:focus-visible,
button:focus-visible,
.wp-block-button__link:focus-visible,
input:focus-visible,
textarea:focus-visible,
select:focus-visible {
  outline: 2px solid var(--wp--preset--color--primary);
  outline-offset: 2px;
}

/* ─── BUTTON BASE + TRANSITIONS ─── */
.wp-block-button__link {
  transition: background-color 0.2s ease, color 0.2s ease, transform 0.2s ease, opacity 0.2s ease;
}

/* ─── BUTTON HOVER ─── */
.wp-block-button__link:hover {
  opacity: 0.85;
  transform: translateY(-1px);
}

/* ─── LINK BASE + TRANSITIONS ─── */
a {
  transition: color 0.2s ease;
}

/* ─── LINK UNDERLINE ANIMATION ─── */
.entry-content a:not(.wp-block-button__link) {
  text-decoration: underline;
  text-decoration-color: transparent;
  text-underline-offset: 0.15em;
  transition: color 0.2s ease, text-decoration-color 0.2s ease;
}

.entry-content a:not(.wp-block-button__link):hover {
  text-decoration-color: currentColor;
}

/* ─── CARD HOVER (founder cards, insight cards) ─── */
.wp-block-column[style*="border"] {
  transition: box-shadow 0.2s ease, transform 0.2s ease;
}

.wp-block-column[style*="border"]:hover {
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.08);
  transform: translateY(-2px);
}

/* ─── NAVIGATION UPPERCASE TRACKING ─── */
.wp-block-navigation .wp-block-navigation-item a {
  text-transform: uppercase;
  letter-spacing: 0.03em;
  font-weight: 600;
}

/* ─── NAV LINK HOVER ─── */
.wp-block-navigation .wp-block-navigation-item a:hover {
  color: var(--wp--preset--color--secondary);
}

/* ─── SEPARATOR / ACCENT LINE ─── */
.wp-block-separator {
  border: none;
  height: 2px;
  background-color: var(--wp--preset--color--primary);
  opacity: 1;
}

/* ─── QUOTE BLOCK ─── */
.wp-block-quote {
  border-left: 3px solid var(--wp--preset--color--primary);
  padding-left: var(--wp--preset--spacing--30);
  font-weight: 600;
  font-style: normal;
}

/* ─── CORAL CALLOUT (use "highlight" text colour in editor) ─── */
.has-secondary-color {
  color: var(--wp--preset--color--secondary);
  font-weight: 600;
}

/* ─── IMAGE DEFAULTS ─── */
.entry-content img {
  height: auto;
  max-width: 100%;
}

/* ─── SMOOTH SCROLL ─── */
html {
  scroll-behavior: smooth;
}

/* ─── SELECTION COLOUR ─── */
::selection {
  background-color: var(--wp--preset--color--primary);
  color: var(--wp--preset--color--background);
}

/* ─── MOBILE ADJUSTMENTS ─── */
@media (max-width: 768px) {
  .entry-content > .wp-block-group + .wp-block-group {
    margin-block-start: var(--wp--preset--spacing--40);
  }
}

/* ─── REDUCED MOTION (WCAG) ─── */
@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
    scroll-behavior: auto !important;
  }
}