/* Owlbase: sign-in, account and Copy Watch. Uses the tokens from style.css. */

/* brand mark: a small owl face */
.owl { position: relative; display: inline-block; width: 28px; height: 28px; border-radius: 9px; background: var(--accent); flex: none; }
.owl::before, .owl::after { content: ""; position: absolute; top: 9px; width: 9px; height: 9px; border-radius: 50%; background: var(--accent-ink);
  box-shadow: inset 0 0 0 2.5px var(--accent-ink), inset 0 0 0 4.5px var(--accent); }
.owl::before { left: 4px; } .owl::after { right: 4px; }

/* header account button */
.acct { display: flex; align-items: center; }
.acct-btn { display: grid; place-items: center; width: 36px; height: 36px; border-radius: 50%; background: var(--panel-2); border: 1px solid var(--line);
  color: var(--text); font-weight: 700; text-decoration: none; }
.acct-btn:hover, .acct-btn:focus-visible { border-color: var(--accent); }

/* sign-in screen */
body.signed-out > :not(.auth):not(.toast):not(.sr) { visibility: hidden; }
.auth { position: fixed; inset: 0; z-index: 100; display: grid; place-items: center; padding: 16px; background: var(--bg); overflow: auto; }
.auth-card { width: min(420px, 100%); background: var(--panel); border: 1px solid var(--line); border-radius: var(--radius-lg); padding: 28px; box-shadow: var(--shadow);
  display: flex; flex-direction: column; gap: 12px; }
.auth-brand { display: flex; align-items: center; gap: 10px; font: 800 20px/1 var(--display); margin-bottom: 6px; }
.auth-card h1 { font: 700 24px/1.2 var(--display); margin: 0; }
.auth-card > p { margin: 0; color: var(--muted); }
.auth-f { display: flex; flex-direction: column; gap: 5px; font-size: 14px; color: var(--muted); }
.auth-f input, .cw-in, .acct-form input { font: inherit; color: var(--text); background: var(--panel); border: 1px solid var(--line-2); border-radius: var(--radius-sm);
  padding: 10px 12px; min-height: 42px; }
.auth-f input:focus-visible, .cw-in:focus-visible, .acct-form input:focus-visible { outline: 2px solid var(--accent); outline-offset: 1px; }
.auth-err { color: var(--down); min-height: 1.2em; margin: 0; font-size: 14px; }
.auth-card .btn { justify-content: center; }
.auth-foot { font-size: 13px; color: var(--faint) !important; }

