:root {
  --page-width: 1600px;
  --space: 40px;
  --quarter-space: calc(var(--space) * 0.25);
  --half-space: calc(var(--space) * 0.5);
  --double-space: calc(var(--space) * 2);
  --triple-space: calc(var(--space) * 3);
  --xl-space: calc(var(--space) * 4);
  --facet-size: 50px;
}

@media screen and (max-width: 915px) {
    :root {
        --space: 16px;
        --facet-size: 25px;
    }
}

body {
    margin: 0;
}

body.mobile-menu-open {
  overflow: hidden;
  position: relative;
  height: 100vh;
  width: 100vw;
}

main {
    display: flex;
    flex-direction: column;
}

.color-scheme--darkest {
    --color-bg: #1B2941;
    --color-headings: #F2EADB;
    --color-body: #FFFFFF;
    --color-accent: #60949F;
    background-color: var(--color-bg);
}

.color-scheme--lightest {
    --color-bg: #FFFFFF;
    --color-headings: #1B2941;
    --color-body: #1B2941;
    --color-accent: #F2EADB;
    background-color: var(--color-bg);
}

.color-scheme--light {
    --color-bg: #F2EADB;
    --color-headings: #1B2941;
    --color-body: #1B2941;
    --color-accent: #60949F;
    background-color: var(--color-bg);
}

h1, h2, h3, h4, h5, h6 {
    color: var(--color-headings);
    font-family: Roboto Condensed;
  font-weight: 600;
  text-transform: uppercase;
   word-wrap: normal;
   margin: 0;
}

h1, .h1 {
    font-size: 32px;
}

h2 {
    font-size: 22px;
}

.color-scheme--darkest h1 {
    color: white;
}



p {
    color: var(--color-body);
    margin: 0;
    font-family: 'Roboto', sans-serif;
    font-size: 16px;
    line-height: 1.4;
}

.primary-button {
    padding: 12px 24px;
    border: none;
    font-size: 18px;
  font-family: 'Roboto Condensed', sans-serif;
  font-weight: 600;
  text-transform: uppercase;
  word-wrap: normal;
  width: fit-content;
}

.primary-button {
    background: var(--color-headings);
    color: var(--color-bg);
    transition: 0.4s ease;
}

.primary-button:hover {
  background: var(--color-accent);
  color: var(--color-bg);
  transition: 0.4s ease;
}

.primary-button svg path {
  fill: var(--color-bg);
  transition: 0.4s ease;
}

.primary-button:hover svg path {
  fill: var(--color-bg);
  transition: 0.4s ease;
}

section.page-width {
    margin-left: var(--space);
  margin-right: var(--space);
  position: relative;
}

section.page-width.add-bottom-space {
  margin-bottom: var(--space);
}

section.page-width.add-top-space {
    margin-top: var(--space);
}

section > .content-wrapper {
  max-width: var(--page-width);
  margin-left: auto;
  margin-right: auto;
  padding-left: var(--space);
  padding-right: var(--space);
  position: relative;
  z-index: 1;
}


.add-facets::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  width: var(--facet-size);
  height: var(--facet-size);
  background: linear-gradient(135deg, white 50%, transparent 50%);
  z-index: 2;
}

.add-facets::after {
  content: '';
  position: absolute;
  bottom: 0;
  right: 0;
  width: var(--facet-size);
  height: var(--facet-size);
  background: linear-gradient(135deg, transparent 50%, white 50%);
  z-index: 2;
}

.content-wrapper {
    display: flex;
  flex-direction: column;
  gap: var(--space);
}

.content-wrapper.medium-height {
  min-height: 500px;
  padding: var(--space)
}

@media screen and (max-width: 915px) {
    .content-wrapper.medium-height {
        min-height: 400px;
        padding-top: var(--triple-space);
  padding-bottom: var(--triple-space);
    }
}

.content-position--center-center {
  justify-content: center;
  align-items: center;
}

.content-position--center-center * {
    text-align: center;
}

.background-image {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  z-index: 0;
  overflow: hidden;
  background-color:var(--color-bg);
}

.background-image img {
  position: absolute;
  top: 50%;
  left: 50%;
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center center;
  display: block;
  transform: translate(-50%, -50%);
}

.background-image.overlay img {
  opacity: 0.55;
}

.relative {
  position: relative;
}


