/**
 * Theme Name:     TransFresh
 * Author:         TransFresh: Freshness Sealed &amp; Delivered
 * Template:       twentytwentyfive
 * Text Domain:	   transfresh
 * Description:    A WordPress theme for TransFresh Corporation, built on WordPress 2025.
 * Theme URI:      http://TransFresh.com
 * Author URI:     http://TransFresh.com
 * Version:        1.0
 */

/* Reverse Button Hover States
   ========================================================================== */

/* Fill Reverse: swap to light background, dark text on hover */
.wp-block-button.is-style-fill-reverse .wp-block-button__link:hover,
.wp-block-button.is-style-fill-reverse .wp-block-button__link:focus {
    background-color: var(--wp--preset--color--base);
    color: var(--wp--preset--color--contrast);
}

/* Outline Reverse: fill with light background, dark text on hover */
.wp-block-button.is-style-outline-reverse .wp-block-button__link:hover,
.wp-block-button.is-style-outline-reverse .wp-block-button__link:focus {
    background-color: var(--wp--preset--color--base);
    color: var(--wp--preset--color--contrast);
}

/* SVG Curved Underline for Highlighted Text
   ========================================================================== */

/*
 * Usage: Add class "tf-underline-header" to any heading block.
 * Then use WordPress's native Highlight format on text within the heading.
 * - Background color controls the underline color
 * - Text color controls the text color
 * - If no background color specified, defaults to #7CBF4B
 */

.tf-underline-header mark {
    background-color: transparent !important;
    background-image: none !important;
    background: transparent !important;
    position: relative;
    display: inline-block;
}

.tf-underline-header mark::after {
    content: '';
    position: absolute;
    bottom: -0.2em;
    left: 0;
    width: 100%;
    height: 0.4em;
    background-color: var(--tf-underline-color, #7CBF4B);
    -webkit-mask: url("data:image/svg+xml,%3Csvg xmlns=%27http://www.w3.org/2000/svg%27 viewBox=%270 0 517.5 40.8%27 preserveAspectRatio=%27none%27%3E%3Cpath d=%27M1.9,28.9c0,0,238.5-38,514,0%27 fill=%27none%27 stroke=%27white%27 stroke-width=%2724%27/%3E%3C/svg%3E") no-repeat center / 100% 100%;
    mask: url("data:image/svg+xml,%3Csvg xmlns=%27http://www.w3.org/2000/svg%27 viewBox=%270 0 517.5 40.8%27 preserveAspectRatio=%27none%27%3E%3Cpath d=%27M1.9,28.9c0,0,238.5-38,514,0%27 fill=%27none%27 stroke=%27white%27 stroke-width=%2724%27/%3E%3C/svg%3E") no-repeat center / 100% 100%;
    z-index: 1;
}


/* ============================================
   Cover as Post Link - Clickable Card Pattern
   ============================================ */

/* Positioning context */
.cover-as-post-link {
  position: relative;
}

/* Hit area - covers entire block */
.cover-as-post-link > .cover-hit-area {
  position: absolute;
  inset: 0;
  z-index: 1;
  text-decoration: none;
  color: inherit;
}

/* Pointer cursor on the whole card */
.cover-as-post-link:hover {
  cursor: pointer;
}

/* Focus outline for keyboard users */
.cover-as-post-link > .cover-hit-area:focus-visible {
  outline: 2px solid currentColor;
  outline-offset: 4px;
}

/* Background and image don't need to capture clicks */
.cover-as-post-link > .wp-block-cover__background,
.cover-as-post-link > .wp-block-cover__image-background {
  pointer-events: none;
}

/* Inner container - allow clicks to pass through to hit-area */
.cover-as-post-link .wp-block-cover__inner-container {
  pointer-events: none;
}

/* Category pill - MUST be positioned and above hit-area to intercept clicks */
.cover-as-post-link .wp-block-post-terms,
.cover-as-post-link .category-pill-cover {
  position: relative;
  z-index: 2;
  pointer-events: auto;
}

.cover-as-post-link .wp-block-post-terms a,
.cover-as-post-link .category-pill-cover a {
  position: relative;
  z-index: 2;
  pointer-events: auto;
  /* display: inline-block; — REMOVED */
}

/* Screen-reader text helper */
.screen-reader-text {
  position: absolute !important;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}