/* Copy Watch */
.cw-stats { display: grid; grid-template-columns: repeat(5, minmax(0, 1fr)); gap: 10px; margin: 4px 0 16px; }
.cw-stats a { background: var(--panel); border: 1px solid var(--line); border-radius: var(--radius); padding: 14px 16px; color: var(--text); text-decoration: none; }
.cw-stats a:hover { border-color: var(--line-2); }
.cw-stats a.hot { border-color: var(--down); }
.cw-stats b { display: block; font: 700 26px/1.1 var(--display); }
.cw-stats span { color: var(--muted); font-size: 13px; }
.cw-tabs { display: flex; gap: 4px; border-bottom: 1px solid var(--line); margin-bottom: 16px; overflow-x: auto; }
.cw-tabs a { padding: 10px 14px; color: var(--muted); text-decoration: none; font-weight: 600; border-bottom: 2px solid transparent; white-space: nowrap; }
.cw-tabs a.on { color: var(--text); border-bottom-color: var(--accent); }
.cw-list { display: flex; flex-direction: column; gap: 12px; }
.cw-match { position: relative; background: var(--panel); border: 1px solid var(--line); border-radius: var(--radius); padding: 16px; }
.cw-pair { display: grid; grid-template-columns: minmax(0, 1fr) auto minmax(0, 1fr); gap: 14px; align-items: start; }
.cw-pair figure { margin: 0; display: grid; grid-template-columns: 96px minmax(0, 1fr); gap: 12px; align-items: start; }
.cw-pair img, .cw-pair .ph { width: 96px; height: 96px; border-radius: var(--radius-sm); background: var(--panel-2); object-fit: contain; }
.cw-pair figcaption { display: flex; flex-direction: column; gap: 3px; min-width: 0; }
.cw-pair figcaption a { color: var(--text); font-weight: 600; overflow-wrap: anywhere; }
.cw-pair small { color: var(--muted); font-size: 13px; }
.cw-pair small a { font-weight: 500; color: var(--accent); }
.cw-who { font-size: 11px; font-weight: 700; text-transform: uppercase; letter-spacing: .06em; color: var(--up); }
.cw-who.sus { color: var(--down); }
.cw-score { display: grid; place-items: center; align-self: center; width: 64px; height: 64px; border-radius: 50%; border: 2px solid var(--line-2); text-align: center; }
.cw-score b { font: 700 20px/1 var(--display); }
.cw-score small { font-size: 10px; color: var(--muted); }
.cw-ai { margin: 12px 0 0; font-size: 14px; }
.cw-shots { display: grid; grid-template-columns: repeat(2, minmax(0, 220px)); gap: 12px; margin-top: 12px; }
.cw-shots figure { margin: 0; }
.cw-shots img, .cw-shots .ph { width: 100%; aspect-ratio: 16 / 9; object-fit: cover; border-radius: var(--radius-sm); background: var(--panel-2); display: block; }
.cw-shots figcaption { font-size: 12px; color: var(--muted); margin-top: 4px; }
.cw-why { margin: 10px 0 0; font-size: 13px; color: var(--muted); }
.cw-rights { margin: 8px 0 0; font-size: 13px; color: var(--warn); }
.cw-acts { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 12px; }
.cw-pick { position: absolute; top: 12px; right: 12px; }
.cw-pick input { width: 20px; height: 20px; accent-color: var(--accent); }
.cw-packbar p { margin: 0 0 10px; }
.cw-packrow, .acct-row, .cw-copyhead, .cw-add { display: flex; gap: 8px; flex-wrap: wrap; align-items: center; }
.cw-copyhead { justify-content: space-between; }
.cw-copyhead h2 { margin: 0; }
.cw-add { margin-bottom: 14px; }
.cw-add .cw-in, .cw-packrow .cw-in { flex: 1; min-width: 200px; }
.cw-in.sm { min-height: 34px; padding: 6px 10px; font-size: 14px; max-width: 140px; }
.cw-items img, .cw-items .ph { width: 44px; height: 44px; border-radius: 8px; object-fit: contain; background: var(--panel-2); }
.cw-items select { font: inherit; padding: 6px 8px; border-radius: 8px; border: 1px solid var(--line-2); background: var(--panel); color: var(--text); }
.cw-items tr.off td { opacity: .55; }
.cw-sw { display: inline-flex; align-items: center; gap: 6px; font-size: 14px; }
.cw-sources { display: flex; flex-direction: column; }
.cw-src { display: flex; justify-content: space-between; gap: 12px; padding: 12px 0; border-top: 1px solid var(--line); }
.cw-srcacts { display: flex; gap: 6px; align-items: flex-start; flex: none; }
.cw-verify { margin-top: 6px; font-size: 14px; }
.cw-verify summary { cursor: pointer; color: var(--accent); }
.cw-ign { display: flex; align-items: center; gap: 8px; padding: 6px 0; border-top: 1px solid var(--line); }
.cw-ign button { margin-left: auto; }
.cw-empty { max-width: 640px; }
.cw-steps { margin: 0 0 16px; padding-left: 22px; display: grid; gap: 6px; }
.cw-warnbox { border-color: color-mix(in srgb, var(--warn) 45%, var(--line)); margin-bottom: 16px; }
.cw-ta { width: 100%; box-sizing: border-box; font: 13px/1.5 ui-monospace, "SF Mono", Menlo, monospace; color: var(--text); background: var(--panel-2);
  border: 1px solid var(--line); border-radius: var(--radius-sm); padding: 10px; margin-top: 10px; resize: vertical; }
.crumb { margin: 0 0 4px; }
.hidden { display: none !important; }

/* account */
.acct-form { display: flex; flex-direction: column; gap: 12px; }
.acct-form label { display: flex; flex-direction: column; gap: 5px; font-size: 14px; color: var(--muted); }
.acct-form p { margin: 0; font-size: 13px; }
.acct-meter { display: block; height: 8px; border-radius: 4px; background: var(--panel-2); overflow: hidden; }
.acct-meter i { display: block; height: 100%; background: var(--accent); }

