/* Appspecifik stil for Hasses Textare. */

.textare-lead{
  max-width: 880px;
}

.app-scope{
  --border: #2b3341;
  --panel: #171a21;
  --panel-soft: #202633;
  --surface: #0b0d12;
  --text: #eef4fb;
  --text-muted: #aeb8c5;
  --accent: #00d4ff;
  --accent-ink: #062831;
  --success: #75f94c;
  --warning: #ffbd59;
  --danger: #ff7676;
  display: grid;
  gap: 16px;
}

.app-scope h2{
  margin: 0;
  color: #fff;
  line-height: 1.2;
}

.textare-help{
  background: #fff8eb;
  border: 1px solid rgba(0,0,0,.12);
  border-radius: 8px;
  padding: 14px 16px;
}

.textare-help h2{
  color: #151515;
  margin-bottom: 8px;
}

.help-steps{
  margin: 0;
  padding-left: 22px;
  line-height: 1.55;
}

.textare-status{
  border: 1px solid #b7c6d9;
  background: #eef6ff;
  color: #10253d;
  border-radius: 8px;
  padding: 12px 14px;
  font-weight: 700;
}

.textare-status[data-status="success"]{
  border-color: #63b96d;
  background: #eaf9eb;
  color: #123d18;
}

.textare-status[data-status="warning"]{
  border-color: #d39b31;
  background: #fff5df;
  color: #553600;
}

.textare-status[data-status="error"]{
  border-color: #d66;
  background: #fff0f0;
  color: #641c1c;
}

.app-scope .card{
  border-radius: 8px;
}

@media (min-width: 980px){
  .app-scope .grid-top{
    align-items: stretch;
  }

  .app-scope .grid-top > .card{
    height: 100%;
  }

  .app-scope section[aria-labelledby="syncTitle"] .lyrics{
    flex: 1 1 220px;
    min-height: 220px;
    max-height: none;
  }
}

.app-scope .media-container{
  display: grid;
  gap: 10px;
}

.app-scope audio#audioPlayer,
.app-scope video#videoPlayer{
  width: 100%;
  max-width: 100%;
  border-radius: 8px;
  background: var(--surface);
  border: 1px solid var(--border);
}

.app-scope video#videoPlayer{
  max-height: 52vh;
}

.media-empty-state,
.lyrics-empty{
  padding: 22px;
  text-align: center;
  color: var(--text-muted);
  border: 2px dashed var(--border);
  border-radius: 8px;
  background: var(--surface);
}

.sync-status-row{
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  justify-content: space-between;
}

.sync-toolbar,
.nudge-toolbar,
.action-row,
.export-downloads{
  align-items: stretch;
}

.sync-toolbar .btn{
  flex: 1 1 160px;
}

.stamp-button{
  flex-grow: 2;
  min-height: 46px;
}

.nudge-toolbar .btn{
  flex: 1 1 120px;
}

.export-actions{
  border-top: 1px solid var(--border);
  padding-top: 14px;
  display: flex;
  flex-direction: column;
  gap: 8px;
  align-items: flex-start;
}

.export-main-button{
  width: auto;
  flex: 0 1 auto;
}

.export-summary{
  width: 100%;
  border: 1px solid var(--border);
  border-radius: 8px;
  padding: 10px 12px;
  background: var(--surface);
  color: var(--text);
}

.export-downloads{
  justify-content: flex-start;
}

.export-downloads .btn{
  flex: 0 1 auto;
}

.app-scope .btn:disabled{
  cursor: not-allowed;
  opacity: .48;
  filter: grayscale(.2);
}

.app-scope .btn:focus-visible,
.app-scope .line:focus-visible{
  outline: 3px solid var(--accent);
  outline-offset: 2px;
}

.app-scope .line{
  width: 100%;
  display: flex;
  gap: 8px;
  align-items: flex-start;
  border: 0;
  color: var(--text);
  background: transparent;
  text-align: left;
  font: inherit;
  cursor: pointer;
}

.app-scope .line:hover{
  background: #111923;
}

.app-scope .line.done .line-time{
  color: var(--success);
}

.app-scope .line-time{
  flex: 0 0 auto;
  color: var(--text-muted);
}

.app-scope .line-text{
  min-width: 0;
  overflow-wrap: anywhere;
}

@media (max-width: 640px){
  .textare-help,
  .textare-status{
    padding: 12px;
  }

  .app-scope .row,
  .app-scope .flex{
    flex-direction: column;
  }

  .app-scope .btn{
    width: 100%;
  }

  .sync-status-row{
    justify-content: flex-start;
  }
}
