/* =========================================================
   Fonts
   ========================================================= */
@font-face {
  font-family: 'Roboto';
  src: url('../font/Roboto-Regular.woff2') format('woff2');
  font-weight: 400;
  font-style: normal;
  font-display: swap;
}
@font-face {
  font-family: 'Big Shoulders';
  src: url('../font/BigShoulders-Regular.woff2') format('woff2');
  font-weight: 400;
  font-style: normal;
  font-display: swap;
}

@font-face {
  font-family: 'Big Shoulders';
  src: url('../font/BigShoulders-Bold.woff2') format('woff2');
  font-weight: 700;
  font-style: normal;
  font-display: swap;
}

/* =========================================================
   Base + Layout
   ========================================================= */
* { box-sizing: border-box; }
html, body { height: 100%; }
body {
  margin: 0;
  background: #1F1F1F;
  color: #ffffff;
  font-family: 'Roboto', system-ui, -apple-system, Segoe UI, Arial, sans-serif;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}
.background{
  z-index: -1;
  position: absolute;
  top: 0;
  right: 0;
  left: 0;
  bottom: 0;
  margin: 0 auto;
}

a { color: inherit; }
img { max-width: 100%; height: auto; }

.wrap {
  width: min(980px, calc(100% - 24px));
  height: 100vh;
  display: flex;
  flex-direction: column;
  justify-content: flex-start;
  align-items: center;
  padding: 15px;
  overflow-y: auto;
  margin: 0 auto;
}


.hero {
  padding: 22px 0 10px;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 20px;
}
.footer {
  padding: 50px 0 28px;
  opacity: 0.82;
  font-size: 13px;
  display: flex;
  align-items: center;
  justify-content: center;
}
.footer a {
  color: #9F9F9F;
  font-family: Roboto;
  font-size: 14px;
  font-style: normal;
  font-weight: 400;
  line-height: normal;
  text-decoration: none;
  display: flex;
  align-items: center;
  gap: 10px;
}
.footer a:hover { color: #fff; }

/* =========================================================
   Alerts
   ========================================================= */
.alert {
  padding: 12px;
  border-radius: 12px;
  margin: 12px 0;
}
.alert-error {
  background: rgba(255, 107, 107, 0.12);
  border: 1px solid rgba(255, 107, 107, 0.25);
}
.alert-warn {
  background: rgba(255, 220, 100, 0.12);
  border: 1px solid rgba(255, 220, 100, 0.25);
}
.alert-list {
  margin: 8px 0 0;
  padding-left: 18px;
}

/* =========================================================
   Form fields
   ========================================================= */
.form-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 12px;
}
@media (max-width: 560px) {
  .form-grid { grid-template-columns: 1fr; }
}

.field label {
  display: block;
  font-size: 13px;
  opacity: 0.88;
  margin-bottom: 6px;
}
.field input {
  width: 100%;
  height: 44px;
  border-radius: 10px;
  border: 1px solid rgba(255,255,255,0.10);
  background: rgba(255,255,255,0.06);
  color: #fff;
  padding: 0 12px;
}
.field input::placeholder { color: rgba(255,255,255,0.40); }
.field input:focus {
  outline: none;
  border-color: rgba(255,255,255,0.25);
}

.captcha { margin-top: 14px; }


/* Buttons */
.btn {
  border-radius: 5px;
  background: #EC1C1F;
  align-items: center;
  min-height: 42px;
  padding: 10px;
  width: 100%;
  color: #fff;
  font-family: "Big Shoulders";
  font-size: 14px;
  font-weight: 700;
text-transform: uppercase;
}
.btn:hover { filter: brightness(0.96); }
.btn:disabled {
  opacity: 0.65;
  cursor: not-allowed;
}

/* =========================================================
   Race banner
   ========================================================= */
.race-banner {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 12px;
}
.race-name {
  color: #FFF;
  font-family: "Big Shoulders";
  font-size: 20px;
  font-style: normal;
  font-weight: 700;
  line-height: normal;
}
.race-meta {
  color: #1CECAD;
  font-size: 12px;
}

/* =========================================================
   Picks UI (Custom dropdowns)
   ========================================================= */
.picks { margin-top: 14px; }
.picks-help {
  margin: 0 0 10px;
  font-size: 14px;
  font-family: Roboto;
}

.picks-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 10px;
}

/* Component wrapper: P# label + dropdown button */
.driver-select {
  position: relative;
  display: grid;
  grid-template-columns: 44px 1fr;
  gap: 8px;
  align-items: center;
}

.pick-label {
  height: 44px;
  display: flex;
  font-weight: 900;
  font-size: 13px;
  border-radius: 8px;
  color: rgba(255,255,255,0.85);
  flex-direction: column;
  align-items: center;
}

/* Button */
.driver-select-button {
  height: 42px;
  width: 100%;
  border: 1px solid #333;
  border-radius: 5px;
  background: #1f1f1f;
  color: #fff;
  padding: 0 10px;
  cursor: pointer;
  text-align: left;
}
.driver-select-button:focus {
  outline: none;
  border-color: rgba(255,255,255,0.25);
}

