/* RRG Contractors — small overrides on top of Tailwind CDN.
   Kept minimal: tokens live in tailwind.config (inline in each page).
   Only add rules here that Tailwind can't express cleanly. */

html { scroll-behavior: smooth; }

/* Nicer text rendering for the display font */
h1, h2, h3, h4 {
  letter-spacing: -0.01em;
}

/* Prevent Tailwind CDN FOUC before JS runs */
body { opacity: 1; }

/* Focus rings use accent color for brand consistency */
:where(a, button, input, textarea):focus-visible {
  outline: 2px solid #E8A838;
  outline-offset: 2px;
}

.site-brand-link {
  display: inline-flex;
  align-items: center;
  min-width: 0;
  text-decoration: none;
}

.site-brand-title {
  font-family: "DM Sans", sans-serif;
  font-size: 1.45rem;
  font-weight: 900;
  line-height: 1;
  color: #1B3A5C;
  background-image: linear-gradient(90deg, #1B3A5C 0%, #2B5A8C 42%, #E8A838 58%, #1B3A5C 100%);
  background-size: 260% 100%;
  background-position: 0% 50%;
  -webkit-background-clip: text;
  background-clip: text;
  transition: background-position 420ms ease, color 420ms ease, transform 220ms ease;
}

.site-brand-link:hover .site-brand-title,
.site-brand-link:focus-visible .site-brand-title {
  color: transparent;
  background-position: 100% 50%;
  transform: translateY(-1px);
}

@media (min-width: 768px) {
  .site-brand-title {
    font-size: 1.75rem;
  }
}

.home-recent-track {
  display: grid;
  grid-auto-flow: column;
  grid-auto-columns: minmax(180px, 240px);
  gap: 14px;
  overflow-x: auto;
  overscroll-behavior-inline: contain;
  scroll-snap-type: inline mandatory;
  scroll-padding-inline: 2px;
  padding: 2px 2px 10px;
  scrollbar-width: thin;
  scrollbar-color: #D1D5DB transparent;
}

.home-recent-track::-webkit-scrollbar {
  height: 8px;
}

.home-recent-track::-webkit-scrollbar-thumb {
  background: #D1D5DB;
  border-radius: 999px;
}

.home-recent-card {
  position: relative;
  height: 132px;
  overflow: hidden;
  border-radius: 8px;
  background: #E8E8E3;
  scroll-snap-align: start;
  box-shadow: 0 8px 20px rgba(15, 38, 64, 0.10);
}

.home-recent-card img,
.home-recent-card video {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 240ms ease;
}

.home-recent-card:hover img,
.home-recent-card:hover video {
  transform: scale(1.04);
}

.home-recent-card::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg, rgba(15, 38, 64, 0) 48%, rgba(15, 38, 64, 0.58) 100%);
  pointer-events: none;
}

.home-recent-caption {
  position: absolute;
  inset-inline: 12px;
  bottom: 10px;
  z-index: 1;
  color: #fff;
  font-size: 13px;
  font-weight: 600;
  line-height: 1.2;
  text-shadow: 0 1px 8px rgba(0, 0, 0, 0.35);
}

.home-recent-control {
  display: inline-flex;
  width: 38px;
  height: 38px;
  align-items: center;
  justify-content: center;
  border: 1px solid #D1D5DB;
  border-radius: 999px;
  color: #1B3A5C;
  background: #fff;
  transition: background-color 180ms ease, border-color 180ms ease, color 180ms ease;
}

.home-recent-control:hover {
  border-color: #1B3A5C;
  background: #1B3A5C;
  color: #fff;
}

.home-recent-play {
  position: absolute;
  top: 10px;
  right: 10px;
  z-index: 1;
  width: 30px;
  height: 30px;
  border-radius: 999px;
  background: rgba(15, 38, 64, 0.74);
  color: #fff;
  display: inline-flex;
  align-items: center;
  justify-content: center;
}

@media (min-width: 768px) {
  .home-recent-card {
    height: 150px;
  }
}

@media (max-width: 480px) {
  .home-recent-track {
    grid-auto-columns: minmax(168px, 74vw);
  }

  .home-recent-card {
    height: 124px;
  }
}
