:root{
  --report-red-light:#c60300;
  --report-red-dark:#ff0400;
  --report-red:var(--report-red-light);
  --report-hover:#d81b18;
  --report-hover-dark:#ff3b30;
  --report-selected:var(--report-red);
  --report-card-bg-light:#ffffff;
  --report-card-bg-dark:#0f172a;
  --report-card-border-light:rgba(198,3,0,.15);
  --report-card-border-dark:rgba(255,4,0,.28);
  --report-shadow-light:0 14px 36px rgba(0,0,0,.14);
  --report-shadow-dark:0 14px 36px rgba(0,0,0,.34);
  --report-radius:16px;
  --report-pad:clamp(10px,1.5vw,16px);
  --report-z-btn:1200;
  --report-z-modal:1300;
}

.dark-mode{
  --report-red:var(--report-red-dark);
}

#schoolepReportIssueMount,
#schoolepReportIssueMount *{
  box-sizing:border-box;
}

.report-issue-btn{
  position:fixed;
  inset-inline-start:max(8px, env(safe-area-inset-left));
  bottom:max(8px, env(safe-area-inset-bottom));
  z-index:var(--report-z-btn);
  display:inline-flex;
  align-items:center;
  justify-content:center;
  gap:0;
  width:36px;
  min-width:36px;
  height:36px;
  padding:0;
  border:none;
  border-radius:999px;
  cursor:pointer;
  overflow:hidden;
  white-space:nowrap;
  background:var(--report-red);
  color:#fff;
  font-size:12px;
  font-weight:700;
  box-shadow:0 8px 18px rgba(0,0,0,.16);
  transition:
    width .18s ease,
    padding .18s ease,
    gap .18s ease,
    border-radius .18s ease,
    background-color .18s ease,
    box-shadow .18s ease,
    transform .18s ease;
}

.report-issue-btn:hover,
.report-issue-btn:focus-visible{
  width:auto;
  min-width:36px;
  padding-inline:10px;
  gap:6px;
  justify-content:flex-start;
  background:var(--report-hover);
  box-shadow:0 10px 22px rgba(0,0,0,.20);
  transform:translateY(-1px);
}

.dark-mode .report-issue-btn:hover,
.dark-mode .report-issue-btn:focus-visible{
  background:var(--report-hover-dark);
}

.report-issue-btn.is-open{
  width:36px;
  min-width:36px;
  height:36px;
  padding:0;
  gap:0;
  justify-content:center;
  border-radius:999px;
  transform:none;
  background:var(--report-red);
}

.report-issue-btn-icon{
  width:16px;
  height:16px;
  display:inline-flex;
  align-items:center;
  justify-content:center;
  flex:0 0 auto;
  font-size:18px;
  line-height:1;
}

.report-issue-btn-label{
  opacity:0;
  max-width:0;
  overflow:hidden;
  transition:opacity .16s ease, max-width .16s ease;
}

.report-issue-btn:hover .report-issue-btn-label,
.report-issue-btn:focus-visible .report-issue-btn-label{
  opacity:1;
  max-width:160px;
}

.report-issue-btn.is-open .report-issue-btn-label{
  opacity:0;
  max-width:0;
}

.report-issue-modal{
  position:fixed;
  inset:0;
  z-index:var(--report-z-modal);
  display:none;
  align-items:center;
  justify-content:center;
  padding:clamp(10px,2vw,20px);
  background:rgba(0,0,0,.45);
  backdrop-filter:blur(2px);
}

.report-issue-modal.open{
  display:flex;
}

.report-issue-card{
  width:min(560px,100%);
  max-width:560px;
  max-height:min(86vh,760px);
  overflow-x:hidden;
  overflow-y:auto;
  border-radius:var(--report-radius);
  background:var(--report-card-bg-light);
  color:#111;
  padding:var(--report-pad);
  border:1px solid var(--report-card-border-light);
  box-shadow:var(--report-shadow-light);
  scrollbar-gutter:stable;
  scrollbar-width:thin;
  scrollbar-color:rgba(59,130,246,.75) transparent;
}

