/* Fase 5B. Sistema editorial compartido; no modifica contenidos ni lógica. */
:root {
  --font-body: 'Nunito', 'Trebuchet MS', sans-serif;
  --space-1: .5rem;
  --space-2: 1rem;
  --space-3: 1.5rem;
  --space-4: 2rem;
  --space-5: 3rem;
  --space-section: clamp(2.5rem, 4vw, 4rem);
  --radius-control: .875rem;
  --radius-card: 1.125rem;
  --radius-soft: 1.5rem;
  --shadow-soft: 0 4px 18px #0f4c5c08;
  --shadow-lift: 0 8px 24px #0f4c5c12;
  --line-soft: #0f4c5c14;
  --surface-sky: #eaf6fb;
  --surface-coral: #fff0ec;
  --surface-butter: #fff5d8;
  --surface-mint: #edf6ef;
}
body { font-family: var(--font-body); line-height: 1.55; }
h1, h2, h3, h4 { letter-spacing: -.025em; }
h1 { font-size: clamp(2.25rem, 3.8vw, 3.6rem); line-height: 1.12; }
h2 { font-size: clamp(1.5rem, 2.2vw, 2rem); line-height: 1.2; }
h3 { font-size: 1.25rem; line-height: 1.3; }
.wrap { max-width: 1360px; padding-inline: 36px; }
main, main > *, .detail-layout > *, .as-layout > * { min-width: 0; }
img { max-width: 100%; }
.topbar { background: var(--cream); border-color: var(--line-soft); box-shadow: none; }
.header { min-height: 88px; gap: 22px; }
.brand { gap: 7px; }
.brand-mark { width: 36px; height: 44px; }
.brand strong { font-size: 1.5rem; letter-spacing: -.035em; }
.brand small { font-size: .75rem; font-weight: 600; }
.header nav { gap: 20px; font-size: .875rem; }
.header nav a { line-height: 1.35; }
.header > .btn { flex-shrink: 0; }
.btn { border-radius: var(--radius-control); min-height: 48px; padding: 12px 18px; box-shadow: none; font-size: .9375rem; }
.btn.small { min-height: 44px; }
.btn:hover:not(:disabled) { box-shadow: var(--shadow-soft); transform: translateY(-1px); }
.btn:active:not(:disabled) { transform: translateY(0); box-shadow: none; }
.btn:disabled { transform: none; box-shadow: none; }
:is(a, button, input, select, textarea, summary):focus-visible { outline: 3px solid var(--navy); outline-offset: 4px; }
.search-form:focus-within { outline: 2px solid var(--navy); outline-offset: 3px; }
.btn.primary { background: var(--navy); border-color: var(--navy); }
.textlink { min-height: 40px; white-space: normal; }
.iconbox { border-radius: 50%; }
svg { stroke-width: 1.8; }