.driver-select-button-inner {
  display: flex;
  align-items: center;
  gap: 10px;
}

.driver-chip {
  display: inline-flex;
  align-items: center;
  gap: 8px;
}
.driver-chip-img img {
  width: 18px;
  height: 18px;
  display: block;
}
.driver-chip-text {
  color: #c1c1c1;
  font-family: Roboto;
  font-size: 14px;
  font-style: normal;
  font-weight: 400;
  line-height: normal;
}

/* Dropdown list */
.driver-select-list {
  position: absolute;
  z-index: 100;
  left: 52px; /* align under button, not label */
  top: 48px;
  width: calc(100% - 52px);
  max-height: 240px;
  overflow: auto;
  border-radius: 12px;
  border: 1px solid rgba(255,255,255,0.10);
  background: #151515;
  display: none;
  padding: 6px;
  box-shadow: 0 12px 30px rgba(0,0,0,0.45);
}
.driver-select.is-open .driver-select-list { display: block; }

.driver-select-option {
  width: 100%;
  border: 0;
  background: transparent;
  color: #fff;
  padding: 10px 10px;
  border-radius: 10px;
  cursor: pointer;
  text-align: left;
}
.driver-select-option:hover {
  background: rgba(255,255,255,0.06);
}
.driver-select-option[aria-selected="true"] {
  background: rgba(255,255,255,0.10);
}

/* Option row */
.opt {
  display: grid;
  grid-template-columns: 22px 1fr;
  align-items: center;
  gap: 10px;
}
.opt-img img { width: 18px; height: 18px; display: block; }
.opt-code {
  color: #FFF;
  font-size: 14px;
  font-weight: 400;
}
.form-error {
  display: none;
  margin-top: 10px;
  font-size: 13px;
  color: #ff6b6b;
}

/* Mobile */
@media (max-width: 380px) {
  .picks-grid { grid-template-columns: 1fr; }
  .driver-select-list {
    left: 0;
    width: 100%;
    top: 96px;
  }
}

/* =========================================================
   Reduce motion
   ========================================================= */
@media (prefers-reduced-motion: reduce) {
  * { scroll-behavior: auto !important; }
}
.w-full{
  width: 100%;
}
.mt-2{
  margin-top: 2rem;
}
.mb-2{
  margin-bottom: 2rem;
}
.input{
  display: flex;
  width: 340px;
  min-height: 42px;
  padding: 10px;
  align-items: center;
  gap: 10px;
}

/* Header container */
.header {
  width: min(980px, calc(100% - 24px));
  position: relative;
  padding: 15px;
  margin: 0 auto;
}

/* subtle dark overlay vibe */
.header::before {
  content: "";
  position: absolute;
  inset: 0;
  pointer-events: none;
}

/* red corner triangle (top-left) */
.header-corner {
  position: absolute;
  top: 0;
  left: 0;
  width: clamp(24px, 5vw, 42px);
  height: clamp(24px, 5vw, 42px);
  background: #e3162b;
  clip-path: polygon(0 0, 100% 0, 0 100%);
  z-index: 2;
}

/* layout */
.header-inner {
  position: relative;
  z-index: 1;
  display: flex;
  align-items: center;
  width: 100%;
  justify-content: space-between;
}

/* left block */
.header-left {
  min-width: 0; /* enables truncation if needed */
}

.header-title {
  color: #FFF;
  font-family: "Big Shoulders";
  font-size: 24px;
  font-style: normal;
  font-weight: 700;
  line-height: normal;
  margin: 0;
}

.header-meta {
  margin-top: clamp(6px, 1.4vw, 10px);
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 10px;
}

.header-season {
  color: #C9C9C9;
  font-family: "Big Shoulders";
  font-size: 16px;
  font-style: normal;
  font-weight: 400;
  line-height: normal;
}

.header-pill {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  color: #FFF;
  text-align: right;
  font-family: Roboto;
  font-size: 11px;
  font-style: normal;
  font-weight: 400;
  line-height: normal;
  border: 1px solid #868686;
  padding: 4px 8px;
  border-radius: 100px;
}

/* right block */
.header-right {
  display: flex;
  align-items: flex-end;
  white-space: nowrap;
  flex-shrink: 0;
  flex-direction: column;
  color: #1CECAD;
  font-family: Roboto;
  font-size: 14px;
  font-style: normal;
  font-weight: 400;
  line-height: normal;
  text-decoration: none;
}

.header-powered {
  font-size: clamp(12px, 2.2vw, 14px);
  opacity: 0.85;
  font-weight: 600;
}

.header-brand {
  display: inline-flex;
  align-items: center;
  gap: 10px;
}

.header-logo {
  width: clamp(18px, 3.2vw, 26px);
  height: clamp(18px, 3.2vw, 26px);
  display: inline-grid;
  place-items: center;
}

.header-logo svg {
  width: 100%;
  height: 100%;
  display: block;
}

.header-spacer{
  width: 100vw;
  height: 1px;
  background: #525252;
  line-height: normal;
  margin: 10px calc(-50vw + 50%);
}