:root {
  --ink: #102742;
  --muted: #5d6f7f;
  --line: #cfdce7;
  --paper: #f8fbff;
  --surface: #ffffff;
  --soft: #eef7f4;
  --rose: #0b4797;
  --green: #079b5f;
  --gold: #11a36a;
  --blue: #0b4797;
  --deep-blue: #07377d;
  --shadow: 0 18px 50px rgba(7, 55, 125, 0.13);
}

* { box-sizing: border-box; }

body {
  margin: 0;
  min-height: 100vh;
  color: var(--ink);
  background: linear-gradient(135deg, #f8fbff 0%, #ffffff 48%, #edf9f4 100%);
  font-family: Arial, Helvetica, sans-serif;
}

button, input, select, textarea { font: inherit; }
button { cursor: pointer; }

.hidden { display: none !important; }

.login-screen {
  min-height: 100vh;
  display: grid;
  grid-template-columns: minmax(0, 1.1fr) minmax(320px, 460px);
  gap: 48px;
  align-items: center;
  padding: clamp(22px, 5vw, 72px);
}

.login-brand h1 {
  margin: 8px 0 14px;
  font-size: clamp(42px, 8vw, 94px);
  line-height: .95;
}

.brand-copy {
  max-width: 620px;
  color: var(--muted);
  font-size: clamp(17px, 2vw, 22px);
}

.login-logo {
  width: min(270px, 76vw);
  height: auto;
  display: block;
  margin-bottom: 20px;
}

.eyebrow {
  margin: 0;
  color: var(--rose);
  font-size: 12px;
  font-weight: 800;
  letter-spacing: 0;
  text-transform: uppercase;
}

.hero-visual {
  margin-top: 32px;
  max-width: 520px;
  aspect-ratio: 16 / 8;
  border: 1px solid var(--line);
  background:
    linear-gradient(90deg, rgba(11,71,151,.1) 1px, transparent 1px),
    linear-gradient(rgba(7,155,95,.1) 1px, transparent 1px),
    #fff;
  background-size: 42px 42px;
  border-radius: 8px;
  position: relative;
  overflow: hidden;
}

.body-map {
  position: absolute;
  inset: 18px;
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 14px;
}

.body-map span {
  border: 2px solid rgba(11,71,151,.16);
  border-radius: 50% 50% 42% 42%;
  background: linear-gradient(180deg, rgba(7,155,95,.16), rgba(11,71,151,.08));
}

.login-card, .panel, .form-sheet {
  background: rgba(255,255,255,.92);
  border: 1px solid var(--line);
  border-radius: 8px;
  box-shadow: var(--shadow);
}

.login-card {
  padding: 30px;
  display: grid;
  gap: 18px;
}

.login-card h2, .topbar h2 {
  margin: 4px 0 0;
  font-size: 28px;
}

label {
  display: grid;
  gap: 7px;
  color: #35414c;
  font-size: 13px;
  font-weight: 700;
}

input, select, textarea {
  width: 100%;
  min-height: 42px;
  border: 1px solid var(--line);
  border-radius: 6px;
  padding: 10px 12px;
  color: var(--ink);
  background: #fff;
}

textarea { resize: vertical; }

.primary-button, .secondary-button, .ghost-button, .icon-button {
  min-height: 42px;
  border-radius: 6px;
  border: 1px solid transparent;
  padding: 10px 14px;
  font-weight: 800;
}

.primary-button { color: #fff; background: var(--blue); }
.secondary-button { color: var(--green); background: #edf9f4; border-color: #b9dfd0; }
.ghost-button { color: var(--ink); background: transparent; border-color: var(--line); }
.icon-button { width: 42px; padding: 0; background: #fff; border-color: var(--line); }

.form-error { min-height: 18px; margin: 0; color: #a72c3c; font-size: 13px; }
.hint { margin: 0; color: var(--muted); font-size: 12px; }

.app-shell {
  min-height: 100vh;
  display: grid;
  grid-template-columns: 280px minmax(0, 1fr);
}

.sidebar {
  position: sticky;
  top: 0;
  height: 100vh;
  padding: 22px;
  display: flex;
  flex-direction: column;
  gap: 24px;
  background: linear-gradient(180deg, var(--deep-blue), #0b4797 54%, #078a59);
  color: #fff;
}

.side-brand {
  display: inline-block;
  padding: 12px;
  background: #fff;
  border-radius: 8px;
}

.side-logo {
  width: min(100%, 220px);
  height: auto;
  display: block;
}

.nav-tabs {
  display: grid;
  gap: 8px;
}

.nav-tabs button {
  min-height: 44px;
  text-align: left;
  color: #dfe8e8;
  border: 1px solid transparent;
  background: transparent;
  border-radius: 6px;
  padding: 10px 12px;
  font-weight: 700;
}

.nav-tabs button.active {
  color: #fff;
  background: rgba(255,255,255,.16);
  border-color: rgba(255,255,255,.16);
}

.sidebar .ghost-button {
  margin-top: auto;
  color: #fff;
  border-color: rgba(255,255,255,.22);
}

.main-panel {
  min-width: 0;
  padding: clamp(16px, 3vw, 34px);
}

.topbar {
  display: flex;
  gap: 16px;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 22px;
}

.top-actions { display: flex; gap: 10px; align-items: center; }

.view { display: none; }
.view.active { display: block; }

.stats-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(160px, 1fr));
  gap: 14px;
  margin-bottom: 18px;
}

.stat {
  padding: 18px;
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: 8px;
}

.stat strong {
  display: block;
  font-size: 32px;
  margin-top: 8px;
}

.content-grid {
  display: grid;
  grid-template-columns: minmax(300px, 420px) minmax(0, 1fr);
  gap: 18px;
  align-items: start;
}

.admin-grid {
  display: grid;
  grid-template-columns: minmax(0, 1.35fr) minmax(320px, .65fr);
  gap: 18px;
  align-items: start;
}

.panel { padding: 18px; }

.panel h3, .form-sheet h3 {
  margin: 0 0 16px;
  font-size: 20px;
}

.area-header {
  display: grid;
  grid-template-columns: 148px minmax(0, 1fr);
  gap: 18px;
  align-items: center;
  margin: 0 0 18px;
  padding: 0 0 16px;
  border-bottom: 3px solid var(--blue);
}

.area-header img {
  width: 138px;
  height: auto;
  display: block;
}

.area-header h3 {
  margin: 3px 0 4px;
  color: var(--blue);
  font-size: clamp(26px, 4vw, 40px);
  line-height: 1;
  text-transform: uppercase;
}

.area-header span {
  color: var(--green);
  font-size: 13px;
  font-weight: 800;
  text-transform: uppercase;
}

.student-form-header {
  display: grid;
  grid-template-columns: 116px minmax(0, 1fr);
  gap: 14px;
  align-items: center;
  margin: -2px 0 18px;
  padding: 12px 0 14px;
  border-bottom: 2px solid var(--blue);
}

.student-form-header img {
  width: 108px;
  height: auto;
  display: block;
}

.student-form-header h3 {
  margin: 3px 0 4px;
  color: var(--blue);
  font-size: 24px;
  text-transform: uppercase;
}

.student-form-header span {
  color: var(--green);
  font-size: 12px;
  font-weight: 800;
  text-transform: uppercase;
}

.panel-note {
  margin: -6px 0 16px;
  color: var(--muted);
  font-size: 14px;
  line-height: 1.45;
}

.form-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px;
}

.form-grid .full { grid-column: 1 / -1; }

.actions-row {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-top: 16px;
}

.table-wrap {
  overflow-x: auto;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fff;
}

table {
  width: 100%;
  border-collapse: collapse;
  min-width: 720px;
}

th, td {
  padding: 11px 12px;
  border-bottom: 1px solid var(--line);
  text-align: left;
  vertical-align: top;
  font-size: 13px;
}

th {
  background: #f2f5f4;
  color: #3b4852;
  font-size: 12px;
  text-transform: uppercase;
}

tr:last-child td { border-bottom: 0; }

.row-actions {
  display: flex;
  gap: 8px;
  white-space: nowrap;
}

.row-actions.wrap {
  flex-wrap: wrap;
  white-space: normal;
}

.link-button {
  border: 0;
  background: transparent;
  color: var(--blue);
  padding: 0;
  font-weight: 800;
}

.danger { color: #a72c3c; }

.form-sheet {
  padding: clamp(14px, 2.6vw, 28px);
}

.sheet-header {
  display: grid;
  grid-template-columns: 150px minmax(0, 1fr) auto;
  gap: 14px;
  align-items: center;
  padding-bottom: 14px;
  border-bottom: 2px solid var(--blue);
  margin-bottom: 16px;
}

.sheet-logo {
  width: 140px;
  height: auto;
  display: block;
}

.sheet-heading {
  min-width: 0;
}

.sheet-title {
  margin: 2px 0 0;
  font-size: clamp(22px, 4vw, 34px);
  text-transform: uppercase;
}

.sheet-code {
  min-width: 150px;
  border: 1px solid var(--blue);
  padding: 8px;
  font-size: 12px;
}

.fieldset {
  margin: 16px 0;
  padding: 0;
  border: 0;
}

.fieldset legend {
  width: 100%;
  margin-bottom: 10px;
  padding: 8px 10px;
  color: #fff;
  background: var(--blue);
  border-radius: 6px;
  font-weight: 800;
}

.measure-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 10px;
}

.anthro-layout {
  grid-template-columns: minmax(0, 1fr);
}

.anthro-sheet {
  max-width: 820px;
  margin: 0 auto;
  background: #fff;
  border: 1px solid #c9d0d6;
  color: #102236;
}

.anthro-logo-wrap {
  display: flex;
  justify-content: center;
  padding: 4px 0 16px;
}

.anthro-logo {
  width: min(260px, 70vw);
  height: auto;
  display: block;
}

.anthro-title-bar {
  margin: 0 0 18px;
  padding: 10px 14px;
  color: #fff;
  background: var(--blue);
  border-radius: 4px;
  text-align: center;
  font-size: 18px;
  font-weight: 800;
  text-transform: uppercase;
}

.anthro-block {
  margin: 0 0 16px;
  border: 1px solid #b9c2cc;
  border-radius: 4px;
  overflow: hidden;
}

.anthro-block h3 {
  margin: 0;
  padding: 8px 10px;
  color: #fff;
  background: var(--green);
  font-size: 13px;
  text-transform: uppercase;
}

.anthro-lines {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 0;
  border-top: 1px solid #b9c2cc;
}

.line-field {
  min-height: 58px;
  padding: 7px 8px;
  border-right: 1px solid #d5dbe1;
  border-bottom: 1px solid #d5dbe1;
  gap: 4px;
  color: #1d364f;
  font-size: 11px;
  font-weight: 800;
  text-transform: uppercase;
}

.line-field.wide { grid-column: span 2; }
.line-field.full { grid-column: 1 / -1; }

.line-field input,
.line-field select,
.line-field textarea,
.anthro-row input {
  min-height: 30px;
  padding: 4px 2px;
  border: 0;
  border-bottom: 1px solid #667788;
  border-radius: 0;
  background: transparent;
  font-size: 14px;
  font-weight: 500;
}

.line-field textarea {
  min-height: 86px;
  border: 1px solid #b9c2cc;
  padding: 8px;
}

.line-input {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 5px;
  align-items: end;
}

.line-input small {
  padding-bottom: 6px;
  color: var(--muted);
  font-size: 11px;
}

.anthro-table {
  display: grid;
  border-top: 1px solid #b9c2cc;
}

.anthro-row {
  display: grid;
  grid-template-columns: 1.1fr 1fr 1fr;
  min-height: 48px;
  border-bottom: 1px solid #d5dbe1;
}

.anthro-row:last-child { border-bottom: 0; }

.anthro-row strong,
.anthro-row label,
.anthro-row span {
  padding: 8px;
  border-right: 1px solid #d5dbe1;
}

.anthro-row strong {
  display: grid;
  align-items: center;
  color: #1d364f;
  background: #f2f8ff;
  font-size: 12px;
  text-transform: uppercase;
}

.anthro-row label {
  gap: 4px;
  color: #425462;
  font-size: 11px;
  text-transform: uppercase;
}

.anthro-row span { border-right: 0; }

.pdf-anthro-sheet {
  width: 100%;
  max-width: 1180px;
  padding: 12px;
  background: #fff;
}

.pdf-form-canvas {
  position: relative;
  width: 100%;
  aspect-ratio: 3 / 2;
  background: #fff;
  border: 1px solid #d8dee4;
  overflow: hidden;
}

.pdf-bg-image {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: contain;
  display: block;
  user-select: none;
  pointer-events: none;
}

.date-mask {
  position: absolute;
  z-index: 1;
  display: block;
  background: #fff;
  pointer-events: none;
}

.pdf-field {
  position: absolute;
  z-index: 2;
  min-height: 0;
  border: 0;
  border-radius: 0;
  padding: 1px 3px;
  background: rgba(255,255,255,.46);
  color: #0d223b;
  font-size: 12px;
  font-weight: 700;
  outline: 1px solid transparent;
}

.anthro-date-mask {
  left: 6.35%;
  top: 21.6%;
  width: 8%;
  height: 2.65%;
}

.pdf-field:focus {
  background: rgba(255,255,255,.95);
  outline-color: var(--green);
}

.pdf-name {
  left: 5.65%;
  top: 17.35%;
  width: 18.75%;
  height: 2.35%;
}

.pdf-date {
  left: 6.85%;
  top: 21.72%;
  width: 7.15%;
  height: 2.25%;
  text-align: center;
}

.pdf-age {
  left: 18.35%;
  top: 21.72%;
  width: 6.05%;
  height: 2.25%;
  text-align: center;
}

.pdf-evaluator {
  left: 8.7%;
  top: 26.18%;
  width: 15.7%;
  height: 2.3%;
}

.pdf-general-notes {
  left: 1.8%;
  top: 38.4%;
  width: 22.7%;
  height: 57.4%;
  resize: none;
  line-height: 2.34;
  background: rgba(255,255,255,.42);
}

.pdf-table-input {
  width: 4.55%;
  height: 2.9%;
  text-align: center;
  background: rgba(255,255,255,.34);
  font-size: 12px;
}

.pdf-bottom-notes {
  left: 27.4%;
  top: 91.3%;
  width: 40.8%;
  height: 5.3%;
  resize: none;
  line-height: 1.55;
  background: rgba(255,255,255,.42);
}

.pdf-check {
  position: absolute;
  width: 1.03%;
  height: 1.55%;
  min-height: 0;
  margin: 0;
  padding: 0;
  accent-color: var(--green);
}

.pdf-retencao { left: 73.08%; top: 92.42%; }
.pdf-flacidez { left: 81.63%; top: 92.42%; }
.pdf-celulite { left: 87.92%; top: 92.42%; }
.pdf-estrias { left: 73.08%; top: 95.45%; }
.pdf-assimetria { left: 81.63%; top: 95.45%; }
.pdf-outros { left: 87.92%; top: 95.45%; }

.pdf-other-text {
  left: 90.92%;
  top: 95.32%;
  width: 7.22%;
  height: 2.05%;
  background: rgba(255,255,255,.55);
}

.pdf-mini-report {
  margin-top: 10px;
}

.physical-layout {
  grid-template-columns: minmax(0, 1fr);
}

.physical-pdf-sheet {
  width: 100%;
  max-width: 860px;
  padding: 12px;
  background: #fff;
}

.physical-form-canvas {
  position: relative;
  width: 100%;
  aspect-ratio: 2 / 3;
  background: #fff;
  border: 1px solid #d8dee4;
  overflow: hidden;
}

.physical-bg-image {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: contain;
  display: block;
  pointer-events: none;
  user-select: none;
}

.physical-field {
  position: absolute;
  z-index: 2;
  min-height: 0;
  border: 0;
  border-radius: 0;
  padding: 1px 3px;
  background: rgba(255,255,255,.48);
  color: #0d223b;
  font-size: 12px;
  font-weight: 700;
  outline: 1px solid transparent;
}

.physical-field:focus {
  background: rgba(255,255,255,.94);
  outline-color: var(--green);
}

.physical-check {
  position: absolute;
  z-index: 2;
  width: 1.9%;
  height: 1.35%;
  min-height: 0;
  margin: 0;
  padding: 0;
  accent-color: var(--green);
}

.phys-date-mask-main {
  left: 80.05%;
  top: 8.55%;
  width: 17.3%;
  height: 2.05%;
}

.phys-date-mask-birth {
  left: 19.55%;
  top: 19.65%;
  width: 17.65%;
  height: 2.05%;
}

.phys-date-mask-peso {
  left: 12.05%;
  top: 47.02%;
  width: 11.65%;
  height: 1.9%;
}

.phys-date-mask-altura {
  left: 36.68%;
  top: 47.02%;
  width: 11.4%;
  height: 1.9%;
}

.phys-date-mask-gordura {
  left: 85.05%;
  top: 47.02%;
  width: 11.5%;
  height: 1.9%;
}

.layout-editing .pdf-field,
.layout-editing .pdf-check,
.layout-editing .physical-field,
.layout-editing .physical-check {
  cursor: move;
  outline: 2px dashed #079b5f;
  background-color: rgba(255,255,255,.86);
  z-index: 4;
}

.layout-editing .dragging-field {
  outline-color: #0b4797;
  box-shadow: 0 0 0 3px rgba(11, 71, 151, .18);
}

.layout-editing .pdf-form-canvas::after,
.layout-editing .physical-form-canvas::after {
  content: "Modo reposicionamento: arraste os campos com o mouse";
  position: absolute;
  left: 12px;
  bottom: 12px;
  z-index: 3;
  padding: 8px 10px;
  color: #fff;
  background: rgba(11, 71, 151, .9);
  border-radius: 6px;
  font-size: 12px;
  font-weight: 800;
  pointer-events: none;
}

.phys-numero { left: 87.25%; top: 5.92%; width: 10.2%; height: 1.35%; text-align: center; }
.phys-data { left: 80.05%; top: 8.82%; width: 17.25%; height: 1.35%; text-align: center; }
.phys-nome { left: 8.85%; top: 16.42%; width: 40.2%; height: 1.5%; }
.phys-sexo-m { left: 61.45%; top: 15.78%; }
.phys-sexo-f { left: 74.88%; top: 15.78%; }
.phys-sexo-o { left: 86.6%; top: 15.78%; }
.phys-nascimento { left: 19.65%; top: 19.9%; width: 17.45%; height: 1.35%; text-align: center; }
.phys-telefone { left: 66.35%; top: 19.85%; width: 27.15%; height: 1.4%; }
.phys-idade { left: 8.85%; top: 23.2%; width: 11.1%; height: 1.35%; text-align: center; }
.phys-email { left: 59.45%; top: 24.72%; width: 36.55%; height: 1.4%; }
.phys-profissao { left: 12.45%; top: 27.78%; width: 36.45%; height: 1.4%; }

.phys-peso { left: 5.1%; top: 39.05%; width: 14%; height: 1.65%; text-align: center; }
.phys-peso-equipamento { left: 11.05%; top: 44.02%; width: 12.65%; height: 1.25%; }
.phys-peso-data { left: 12.05%; top: 47.27%; width: 11.6%; height: 1.25%; text-align: center; }
.phys-peso-horario { left: 8.25%; top: 50.53%; width: 15.4%; height: 1.25%; }

.phys-altura { left: 29.68%; top: 39.05%; width: 13.75%; height: 1.65%; text-align: center; }
.phys-altura-equipamento { left: 35.65%; top: 44.02%; width: 12.4%; height: 1.25%; }
.phys-altura-data { left: 36.68%; top: 47.27%; width: 11.35%; height: 1.25%; text-align: center; }
.phys-altura-horario { left: 32.85%; top: 50.53%; width: 15.2%; height: 1.25%; }

.phys-imc { left: 53.42%; top: 39.05%; width: 13.95%; height: 1.65%; text-align: center; }
.phys-imc-classificacao { left: 60.55%; top: 44.86%; width: 11.6%; height: 1.35%; }

.phys-gordura { left: 77.85%; top: 39.05%; width: 13.9%; height: 1.65%; text-align: center; }
.phys-gordura-equipamento { left: 83.95%; top: 44.02%; width: 12.65%; height: 1.25%; }
.phys-gordura-data { left: 85.05%; top: 47.27%; width: 11.45%; height: 1.25%; text-align: center; }
.phys-gordura-horario { left: 81.15%; top: 50.53%; width: 15.35%; height: 1.25%; }

.phys-comp {
  left: 24%;
  width: 24.6%;
  height: 1.55%;
  text-align: right;
  background: rgba(255,255,255,.35);
}
.phys-comp-1 { top: 59.36%; }
.phys-comp-2 { top: 62.28%; }
.phys-comp-3 { top: 65.23%; }
.phys-comp-4 { top: 68.16%; }
.phys-comp-5 { top: 71.1%; }
.phys-comp-6 { top: 74.03%; }
.phys-comp-7 { top: 76.96%; }

.phys-observacoes {
  left: 58.05%;
  top: 59.25%;
  width: 39.1%;
  height: 18.25%;
  resize: none;
  line-height: 1.95;
  background: rgba(255,255,255,.38);
}

.phys-prof-nome { left: 11.45%; top: 92.86%; width: 78.55%; height: 1.3%; }
.phys-prof-registro { left: 22.55%; top: 94.98%; width: 67.45%; height: 1.25%; }
.phys-prof-assinatura { left: 26.45%; top: 96.78%; width: 47.2%; height: 1.22%; text-align: center; }

.two-col {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px;
}

.mini-report {
  margin-top: 16px;
  padding: 14px;
  border: 1px dashed var(--line);
  border-radius: 8px;
  background: #fff;
}

.mini-report p { margin: 6px 0; color: var(--muted); }

.student-portal {
  display: grid;
  gap: 18px;
}

.portal-hero {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(220px, 300px);
  gap: 18px;
  align-items: center;
  padding: 16px 18px;
  background: #fff;
  border: 1px solid var(--line);
  border-radius: 8px;
  box-shadow: var(--shadow);
}

.portal-hero h3 {
  margin: 0;
  color: var(--blue);
  font-size: clamp(22px, 3.2vw, 34px);
  text-transform: uppercase;
}

.portal-hero p {
  margin: 0;
  color: var(--muted);
}

.portal-badge {
  justify-self: end;
  padding: 10px 12px;
  color: var(--green);
  background: #edf9f4;
  border: 1px solid #b9dfd0;
  border-radius: 6px;
  font-size: 13px;
  font-weight: 800;
}

.portal-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 14px;
}

.portal-card {
  padding: 16px;
  background: #fff;
  border: 1px solid var(--line);
  border-top: 4px solid var(--green);
  border-radius: 8px;
}

.portal-card h4 {
  margin: 0 0 10px;
  color: var(--blue);
  font-size: 16px;
}

.portal-card p {
  margin: 7px 0;
  color: #34495c;
  font-size: 13px;
  line-height: 1.4;
}

@media (max-width: 960px) {
  .login-screen, .app-shell, .content-grid, .admin-grid {
    grid-template-columns: 1fr;
  }

  .sidebar {
    position: static;
    height: auto;
  }

  .nav-tabs {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .stats-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .portal-hero, .portal-grid {
    grid-template-columns: 1fr 1fr;
  }
}

@media (max-width: 620px) {
  .login-screen { padding: 16px; }
  .login-card { padding: 20px; }
  .topbar { align-items: flex-start; flex-direction: column; }
  .top-actions { width: 100%; }
  .secondary-button { flex: 1; }
  .nav-tabs, .stats-grid, .form-grid, .measure-grid, .two-col {
    grid-template-columns: 1fr;
  }
  .anthro-lines, .anthro-row {
    grid-template-columns: 1fr;
  }
  .portal-hero, .portal-grid {
    grid-template-columns: 1fr;
  }
  .area-header, .student-form-header {
    grid-template-columns: 1fr;
  }
  .area-header img {
    width: 128px;
  }
  .line-field.wide { grid-column: auto; }
  .sheet-header { grid-template-columns: 1fr; }
}

@media print {
  body { background: #fff; }
  .sidebar, .topbar, .panel:not(.printable), .actions-row, .login-screen { display: none !important; }
  .app-shell, .main-panel { display: block; padding: 0; }
  .view { display: none !important; }
  .view.active { display: block !important; }
  .form-sheet { box-shadow: none; border: 0; padding: 0; }
  input, select, textarea { border-color: #999; min-height: 34px; }
  .pdf-form-canvas {
    border: 0;
    -webkit-print-color-adjust: exact;
    print-color-adjust: exact;
  }
  .pdf-bg-image {
    display: block !important;
    -webkit-print-color-adjust: exact;
    print-color-adjust: exact;
  }
  .physical-form-canvas {
    border: 0;
    -webkit-print-color-adjust: exact;
    print-color-adjust: exact;
  }
  .physical-bg-image {
    display: block !important;
    -webkit-print-color-adjust: exact;
    print-color-adjust: exact;
  }
  .anthro-logo { width: 210px; }
  .anthro-title-bar, .anthro-block h3 {
    -webkit-print-color-adjust: exact;
    print-color-adjust: exact;
  }
}