/**********************************************
*
* Multicolumn Section
*
**********************************************/
.content-multicolumn {
    padding: var(--space);
    display: flex;
    gap:var(--space);
    align-items: center;
}


/* Custom styles for multicolumn variations */
.content-multicolumn .c-allchalk-benefits {
    max-width: 123px;
}

.multicolumn-items {
    display: grid;
    grid-template-columns: 1fr 1fr 1fr 1fr;
    gap: var(--half-space);
    flex-grow: 1;
    width: 100%;
}

@media screen and (max-width: 915px) {
    .content-multicolumn {
        flex-direction: column;
        align-items: center;
    }

    .multicolumn-items {
        grid-template-columns: 1fr;
    }
}

.multicol-item {
        display: flex;
    flex-direction: column;
    height: 100%;
    flex-grow: 1;
}

.multicol-item-content {
    background-color: var(--color-accent);
    margin-top: -2px;
    margin-bottom: -2px;
    padding: var(--half-space) var(--space);
    gap: var(--half-space);
    display: flex;
    flex-direction: column;
    flex-grow: 1;
}

@media screen and (max-width: 915px) {
    .multicol-item-content {
        padding-bottom: var(--space);
        padding-top: var(--space);
    }
}

.multicol-item-content > img {
    max-width: 42px;
    margin: 0 auto;
}

.multicol-item-content * {
    text-align: center;
}

.multicol-item > img {
    width: 100%;
    height: auto;
}

@media screen and (max-width: 915px) {
    .content-multicolumn .c-allchalk-benefits {
        max-width: 227px;
        text-align: center;
        margin: 0 auto;
        width: 100%;
    } 
}

/**********************************************
*
* Split Content Section
*
**********************************************/
section .split-content {
    display: grid;
}

@media screen and (min-width: 750px) {
    section .split-content {
        grid-template-columns: 1fr 1fr;
    }
}

section .split-content .content-wrapper {
    padding: var(--triple-space) var(--space);
    max-width: 636px;
    margin: 0 auto;
}

.icon-with-text-columns {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  width: 100%;
}

.icon-with-text {
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
      gap: var(--half-space);
    padding-top: var(--half-space);
    padding-bottom: var(--half-space);
    max-width: 175px;
    margin: 0 auto;
}

section .split-content .c-max-width-340 {
max-width: 340px;
}

@media screen and (max-width: 915px) {
    section .split-content .split-content--image {
        order: -1;
        min-height: 20rem;;
    }

    section .split-content .content-wrapper {
        padding: var(--triple-space) var(--double-space);
    }

    .icon-with-text-columns {
        grid-template-columns: 1fr;
        gap: var(--space);
        max-width: 175px;
        padding-top: var(--space);
        padding-bottom: var(--space);
    }
}

