.study-aula-hero .campus-hero-copy{padding:clamp(1rem,3vw,2rem)}
.study-aula-hero .campus-hero-art{min-height:180px;max-height:260px}
.study-aula-hero h1{font-size:clamp(1.7rem,3.2vw,3rem)}
.study-room-nav{display:flex;gap:.45rem;margin:1rem 0}
.study-topics,.study-search-results{margin:1rem 0 1.7rem}
.study-topics h2,.study-search-results h2{font:500 clamp(1.6rem,3vw,2.4rem)/1.1 Georgia,serif;margin:.7rem 0 1rem}
.study-grid{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:1rem}
.study-card{border:1px solid #d9dcd1;border-radius:12px;background:#fff;overflow:hidden;min-width:0;scroll-margin:90px}
.study-card-body{padding:1rem}
.study-card h3,.study-card h4{margin:.1rem 0 .55rem;color:#18342b;line-height:1.2;font-size:1.2rem;overflow-wrap:anywhere}
.study-card p{margin:.4rem 0 .65rem;color:#4b5a52;line-height:1.44}
.study-image-link,.study-picture{display:block}
.study-picture,.study-type-cover{aspect-ratio:1.8;background:#e3dfd1;overflow:hidden}
.study-picture img{width:100%;height:100%;object-fit:cover;display:block}
.study-picture img[hidden]{display:none}
.study-picture-contain img{object-fit:contain}
.study-picture-error::after{content:'Imagen no disponible';display:grid;place-items:center;height:100%;color:#3d483e}
.study-type-cover{display:flex;align-items:end;padding:.8rem;color:#234c3d;background:#e6ece0;font:1.4rem Georgia,serif}
.study-actions{display:flex;flex-wrap:wrap;align-items:center;gap:.45rem}
.study-actions a:not(.campus-action){padding:.35rem 0;color:#075240;font-weight:600;min-height:36px;display:inline-flex;align-items:center}
.study-actions [aria-pressed=true]{background:#075240;color:white}
.study-mark{display:flex;align-items:center;gap:.35rem;min-height:40px}
.study-practice{margin-top:.55rem}
.study-practice summary{cursor:pointer;padding:.45rem 0}
.study-gallery>section{margin:1rem 0 1.35rem}
.study-resume{display:flex;align-items:center;justify-content:space-between;gap:.8rem;flex-wrap:wrap;background:#e7efe5;border:1px solid #ccd9cb;border-radius:10px;margin:1rem 0;padding:.8rem 1rem}
.study-resume h2,.study-resume p{margin:.2rem 0}
.study-result-link{display:block;padding:.7rem .85rem;border:1px solid #d9dcd1;border-radius:8px;background:white;color:#075240}
.study-result-link small{display:block;margin-top:.25rem;color:#4b5a52}
.student .student-nav .study-fans-nav{color:#73263e;font-weight:700}
.study-listen{margin:0 0 .75rem}
.study-episode-picture{display:block;overflow:hidden;border-radius:6px}
.study-episode-picture .study-picture{aspect-ratio:1}
.study-import{display:block;margin:.55rem 0}
.study-import input{max-width:100%}
#study-viewer{padding:1rem;width:min(calc(100% - 1.25rem),850px);max-height:90dvh;max-width:none;border:1px solid #d9dcd1;border-radius:12px;box-sizing:border-box;color:#18342b}
#study-viewer::backdrop{background:#17261ec9}
#study-viewer header{display:flex;align-items:start;justify-content:space-between;gap:.5rem}
#study-viewer h2{font:500 clamp(1.25rem,3vw,2rem) Georgia,serif;margin:.4rem 0}
.study-zoom{display:flex;align-items:center;gap:.5rem;min-height:44px}
.study-viewer-scroll{overflow:auto;max-height:50vh;background:#eee8dc}
.study-viewer-scroll img{display:block;width:100%;height:auto;max-width:none}
.study-viewer-scroll img[hidden]{display:none}
@media(max-width:1050px){.study-grid{grid-template-columns:repeat(2,minmax(0,1fr))}}
@media(max-width:610px){.study-grid{grid-template-columns:1fr}.student .study-aula-hero .campus-hero-art{min-height:0;aspect-ratio:3.4}.study-room-nav a{flex:1;justify-content:center}.study-card-body{padding:.85rem}}
.student .student-tabs.study-room-nav{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));align-items:stretch;max-width:32rem}
.student .study-room-nav>a{justify-content:center;text-align:center}
@media(max-width:610px){
  .student .study-aula-hero .campus-hero-art{aspect-ratio:4.5}
  .student .study-aula-hero .campus-hero-copy{padding:.85rem}
}

.study-room-nav .campus-action { min-width:0; white-space:normal; text-align:center; line-height:1.2; }
.study-block-grid { align-items:start; }
.study-theme-details, .study-exercise, .study-series { margin-block:1rem; }
.study-theme-details summary, .study-exercise summary, .study-series summary { cursor:pointer; font-weight:650; padding:.55rem 0; }
.study-theme-list { list-style:none; padding:0; margin:0; }
.study-theme-list > li { border-top:1px solid #d9e2db; padding:.8rem 0; overflow-wrap:anywhere; }
.study-theme-list h4 { margin:.25rem 0 .55rem; font-size:1rem; }
.study-theme-number, .study-context { font-size:.84rem; color:#304c40; }
.study-theme-episode { margin-block:.5rem; }
.study-theme-episode .campus-action { max-width:100%; white-space:normal; }
.study-series table { width:100%; border-collapse:collapse; font-variant-numeric:tabular-nums; font-size:.9rem; }
.study-series :is(td,th) { padding:.4rem; border-bottom:1px solid #d9e2db; text-align:left; }
.study-series caption { margin:.5rem; text-align:left; }
.study-exercise { border-top:1px solid #d9e2db; padding-top:.6rem; }
.study-picture-error::after { content:'Imagen no disponible'; display:grid; place-content:center; height:100%; color:#304c40; }
.study-theme-list [id], #practica { scroll-margin-top:6rem; }
.study-viewer-scroll { max-height:50vh; }
#study-viewer [hidden] { display:none; }

.student :is(.study-room-nav, .study-listen, [aria-label="Tipos de recursos"]) .campus-action { min-height:44px; }
.student [aria-label="Tipos de recursos"] [aria-current="page"] { background:#075240; color:#fff; }
.study-pagination { margin-block:1rem; }
#campus-resources { scroll-margin-top:80px; }
@media (max-width:768px) {
  .student .study-aula-hero .campus-hero-copy { padding:.65rem .8rem; }
  .student .study-aula-hero h1 { font-size:clamp(1.3rem,5.4vw,2.05rem); line-height:1.12; margin:.2rem 0 .32rem; overflow-wrap:normal; hyphens:auto; }
  .student .study-aula-hero .campus-hero-copy p { font-size:.91rem; line-height:1.35; margin:.25rem 0; }
  .student .study-aula-hero .campus-hero-copy .campus-kicker { font-size:.72rem; }
  .student .study-aula-hero .campus-hero-actions { margin:.25rem 0 0; }
  .student .study-aula-hero .campus-hero-actions .campus-action { min-height:44px; padding:.3rem .6rem; }
  .student .study-aula-hero .campus-hero-art { min-height:0; aspect-ratio:3.4; max-height:120px; }
  .student .study-room-nav { margin:.65rem 0; }
  .student .study-room-nav > .campus-action {
    font-size:clamp(.76rem,3.4vw,1rem); padding:.45rem .25rem; overflow-wrap:normal; word-break:normal;
  }
  .student .study-room-nav > :is(:first-child,:last-child) { white-space:nowrap; }
}

.campus-episode-description p { white-space: pre-line; overflow-wrap: anywhere; }

.student .student-tabs.study-room-nav {grid-template-columns:minmax(0,1fr) minmax(0,1.3fr) minmax(0,1fr)}
.student .study-room-nav a {text-align:center;overflow-wrap:normal;word-break:normal;min-height:44px}
.study-fan-episodes {border-top:1px solid #d9e2db;margin-top:.9rem;padding-top:.8rem}
.study-fan-episodes ul {list-style:none;padding:0;margin:0}
.study-fan-episodes li + li {margin-top:.75rem}
.study-fan-title {font-weight:650;text-underline-offset:.14em}
.study-fan-meta {display:flex;align-items:center;flex-wrap:wrap;gap:.4rem;margin:.25rem 0 0;font-size:.85rem}

/* Defer large episode groups; individual cards stay at their natural height. */
.student-panel > details[open]:has(> .student-resource:nth-of-type(10)) {
  content-visibility:auto;
  contain-intrinsic-size:auto 900px;
}
.student :is(#campus-directory,#campus-resources,#campus-directory-fallback) {scroll-margin-top:4rem}
@media(max-width:760px) {
  .student :is(#campus-directory,#campus-resources,#campus-directory-fallback) {scroll-margin-top:7rem}
}

.campus-search-caption {font-weight:650;flex-basis:100%;color:var(--campus-ink)}
.student-search:has(.campus-search-caption) {flex-wrap:wrap}
.student-search:has(.campus-search-caption) input {flex:1;width:auto}
.study-search-scope {display:grid;grid-template-columns:repeat(auto-fit,minmax(min(100%,14rem),1fr));gap:.65rem}
.study-search-scope label {display:grid;gap:.3rem;font-weight:650;min-width:0}
.study-search-scope select {max-width:100%;min-height:44px;padding:.4rem .6rem;border:1px solid var(--campus-border);border-radius:.5rem;background:white;color:var(--campus-ink)}
.study-search-scope select:focus-visible {outline:2px solid #a25912;outline-offset:2px}
.campus-load-notice {position:fixed;inset:auto 1rem 1rem auto;z-index:30;max-width:calc(100% - 2rem);background:white;border:1px solid var(--campus-border);padding:.75rem}
.study-search-scope select {width:100%;min-width:0}
