/* Selectr case study, part 2: Round 2 with the poll, the Final leaderboard and responsive rules. */

/* ---------- round 2: the design ---------- */
.se-r2 { background: var(--cs-bg); }
.se-split { display: grid; grid-template-columns: minmax(0, 7fr) minmax(0, 4fr); gap: 40px clamp(40px, 5vw, 72px); align-items: center; margin-top: 56px; }
.se-split .se-panel { margin: 0; }
.se-notes { display: grid; margin: 0; padding: 0; list-style: none; }
.se-notes li { position: relative; display: grid; gap: 6px; padding: 22px 0 22px 24px; border-top: 1px solid var(--cs-line); }
.se-notes li:first-child { border-top: 0; }
.se-notes li::before { content: ""; position: absolute; top: 30px; left: 0; width: 10px; height: 10px; border-radius: 50%; background: var(--se-coral); }
.se-notes h3 { font-size: 19px; font-weight: 600; letter-spacing: -.01em; }
.se-notes p { margin: 0; font-size: 15px; line-height: 1.6; color: var(--cs-muted); }

/* ---------- the poll ---------- */
.se-vote { display: grid; grid-template-columns: minmax(0, 6fr) minmax(0, 5fr); gap: 40px clamp(32px, 4vw, 64px); align-items: center; margin-top: clamp(80px, 9vw, 120px); padding: clamp(28px, 4vw, 56px); border-radius: 32px; background: radial-gradient(60% 80% at 100% 0%, rgb(240 56 74 / 28%), transparent 60%), linear-gradient(135deg, var(--se-navy), #2b377a); color: var(--white); }
.se-vote__copy { display: grid; gap: 14px; }
.se-vote__tag { margin: 0; font-size: 12px; font-weight: 700; letter-spacing: .16em; text-transform: uppercase; color: #ff7884; }
.se-vote__q { font-size: clamp(30px, 3vw, 46px); font-weight: 600; line-height: 1.05; letter-spacing: -.035em; }
.se-vote__copy > p:not([class]) { max-width: 520px; margin: 0; font-size: 16px; line-height: 1.6; color: rgb(255 255 255 / 72%); }
.se-vote__shot { margin: 14px 0 0; border-radius: 18px; overflow: hidden; background: var(--white); }
.se-vote__shot img { display: block; width: 100%; height: auto; }
.se-poll { padding: clamp(22px, 2.4vw, 32px); border-radius: 24px; background: var(--white); color: var(--se-navy); box-shadow: 0 40px 70px -40px rgb(0 0 0 / 55%); }
.se-poll__title { margin: 0 0 18px; font-size: 18px; font-weight: 600; line-height: 1.35; }
.se-poll__list { display: grid; gap: 10px; margin: 0; padding: 0; list-style: none; }
.se-poll button { display: grid; grid-template-columns: 42px minmax(0, 1fr) auto; grid-template-rows: auto 8px; gap: 8px 12px; align-items: center; width: 100%; padding: 12px 16px 14px 12px; border: 1px solid var(--cs-line); border-radius: 16px; background: var(--white); font: inherit; color: inherit; text-align: left; cursor: pointer; transition: border-color .3s, box-shadow .3s; }
.se-poll button:hover { border-color: rgb(240 56 74 / 45%); }
.se-poll button:focus-visible { outline: 2px solid var(--se-coral); outline-offset: 2px; }
.se-poll button[aria-pressed="true"] { border-color: var(--se-coral); box-shadow: 0 10px 24px -14px rgb(240 56 74 / 60%); }
.se-poll__av { grid-row: 1 / 3; display: grid; place-items: center; width: 42px; height: 42px; border-radius: 50%; background: var(--se-lilac-2); font-size: 13px; font-weight: 700; transition: background .3s, color .3s; }
[aria-pressed="true"] .se-poll__av { background: var(--se-coral); color: var(--white); }
.se-poll__name { overflow: hidden; font-size: 15px; font-weight: 600; text-overflow: ellipsis; white-space: nowrap; }
.se-poll__pc { font-size: 15px; font-weight: 700; font-variant-numeric: tabular-nums; }
.se-poll__bar { grid-column: 2 / 4; height: 8px; border-radius: 8px; background: #eceaf6; overflow: hidden; }
.se-poll__bar i { display: block; width: var(--w, 0%); height: 100%; border-radius: 8px; background: #8f98d4; transition: width 1s cubic-bezier(.22, 1, .36, 1); }
[aria-pressed="true"] .se-poll__bar i { background: var(--se-coral); }
.se-poll__note { min-height: 3em; margin: 16px 0 0; font-size: 13px; line-height: 1.5; color: var(--cs-faint); }

/* ---------- final: the leaderboard ---------- */
.se-final { background: radial-gradient(50% 60% at 90% 10%, rgb(240 56 74 / 22%), transparent 70%), var(--cs-dark); color: var(--white); }
.se-final .cs-lead { color: rgb(255 255 255 / 70%); }
.se-final .se-hl { color: #ff6b79; }
.se-final__grid { display: grid; grid-template-columns: minmax(0, 7fr) minmax(0, 5fr); gap: 48px clamp(40px, 5vw, 80px); align-items: center; margin-top: 56px; }
.se-board { display: grid; gap: 12px; margin: 0; padding: 0; list-style: none; }
.se-board li { display: grid; grid-template-columns: 64px minmax(0, 1fr); gap: 20px; align-items: center; padding: 22px 26px 22px 20px; border-radius: 20px; background: rgb(255 255 255 / 6%); border: 1px solid rgb(255 255 255 / 10%); }
.se-board li:first-child { background: linear-gradient(90deg, rgb(240 56 74 / 22%), rgb(255 255 255 / 6%)); border-color: rgb(240 56 74 / 45%); }
.se-board__rank { display: grid; place-items: center; width: 56px; height: 56px; border-radius: 50%; background: rgb(255 255 255 / 10%); font-size: 24px; font-weight: 700; }
.se-board li:first-child .se-board__rank { background: var(--se-coral); }
.se-board h3 { margin: 0 0 6px; font-size: clamp(18px, 1.5vw, 21px); font-weight: 600; letter-spacing: -.01em; }
.se-board p { margin: 0; font-size: 15px; line-height: 1.6; color: rgb(255 255 255 / 68%); }
.se-final__shot { justify-self: center; width: min(100%, 560px); margin: 0; border-radius: 28px; overflow: hidden; }
.se-final__shot img { display: block; width: 100%; height: auto; }

/* ---------- responsive ---------- */
@media (max-width: 1000px) {
  .se-hero__grid, .se-split, .se-vote, .se-final__grid { grid-template-columns: 1fr; }
  .se-cards { grid-template-columns: 1fr; }
  .se-notes { grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 0 24px; }
  .se-notes li { border-top: 1px solid var(--cs-line); }
  .se-notes li:first-child { border-top: 1px solid var(--cs-line); }
}
@media (max-width: 720px) {
  .se-hero__shot { order: 1; margin-top: 6px; border-radius: 20px; }
  .se-hero__grid { row-gap: 22px; }
  .se-hero__copy { display: contents; }
  .se-chip, .se-hero__title { justify-self: start; }
  .se-profile { order: 2; margin-top: 6px; }
  .se-profile > div:nth-child(n + 3) { grid-column: 1 / -1; }
  .se-stepper { padding: 0 12px; }
  .se-stepper ol { margin-top: 16px; padding: 5px; }
  .se-stepper a { padding: 9px 2px; font-size: 13px; }
  .se-stepper__bar { top: 59px; width: calc(100% - 64px); }
  .se-intro { padding-top: 120px; }
  .se-phases { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; }
  .se-phases::before { display: none; }
  .se-phases li { justify-content: flex-start; padding: 10px 14px 10px 10px; font-size: 14.5px; }
  .se-panel, .se-vote__shot { border-radius: 18px; }
  .se-card { padding: 84px 22px 26px; }
  .se-card__n { top: 24px; left: 22px; }
  .se-notes { grid-template-columns: 1fr; }
  .se-vote { margin-inline: calc(var(--gutter) * -1 + 8px); border-radius: 24px; }
  .se-poll button { padding: 10px 12px 12px 10px; gap: 6px 10px; grid-template-columns: 36px minmax(0, 1fr) auto; }
  .se-poll__av { width: 36px; height: 36px; font-size: 12px; }
  .se-board li { grid-template-columns: 44px minmax(0, 1fr); gap: 14px; padding: 18px 18px 18px 14px; }
  .se-board__rank { width: 44px; height: 44px; font-size: 19px; }
}
@media (prefers-reduced-motion: reduce) {
  .se-poll__bar i, .se-stepper a { transition: none; }
  .se-live::before { animation: none; }
}
