.portal-selector-page,
.portal-mode-page {
  background: var(--color-background);
  color: var(--color-ink);
}

.portal-shell {
  min-height: 100vh;
  display: flex;
  flex-direction: column;
}

.portal-shell--light,
.portal-shell--desk {
  background:
    radial-gradient(circle at 50% 12%, rgba(255, 255, 255, 0.55), rgba(255, 255, 255, 0) 24%),
    linear-gradient(180deg, #f6f5f3 0%, var(--color-background) 100%);
  color: var(--color-ink);
}

.portal-shell--selector {
  background:
    radial-gradient(circle at 50% 14%, rgba(255, 255, 255, 0.6), rgba(255, 255, 255, 0) 18%),
    linear-gradient(180deg, #f8f7f5 0%, var(--color-background) 56%, #eceae7 100%);
}

.portal-main {
  flex: 1;
}

.portal-main--selector {
  display: grid;
  min-height: 100vh;
  min-height: 100svh;
}

.portal-main--selector .container-wide {
  width: 100%;
  max-width: none;
  margin: 0;
}

.portal-mode-switch {
  display: inline-flex;
  flex-wrap: wrap;
  gap: var(--space-3);
  margin-bottom: var(--space-2);
}

.portal-mode-switch__link {
  padding: 0.35rem 0.6rem;
  border-radius: var(--radius-sm);
  color: rgba(15, 16, 18, 0.62);
  font-family: var(--font-label);
  letter-spacing: 0.14em;
  text-transform: uppercase;
  font-size: 0.72rem;
}

.portal-mode-switch__link.is-active {
  background: rgba(17, 18, 20, 0.08);
  color: var(--color-ink);
}

.portal-mode-switch--light .portal-mode-switch__link {
  color: rgba(15, 16, 18, 0.62);
}

.portal-mode-switch--light .portal-mode-switch__link.is-active {
  background: rgba(17, 18, 20, 0.08);
  color: var(--color-ink);
}

.portal-hero {
  position: relative;
  min-height: 100vh;
  min-height: 100svh;
  display: grid;
}

.portal-hero--selector,
.portal-hero--public {
  align-items: center;
}

.portal-hero--staff-simple,
.portal-hero--student-simple {
  min-height: 0;
  overflow: clip;
  padding: var(--space-12) 0 var(--space-8);
}

.portal-hero__media {
  position: absolute;
  inset: 0;
  overflow: hidden;
}

.portal-hero__image {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center top;
  opacity: 0.68;
  filter: grayscale(1) saturate(0) contrast(1.04);
  position: relative;
  z-index: 0;
  transform: translate3d(0, 0, 0) scale(1.03);
  will-change: transform;
}

.portal-hero__overlay {
  position: absolute;
  inset: 0;
  background:
    radial-gradient(circle at 50% 38%, rgba(255, 255, 255, 0.14), rgba(255, 255, 255, 0) 28%),
    linear-gradient(180deg, rgba(247, 246, 244, 0.06) 0%, rgba(242, 241, 239, 0.22) 42%, rgba(242, 241, 239, 0.82) 72%, rgba(242, 241, 239, 1) 100%);
}

.portal-hero__media--selector .portal-hero__overlay {
  background:
    radial-gradient(circle at 50% 40%, rgba(255, 255, 255, 0.16), rgba(255, 255, 255, 0) 25%),
    linear-gradient(180deg, rgba(248, 247, 245, 0.08) 0%, rgba(242, 241, 239, 0.26) 40%, rgba(242, 241, 239, 0.86) 70%, rgba(242, 241, 239, 1) 100%);
}

.portal-hero__content {
  position: relative;
  z-index: 1;
  padding-top: var(--space-6);
  padding-bottom: var(--space-10);
}

.portal-hero__content::before {
  content: "";
  position: absolute;
  left: 50%;
  top: 4rem;
  width: min(88vw, 72rem);
  aspect-ratio: 1.08 / 0.76;
  transform: translateX(-50%);
  border-radius: 50%;
  background: radial-gradient(circle at 40% 30%, rgba(255, 255, 255, 0.28), rgba(225, 225, 225, 0.10) 50%, rgba(188, 188, 188, 0.03) 72%, rgba(255, 255, 255, 0) 78%);
  filter: blur(6px);
  z-index: -1;
}

.portal-hero__content::after {
  content: "";
  position: absolute;
  inset: auto 6% 12% auto;
  width: min(44vw, 30rem);
  height: min(24vw, 13rem);
  background: radial-gradient(circle, rgba(0, 0, 0, 0.04), rgba(0, 0, 0, 0) 70%);
  filter: blur(18px);
  z-index: -1;
}

.portal-hero__content--selector {
  width: 100%;
  min-height: 100%;
  display: grid;
  grid-template-rows: auto 1fr;
  align-items: stretch;
  padding-top: clamp(1rem, 2vh, 1.5rem);
  padding-bottom: clamp(1rem, 3vh, 2rem);
  padding-left: clamp(1.25rem, 4vw, 3.5rem);
  padding-right: clamp(1.25rem, 4vw, 3.5rem);
}

.portal-hero__content--selector .portal-brand-strip {
  position: relative;
  margin-bottom: var(--space-4);
}

.portal-hero__content--newsroom {
  width: 100%;
  min-height: 100vh;
  min-height: 100svh;
  display: grid;
  grid-template-rows: auto 1fr;
  align-items: stretch;
  padding-top: clamp(1rem, 2vh, 1.5rem);
  padding-bottom: clamp(1.5rem, 3vh, 2.25rem);
}

.portal-hero__content--newsroom .portal-brand-strip {
  margin-bottom: var(--space-4);
}

.portal-hero__content--newsroom .portal-greeting {
  align-self: center;
  justify-self: center;
  width: min(100%, 56rem);
}

.portal-hero__content--editorial {
  width: 100%;
  min-height: 100vh;
  min-height: 100svh;
  display: grid;
  grid-template-rows: auto auto 1fr;
  align-items: stretch;
  padding-top: clamp(1rem, 2vh, 1.5rem);
  padding-bottom: clamp(1.5rem, 3vh, 2.25rem);
}

.portal-hero__content--editorial .portal-brand-strip {
  margin-bottom: var(--space-4);
}

.portal-hero__content--editorial .portal-mode-switch {
  margin-bottom: var(--space-4);
}

.portal-hero__content--editorial .portal-editorial-grid {
  align-self: center;
  justify-self: center;
  width: min(100%, 72rem);
}

.portal-selector-stack {
  width: min(100%, 72rem);
  display: grid;
  align-content: center;
  align-self: center;
  justify-self: center;
  gap: var(--space-4);
  min-height: 0;
}

.portal-editorial-grid {
  display: grid;
  gap: var(--space-8);
}

.portal-editorial-grid--public,
.portal-editorial-grid--student,
.portal-editorial-grid--staff {
  align-items: start;
}

.portal-editorial-grid__main,
.portal-editorial-grid__aside {
  min-width: 0;
}

.portal-brand-strip {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: var(--space-4);
  margin-bottom: var(--space-6);
}

.portal-brand-strip__brand {
  display: inline-flex;
  align-items: center;
  font-family: var(--font-display);
  font-size: 1rem;
  letter-spacing: 0.14em;
  text-transform: uppercase;
}

.portal-brand-strip__brand img {
  display: block;
  width: clamp(8.75rem, 16vw, 11.5rem);
  height: auto;
}

.portal-link-button {
  text-decoration: none;
  white-space: nowrap;
}

.portal-inline-actions {
  display: flex;
  gap: 0.75rem;
  flex-wrap: wrap;
  margin-top: 1rem;
}

.newsroom-header-actions {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 0.75rem;
  flex-shrink: 0;
  flex-wrap: wrap;
}

.newsroom-user-badge {
  max-width: 18rem;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.newsroom-header-nav {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  flex-wrap: wrap;
}

.newsroom-signout-button {
  border-color: rgba(15, 16, 18, 0.2);
  color: rgba(15, 16, 18, 0.8);
}

@media (max-width: 980px) {
  .newsroom-header-actions {
    width: 100%;
    justify-content: flex-start;
  }

  .newsroom-user-badge {
    max-width: 100%;
    order: 1;
  }

  .newsroom-header-nav {
    order: 2;
  }

  .newsroom-signout-button {
    order: 3;
  }
}

.newsroom-link-nowrap {
  text-decoration: none;
  white-space: nowrap;
}

.newsroom-link-plain {
  text-decoration: none;
}

.newsroom-section {
  padding-bottom: var(--space-20);
}

.newsroom-auth-actions {
  margin-top: 1.25rem;
  display: flex;
  gap: 0.75rem;
  flex-wrap: wrap;
}

.newsroom-section-intro {
  margin-top: 0.35rem;
}

.newsroom-entry-actions {
  display: flex;
  width: 100%;
  align-items: center;
  justify-content: center;
  gap: var(--space-3);
}

.newsroom-entry-toggle.is-active {
  border-color: rgba(0, 0, 255, 0.22);
  color: var(--color-ai);
  box-shadow: inset 0 0 0 1px rgba(0, 0, 255, 0.06);
}

.newsroom-board {
  margin-top: var(--space-10);
}

.newsroom-side-head {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: var(--space-3);
  margin-bottom: var(--space-4);
}

.newsroom-side-head__title {
  margin-bottom: 0;
}

.newsroom-filter-nav {
  flex-wrap: wrap;
  gap: 0.4rem;
  margin-bottom: 0.75rem;
}

/* ── Type filter chips + search bar ────────────────────── */
.newsroom-filter-bar {
  display: flex;
  flex-direction: column;
  gap: var(--space-2);
  margin-bottom: 1rem;
}

.newsroom-filter-chips {
  display: flex;
  flex-wrap: wrap;
  gap: 0.35rem;
}

.newsroom-filter-chip {
  display: inline-flex;
  align-items: center;
  padding: 0.22rem 0.7rem;
  border-radius: 999px;
  border: 1px solid rgba(15, 16, 18, 0.14);
  background: transparent;
  font-family: var(--font-label);
  font-size: 0.68rem;
  font-weight: 700;
  letter-spacing: 0.07em;
  text-transform: uppercase;
  color: rgba(15, 16, 18, 0.48);
  cursor: pointer;
  transition: background var(--motion-fast), border-color var(--motion-fast), color var(--motion-fast);
}

.newsroom-filter-chip:hover {
  background: rgba(15, 16, 18, 0.05);
  border-color: rgba(15, 16, 18, 0.24);
  color: var(--color-ink);
}

.newsroom-filter-chip.is-active {
  background: var(--color-terracotta-soft, rgba(168, 102, 63, 0.08));
  border-color: var(--color-terracotta, #a8663f);
  color: var(--color-terracotta, #a8663f);
}

.newsroom-search-field {
  position: relative;
  display: flex;
  align-items: center;
  gap: 0.4rem;
  border-bottom: 1.5px solid rgba(15, 16, 18, 0.14);
  transition: border-color var(--motion-fast);
}

.newsroom-search-field:focus-within {
  border-bottom-color: var(--color-ai, #0000ff);
}

.newsroom-search-field__icon {
  flex-shrink: 0;
  color: rgba(15, 16, 18, 0.36);
  font-size: 1rem;
  line-height: 1;
  pointer-events: none;
  user-select: none;
}

.newsroom-search-input {
  flex: 1 1 auto;
  border: 0;
  background: transparent;
  color: var(--color-ink);
  font: inherit;
  font-size: 0.84rem;
  padding: 0.5rem 0.25rem;
  outline: none;
  min-width: 0;
}

.newsroom-search-input::placeholder {
  color: rgba(15, 16, 18, 0.36);
}

/* ── Results count ──────────────────────────────────────── */
.newsroom-results-count {
  margin: 0 0 var(--space-2);
  font-family: var(--font-label);
  font-size: 0.67rem;
  font-weight: 700;
  letter-spacing: 0.07em;
  text-transform: uppercase;
  color: rgba(15, 16, 18, 0.38);
}

/* ── Pagination ─────────────────────────────────────────── */
.newsroom-pagination {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--space-2);
  padding: var(--space-4) 0 var(--space-2);
  border-top: 1px solid rgba(15, 16, 18, 0.08);
  margin-top: var(--space-3);
}

.newsroom-pagination__info {
  flex: 1;
  text-align: center;
  font-family: var(--font-label);
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 0.07em;
  text-transform: uppercase;
  color: rgba(15, 16, 18, 0.42);
}

.newsroom-pagination__prev,
.newsroom-pagination__next {
  flex-shrink: 0;
}

.newsroom-pagination__prev:disabled,
.newsroom-pagination__next:disabled {
  opacity: 0.28;
  pointer-events: none;
}

.newsroom-stat-grid {
  margin-bottom: 1rem;
}

.newsroom-stat-card {
  animation: none;
  opacity: 1;
}

.newsroom-stat-card__value {
  margin: 0;
  font-size: 1.75rem;
}

.newsroom-status {
  opacity: 0.55;
  font-size: 0.85rem;
}

.newsroom-post-list {
  display: grid;
  gap: 0.75rem;
}

.newsroom-post-card {
  opacity: 0;
  animation: portal-fade-up 480ms cubic-bezier(0.2, 0.8, 0.2, 1) forwards;
}

.newsroom-post-card__meta-row {
  display: flex;
  align-items: center;
  gap: 0.4rem;
  flex-wrap: wrap;
  margin-bottom: 0.45rem;
}

.newsroom-post-card__title {
  margin-bottom: 0.25rem;
  font-size: 1rem;
}

.newsroom-post-card__summary {
  margin: 0;
  font-size: 0.8rem;
}

.newsroom-post-card__review {
  margin-top: 0.45rem;
  padding-left: 0.55rem;
  border-left: 2px solid rgba(15, 16, 18, 0.1);
  color: rgba(15, 16, 18, 0.55);
  font-size: 0.75rem;
}

.newsroom-post-card__footer {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
  margin-top: 0.5rem;
  color: rgba(15, 16, 18, 0.45);
  font-size: 0.72rem;
}

.newsroom-post-card__actions {
  display: flex;
  flex-wrap: wrap;
  gap: 0.4rem;
  margin-top: 0.75rem;
}

.portfolio-ingest-test-section {
  padding-bottom: var(--space-20);
}

.portfolio-ingest-test-board {
  margin-top: var(--space-10);
}

.portfolio-ingest-test__payload {
  font-family: Consolas, "Courier New", monospace;
}

.portfolio-ingest-test__actions {
  justify-content: space-between;
  gap: 0.75rem;
  flex-wrap: wrap;
}

.portfolio-ingest-test__secondary-actions {
  display: flex;
  gap: 0.75rem;
  flex-wrap: wrap;
}

.portfolio-ingest-test__response {
  margin-top: 1rem;
  white-space: pre-wrap;
  word-break: break-word;
  font-size: 0.8rem;
  line-height: 1.55;
  max-height: 34rem;
  overflow: auto;
  background: rgba(15, 16, 18, 0.04);
  border-radius: 1rem;
  padding: 1rem;
}

.portfolio-ingest-test__notes {
  margin-top: 1rem;
}

.portfolio-submit-section {
  padding-bottom: var(--space-20);
}

.portfolio-submit-board {
  margin-top: var(--space-10);
}

/* ── Sticky side panel on wide screens ─────────────────── */
@media (min-width: 1080px) {
  .portfolio-submit-board .portal-command-board__side {
    position: sticky;
    top: var(--space-8);
    align-self: start;
    max-height: calc(100vh - var(--space-16));
    overflow-y: auto;
  }
}

.portfolio-submit-form {
  display: grid;
  gap: 1.5rem;
}

.portfolio-submit-form__section--quick-tools {
  gap: 0.85rem;
  padding: 0.95rem 1rem 1.1rem;
  border: 1px solid rgba(15, 16, 18, 0.1);
  border-radius: 0.9rem;
  background: rgba(255, 255, 255, 0.74);
}

.portfolio-submit-quick-hint {
  margin: 0;
  color: rgba(15, 16, 18, 0.62);
  font-size: 0.88rem;
}

.portfolio-submit-checklist {
  border-radius: 0.75rem;
  background: rgba(15, 16, 18, 0.035);
  border: 1px solid rgba(15, 16, 18, 0.08);
  padding: 0.65rem 0.8rem;
}

.portfolio-submit-checklist__title {
  margin: 0;
  font-family: var(--font-label);
  font-size: 0.7rem;
  text-transform: uppercase;
  letter-spacing: 0.09em;
  color: rgba(15, 16, 18, 0.58);
}

.portfolio-submit-checklist__list {
  margin: 0.55rem 0 0;
  padding: 0;
  list-style: none;
  display: grid;
  gap: 0.34rem;
}

.portfolio-submit-checklist__list li {
  display: flex;
  align-items: center;
  gap: 0.42rem;
  font-size: 0.86rem;
}

.portfolio-submit-checklist__mark {
  width: 0.9rem;
  text-align: center;
  font-weight: 700;
}

.portfolio-submit-checklist__list li.is-ok {
  color: rgba(22, 90, 56, 0.96);
}

.portfolio-submit-checklist__list li.is-missing {
  color: rgba(160, 44, 36, 0.9);
}

/* ── Section dividers ───────────────────────────────────── */
.portfolio-submit-form__section {
  display: grid;
  gap: var(--space-5);
  padding-top: var(--space-6);
  border-top: 1px solid rgba(15, 16, 18, 0.07);
}

.portfolio-submit-form__section:first-of-type {
  padding-top: 0;
  border-top: 0;
}

/* ── Compact section heading component ─────────────────── */
.submit-section-head {
  display: flex;
  align-items: baseline;
  flex-wrap: wrap;
  gap: var(--space-2) var(--space-4);
}

.submit-section-head__kicker {
  color: rgba(15, 16, 18, 0.36);
  font-family: var(--font-label);
  font-size: var(--type-label-sm);
  font-weight: 700;
  letter-spacing: var(--tracking-label);
  text-transform: uppercase;
  flex-shrink: 0;
  min-width: 4.5rem;
}

.submit-section-head__title {
  margin: 0;
  font-family: var(--font-display);
  font-size: 1rem;
  font-weight: 600;
  color: var(--color-ink);
  letter-spacing: -0.01em;
  flex: 1 1 auto;
}

.submit-section-head__badge {
  display: inline-flex;
  align-items: center;
  padding: 0.2rem 0.6rem;
  border-radius: 999px;
  background: var(--color-terracotta-soft);
  color: var(--color-terracotta);
  font-family: var(--font-label);
  font-size: 0.62rem;
  font-weight: 700;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  white-space: nowrap;
  flex-shrink: 0;
}

/* ── Field grid ─────────────────────────────────────────── */
.portfolio-submit-form__grid {
  display: grid;
  gap: 1rem;
}

/* ── Select — match input/textarea appearance ───────────── */
.portal-draft-field select {
  width: 100%;
  border: 0;
  border-bottom: 2px solid rgba(15, 16, 18, 0.14);
  border-radius: 0;
  background: rgba(255, 255, 255, 0.84);
  color: var(--color-ink);
  font: inherit;
  padding: 0.9rem 2.5rem 0.9rem 1rem;
  appearance: none;
  cursor: pointer;
  background-image: url("data:image/svg+xml,%3Csvg width='10' height='6' fill='none' xmlns='http://www.w3.org/2000/svg'%3E%3Cpath d='M1 1l4 4 4-4' stroke='rgba(15%2C16%2C18%2C0.42)' stroke-width='1.6' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 1rem center;
  background-size: 0.625rem;
  transition: box-shadow var(--motion-fast);
}

.portal-draft-field select:focus {
  outline: none;
  box-shadow: inset 0 -2px 0 var(--color-ai);
}

/* ── Checkbox ───────────────────────────────────────────── */
.portfolio-submit-form__checkbox {
  display: inline-flex;
  align-items: center;
  gap: 0.65rem;
  font-size: 0.95rem;
}

/* ── Actions bar ────────────────────────────────────────── */
.portfolio-submit-form__inline-status {
  font-size: 0.82rem;
  line-height: 1.5;
  padding: 0.5rem 0.75rem;
  border-radius: 6px;
  margin-bottom: 0.5rem;
}
.portfolio-submit-form__inline-status[data-inline-state="error"] {
  background: #fff0f0;
  color: #b91c1c;
  border: 1px solid #fca5a5;
}
.portfolio-submit-form__inline-status[data-inline-state="loading"] {
  background: #f0f4ff;
  color: #1d4ed8;
  border: 1px solid #93c5fd;
}

.portfolio-submit-form__actions {
  justify-content: space-between;
  gap: 0.75rem;
  flex-wrap: wrap;
  padding-top: var(--space-5);
  border-top: 1px solid rgba(15, 16, 18, 0.07);
  margin-top: var(--space-2);
}

.portfolio-submit-form__secondary-actions {
  display: flex;
  gap: 0.75rem;
  flex-wrap: wrap;
}

/* ── JSON preview ───────────────────────────────────────── */
.portfolio-submit-form__response {
  margin-top: var(--space-4);
  white-space: pre-wrap;
  word-break: break-word;
  font-family: "Consolas", "Courier New", monospace;
  font-size: 0.76rem;
  line-height: 1.6;
  max-height: 38rem;
  overflow: auto;
  background: var(--color-editorial-band);
  border: 1px solid rgba(15, 16, 18, 0.08);
  border-radius: var(--radius-lg);
  padding: var(--space-5);
  color: rgba(15, 16, 18, 0.72);
}

.portfolio-submit-upload-list {
  display: grid;
  gap: 0.75rem;
}

.portfolio-submit-upload-item {
  padding: 0.9rem 1rem;
  border: 1px solid rgba(15, 16, 18, 0.08);
  border-radius: 1rem;
  background: rgba(255, 255, 255, 0.62);
}

.portfolio-submit-upload-item__title {
  margin-bottom: 0.3rem;
}

.portfolio-submit-form__notes {
  margin-top: var(--space-2);
}

.portfolio-submit-summary__grid {
  display: grid;
  gap: 0.9rem;
}

.portfolio-review-section {
  padding-bottom: var(--space-20);
  position: relative;
  z-index: 1;
  isolation: isolate;
}

/* Hero containment: suppress overflowing pseudo-element glows for the
   compact staff-simple hero so they don't bleed into the board below */
.portal-hero--staff-simple .portal-hero__content::before,
.portal-hero--staff-simple .portal-hero__content::after,
.portal-hero--student-simple .portal-hero__content::before,
.portal-hero--student-simple .portal-hero__content::after {
  display: none;
}

.portal-hero--staff-simple,
.portal-hero--student-simple {
  border-bottom: 1px solid rgba(15, 16, 18, 0.07);
}

.portfolio-review-board {
  margin-top: var(--space-10);
}

.portfolio-review-toolbar {
  display: flex;
  justify-content: space-between;
  align-items: end;
  gap: 1rem;
  flex-wrap: wrap;
}

.portfolio-review-toolbar__actions {
  display: flex;
  gap: 0.75rem;
  flex-wrap: wrap;
  align-items: center;
}

.portfolio-review-tabs {
  flex-wrap: wrap;
  gap: 0.4rem;
}

.portfolio-review-stats {
  margin-top: 1rem;
  margin-bottom: 1rem;
}

.portfolio-review-status {
  opacity: 0.55;
  font-size: 0.85rem;
}

.portfolio-review-list {
  display: grid;
  gap: 1rem;
}

.portfolio-review-empty,
.portfolio-review-notes {
  margin-top: 1rem;
}

.portfolio-review-session {
  display: grid;
  gap: 0.45rem;
}

.portfolio-review-stat-value {
  font-size: 1.75rem;
  margin: 0;
}

.portfolio-review-card {
  opacity: 0;
  animation: portal-fade-up 480ms cubic-bezier(0.2, 0.8, 0.2, 1) forwards;
}

.portfolio-review-card__header {
  display: grid;
  gap: 1rem;
}

.portfolio-review-card__meta {
  display: flex;
  align-items: center;
  gap: 0.4rem;
  flex-wrap: wrap;
  margin-bottom: 0.4rem;
}

.portfolio-review-card__title {
  font-size: 1.05rem;
  margin-bottom: 0.25rem;
}

.portfolio-review-card__summary {
  margin-top: 0.9rem;
}

.portfolio-review-card__grid {
  display: grid;
  gap: 0.9rem;
  margin-top: 1rem;
}

.portfolio-review-card__draft {
  margin-top: 1rem;
  padding-left: 1rem;
  border-left: 2px solid rgba(15, 16, 18, 0.12);
}

.portfolio-review-card__tags {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
  margin-top: 1rem;
}

.portfolio-review-card__actions {
  display: flex;
  gap: 0.75rem;
  flex-wrap: wrap;
  margin-top: 1rem;
}

.portfolio-review-card__image {
  width: 100%;
  max-height: 13rem;
  object-fit: cover;
  border-radius: 1rem;
  border: 1px solid rgba(15, 16, 18, 0.08);
}

/* ── Secondary-actions disclosure ──────────────────────── */
.portfolio-review-card__secondary-actions {
  position: relative;
}

.portfolio-review-card__secondary-actions > summary {
  list-style: none;
  cursor: pointer;
  user-select: none;
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  padding: 0.35rem 0.75rem;
  border-radius: var(--radius-sm, 0.5rem);
  border: 1px solid rgba(15, 16, 18, 0.14);
  background: rgba(255, 255, 255, 0.72);
  font-family: var(--font-label);
  font-size: 0.8rem;
  letter-spacing: 0.06em;
  color: rgba(15, 16, 18, 0.72);
  white-space: nowrap;
  transition: background 120ms, color 120ms;
}

.portfolio-review-card__secondary-actions > summary::-webkit-details-marker {
  display: none;
}

.portfolio-review-card__secondary-actions > summary::after {
  content: "▾";
  font-size: 0.7em;
  opacity: 0.6;
}

.portfolio-review-card__secondary-actions[open] > summary {
  background: rgba(15, 16, 18, 0.07);
  color: var(--color-ink);
}

.portfolio-review-card__secondary-menu {
  position: absolute;
  bottom: calc(100% + 6px);
  left: 0;
  z-index: 20;
  min-width: 12rem;
  background: #fff;
  border: 1px solid rgba(15, 16, 18, 0.1);
  border-radius: 0.75rem;
  box-shadow: 0 4px 16px rgba(15, 16, 18, 0.1), 0 1px 4px rgba(15, 16, 18, 0.06);
  padding: 0.4rem;
  display: flex;
  flex-direction: column;
  gap: 0.25rem;
}

.portfolio-review-card__secondary-menu > * {
  width: 100%;
  justify-content: flex-start;
  border-radius: 0.5rem;
}

.portfolio-detail-section {
  padding-bottom: var(--space-20);
}

.portfolio-detail-board {
  margin-top: var(--space-10);
}

.portfolio-detail-block {
  margin-top: 1rem;
}

.portfolio-detail-section-head {
  display: flex;
  justify-content: space-between;
  align-items: start;
  gap: 1rem;
  flex-wrap: wrap;
}

.portfolio-detail-header {
  display: grid;
  gap: 0.5rem;
}

.portfolio-detail-actions {
  display: flex;
  gap: 0.75rem;
  flex-wrap: wrap;
  margin-top: 1rem;
}

.portfolio-detail-actions--compact {
  margin-top: 0;
}

.portfolio-detail-note {
  display: grid;
  gap: 0.55rem;
  margin-top: 1rem;
}

.portfolio-detail-note__label {
  font-family: var(--font-label);
  letter-spacing: 0.08em;
  text-transform: uppercase;
  font-size: 0.78rem;
  color: rgba(15, 16, 18, 0.68);
}

.portfolio-detail-note__input {
  min-height: 7.5rem;
  border-radius: 1rem;
  border: 1px solid rgba(15, 16, 18, 0.12);
  background: rgba(255, 255, 255, 0.8);
  padding: 0.9rem 1rem;
  font: inherit;
  color: inherit;
  resize: vertical;
}

.portfolio-detail-grid {
  display: grid;
  gap: 1rem;
  margin-top: 1rem;
}

.portfolio-detail-grid__wide {
  grid-column: 1 / -1;
}

.portfolio-detail-output {
  display: grid;
  gap: 1rem;
}

.portfolio-detail-output__block {
  padding-left: 1rem;
  border-left: 2px solid rgba(15, 16, 18, 0.12);
}

.portfolio-detail-assets,
.portfolio-detail-jobs {
  display: grid;
  gap: 1rem;
}

.portfolio-detail-asset-card,
.portfolio-detail-job {
  border: 1px solid rgba(15, 16, 18, 0.08);
  border-radius: 1rem;
  padding: 1rem;
  background: rgba(255, 255, 255, 0.62);
}

/* ── Detail: enhanced asset grid ─────────────────────────────────────── */
.portfolio-detail-asset-grid {
  display: grid;
  gap: 1rem;
  grid-template-columns: 1fr;
}

.portfolio-detail-asset-card {
  display: grid;
  grid-template-columns: 1fr;
  gap: 1rem;
}

.portfolio-detail-asset-card--primary {
  border-color: var(--color-terracotta, #c0603e);
  border-width: 2px;
}

.portfolio-detail-asset-card__thumb {
  position: relative;
  background: rgba(15, 16, 18, 0.04);
  border-radius: 0.5rem;
  overflow: hidden;
}

.portfolio-detail-asset-card__thumb img {
  width: 100%;
  max-height: 14rem;
  object-fit: cover;
  display: block;
}

.portfolio-detail-asset-card__placeholder {
  height: 8rem;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 0.8rem;
  color: var(--editorial-muted);
}

.portfolio-detail-asset-card__badge {
  position: absolute;
  top: 0.5rem;
  left: 0.5rem;
  background: var(--color-terracotta, #c0603e);
  color: #fff;
  font-size: 0.7rem;
  font-weight: 700;
  padding: 2px 7px;
  border-radius: 999px;
}

.portfolio-detail-asset-card__meta {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.4rem;
  margin-bottom: 0.4rem;
}

.portfolio-detail-asset-card__body {
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
}

/* ── Detail: work-type block ──────────────────────────────────────────── */
.portfolio-detail-worktype-block {
  margin-top: 1.5rem;
  padding-top: 1rem;
  border-top: 1px solid rgba(15, 16, 18, 0.1);
}

@media (min-width: 760px) {
  .portfolio-submit-form__grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .portfolio-submit-summary__grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .portfolio-review-card__header {
    grid-template-columns: minmax(0, 1fr) 14rem;
    align-items: start;
  }

  .portfolio-review-card__grid {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }

  .portfolio-detail-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .portfolio-detail-asset-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .portfolio-detail-asset-card {
    grid-template-columns: 10rem minmax(0, 1fr);
    align-items: start;
  }

  .portfolio-detail-asset-card__thumb img {
    max-height: 100%;
    height: 100%;
    min-height: 8rem;
  }
}

.portal-brand-strip__mode {
  color: rgba(15, 16, 18, 0.52);
  font-family: var(--font-label);
  letter-spacing: 0.14em;
  text-transform: uppercase;
  font-size: 0.8rem;
}

.portal-brand-strip--light .portal-brand-strip__brand,
.portal-brand-strip--light .portal-brand-strip__mode,
.portal-greeting--light .portal-greeting__headline,
.portal-greeting--light .portal-greeting__body,
.portal-greeting--light .portal-greeting__eyebrow {
  color: var(--color-ink);
}

.portal-greeting {
  max-width: 60rem;
  margin: 0 auto var(--space-6);
  text-align: center;
}

.portal-greeting__eyebrow {
  margin: 0 0 var(--space-3);
  color: rgba(15, 16, 18, 0.42);
  font-family: var(--font-label);
  letter-spacing: 0.18em;
  text-transform: uppercase;
  font-size: 0.78rem;
}

.portal-greeting__headline {
  margin: 0;
  font-family: var(--font-display);
  font-size: clamp(2.8rem, 6.4vw, 5.9rem);
  line-height: 0.92;
  font-weight: 400;
  letter-spacing: -0.04em;
}

.portal-greeting__body {
  max-width: 42rem;
  margin: var(--space-4) auto 0;
  color: rgba(15, 16, 18, 0.58);
  font-size: clamp(1.05rem, 1.8vw, 1.45rem);
  line-height: 1.48;
  letter-spacing: -0.02em;
}

.portal-public-page {
  --side-nav-width: 13rem;
  --side-nav-clearance: calc(var(--side-nav-width) + clamp(0.75rem, 1.4vw, 1.25rem) + 0.5rem);
  background: var(--color-editorial-bg);
  color: var(--color-ink);
}

.portal-public-topbar {
  --site-topbar-scrolled-bg: rgba(255, 255, 255, 0.74);
  --site-topbar-scrolled-shadow: 0 12px 36px rgba(15, 16, 18, 0.035);
  --site-topbar-scrolled-blur: blur(18px);
}

.portal-public-sidenav {
  border-right-color: transparent;
  background: transparent;
}

.portal-public-main {
  width: 100%;
  background: var(--color-editorial-bg);
}

.portal-public-hero,
.portal-public-index,
.portal-public-why,
.portal-public-signals,
.portal-public-manifesto,
.portal-public-news,
.portal-public-faculty,
.portal-public-apply {
  padding: var(--space-editorial-section-y) var(--space-editorial-section-x);
}

.portal-public-hero {
  position: relative;
  display: grid;
  align-items: center;
  min-height: 92vh;
  overflow: hidden;
  background:
    linear-gradient(90deg, rgba(244, 243, 240, 0.88) 0%, rgba(244, 243, 240, 0.40) 44%, rgba(244, 243, 240, 0.10) 100%),
    var(--color-editorial-bg);
}

.portal-public-hero__media {
  position: absolute;
  inset: 0;
  opacity: 0.45;
  filter: grayscale(1) contrast(1.04);
}

.portal-public-hero__image {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: 60% top;
}

/* ── Student / Staff hero background image ─────────────── */
.portal-student-hero,
.portal-staff-hero {
  position: relative;
  overflow: hidden;
}

.portal-student-hero__content,
.portal-staff-hero__content {
  position: relative;
  z-index: 1;
}

.portal-student-hero__media,
.portal-staff-hero__media {
  position: absolute;
  inset: 0;
  opacity: 0.42;
  filter: grayscale(1) contrast(1.04);
  pointer-events: none;
}

.portal-student-hero__image,
.portal-staff-hero__image {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.portal-student-hero__image {
  object-position: 30% center;
}

.portal-staff-hero__image {
  object-position: 75% center;
}

.portal-public-hero__content,
.portal-public-shell {
  position: relative;
  z-index: 1;
  width: min(100%, 72rem);
}

.portal-public-hero__content {
  display: grid;
  gap: clamp(2.35rem, 5vw, 4.5rem);
}

.portal-public-kicker,
.portal-public-facts dt,
.portal-public-heading .portal-public-kicker,
.portal-route-list--index .portal-route-card__meta,
.portal-route-list--index .portal-route-card__eyebrow {
  color: var(--editorial-muted);
  font-family: var(--font-label);
  font-size: var(--type-label-sm);
  font-weight: 700;
  letter-spacing: var(--tracking-label);
  text-transform: uppercase;
}

.portal-public-kicker {
  display: block;
  margin-bottom: 1.9rem;
}

.portal-public-hero__title,
.portal-public-heading h2 {
  margin: 0;
  color: var(--color-primary);
  font-family: var(--font-display);
  font-weight: 500;
  letter-spacing: -0.072em;
}

.portal-public-hero__title {
  max-width: 11ch;
  font-size: clamp(3.4rem, 7.4vw, 6rem);
  line-height: 0.94;
}

.portal-public-hero__body,
.portal-public-heading p,
.portal-public-intro p,
.portal-public-intro__thai {
  color: rgba(15, 16, 18, 0.68);
  line-height: 1.82;
}

.portal-public-hero__body {
  max-width: 42rem;
  margin: 1.7rem 0 0;
  font-size: clamp(1.04rem, 1.6vw, 1.2rem);
}

.portal-public-intro {
  display: grid;
  gap: 0.95rem;
}

.portal-public-intro p,
.portal-public-intro__thai {
  margin: 0;
}

.portal-public-intro__thai {
  font-size: 0.98rem;
  color: rgba(15, 16, 18, 0.56);
}

.portal-public-facts {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  max-width: 46rem;
  margin: 2.55rem 0 0;
  border-top: 1px solid var(--editorial-line);
  border-left: 1px solid var(--editorial-line);
}

.portal-public-facts div {
  padding: 1rem 1.05rem;
  border-right: 1px solid var(--editorial-line);
  border-bottom: 1px solid var(--editorial-line);
}

.portal-public-facts dt {
  margin: 0 0 0.25rem;
  font-size: 0.68rem;
  letter-spacing: 0.14em;
}

.portal-public-facts dd {
  margin: 0;
  color: var(--color-primary);
  font-family: var(--font-display);
  font-size: 1.05rem;
}

.portal-public-hero__side {
  display: grid;
  gap: 1.75rem;
  align-content: start;
}

.portal-prompt-surface--public-ref {
  width: 100%;
  padding: 1.3rem 1.35rem;
  border: 1px solid var(--editorial-line);
  border-radius: 0;
  background: rgba(255, 255, 255, 0.58);
  box-shadow: none;
  backdrop-filter: none;
}

.portal-public-index,
.portal-public-faculty {
  background: var(--color-editorial-bg);
}

.portal-public-why,
.portal-public-signals,
.portal-public-news {
  background: var(--color-editorial-band);
}

.portal-public-manifesto {
  background: var(--color-editorial-panel);
}

.portal-public-apply {
  background: var(--color-editorial-panel);
}

.portal-public-shell {
  display: grid;
  gap: clamp(2.35rem, 5vw, 4.25rem);
}

.portal-public-heading {
  max-width: 58rem;
}

.portal-public-heading--split {
  display: grid;
  gap: 1.75rem;
  max-width: none;
}

.portal-public-heading h2 {
  font-size: clamp(2.2rem, 4.8vw, 3.15rem);
  line-height: 1.5;
}

.portal-public-heading p {
  max-width: 42rem;
  margin: 1.05rem 0 0;
  font-size: 1rem;
  line-height: 1.88;
}

.portal-public-heading--split > p {
  margin: 0;
}

.portal-route-list--index {
  margin-top: 0;
  border-top: 1px solid var(--editorial-line);
  display: grid;
  grid-template-columns: 1fr;
  gap: 0;
}

.portal-route-list--index .portal-route-card {
  position: relative;
  grid-template-columns: 3.2rem minmax(0, 1fr);
  gap: 0.9rem 1.25rem;
  align-items: baseline;
  padding: 1.5rem 0;
  border: 0;
  border-bottom: 1px solid var(--editorial-line);
  border-radius: 0;
  background: transparent;
  box-shadow: none;
}

.portal-route-list--index .portal-route-card:hover,
.portal-route-list--index .portal-route-card:focus-visible {
  border-color: transparent;
  background: transparent;
  box-shadow: none;
}

.portal-route-list--index .portal-route-card__meta {
  margin: 0;
}

.portal-route-list--index .portal-route-card__eyebrow {
  grid-column: 2;
  margin: 0;
}

.portal-route-list--index .portal-route-card__title {
  grid-column: 2;
  max-width: none;
  font-size: clamp(1.48rem, 3vw, 2.42rem);
  letter-spacing: -0.04em;
  line-height: 1.05;
}

.portal-route-list--index .portal-route-card__reason {
  grid-column: 2;
  margin: 0.1rem 0 0;
  max-width: 42rem;
  color: rgba(15, 16, 18, 0.64);
  line-height: 1.72;
}

.portal-route-list--index .portal-route-card__link {
  grid-column: 2;
  justify-self: end;
  margin-top: -2.45rem;
  color: var(--editorial-muted);
  font-family: var(--font-display);
  font-size: 1.4rem;
  letter-spacing: 0;
  text-transform: none;
}

.portal-route-list--index .portal-route-card__link::before {
  content: "+";
  font-size: 1.4rem;
  line-height: 1;
}

.portal-route-list--index .portal-route-card__link {
  font-size: 0;
}

.portal-public-signals__grid {
  display: grid;
  gap: 0;
  border-top: 1px solid var(--editorial-line);
  border-left: 1px solid var(--editorial-line);
  margin-bottom: clamp(1.6rem, 2.6vw, 2.4rem);
}

.portal-public-why__grid {
  grid-template-columns: 1fr;
}

.portal-public-panel--manifesto-standalone {
  min-height: auto;
}

.portal-public-panel--manifesto-standalone .portal-copy-statements {
  margin-top: 0.25rem;
}

/* Sidenav: fade out when works carousel is in view */
@media (min-width: 1024px) {
  .site-sidenav {
    transition: opacity 0.35s ease, visibility 0.35s;
  }

  .site-sidenav--carousel-hidden {
    opacity: 0;
    visibility: hidden;
    pointer-events: none;
  }
}

/* ── Works Carousel ─────────────────────────────────── */
.works-carousel {
  --carousel-gap: 0.75rem;
  position: relative;
  width: 100%;
}

/* Nav buttons */
.works-carousel__btn {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  z-index: 3;
  width: 2.5rem;
  height: 2.5rem;
  border-radius: 50%;
  border: 1px solid rgba(0, 0, 0, 0.14);
  background: rgba(255, 255, 255, 0.94);
  backdrop-filter: blur(4px);
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 2px 10px rgba(0, 0, 0, 0.12);
  transition: background 0.18s, box-shadow 0.18s, opacity 0.18s;
  padding: 0;
}

.works-carousel__btn .material-symbols-outlined {
  font-size: 1.2rem;
  color: #1a1a1a;
  line-height: 1;
}

.works-carousel__btn:hover {
  background: #fff;
  box-shadow: 0 4px 18px rgba(0, 0, 0, 0.18);
}

.works-carousel__btn:disabled {
  opacity: 0;
  pointer-events: none;
}

.works-carousel__btn--prev { left: 1rem; }
.works-carousel__btn--next { right: 1rem; }

/* Track */
.portal-work-grid {
  display: flex;
  gap: var(--carousel-gap);
  overflow-x: auto;
  scroll-snap-type: x mandatory;
  scroll-snap-stop: always;
  scroll-behavior: smooth;
  -webkit-overflow-scrolling: touch;
  scrollbar-width: none;
  padding: 0.125rem 0 0.75rem;
}

.portal-work-grid::-webkit-scrollbar {
  display: none;
}

/* Cards — 3 visible at a time, 4:3 aspect ratio */
.portal-work-card {
  position: relative;
  display: block;
  overflow: hidden;
  text-decoration: none;
  color: #fff;
  cursor: default;
  opacity: 0;
  flex: 0 0 50vw;
  aspect-ratio: 4 / 3;
  background: #1c1918;
  scroll-snap-align: center;
  border-radius: 3px;
}

.portal-work-card.is-center {
  cursor: pointer;
}

.portal-work-card--cap {
  pointer-events: none;
  color: rgba(255, 255, 255, 0.9);
  background:
    radial-gradient(circle at 18% 18%, rgba(255, 255, 255, 0.08), transparent 34%),
    linear-gradient(150deg, #111314 0%, #1b1f22 55%, #0f1112 100%);
  border: 1px solid rgba(255, 255, 255, 0.14);
}

.portal-work-card--cap::before {
  opacity: 0.95;
  background: linear-gradient(
    to top,
    rgba(0, 0, 0, 0.82) 0%,
    rgba(0, 0, 0, 0.56) 36%,
    rgba(0, 0, 0, 0.2) 74%,
    rgba(0, 0, 0, 0.08) 100%
  );
}

.portal-work-card--cap-start {
  border-radius: 3px 0 0 3px;
}

.portal-work-card--cap-end {
  border-radius: 0 3px 3px 0;
}

.portal-work-card__cap-topography {
  position: absolute;
  inset: 0;
  z-index: 0;
  overflow: hidden;
}

.portal-work-card__cap-topography span {
  position: absolute;
  inset: 12% 10%;
  border: 1px solid rgba(255, 255, 255, 0.18);
  border-radius: 44% 56% 52% 48% / 50% 43% 57% 50%;
  transform: rotate(-8deg) scale(1);
}

.portal-work-card__cap-topography span:nth-child(2) {
  inset: 22% 16%;
  transform: rotate(6deg) scale(0.88);
}

.portal-work-card__cap-topography span:nth-child(3) {
  inset: 31% 20%;
  transform: rotate(-4deg) scale(0.76);
}

.portal-work-card__cap-topography span:nth-child(4) {
  inset: 41% 26%;
  transform: rotate(9deg) scale(0.62);
}

.portal-work-card__cap-body {
  position: absolute;
  right: 0;
  bottom: 0;
  left: 0;
  z-index: 2;
  padding: clamp(0.9rem, 2.2vw, 1.4rem);
  display: flex;
  flex-direction: column;
  gap: 0.2rem;
}

.portal-work-card--cap .portal-work-card__type,
.portal-work-card--cap .portal-work-card__title {
  opacity: 1;
  transform: none;
}

.portal-work-card--cap .portal-work-card__type {
  color: rgba(255, 255, 255, 0.66);
}

.portal-work-card--cap .portal-work-card__title {
  font-size: clamp(0.82rem, 1.45vw, 1rem);
  color: rgba(255, 255, 255, 0.92);
}

.portal-work-card::before {
  content: "";
  position: absolute;
  inset: 0;
  z-index: 1;
  pointer-events: none;
  background: linear-gradient(
    to top,
    rgba(0, 0, 0, 0.78) 0%,
    rgba(0, 0, 0, 0.42) 34%,
    rgba(0, 0, 0, 0.16) 68%,
    rgba(0, 0, 0, 0.04) 100%
  );
  opacity: 0.72;
  transition: opacity 0.35s ease;
}

.portal-work-card:is(:hover, :focus-visible)::before {
  opacity: 0.92;
}

/* Fallback gradient backgrounds (no image) */
.portal-work-card:nth-child(1) { --work-bg: linear-gradient(145deg, #1d1a16 0%, #2c2118 100%); }
.portal-work-card:nth-child(2) { --work-bg: linear-gradient(145deg, #141d26 0%, #1c2a38 100%); }
.portal-work-card:nth-child(3) { --work-bg: linear-gradient(145deg, #131d14 0%, #1a2818 100%); }
.portal-work-card:nth-child(4) { --work-bg: linear-gradient(145deg, #1a1624 0%, #271e38 100%); }
.portal-work-card:nth-child(5) { --work-bg: linear-gradient(145deg, #1a1616 0%, #2e1c1c 100%); }
.portal-work-card:nth-child(6) { --work-bg: linear-gradient(145deg, #121a1d 0%, #18262a 100%); }

.portal-work-card--no-image {
  background: var(--work-bg, linear-gradient(145deg, #1c1918, #2a2018));
}

.portal-work-card__media {
  position: absolute;
  inset: 0;
  z-index: 0;
}

.portal-work-card__img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transform: scale(1.05);
  transition: transform 0.9s cubic-bezier(0.25, 0.46, 0.45, 0.94), opacity 0.5s, filter 0.35s ease;
  opacity: 0.88;
  filter: saturate(1);
}

.portal-work-card:is(:hover, :focus-visible) .portal-work-card__img {
  transform: scale(1.0);
  opacity: 0.98;
  filter: grayscale(1) contrast(1.03) brightness(0.76);
}

/* Body — pinned to bottom */
.portal-work-card__body {
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  z-index: 2;
  padding: clamp(0.9rem, 2.2vw, 1.4rem);
  display: flex;
  flex-direction: column;
  gap: 0.18rem;
}

/* Tag — always visible */
.portal-work-card__type {
  font-size: 0.6rem;
  font-weight: 700;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: rgba(255, 255, 255, 0.60);
  margin-bottom: 0.12rem;
  transition: color 0.3s;
}

.portal-work-card:is(:hover, :focus-visible) .portal-work-card__type {
  color: rgba(255, 255, 255, 0.80);
}

/* Title — hidden until hover (fritz-kola style: slides up) */
.portal-work-card__title {
  font-size: clamp(0.85rem, 1.6vw, 1.1rem);
  font-weight: 600;
  color: #fff;
  line-height: 1.25;
  margin: 0;
  opacity: 0;
  transform: translateY(0.55rem);
  transition: opacity 0.38s cubic-bezier(0.25, 0.46, 0.45, 0.94),
              transform 0.38s cubic-bezier(0.25, 0.46, 0.45, 0.94);
}

.portal-work-card:is(:hover, :focus-visible) .portal-work-card__title {
  opacity: 1;
  transform: translateY(0);
}

/* Description — hidden, appears after title on hover */
.portal-work-card__desc {
  font-size: 0.75rem;
  color: rgba(255, 255, 255, 0.65);
  line-height: 1.42;
  max-width: 32ch;
  margin-top: 0.15rem;
  opacity: 0;
  transform: translateY(0.35rem);
  transition: opacity 0.32s 0.08s, transform 0.36s 0.08s;
}

.portal-work-card:is(:hover, :focus-visible) .portal-work-card__desc {
  opacity: 1;
  transform: translateY(0);
}

/* Arrow link */
.portal-work-card__link {
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
  margin-top: 0.4rem;
  font-size: 0.72rem;
  font-weight: 600;
  letter-spacing: 0.04em;
  color: rgba(255, 255, 255, 0.60);
  opacity: 0;
  transform: translateX(-0.4rem);
  transition: opacity 0.28s 0.12s, transform 0.32s 0.12s, color 0.2s;
}

.portal-work-card:is(:hover, :focus-visible) .portal-work-card__link {
  opacity: 1;
  transform: translateX(0);
  color: #fff;
}

/* Reveal animation */
@keyframes work-card-in {
  from {
    opacity: 0;
    transform: translateY(1.5rem);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.portal-work-card.is-revealed {
  animation: work-card-in 0.65s cubic-bezier(0.22, 1, 0.36, 1) both;
  animation-delay: calc(var(--stagger-index, 0) * 0.10s);
}

/* Mobile: 1 card + peek of next */
@media (max-width: 639px) {
  .portal-work-card {
    flex: 0 0 80vw;
  }
}

/* Reduced motion */
@media (prefers-reduced-motion: reduce) {
  .portal-work-card { opacity: 1; }
  .portal-work-card.is-revealed { animation: none; }
  .portal-work-card__img { transform: none !important; }
  .portal-work-card__title { opacity: 1; transform: none !important; }
  .portal-work-card__desc,
  .portal-work-card__link { opacity: 1; transform: none !important; }
}

/* ── Event cards (B4) ───────────────────────────────── */
.portal-event-cards {
  display: grid;
  gap: 0;
  grid-template-columns: repeat(auto-fill, minmax(min(100%, 22rem), 1fr));
  border-top: 1px solid var(--editorial-line);
  border-left: 1px solid var(--editorial-line);
}

.portal-event-card {
  display: grid;
  grid-template-columns: 4.5rem 1fr;
  gap: 0;
  min-height: 7rem;
  border-right: 1px solid var(--editorial-line);
  border-bottom: 1px solid var(--editorial-line);
  text-decoration: none;
  color: inherit;
  transition: background 0.15s;
}

.portal-event-card:hover {
  background: color-mix(in srgb, var(--color-accent-primary, #2e62c7) 4%, white);
}

.portal-event-card__date {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 0.75rem 0.5rem;
  background: var(--color-accent-primary, #2e62c7);
  color: #fff;
  text-align: center;
  line-height: 1.1;
}

.portal-event-card__date-day {
  font-size: 1.75rem;
  font-weight: 700;
  letter-spacing: -0.02em;
}

.portal-event-card__date-month {
  font-size: 0.65rem;
  font-weight: 600;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  opacity: 0.88;
}

.portal-event-card__body {
  padding: 0.875rem 1rem;
  display: flex;
  flex-direction: column;
  gap: 0.25rem;
}

.portal-event-card__type {
  font-size: 0.65rem;
  font-weight: 700;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--color-text-secondary, #666);
}

.portal-event-card__title {
  font-size: 0.9375rem;
  font-weight: 600;
  line-height: 1.3;
  color: var(--color-text-primary, #1a1a1a);
}

.portal-event-card__meta {
  font-size: 0.8rem;
  color: var(--color-text-secondary, #666);
  margin-top: auto;
}

.portal-event-cards--empty {
  display: none;
}

/* ── Portal nav dropdown (mode switcher) ─────────── */
.topbar-item {
  position: relative;
}

.topbar-item--has-submenu > .topbar-link {
  display: inline-flex;
  align-items: center;
  gap: 0.2rem;
}

.topbar-item--has-submenu > .topbar-link::before {
  content: "";
  position: absolute;
  bottom: -0.5rem;
  left: 50%;
  translate: -50% 0;
  width: 1px;
  height: 0.5rem;
}

.portal-mode-dropdown {
  position: absolute;
  top: calc(100% + 0.5rem);
  left: 50%;
  translate: -50% 0;
  z-index: 200;
  background: var(--color-paper, #fffdf8);
  border: 1px solid var(--color-border);
  border-radius: 0;
  box-shadow: var(--shadow-panel);
  padding: 0.35rem;
  min-width: 13rem;
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
  transform: translateY(-6px);
  transition: opacity 0.18s ease, transform 0.18s ease, visibility 0s linear 0.18s;
}

.topbar-item--has-submenu:hover .portal-mode-dropdown,
.topbar-item--has-submenu:focus-within .portal-mode-dropdown {
  opacity: 1;
  visibility: visible;
  pointer-events: auto;
  transform: translateY(0);
  transition: opacity 0.18s ease, transform 0.18s ease;
}

.portal-mode-dropdown__label {
  font-size: 0.55rem;
  font-weight: 700;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--color-stone-dark);
  padding: 0.2rem 0.65rem 0.3rem;
}

.portal-mode-switcher__nav {
  display: flex;
  flex-direction: column;
  gap: 0;
}

.portal-mode-switch {
  display: flex;
  align-items: center;
  gap: 0.65rem;
  padding: 0.45rem 0.7rem;
  border-radius: 0;
  text-decoration: none;
  font-size: 0.7rem;
  font-weight: 600;
  letter-spacing: 0.05em;
  text-transform: uppercase;
  color: var(--color-stone-ink);
  transition: background 0.13s, color 0.13s;
  white-space: nowrap;
}

.portal-mode-switch .material-symbols-outlined {
  font-size: 1.05rem;
  line-height: 1;
  flex-shrink: 0;
  width: 1.6rem;
  height: 1.6rem;
  border-radius: 0;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  background: var(--color-stone, #e4e2de);
  color: var(--color-stone-ink);
  transition: background 0.13s, color 0.13s;
}

.portal-mode-switch:hover {
  background: var(--color-primary-soft);
  color: var(--color-ink);
}

.portal-mode-switch:hover .material-symbols-outlined {
  background: var(--color-ink);
  color: var(--color-white);
}

.portal-mode-switch[aria-current="page"] {
  background: var(--color-primary-soft);
  color: var(--color-ink);
  font-weight: 700;
}

.portal-mode-switch[aria-current="page"] .material-symbols-outlined {
  background: var(--color-ink);
  color: var(--color-white);
}

.portal-public-panel,
.portal-feature-grid--public-grid .portal-card,
.portal-faculty-strip--public-grid .portal-card,
.portal-story-rail .portal-story-card {
  border-radius: 0;
  background: rgba(255, 255, 255, 0.4);
  box-shadow: none;
}

.portal-public-panel {
  padding: clamp(1.45rem, 2.6vw, 2.15rem);
  border-right: 1px solid var(--editorial-line);
  border-bottom: 1px solid var(--editorial-line);
}

.portal-public-panel--manifesto,
.portal-public-panel--news {
  min-height: 100%;
}

/* News widget styles moved to ./pages/portal/news-widget.css */

.portal-breakout-panel--story::after {
  display: none;
}

.portal-feature-grid--public-grid,
.portal-faculty-strip--public-grid {
  gap: 0;
  border-top: 1px solid var(--editorial-line);
  border-left: 1px solid var(--editorial-line);
}

.portal-feature-grid--public-grid .portal-card,
.portal-faculty-strip--public-grid .portal-card {
  min-height: 16rem;
  padding: clamp(1.45rem, 2.55vw, 2.1rem);
  border-right: 1px solid var(--editorial-line);
  border-bottom: 1px solid var(--editorial-line);
}

.portal-feature-grid--public-grid .portal-card:hover,
.portal-faculty-strip--public-grid .portal-card:hover,
.portal-story-rail .portal-story-card:hover {
  background: rgba(255, 255, 255, 0.7);
  box-shadow: none;
}

.portal-feature-grid--public-grid .portal-card:nth-child(2),
.portal-feature-grid--public-grid .portal-card:nth-child(3),
.portal-faculty-strip--public-grid .portal-card:nth-child(2) {
  transform: none;
}

.portal-story-rail .portal-story-card {
  padding: 1.2rem 0;
  border: 0;
  border-bottom: 1px solid var(--editorial-line);
}

.portal-story-rail .portal-story-card:last-child {
  border-bottom: 0;
}

.portal-story-card--lead,
.portal-card--lead {
  transform: none;
}

.portal-public-next-strip {
  display: grid;
  gap: 1.15rem;
  align-items: center;
  padding-top: 1.5rem;
  border-top: 1px solid var(--editorial-line);
}

.portal-public-next-strip p {
  margin: 0;
  color: rgba(15, 16, 18, 0.66);
}

.portal-public-footer {
  padding-left: max(1.5rem, env(safe-area-inset-left));
  padding-right: 1.5rem;
}

.portal-public-page .portal-action-button,
.portal-public-page .portal-secondary-button-lite,
.portal-public-page .portal-prompt-surface__submit,
.portal-public-page .portal-prompt-surface--public-ref,
.portal-public-page .portal-prompt-surface__reply,
.portal-public-page .portal-prompt-surface__chips button {
  border-radius: 0;
}

.portal-entry-page {
  background: var(--color-editorial-bg);
  color: var(--color-ink);
}

.portal-entry-page .portal-shell--selector {
  background:
    radial-gradient(circle at 50% 14%, rgba(255, 255, 255, 0.98), rgba(255, 255, 255, 0) 18%),
    linear-gradient(180deg, #f8f7f4 0%, #f3f1ed 58%, #ece9e3 100%);
}

.portal-entry-page .portal-hero__image {
  opacity: 0.68;
  filter: grayscale(1) saturate(0) contrast(1.06);
}

@media (prefers-reduced-motion: reduce) {
  .portal-hero__image {
    transform: none;
  }
}

.portal-entry-page .portal-hero__overlay,
.portal-entry-page .portal-hero__media--selector .portal-hero__overlay {
  z-index: 1;
  background:
    radial-gradient(circle at 50% 36%, rgba(255, 255, 255, 0.16), rgba(255, 255, 255, 0) 26%),
    linear-gradient(180deg, rgba(248, 247, 244, 0.06) 0%, rgba(243, 241, 237, 0.18) 44%, rgba(243, 241, 237, 0.52) 68%, rgba(243, 241, 237, 0.78) 88%, rgba(243, 241, 237, 1) 100%);
}

.portal-entry-page .portal-hero__content::before,
.portal-entry-page .portal-hero__content::after {
  display: none;
}

.portal-entry-page .portal-brand-strip {
  margin-bottom: var(--space-8);
}

.portal-entry-page .portal-brand-strip__mode {
  color: rgba(15, 16, 18, 0.52);
  letter-spacing: 0.16em;
}

.portal-entry-page .portal-selector-stack {
  width: min(100%, 72rem);
  gap: clamp(1.5rem, 2.4vw, 2.5rem);
  align-content: center;
  align-self: center;
  padding-top: 0;
}

.portal-entry-split {
  display: grid;
  grid-template-columns: minmax(0, 0.94fr) minmax(21rem, 0.86fr);
  align-items: center;
}

.portal-entry-copy {
  min-width: 0;
}

.portal-entry-page .portal-greeting {
  max-width: 34rem;
  text-align: left;
  margin-bottom: 0;
}

.portal-entry-page .portal-entry-mode-mark {
  margin: 0 0 1.2rem;
  color: rgba(15, 16, 18, 0.42);
  font-family: var(--font-label);
  font-size: 0.78rem;
  font-weight: 700;
  letter-spacing: 0.16em;
  text-transform: uppercase;
}

.portal-entry-page .portal-greeting__eyebrow {
  color: var(--editorial-muted);
  margin-bottom: 0.8rem;
  letter-spacing: var(--tracking-label);
}

.portal-entry-page .portal-greeting__headline {
  max-width: 9ch;
  font-size: clamp(3rem, 5.4vw, 4.6rem);
  line-height: 0.98;
  font-weight: 500;
  letter-spacing: -0.07em;
  color: var(--color-primary);
}

.portal-entry-page .portal-greeting__body {
  max-width: 30rem;
  margin-top: 1rem;
  color: rgba(15, 16, 18, 0.68);
  font-size: clamp(1rem, 1.35vw, 1.08rem);
  line-height: 1.72;
}

.portal-entry-page .portal-entry-mode-hint {
  margin: 1.05rem 0 0;
  color: rgba(15, 16, 18, 0.48);
  font-family: var(--font-label);
  font-size: 0.74rem;
  font-weight: 700;
  letter-spacing: 0.12em;
  line-height: 1.5;
  text-transform: uppercase;
}

.portal-entry-ai-panel {
  width: 100%;
  margin: 0;
  padding: 1.25rem 1.25rem 1.1rem;
  border: 1px solid var(--editorial-line);
  border-radius: 0;
  background: rgba(255, 255, 255, 0.74);
  box-shadow: none;
}

.portal-entry-ai-panel__head {
  margin-bottom: 1rem;
}

.portal-entry-ai-panel__label {
  margin: 0 0 0.45rem;
  color: var(--editorial-muted);
  font-family: var(--font-label);
  font-size: 0.7rem;
  font-weight: 700;
  letter-spacing: 0.16em;
  text-transform: uppercase;
}

.portal-entry-ai-panel__title {
  margin: 0;
  color: var(--color-primary);
  font-family: var(--font-display);
  font-size: clamp(1.5rem, 2.4vw, 2.15rem);
  font-weight: 500;
  letter-spacing: -0.04em;
  line-height: 1.04;
}

.portal-entry-ai-panel__body {
  margin: 0.75rem 0 0;
  color: rgba(15, 16, 18, 0.62);
  font-size: 0.96rem;
  line-height: 1.7;
}

.portal-entry-page .portal-entry-desktop-details {
  width: 100%;
}

.portal-entry-page .portal-selector-details {
  width: 100%;
  margin: 0 0 var(--space-2);
  gap: 0;
  border-top: 1px solid var(--editorial-line);
  border-left: 1px solid var(--editorial-line);
}

.portal-entry-page .portal-selector-detail {
  padding: 1rem 1.1rem 1.15rem;
  border-right: 1px solid var(--editorial-line);
  border-bottom: 1px solid var(--editorial-line);
}

.portal-entry-page .portal-selector-detail__label {
  color: var(--editorial-muted);
  font-size: 0.7rem;
  letter-spacing: 0.14em;
}

.portal-entry-page .portal-selector-detail__value {
  margin-top: 0.45rem;
  color: var(--color-primary);
  font-family: var(--font-display);
  font-size: 1rem;
  line-height: 1.42;
}

.portal-entry-page .portal-prompt-surface--selector {
  width: 100%;
  margin: 0;
  padding: 0;
  border: 0;
  border-radius: 0;
  background: transparent;
  box-shadow: none;
  -webkit-backdrop-filter: none;
  backdrop-filter: none;
}

.portal-entry-page .portal-entry-desktop-details,
.portal-entry-page .portal-entry-personas {
  display: none;
}

.portal-entry-page .portal-prompt-surface__field {
  border: 1px solid var(--editorial-line);
  border-bottom-width: 1px;
  border-radius: 0;
  background: rgba(255, 255, 255, 0.72);
  box-shadow: none;
}

.portal-entry-page .portal-prompt-surface__submit,
.portal-entry-page .portal-prompt-surface__reply,
.portal-entry-page .portal-prompt-surface__chips button {
  border-radius: 0;
}

.portal-entry-page .portal-prompt-surface__chips {
  margin-top: 0.85rem;
  gap: 0.55rem;
}

.portal-entry-page .portal-prompt-surface__chips button {
  background: transparent;
  border-color: var(--editorial-line);
}

.portal-entry-page .portal-prompt-surface__reply {
  margin-top: 0.9rem;
  padding-top: 0;
  border-top: 0;
  color: rgba(15, 16, 18, 0.56);
  font-size: 0.92rem;
}

.portal-staff-page,
.portal-student-page {
  --side-nav-width: 13rem;
  --side-nav-clearance: calc(var(--side-nav-width) + clamp(0.75rem, 1.4vw, 1.25rem) + 0.5rem);
  background: var(--color-editorial-bg);
  color: var(--color-ink);
}

.portal-staff-topbar,
.portal-student-topbar {
  --site-topbar-scrolled-bg: rgba(255, 255, 255, 0.74);
  --site-topbar-scrolled-shadow: 0 12px 36px rgba(15, 16, 18, 0.035);
  --site-topbar-scrolled-blur: blur(18px);
}

.portal-staff-sidenav,
.portal-student-sidenav {
  border-right-color: transparent;
  background: transparent;
}

.portal-staff-main,
.portal-student-main {
  width: 100%;
  background: var(--color-editorial-bg);
}

.portal-staff-quickbar {
  padding-block: 0.6rem;
  background: var(--color-editorial-bg, #f4f3f0);
  border-block: 1px solid color-mix(in srgb, currentColor 10%, transparent);
}

.portal-staff-quickbar__inner {
  display: flex;
  align-items: center;
  gap: 1rem;
  flex-wrap: wrap;
}

.portal-staff-quickbar__label {
  font-size: 0.7rem;
  font-weight: 700;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--color-text-secondary, #666);
  white-space: nowrap;
}

.portal-staff-quickbar__actions {
  display: flex;
  gap: 0.5rem;
  flex-wrap: wrap;
}

.portal-staff-quickbar__btn {
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
  font-size: 0.8125rem;
  font-weight: 500;
  padding: 0.35em 0.75em;
  border-radius: 4px;
  border: 1px solid color-mix(in srgb, currentColor 20%, transparent);
  color: var(--color-text-primary, #1a1a1a);
  text-decoration: none;
  transition: background 0.15s, border-color 0.15s;
}

.portal-staff-quickbar__btn:hover {
  background: color-mix(in srgb, currentColor 6%, transparent);
  border-color: color-mix(in srgb, currentColor 30%, transparent);
}

.portal-staff-quickbar__btn .material-symbols-outlined {
  font-size: 1rem;
  line-height: 1;
}

.portal-staff-hero,
.portal-staff-quickbar,
.portal-staff-routes,
.portal-staff-command,
.portal-staff-records,
.portal-staff-signals,
.portal-public-feed,
.portal-student-hero,
.portal-student-announcements,
.portal-student-paths,
.portal-student-status,
.portal-student-workflow {
  padding: var(--space-editorial-section-y) var(--space-editorial-section-x);
}

/* Feed section: full-width carousel — no horizontal padding on section */
.portal-public-feed,
.portal-student-feed {
  padding-block: var(--space-editorial-section-y);
  overflow: hidden;
}

/* Heading inside feed stays within shell padding */
.portal-public-feed__head,
.portal-student-feed__head {
  padding-inline: var(--space-editorial-section-x);
  margin-bottom: clamp(1.5rem, 3vw, 2.5rem);
}

/* Feed kicker: editorial floating label above carousel */
.portal-public-feed__kicker {
  padding-inline: var(--space-editorial-section-x);
  margin-bottom: clamp(0.875rem, 1.5vw, 1.25rem);
  font-size: 0.6875rem;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--color-text-secondary);
}

/* Desktop: override sidenav clearance so feed is true 100vw */
@media (min-width: 1024px) {
  .page-shell--with-sidenav .page-main > .portal-public-feed,
  .page-shell--with-sidenav .page-main > .portal-student-feed {
    padding-inline: 0;
  }

  .portal-public-feed__head,
  .portal-student-feed__head {
    padding-left: max(var(--side-nav-clearance, 22rem), env(safe-area-inset-left));
    padding-right: clamp(1.25rem, 4vw, 3rem);
  }

  .portal-public-feed__kicker {
    padding-left: max(var(--side-nav-clearance, 22rem), env(safe-area-inset-left));
    padding-right: clamp(1.25rem, 4vw, 3rem);
  }
}

.portal-student-announcements {
  padding-block: 0.75rem;
  background: color-mix(in srgb, var(--color-accent-primary, #2e62c7) 8%, transparent);
  border-block: 1px solid color-mix(in srgb, var(--color-accent-primary, #2e62c7) 18%, transparent);
}

.portal-student-announcements__list {
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
}

.portal-student-announcement {
  display: flex;
  align-items: baseline;
  gap: 0.75rem;
  font-size: 0.875rem;
  line-height: 1.4;
}

.portal-student-announcement__badge {
  flex-shrink: 0;
  font-size: 0.7rem;
  font-weight: 700;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: var(--color-accent-primary, #2e62c7);
  background: color-mix(in srgb, var(--color-accent-primary, #2e62c7) 12%, white);
  padding: 0.1em 0.45em;
  border-radius: 3px;
}

.portal-student-announcement__title {
  font-weight: 500;
  color: var(--color-text-primary, #1a1a1a);
}

.portal-student-announcement__date {
  margin-left: auto;
  flex-shrink: 0;
  font-size: 0.75rem;
  color: var(--color-text-secondary, #555);
}

.portal-staff-hero,
.portal-student-hero {
  position: relative;
  overflow: hidden;
}

.portal-staff-hero {
  background:
    linear-gradient(90deg, rgba(244, 243, 240, 0.90) 0%, rgba(244, 243, 240, 0.44) 52%, rgba(244, 243, 240, 0.14) 100%),
    var(--color-editorial-bg);
}

.portal-student-hero {
  background:
    linear-gradient(90deg, rgba(244, 243, 240, 0.88) 0%, rgba(244, 243, 240, 0.40) 46%, rgba(244, 243, 240, 0.12) 100%),
    var(--color-editorial-bg);
}

.portal-staff-command,
.portal-student-workflow {
  background: var(--color-editorial-band);
}

.portal-staff-signals,
.portal-student-feed {
  background: var(--color-editorial-panel);
}

.portal-staff-shell,
.portal-student-shell {
  position: relative;
  z-index: 1;
  display: grid;
  gap: clamp(2.35rem, 5vw, 4.25rem);
  width: min(100%, 72rem);
}

.portal-staff-hero__content,
.portal-student-hero__content {
  display: grid;
  gap: clamp(2.35rem, 5vw, 4.5rem);
}

.portal-staff-hero__title,
.portal-student-hero__title {
  max-width: 10.5ch;
}

.portal-staff-hero__body,
.portal-student-hero__body {
  max-width: 41rem;
}

.portal-staff-hero__side,
.portal-student-hero__side {
  display: grid;
  gap: 1.4rem;
  align-content: start;
}

.portal-staff-note {
  padding: 1rem 0 0;
  border-top: 1px solid var(--editorial-line);
}

.portal-staff-note p {
  margin: 0;
  color: rgba(15, 16, 18, 0.66);
  line-height: 1.76;
}

.portal-staff-stat-grid {
  gap: 0;
  border-top: 1px solid var(--editorial-line);
  border-left: 1px solid var(--editorial-line);
}

.portal-staff-stat-grid .portal-stat-card,
.portal-student-summary--editorial .portal-student-stat {
  min-height: 100%;
  padding: 1.1rem 1.15rem 1.25rem;
  border-radius: 0;
  border-right: 1px solid var(--editorial-line);
  border-bottom: 1px solid var(--editorial-line);
  background: rgba(255, 255, 255, 0.38);
  box-shadow: none;
}

.portal-staff-stat-grid .portal-panel__title,
.portal-student-summary--editorial .portal-panel__title {
  font-size: clamp(1.7rem, 2.7vw, 2.2rem);
  line-height: 0.98;
}

.portal-staff-command__grid,
.portal-staff-records__grid,
.portal-staff-signals__grid {
  display: grid;
  gap: 0;
  border-top: 1px solid var(--editorial-line);
  border-left: 1px solid var(--editorial-line);
}

.portal-public-panel--staff,
.portal-public-panel--student,
.portal-feature-grid--student-feed .portal-card,
.portal-breakout-panel--flat {
  border-radius: 0;
  background: rgba(255, 255, 255, 0.34);
  box-shadow: none;
}

.portal-public-panel--staff,
.portal-public-panel--student,
.portal-breakout-panel--flat {
  min-height: 100%;
  padding: clamp(1.45rem, 2.6vw, 2.15rem);
  border-right: 1px solid var(--editorial-line);
  border-bottom: 1px solid var(--editorial-line);
}

.portal-breakout-panel--flat::after {
  display: none;
}

.portal-review-grid--staff {
  gap: 0;
}

.portal-review-grid--staff .portal-review-ticket {
  border-radius: 0;
  background: rgba(255, 255, 255, 0.46);
  box-shadow: none;
}

.portal-student-workflow-callout {
  display: grid;
  gap: 0.9rem;
  max-width: 34rem;
  margin-top: 2.5rem;
}

.portal-student-summary--editorial {
  gap: 0;
  border-top: 1px solid var(--editorial-line);
  border-left: 1px solid var(--editorial-line);
}

.portal-student-grid--editorial,
.portal-feature-grid--student-feed {
  gap: 0;
  border-top: 1px solid var(--editorial-line);
  border-left: 1px solid var(--editorial-line);
  margin: 0;
}

.portal-feature-grid--student-feed .portal-card {
  min-height: 15rem;
  padding: clamp(1.45rem, 2.55vw, 2.1rem);
  border-right: 1px solid var(--editorial-line);
  border-bottom: 1px solid var(--editorial-line);
}

.portal-student-grid--editorial .portal-public-panel--student .portal-chip-row {
  margin-top: 1.35rem;
}

.portal-student-page .portal-primary-workflow-cta,
.portal-staff-page .portal-action-button,
.portal-staff-page .portal-secondary-button-lite,
.portal-staff-page .portal-prompt-surface__submit,
.portal-student-page .portal-secondary-button-lite,
.portal-student-page .portal-prompt-surface__submit,
.portal-student-page .portal-prompt-surface__reply,
.portal-staff-page .portal-prompt-surface__reply,
.portal-student-page .portal-prompt-surface__chips button,
.portal-staff-page .portal-prompt-surface__chips button {
  border-radius: 0;
}

.portal-staff-page .portal-primary-workflow-cta,
.portal-student-page .portal-primary-workflow-cta {
  box-shadow: none;
}

.portal-selector-details {
  display: grid;
  gap: var(--space-4);
  grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
  width: min(100%, 62rem);
  margin: 0 auto var(--space-7);
}

.portal-selector-detail {
  padding-top: var(--space-4);
  border-top: 1px solid rgba(15, 16, 18, 0.12);
}

.portal-selector-detail__label,
.portal-mode-card__meta,
.portal-route-card__meta,
.portal-card__meta,
.portal-story-card__meta {
  margin: 0;
  color: rgba(15, 16, 18, 0.38);
  font-family: var(--font-label);
  font-size: 0.72rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}

.portal-selector-detail__value {
  margin: var(--space-2) 0 0;
  color: rgba(15, 16, 18, 0.76);
  font-size: 0.92rem;
  line-height: 1.6;
}

.portal-prompt-surface {
  width: min(100%, 54rem);
  padding: 1.35rem 1.4rem;
  border: 1px solid var(--color-border);
  border-radius: var(--radius-2xl);
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.82), rgba(247, 244, 238, 0.64)),
    var(--color-surface-glass);
  box-shadow: var(--shadow-lifted);
  -webkit-backdrop-filter: blur(24px);
  backdrop-filter: blur(24px);
}

.portal-prompt-surface--light {
  border-color: var(--color-border);
  background: rgba(255, 255, 255, 0.68);
}

.portal-prompt-surface--selector {
  width: min(100%, 43rem);
  margin: 0 auto;
  position: relative;
  overflow: visible;
}

.portal-hero--selector .portal-prompt-surface--selector {
  margin-top: var(--space-6);
}

.portal-prompt-surface__field {
  display: grid;
  grid-template-columns: auto 1fr auto;
  gap: var(--space-4);
  align-items: center;
  padding: 0.85rem 1rem;
  border: 1px solid rgba(17, 18, 20, 0.08);
  border-bottom: 2px solid rgba(17, 18, 20, 0.16);
  border-radius: var(--radius-lg);
  background: rgba(255, 255, 255, 0.84);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.72);
}

.portal-prompt-surface--light .portal-prompt-surface__field {
  background: rgba(255, 255, 255, 0.9);
}

.portal-prompt-surface__icon {
  color: var(--color-ai);
  font-family: var(--font-label);
  font-weight: 700;
  letter-spacing: 0.12em;
}

.portal-prompt-surface__input {
  border: 0;
  background: transparent;
  color: var(--color-ink);
  outline: 0;
  font-size: 1rem;
}

.portal-prompt-surface__input:focus {
  box-shadow: inset 0 -2px 0 var(--color-ai);
}

.portal-prompt-surface__submit {
  padding: 0.82rem 1.1rem;
  border-radius: 999px;
  background: linear-gradient(135deg, #0f1012 0%, #4b4c50 100%);
  color: var(--color-white);
  font-family: var(--font-label);
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  box-shadow: 0 12px 26px rgba(15, 16, 18, 0.16);
  transition: transform var(--motion-fast), box-shadow var(--motion-fast), background var(--motion-fast);
}

.portal-prompt-surface__submit:hover,
.portal-prompt-surface__submit:focus-visible {
  transform: translateY(-1px);
  box-shadow: 0 16px 34px rgba(15, 16, 18, 0.2);
}

.portal-prompt-surface--light .portal-prompt-surface__submit {
  background: linear-gradient(135deg, #0f1012 0%, #4b4c50 100%);
}

.portal-prompt-surface__chips,
.portal-chip-row {
  display: flex;
  flex-wrap: wrap;
  gap: var(--space-3);
  margin-top: var(--space-5);
}

.portal-prompt-surface__chips button,
.portal-chip-row a,
.portal-chip-row button {
  padding: 0.45rem 0.85rem;
  border: 1px solid var(--color-border);
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.74);
  color: rgba(15, 16, 18, 0.86);
  font-family: var(--font-label);
  font-size: 0.78rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  transition: border-color var(--motion-fast), background-color var(--motion-fast), box-shadow var(--motion-fast), transform var(--motion-fast);
}

.portal-prompt-surface__chips button:hover,
.portal-prompt-surface__chips button:focus-visible,
.portal-chip-row a:hover,
.portal-chip-row a:focus-visible,
.portal-chip-row button:hover,
.portal-chip-row button:focus-visible {
  border-color: rgba(0, 0, 255, 0.2);
  background: rgba(0, 0, 255, 0.06);
  box-shadow: var(--shadow-focus);
  transform: translateY(-1px);
}

.portal-prompt-surface--light .portal-prompt-surface__chips button,
.portal-shell--light .portal-chip-row a,
.portal-shell--desk .portal-chip-row a {
  border-color: var(--color-border);
  background: rgba(255, 255, 255, 0.78);
  color: rgba(15, 16, 18, 0.82);
}

.portal-prompt-surface__chips button {
  color: var(--color-ai);
}

.portal-prompt-surface__status,
.portal-prompt-surface__reply {
  margin-top: var(--space-4);
}

.portal-prompt-surface__reply {
  color: var(--color-ai);
  background:
    linear-gradient(180deg, rgba(0, 0, 255, 0.06), rgba(0, 0, 255, 0.02)),
    rgba(255, 255, 255, 0.58);
  padding: 0.85rem 1rem;
  border: 1px solid rgba(0, 0, 255, 0.08);
  border-radius: var(--radius-lg);
}

.portal-prompt-surface__status {
  color: var(--color-ai);
}

[data-mode-intent-surface][data-ai-state="thinking"] {
  box-shadow: 0 0 0 1px rgba(0, 0, 255, 0.08), 0 12px 36px rgba(0, 0, 255, 0.08);
}

[data-mode-intent-surface][data-ai-state="thinking"] .portal-prompt-surface__reply,
[data-mode-intent-surface][data-ai-state="thinking"] .portal-prompt-surface__status {
  animation: ai-pulse 1.8s cubic-bezier(0.2, 0.8, 0.2, 1) infinite;
}

[data-mode-intent-surface] .portal-prompt-surface__reply[data-ai-generating="true"] {
  position: relative;
  overflow: hidden;
}

[data-mode-intent-surface] .portal-prompt-surface__reply[data-ai-generating="true"]::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(100deg, rgba(0, 0, 255, 0) 0%, rgba(0, 0, 255, 0.08) 42%, rgba(255, 255, 255, 0.42) 50%, rgba(0, 0, 255, 0.08) 58%, rgba(0, 0, 255, 0) 100%);
  transform: translateX(-100%);
  animation: ai-shimmer 2.2s cubic-bezier(0.2, 0.8, 0.2, 1) infinite;
  pointer-events: none;
}

[data-mode-intent-surface][data-ai-state="thinking"] .portal-prompt-surface__status::after {
  content: "...";
  display: inline-block;
  width: 1.2em;
  overflow: hidden;
  vertical-align: bottom;
  animation: ai-ellipsis 1.2s steps(4, end) infinite;
}

[data-mode-intent-surface][data-ai-state="ready"] .portal-prompt-surface__reply {
  box-shadow: inset 2px 0 0 var(--color-ai);
}

[data-mode-intent-surface][data-ai-state="error"] .portal-prompt-surface__status {
  color: #c62828;
}

.portal-route-bubble {
  position: absolute;
  left: 50%;
  top: 0.2rem;
  display: grid;
  place-items: center;
  width: clamp(10.5rem, 23vw, 13.5rem);
  min-height: 10.5rem;
  padding: 1.25rem;
  border: 1px solid rgba(255, 255, 255, 0.44);
  border-radius: 47% 53% 46% 54% / 55% 44% 56% 45%;
  background:
    radial-gradient(circle at 28% 24%, rgba(255, 255, 255, 0.84), rgba(255, 255, 255, 0.26) 18%, rgba(255, 255, 255, 0.08) 36%, rgba(107, 130, 255, 0.14) 76%, rgba(109, 238, 255, 0.1) 100%),
    linear-gradient(145deg, rgba(255, 255, 255, 0.32), rgba(129, 147, 255, 0.08));
  box-shadow: 0 24px 60px rgba(15, 16, 18, 0.14), inset 0 1px 0 rgba(255, 255, 255, 0.74), inset -12px -18px 28px rgba(84, 114, 255, 0.08);
  -webkit-backdrop-filter: blur(18px) saturate(135%);
  backdrop-filter: blur(18px) saturate(135%);
  opacity: 0;
  pointer-events: none;
  transform: translate(-50%, 18px) scale(0.72);
  transform-origin: center center;
  isolation: isolate;
  will-change: transform, opacity;
  --bubble-shimmer-x: -120%;
  --bubble-shimmer-rotate: -14deg;
  --bubble-halo-opacity: 0.82;
  --bubble-orbit-a-x: -2px;
  --bubble-orbit-a-y: 12px;
  --bubble-orbit-a-scale: 0.82;
  --bubble-orbit-a-opacity: 0;
  --bubble-orbit-b-x: 8px;
  --bubble-orbit-b-y: 24px;
  --bubble-orbit-b-scale: 0.76;
  --bubble-orbit-b-opacity: 0;
}

.portal-route-bubble.is-active {
  opacity: 1;
}

.portal-route-bubble::before {
  content: "";
  position: absolute;
  inset: 9% 13% 40% 17%;
  border-radius: 50%;
  background: radial-gradient(circle, rgba(255, 255, 255, 0.78) 0%, rgba(255, 255, 255, 0.22) 38%, rgba(255, 255, 255, 0.05) 72%, rgba(255, 255, 255, 0) 100%);
  filter: blur(0.5px);
  opacity: 0.92;
  transform: rotate(-18deg);
}

.portal-route-bubble__halo {
  position: absolute;
  inset: -11px;
  border-radius: 58% 42% 55% 45% / 44% 59% 41% 56%;
  background: conic-gradient(from 180deg at 50% 50%, rgba(92, 116, 255, 0.1), rgba(255, 255, 255, 0.5), rgba(0, 212, 255, 0.16), rgba(92, 116, 255, 0.1));
  filter: blur(14px);
  opacity: var(--bubble-halo-opacity);
  transition: opacity 260ms ease;
}

.portal-route-bubble__highlight,
.portal-route-bubble__shimmer,
.portal-route-bubble__specular,
.portal-route-bubble__orbit {
  position: absolute;
  pointer-events: none;
}

.portal-route-bubble__highlight {
  inset: 17% 21% 52% 23%;
  border-radius: 50%;
  background: radial-gradient(circle, rgba(255, 255, 255, 0.88) 0%, rgba(255, 255, 255, 0.28) 34%, rgba(255, 255, 255, 0) 100%);
  filter: blur(1px);
  opacity: 0.92;
  transform: rotate(-18deg);
}

.portal-route-bubble__shimmer {
  inset: 0;
  border-radius: inherit;
  overflow: hidden;
}

.portal-route-bubble__shimmer::before {
  content: "";
  position: absolute;
  inset: -18% -40%;
  background: linear-gradient(108deg, rgba(255, 255, 255, 0) 30%, rgba(255, 255, 255, 0.12) 42%, rgba(255, 255, 255, 0.58) 50%, rgba(205, 236, 255, 0.3) 56%, rgba(255, 255, 255, 0) 66%);
  transform: translateX(var(--bubble-shimmer-x)) rotate(var(--bubble-shimmer-rotate));
  opacity: 0.92;
}

.portal-route-bubble__specular {
  top: 18%;
  left: 29%;
  width: 0.92rem;
  height: 0.92rem;
  border-radius: 50%;
  background: radial-gradient(circle, rgba(255, 255, 255, 0.98) 0%, rgba(255, 255, 255, 0.48) 46%, rgba(255, 255, 255, 0) 100%);
  box-shadow: 0 0 10px rgba(255, 255, 255, 0.32);
  opacity: 0.9;
}

.portal-route-bubble__label {
  position: relative;
  z-index: 1;
  color: rgba(15, 16, 18, 0.92);
  font-family: var(--font-label);
  max-width: 8.2rem;
  font-size: 0.8rem;
  font-weight: 700;
  line-height: 1.45;
  letter-spacing: 0.08em;
  text-align: center;
}

.portal-route-bubble__orbit {
  z-index: 0;
  border-radius: 50%;
  border: 1px solid rgba(232, 244, 255, 0.48);
  background:
    radial-gradient(circle at 30% 28%, rgba(255, 255, 255, 0.86), rgba(255, 255, 255, 0.22) 30%, rgba(143, 228, 255, 0.14) 72%, rgba(255, 255, 255, 0.04) 100%),
    linear-gradient(145deg, rgba(255, 255, 255, 0.2), rgba(150, 220, 255, 0.08));
  box-shadow: 0 10px 26px rgba(15, 16, 18, 0.1), inset 0 1px 0 rgba(255, 255, 255, 0.72);
}

.portal-route-bubble__orbit--a {
  top: 72%;
  left: 18%;
  width: 1.85rem;
  height: 1.85rem;
  opacity: var(--bubble-orbit-a-opacity);
  transform: translate(var(--bubble-orbit-a-x), var(--bubble-orbit-a-y)) scale(var(--bubble-orbit-a-scale));
}

.portal-route-bubble__orbit--b {
  top: 64%;
  right: 14%;
  width: 1.32rem;
  height: 1.32rem;
  opacity: var(--bubble-orbit-b-opacity);
  transform: translate(var(--bubble-orbit-b-x), var(--bubble-orbit-b-y)) scale(var(--bubble-orbit-b-scale));
}

.portal-route-list,
.portal-mode-card-grid,
.portal-card-grid,
.portal-stat-grid,
.portal-student-summary {
  display: grid;
  gap: var(--space-5);
}

.portal-route-list--public {
  align-items: start;
}

.portal-route-list,
.portal-mode-card-grid {
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  margin-top: var(--space-8);
}

.portal-route-card,
.portal-mode-card,
.portal-panel,
.portal-stat-card,
.portal-card,
.portal-student-stat {
  padding: 1.35rem;
  border: 1px solid rgba(68, 71, 72, 0.08);
  border-radius: var(--radius-2xl);
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.7), rgba(247, 245, 240, 0.42)),
    rgba(255, 255, 255, 0.34);
  box-shadow: 0 18px 42px rgba(15, 16, 18, 0.045);
  transition: transform var(--motion-base), background-color var(--motion-base), box-shadow var(--motion-base), border-color var(--motion-base);
}

.portal-route-card,
.portal-card,
.portal-story-card,
.portal-mode-card {
  display: grid;
  align-content: start;
  gap: 0.75rem;
}

.portal-breakout-panel,
.portal-story-card {
  padding: 1.45rem;
  border: 1px solid rgba(68, 71, 72, 0.08);
  border-radius: var(--radius-2xl);
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.78), rgba(247, 245, 240, 0.48)),
    rgba(255, 255, 255, 0.54);
  box-shadow: var(--shadow-card);
}

.portal-breakout-panel--story,
.portal-breakout-panel--student-visual,
.portal-breakout-panel--staff-note {
  position: relative;
  overflow: hidden;
}

.portal-breakout-panel--story {
  padding: 1.3rem 1.25rem;
}

.portal-breakout-panel--story::after,
.portal-breakout-panel--student-visual::after,
.portal-breakout-panel--staff-note::after {
  content: "";
  display: block;
  width: min(100%, 18rem);
  margin-top: var(--space-6);
  aspect-ratio: 4 / 5;
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-panel);
}

.portal-breakout-panel--story::after {
  margin-left: auto;
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.22), rgba(255, 255, 255, 0.02)),
    url("../../assets/images/home/hero-architecture.jpg") center / cover;
  transform: translateX(10%) rotate(4deg);
  filter: grayscale(1) contrast(1.05);
}

.portal-breakout-panel--student-visual::after {
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.16), rgba(0, 0, 0, 0.08)),
    url("../../assets/images/home/hero-architecture.jpg") center / cover;
  transform: translateX(4%) rotate(-3deg);
  filter: grayscale(1) contrast(1.08);
}

.portal-breakout-panel--staff-note::after {
  width: min(100%, 13rem);
  aspect-ratio: 1 / 1.25;
  background: linear-gradient(180deg, rgba(255, 255, 255, 0.34), rgba(198, 198, 199, 0.12));
  border: 1px solid var(--color-border);
  transform: translateX(12%) rotate(5deg);
}

.portal-story-rail,
.portal-feature-grid,
.portal-faculty-strip,
.portal-review-grid {
  display: grid;
  gap: var(--space-4);
}

.portal-story-rail {
  gap: 0.85rem;
}

.portal-story-rail .portal-story-card {
  padding: 1.1rem 1.15rem;
}

.portal-story-card--lead,
.portal-card--lead {
  transform: translateX(var(--space-3));
}

.portal-feature-grid--staggered .portal-card:nth-child(2) {
  transform: translateY(var(--space-8));
}

.portal-feature-grid--staggered .portal-card:nth-child(3) {
  transform: translateY(calc(var(--space-4) * -1));
}

.portal-faculty-strip .portal-card:nth-child(2) {
  transform: translateY(var(--space-6));
}

.portal-route-card--priority {
  background: rgba(255, 255, 255, 0.74);
}

.portal-shell--light .portal-route-card,
.portal-shell--light .portal-panel,
.portal-shell--light .portal-stat-card,
.portal-shell--light .portal-card,
.portal-shell--desk .portal-panel,
.portal-shell--desk .portal-student-stat,
.portal-shell--desk .portal-route-card {
  border-color: rgba(68, 71, 72, 0.08);
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.76), rgba(247, 245, 240, 0.5)),
    rgba(255, 255, 255, 0.44);
  color: var(--color-ink);
}

.portal-mode-card__eyebrow,
.portal-route-card__eyebrow,
.portal-panel__eyebrow {
  margin: 0 0 var(--space-3);
  color: rgba(15, 16, 18, 0.4);
  font-family: var(--font-label);
  font-size: 0.78rem;
  letter-spacing: 0.16em;
  text-transform: uppercase;
}

.portal-mode-card__title,
.portal-route-card__title,
.portal-panel__title {
  margin: 0;
  font-family: var(--font-display);
  font-size: clamp(1.35rem, 1.55vw, 1.72rem);
  line-height: 1.08;
  letter-spacing: -0.03em;
}

.portal-route-card__title,
.portal-card .portal-panel__title,
.portal-story-card .portal-panel__title,
.portal-mode-card__title {
  max-width: 16ch;
}

.portal-mode-card__body,
.portal-route-card__reason,
.portal-panel__body {
  margin: var(--space-4) 0 0;
  color: rgba(15, 16, 18, 0.72);
  font-size: 0.98rem;
  line-height: 1.7;
}

.portal-mode-card__body,
.portal-route-card__reason,
.portal-card .portal-panel__body,
.portal-story-card .portal-panel__body {
  margin-top: 0;
}

.portal-mode-card__link,
.portal-route-card__link,
.portal-card__link,
.portal-story-card__link {
  margin-top: auto;
  color: rgba(15, 16, 18, 0.78);
  font-family: var(--font-label);
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}

.portal-card[href],
.portal-story-card[href] {
  color: inherit;
  text-decoration: none;
}

.portal-card[href]:focus-visible,
.portal-story-card[href]:focus-visible {
  outline: 2px solid var(--color-ai);
  outline-offset: 3px;
}

.portal-shell--light .portal-route-card__reason,
.portal-shell--light .portal-panel__body,
.portal-shell--desk .portal-route-card__reason,
.portal-shell--desk .portal-panel__body {
  color: rgba(15, 16, 18, 0.68);
}

.portal-mode-card-grid {
  margin-top: var(--space-16);
}

.portal-mode-card {
  min-height: 18rem;
  padding: 1.7rem 1.55rem;
  background: rgba(255, 255, 255, 0.18);
}

.portal-route-list--editorial {
  gap: var(--space-8);
}

.portal-feature-grid--news,
.portal-faculty-strip--editorial {
  gap: var(--space-8);
}

.portal-whitespace-band--news .portal-panel--manifesto {
  padding-top: var(--space-8);
}

.portal-mode-card:hover,
.portal-route-card:hover,
.portal-card:hover,
.portal-story-card:hover,
.portal-review-ticket:hover {
  border-color: rgba(0, 0, 255, 0.1);
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.88), rgba(250, 247, 242, 0.62)),
    rgba(255, 255, 255, 0.62);
  box-shadow: var(--shadow-lifted);
}

.portal-content-band,
.portal-ops-layout,
.portal-student-grid {
  display: grid;
  gap: var(--space-6);
  margin-top: var(--space-16);
  margin-bottom: var(--space-16);
}

.portal-whitespace-band,
.portal-asymmetric-section,
.portal-command-board {
  display: grid;
  gap: var(--space-8);
  margin-top: var(--space-20);
  margin-bottom: var(--space-20);
}

.portal-asymmetric-section__lead {
  max-width: 26rem;
}

.portal-command-board__main,
.portal-command-board__side {
  display: grid;
  gap: var(--space-6);
}

.portal-ops-layout__main,
.portal-ops-layout__side {
  display: grid;
  gap: var(--space-6);
}

.portal-copy-statements,
.portal-stack-list,
.portal-mini-list {
  display: grid;
  gap: var(--space-4);
  margin-top: var(--space-4);
}

.portal-list-item,
.portal-mini-item,
.portal-route-card,
.portal-card,
.portal-story-card,
.portal-stat-card,
.portal-student-stat,
.portal-breakout-panel,
.portal-review-ticket,
.portal-copy-statement,
.portal-chip-row a {
  opacity: 0;
  animation: portal-fade-up 720ms cubic-bezier(0.2, 0.8, 0.2, 1) forwards;
  animation-delay: calc(var(--stagger-index, 0) * 90ms);
}

.portal-panel--manifesto {
  background: transparent;
  box-shadow: none;
  padding-left: 0;
}

.portal-panel--document {
  background: linear-gradient(135deg, rgba(255, 255, 255, 0.92) 0%, rgba(211, 211, 214, 0.92) 100%);
  color: var(--color-ink);
}

.portal-panel--document .portal-panel__eyebrow,
.portal-panel--document .portal-panel__body,
.portal-panel--document .portal-panel__title {
  color: #2f3131;
}

.portal-copy-statement,
.portal-list-item,
.portal-mini-item {
  padding-top: var(--space-4);
  border-top: 0;
  background: rgba(255, 255, 255, 0.4);
  padding: var(--space-4);
  border-radius: var(--radius-md);
}

.portal-mini-item__label {
  display: block;
  font-size: 0.8125rem;
  font-weight: 500;
  color: var(--color-text-primary, #1a1a1a);
  line-height: 1.4;
}

.portal-mini-item__body {
  display: block;
  font-size: 0.72rem;
  color: var(--color-text-muted, #767676);
  margin-top: 0.15rem;
}

.portal-mini-item__badge {
  display: inline-block;
  font-size: 0.65rem;
  font-weight: 600;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  padding: 0.1em 0.45em;
  border-radius: var(--radius-sm, 4px);
  margin-bottom: 0.25rem;
  background: rgba(0, 0, 0, 0.06);
  color: var(--color-text-muted, #767676);
}

.portal-mini-item__badge--cat {
  background: color-mix(in srgb, var(--color-accent, #2563eb) 12%, transparent);
  color: var(--color-accent, #2563eb);
}

.portal-mini-item--published {
  display: flex;
  flex-direction: column;
  gap: 0;
}

/* Section separator label inside deadline panel */
.portal-list-section-label {
  margin-top: var(--space-4);
  padding-top: var(--space-3);
  border-top: 1px solid var(--color-border, rgba(0,0,0,0.08));
  font-size: 0.68rem;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--color-text-muted, #767676);
}

.portal-list-item--event .portal-panel__eyebrow {
  color: var(--color-accent, #2563eb);
}

.portal-mini-list__empty {
  font-size: 0.8125rem;
  color: var(--color-text-muted, #767676);
  padding: var(--space-3) 0;
}

.portal-review-ticket {
  padding: var(--space-6);
  border-radius: var(--radius-lg);
  border: 1px solid var(--color-border);
  background: linear-gradient(180deg, rgba(255, 255, 255, 0.78), rgba(235, 233, 229, 0.88));
  box-shadow: var(--shadow-card);
}

.portal-review-ticket__head {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: var(--space-4);
}

.portal-review-ticket__status {
  display: inline-flex;
  align-items: center;
  padding: 0.3rem 0.55rem;
  border-radius: var(--radius-sm);
  font-size: 0.75rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.portal-review-ticket__status--urgent {
  background: rgba(255, 180, 171, 0.12);
  color: var(--color-danger);
}

.portal-review-ticket__status--review {
  background: rgba(15, 16, 18, 0.08);
  color: var(--color-ink);
}

.portal-review-ticket__meta {
  display: grid;
  gap: var(--space-3);
  margin: var(--space-5) 0 0;
}

.portal-review-ticket__meta div {
  display: grid;
  gap: 0.1rem;
}

.portal-review-ticket__meta dt {
  font-family: var(--font-label);
  font-size: 0.72rem;
  text-transform: uppercase;
  letter-spacing: 0.12em;
  color: var(--color-stone-dark);
}

.portal-review-ticket__meta dd {
  margin: 0;
  color: var(--color-ink);
}

.portal-review-ticket__actions {
  display: flex;
  flex-wrap: wrap;
  gap: var(--space-4);
  margin-top: var(--space-5);
}

.portal-review-ticket__actions a {
  color: var(--color-ink);
  font-weight: 600;
  text-decoration: underline;
  text-underline-offset: 0.2rem;
}

.portal-draft-studio__head,
.portal-draft-preview__head {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: var(--space-4);
}

.portal-auth-badge {
  display: inline-flex;
  align-items: center;
  padding: 0.38rem 0.65rem;
  border-radius: var(--radius-sm);
  background: rgba(15, 16, 18, 0.08);
  color: var(--color-ink);
  font-family: var(--font-label);
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.portal-auth-badge[data-state="ready"] {
  background: rgba(0, 0, 255, 0.08);
  color: var(--color-ai);
}

.portal-auth-badge[data-state="warning"] {
  background: rgba(255, 180, 171, 0.12);
  color: var(--color-danger);
}

.portal-draft-studio__auth-actions,
.portal-draft-form__actions {
  display: flex;
  flex-wrap: wrap;
  gap: var(--space-3);
  margin-top: var(--space-5);
}

.portal-draft-studio__auth-google {
  display: flex;
  align-items: center;
}

.portal-draft-studio__auth-google[hidden] {
  display: none;
}

.portal-draft-health {
  display: grid;
  gap: var(--space-4);
  margin-top: var(--space-5);
  padding: var(--space-4);
  border: 1px solid rgba(15, 16, 18, 0.08);
  border-radius: var(--radius-lg);
  background: rgba(255, 255, 255, 0.72);
}

.portal-draft-health__head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: var(--space-3);
}

.portal-draft-health__meta {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(10rem, 1fr));
  gap: var(--space-3);
}

.portal-draft-health__meta p {
  margin: 0;
  padding: 0.8rem 0.9rem;
  border-radius: var(--radius-sm);
  background: rgba(15, 16, 18, 0.04);
  color: rgba(15, 16, 18, 0.68);
  line-height: 1.5;
}

.portal-draft-health__meta strong {
  display: block;
  margin-bottom: 0.2rem;
  color: var(--color-ink);
  font-family: var(--font-label);
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.portal-topbar-auth-actions {
  display: flex;
  align-items: center;
  gap: 0.65rem;
  flex-shrink: 0;
  flex-wrap: wrap;
}

/* Google GIS button: rendered inside iframe — apply grayscale on wrapper */
[data-topbar-gis-button] {
  display: flex;
  align-items: center;
}

[data-topbar-gis-button][hidden],
.portal-topbar-avatar[hidden] {
  display: none !important;
}

.portal-topbar-avatar {
  width: 2.7rem;
  height: 2.7rem;
  border-radius: 999px;
  overflow: hidden;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  background: #111;
  box-shadow: 0 0 0 1px rgba(17, 17, 17, 0.08);
}

.portal-topbar-avatar img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

/* Hide the topbar newsroom badge (faint purple box) — hidden for now */
[data-staff-newsroom-badge] {
  display: none !important;
}

.portal-topbar-session-actions {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  flex-wrap: wrap;
  opacity: 0;
  transform: translateY(-0.35rem);
  visibility: hidden;
  pointer-events: none;
  transition: opacity 220ms ease, transform 220ms ease, visibility 0s linear 220ms;
}

.portal-topbar-session-actions[data-visible="true"] {
  opacity: 1;
  transform: translateY(0);
  visibility: visible;
  pointer-events: auto;
  transition: opacity 220ms ease, transform 220ms ease;
}

.portal-topbar-session-actions > .portal-action-button,
.portal-topbar-session-actions > .portal-secondary-button-lite {
  width: auto;
  min-width: 0;
  min-height: 2.65rem;
  padding: 0.62rem 0.9rem;
  box-sizing: border-box;
}

.portal-action-button,
.portal-secondary-button-lite {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 2.8rem;
  padding: 0.8rem 1rem;
  border-radius: var(--radius-sm);
  font-family: var(--font-label);
  font-size: 0.78rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.portal-action-button {
  background: linear-gradient(135deg, #0f1012 0%, #3d3e42 100%);
  color: var(--color-white);
  text-decoration: none;
}

.portal-action-button--newsroom {
  white-space: nowrap;
}

.portal-secondary-button-lite {
  border: 1px solid var(--color-border);
  background: rgba(255, 255, 255, 0.82);
  color: var(--color-ink);
}

.portal-secondary-button-lite--topbar {
  background: rgba(255, 255, 255, 0.92);
}

@media (max-width: 980px) {
  .topbar-actions--staff {
    align-items: flex-start;
  }

  .portal-topbar-auth-actions {
    justify-content: flex-start;
  }

  .portal-topbar-session-actions {
    width: 100%;
  }
}

.portal-secondary-button-lite--danger {
  border-color: rgba(200, 30, 30, 0.35);
  color: #b91c1c;
  background: rgba(254, 242, 242, 0.85);
}
.portal-secondary-button-lite--danger:hover:not(:disabled) {
  background: rgba(254, 226, 226, 0.95);
  border-color: rgba(200, 30, 30, 0.6);
}
.portal-secondary-button-lite--danger:disabled {
  opacity: 0.5;
  cursor: not-allowed;
}

.portal-draft-form {
  display: grid;
  gap: var(--space-5);
  margin-top: var(--space-6);
}

.portal-draft-grid {
  display: grid;
  gap: var(--space-4);
}

.portal-draft-field {
  display: grid;
  gap: var(--space-2);
}

.portal-draft-field span {
  color: rgba(15, 16, 18, 0.42);
  font-family: var(--font-label);
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}

.portal-draft-field input,
.portal-draft-field textarea {
  width: 100%;
  border: 0;
  border-bottom: 2px solid rgba(15, 16, 18, 0.14);
  background: rgba(255, 255, 255, 0.84);
  color: var(--color-ink);
  font: inherit;
  padding: 0.9rem 1rem;
}

.portal-draft-field textarea {
  min-height: 8rem;
  resize: vertical;
}

.portal-draft-field input:focus,
.portal-draft-field textarea:focus {
  outline: none;
  box-shadow: inset 0 -2px 0 var(--color-ai);
}

.portal-draft-preview {
  margin-top: var(--space-6);
  padding: var(--space-5);
  border-radius: var(--radius-lg);
  background: linear-gradient(180deg, rgba(255, 255, 255, 0.84), rgba(238, 236, 232, 0.9));
  box-shadow: var(--shadow-card);
}

.portal-draft-preview__summary {
  margin: var(--space-4) 0 0;
  color: rgba(15, 16, 18, 0.78);
  font-size: 1rem;
  line-height: 1.7;
}

.portal-draft-preview__meta {
  display: grid;
  gap: var(--space-2);
  margin-top: var(--space-4);
}

.portal-draft-preview__meta p {
  margin: 0;
  color: rgba(15, 16, 18, 0.56);
  font-size: 0.9rem;
  line-height: 1.6;
}

.portal-draft-preview__body {
  display: grid;
  gap: var(--space-3);
  margin-top: var(--space-5);
}

.portal-draft-preview__body p,
.portal-draft-preview__footer p {
  margin: 0;
  color: rgba(15, 16, 18, 0.76);
  line-height: 1.8;
}

.portal-draft-preview__highlights {
  display: grid;
  gap: var(--space-2);
  margin: var(--space-5) 0 0;
  padding-left: 1.2rem;
  color: rgba(15, 16, 18, 0.78);
}

.portal-draft-preview__footer {
  display: grid;
  gap: var(--space-3);
  margin-top: var(--space-5);
  padding-top: var(--space-4);
  border-top: 1px solid rgba(15, 16, 18, 0.08);
}

.portal-draft-preview__actions {
  display: flex;
  flex-wrap: wrap;
  gap: var(--space-3);
  margin-top: var(--space-5);
}

.portal-draft-preview__actions .portal-secondary-button-lite[disabled] {
  opacity: 0.55;
  cursor: wait;
}

.portal-draft-preview__student-meta {
  display: grid;
  gap: var(--space-2);
  margin-top: var(--space-4);
  padding: var(--space-4);
  border-radius: var(--radius-md);
  background: rgba(255, 255, 255, 0.56);
}

.portal-draft-preview__student-meta div {
  display: grid;
  gap: 0.2rem;
}

.portal-draft-preview__student-meta dt {
  margin: 0;
  font-family: var(--font-label);
  font-size: 0.72rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: rgba(15, 16, 18, 0.42);
}

.portal-draft-preview__student-meta dd {
  margin: 0;
  color: rgba(15, 16, 18, 0.78);
  line-height: 1.6;
}

.portal-draft-upload-list {
  display: grid;
  gap: var(--space-3);
}

.portal-draft-upload-item {
  padding: 0.85rem 1rem;
  border: 1px solid rgba(15, 16, 18, 0.08);
  border-radius: 1rem;
  background: rgba(255, 255, 255, 0.62);
  cursor: grab;
}

.portal-draft-upload-item.is-dragging {
  opacity: 0.6;
  cursor: grabbing;
}

.portal-draft-upload-item.is-drop-target {
  border-color: rgba(15, 16, 18, 0.28);
  background: rgba(255, 255, 255, 0.88);
}

.portal-draft-upload-item__layout {
  display: grid;
  grid-template-columns: 132px minmax(0, 1fr);
  gap: 0.8rem;
  align-items: start;
}

.portal-draft-upload-item__thumb-wrap {
  border-radius: 0.75rem;
  overflow: hidden;
  border: 1px solid rgba(15, 16, 18, 0.08);
  background: rgba(15, 16, 18, 0.06);
}

.portal-draft-upload-item__thumb {
  width: 100%;
  height: 92px;
  object-fit: cover;
  display: block;
}

.portal-draft-upload-item__meta {
  min-width: 0;
}

.portal-draft-upload-item__title {
  margin-bottom: 0.25rem;
}

.portal-draft-wizard {
  margin-bottom: 0.8rem;
}

.portal-draft-wizard__steps {
  display: flex;
  flex-wrap: wrap;
  gap: 0.45rem;
}

.portal-draft-wizard__step {
  border: 1px solid rgba(15, 16, 18, 0.16);
  background: rgba(255, 255, 255, 0.65);
  color: rgba(15, 16, 18, 0.7);
  padding: 0.35rem 0.7rem;
  border-radius: 999px;
  font-family: var(--font-label);
  font-size: 0.72rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  cursor: pointer;
}

.portal-draft-wizard__step.is-active {
  background: rgba(15, 16, 18, 0.92);
  border-color: rgba(15, 16, 18, 0.92);
  color: #fff;
}

.portal-draft-wizard__nav {
  display: flex;
  justify-content: space-between;
  gap: 0.75rem;
  margin-top: 0.35rem;
}

@media (max-width: 760px) {
  .portal-draft-upload-item__layout {
    grid-template-columns: 1fr;
  }

  .portal-draft-upload-item__thumb {
    height: 164px;
  }
}

.portal-draft-preview__fact-box {
  display: grid;
  gap: var(--space-3);
  margin-top: var(--space-4);
  padding: var(--space-4);
  border-radius: var(--radius-md);
  background: linear-gradient(180deg, rgba(255,255,255,0.74), rgba(247,244,240,0.92));
  border: 1px solid rgba(15, 16, 18, 0.08);
}

.portal-draft-preview__fact-box-head {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: var(--space-3);
  flex-wrap: wrap;
}

.portal-draft-preview__fact-grid {
  display: grid;
  gap: var(--space-3);
}

.portal-draft-preview__fact-grid div {
  display: grid;
  gap: 0.2rem;
}

.portal-draft-preview__fact-grid dt {
  margin: 0;
  font-family: var(--font-label);
  font-size: 0.72rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: rgba(15, 16, 18, 0.42);
}

.portal-draft-preview__fact-grid dd {
  margin: 0;
  color: rgba(15, 16, 18, 0.82);
  line-height: 1.6;
}

@media (min-width: 760px) {
  .portal-draft-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .portal-draft-preview__fact-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

.portal-cta-actions {
  display: flex;
  flex-wrap: wrap;
  gap: var(--space-4);
  margin-top: var(--space-6);
}

.portal-action-link,
.portal-primary-workflow-cta {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0.9rem 1.15rem;
  border-radius: var(--radius-sm);
  background: linear-gradient(135deg, #0f1012 0%, #3d3e42 100%);
  color: var(--color-white);
  font-family: var(--font-label);
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.portal-primary-workflow-note {
  margin: var(--space-4) 0 0;
  max-width: 38rem;
  color: rgba(15, 16, 18, 0.56);
}

.portal-student-hero-tools {
  margin-bottom: var(--space-8);
}

.portal-footer {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(9rem, max-content));
  justify-content: center;
  gap: 0.8rem clamp(1.25rem, 3vw, 2.5rem);
  padding: clamp(2.5rem, 6vw, 4.5rem) var(--space-4);
  border-top: 1px solid var(--footer-line);
  background: var(--footer-bg);
  color: var(--footer-fg);
  font-family: var(--font-label);
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}

.portal-footer--light {
  background: var(--color-editorial-footer);
  border-top-color: var(--editorial-line);
  color: rgba(15, 16, 18, 0.62);
}

.portal-footer a {
  display: inline-flex;
  align-items: center;
  min-height: 2.4rem;
  border-bottom: 1px solid transparent;
}

.portal-footer a:hover,
.portal-footer a:focus-visible {
  color: var(--color-white);
  border-bottom-color: currentColor;
}

.portal-footer--light a:hover,
.portal-footer--light a:focus-visible {
  color: var(--color-primary);
}

@keyframes portal-fade-up {
  from {
    opacity: 0;
    transform: translate3d(0, 18px, 0);
  }

  to {
    opacity: 1;
    transform: translate3d(0, 0, 0);
  }
}

@media (min-width: 768px) {
  .portal-public-signals__grid,
  .portal-feature-grid--public-grid,
  .portal-faculty-strip--public-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .portal-staff-stat-grid,
  .portal-staff-command__grid,
  .portal-staff-records__grid,
  .portal-staff-signals__grid,
  .portal-student-summary--editorial,
  .portal-student-grid--editorial,
  .portal-feature-grid--student-feed {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .portal-public-next-strip {
    grid-template-columns: auto auto;
    justify-content: space-between;
    align-items: center;
  }
}

@media (min-width: 1024px) {
  .page-shell--with-sidenav.portal-public-page {
    --side-nav-clearance: calc(var(--side-nav-width) + clamp(0.75rem, 1.4vw, 1.25rem) + 0.5rem);
  }

  .page-shell--with-sidenav.portal-staff-page,
  .page-shell--with-sidenav.portal-student-page {
    --side-nav-clearance: calc(var(--side-nav-width) + clamp(0.75rem, 1.4vw, 1.25rem) + 0.5rem);
  }

  .page-shell--with-sidenav.portal-public-page .portal-public-hero__content,
  .page-shell--with-sidenav.portal-public-page .portal-public-shell {
    width: 100%;
    max-width: none;
  }

  .page-shell--with-sidenav.portal-staff-page .portal-staff-shell,
  .page-shell--with-sidenav.portal-staff-page .portal-staff-hero__content,
  .page-shell--with-sidenav.portal-student-page .portal-student-shell,
  .page-shell--with-sidenav.portal-student-page .portal-student-hero__content {
    width: 100%;
    max-width: none;
  }

  .portal-public-hero {
    min-height: calc(100vh - 1rem);
    padding: 6.5rem 4rem 6rem;
  }

  .portal-staff-hero,
  .portal-student-hero {
    min-height: calc(100vh - 1rem);
    padding: 13rem 4rem 6rem;
  }

  .portal-public-hero__content {
    grid-template-columns: minmax(0, 0.98fr) minmax(20rem, 0.52fr);
    align-items: center;
  }

  .portal-staff-hero__content {
    grid-template-columns: minmax(0, 0.98fr) minmax(20rem, 0.52fr);
    align-items: center;
  }

  .portal-student-hero__content {
    grid-template-columns: minmax(0, 1fr) minmax(19rem, 0.5fr);
    align-items: center;
  }

  .portal-public-hero__lead {
    padding-right: 1.25rem;
  }

  .portal-staff-hero__lead,
  .portal-student-hero__lead {
    padding-right: 1.25rem;
  }

  .portal-public-heading--split {
    grid-template-columns: minmax(0, 0.95fr) minmax(20rem, 0.55fr);
    align-items: end;
  }

  .portal-public-signals__grid {
    grid-template-columns: minmax(0, 0.82fr) minmax(0, 1.18fr);
  }

  .portal-public-why__grid {
    grid-template-columns: 1fr;
  }

  .portal-feature-grid--public-grid,
  .portal-faculty-strip--public-grid {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }

  .portal-staff-command__grid {
    grid-template-columns: minmax(0, 0.8fr) minmax(0, 1.2fr);
  }

  .portal-staff-stat-grid,
  .portal-staff-records__grid,
  .portal-staff-signals__grid,
  .portal-student-summary--editorial,
  .portal-student-grid--editorial,
  .portal-feature-grid--student-feed {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }

  .portal-staff-signals__grid {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }

  .portal-staff-signals__note {
    grid-column: 1 / -1;
  }

  .portal-editorial-grid--public {
    grid-template-columns: minmax(0, 1.28fr) minmax(320px, 0.88fr);
    align-items: start;
  }

  .portal-editorial-grid--public .portal-editorial-grid__main {
    max-width: 50rem;
  }

  .portal-editorial-grid--public .portal-editorial-grid__aside--story {
    width: min(100%, 23rem);
    justify-self: end;
  }

  .portal-editorial-grid--public .portal-greeting {
    max-width: 48rem;
    margin-bottom: var(--space-5);
  }

  .portal-editorial-grid--public .portal-greeting__headline {
    max-width: 11ch;
    font-size: clamp(2.55rem, 5.6vw, 5.1rem);
  }

  .portal-editorial-grid--public .portal-greeting__body {
    max-width: 34rem;
    font-size: clamp(0.98rem, 1.25vw, 1.14rem);
  }

  .portal-editorial-grid--staff {
    grid-template-columns: minmax(0, 1.2fr) minmax(280px, 0.8fr);
    align-items: start;
  }

  .portal-editorial-grid--student {
    grid-template-columns: minmax(0, 1.25fr) minmax(280px, 0.72fr);
    align-items: start;
  }

  .portal-content-band {
    grid-template-columns: 1.1fr 1fr 0.9fr;
  }

  .portal-whitespace-band {
    grid-template-columns: minmax(0, 0.75fr) minmax(0, 1.25fr);
    align-items: start;
  }

  .portal-asymmetric-section--faculty,
  .portal-asymmetric-section--student-feed {
    grid-template-columns: minmax(240px, 0.6fr) minmax(0, 1.4fr);
    align-items: start;
  }

  .portal-asymmetric-section--student-feed .portal-feature-grid {
    margin-left: var(--space-10);
  }

  .portal-asymmetric-section--cta {
    grid-template-columns: minmax(0, 1fr) minmax(320px, 0.8fr);
  }

  .portal-command-board {
    grid-template-columns: minmax(0, 1.35fr) minmax(320px, 0.78fr);
    align-items: start;
  }

  .portal-ops-layout {
    grid-template-columns: minmax(0, 1.4fr) minmax(280px, 0.8fr);
    align-items: start;
  }

  .portal-student-grid,
  .portal-stat-grid,
  .portal-student-summary {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }

  .portal-feature-grid--staggered {
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: var(--space-12);
  }

  .portal-faculty-strip {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }

  .portal-review-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .portal-public-footer {
    padding-left: max(var(--side-nav-clearance), env(safe-area-inset-left));
  }
}

/* ── Fix: restore correct selector name for review card image ─────────────── */
/* (The original .portfolio-review-card__image block was accidentally renamed;
    this override restores correct styling for the image element.) */
.portfolio-review-card__image {
  display: block;
  flex-shrink: 0;
  width: min(100%, 18rem);
  min-height: 18rem;
  object-fit: cover;
  border-radius: var(--radius-sm, 4px);
}

/* Override: reset any image-style leak on __actions from the renamed duplicate */
.portfolio-review-card__actions {
  min-height: 0;
  width: auto;
  object-fit: unset;
}

/* ── Review card: primary/secondary action hierarchy ─────────────────────── */
.portfolio-review-card__secondary-actions {
  position: relative;
}

.portfolio-review-card__secondary-actions > summary {
  list-style: none;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  gap: 0.35em;
  -webkit-user-select: none;
  user-select: none;
}

.portfolio-review-card__secondary-actions > summary::-webkit-details-marker {
  display: none;
}

.portfolio-review-card__secondary-actions[open] > summary {
  background: var(--color-primary, #111214);
  color: var(--color-white, #fff);
  border-color: var(--color-primary, #111214);
}

.portfolio-review-card__secondary-menu {
  position: absolute;
  bottom: calc(100% + 4px);
  left: 0;
  z-index: 20;
  display: flex;
  flex-direction: column;
  gap: 0.35rem;
  padding: 0.65rem;
  min-width: 15rem;
  background: var(--color-white, #fff);
  border: 1px solid rgba(15, 16, 18, 0.12);
  box-shadow: 0 4px 24px rgba(15, 16, 18, 0.10), 0 1px 4px rgba(15, 16, 18, 0.06);
  border-radius: 2px;
}

.portfolio-review-card__secondary-menu > button {
  width: 100%;
  text-align: left;
  white-space: nowrap;
}

@media (max-width: 767px) {
  .portal-entry-page .portal-brand-strip {
    margin-bottom: var(--space-5);
  }

  .portal-entry-page .portal-selector-stack {
    gap: var(--space-4);
    padding-top: 0;
  }

  .portal-entry-split {
    grid-template-columns: 1fr;
    align-items: start;
  }

  .portal-entry-page .portal-entry-mode-mark {
    margin-bottom: 0.95rem;
  }

  .portal-entry-page .portal-entry-desktop-details {
    display: none;
  }

  .portal-entry-page .portal-greeting__headline {
    max-width: 100%;
    font-size: clamp(2.45rem, 11vw, 3.85rem);
    line-height: 1;
  }

  .portal-entry-page .portal-greeting__body {
    max-width: none;
    font-size: 0.98rem;
  }

  .portal-entry-page .portal-entry-mode-hint {
    margin-top: 0.85rem;
  }

  .portal-entry-page .portal-prompt-surface--selector {
    width: 100%;
  }

  .portal-entry-ai-panel {
    padding: 1rem 1rem 0.95rem;
  }

  .portal-entry-ai-panel__title {
    font-size: clamp(1.32rem, 6vw, 1.8rem);
  }

  .portal-entry-ai-panel__body {
    font-size: 0.92rem;
  }

  .portal-public-hero,
  .portal-public-index,
  .portal-public-why,
  .portal-public-signals,
  .portal-public-faculty,
  .portal-public-apply {
    padding-right: 1rem;
    padding-left: 1rem;
  }

  .portal-public-hero__content,
  .portal-public-shell {
    width: calc(100vw - 2rem);
    max-width: calc(100vw - 2rem);
  }

  .portal-staff-hero,
  .portal-staff-quickbar,
  .portal-staff-routes,
  .portal-staff-command,
  .portal-staff-records,
  .portal-staff-signals,
  .portal-student-hero,
  .portal-student-announcements,
  .portal-student-paths,
  .portal-student-status,
  .portal-student-workflow {
    padding-right: 1rem;
    padding-left: 1rem;
  }

  .portal-student-feed__head {
    padding-inline: 1rem;
  }

  .portal-staff-shell,
  .portal-student-shell {
    width: calc(100vw - 2rem);
    max-width: calc(100vw - 2rem);
  }

  .portal-public-hero__title,
  .portal-public-heading h2 {
    max-width: 100%;
    overflow-wrap: anywhere;
  }

  .portal-public-facts {
    grid-template-columns: 1fr;
    max-width: none;
    margin-top: 2rem;
  }

  .portal-public-intro {
    gap: 0.7rem;
  }

  .portal-route-list--index .portal-route-card {
    grid-template-columns: 2.4rem minmax(0, 1fr);
  }

  .portal-route-list--index .portal-route-card__link {
    margin-top: 0.45rem;
    justify-self: start;
  }

  .portal-public-panel,
  .portal-feature-grid--public-grid .portal-card,
  .portal-faculty-strip--public-grid .portal-card,
  .portal-public-panel--staff,
  .portal-public-panel--student,
  .portal-feature-grid--student-feed .portal-card {
    min-height: auto;
  }

  .portal-hero,
  .portal-main--selector {
    min-height: auto;
  }

  .portal-hero--selector,
  .portal-hero--public {
    align-items: start;
  }

  .portal-hero__content,
  .portal-hero__content--selector,
  .portal-hero__content--newsroom,
  .portal-hero__content--editorial {
    min-height: auto;
    padding-top: var(--space-4);
    padding-bottom: var(--space-8);
  }

  .portal-selector-stack {
    align-content: start;
    gap: var(--space-5);
  }

  .portal-brand-strip {
    flex-direction: column;
    align-items: flex-start;
    gap: var(--space-3);
    margin-bottom: var(--space-5);
  }

  .portal-greeting {
    text-align: left;
    margin-bottom: var(--space-5);
  }

  .portal-greeting__headline {
    font-size: clamp(2.35rem, 13vw, 3.9rem);
    line-height: 0.98;
    max-width: 12ch;
  }

  .portal-greeting__body {
    margin-left: 0;
    margin-right: 0;
    max-width: none;
    font-size: 1rem;
  }

  .portal-prompt-surface__field {
    grid-template-columns: 1fr;
    gap: var(--space-3);
  }

  .portal-prompt-surface__submit {
    width: 100%;
  }

  .portal-prompt-surface,
  .portal-breakout-panel,
  .portal-story-card,
  .portal-route-card,
  .portal-mode-card,
  .portal-panel,
  .portal-stat-card,
  .portal-card,
  .portal-student-stat {
    border-radius: var(--radius-xl);
  }

  .portal-content-band,
  .portal-ops-layout,
  .portal-student-grid,
  .portal-whitespace-band,
  .portal-asymmetric-section,
  .portal-command-board {
    margin-top: var(--space-10);
    margin-bottom: var(--space-10);
    gap: var(--space-5);
  }

  .portal-route-list,
  .portal-mode-card-grid,
  .portal-card-grid,
  .portal-stat-grid,
  .portal-student-summary {
    gap: var(--space-4);
  }

  .portal-story-card--lead,
  .portal-card--lead,
  .portal-feature-grid--staggered .portal-card:nth-child(2),
  .portal-feature-grid--staggered .portal-card:nth-child(3),
  .portal-faculty-strip .portal-card:nth-child(2),
  .portal-breakout-panel--story::after,
  .portal-breakout-panel--student-visual::after,
  .portal-breakout-panel--staff-note::after {
    transform: none;
  }
}

.portal-action-button,
.portal-primary-workflow-cta,
.portal-action-link {
  box-shadow: 0 14px 32px rgba(15, 16, 18, 0.16);
  transition: transform var(--motion-fast), box-shadow var(--motion-fast), background var(--motion-fast);
}

.portal-action-button:hover,
.portal-action-button:focus-visible,
.portal-primary-workflow-cta:hover,
.portal-primary-workflow-cta:focus-visible,
.portal-action-link:hover,
.portal-action-link:focus-visible {
  transform: translateY(-1px);
  box-shadow: 0 18px 40px rgba(15, 16, 18, 0.22);
}

.portal-secondary-button-lite {
  transition: transform var(--motion-fast), border-color var(--motion-fast), background-color var(--motion-fast), box-shadow var(--motion-fast);
}

.portal-secondary-button-lite:hover,
.portal-secondary-button-lite:focus-visible {
  border-color: rgba(0, 0, 255, 0.18);
  background: rgba(255, 255, 255, 0.94);
  box-shadow: var(--shadow-focus);
  transform: translateY(-1px);
}

.portal-inline-actions--cta {
  margin-top: var(--space-6);
}

.portal-cta-link {
  gap: 0.5rem;
}

.portal-cta-link .material-symbols-outlined {
  font-size: 1.15rem;
}

/* ================================================
   Work-type conditional sections
   ================================================ */

.work-type-section {
  padding: var(--space-5) var(--space-6) var(--space-6) var(--space-6);
  border-left: 3px solid var(--color-terracotta);
  border-radius: 0 var(--radius-lg) var(--radius-lg) 0;
  background: linear-gradient(160deg, rgba(255, 255, 255, 0.72), rgba(251, 246, 237, 0.48));
  box-shadow: 0 4px 18px rgba(168, 102, 63, 0.06);
  animation: workSectionFadeIn var(--motion-base) both;
}

@keyframes workSectionFadeIn {
  from { opacity: 0; transform: translateY(6px); }
  to   { opacity: 1; transform: translateY(0); }
}

/* ================================================
   Visual Ingest — Phase 1
   ================================================ */

/* Drop zone */
.visual-ingest-zone {
  position: relative;
  border: 2px dashed var(--color-stone);
  border-radius: var(--radius-lg);
  background: var(--color-sand);
  padding: var(--space-10) var(--space-8);
  text-align: center;
  cursor: pointer;
  transition: border-color var(--motion-fast), background var(--motion-fast);
  outline: none;
  margin-top: var(--space-4);
}

.visual-ingest-zone:hover,
.visual-ingest-zone:focus-visible {
  border-color: var(--color-stone-dark);
  background: var(--color-editorial-bg);
}

.visual-ingest-zone--over {
  border-color: var(--color-ai);
  background: var(--color-ai-soft);
}

.visual-ingest-zone__input {
  position: absolute;
  width: 1px;
  height: 1px;
  opacity: 0;
  pointer-events: none;
}

.visual-ingest-zone__icon {
  display: block;
  font-size: 2rem;
  line-height: 1;
  margin-bottom: var(--space-3);
  color: var(--color-stone-dark);
}

.visual-ingest-zone__label {
  font-size: 0.9rem;
  color: var(--color-stone-ink);
  margin: 0 0 var(--space-2);
}

.visual-ingest-zone__browse {
  color: var(--color-ai);
  text-decoration: underline;
  text-underline-offset: 2px;
}

.visual-ingest-zone__hint {
  font-size: var(--type-label-sm);
  color: var(--editorial-muted);
  margin: 0;
  letter-spacing: 0.04em;
}

/* Image card grid */
.visual-ingest-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(180px, 1fr));
  gap: var(--space-4);
  margin-top: var(--space-5);
}

/* Individual card */
.visual-ingest-card {
  background: var(--color-paper);
  border: 1.5px solid var(--color-border);
  border-radius: var(--radius-md);
  overflow: hidden;
  cursor: grab;
  transition: border-color var(--motion-fast), box-shadow var(--motion-fast), opacity var(--motion-fast);
  user-select: none;
}

.visual-ingest-card:active {
  cursor: grabbing;
}

.visual-ingest-card--primary {
  border-color: var(--color-terracotta);
  box-shadow: 0 0 0 2px var(--color-terracotta-soft);
}

.visual-ingest-card--dragging {
  opacity: 0.35;
  cursor: grabbing;
}

.visual-ingest-card--over {
  border-color: var(--color-ai);
  box-shadow: 0 0 0 2px var(--color-ai-soft);
}

/* Thumbnail */
.visual-ingest-card__thumb {
  position: relative;
  aspect-ratio: 4 / 3;
  background: var(--color-stone);
  overflow: hidden;
}

.visual-ingest-card__img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
  pointer-events: none;
}

.visual-ingest-card__placeholder {
  display: flex;
  align-items: center;
  justify-content: center;
  height: 100%;
  font-size: 0.75rem;
  color: var(--editorial-muted);
}

/* Primary (★) badge */
.visual-ingest-card__badge {
  position: absolute;
  top: var(--space-2);
  right: var(--space-2);
  width: 26px;
  height: 26px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: rgba(255, 255, 255, 0.88);
  border: 1px solid var(--color-border);
  border-radius: 50%;
  font-size: 13px;
  line-height: 1;
  cursor: pointer;
  color: var(--color-stone-dark);
  transition: background var(--motion-fast), color var(--motion-fast), border-color var(--motion-fast);
  padding: 0;
}

.visual-ingest-card__badge:hover {
  background: var(--color-warm-paper);
  border-color: var(--color-terracotta);
  color: var(--color-terracotta);
}

.visual-ingest-card__badge--active {
  background: var(--color-terracotta);
  border-color: var(--color-terracotta);
  color: #fff;
}

/* Sequence number */
.visual-ingest-card__seq {
  position: absolute;
  top: var(--space-2);
  left: var(--space-2);
  background: rgba(15, 16, 18, 0.64);
  color: #fff;
  border-radius: var(--radius-sm);
  padding: 2px 6px;
  font-size: 0.68rem;
  font-weight: 600;
  letter-spacing: 0.04em;
  line-height: 1.4;
  pointer-events: none;
}

/* Card body */
.visual-ingest-card__body {
  padding: var(--space-3);
  display: flex;
  flex-direction: column;
  gap: var(--space-2);
}

.visual-ingest-card__name {
  font-size: 0.78rem;
  font-weight: 600;
  color: var(--color-ink);
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  margin: 0;
}

.visual-ingest-card__meta {
  font-size: 0.68rem;
  color: var(--editorial-muted);
  margin: 0;
}

/* Per-card fields */
.visual-ingest-card__field {
  display: flex;
  flex-direction: column;
  gap: 3px;
}

.visual-ingest-card__field span {
  font-size: 0.64rem;
  color: var(--editorial-muted);
  text-transform: uppercase;
  letter-spacing: 0.08em;
}

.visual-ingest-card__field select,
.visual-ingest-card__field input[type="text"],
.visual-ingest-card__field textarea {
  font-size: 0.76rem;
  padding: 4px 8px;
  border: 1px solid var(--color-border);
  border-radius: var(--radius-sm);
  background: var(--color-surface-strong);
  color: var(--color-ink);
  font-family: var(--font-body);
  width: 100%;
  box-sizing: border-box;
  transition: border-color var(--motion-fast);
}

.visual-ingest-card__field select:focus,
.visual-ingest-card__field input[type="text"]:focus,
.visual-ingest-card__field textarea:focus {
  outline: none;
  border-color: var(--color-ai);
  box-shadow: 0 0 0 2px var(--color-ai-soft);
}

.visual-ingest-card__field textarea {
  resize: vertical;
  min-height: 48px;
}

/* Remove button */
.visual-ingest-card__remove {
  align-self: flex-start;
  font-size: 0.7rem;
  color: var(--color-stone-dark);
  background: none;
  border: none;
  padding: 0;
  cursor: pointer;
  font-family: var(--font-body);
  transition: color var(--motion-fast);
}

.visual-ingest-card__remove:hover {
  color: var(--color-danger);
}

/* Action bar */
.visual-ingest-bar {
  display: flex;
  align-items: center;
  gap: var(--space-4);
  margin-top: var(--space-4);
}

.visual-ingest-bar__count {
  font-size: 0.8rem;
  color: var(--editorial-muted);
}

.visual-ingest-bar__ai {
  margin-left: auto;
  color: var(--color-ai, #7c5cbf);
  border-color: var(--color-ai, #7c5cbf);
}

.visual-ingest-bar__ai:hover {
  background: color-mix(in srgb, var(--color-ai, #7c5cbf) 8%, transparent);
}

/* ─────────────────────────────────────────────────────────────
   AI Text-trigger row (below concept/design-problem fields)
───────────────────────────────────────────────────────────── */
.ai-text-trigger-row {
  display: flex;
  align-items: center;
  gap: var(--space-4);
  margin-top: var(--space-3);
}

.ai-text-trigger-btn {
  flex-shrink: 0;
  color: var(--color-ai, #7c5cbf);
  border-color: var(--color-ai, #7c5cbf);
}

.ai-text-trigger-btn:hover {
  background: color-mix(in srgb, var(--color-ai, #7c5cbf) 8%, transparent);
}

.ai-text-trigger-hint {
  font-size: 0.78rem;
  color: var(--editorial-muted);
  line-height: 1.4;
}

/* ─────────────────────────────────────────────────────────────
   AI Analysis Panel (aside)
───────────────────────────────────────────────────────────── */
.ai-analysis-panel {
  border-top: 2px solid var(--color-ai, #7c5cbf);
}

.ai-analysis-panel__body {
  display: flex;
  flex-direction: column;
  gap: var(--space-4);
  margin-top: var(--space-4);
}

/* Text blocks */
.ai-panel__block {
  background: var(--surface-2, #f5f3ef);
  border-radius: var(--radius-md, 8px);
  padding: var(--space-4);
}

.ai-panel__block--academic  { border-left: 3px solid var(--color-terracotta, #c0603e); }
.ai-panel__block--story     { border-left: 3px solid var(--color-sand, #d4a96a); }
.ai-panel__block--en        { border-left: 3px solid var(--color-ai, #7c5cbf); }
.ai-panel__block--keywords  { background: transparent; padding: 0; }

.ai-panel__block-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: var(--space-2);
}

.ai-panel__label {
  font-size: 0.72rem;
  font-weight: 600;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--editorial-muted);
  margin: 0;
}

.ai-panel__text {
  font-size: 0.85rem;
  line-height: 1.65;
  color: var(--editorial-body, inherit);
  margin: 0;
  white-space: pre-wrap;
}

.ai-panel__copy {
  font-size: 0.72rem;
  padding: 2px 8px;
  border: 1px solid var(--color-ai, #7c5cbf);
  color: var(--color-ai, #7c5cbf);
  border-radius: var(--radius-sm, 4px);
  background: transparent;
  cursor: pointer;
  transition: background var(--motion-fast, 100ms);
}

.ai-panel__copy:hover {
  background: color-mix(in srgb, var(--color-ai, #7c5cbf) 10%, transparent);
}

/* Keywords */
.ai-panel__section-label {
  font-size: 0.72rem;
  font-weight: 600;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--editorial-muted);
  margin: 0 0 var(--space-2);
}

.ai-panel__keywords {
  display: flex;
  flex-wrap: wrap;
  gap: var(--space-2);
}

.ai-panel__keyword {
  font-size: 0.78rem;
  padding: 2px 8px;
  background: color-mix(in srgb, var(--color-ai, #7c5cbf) 10%, transparent);
  color: var(--color-ai, #7c5cbf);
  border-radius: 999px;
}

/* Image result rows */
.ai-panel__image-list {
  display: flex;
  flex-direction: column;
  gap: var(--space-2);
}

.ai-panel__image-row {
  display: grid;
  grid-template-columns: 28px 1fr auto;
  align-items: center;
  gap: var(--space-2);
  font-size: 0.78rem;
  padding: var(--space-2) var(--space-3);
  background: var(--surface-2, #f5f3ef);
  border-radius: var(--radius-sm, 4px);
}

.ai-panel__img-idx {
  font-weight: 600;
  color: var(--editorial-muted);
}

.ai-panel__img-name {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  color: var(--editorial-body, inherit);
}

.ai-panel__img-role {
  font-size: 0.72rem;
  padding: 2px 6px;
  background: var(--color-ai-surface, #ede9f6);
  color: var(--color-ai, #7c5cbf);
  border-radius: 4px;
  white-space: nowrap;
}

.ai-panel__img-note {
  grid-column: 2 / -1;
  font-size: 0.72rem;
  color: var(--editorial-muted);
  font-style: italic;
}

/* ─────────────────────────────────────────────────────────────────────────────
   Phase 4 — Canvas Block Preview (portfolio detail page)
───────────────────────────────────────────────────────────────────────────── */

.portfolio-canvas-list {
  display: flex;
  flex-direction: column;
  gap: var(--space-4, 16px);
  margin-top: var(--space-4, 16px);
}

.portfolio-canvas-block {
  border: 1.5px solid rgba(15, 16, 18, 0.09);
  border-radius: var(--radius-md, 8px);
  overflow: hidden;
  background: var(--color-editorial-panel, #fbfaf7);
}

.portfolio-canvas-block__header {
  display: flex;
  align-items: center;
  gap: var(--space-2, 8px);
  padding: var(--space-3, 10px) var(--space-4, 14px);
  background: var(--color-editorial-band, #efeeeb);
  border-bottom: 1px solid rgba(15, 16, 18, 0.08);
  flex-wrap: wrap;
}

.portfolio-canvas-block__seq {
  font-size: 0.65rem;
  font-weight: 700;
  color: var(--editorial-muted);
  letter-spacing: 0.06em;
  min-width: 1.4em;
  text-align: right;
}

.portfolio-canvas-block__icon {
  font-size: 0.85rem;
  line-height: 1;
}

.portfolio-canvas-block__type {
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 0.07em;
  text-transform: uppercase;
  color: var(--editorial-muted);
}

.portfolio-canvas-block__variant {
  font-size: 0.62rem;
  padding: 1px 6px;
  border-radius: 3px;
  background: rgba(15, 16, 18, 0.07);
  border: 1px solid rgba(15, 16, 18, 0.08);
}

.portfolio-canvas-block__ai {
  font-size: 0.62rem;
  font-weight: 700;
  padding: 1px 6px;
  border-radius: 3px;
  background: var(--color-ai-soft, rgba(0,0,255,0.08));
  color: var(--color-ai, #0000ff);
  letter-spacing: 0.04em;
  margin-left: auto;
}

.portfolio-canvas-block__lock {
  font-size: 0.72rem;
}

.portfolio-canvas-block__content {
  padding: var(--space-4, 14px);
  display: flex;
  flex-direction: column;
  gap: var(--space-2, 8px);
}

.portfolio-canvas-block__image {
  width: 100%;
  max-height: 220px;
  overflow: hidden;
  border-radius: var(--radius-sm, 4px);
  background: rgba(15, 16, 18, 0.04);
  margin-bottom: var(--space-2, 8px);
}

.portfolio-canvas-block__image img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

.portfolio-canvas-block__text {
  display: flex;
  flex-direction: column;
  gap: var(--space-1, 4px);
}

.portfolio-canvas-block__dl {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(180px, 1fr));
  gap: var(--space-2, 8px) var(--space-4, 14px);
  margin: var(--space-2, 8px) 0 0;
  padding: 0;
}

.portfolio-canvas-block__dl dt {
  font-size: 0.68rem;
  font-weight: 600;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--editorial-muted);
  margin: 0 0 2px;
}

.portfolio-canvas-block__dl dd {
  font-size: 0.82rem;
  color: var(--editorial-body, inherit);
  margin: 0;
  line-height: 1.5;
}

/* ══════════════════════════════════════════════════════════════════════
   Submit Wizard — 2-step wizard nav, canvas builder, rich editor
   ═══════════════════════════════════════════════════════════════════ */

/* ── Wizard step nav ─────────────────────────────────────────── */

.submit-wizard-nav {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  padding: 1.25rem 0 1rem;
}

.submit-wizard-nav__step {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.45rem 0.85rem;
  border: 1px solid var(--project-line, rgba(15, 16, 18, 0.12));
  background: transparent;
  color: var(--editorial-muted, rgba(15, 16, 18, 0.42));
  font-family: var(--font-label);
  font-size: 0.78rem;
  font-weight: 700;
  letter-spacing: 0.10em;
  text-transform: uppercase;
  cursor: pointer;
  transition: border-color 0.15s, color 0.15s;
}

.submit-wizard-nav__step--active {
  border-color: var(--color-primary, #0f1012);
  color: var(--color-primary, #0f1012);
}

.submit-wizard-nav__num {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 1.4rem;
  height: 1.4rem;
  border-radius: 50%;
  background: var(--project-line, rgba(15, 16, 18, 0.12));
  font-size: 0.72rem;
  line-height: 1;
}

.submit-wizard-nav__step--active .submit-wizard-nav__num {
  background: var(--color-primary, #0f1012);
  color: #fff;
}

.submit-wizard-nav__divider {
  color: var(--editorial-muted, rgba(15, 16, 18, 0.28));
  font-size: 0.85rem;
}

/* ── Step 1 footer ───────────────────────────────────────────── */

.submit-step-footer {
  display: flex;
  justify-content: flex-end;
  padding: 1.5rem 0 0;
  margin-top: 0.5rem;
  border-top: 1px solid var(--project-line, rgba(15, 16, 18, 0.10));
}

/* ── Rich text overview editor ───────────────────────────────── */

.submit-overview-editor {
  margin: 0.25rem 0 1rem;
}

.portal-draft-field__label {
  display: block;
  margin-bottom: 0.35rem;
  font-family: var(--font-label);
  font-size: 0.8rem;
  font-weight: 700;
  letter-spacing: 0.07em;
  text-transform: uppercase;
  color: var(--editorial-muted, rgba(15, 16, 18, 0.48));
}

.rich-editor-toolbar {
  display: flex;
  gap: 2px;
  padding: 4px 6px;
  background: rgba(15, 16, 18, 0.04);
  border: 1px solid var(--project-line, rgba(15, 16, 18, 0.12));
  border-bottom: none;
}

.rich-editor-toolbar button {
  padding: 3px 8px;
  border: 1px solid transparent;
  background: transparent;
  cursor: pointer;
  font-size: 0.85rem;
  color: var(--color-ink, #0f1012);
  border-radius: 2px;
  transition: background 0.1s;
}

.rich-editor-toolbar button:hover {
  background: rgba(15, 16, 18, 0.08);
}

.canvas-rich-editor {
  min-height: 8rem;
  padding: 0.75rem;
  border: 1px solid var(--project-line, rgba(15, 16, 18, 0.12));
  background: #fff;
  font-size: 1rem;
  line-height: 1.55;
  outline: none;
  white-space: pre-wrap;
}

.canvas-rich-editor:focus {
  border-color: var(--color-primary, #0f1012);
}

/* ── Canvas container ────────────────────────────────────────── */

.submit-canvas {
  min-height: 12rem;
  padding: 1.5rem;
  border: 2px dashed rgba(15, 16, 18, 0.16);
  background: rgba(15, 16, 18, 0.015);
  display: flex;
  flex-direction: column;
  gap: 1rem;
}

.submit-canvas__empty {
  margin: auto;
  text-align: center;
  color: var(--editorial-muted, rgba(15, 16, 18, 0.38));
  font-family: var(--font-label);
  font-size: 0.82rem;
  letter-spacing: 0.06em;
  text-transform: uppercase;
}

.submit-canvas-addbar {
  display: flex;
  gap: 0.5rem;
  margin-top: 0.75rem;
}

/* ── Canvas block cards ──────────────────────────────────────── */

.submit-canvas-card {
  position: relative;
  background: #fff;
  border: 1px solid var(--project-line, rgba(15, 16, 18, 0.12));
  padding: 1rem;
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
}

.submit-canvas-card__header {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  font-family: var(--font-label);
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 0.10em;
  text-transform: uppercase;
  color: var(--editorial-muted, rgba(15, 16, 18, 0.48));
}

.submit-canvas-card__type-badge {
  padding: 2px 6px;
  background: rgba(15, 16, 18, 0.06);
  border-radius: 2px;
}

.submit-canvas-card__remove {
  margin-left: auto;
  padding: 2px 8px;
  border: 1px solid var(--project-line, rgba(15, 16, 18, 0.12));
  background: transparent;
  cursor: pointer;
  font-size: 0.75rem;
  color: var(--editorial-muted, rgba(15, 16, 18, 0.42));
}

.submit-canvas-card__remove:hover {
  border-color: var(--color-terracotta, #c0603e);
  color: var(--color-terracotta, #c0603e);
}

/* ── Canvas image upload zone ────────────────────────────────── */

.submit-canvas-image-zone {
  position: relative;
  min-height: 10rem;
  border: 2px dashed rgba(15, 16, 18, 0.14);
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  overflow: hidden;
  background: rgba(15, 16, 18, 0.02);
  transition: border-color 0.15s, background 0.15s;
}

.submit-canvas-image-zone:hover {
  border-color: var(--color-primary, #0f1012);
  background: rgba(15, 16, 18, 0.04);
}

.submit-canvas-image-zone input[type="file"] {
  position: absolute;
  inset: 0;
  opacity: 0;
  cursor: pointer;
  z-index: 2;
}

.submit-canvas-image-zone__hint {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.3rem;
  color: var(--editorial-muted, rgba(15, 16, 18, 0.38));
  font-family: var(--font-label);
  font-size: 0.78rem;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  pointer-events: none;
  text-align: center;
  z-index: 1;
}

.submit-canvas-image-zone__preview {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: contain;
  display: none;
  z-index: 3;
}

.submit-canvas-image-zone--has-image .submit-canvas-image-zone__preview { display: block; }
.submit-canvas-image-zone--has-image .submit-canvas-image-zone__hint { display: none; }

/* Replace button — revealed when an image is already loaded */
.submit-canvas-image-zone__replace {
  display: none;
  position: absolute;
  bottom: 0.6rem;
  right: 0.6rem;
  z-index: 5;
  padding: 0.28rem 0.72rem;
  background: rgba(15, 16, 18, 0.68);
  color: #fff;
  border: none;
  border-radius: 4px;
  font-size: 0.75rem;
  font-family: var(--font-label, sans-serif);
  letter-spacing: 0.04em;
  cursor: pointer;
  transition: background 0.15s;
  pointer-events: auto;
}
.submit-canvas-image-zone__replace:hover {
  background: rgba(15, 16, 18, 0.9);
}
.submit-canvas-image-zone--has-image .submit-canvas-image-zone__replace {
  display: block;
}

.submit-canvas-image-zone__caption {
  padding: 0.4rem 0 0;
  font-size: 0.9rem;
  border: none;
  border-bottom: 1px solid var(--project-line, rgba(15, 16, 18, 0.12));
  outline: none;
  width: 100%;
  background: transparent;
  font-family: var(--font-label);
  color: var(--color-ink, #0f1012);
}

/* ── Drafting details collapsible ────────────────────────────── */

.portfolio-submit-details {
  margin: 1.5rem 0 0;
  border-top: 1px solid var(--project-line, rgba(15, 16, 18, 0.10));
}

.submit-details-summary {
  padding: 0.85rem 0;
  list-style: none;
  cursor: pointer;
  font-family: var(--font-label);
  font-size: 0.78rem;
  font-weight: 700;
  letter-spacing: 0.10em;
  text-transform: uppercase;
  color: var(--editorial-muted, rgba(15, 16, 18, 0.48));
  user-select: none;
}

.submit-details-summary::-webkit-details-marker { display: none; }

.submit-details-summary::before { content: "▸ "; font-size: 0.65rem; }
.portfolio-submit-details[open] .submit-details-summary::before { content: "▾ "; }
