/* SETTINGS PAGE */
.settings-page {
    padding: 20px;
}

.settings-title {
    margin-bottom: 20px;
    font-size: 22px;
    font-weight: 600;
}

.settings-group {
    background: var(--bg-soft);
    border-radius: var(--radius);
    padding: 18px;
    margin-bottom: 20px;
    border: 1px solid var(--border);
}

.group-title {
    font-size: 16px;
    margin-bottom: 12px;
    color: var(--text-muted);
}

/* BUTTONS */
.settings-buttons {
    display: flex;
    gap: 10px;
    flex-wrap: wrap;
}

.modern-btn {
    background: var(--bg-card);
    padding: 10px 18px;
    border-radius: var(--radius);
    border: 1px solid var(--border);
    color: var(--text);
    font-size: 15px;
    cursor: pointer;
    transition: var(--transition);
    flex: 1;
    text-align: center;
    white-space: nowrap;
}

.modern-btn:hover {
    background: #1f2025;
    border-color: #3b82f6;
    color: #3b82f6;
}

/* TOGGLE ROW */
.toggle-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-top: 6px;
}

.toggle-label {
    font-size: 15px;
    color: var(--text);
}

/* SWITCH (iOS style) */
.switch {
    position: relative;
    width: 48px;
    height: 26px;
}

.switch input {
    opacity: 0;
    width: 0;
    height: 0;
}

.slider {
    position: absolute;
    cursor: pointer;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background-color: #444;
    border-radius: 30px;
    transition: 0.25s ease;
}

.slider:before {
    position: absolute;
    content: "";
    height: 20px;
    width: 20px;
    left: 3px;
    bottom: 3px;
    background-color: white;
    border-radius: 50%;
    transition: 0.25s ease;
}

/* Checked State */
.switch input:checked + .slider {
    background-color: #3b82f6;
}

.switch input:checked + .slider:before {
    transform: translateX(22px);
}





/* CATEGORIES; EXERCISES */

/* ===== Settings: Übungen & Kategorien (kompakt & modern) ===== */
.settings-card{
  padding:12px;
  border-radius:16px;
  background:rgba(255,255,255,.05);
  border:1px solid rgba(255,255,255,.08);
  box-shadow:0 10px 30px rgba(0,0,0,.20);
}

.settings-card h4{
  margin:0 0 10px;
  font-size:.95rem;
  font-weight:700;
  opacity:.9;
}

.settings-row{
  display:grid;
  grid-template-columns: 1.6fr .6fr auto;
  gap:10px;
  align-items:center;
}

.settings-row.ex{
  grid-template-columns: 1.6fr 1fr auto;
}

.modern-input{
  width:100%;
  padding:10px 12px;
  border-radius:12px;
  border:1px solid rgba(255,255,255,.10);
  background:rgba(0,0,0,.18);
  color:#fff;
  outline:none;
}

.modern-input:focus{
  border-color:rgba(255,255,255,.22);
  box-shadow:0 0 0 3px rgba(255,255,255,.06);
}

.modern-input[type="color"]{
  height:42px;
  padding:6px;
  cursor:pointer;
}

.settings-list{
  margin-top:10px;
  display:flex;
  flex-direction:column;
  gap:6px;
}

.settings-item{
  display:flex;
  align-items:center;
  justify-content:space-between;
  gap:10px;
  padding:2px 10px;
  border-radius:14px;
  background:rgba(255,255,255,.04);
  border:1px solid rgba(255,255,255,.07);
  font-weight: 100;
  font-size: 0.8rem;
}

.settings-item .left{
  display:flex;
  align-items:center;
  gap:10px;
  min-width:0;
}

.settings-item strong,
.settings-item span{
  white-space:nowrap;
  overflow:hidden;
  text-overflow:ellipsis;
}

.badge{
  font-size:.8rem;
  opacity:.75;
}

.dot{
  width:10px;
  height:10px;
  border-radius:999px;
  flex:0 0 auto;
  box-shadow:0 0 0 3px rgba(255,255,255,.06);
}

/* Button kompakter */
.danger-btn.small,
.modern-btn.small{
  padding:8px 10px;
  border-radius:12px;
  font-size:.9rem;
  line-height:1;
}

/* Mobile: Inputs untereinander */
@media (max-width:520px){
  .settings-row,
  .settings-row.ex{
    grid-template-columns: 1fr;
  }
}


/* ===== Dezenter Delete Button ===== */
.icon-btn{
  border:none;
  background:transparent;
  color:rgba(255,255,255,.45);
  padding:4px;
  border-radius:10px;
  cursor:pointer;
  line-height:1;
  max-width: 30px;
  transition:background .15s ease, color .15s ease, transform .1s ease, opacity .15s ease;
}

.icon-btn:hover{
  background:rgba(255,255,255,.08);
  color:#f87171;
}

.icon-btn:active{ transform:scale(.92); }

.settings-item .icon-btn{ opacity:.25; }
.settings-item:hover .icon-btn{ opacity:1; }



.item-actions{
  display:flex;
  align-items:center;
  gap:6px;
  flex:0 0 auto; /* verhindert Flex-Stretch */
}

.icon-btn{
  all:unset;
  width:24px;
  height:24px;
  display:grid;
  place-items:center;
  border-radius:10px;
  cursor:pointer;
  color:rgba(255,255,255,.45);
  opacity:.35;
  transition:background .15s ease, color .15s ease, transform .1s ease, opacity .15s ease;
}

.settings-item:hover .icon-btn{ opacity:1; }

.icon-btn:hover{
  background:rgba(255,255,255,.08);
  color:rgba(255,255,255,.85);
}

.icon-btn:active{ transform:scale(.92); }

.icon-btn.delete:hover{
  color:#f87171;
}

