/**
 * futbol-mesa CSS — partial 1/6: 01-tokens-header. Contiguous slice of the former style.css.
 * Tokens, base typography, header/contact bar, primary nav (desktop), beginner banner, single-product trust + sticky bar, content column, header desktop media.
 * Load order is load-bearing (LRN-020/TSK-034): enqueued 01->06 in functions.php,
 * before storefront-woocommerce. Do NOT reorder or move rules between partials. @package futbol-mesa
 */
/* Claude Design color palette (TSK-020). */
:root {
  --color-terracotta: #A84830;
  --color-terracotta-hover: #7E3422;
  --color-pitch-green: #1F6B4A;
  --color-ink: #181818;
  --color-cream: #F7F3EC;
  --color-night: #15110E;
  --color-footer-text: #C9C1B6;
  --color-hairline: #E2DCD3;

  /* Extended neutrals / accents (mirrored from the design tokens.css). */
  --color-muted: #606060;             /* body labels, captions, counts */
  --color-footer-muted: #9A9087;      /* footer links / tagline */
  --color-footer-faint: #948B7E;      /* footer copyright; a11y: was #7E766C at 4.19:1 on --color-night, fails AA (TSK-040) */
  --color-accent-green: #6FBF94;      /* WhatsApp accent */
  --color-accent-green-hover: #8FD6AD;
  --color-bar-text: #EDE7DC;          /* utility-bar text on ink */
  --color-body: #303030;              /* body copy (design-system layer of tokens.css) */
  --color-hairline-faint: #F1EBE1;    /* faint dividers (design-system layer of tokens.css) */

  /* Type tokens (single source of truth, mirrored into the design tokens.css).
     Archivo = headings / UI labels, Public Sans = body. Existing font-family
     literals can migrate to these vars incrementally. */
  --font-heading: 'Archivo', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
  --font-body: 'Public Sans', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;

  /* Radius scale (mirrors the design-system layer of the design tokens.css). */
  --radius-sm: 8px;
  --radius-button: 10px;
  --radius-md: 12px;
  --radius-lg: 14px;
  --radius-card: 16px;
  --radius-panel: 18px;
  --radius-pill: 999px;

  /* Shadows (mirror the design-system layer of the design tokens.css). */
  --shadow-card: 0 18px 30px -18px rgba(24, 17, 14, 0.28);
  --shadow-menu: 0 24px 40px -20px rgba(24, 17, 14, 0.25);
  --shadow-figure: 0 28px 50px -28px rgba(24, 17, 14, 0.32);
  --shadow-figure-sm: 0 20px 36px -22px rgba(24, 17, 14, 0.30);

  /* Content column (single source of truth, per the Claude Design mockup). Every
     band — header, footer, breadcrumb, sidebar, page content — rides this width
     via .col-full. Full-bleed bands recover the column edge with --content-edge:
     padding-inline: max(24px, var(--content-edge)). */
  --content-max: 1280px;
  --content-gutter: clamp(16px, 4vw, 48px);
  --content-edge: calc(50vw - var(--content-max) / 2 + var(--content-gutter));
}

/* Typography overrides: Archivo (headings), Public Sans (body). */
body,
input,
button,
select,
textarea {
  font-family: 'Public Sans', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
}

h1,
h2,
h3,
h4,
h5,
h6 {
  font-family: 'Archivo', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
  font-weight: 700;
  letter-spacing: -0.02em;
}

h1,
h2,
h3 {
  font-weight: 900 !important; /* beat WC-blocks/Storefront weight rules of higher specificity */
}

.wp-block-woocommerce-featured-category {
  min-height: 400px !important; /* WP inline styles override */
}

.no-margin-bottom {
  margin-bottom: 0 !important; /* Utility: must override all cascade levels */
}

.site-header {
  border-bottom: 0;
  margin-bottom: 48px;
}

.site-header .site-branding,
.site-header .site-search {
  margin-bottom: 0;
}

.site-header .site-search {
  margin-right: 16px;
}

.site-header-cart .amount {
  color: var(--color-terracotta);
  font-weight: bold;
}

#site-header-cart .cart-contents {
  background-color: var(--color-ink);
  color: #fff;
  padding: 8px 16px;
}

#site-header-cart .cart-contents:hover {
  color: #fff;
}

.futbol_mesa_contact {
  background-color: var(--color-ink);
  color: var(--color-bar-text); /* utility-bar text, per the design */
  /* Stack above Storefront's z-index:999 header so the Bizum tooltip isn't
     painted over by it. */
  position: relative;
  z-index: 1000;
}

.futbol_mesa_contact svg {
  display: inline-block;
  width: 16px;
  height: 16px;
  margin-right: 0;
}