/* Home: la ilustración forma parte de la composición, sin tarjeta envolvente. */
.hero { background: transparent; border-radius: 0; overflow: visible; min-height: 0; margin-top: 0; padding: 52px 0 38px; grid-template-columns: minmax(0, 1.08fr) minmax(0, .92fr); gap: 28px; }
.hero::before, .hero::after { display: none; }
.hero .eyebrow { margin-bottom: 18px; font-size: .9375rem; font-weight: 700; }
.hero h1 { font-size: clamp(2.75rem, 4.6vw, 4.25rem); line-height: 1.07; letter-spacing: -.035em; max-width: 680px; text-wrap: balance; }
.hero h1 br { display: initial; }
.hero h1::after { width: 100px; height: 5px; margin-top: 19px; }
.hero p { margin-top: 24px; font-size: 1.1875rem; line-height: 1.5; }
.hero-search-label { display: block; margin-top: 28px; margin-bottom: 10px; color: var(--navy); font-size: 1.125rem; font-weight: 800; }
.hero .search-form { margin-top: 0; min-height: 66px; border-radius: 100px; padding: 7px 7px 7px 20px; box-shadow: var(--shadow-soft); gap: 12px; }
.hero .search-form input { font-size: 1rem; }
.hero .search-form .btn { min-height: 50px; border-radius: 100px; padding-inline: 24px; }
.hero .grades { margin-top: 24px; gap: 8px; }
.hero .grades .label { width: 100%; font-size: .875rem; margin: 0 0 2px; }
.hero .chip { min-height: 46px; min-width: 53px; padding: 10px 13px; box-shadow: none; border: 0; border-radius: 13px; font-size: 1rem; }
.hero .chip.pending { order: 2; font-size: .8125rem; background: transparent; min-width: 0; }
.hero-art { width: 100%; max-width: none; display: block; margin: 0; align-self: center; }
.hero-art img { display: block; width: 100%; height: auto; aspect-ratio: 3 / 2; object-fit: contain; object-position: center; border: 0; border-radius: 0; box-shadow: none; }
.art-label { position: static; margin: 8px 16px 0; padding: 12px 16px; border: 0; background: var(--surface-butter); box-shadow: none; border-radius: 14px; font-size: .875rem; }
.art-label > span { background: var(--yellow); }
.home-page > .section { padding: var(--space-section) 0 0; }
.home-page > .home-subjects { padding-top: 20px; }
.section-head { margin-bottom: 22px; gap: 20px; }
.section-head p { margin-top: 7px; font-size: 1rem; }
.subjects { grid-template-columns: repeat(5, minmax(0, 1fr)); gap: 12px; }
.subject { min-height: 91px; padding: 16px; flex-direction: row; justify-content: flex-start; gap: 12px; text-align: left; border: 1px solid transparent; border-radius: 15px; background: #ffffff85; box-shadow: none; font-size: .9375rem; position: relative; }
.subject .iconbox { flex: none; width: 40px; height: 40px; border-radius: 13px; }
.subject .iconbox svg { width: 24px; height: 24px; }
.subject.pending { background: transparent; flex-wrap: wrap; gap: 5px 12px; }
.subject.pending small { display: block; width: 100%; font-size: .75rem; }
.subject:hover { box-shadow: var(--shadow-soft); transform: translateY(-1px); }
.home-needs { padding-top: var(--space-section) !important; }
.needs { grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 12px; }
.need { border: 1px solid var(--line-soft); box-shadow: none; border-radius: 15px; padding: 16px 18px; min-height: 72px; font-size: .9375rem; }
.need.need-time { min-height: 92px; font-size: 1.0625rem; background: var(--surface-coral); border-color: transparent; }
.need.need-time:nth-child(2) { background: var(--surface-butter); }
.need.need-time:nth-child(3) { background: var(--surface-mint); }
.need.need-time .iconbox { width: 44px; height: 44px; background: white; }
.need-secondary { background: transparent; }
.need-secondary .iconbox { background: transparent; width: 32px; height: 32px; }
.need.pending { background: transparent; }
.pending small { display: block; margin-top: 3px; }
.access-grid { gap: 16px; }
.access-card { min-height: 112px; border: 0; padding: 20px; box-shadow: none; border-radius: var(--radius-card); }
.access-card small { font-size: .875rem; }
.home-tools-grid { gap: 20px; }
.home-tool-feature { box-shadow: none; border-radius: var(--radius-soft); }
.home-tool-links a { box-shadow: none; border-color: var(--line-soft); }
.ribbon { margin-top: 36px; background: var(--surface-butter); border: 0; padding: 28px; box-shadow: none; }
.footer { background: transparent; border-color: var(--line-soft); margin-top: var(--space-section); }
.footer-inner p, .footer-links { font-size: .875rem; }

/* La misma tarjeta editorial en Biblioteca, Home y Mi Aula. */
.cards { gap: 24px; }
.card { border-radius: var(--radius-card); border: 1px solid var(--line-soft); box-shadow: var(--shadow-soft); }
.card:hover { transform: translateY(-2px); box-shadow: var(--shadow-lift); }
.card .cover,
.card .cover:has(> .activity-cover) { height: 7rem; flex: 0 0 auto; aspect-ratio: auto; margin: 6px 6px 0; border-radius: 13px; }
.card .cover img { width: 100%; height: 100%; object-fit: contain; }
.cover .cover-type { top: 12px; left: 12px; bottom: auto; max-width: calc(100% - 76px); font-size: .75rem; line-height: 1.35; padding: 6px 9px; letter-spacing: 0; text-transform: none; border-radius: 8px; box-shadow: none; }
.save-icon { width: 44px; height: 44px; top: 14px; right: 14px; box-shadow: var(--shadow-soft); }
.card .save-icon { top: 10px; right: 10px; box-shadow: none; background: #fffffff0; }
.card .save-icon.saved { background: #fff3f0; }
.card .save-icon svg { width: 18px; height: 18px; }
.card-body { padding: 22px 22px 16px; }
.card h3 { font-size: 1.4375rem; line-height: 1.25; color: var(--navy); overflow-wrap: break-word; }
.card-meta { font-size: .9375rem; line-height: 1.45; margin-top: 12px; color: #426573; }
.card-details { display: flex; flex-wrap: wrap; align-items: center; gap: 8px 12px; margin-top: 12px; }
.card-type { padding: 4px 8px; border-radius: 6px; background: var(--surface-sky); color: #426573; font-size: .8125rem; line-height: 1.4; font-weight: 700; }
.card-duration { font-size: .875rem; line-height: 1.45; align-items: flex-start; }
.card-details .card-duration { margin-top: 0; font-weight: 700; color: #426573; }
.card-duration svg { margin-top: 2px; }
.card p { font-size: .9375rem; line-height: 1.5; margin-top: 12px; }
.card-footer { padding: 12px 22px 18px; border: 0; font-size: .9375rem; }
.card-footer .arrow { background: var(--surface-sky); width: 28px; height: 28px; }

/* Biblioteca: controles discretos, resultados protagonistas. */
.breadcrumb { flex-wrap: wrap; padding: 25px 0 18px; font-size: .875rem; }
.page-title { padding: 4px 0 32px; }
.page-title h1 { font-size: clamp(2.25rem, 3.8vw, 3.5rem); }
.page-title p { font-size: 1.0625rem; max-width: 65ch; }
.page-title .search-form { max-width: 800px; border-radius: 100px; box-shadow: var(--shadow-soft); }
.page-title .search-form .btn { border-radius: 100px; }
.library-layout { grid-template-columns: 242px minmax(0, 1fr); gap: 32px; }
.filters { padding: 22px; border-color: var(--line-soft); box-shadow: none; border-radius: var(--radius-card); }
.filter-heading { margin-bottom: 18px; }
.filter-heading h3 { font-size: 1.125rem; }
.field { font-size: .875rem; gap: 8px; }
.field select, .field input, select { font-size: 1rem; min-height: 46px; border-radius: 10px; }
.results-head { padding: 3px 0 18px; margin-bottom: 22px; border-bottom: 1px solid var(--line-soft); }
.results-head p, .results-head strong { font-size: 1rem; }
.results-head .pill { font-size: .8125rem; padding: 6px 10px; }
.filter-chip { font-size: .875rem; min-height: 40px; }
.empty { border: 1px dashed #b8d1d3; border-radius: var(--radius-card); box-shadow: none; padding: 40px 24px; }
.library-results .cards { grid-template-columns: repeat(2, minmax(0, 1fr)); }

/* Ficha: encabezado abierto y módulos docentes en dos columnas. */
.detail-layout { grid-template-columns: minmax(0, 1fr) 320px; gap: 32px; }
.detail-intro { padding: 10px 0 30px; margin-bottom: 0; background: transparent; border-radius: 0; overflow: visible; }
.detail-intro::after { display: none; }
.detail-intro h1 { font-size: clamp(2.3rem, 3.5vw, 3.5rem); letter-spacing: -.025em; line-height: 1.12; overflow-wrap: break-word; }
.detail-intro > p, .detail-lead p { font-size: 1.0625rem; max-width: 62ch; line-height: 1.6; }
.detail-lead-illustrated { display: grid; grid-template-columns: minmax(0, 1.25fr) minmax(0, .75fr); align-items: center; gap: 20px; }
.detail-lead-art { min-width: 0; }
.detail-lead-art img { display: block; width: 100%; height: auto; border-radius: 42% 18% 36% 14%; }
.badges { margin-top: 20px; gap: 8px; }
.pill { font-size: .8125rem; border-radius: 11px; padding: 8px 11px; }
.warm { font-size: .75rem; letter-spacing: .035em; }
.detail-actions { margin-top: 24px; gap: 10px; }
.detail-actions .btn { padding: 12px 15px; min-height: 48px; font-size: .9375rem; }
.secondary-actions { gap: 14px 22px; margin-top: 14px; flex-wrap: wrap; }
.detail-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 18px; }
.detail-grid > .detail-block:first-child { grid-column: auto; background: white; border-color: var(--line-soft); }
.detail-block { padding: 23px 20px; border: 1px solid var(--line-soft); border-radius: var(--radius-card); gap: 13px; box-shadow: none; }
.detail-block > div { min-width: 0; }
.detail-block > .iconbox { width: 37px; height: 37px; border-radius: 50%; }
.detail-block h2 { font-size: 1.125rem; line-height: 1.35; margin-top: 5px; }
.detail-block p, .checklist, .steps { font-size: 1rem; line-height: 1.6; }
.detail-aside { display: block; position: sticky; top: 108px; }
.summary-card { border: 1px solid var(--line-soft); border-radius: var(--radius-card); padding: 14px; box-shadow: var(--shadow-soft); }
.summary-card > .cover { height: auto; aspect-ratio: 3 / 2; border-radius: 12px; }
.summary-card > .cover img { object-fit: contain; }
.summary-data { padding: 20px 8px; gap: 17px; }
.summary-data b, .summary-data small { font-size: .875rem; }
.teacher-note { padding: 15px; background: var(--surface-sky); border-radius: 13px; }
.teacher-note p { font-size: .9375rem; }
.downloads-box { margin-top: 18px; padding: 20px; border: 1px solid var(--line-soft); background: white; border-radius: var(--radius-card); }
.downloads-box h3 { font-size: 1.125rem; }
.downloads-box p { font-size: .875rem; }
.downloads-box a { min-height: 52px; padding: 10px 12px; font-size: .875rem; border-color: var(--line-soft); border-radius: 10px; box-shadow: none; align-items: center; }
.downloads-box a span { min-width: 0; }
.downloads-box a small { font-size: .75rem; }
.aside-quote { border-radius: var(--radius-soft); background: var(--surface-butter); }
.lesson-box { border: 1px solid var(--line-soft); padding: 28px; background: var(--surface-mint); }

/* Mi Aula: contenido real a la izquierda, semana y acciones a la derecha. */
.aula-tabs { background: transparent; border-bottom: 1px solid var(--line-soft); padding: 0 0 12px; border-radius: 0; gap: 5px; margin: 12px 0 30px; flex-wrap: wrap; }
.aula-tabs a { min-height: 44px; font-size: .875rem; padding: 10px 12px; border-radius: 10px; }
.aula-tabs a.active { background: var(--surface-sky); box-shadow: none; }
.aula-overview-page > .page-title { padding-bottom: 12px; }
.aula-welcome { display: grid; grid-template-columns: minmax(0, 1.2fr) minmax(0, .8fr); align-items: center; gap: 30px; padding-bottom: 30px; }
.aula-welcome > div { min-width: 0; }
.aula-welcome h2 { font-size: clamp(1.8rem, 2.8vw, 2.6rem); line-height: 1.2; overflow-wrap: anywhere; }
.aula-welcome p { max-width: 50ch; font-size: 1.0625rem; }
.aula-welcome > img { width: 100%; max-height: 270px; object-fit: contain; }
.aula-welcome .account-summary { margin: 24px 0 0; gap: 12px; grid-template-columns: repeat(4, minmax(0, 1fr)); }
.aula-welcome .account-summary a { padding: 15px 12px; border: 0; border-radius: 14px; font-size: .8125rem; background: white; box-shadow: var(--shadow-soft); gap: 3px; min-width: 0; }
.account-summary a:nth-child(1) > svg { color: #ad4c50; }
.account-summary a:nth-child(2) > svg { color: #846c2f; }
.account-summary strong { font-size: 1.75rem; line-height: 1.15; }
.aula-desk { display: grid; grid-template-columns: minmax(0, 1fr) 310px; gap: 30px; align-items: start; }
.aula-desk-main, .aula-desk-side { min-width: 0; }
.aula-desk-section { margin-bottom: 36px; }
.aula-desk .section-head { margin-bottom: 18px; }
.aula-desk h2 { font-size: 1.375rem; }
.aula-desk .cards { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 20px; }
.aula-desk .card h3 { font-size: 1.375rem; }
.aula-folders { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 14px; }
.aula-folders .folder-card { padding: 20px 16px; min-height: 154px; background: var(--surface-sky); border: 0; box-shadow: none; border-radius: 15px; }
.aula-folders .folder-card:nth-child(3n+2) { background: var(--surface-mint); }
.aula-folders .folder-card:nth-child(3n) { background: var(--surface-butter); }
.aula-folders .folder-card h3 { margin-top: 13px; font-size: 1rem; overflow-wrap: anywhere; }
.aula-folders .folder-card p { font-size: .8125rem; }
.aula-desk .empty { padding: 28px 20px; }
.aula-desk .empty h3 { font-size: 1.125rem; }
.aula-week-preview { padding: 24px 20px; background: var(--surface-butter); border-radius: var(--radius-card); }
.aula-week-preview > p { font-size: .9375rem; }
.aula-week-preview ol { list-style: none; padding: 0; margin: 20px 0; }
.aula-week-preview li { display: grid; grid-template-columns: 38px minmax(0, 1fr); gap: 11px; padding: 13px 0; border-bottom: 1px solid var(--line-soft); font-size: .875rem; }
.aula-week-preview li > b { display: grid; place-items: center; width: 36px; height: 36px; border-radius: 50%; font-size: .75rem; background: white; }
.aula-week-preview li a { display: block; color: var(--navy); font-weight: 800; padding-block: 3px; }
.aula-week-preview li span { color: var(--muted); }
.aula-week-preview > .btn { width: 100%; }
.aula-desk-action { display: block; padding: 22px 20px; margin-top: 18px; border-radius: var(--radius-card); background: var(--surface-sky); width: 100%; text-align: left; }
.aula-desk-action h3 { margin: 12px 0 5px; font-size: 1.125rem; }
.aula-desk-action p { font-size: .9375rem; margin-bottom: 14px; }
.aula-desk-action > span:last-child { display: inline-flex; font-weight: 800; font-size: .9375rem; }
.aula-desk-action.folder { background: var(--surface-coral); }
.account-panel, .account-notice { border-color: var(--line-soft); border-radius: var(--radius-card); box-shadow: none; }
.week-grid { gap: 16px; }
.day-column { border-color: var(--line-soft); background: white; }
.day-title small, .day-empty, .plan-card p { font-size: .875rem; }

/* Asistente y Modo Clase comparten colores, controles y tipografía. */
.as-head { background: transparent; border: 0; padding: 12px 0 30px; border-radius: 0; }
.as-head h1 { font-size: clamp(2.25rem, 3.8vw, 3.5rem); line-height: 1.12; }
.as-head p { font-size: 1.0625rem; max-width: 58ch; }
.as-kicker { font-size: .8125rem; letter-spacing: .035em; }
.as-layout { grid-template-columns: minmax(0, .9fr) minmax(0, 1.1fr); gap: 28px; }
.as-panel, .as-preview { min-width: 0; border-color: var(--line-soft); border-radius: var(--radius-card); box-shadow: var(--shadow-soft); }
.as-preview { top: 108px; max-height: calc(100vh - 128px); }
.as-head::after { display: none; }
.as-field input, .as-field select, .as-field textarea { font-size: 1rem; }
.as-doc { box-shadow: none; }
.classroom { background: var(--cream); }
.class-header { background: var(--cream); gap: 20px; }
.class-content { padding: 42px 28px 60px; }
.class-content h1 { font-size: clamp(2rem, 3.2vw, 3.125rem); line-height: 1.22; }
.class-lead { font-size: 1.25rem; }
.answer-option { box-shadow: none; border-radius: 16px; min-height: 72px; font-size: 1.25rem; }
.feedback { font-size: 1.125rem; line-height: 1.55; box-shadow: none; }
.class-buttons .btn { min-height: 54px; }

@media (max-width: 1180px) {
  .header { gap: 18px; min-height: 82px; }
  .header nav { display: none; }
  .header > .btn { margin-left: auto; }
  .header .menu-btn { display: inline-grid; place-items: center; width: 44px; height: 44px; flex: none; }
  .header nav.open { display: flex; position: absolute; inset: 100% 24px auto; flex-direction: column; align-items: stretch; gap: 0; padding: 14px 20px; background: white; border: 1px solid var(--line); border-radius: 16px; box-shadow: var(--shadow-lift); }
  .header nav.open a { padding: 12px 8px; }
  .subjects { grid-template-columns: repeat(5, minmax(0, 1fr)); }
  .subject { flex-direction: column; justify-content: center; text-align: center; padding: 14px 8px; }
  .access-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .detail-layout { grid-template-columns: minmax(0, 1fr) 292px; gap: 24px; }
  .detail-grid { grid-template-columns: 1fr; }
  .detail-lead-illustrated { grid-template-columns: minmax(0, 1fr); }
  .detail-lead-art { max-width: 250px; margin-top: 8px; }
  .library-layout { grid-template-columns: 224px minmax(0, 1fr); gap: 24px; }
  .filter-primary, .filter-advanced { display: block; }
  .filters .apply-filter { min-width: 0; width: 100%; }
  .aula-desk { grid-template-columns: minmax(0, 1fr) 285px; gap: 24px; }
  .aula-folders { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .aula-welcome .account-summary { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}
@media (max-width: 900px) {
  .wrap { padding-inline: 28px; }
  .hero { grid-template-columns: minmax(0, 1.1fr) minmax(0, .9fr); padding: 34px 0 24px; gap: 12px; }
  .hero h1 { font-size: 2.875rem; }
  .hero p { font-size: 1.0625rem; margin-top: 18px; }
  .hero-search-label { margin-top: 22px; font-size: 1rem; }
  .hero .search-form { min-height: 60px; padding-left: 14px; gap: 8px; }
  .hero .search-form .btn { padding-inline: 16px; min-height: 46px; }
  .hero .grades { gap: 6px; }
  .hero .chip { min-width: 44px; padding-inline: 11px; }
  .art-label { margin-inline: 0; font-size: .8125rem; padding: 12px; }
  .home-featured .cards { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .home-featured .card:last-child { grid-column: 1 / -1; width: calc((100% - 24px) / 2); }
  .library-layout, .detail-layout, .aula-desk, .as-layout { grid-template-columns: minmax(0, 1fr); }
  .filters { position: static; padding: 20px; }
  .filter-primary, .filter-advanced { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 0 16px; }
  .filters .apply-filter { width: auto; }
  .detail-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .detail-aside { position: static; display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 20px; align-items: start; }
  .detail-aside .downloads-box { margin-top: 0; }
  .detail-aside > .note { grid-column: 1 / -1; }
  .detail-aside .aside-quote { margin: 0; }
  .aula-desk-side { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 18px; align-items: start; }
  .aula-week-preview { grid-row: span 2; }
  .aula-desk-action { margin-top: 0; }
  .as-preview { position: static; max-height: none; }
  .as-head em { display: none; }
  .aula-tabs { flex-wrap: wrap; overflow-x: visible; }
}
@media (max-width: 600px) {
  .wrap { padding-inline: 20px; }
  .header { min-height: 76px; gap: 9px; flex-wrap: wrap; }
  .header .brand-mark { width: 27px; height: 34px; }
  .header .brand strong { font-size: 1.125rem; }
  .brand small { display: none; }
  .header > .btn { min-height: 44px; font-size: .875rem; padding: 10px 12px; }
  .header > .btn svg { width: 18px; height: 18px; }
  .account-avatar { width: 32px; height: 32px; flex-basis: 32px; }
  .header nav.open { inset: 100% 16px auto; }
  .hero { grid-template-columns: minmax(0, 1fr); padding: 30px 0 16px; gap: 20px; margin-top: 0; }
  .hero .eyebrow { font-size: .875rem; margin-bottom: 14px; }
  .hero h1 { font-size: clamp(2.25rem, 9.4vw, 2.75rem); line-height: 1.1; }
  .hero h1::after { margin-top: 14px; width: 76px; }
  .hero p { margin-top: 19px; font-size: 1.0625rem; }
  .hero-search-label { margin-top: 23px; }
  .hero .search-form { padding: 6px 6px 6px 14px; min-height: 60px; }
  .hero .search-form > svg { display: block; width: 20px; height: 20px; }
  .hero .search-form input { font-size: 1rem; }
  .hero .search-form .btn { min-height: 46px; padding-inline: 16px; font-size: .875rem; }
  .hero .grades { margin-top: 20px; gap: 8px; }
  .hero .chip { min-width: 46px; min-height: 46px; font-size: .9375rem; }
  .hero-art { display: block; width: 100%; max-width: 380px; margin: 0 auto; }
  .hero-art img { max-height: 235px; }
  .art-label { margin: 0; font-size: .875rem; }
  .home-page > .section { padding-top: 36px; }
  .section-head { align-items: flex-start; flex-wrap: wrap; gap: 10px; margin-bottom: 20px; }
  .section-head h2 { font-size: 1.5rem; }
  .section-head p { font-size: 1rem; }
  .subjects { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; }
  .subject { flex-direction: row; justify-content: flex-start; text-align: left; padding: 13px 12px; min-height: 76px; gap: 10px; font-size: .875rem; }
  .subject .iconbox { width: 34px; height: 34px; }
  .subject.pending { min-height: 60px; }
  .subject.pending .iconbox { display: none; }
  .home-featured .cards, .library-results .cards, .cards, .aula-desk .cards { grid-template-columns: minmax(0, 1fr); gap: 20px; }
  .home-featured .card:last-child { grid-column: auto; width: auto; }
  .card .cover,
  .card .cover:has(> .activity-cover) { height: 6rem; aspect-ratio: auto; }
  .card h3 { font-size: 1.375rem; }
  .card-body { padding: 20px 20px 16px; }
  .card-footer { padding-inline: 20px; }
  .needs { grid-template-columns: minmax(0, 1fr); gap: 10px; }
  .need { flex-direction: row; align-items: center; }
  .need.need-time { min-height: 78px; font-size: 1rem; }
  .need-secondary { min-height: 54px; padding-block: 12px; }
  .access-grid { grid-template-columns: minmax(0, 1fr); gap: 12px; }
  .access-card { min-height: 92px; }
  .home-tools-grid { grid-template-columns: minmax(0, 1fr); }
  .ribbon { padding: 22px 20px; flex-wrap: wrap; gap: 14px; }
  .ribbon .btn { margin-left: 0; }
  .footer-inner { align-items: flex-start; gap: 22px; }
  .footer-links { gap: 22px; }
  .breadcrumb { padding: 22px 0 18px; gap: 6px; font-size: .8125rem; }
  .page-title { padding-bottom: 26px; }
  .page-title h1 { font-size: 2.25rem; }
  .page-title p { font-size: 1rem; }
  .page-title .search-form input { font-size: 1rem; }
  .filters { padding: 0; background: transparent; border: 0; }
  .filter-toggle { display: inline-flex; min-height: 48px; width: 100%; }
  .filters form { display: none; padding: 20px; margin-top: 12px; background: white; border: 1px solid var(--line-soft); border-radius: var(--radius-card); }
  .filters.expanded form { display: block; }
  .filter-primary, .filter-advanced { display: block; }
  .filters .apply-filter { width: 100%; }
  .results-head { margin-bottom: 20px; gap: 10px; flex-wrap: wrap; }
  .detail-intro { padding: 4px 0 28px; }
  .detail-intro h1 { font-size: clamp(2rem, 8.5vw, 2.5rem); }
  .detail-intro > p, .detail-lead p { font-size: 1rem; }
  .detail-lead-art { max-width: 250px; }
  .detail-grid, .detail-aside { grid-template-columns: minmax(0, 1fr); }
  .detail-block { padding: 22px 18px; gap: 12px; }
  .detail-block h2 { font-size: 1.125rem; }
  .detail-actions { display: flex; flex-direction: column; align-items: stretch; }
  .detail-actions > .btn { width: 100%; min-height: 48px; white-space: normal; text-align: center; }
  .secondary-actions { gap: 8px; flex-direction: column; align-items: flex-start; }
  .secondary-actions .textlink { min-height: 44px; }
  .lesson-box { padding: 24px 20px; }
  .aula-tabs { flex-wrap: wrap; gap: 5px; }
  .aula-tabs a { font-size: .8125rem; padding: 10px 9px; }
  .aula-welcome { grid-template-columns: minmax(0, 1fr); gap: 16px; padding-bottom: 26px; }
  .aula-welcome h2 { font-size: 1.875rem; }
  .aula-welcome > img { max-height: 200px; }
  .aula-welcome .account-summary { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .aula-welcome .account-summary a { padding: 16px; font-size: .875rem; }
  .aula-folders { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 12px; }
  .aula-desk-side { display: block; }
  .aula-desk-action { margin-top: 16px; }
  .aula-desk .section-head h2 { font-size: 1.375rem; }
  .as-head { padding-top: 5px; padding-bottom: 25px; }
  .as-head h1 { font-size: 2.25rem; }
  .as-head p { font-size: 1rem; }
  .as-kicker { font-size: .75rem; }
  .as-panel { padding: 20px; }
  .class-header { flex-wrap: wrap; justify-content: space-between; gap: 12px; padding: 14px 20px; }
  .class-header > span { display: block; order: 3; width: 100%; font-size: .875rem; }
  .class-content { padding: 30px 20px 44px; }
  .class-content h1 { font-size: 2rem; }
  .class-lead { font-size: 1.125rem; }
  .answer-option { font-size: 1.125rem; padding: 18px; min-height: 64px; }
  .feedback { padding: 20px; }
  .class-buttons { flex-wrap: wrap; }
}
@media (prefers-reduced-motion: reduce) {
  .btn, .card, .subject, .need, .access-card { transition: none; }
  .btn:hover, .card:hover, .subject:hover, .need:hover, .access-card:hover { transform: none; }
}