/**********************************************
*
* Main Navigation Styles
*
**********************************************/
.main-nav {
  display: grid;
  grid-template-columns: 1fr auto 1fr;
  align-items: center;
  justify-content: space-between;
  padding: 30px var(--space);
  background: var(--color-bg, #fff);
  position: sticky;
  top: 0;
  z-index: 100; /* Lower than overlay */
}

.main-nav.gradient-nav {
  background: linear-gradient(90deg, #8EADB6 -17.18%, #EFE8DA 51.83%, #8EADB6 113.31%);
  box-shadow: 0 5px 35px 0 rgba(27, 41, 65, 0.25);
}
.nav-section {
  display: flex;
  align-items: center;
}
.nav-link,
.mobile-menu .nav-link {
  margin-right: var(--half-space);
  color: var(--color-headings, #222);
  text-decoration: none;
  font-family: 'Roboto Condensed', sans-serif;
  font-weight: 600;
  font-size: 18px;
  letter-spacing: 0.02em;
  transition: color 0.2s;
  text-transform: uppercase
}

.nav-left .nav-link:last-child {
  margin-right: 0;
}
.nav-link:hover {
  /* Remove color change on hover */
  color: var(--color-headings, #222);
}
.nav-logo img {
  display: block;
  height: 40px;
}
.nav-right {
  gap: var(--half-space);
  justify-content: flex-end;
  display: flex;
  align-items: center;
}
.nav-right .nav-link, .mobile-nav-actions .nav-link {
  font-family: 'Roboto Mono', monospace;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  font-weight: 500;
  font-size: 16px;
  margin-right: 12px;
}

.mobile-nav-actions .mobile-socials {
    display: flex;
    gap: var(--space);
    width: 100%;
}

.mobile-nav-actions {
    display: flex;
    row-gap: var(--triple-space);
    flex-wrap: wrap;
    margin-top: var(--double-space);
    column-gap: var(--space);
}

.nav-right .nav-link:last-child {
  margin-right: 0;
}
.nav-social img {
  display: block;
  height: 18px;
  width: 18px;
}
.nav-socials-flex {
  display: flex;
  gap: 16px;
  align-items: center;
}
.hamburger {
  display: none;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  width: 40px;
  height: 40px;
  background: none;
  border: none;
  cursor: pointer;
  margin-left: var(--half-space);
}
.hamburger span {
  display: block;
  width: 24px;
  height: 3px;
  background: var(--color-headings, #222);
  margin: 3px 0;
  border-radius: 2px;
  transition: 0.3s;
}
.mobile-menu {
  display: flex;
  flex-direction: column;
  position: fixed;
  top: 0;
  left: 0;
  height: 100vh;
  width: calc(100% - var(--double-space)); /* Full width */
  max-width: none; /* Remove max-width */
  background: var(--color-bg, #fff);
  box-shadow: 2px 0 16px rgba(0,0,0,0.12);
  padding: var(--double-space) var(--double-space) var(--double-space) var(--double-space);
  z-index: 2000; /* Ensure mobile menu overlays hamburger icon */
  transform: translateX(-100%);
  transition: transform 0.4s cubic-bezier(0.4,0,0.2,1);
}

/* Remove overlay */
body.mobile-menu-open::after {
  display: none !important;
}

/* Close button styles */
.mobile-menu .close-mobile-menu {
  position: absolute;
  top: 18px;
  right: 18px;
  background: none;
  border: none;
  font-size: 2.5rem;
  color: var(--color-headings, #222);
  cursor: pointer;
  z-index: 1101;
  line-height: 1;
  padding: 0;
}

@media (max-width: 915px) {
  .mobile-menu {
    width: auto;
    max-width: none;
    left: 0;
    right: 0;
  }
}

.mobile-nav-links {
    display: grid;
    gap: var(--half-space);
    margin-bottom: var(--space);
}

 .mobile-nav-links .nav-link {
    font-size: 200%;
 }

.mobile-menu.open {
  transform: translateX(0);
}

/* Overlay for mobile menu (optional, for dimming background) */
body.mobile-menu-open::after {
  content: '';
  position: fixed;
  top: 0;
  left: 0;
  width: 100vw;
  height: 100vh;
  background: rgba(0,0,0,0.3);
  z-index: 9999; /* Overlay above nav bar */
}

.nav-left .nav-link {
  display: flex;
  align-items: center;
  gap: 6px;
}

.nav-left .button-arrows {
  width: 11px;
  height: 13px;
  margin-left: 2px;
  vertical-align: middle;
}

.nav-left .button-arrows path {
  fill: var(--color-headings, #222);
  transition: fill 0.4s;
}

.nav-left .nav-link:hover .button-arrows path {
  fill: var(--color-headings, #222);
}

.nav-left .button-arrows {
  opacity: 0;
  transition: opacity 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

.nav-left .nav-link:hover .button-arrows,
.nav-left .nav-link:focus .button-arrows {
  opacity: 1;
}

.nav-left .nav-link.active .button-arrows {
  opacity: 1;
}

@media (max-width: 900px) {
  .main-nav {
    padding: 0 var(--half-space);
  }
  .nav-left, .nav-right {
    flex: 1;
  }
  .nav-center {
    flex: 0 0 auto;
    justify-content: center;
    display: flex;
  }
}
@media (max-width: 915px) {
  .main-nav {
    height: 56px;
  }
  .nav-left, .nav-right {
    display: none;
  }
  .nav-center {
    flex: 1;
    justify-content: center;
  }
  .nav-logo img {
    max-width: 165px;
    height: auto;
  }
  .hamburger {
    display: flex;
    position: absolute;
    right: var(--half-space);
    top: 8px;
    z-index: 1000; /* Lower than .mobile-menu */
  }
  .mobile-menu {
    display: flex;
  }
}

/* Pricing Table Styles */
.pricing-container {
    display: flex;
    gap: var(--double-space);
    justify-content: center;
    align-items: stretch;
}

.pricing-container .price-info {
    max-width: 250px;
    min-width: 0;
    padding: var(--half-space);
    display: flex;
    flex-direction: column;
    gap: var(--quarter-space);
    background: rgba(255,255,255,0.04);
    border-radius: 12px;
    align-items: center;
    text-align: center;
}

.gradient-divider-line {
    display: flex;
    align-items: center;
    justify-content: center;
}
.gradient-divider-line span {
    width: 3px;
    min-width: 3px;
    height: 100%;
    min-height: 80px;
    display: block;
    background: linear-gradient(0deg, rgba(242, 234, 219, 0) 6%, #F2EADB 50%, rgba(242, 234, 219, 0) 94%);
}

@media (max-width: 900px) {
  .pricing-container {
    gap: var(--space);
  }
}

@media (max-width: 915px) {
  .pricing-container {
    flex-direction: column;
    gap: var(--space);
    align-items: center;
  }
  .gradient-divider-line {
    width: 100%;
    justify-content: center;
    margin: 16px 0;
  }
  .gradient-divider-line span {
    width: 80px;
    min-width: 80px;
    height: 3px;
    min-height: 3px;
    background: linear-gradient(90deg, rgba(242, 234, 219, 0) 6%, #F2EADB 50%, rgba(242, 234, 219, 0) 94%);
  }
  .pricing-container .price-info {
    max-width: 100%;
    width: 100%;
    min-width: 0;
    padding: var(--half-space) 0;
    border-radius: 10px;
  }
}

.background-image.overlay.pricing-section img {
    opacity: 0.25;
}

/**********************************************
*
* App Layout Styles (Interesting Horses, etc.)
*
**********************************************/

h5 {
    font-size: 16px;
    letter-spacing: 0.04em;
    color: var(--color-body);
    align-self: center;
}

h6 {
    font-size: 14px;
    letter-spacing: 0.04em;
    color: var(--color-body);
    text-transform: uppercase;
    font-style: italic;
    font-weight: 500;
}

hr {
    height: 3px;
    min-height: 3px;
    border: none;
    padding: 0;
    margin: 0;
    display: block;
    width: 100%;
    flex-shrink: 0;
}

.color-scheme--darkest hr {
    background: linear-gradient(90deg, rgba(27, 41, 65, 0.20) 0%, rgba(242, 234, 219, 0.20) 48.56%, rgba(27, 41, 65, 0.20) 100%);
}

button {
    border: none;
    background-color: rgba(0,0,0,0);
}

.text-medium {
    font-weight: 500;
}

/* Time badges */
.time-badge {
    padding: 6px 10px;
    border-radius: 50px;
    width: fit-content;
}

.time-badge p {
    line-height: 1;
}

[data-color*="Green"] {
    background: rgba(26,213,152,0.15);
}

[data-color*="Green"] p {
    color: #0EBD84;
}

[data-color*="Yellow"] {
    background: rgba(250,202,74,0.15);
}

[data-color*="Yellow"] p {
    color: #FACA4A;
}

[data-color*="Red"] {
    background: rgba(244,9,56,0.15);
}

[data-color*="Red"] p {
    color: #F40938;
}

/* App Main Layout */
@media screen and (min-width: 990px) {
    main#app-main {
        display: grid;
        grid-template-columns: 350px 1fr;
    }

    main#app-main.race-details {
        grid-template-columns: 1fr;
    }
}

/* Sidebar */
main#app-main .app-sidebar {
    height: 100%;
    max-height: 100vh;
    position: sticky;
    top: 0;
    padding: calc(var(--half-space) + var(--quarter-space));
    display: flex;
    flex-direction: column;
    gap: calc(var(--half-space) + var(--quarter-space));
    overflow-y: auto;
    border-right: 5px solid #fafafa;
}

@media screen and (max-width: 989px) {
    main#app-main .app-sidebar {
        display: none;
    }
}

main#app-main .app-sidebar .sidebar--date-time {
    display: flex;
    justify-content: space-between;
    gap: var(--space);
    color: var(--color-headings);
}

.sidebar--date-time span {
    font-family: 'Roboto Mono', monospace;
    text-transform: uppercase;
    letter-spacing: 0.08em;
    font-weight: 500;
    font-size: 16px;
    color: var(--color-headings);
}

.sidebar--items-group, .sidebar--item.has-children .sidebar--item-children {
    display: flex;
    flex-direction: column;
    gap: 5px;
}

.sidebar--item.has-children .sidebar--item-children {
    padding: 0 var(--half-space);
    padding-bottom: var(--half-space);
}

.sidebar--item.has-children:not([open]) .sidebar--item-children {
    max-height: 0%;
    transition: 0.4s ease;
    overflow: hidden;
}

.sidebar--item.has-children .accordion-icon img {
    transition: 0.4s ease;
    transform: rotate(180deg);
}

.sidebar--item.has-children[open] .accordion-icon img {
    transition: 0.4s ease;
    transform: rotate(0deg);
}

.sidebar--item {
    background: rgba(242, 234, 219, 0.10);
    position: relative;
    transition: 0.5s ease;
    border: none;
    width: 100%;
    text-decoration: none;
    display: block;
}

.sidebar--item-children .sidebar--item {
    background: rgba(242, 234, 219, 0.0);
}

.sidebar--item .sidebar--item-label h5 {
    flex-grow: 1;
    text-align: left;
}

.sidebar--item-children .sidebar--item .sidebar--item-label {
    padding: var(--quarter-space) 15px;
    padding-right: 0;
}

.sidebar--item-children .sidebar--item:after {
    display: none;
}

.sidebar--item.has-children .sidebar--item-parent {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding-right: 15px;
    cursor: pointer;
}

.sidebar--item:not(.has-children):hover, .sidebar--item-children .sidebar--item:hover {
    background: rgba(242, 234, 219, 0.15);
    transition: 0.5s ease;
}

.sidebar--item::after {
    content: '';
    width: 12px;
    height: 12px;
    background: linear-gradient(135deg, rgba(27, 41, 65, 0.00) 50%, var(--color-bg) 50%);
    position: absolute;
    top: 100%;
    left: 100%;
    transform: translate(-100%, -100%);
}

.sidebar--item-label {
    display: flex;
    gap: var(--quarter-space);
    padding: var(--half-space) 15px;
    row-gap: calc(0.5 * var(--quarter-space));
    align-items: center;
}

.sidebar--item-icon {
    width: 19px;
    height: 22px;
}

.sidebar--item-icon img {
    width: 100%;
    height: 100%;
}

.sidebar--item.sidebar--upcoming-race .sidebar--item-label {
    display: grid;
    grid-template-columns: 1fr auto;
    padding: 15px;
}

.sidebar--item.sidebar--upcoming-race .sidebar--item-label * {
    text-align: left;
}

/* Main Content Area */
main#app-main .app-content {
    padding: var(--space);
    display: flex;
    flex-direction: column;
    gap: calc(2 * var(--space));
    border-left: 1px solid #ededed;
}

#app-main .app-content section.app--heading {
    display: flex;
    flex-direction: column;
    gap: var(--half-space);
}

#app-main .app-content section.app--heading h1 {
    display: flex;
    align-items: center;
    gap: var(--half-space);
}

#app-main .app-content section.app--heading .heading-icon {
    height: 1.5em;
    width: auto;
    vertical-align: middle;
}

/* Tables */
.app--table .entry-column-header {
    background-color: var(--color-accent);
    border-bottom: 1px solid;
    padding: var(--quarter-space);
    text-align: left;
}

@media screen and (min-width: 990px) {
    .app--table h6 {
        display: none;
    }
}

@media screen and (max-width: 989px) {
    .app--table .entry-column-header {
        display: none;
    }

    .app--table {
        border-top: 1px solid #809FB8;
    }

    .app--table h6 {
        color: #60949F;
        font-size: 13px;
        font-style: normal;
        width: 100%;
        text-transform: capitalize;
        font-family: Roboto;
        font-weight: 400;
        text-align: left;
    }

    .app--table .entry {
        flex-wrap: wrap;
        align-content: baseline;
        text-align: left;
        gap: 7px;
    }
}

.app--table > button {
    border-bottom: 1px solid #809FB8;
}

/* Horse number colors */
[data-number="1"] {
    background: #E53935;
    color: white;
    align-items: center;
}

[data-number="2"] {
    background: #F5F5F5;
    color: black;
    align-items: center;
}

[data-number="3"] {
    background: #1E88E5;
    color: white;
    align-items: center;
}

[data-number="4"] {
    background: #FDD835;
    color: black;
    align-items: center;
}

[data-number="5"] {
    background: #43A047;
    color: white;
    align-items: center;
}

[data-number="6"] {
    background: #212121;
    color: white;
    align-items: center;
}

[data-number="7"] {
    background: #FF9800;
    color: white;
    align-items: center;
}

[data-number="8"] {
    background: #F48FB1;
    color: black;
    align-items: center;
}

[data-number="9"] {
    background: #26C6DA;
    color: black;
    align-items: center;
}

[data-number="10"] {
    background: #7E57C2;
    color: white;
    align-items: center;
}

[data-number="11"] {
    background: #8D6E63;
    color: white;
    align-items: center;
}

[data-number="12"] {
    background: #66BB6A;
    color: white;
    align-items: center;
}

/* Filters */
.filter {
    margin-bottom: var(--space);
}

.filter label[for="track-filter"] {
    display: none;
}

.filter select {
    border: none;
    min-width: 200px;
    border-bottom: 1px solid;
    padding: var(--quarter-space) 0;
    color: var(--color-body);
    font-family: 'Roboto Condensed';
    text-transform: uppercase;
    letter-spacing: 0.04em;
    font-size: 16px;
    font-weight: 600;
    margin-bottom: var(--half-space);
    background: transparent;
    cursor: pointer;
}

.filter__tags {
    list-style: none;
    display: flex;
    gap: var(--half-space);
    padding: 0;
    margin: 0;
}

.filter__tags li {
    padding: var(--quarter-space) var(--half-space);
    padding-right: calc(var(--half-space) + 20px);
    background-color: #F2EADB;
    position: relative;
    color: #1B2941;
    font-family: 'Roboto Condensed';
    font-size: 14px;
    text-transform: uppercase;
    letter-spacing: 0.04em;
}

button.filter__tag-remove {
    width: 13px;
    height: 13px;
    background: #DCC9A5;
    position: absolute;
    top: 0;
    right: 0;
    line-height: 1.1;
    color: #FFFCF7;
    border: none;
    cursor: pointer;
    font-size: 12px;
}

@media screen and (max-width: 989px) {
    .filter__tags {
        flex-wrap: nowrap;
        overflow-x: scroll;
        padding-bottom: var(--quarter-space);
        gap: var(--half-space);
    }

    .filter__tags li {
        padding-right: calc(1.5 * var(--space));
        white-space: nowrap;
    }

    button.filter__tag-remove {
        width: 16px;
        height: 16px;
    }
}

/* Pagination */
.pagination {
    display: flex;
    justify-content: center;
    align-items: center;
    padding: var(--half-space) 0;
    gap: var(--half-space);
}

.pagination ul.pagination-numbers {
    list-style: none;
    display: flex;
    gap: var(--quarter-space);
    padding: 0;
    margin: 0;
}

.pagination ul.pagination-numbers li .pagination-button.active,
.pagination ul.pagination-numbers li .pagination-button:hover {
    background-color: var(--color-accent);
    transition: 0.4s ease;
}

.pagination ul.pagination-numbers li .pagination-button {
    padding: 5px 10px;
    border-radius: 8px;
    transition: 0.4s ease;
    font-weight: 500;
    font-family: 'Roboto';
    font-size: 14px;
    cursor: pointer;
}

.pagination .pagination-button {
    cursor: pointer;
    padding: 5px;
    border: none;
    background: transparent;
    border-radius: 4px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.pagination .pagination-button:hover {
    background-color: rgba(96, 148, 159, 0.15);
}

.pagination .pagination-button svg {
    width: 16px;
    height: 16px;
}

.pagination .pagination-button svg path {
    stroke: #1B2941;
}

/* Interesting Horses Table & Today's Races Table */
.app--table.app--table-interesting-horses .row--interesting-horses,
.app--table.app--table-todays-races .row--todays-races {
    grid-template-columns: 1fr 1fr 1fr 1fr;
    display: grid;
}

@media screen and (max-width: 989px) {
    .app--table.app--table-interesting-horses .row--interesting-horses,
    .app--table.app--table-todays-races .row--todays-races {
        grid-template-columns: 1fr 1fr;
    }
}

.app--table.app--table-interesting-horses button.row--interesting-horses,
.app--table.app--table-todays-races button.row--todays-races,
.app--table.app--table-todays-races a.row--todays-races {
    width: 100%;
    transition: 0.4s ease;
    text-decoration: none;
    color: inherit;
    border-bottom: 1px solid rgba(27, 41, 65, 0.1);
}

.app--table.app--table-interesting-horses button.row--interesting-horses:hover,
.app--table.app--table-todays-races button.row--todays-races:hover,
.app--table.app--table-todays-races a.row--todays-races:hover {
    background-color: rgba(96, 148, 159, 0.075);
    transition: 0.4s ease;
    cursor: pointer;
}

.app--table .entry {
    height: 70px;
    display: flex;
    align-items: center;
    padding-left: var(--quarter-space);
    padding-right: var(--quarter-space);
    gap: 6px;
}

.app--table .entry.entry-track-race {
    flex-direction: column;
    justify-content: center;
    align-items: flex-start;
    align-content: flex-start;
    gap: 5px;
}

.app--table .entry.entry-track-race h5 {
    align-self: flex-start;
}

@media screen and (max-width: 989px) {
    .app--table .entry.entry-track-race,
    .app--table .entry.entry-mtp {
        order: -1;
    }

    .app--table .entry.entry-mtp {
        justify-content: flex-end;
    }
}

@media screen and (min-width: 900px) {
    .app--table .entry.entry-ml h6,
    .app--table .entry.entry-projected-winner h6 {
        display: none;
    }
}

.app--table .entry.entry-ml > p {
    flex-grow: 1;
    text-align: left;
}

p.entry-number {
    width: 22px;
    min-width: 22px;
    text-align: center;
    height: 22px;
    min-height: 22px;
    line-height: 1.5;
    font-size: 14px;
    font-weight: 500;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
}

/* Sortable table headers */
.entry-column-header.sortable {
    cursor: pointer;
    user-select: none;
}

.entry-column-header.sortable:hover {
    opacity: 0.8;
}

.entry-column-header.sortable h5 {
    display: flex;
    align-items: center;
    gap: 4px;
}

.sort-indicator {
    font-size: 10px;
    opacity: 0.7;
}

/* Don't apply button styles to header row */
.row--interesting-horses.row--header {
    cursor: default;
}

.entry-badges {
    display: flex;
    gap: 6px;
    margin-left: 8px;
}

.entry-badges img {
    height: 34px;
    width: auto;
}

/* Badge tooltip styles */
.badge-tooltip {
    position: relative;
    display: inline-flex;
    cursor: pointer;
}

.badge-tooltip::after {
    content: attr(data-tooltip);
    position: absolute;
    bottom: 100%;
    left: 50%;
    transform: translateX(-50%);
    background-color: #1B2941;
    color: #fff;
    padding: 6px 10px;
    border-radius: 4px;
    font-size: 12px;
    font-weight: 500;
    white-space: nowrap;
    opacity: 0;
    visibility: hidden;
    transition: opacity 0.15s ease-out, visibility 0.15s;
    transition-delay: 0.15s;
    z-index: 1000;
    pointer-events: none;
    margin-bottom: 6px;
}

.badge-tooltip::before {
    content: '';
    position: absolute;
    bottom: 100%;
    left: 50%;
    transform: translateX(-50%);
    border: 6px solid transparent;
    border-top-color: #1B2941;
    opacity: 0;
    visibility: hidden;
    transition: opacity 0.15s ease-out, visibility 0.15s;
    transition-delay: 0.15s;
    z-index: 1000;
    pointer-events: none;
}

.badge-tooltip:hover::after,
.badge-tooltip:hover::before {
    opacity: 1;
    visibility: visible;
    transition-delay: 0s;
}

/* ============================================ */
/* Race Details Page Styles                     */
/* ============================================ */

/* Race page heading subheading (Race # + time badge inline) */
.app--race-subheading {
    display: flex;
    gap: var(--half-space);
    align-items: center;
}

.app--race-subheading * {
    align-self: center;
}

.app--race-subheading h4 {
    font-style: italic;
    margin: 0;
}

/* Projected winner callout */
.race-details--projected-winner, .race-details--projected-winner > span {
    display: flex;
    flex-wrap: wrap;
    gap: 6px;
    align-items: center;
}

.race-details--projected-winner {
    margin-bottom: var(--half-space);
    padding: var(--half-space);
    background-color: rgba(96, 148, 159, 0.1);
    border-radius: 8px;
}

/* Race details table - uses shared .app--table styles with 3-column grid */
.app--table.app--table-race-details .row--race-details {
    grid-template-columns: 1fr 1fr 1fr;
    display: grid;
}

/* Row styling - same pattern as todays-races and interesting-horses */
.app--table.app--table-race-details a.row--race-details {
    width: 100%;
    transition: 0.4s ease;
    text-decoration: none;
    color: inherit;
    border-bottom: 1px solid rgba(27, 41, 65, 0.1);
}

.app--table.app--table-race-details a.row--race-details:hover {
    background-color: rgba(96, 148, 159, 0.075);
    transition: 0.4s ease;
    cursor: pointer;
}

/* Header row - don't apply hover styles */
.row--race-details.row--header {
    cursor: default;
}

/* ML column with badges - space between content and badges */
.row--race-details .entry-ml {
    justify-content: space-between;
}

/* Race navigation */
.race-nav {
    display: flex;
    flex-wrap: wrap;
    gap: var(--quarter-space);
    margin-bottom: var(--half-space);
    align-items: center;
}

.race-nav .race-buttons {
    display: flex;
    gap: 4px;
}

.race-nav a {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 32px;
    height: 32px;
    padding: 0 8px;
    border-radius: 4px;
    text-decoration: none;
    color: var(--color-body);
    background-color: rgba(0, 0, 0, 0.05);
    font-size: 14px;
    transition: all 0.2s;
}

.race-nav a:hover {
    background-color: rgba(96, 148, 159, 0.2);
}

.race-nav a.active {
    background-color: #60949F;
    color: white;
    font-weight: 600;
}

.race-nav .next-race-container {
    display: flex;
    align-items: center;
    gap: 8px;
    margin-left: 8px;
}

.race-nav .separator {
    color: rgba(0, 0, 0, 0.3);
}

.race-nav .next-race {
    font-weight: 600;
    color: #60949F;
}

/* Results available banner */
.results-available-banner {
    background-color: #dce1ee;
    border-left: 4px solid #5e6da0;
    padding: var(--quarter-space) var(--half-space);
    margin-bottom: var(--half-space);
    border-radius: 4px;
}

.results-available-banner a {
    color: #5e6da0;
    font-weight: 600;
    text-decoration: none;
}

.results-available-banner a:hover {
    text-decoration: underline;
}

/* Last updated timestamp */
.race-details-content .last-updated {
    text-align: center;
    color: var(--color-body);
    opacity: 0.6;
    font-size: 12px;
    margin-top: var(--half-space);
    padding-top: var(--half-space);
    border-top: 1px solid rgba(0, 0, 0, 0.08);
}

/* Entries section */
.entries-section {
    margin-top: var(--space);
    padding: var(--half-space);
    background-color: rgba(242, 234, 219, 0.3);
    border-radius: 8px;
}

.entries-section h2 {
    margin: 0 0 var(--half-space) 0;
    font-size: 18px;
}

.entries-list {
    list-style: none;
    padding: 0;
    margin: 0;
    display: flex;
    flex-direction: column;
    gap: var(--quarter-space);
}

.entries-list li {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 8px 12px;
}

.entries-list .horse-link {
    color: var(--color-body);
    text-decoration: none;
}

.entries-list .horse-link:hover {
    text-decoration: underline;
}

/* Paywall section */
.paywall-section {
    padding: var(--space);
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    border-radius: 12px;
    text-align: center;
    margin: var(--half-space) 0;
}

.paywall-section h2 {
    color: white;
    font-size: 24px;
    margin-bottom: var(--quarter-space);
}

.paywall-section p {
    color: rgba(255, 255, 255, 0.95);
    font-size: 16px;
    margin-bottom: var(--half-space);
}

.paywall-buttons {
    display: flex;
    gap: 15px;
    justify-content: center;
    flex-wrap: wrap;
}

.paywall-section .btn {
    display: inline-block;
    padding: 12px 30px;
    text-decoration: none;
    border-radius: 6px;
    font-weight: bold;
    font-size: 16px;
    transition: transform 0.2s;
}

.paywall-section .btn-primary {
    background-color: #4CAF50;
    color: white;
}

.paywall-section .btn-secondary {
    background-color: white;
    color: #667eea;
}

.paywall-section .btn:hover {
    transform: translateY(-2px);
}

/* Mobile responsive for race details */
@media screen and (max-width: 989px) {
    .app--table .row--race-details {
        grid-template-columns: 1fr 1fr;
    }

    .row--race-details .entry-projected-winner {
        grid-column: span 2;
        align-content: center !important;
    }

    .row--race-details .entry-projected-winner > * {
        align-self: center;
    }

    .row--race-details .entry h6 {
        display: block;
    }

    .race-details--projected-winner {
        margin-bottom: var(--space);
    }
}
