/* ================================================================
   PROGRAM.CSS — Tab-uri săli, grilă clase, stări selecție/conflict
   ================================================================ */

/* ===== TAB-URI SĂLI ===== */
.rooms-nav {
  display: flex;
  gap: 0;
  margin-bottom: 28px;
  border: 1.5px solid rgba(61, 26, 74, .15);
  border-radius: var(--radius-md);
  overflow: hidden;
  width: fit-content;
  max-width: 100%;
}
.room-tab {
  padding: 10px 22px;
  cursor: pointer;
  font-family: var(--font-body);
  font-size: .82rem;
  font-weight: 500;
  color: var(--text-soft);
  background: var(--white);
  border: none;
  transition: all .2s;
  white-space: nowrap;
}
.room-tab.active        { background: var(--plum); color: var(--white); }
.room-tab:hover:not(.active) { background: var(--lav-pale); }

/* ===== PANOURI SĂLI ===== */
.room-panel        { display: none; }
.room-panel.active { display: block; }

.room-header {
  background: linear-gradient(135deg, var(--plum) 0%, var(--plum-light) 100%);
  border-radius: var(--radius-lg) var(--radius-lg) 0 0;
  overflow: hidden;
  position: relative;
  display: grid;
  grid-template-columns: 160px 1fr;
}
@media (max-width: 600px) {
  .room-header { grid-template-columns: 1fr; }
}
.room-header-img .img-ph {
  border-radius: 0;
  border: none;
  height: 100%;
  min-height: 120px;
}
.room-header-text { padding: 24px 28px; color: var(--cream); }
.room-title {
  font-family: var(--font-head);
  font-size: 1.5rem;
  font-weight: 400;
  margin-bottom: 6px;
}
.room-tagline {
  font-size: .82rem;
  color: rgba(251,245,238,.75);
  line-height: 1.65;
  font-weight: 300;
}

/* ===== LISTA DE CLASE ===== */
.class-list {
  background: var(--white);
  border-radius: 0 0 var(--radius-lg) var(--radius-lg);
  border: 1px solid rgba(61, 26, 74, .1);
  border-top: none;
  overflow: hidden;
}

/* Rândul unei clase */
.cls {
  display: grid;
  grid-template-columns: 88px 1fr auto;
  align-items: stretch;
  border-bottom: 1px solid rgba(61, 26, 74, .06);
  transition: background .2s, opacity .2s;
  position: relative;
  cursor: pointer;
}
.cls:last-child { border-bottom: none; }

/* Starea: disponibilă */
.cls.available:hover          { background: var(--lav-pale); }
.cls.available .cls-time      { border-right: 3px solid var(--lav-light); }

/* Starea: selectată */
.cls.selected                 { background: var(--selected-bg); }
.cls.selected .cls-time       { border-right: 3px solid var(--lavender); }

/* Starea: conflict de orar */
.cls.conflicted               { opacity: .42; cursor: not-allowed; background: var(--conflict-bg); }
.cls.conflicted .cls-time     { border-right: 3px solid #C8C2CC; }

/* Clasă specială (ex: rugăciune finală) — fără selecție */
.cls.special                  { cursor: default; opacity: .8; }

/* Coloana timp */
.cls-time {
  padding: 16px 12px 16px 16px;
  border-right: 3px solid transparent;
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  justify-content: center;
  gap: 2px;
}
.cls-time .start { font-weight: 600; font-size: .9rem; color: var(--plum); }
.cls-time .end   { font-size: .74rem; color: var(--text-muted); font-weight: 300; }

/* Coloana body */
.cls-body {
  padding: 14px;
  display: flex;
  flex-direction: column;
  justify-content: center;
  gap: 4px;
}
.cls-type {
  font-size: .68rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: .06em;
}
.cls-name {
  font-family: var(--font-head);
  font-size: 1.05rem;
  color: var(--text-main);
  line-height: 1.3;
  font-weight: 400;
}
.cls-instructor {
  font-size: .78rem;
  color: var(--text-soft);
  display: flex;
  align-items: center;
  gap: 6px;
  font-weight: 300;
}
.instructor-avatar {
  width: 20px;
  height: 20px;
  border-radius: 50%;
  border: 1.5px dashed var(--lav-light);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-size: .45rem;
  color: var(--text-muted);
  flex-shrink: 0;
}
.cls-conflict-reason {
  font-size: .72rem;
  color: #8B6B6B;
  margin-top: 2px;
  display: none;
  font-weight: 300;
}
.cls.conflicted .cls-conflict-reason { display: block; }

/* Coloana acțiuni */
.cls-actions {
  padding: 14px;
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 8px;
}
.btn-info {
  width: 26px;
  height: 26px;
  border-radius: 50%;
  background: transparent;
  border: 1.5px solid var(--lav-light);
  color: var(--lavender);
  font-size: .78rem;
  font-weight: 600;
  cursor: pointer;
  transition: all .2s;
  flex-shrink: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  font-family: var(--font-body);
}
.btn-info:hover { background: var(--lavender); color: var(--white); border-color: var(--lavender); }

.cls-select-indicator {
  width: 20px;
  height: 20px;
  border-radius: 50%;
  background: transparent;
  border: 1.5px solid var(--lav-light);
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  transition: all .2s;
  font-size: .72rem;
  color: transparent;
}
.cls.selected .cls-select-indicator {
  background: var(--lavender);
  border-color: var(--lavender);
  color: var(--white);
}
.cls.available:hover .cls-select-indicator { border-color: var(--lavender); }

/* Label hover/selectat */
.cls.available::after {
  content: '+ Adaugă';
  position: absolute;
  right: 52px;
  top: 50%;
  transform: translateY(-50%);
  font-size: .7rem;
  font-weight: 500;
  color: var(--lavender);
  opacity: 0;
  transition: opacity .2s;
  pointer-events: none;
}
.cls.available:hover::after { opacity: 1; }
.cls.selected::after {
  content: '✓ Selectat';
  position: absolute;
  right: 52px;
  top: 50%;
  transform: translateY(-50%);
  font-size: .7rem;
  font-weight: 500;
  color: var(--lavender);
  opacity: 1;
  pointer-events: none;
}
@media (max-width: 600px) {
  .cls.available::after,
  .cls.selected::after { display: none; }
}