@media (max-width: 760px) {
  .cw-stats { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .cw-stats a:first-child { grid-column: 1 / -1; }
  .cw-pair { grid-template-columns: 1fr; }
  .cw-score { width: auto; height: auto; border: 0; display: flex; gap: 6px; justify-content: flex-start; }
  .cw-pair figure { grid-template-columns: 80px minmax(0, 1fr); }
  .cw-pair img, .cw-pair .ph { width: 80px; height: 80px; }
  .cw-src { flex-direction: column; }
  .cw-items th:nth-child(3), .cw-items td:nth-child(3) { display: none; }
}
@media print {
  .auth, .acct, .cw-tabs, .cw-acts, .cw-pick { display: none !important; }
}

/* Watchlist: watched games */
.watch-games { margin-bottom: 18px; }
.wg-head { display: flex; flex-wrap: wrap; align-items: baseline; justify-content: space-between; gap: 6px 16px; margin-bottom: 8px; }
.wg-head h2 { margin: 0; }
@container (min-width: 521px) { .watch-games .sp { display: flex; flex-direction: column; align-items: flex-end; gap: 2px; } }
.wg-note { font-size: 12px; margin: 8px 0 0; }
.wt-h { margin: 0 0 10px; }

/* Copy Watch: bulk changes on Your items */
.cw-selcol { width: 28px; padding-right: 0 !important; }
.cw-selcol input { width: 18px; height: 18px; accent-color: var(--accent); }
.cw-hint { margin: 0 0 10px; display: flex; flex-wrap: wrap; align-items: center; gap: 8px; }
.cw-bulk { position: sticky; bottom: 16px; z-index: 20; margin-top: 16px; display: flex; flex-wrap: wrap; align-items: center; gap: 8px;
  padding: 10px 14px; background: var(--panel); border: 1px solid var(--accent); border-radius: var(--radius); box-shadow: var(--shadow); }
.cw-bulk select { font: inherit; padding: 6px 8px; border-radius: 8px; border: 1px solid var(--line-2); background: var(--panel); color: var(--text); }
.cw-bulk-sep { width: 1px; align-self: stretch; background: var(--line); margin: 0 4px; }
@media (max-width: 760px) { .cw-bulk { bottom: calc(76px + env(safe-area-inset-bottom)); } .cw-bulk-sep { display: none; } }

/* Watch stars on prediction rows and the All trends list */
.p-watch .watchbtn, .c-watch .watchbtn { width: 36px; min-height: 36px; padding: 0; justify-content: center; }
.prowhead, .prow { grid-template-columns: 44px minmax(0, 1fr) 104px 96px 112px 108px 36px; }
.rowhead, .lrow.trend-row { grid-template-columns: 28px 44px minmax(0, 1fr) 118px 120px 86px 110px 92px 36px; }
@media (max-width: 1180px) {
  .rowhead, .lrow.trend-row { grid-template-columns: 28px 44px minmax(0, 1fr) 110px 100px 80px 88px 36px; }
}
@media (min-width: 981px) and (max-width: 1180px) {
  /* the lanes share the page with the side column here: drop Build type so the name keeps room next to the star */
  .prowhead, .prow { grid-template-columns: 44px minmax(0, 1fr) 104px 96px 108px 36px; }
  .prowhead span:nth-child(5), .prow .p-kind { display: none; }
}
@media (min-width: 701px) and (max-width: 980px) {
  .prowhead, .prow { grid-template-columns: 40px minmax(0, 1fr) 84px 72px 96px 36px; }
}
@media (max-width: 700px) {
  /* phones: score stacked (number over words) top right, star under it, so the name keeps its width */
  .prow { grid-template-columns: 44px minmax(0, 1fr) auto; grid-template-areas: "th nm sc" "th eta wt"; }
  .prow .pscore { flex-direction: column; align-items: flex-end; gap: 0; }
  .prow .p-watch { grid-area: wt; justify-self: end; }
  .lrow.trend-row { grid-template-columns: 44px minmax(0, 1fr) 36px; grid-template-areas: "th nm wt" "th ph wt"; }
  .lrow.trend-row .c-watch { grid-area: wt; align-self: center; }
}
.prowhead span:nth-last-child(2), .rowhead span:nth-last-child(2) { text-align: right; }