.dark-mode .report-issue-card{
  background:var(--report-card-bg-dark);
  color:#e5e7eb;
  border-color:var(--report-card-border-dark);
  box-shadow:var(--report-shadow-dark);
  scrollbar-color:rgba(96,165,250,.95) transparent;
}

.report-issue-card::-webkit-scrollbar{
  width:7px;
}

.report-issue-card::-webkit-scrollbar-track{
  background:transparent;
  border-radius:999px;
}

.report-issue-card::-webkit-scrollbar-thumb{
  background:linear-gradient(180deg, rgba(59,130,246,.95), rgba(37,99,235,.92));
  border-radius:999px;
}

.report-issue-card::-webkit-scrollbar-thumb:hover{
  background:linear-gradient(180deg, rgba(96,165,250,.98), rgba(59,130,246,.98));
}

.dark-mode .report-issue-card::-webkit-scrollbar-thumb{
  background:linear-gradient(180deg, rgba(96,165,250,.98), rgba(59,130,246,.96));
}

.dark-mode .report-issue-card::-webkit-scrollbar-thumb:hover{
  background:linear-gradient(180deg, rgba(147,197,253,.98), rgba(96,165,250,.98));
}

.report-issue-head{
  position:relative;
  min-height:40px;
  margin-bottom:8px;
}

.report-issue-head > div:first-child{
  width:100%;
  text-align:center;
  padding:0 42px;
}

.report-issue-title{
  margin:0;
  font-size:clamp(16px,2vw,18px);
  line-height:1.3;
  font-weight:800;
  text-align:center;
}

.report-issue-close{
  position:absolute;
  top:-4px;
  inset-inline-end:0;
  border:none;
  background:transparent;
  color:inherit;
  width:34px;
  height:34px;
  border-radius:10px;
  cursor:pointer;
  font-size:24px;
  line-height:1;
  display:inline-flex;
  align-items:center;
  justify-content:center;
  transition:background-color .16s ease, color .16s ease;
}

.report-issue-close:hover,
.report-issue-close:focus-visible{
  background:rgba(216,27,24,.10);
  color:var(--report-hover);
}

.dark-mode .report-issue-close:hover,
.dark-mode .report-issue-close:focus-visible{
  background:rgba(255,59,48,.16);
  color:var(--report-hover-dark);
}

.report-issue-desc{
  margin:4px 0 10px;
  opacity:.92;
  line-height:1.5;
  font-size:13px;
  text-align:center;
}

.report-issue-type-grid{
  display:grid;
  grid-template-columns:repeat(2, minmax(0,1fr));
  gap:7px;
  margin-bottom:10px;
}

.report-issue-type{
  border:1px solid rgba(0,0,0,.10);
  border-radius:10px;
  background:rgba(0,0,0,.03);
  color:inherit;
  padding:9px 10px;
  text-align:center;
  cursor:pointer;
  font:inherit;
  font-size:12px;
  font-weight:700;
  min-height:38px;
  transition:
    background-color .16s ease,
    border-color .16s ease,
    transform .16s ease,
    box-shadow .16s ease,
    color .16s ease;
}

.report-issue-type:hover,
.report-issue-type:focus-visible{
  transform:translateY(-1px);
  background:rgba(216,27,24,.10);
  border-color:rgba(216,27,24,.35);
  color:var(--report-hover);
  box-shadow:0 6px 14px rgba(216,27,24,.12);
}

.report-issue-type.is-selected,
.report-issue-type.is-selected:hover,
.report-issue-type.is-selected:focus-visible{
  background:var(--report-selected);
  border-color:var(--report-selected);
  color:#fff;
  box-shadow:0 8px 18px rgba(198,3,0,.22);
}

.dark-mode .report-issue-type{
  border-color:rgba(255,255,255,.14);
  background:rgba(255,255,255,.07);
  color:#f3f4f6;
}

.dark-mode .report-issue-type:hover,
.dark-mode .report-issue-type:focus-visible{
  background:rgba(255,59,48,.16);
  border-color:rgba(255,59,48,.34);
  color:var(--report-hover-dark);
  box-shadow:0 8px 18px rgba(0,0,0,.22);
}