/* Left side: Bizum payment note with a hover tooltip. */
.futbol_mesa_contact .claim {
  display: flex;
  align-items: center;
  gap: 8px;
}

.futbol_mesa_contact .bizum-note {
  position: relative;
  color: #fff;
  font-weight: 700;
  cursor: help;
}

.futbol_mesa_contact .bizum-note sup {
  font-size: 0.7em;
}

.futbol_mesa_contact .bizum-note::after {
  content: attr(data-tip);
  position: absolute;
  top: 100%;
  left: 0;
  transform: translateY(6px);
  z-index: 50;
  padding: 4px 8px;
  border-radius: 6px;
  background: #fff;
  color: var(--color-ink);
  font-weight: 600;
  letter-spacing: 0;
  white-space: nowrap;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.12s ease;
}

.futbol_mesa_contact .bizum-note:hover::after,
.futbol_mesa_contact .bizum-note:focus::after {
  opacity: 1;
}

/* Icon and value share a flex line so the icon is vertically centered against
   the text instead of sitting on its baseline. */
.futbol_mesa_contact .contact-link {
  display: inline-flex;
  align-items: center;
  gap: 8px;
}

.futbol_mesa_contact .content-area {
  padding-top: 7px;
  padding-bottom: 7px;
  margin-bottom: 0;
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  width: 100%;
  /* Set the smaller utility-bar type here, not on .futbol_mesa_contact, so the
     em-based .col-full max-width/padding still resolve at the root font size and
     the bar aligns with the header instead of shrinking. */
  font-size: 0.78rem;
  letter-spacing: 0.02em;
}

.futbol_mesa_contact .main {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  column-gap: 22px;
  row-gap: 8px;
}

.futbol_mesa_contact .main p {
  display: flex;
  align-items: center;
}

.futbol_mesa_contact .main a {
  margin-left: 4px;
}

.futbol_mesa_contact p {
  margin-bottom: 0;
}

.futbol_mesa_contact a {
  color: #fff;
}

/* Email in cream, WhatsApp in green, per the design. */
.futbol_mesa_contact .contact-link--mail {
  color: var(--color-bar-text);
}

.futbol_mesa_contact .contact-link--mail:hover {
  color: #fff;
}

.futbol_mesa_contact .contact-link--wa {
  color: var(--color-accent-green);
  font-weight: 600;
}

.futbol_mesa_contact .contact-link--wa:hover {
  color: var(--color-accent-green-hover);
}

#site-navigation.main-navigation {
  width: 100%;
  margin-right: 0;
  float: none;
  margin-top: 32px;
}

#site-navigation-menu-toggle {
  display: none;
}

.mega-menu-link[href="#"] {
  cursor: default;
}

.mega-menu-description {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border-width: 0;
}

/* Drop the header's 48px bottom margin on shop/archive so the breadcrumb sits
   ~28px below the nav (its own top padding) — exactly like the Tienda mockup,
   where the breadcrumb follows the header with no extra band of space. */
body.woocommerce-shop .site-header,
body.archive.woocommerce-page .site-header,
body.woocommerce-cart .site-header {
  margin-bottom: 0;
}

/* Breadcrumb band rides the site-wide 1280 column (the base .col-full), but its
   own vertical rhythm differs: top padding sits the crumbs ~28px below the nav,
   bottom padding 0 keeps the gap to the title tight — the title's own top padding
   supplies that spacing. The inner .col-full is flattened so the wrapper alone
   controls width/centering. */
body.woocommerce-shop .storefront-breadcrumb,
body.archive.woocommerce-page .storefront-breadcrumb,
body.woocommerce-cart .storefront-breadcrumb {
  max-width: 1280px;
  margin: 0 auto;
  padding: clamp(20px, 3vw, 28px) clamp(16px, 4vw, 48px) 0;
}

body.woocommerce-shop .storefront-breadcrumb .col-full,
body.archive.woocommerce-page .storefront-breadcrumb .col-full,
body.woocommerce-cart .storefront-breadcrumb .col-full {
  max-width: none;
  margin: 0;
  padding: 0;
}

.onsale {
  position: absolute;
  top: 8px;
  right: 8px;
  color: #fff;
  background-color: var(--color-terracotta);
}

/* Beginners-guide banner: full-bleed pitch-green band with intro copy + CTAs.
   Breaks out of the max-width content column to span the viewport; --content-edge
   re-aligns the inner content with the column's gutter edge (max(24px, …) keeps a
   floor on very narrow viewports). */
.rules-banner {
  width: 100vw;
  max-width: 100vw;
  margin-left: calc(50% - 50vw);
  margin-right: calc(50% - 50vw);
  box-sizing: border-box;
  background-color: var(--color-pitch-green);
  color: #fff;
  align-items: center;
  gap: clamp(24px, 5vw, 64px);
  padding: clamp(48px, 7vw, 96px) max(24px, var(--content-edge));
}

