.theory-index-head{
  display:flex;
  align-items:center;
  justify-content:space-between;
  gap:14px;
  margin:40px 0 24px;
}

.theory-index-head .section-title{
  margin:0;
}

.theory-actions{
  display:flex;
  flex:0 0 auto;
  align-items:center;
  justify-content:flex-end;
  gap:8px;
  margin-left:auto;
}

.theory-lesson-header{
  border-bottom:1px solid #dfe6ef;
}

.theory-title-band{
  padding:15px 18px;
  background:#edf5ff;
}

.theory-lesson-kicker{
  margin:0 0 4px;
  color:#315f94;
  font-size:13px;
  font-weight:850;
  line-height:1.25;
  text-transform:uppercase;
}

.theory-lesson-title{
  margin:0;
  color:#141414;
  font-family:system-ui,-apple-system,"Segoe UI",Roboto,Arial,sans-serif;
  font-size:24px;
  font-weight:850;
  line-height:1.2;
  letter-spacing:0;
}

.theory-lesson-subtitle{
  max-width:860px;
  margin:6px 0 0;
  color:#5d6470;
  font-size:14px;
  line-height:1.45;
}

.theory-commandbar{
  display:flex;
  align-items:center;
  justify-content:space-between;
  gap:16px;
  min-height:58px;
  padding:10px 18px;
  background:#fff;
}

.theory-commandbar .theory-back-btn{
  min-height:36px;
  padding:7px 0;
  border:0;
  border-radius:0;
  background:transparent;
  color:#315f94;
  font-size:14px;
}

.theory-commandbar .theory-back-btn:hover{
  background:transparent;
  color:#284f7d;
  text-decoration:underline;
}

.theory-commandbar .print-btn,
.theory-commandbar .reset-btn,
.theory-commandbar .complete-lesson-btn{
  box-sizing:border-box;
  display:inline-flex;
  min-height:38px;
  align-items:center;
  justify-content:center;
  gap:7px;
  padding:8px 12px;
  border-radius:10px;
  font:inherit;
  font-size:14px;
  font-weight:750;
  line-height:1.2;
  cursor:pointer;
}

.theory-commandbar .complete-lesson-btn{
  border:1px solid #315f94;
  background:#315f94;
  color:#fff;
}

.theory-commandbar .complete-lesson-btn:hover{
  border-color:#284f7d;
  background:#284f7d;
}

.theory-commandbar .complete-lesson-btn.is-complete,
.theory-commandbar .complete-lesson-btn:disabled{
  border-color:#b9ddc8;
  background:#edf8f1;
  color:#287252;
  cursor:default;
}

.theory-commandbar .reset-btn:disabled{
  opacity:.6;
  cursor:wait;
}

.theory-commandbar .print-btn{
  border:1px solid #d9e2ee;
  background:#fff;
  color:#141414;
}

.theory-commandbar .print-btn:hover{
  border-color:#b9c9dc;
  background:#f7f9fc;
}

.theory-commandbar .reset-btn{
  border:1px solid transparent;
  background:transparent;
  color:#315f94;
}

.theory-commandbar .reset-btn:hover{
  background:#edf5ff;
}

.theory-action-icon{
  font-size:17px;
  font-style:normal;
  font-weight:700;
  line-height:1;
}

.theory-back-btn{
  display:inline-flex;
  min-height:38px;
  align-items:center;
  justify-content:center;
  border:1px solid #3f6ea5;
  border-radius:10px;
  background:#fff;
  color:#315f94;
  padding:9px 13px;
  font:inherit;
  font-weight:800;
  line-height:1.2;
  text-decoration:none;
}

.theory-back-btn:hover{
  background:#edf5ff;
  color:#284f7d;
}

@media (max-width:900px){
  .theory-index-head{
    align-items:flex-start;
  }

  .theory-actions{
    width:100%;
    justify-content:flex-end;
  }

  .theory-actions .print-btn,
  .theory-actions .complete-lesson-btn{
    width:auto;
  }

  .theory-commandbar .theory-actions{
    width:auto;
  }
}

@media (max-width:640px){
  .theory-title-band{
    padding:14px;
  }

  .theory-lesson-title{
    font-size:22px;
    overflow-wrap:anywhere;
  }

  .theory-commandbar{
    display:grid;
    grid-template-columns:minmax(0,1fr);
    align-items:stretch;
    gap:10px;
    padding:10px 14px;
  }

  .theory-commandbar .theory-back-btn{
    box-sizing:border-box;
    width:100%;
    min-height:44px;
    justify-self:stretch;
    padding:9px 12px;
    border:1px solid #d9e2ee;
    border-radius:10px;
    background:#fff;
    text-align:center;
  }

  .theory-commandbar .theory-actions{
    display:grid;
    width:100%;
    min-width:0;
    grid-template-columns:repeat(2,minmax(0,1fr));
    gap:8px;
    margin-left:0;
  }

  .theory-commandbar .theory-actions > :is(a,button){
    box-sizing:border-box;
    width:100%!important;
    min-width:0!important;
    min-height:44px;
    margin:0!important;
    justify-content:center;
    padding:9px 8px;
    font-size:13px;
    white-space:normal;
    overflow-wrap:anywhere;
    text-align:center;
  }

  .theory-commandbar .theory-actions > :only-child,
  .theory-commandbar .theory-actions > :first-child:nth-last-child(3){grid-column:1 / -1}
}

@media print{
  .theory-actions,
  .theory-index-head .theory-back-btn,
  .theory-commandbar{
    display:none!important;
  }

  .theory-title-band{
    padding:0 0 12px;
    background:#fff!important;
  }
}