.dark-mode .report-issue-type.is-selected,
.dark-mode .report-issue-type.is-selected:hover,
.dark-mode .report-issue-type.is-selected:focus-visible{
  background:var(--report-red);
  border-color:var(--report-red);
  color:#fff;
  box-shadow:0 8px 18px rgba(255,4,0,.28);
}

.report-issue-text-wrap{
  display:none;
}

.report-issue-text-wrap.is-visible{
  display:block;
}

.report-issue-text{
  width:100%;
  min-height:100px;
  resize:vertical;
  border-radius:10px;
  border:1px solid rgba(0,0,0,.15);
  padding:10px;
  font:inherit;
  font-size:13px;
  line-height:1.5;
  background:rgba(0,0,0,.03);
  color:inherit;
}

.report-issue-text:focus{
  outline:none;
  border-color:var(--report-red);
  box-shadow:0 0 0 3px rgba(198,3,0,.10);
}

.dark-mode .report-issue-text{
  border-color:rgba(255,255,255,.15);
  background:rgba(255,255,255,.06);
}

.report-issue-actions {
  display: flex;
  flex-direction: column; /* Forces the message to sit directly under the button */
  align-items: center;
  justify-content: center;
  margin-top: 15px;
  gap: 10px; /* Adds space between the button and the message */
}

.report-issue-hint {
  margin-top: 0;
  text-align: center;
  font-size: 13px;
  line-height: 1.5;
  white-space: pre-line; /* Allows us to use line breaks in JavaScript */
}

.report-issue-hint:empty{
  display:none;
}

.report-issue-send{
  flex:0 0 auto;
  min-width:140px;
  height:44px;
  border:none;
  border-radius:12px;
  padding:0 18px;
  display:inline-flex;
  align-items:center;
  justify-content:center;
  font:inherit;
  font-size:14px;
  font-weight:800;
  cursor:pointer;
  transition:
    background-color .16s ease,
    color .16s ease,
    transform .16s ease,
    box-shadow .16s ease,
    opacity .16s ease;
  background:var(--report-red);
  color:#fff;
}

.report-issue-send:hover,
.report-issue-send:focus-visible{
  background:var(--report-hover);
  transform:translateY(-1px);
  box-shadow:0 8px 18px rgba(216,27,24,.18);
}

.report-issue-send:disabled{
  opacity:.7;
  cursor:not-allowed;
  transform:none;
  box-shadow:none;
}

.dark-mode .report-issue-send:hover,
.dark-mode .report-issue-send:focus-visible{
  background:var(--report-hover-dark);
}

.report-status.ok{
  color:#15803d;
}

.report-status.error{
  color:#dc2626;
}

.dark-mode .report-status.ok{
  color:#4ade80;
}

.dark-mode .report-status.error{
  color:#f87171;
}

@media (max-width:900px){
  .report-issue-btn{
    width:34px;
    min-width:34px;
    height:34px;
    bottom:8px;
    inset-inline-start:8px;
  }

  .report-issue-btn.is-open{
    width:34px;
    min-width:34px;
    height:34px;
  }

  .report-issue-card{
    width:min(480px, calc(100vw - 24px));
    max-width:480px;
    max-height:min(82vh,660px);
    border-radius:14px;
    margin:0 auto;
  }
}

@media (max-width:640px){
  .report-issue-card{
    width:min(100%, 460px);
    max-width:calc(100vw - 20px);
    max-height:min(88vh, 720px);
    border-radius:14px;
    padding:10px;
  }

  .report-issue-type-grid{
    gap:6px;
  }

  .report-issue-type{
    min-height:40px;
    padding:8px 8px;
    font-size:12px;
  }

  .report-issue-send{
    min-width:140px;
    height:42px;
  }
}

@media (max-width:420px){
  .report-issue-btn{
    width:32px;
    min-width:32px;
    height:32px;
  }

  .report-issue-btn.is-open{
    width:32px;
    min-width:32px;
    height:32px;
  }

  .report-issue-card{
    width:100%;
    max-width:calc(100vw - 16px);
    max-height:min(90vh, 760px);
    padding:9px;
    border-radius:12px;
  }

  .report-issue-title{
    font-size:15px;
  }

  .report-issue-close{
    top:-2px;
    width:30px;
    height:30px;
    font-size:22px;
  }
}