/* Use stable author class instead of WP-generated block hash (TSK-014). */
.rules-banner .wp-block-column {
  margin-bottom: 0 !important; /* WP block inline styles override */
}

.rules-banner__eyebrow {
  margin: 0 0 16px;
  font-size: 0.875rem;
  font-weight: 700;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: rgba(255, 255, 255, 0.85); /* a11y: 0.7 was 4.07:1 on pitch-green, fails AA; 0.85 clears 4.5:1 (TSK-040) */
}

.rules-banner__title {
  margin: 0 0 20px;
  font-size: clamp(2rem, 4vw, 3rem);
  line-height: 1.05;
  color: #fff;
}

.rules-banner__text {
  margin: 0;
  max-width: 32em;
  font-size: 1.125rem;
  line-height: 1.6;
  color: rgba(255, 255, 255, 0.85);
}

.rules-banner .wp-block-buttons {
  display: flex;
  flex-wrap: wrap;
  gap: 16px;
  justify-content: center;
}

.rules-banner__cta .wp-block-button__link {
  padding: 16px 28px;
  border-radius: var(--radius-pill);
  font-weight: 700;
  font-size: 1rem;
}

.rules-banner__cta.is-style-fill .wp-block-button__link {
  background-color: #fff;
  color: var(--color-pitch-green);
  border: 2px solid #fff;
}

.rules-banner__cta.is-style-fill .wp-block-button__link:hover {
  background-color: var(--color-cream);
  border-color: var(--color-cream);
  color: var(--color-pitch-green);
}

.rules-banner__cta.is-style-outline .wp-block-button__link {
  background-color: transparent;
  color: #fff;
  border: 2px solid rgba(255, 255, 255, 0.5);
}

.rules-banner__cta.is-style-outline .wp-block-button__link:hover {
  background-color: rgba(255, 255, 255, 0.1);
  border-color: #fff;
  color: #fff;
}

/* Stacked layout below WP's column breakpoint: center copy + CTAs. */
@media (max-width: 781px) {
  .rules-banner {
    text-align: center;
  }

  .rules-banner__text {
    margin-left: auto;
    margin-right: auto;
  }
}

/* TSK-022: Single-product trust block, injected via hook below add-to-cart. */
.futbol_mesa_trust {
  list-style: none;
  margin: 16px 0 0;
  padding: 16px 0 0;
  border-top: 1px solid #e6e6e6;
  display: flex;
  flex-wrap: wrap;
  gap: 8px 24px;
}

.futbol_mesa_trust li {
  display: flex;
  align-items: center;
  gap: 8px;
  margin: 0;
  font-size: 0.875em;
  color: #595959;
}

.futbol_mesa_trust svg {
  width: 20px;
  height: 20px;
  flex-shrink: 0;
}

/* TSK-029: returns + WhatsApp items link out, so they need their own
   underline/hover treatment instead of inheriting the plain text styling. */
.futbol_mesa_trust a {
  color: inherit;
  text-decoration: underline;
}

.futbol_mesa_trust a:hover,
.futbol_mesa_trust a:focus {
  color: #c0421b;
}

/* TSK-027: shipping-cost disclosure, below the trust block. */
.futbol_mesa_shipping_note {
  margin: 8px 0 0;
  font-size: 0.875em;
  color: #595959;
}

/* TSK-031: mobile sticky add-to-cart bar. Hidden by default (desktop already
   shows price + CTA in the first viewport); the 767px breakpoint below pins it
   to the bottom of the screen so both stay visible without scrolling, on every
   product regardless of title length, gallery size or product type. */
.futbol_mesa_sticky_atc {
  display: none;
}

/* Scroll target for the bar's CTA, printed just above the real add-to-cart
   form. The offset keeps the form clear of the sticky mobile header (~60px)
   after the jump; it's a no-op on desktop, where the header isn't sticky. */
.futbol_mesa_add_to_cart_anchor {
  display: block;
  scroll-margin-top: 76px;
}

@media (max-width: 767px) {
  html {
    scroll-behavior: smooth;
  }

  .futbol_mesa_sticky_atc {
    position: fixed;
    left: 0;
    right: 0;
    bottom: 0;
    z-index: 99; /* below the sticky header (100), above page content */
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
    padding: 10px var(--content-gutter);
    padding-bottom: max(10px, env(safe-area-inset-bottom));
    background: #fff;
    border-top: 1px solid var(--color-hairline);
    box-shadow: 0 -2px 10px rgba(0, 0, 0, 0.08);
  }

  .futbol_mesa_sticky_atc__price {
    font-size: 1.125rem;
    font-weight: 700;
    color: var(--color-terracotta);
    white-space: nowrap;
  }

  .futbol_mesa_sticky_atc__cta {
    flex: 0 0 auto;
    text-decoration: none;
  }

  /* Reserve room at the foot of every single-product page so the fixed bar
     never overlaps the trust block / related products it sits on top of. */
  body.single-product {
    padding-bottom: 76px;
  }
}

