/* ================================================================
   PROP PHONE STUDIO 11.2.1 — tablet-custom-screens.css
   Styles pour iPad / tablette Android (vue split) et pour
   l'ecran "custom" (signage neutre).
   ================================================================ */

/* ---------- Hosts : caches par defaut, affiches via .show ---------- */
#tablet-environment,
#custom-environment {
  position: absolute;
  inset: 0;
  z-index: 130;
  display: none;
  overflow: hidden;
}
#tablet-environment.show,
#custom-environment.show { display: block; }

/* Cacher l'ecran telephone standard quand un environnement dedie est actif
   (classe posee par tablet-custom-screens.js, plus fiable qu'un selecteur CSS) */
body.tcs-hide-phone-screen #phone-screen > .screen.active {
  visibility: hidden;
}

/* ================= TABLETTE : vue split messages ================= */
.tab-split {
  display: flex;
  height: 100%;
  background: #f4f4f6;
  color: #17191e;
  font-family: -apple-system, "Segoe UI", system-ui, sans-serif;
}
body.kind-android-tablet .tab-split { background: #eef0f3; }

.tab-conv-list {
  width: 34%;
  min-width: 220px;
  border-right: 1px solid #dcdfe4;
  background: #fff;
  overflow-y: auto;
}
.tab-conv-header {
  padding: 16px 14px 10px;
  font-weight: 700;
  font-size: 20px;
}
.tab-conv-item {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 10px 14px;
  cursor: default;
  border-left: 3px solid transparent;
}
.tab-conv-item.active { background: #e8f0fe; border-left-color: #2588ef; }
body.kind-android-tablet .tab-conv-item.active { background: #e3f2ea; border-left-color: #2e9e5b; }
.tab-conv-avatar {
  width: 40px; height: 40px; border-radius: 50%;
  background: #8a8fa3; color: #fff;
  display: flex; align-items: center; justify-content: center;
  font-weight: 700; flex-shrink: 0;
}
.tab-conv-info { display: flex; flex-direction: column; overflow: hidden; }
.tab-conv-info b { font-size: 13px; }
.tab-conv-info span { font-size: 11px; color: #888; }

.tab-conv-thread {
  flex: 1;
  display: flex;
  flex-direction: column;
  min-width: 0;
}
.tab-conv-thread-header {
  padding: 14px 20px;
  border-bottom: 1px solid #dcdfe4;
  background: #fff;
  font-size: 15px;
}
.tab-conv-bubbles {
  flex: 1;
  padding: 16px 20px;
  overflow-y: auto;
  display: flex;
  flex-direction: column;
  gap: 8px;
}
.tab-bubble {
  max-width: 60%;
  padding: 10px 14px;
  border-radius: 16px;
  background: #e5e6ea;
  font-size: 13px;
  align-self: flex-start;
}
.tab-bubble.out {
  align-self: flex-end;
  background: #2588ef;
  color: #fff;
}
body.kind-android-tablet .tab-bubble.out { background: #2e9e5b; }
.tab-conv-input {
  margin: 12px 20px 16px;
  padding: 10px 16px;
  border-radius: 20px;
  background: #fff;
  border: 1px solid #dcdfe4;
  color: #999;
  font-size: 13px;
}

/* ================= TABLETTE : vue appel plein ecran ================= */
.tab-call {
  height: 100%;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  background: linear-gradient(160deg, #1c1f26, #0a0b0d);
  color: #fff;
  text-align: center;
}
.tab-call-avatar {
  width: 120px; height: 120px; border-radius: 50%;
  background: #565c68;
  display: flex; align-items: center; justify-content: center;
  font-size: 44px; font-weight: 700;
  margin-bottom: 18px;
}
.tab-call h2 { margin: 0 0 6px; font-size: 26px; }
.tab-call p { margin: 0 0 40px; color: #b6bac2; }
.tab-call-actions { display: flex; gap: 22px; }
.tab-call-btn {
  width: 60px; height: 60px; border-radius: 50%;
  background: #2c313b;
  display: flex; align-items: center; justify-content: center;
  font-size: 22px;
}
.tab-call-btn.end { background: #e0453c; }

/* ================= TABLETTE : vue accueil grille large ================= */
.tab-home {
  height: 100%;
  background: linear-gradient(160deg, #274472, #1a2c4d 55%, #0f1a30);
  color: #fff;
  display: flex;
  flex-direction: column;
  padding: 28px 40px;
}
.tab-home-time { font-size: 48px; font-weight: 300; text-align: center; margin-bottom: 30px; }
.tab-home-grid {
  flex: 1;
  display: grid;
  grid-template-columns: repeat(6, 1fr);
  gap: 24px;
  align-content: start;
}
.tab-app-icon { display: flex; flex-direction: column; align-items: center; gap: 6px; font-size: 11px; }
.tab-app-glyph {
  width: 52px; height: 52px; border-radius: 14px;
  background: rgba(255,255,255,0.9);
}
body.kind-android-tablet .tab-app-glyph { border-radius: 50%; }
.tab-home-dock {
  display: flex;
  justify-content: center;
  gap: 20px;
  padding: 14px;
  margin-top: 20px;
  background: rgba(255,255,255,0.12);
  border-radius: 20px;
  backdrop-filter: blur(12px);
}
.tab-dock-icon { width: 44px; height: 44px; border-radius: 12px; background: rgba(255,255,255,0.9); }

/* ================= CUSTOM : signage neutre ================= */
.custom-signage {
  height: 100%;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 14px;
  background: #08090b;
  color: #e6e6ea;
  font-family: "Courier New", monospace;
  position: relative;
}
.custom-clock { font-size: 64px; font-weight: 200; letter-spacing: 2px; }
.custom-date { font-size: 16px; color: #8a8a92; text-transform: capitalize; }
.custom-marquee {
  position: absolute;
  bottom: 40px; left: 0; right: 0;
  overflow: hidden;
  white-space: nowrap;
  border-top: 1px solid #2a2a2f;
  border-bottom: 1px solid #2a2a2f;
  padding: 8px 0;
}
.custom-marquee span {
  display: inline-block;
  padding-left: 100%;
  animation: custom-scroll 14s linear infinite;
  font-size: 12px;
  letter-spacing: 1px;
  color: #c9a227;
}
@keyframes custom-scroll {
  from { transform: translateX(0); }
  to   { transform: translateX(-100%); }
}
.custom-qr {
  width: 90px; height: 90px;
  background:
    repeating-linear-gradient(0deg, #e6e6ea 0 6px, transparent 6px 12px),
    repeating-linear-gradient(90deg, #e6e6ea 0 6px, transparent 6px 12px);
  background-blend-mode: multiply;
  opacity: 0.85;
  border: 4px solid #e6e6ea;
}

@media (max-width: 900px) {
  .tab-home-grid { grid-template-columns: repeat(4, 1fr); }
  .tab-conv-list { width: 42%; }
}
