/* Student workspace: SDEP Portal's neutral palette, with compact document navigation. */
body[data-view="home"] {
  --home-ink: #37352f;
  --home-muted: #787774;
  display: block;
  padding: 0;
  background: #fff;
  color: #37352f;
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
}
body[data-view="home"] .shell {
  width: 100%;
  min-height: 100dvh;
  margin: 0;
  border-radius: 0;
  box-shadow: none;
  background: #fff;
  overflow: visible;
}
body[data-view="home"] .shell::before { display: none; }
body[data-view="home"] .topbar {
  position: sticky;
  top: 0;
  z-index: 20;
  display: flex;
  align-items: center;
  gap: 12px;
  height: 56px;
  width: auto;
  margin-left: 224px;
  padding: 0 32px;
  background: #fffffff5;
  border-bottom: 1px solid #eeedeb;
}
body[data-view="home"] .topbar::before { content: "Espai de votació"; color: #9b9a97; font-size: 12px; font-weight: 400; }
body[data-view="home"] .brand-lockup,
body[data-view="home"] .session-pill { display: none; }
body[data-view="home"] .top-actions { margin-left: auto; display: flex; gap: 4px; }
body[data-view="home"] .top-actions .ghost-button {
  width: auto;
  min-height: 30px;
  padding: 5px 10px;
  border: 0;
  border-radius: 4px;
  background: transparent;
  color: #787774;
  box-shadow: none;
  font-size: 12px;
  font-weight: 400;
}
body[data-view="home"] .top-actions .ghost-button:hover { color: #37352f; background: #f1f1ef; }
body[data-view="home"] #homeView {
  display: block;
  min-height: calc(100dvh - 56px);
  margin-left: 224px;
  padding: 58px clamp(24px, 5vw, 76px) 64px;
  color: #37352f;
}
#homeView :where(span, small, p) { font-weight: 400; text-transform: none; letter-spacing: normal; }
#homeView :where(strong, b) { font-weight: 600; }
#homeView :where(h2, h3) { font-weight: 650; font-style: normal; letter-spacing: -.025em; }
#homeView :where(button) { font-size: 13px; font-weight: 500; text-transform: none; cursor: pointer; }
#homeView button:focus-visible,
body[data-view="home"] .topbar button:focus-visible { outline: 2px solid #2383e2; outline-offset: 3px; }
#homeView .workspace-sidebar {
  position: fixed;
  inset: 0 auto 0 0;
  z-index: 30;
  display: flex;
  flex-direction: column;
  width: 224px;
  padding: 24px 12px 18px;
  border-right: 1px solid #eeedeb;
  background: #f7f7f5;
}
#homeView .workspace-brand { display: flex; align-items: center; gap: 10px; padding: 0 10px 32px; }
#homeView .workspace-brand > div { display: grid; gap: 3px; }
#homeView .workspace-brand strong { font-size: 15px; font-weight: 650; letter-spacing: -.035em; }
#homeView .workspace-brand small { color: #9b9a97; font-size: 10px; }
#homeView .workspace-mark { display: grid; place-items: center; width: 30px; height: 30px; border: 1px solid #deddd9; border-radius: 6px; background: #fff; font-size: 22px; font-weight: 750; letter-spacing: -.06em; }
#homeView .workspace-navigation { display: grid; gap: 3px; }
#homeView .workspace-navigation button { display: flex; align-items: center; gap: 9px; min-height: 37px; padding: 8px 10px; border: 0; border-radius: 5px; background: transparent; color: #787774; text-align: left; font-size: 12px; }
#homeView .workspace-navigation button > span:first-child { width: 17px; color: #9b9a97; font-size: 17px; text-align: center; }
#homeView .workspace-navigation button:hover { background: #eeedeb; color: #37352f; }
#homeView .workspace-navigation button.active { background: #eae9e6; color: #37352f; font-weight: 550; }
#homeView .workspace-count { margin-left: auto; color: #787774; font-size: 11px; }
#homeView .workspace-profile { display: flex; align-items: center; gap: 9px; margin-top: auto; padding: 18px 8px 0; border-top: 1px solid #e9e9e7; }
#homeView .workspace-profile > div { min-width: 0; display: grid; gap: 4px; }
#homeView .workspace-profile strong { font-size: 11px; font-weight: 500; line-height: 1.45; }
#homeView .workspace-profile small { display: flex; align-items: center; gap: 5px; color: #9b9a97; font-size: 10px; }
#homeView .profile-avatar { display: grid; place-items: center; flex: 0 0 28px; height: 28px; border-radius: 5px; background: #e9e9e6; color: #787774; font-size: 12px; font-weight: 500; }
#homeView .session-dot { width: 5px; height: 5px; border-radius: 50%; background: #448361; }
body[data-view="home"] #homeView .voting-panel { display: block; width: 100%; max-width: 1000px; min-height: 0; margin: 0 auto; padding: 0; border: 0; border-radius: 0; background: #fff; box-shadow: none; }
#homeView .home-hero { display: block; margin: 0 0 38px; padding: 0; text-align: left; }
#homeView .home-hero::after { display: none; }
#homeView .home-hero-copy { display: grid; gap: 9px; max-width: none; }
#homeView .home-kicker { color: #9b9a97; font-size: 11px; font-weight: 400; }
#homeView .home-hero h2 { margin: 0; font-size: 32px; line-height: 1.25; color: #37352f; }
#homeView .home-hero-copy p:last-child { max-width: none; color: #787774; font-size: 13px; line-height: 1.7; font-weight: 400; }
#homeView .home-dashboard { display: grid; grid-template-columns: minmax(0, 1.7fr) minmax(220px, 1fr); align-items: start; gap: 32px; }
#homeView .home-dashboard:not([data-section="ballots"]) { display: block; max-width: 720px; }
#homeView .dashboard-section, #homeView .dashboard-rail { display: grid; align-content: start; min-width: 0; gap: 14px; }
#homeView .dashboard-main { grid-row: auto; }
#homeView .dashboard-title { min-height: 30px; display: flex; align-items: center; justify-content: space-between; gap: 12px; padding-bottom: 12px; border-bottom: 1px solid #e9e9e7; }
#homeView .dashboard-title h3, #homeView .live-results-panel > h3 { color: #37352f; font-size: 13px; font-weight: 550; letter-spacing: 0; }
#homeView .live-results-panel > h3 { min-height: 30px; padding: 5px 0 12px; border-bottom: 1px solid #e9e9e7; }
#homeView .dashboard-title .ghost-button { min-height: 26px; padding: 4px 7px; border: 0; border-radius: 4px; background: transparent; color: #787774; box-shadow: none; font-size: 11px; font-weight: 400; }
#homeView .dashboard-title .ghost-button:hover { background: #f1f1ef; }
#homeView .proposal-list { display: grid; gap: 12px; }
#homeView .proposal-summary { display: grid; grid-template-columns: minmax(0, 1fr); gap: 20px; min-height: 0; padding: 22px; border: 1px solid #e9e9e7; border-radius: 5px; background: #fff; box-shadow: 0 1px 2px #00000003; }
#homeView .proposal-summary.is-urgent, #homeView .proposal-summary.is-voted { box-shadow: 0 1px 2px #00000003; }
#homeView .proposal-summary-copy { display: grid; gap: 9px; min-width: 0; }
#homeView .proposal-summary .proposal-status { justify-self: start; padding: 3px 7px; border-radius: 3px; background: #faf0db; color: #986d24; font-size: 10px; font-weight: 500; line-height: 1.4; }
#homeView .proposal-summary.is-voted .proposal-status { color: #448361; background: #edf4ee; }
#homeView .proposal-summary h3 { color: #37352f; font-size: 17px; font-weight: 600; line-height: 1.45; }
#homeView .proposal-summary-copy > p { display: -webkit-box; -webkit-box-orient: vertical; -webkit-line-clamp: 2; overflow: hidden; max-height: 44px; color: #787774; font-size: 12px; line-height: 1.8; font-weight: 400; }
#homeView .proposal-summary-meta { display: flex; align-items: center; flex-wrap: wrap; gap: 12px; padding-top: 15px; border-top: 1px solid #f1f1ef; }
#homeView .proposal-summary-meta strong, #homeView .proposal-summary-meta > span { color: #9b9a97; font-size: 11px; font-weight: 400; }
#homeView .open-proposal-button, #homeView .back-link, #homeView .primary-button, #homeView .secondary-button { min-height: 32px; width: fit-content; padding: 7px 12px; border: 1px solid #37352f; border-radius: 4px; background: #37352f; color: #fff; box-shadow: none; font-weight: 500; font-size: 12px; transition: background-color 120ms ease; }
#homeView .open-proposal-button:hover, #homeView .primary-button:hover, #homeView .secondary-button:hover { background: #1a1a1a; }
#homeView .proposal-summary-meta .open-proposal-button { margin-left: auto; }
#homeView .live-results-list { display: grid; gap: 12px; }
#homeView .live-result-card { display: grid; gap: 16px; padding: 18px; border: 1px solid #e9e9e7; border-radius: 5px; background: #fff; box-shadow: none; }
#homeView .live-result-card > div:first-child { display: grid; gap: 5px; }
#homeView .live-result-card > div:first-child > span { color: #9b9a97; font-size: 10px; }
#homeView .live-result-card strong { color: #37352f; font-size: 12px; font-weight: 500; line-height: 1.5; }
#homeView .live-result-card .open-proposal-button { padding: 0; border: 0; background: transparent; color: #787774; font-size: 11px; min-height: 22px; }
#homeView .result-bar div { color: #787774; font-size: 10px; font-weight: 400; }
#homeView .result-bar strong { font-size: 10px; }
#homeView .result-bar i { height: 4px; background: #eeedeb; box-shadow: none; }
#homeView .result-bar.yes i::before { background: #779c83; }
#homeView .result-bar.no i::before { background: #c28079; }
#homeView .result-bar.abstain i::before { background: #b4b2ab; }
#homeView .dashboard-tabs { display: none; }
#homeView .notification-card, #homeView .notification-card.urgent, #homeView .notification-card.push-card, #homeView .notification-card.push-card.enabled { padding: 18px; border: 1px solid #e9e9e7; border-radius: 5px; background: #fff; box-shadow: none; }
#homeView .notification-card span { color: #9b9a97; font-size: 10px; font-weight: 400; }
#homeView .notification-card strong { color: #37352f; font-size: 13px; font-weight: 550; line-height: 1.5; }
#homeView .notification-card small { color: #787774; font-size: 12px; font-weight: 400; line-height: 1.7; }
#homeView .dashboard-placeholder, #homeView .my-proposal { min-height: 0; padding: 24px; border: 1px solid #e9e9e7; border-radius: 5px; background: #fafaf9; color: #787774; box-shadow: none; font-size: 13px; font-weight: 400; line-height: 1.8; }
#homeView .student-proposal-form { display: grid; gap: 20px; padding: 24px; border: 1px solid #e9e9e7; border-radius: 5px; background: #fff; box-shadow: none; }
#homeView label { color: #37352f; font-size: 12px; font-weight: 500; }
#homeView input, #homeView textarea { padding: 10px 12px; border: 1px solid #deddd9; border-radius: 4px; background: #fff; font-size: 13px; color: #37352f; font-weight: 400; }
#homeView .student-proposal-form .secondary-button { justify-self: start; }
#homeView .detail-mode .home-hero { display: none; }
#homeView .proposal-detail-page-card { padding: 0; border: 0; border-radius: 0; background: #fff; box-shadow: none; }
#homeView .proposal-detail-page-card::before, #homeView .proposal-detail-page-card::after { display: none; }
#homeView .detail-page-header { margin-bottom: 28px; padding: 0 0 16px; border-bottom: 1px solid #e9e9e7; background: #fff; }
#homeView .ballot-seal { display: none; }
#homeView .back-link { color: #787774; background: transparent; border-color: #e9e9e7; }
#homeView .legal-status-stack .proposal-status { color: #448361; font-size: 11px; font-weight: 500; }
#homeView .legal-status-stack small { display: none; }
#homeView .detail-page-grid { display: grid; grid-template-columns: minmax(0, 1.8fr) minmax(220px, 1fr); gap: 32px; }
#homeView .detail-main-panel { gap: 18px; }
#homeView .detail-main-panel h3 { font-size: 26px; line-height: 1.3; color: #37352f; }
#homeView .detail-main-panel > p:not(.home-kicker) { max-height: 240px; overflow-y: auto; padding-right: 8px; color: #787774; font-size: 13px; font-weight: 400; line-height: 1.8; white-space: pre-wrap; }
#homeView .ballot-notice, #homeView .current-vote-card, #homeView .ballot-process-card, #homeView .locked-vote-panel, #homeView .detail-results-panel { padding: 18px; border: 1px solid #e9e9e7; border-radius: 5px; background: #fafaf9; box-shadow: none; }
#homeView .ballot-notice strong, #homeView .locked-vote-panel strong, #homeView .ballot-process-card strong { color: #37352f; font-size: 13px; font-weight: 550; }
#homeView .ballot-notice span, #homeView .locked-vote-panel span, #homeView .ballot-process-card p { color: #787774; font-size: 12px; font-weight: 400; line-height: 1.8; }
#homeView .ballot-process-card p { max-height: 200px; overflow-y: auto; }
#homeView .ballot-process-card .primary-button { background: #37352f; border-radius: 4px; min-height: 34px; color: #fff; }
#homeView .ballot-process-track span { min-height: 25px; border-radius: 3px; background: #f1f1ef; color: #9b9a97; font-size: 10px; font-weight: 400; }
#homeView .ballot-process-track span.active { background: #eae9e6; color: #37352f; }
#homeView .current-vote-card span, #homeView .detail-results-panel > span { color: #9b9a97; font-size: 10px; }
#homeView .current-vote-card strong, #homeView .detail-results-panel > strong { color: #37352f; font-size: 14px; }
#homeView .detail-vote-grid { display: grid; grid-template-columns: 1fr; gap: 8px; }
#homeView .vote-button { min-height: 42px; padding: 10px 14px; border: 1px solid #deddd9; border-radius: 4px; background: #fff; color: #37352f; box-shadow: none; font-size: 13px; font-weight: 500; }
#homeView .vote-button.yes { background: #edf4ee; color: #448361; }
#homeView .vote-button.no { background: #fbefee; color: #a85b53; }
#homeView .vote-button.abstain { background: #f1f1ef; color: #787774; }
@media (max-width: 1100px) {
  #homeView .home-dashboard, #homeView .detail-page-grid { grid-template-columns: minmax(0, 1fr); gap: 28px; }
}
@media (max-width: 760px) {
  body[data-view="home"] .topbar { height: 48px; margin-left: 0; padding: 0 20px; }
  body[data-view="home"] .topbar::before { content: "mySDEP"; color: #37352f; font-size: 14px; font-weight: 650; }
  body[data-view="home"] #homeView { margin-left: 0; padding: 0 20px 40px; }
  #homeView .workspace-sidebar { position: static; width: auto; margin: 0 -20px 30px; padding: 12px 16px; border: 0; border-bottom: 1px solid #e9e9e7; background: #fafaf9; }
  #homeView .workspace-brand, #homeView .workspace-profile { display: none; }
  #homeView .workspace-navigation { display: flex; gap: 4px; overflow-x: auto; }
  #homeView .workspace-navigation button { flex: 0 0 auto; min-height: 34px; gap: 5px; padding: 7px 9px; font-size: 11px; }
  #homeView .workspace-navigation button > span:first-child { display: none; }
  #homeView .workspace-navigation .workspace-count { margin-left: 2px; }
  #homeView .home-hero { margin-bottom: 26px; }
  #homeView .home-hero h2 { font-size: 27px; }
  #homeView .home-hero-copy p:last-child { font-size: 12px; }
  #homeView .proposal-summary { padding: 18px; }
  #homeView .proposal-summary-meta { gap: 8px; }
  #homeView .proposal-summary h3 { font-size: 16px; }
}
/* Feedback stays brief; queue positions and completion come from the server. */
#homeView .workspace-navigation button { transition: background-color 120ms ease, color 120ms ease; }
#homeView .open-proposal-button:active, #homeView .primary-button:active, #homeView .vote-button:active { transform: scale(.98); }
#homeView .open-proposal-button, #homeView .primary-button, #homeView .vote-button { transition: transform 120ms cubic-bezier(.23,1,.32,1), background-color 120ms ease; }
#homeView .student-access-notice { margin: 0 0 24px; padding: 14px 18px; border: 1px solid #eadfc2; border-radius: 5px; background: #fcf8ed; color: #9a8051; font-size: 12px; line-height: 1.7; }
#homeView .student-turnout { display: grid; gap: 12px; padding-block: 10px; }
#homeView .student-turnout > strong { font-size: 34px; font-weight: 600; letter-spacing: -.04em; color: #6e865d; }
#homeView .student-turnout > strong > small { display: inline; margin-left: 3px; font-size: 18px; color: inherit; }
#homeView .student-turnout p { font-size: 11px; color: #85857f; }
#homeView .student-turnout > small { color: #aaa99f; font-size: 10px; }
#homeView .turnout-track { height: 5px; overflow: hidden; border-radius: 3px; background: #eeeee8; }
#homeView .turnout-track i { display: block; height: 100%; background: #91a782; }
.voting-demo-banner { position: fixed; z-index: 65; inset: auto 16px 16px; display: flex; align-items: center; gap: 14px; width: fit-content; max-width: calc(100% - 32px); margin-inline: auto; padding: 12px 18px; border: 1px solid #dedfce; border-radius: 6px; background: #fafcf3; color: #7d885e; box-shadow: 0 4px 20px #00000008; font: 11px -apple-system,BlinkMacSystemFont,"Segoe UI",sans-serif; }
.voting-demo-banner strong { font-weight: 600; }
.voting-demo-banner a { color: inherit; white-space: nowrap; }
.queue-notice { border-color: #e0e5da; background: #fcfdf8; }
.queue-notice strong { font-weight: 600; }
.queue-pulse { background: #879f76; }
@media(max-width:700px) { .voting-demo-banner { flex-wrap: wrap; gap: 7px; } .voting-demo-banner span { order: 3; width: 100%; font-size: 10px; } }
@media(prefers-reduced-motion:reduce) { #homeView .workspace-navigation button, #homeView .open-proposal-button, #homeView .primary-button, #homeView .vote-button { transition: none; } }
#homeView .ballot-choice-screen { gap: 14px; }
#homeView .ballot-choice-screen > strong { color: #37352f; font-size: 16px; font-weight: 600; }
#homeView .vote-button { text-align: left; padding-left: 42px; position: relative; }
#homeView .vote-button::before { content: ''; position: absolute; left: 15px; top: 50%; width: 13px; height: 13px; border: 1px solid currentColor; border-radius: 50%; transform: translateY(-50%); opacity: .55; }
#homeView .vote-button[aria-pressed="true"] { border-color: currentColor; box-shadow: inset 0 0 0 1px currentColor; }
#homeView .vote-button[aria-pressed="true"]::before { background: currentColor; box-shadow: inset 0 0 0 3px #fff; opacity: 1; }
#homeView .vote-confirmation-copy { color: #85857f; font-size: 11px; line-height: 1.8; }
#homeView [data-confirm-vote]:disabled { opacity: .4; cursor: default; }
#homeView .ballot-process-track { grid-template-columns: repeat(2,minmax(0,1fr)); }
.queue-count { display: none; }
body[data-view="login"].is-queued::after { content: ''; position: fixed; inset: 0; z-index: 65; background: #fafaf9; }
body[data-view="login"].is-queued .queue-notice { top: 50%; bottom: auto; transform: translate(-50%,-50%); flex-direction: column; align-items: center; width: min(380px,calc(100% - 40px)); padding: 30px; border: 1px solid #e5e6df; background: #fff; border-radius: 7px; box-shadow: 0 8px 32px #00000006; text-align: center; }
body[data-view="login"].is-queued .queue-count { display: grid; gap: 4px; }
body[data-view="login"].is-queued .queue-count > strong { color: #758b64; font-size: 46px; font-weight: 600; line-height: 1.1; letter-spacing: -.045em; }
body[data-view="login"].is-queued .queue-count > span { color: #91918b; font-size: 11px; }
body[data-view="login"].is-queued .queue-notice > div:last-child > strong { font-size: 12px; }
body[data-view="login"].is-queued .queue-notice p { color: #a1a199; font-size: 11px; line-height: 1.8; }
#homeView .result-denominator { color: #70716a; font-size: 10px; line-height: 1.6; }