/* Site-wide content column (per the Claude Design mockup): the --content-max
   band with a responsive gutter, border-box so the padding sits inside the
   max-width. Storefront's default is a narrower content-box column with two
   breakpoint rules (max-width:66.4989em -> 2.617924em margins, and a smaller
   one -> 1.41575em margins) that swap the base margin:0 auto for fixed em
   margins and break the fluid gutter. Override unconditionally so every band —
   contact bar, header, nav, page content, footer — keeps one auto-centered
   left/right edge with the same fluid gutter at all viewport widths. */
.col-full {
  max-width: var(--content-max);
  box-sizing: border-box;
  margin-left: auto;
  margin-right: auto;
  padding-left: var(--content-gutter);
  padding-right: var(--content-gutter);
}

@media (min-width: 768px) {
  /* #masthead id beats Storefront's all-class width rule on .site-branding, which
     otherwise stays wide and starves the search. Shrink branding to the logo so
     .site-search can claim the row's free space; the logo link must be
     inline-block or the branding's auto width follows the block link's stretch. */
  #masthead .site-branding {
    flex: 0 0 auto;
    width: auto;
  }

  #masthead .site-branding .custom-logo-link {
    display: inline-block;
  }

  /* Keep the cart flush to the right edge with a clear gap after the search
     (mockup). margin-left shrinks the flex-grown search, opening the gap while
     the cart stays last in the row. */
  #masthead #site-header-cart {
    margin-left: clamp(16px, 2.5vw, 40px);
  }

  /* Let the search claim the row's free space so the field is wide enough to
     show the full "Buscar productos…" placeholder next to the Buscar button. */
  .site-header .site-search {
    flex: 1 1 auto;
    min-width: 320px;
  }

  .site-header .col-full {
    display: flex;
    align-items: center;
  }

  /* Header dividers span the full viewport, like the design: the nav's top
     rule and the header's bottom rule sit on the full-width wrappers, while
     Max Mega Menu's own border (inset to the max-width column) is removed so
     it doesn't draw a shorter line. */
  #mega-menu-wrap-primary {
    border: 0 !important; /* remove Max Mega Menu's inset wrap border so the full-width divider shows */
  }

  .storefront-primary-navigation {
    border-top: 1px solid var(--color-hairline);
  }

  .site-header {
    border-bottom: 1px solid var(--color-hairline);
    /* Storefront pads the header 2.6em on top and 0 on the bottom; the design
       uses an even 16px. Bottom padding is 0 because the nav's own link padding
       gives the lower band its height (the nav lives inside the header here). */
    padding-top: 16px;
    padding-bottom: 0;
  }

  /* 16px gap between the search row and the full-width divider, like the design. */
  .storefront-primary-navigation {
    margin-top: 16px;
  }

  #site-navigation.main-navigation {
    margin-top: 0;
  }

  /* Symmetric link padding centers the labels in the nav band (design uses
     14px/16px); override Max Mega Menu's fixed 44px row height/line-height. */
  #mega-menu-wrap-primary #mega-menu-primary > li.mega-menu-item > a.mega-menu-link {
    height: auto;
    line-height: 1.3;
    padding: 14px 16px;
  }

  /* Drop the menu's own left padding so the first item's box (and thus its
     bottom-border underline) is flush with the logo / content edge, while the
     link's own padding keeps the label text indented. */
  #mega-menu-wrap-primary #mega-menu-primary {
    padding-left: 0;
  }

  /* Dropdown panels: ink background like the "Añadir al carrito" button,
     terracotta on hover like the "Buscar" button. */
  #mega-menu-wrap-primary #mega-menu-primary > li.mega-menu-item .mega-sub-menu,
  #mega-menu-wrap-primary #mega-menu-primary > li.mega-menu-item .mega-sub-menu a.mega-menu-link {
    background-color: var(--color-ink) !important; /* beats Max Mega Menu's themed colors */
    color: #fff !important;
  }

  #mega-menu-wrap-primary #mega-menu-primary > li.mega-menu-item .mega-sub-menu a.mega-menu-link:hover,
  #mega-menu-wrap-primary #mega-menu-primary > li.mega-menu-item .mega-sub-menu a.mega-menu-link:focus,
  #mega-menu-wrap-primary #mega-menu-primary > li.mega-menu-item .mega-sub-menu li.mega-menu-item:hover > a.mega-menu-link {
    background-color: var(--color-terracotta) !important;
    color: #fff !important;
  }
}

