html {
  font-size: 14px;
}

@media (min-width: 768px) {
  html {
    font-size: 16px;
  }
}

.btn:focus, .btn:active:focus, .btn-link.nav-link:focus, .form-control:focus, .form-check-input:focus {
  box-shadow: 0 0 0 0.1rem white, 0 0 0 0.25rem #258cfb;
}

html {
  position: relative;
  min-height: 100%;
}

body {
  margin-bottom: 60px;
}

.form-floating > .form-control-plaintext::placeholder, .form-floating > .form-control::placeholder {
  color: var(--bs-secondary-color);
  text-align: end;
}

.form-floating > .form-control-plaintext:focus::placeholder, .form-floating > .form-control:focus::placeholder {
  text-align: start;
}
/* ============================================================
   CommI görüşme ekranı
   Satır içi <style> bloğu yerine burada: CSP kuralları netleşiyor
   ve stiller sayfalar arasında paylaşılabiliyor.
   ============================================================ */

/* Kutucuk ızgarası. Sütun sayısını JS kişi sayısına göre belirler
   (video-grid.js _relayout); burada yalnızca boşluk ve oran var. */
.commi-grid-host {
    min-height: 0;
    overflow: hidden;
}

.commi-video-grid {
    display: grid;
    gap: 8px;
    padding: 8px;
    height: 100%;
}

.commi-tile {
    position: relative;
    background: #000;
    border: 2px solid transparent;
    border-radius: 8px;
    overflow: hidden;
    min-height: 0;
}

.commi-tile video {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
}

/* Kamera kapalıyken siyah kare yerine kullanıcıya bilgi veren bir yüzey */
.commi-tile.video-off::after {
    content: "\F2E9";
    font-family: "bootstrap-icons";
    position: absolute;
    inset: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 3rem;
    color: #6c757d;
    background: #1a1a1a;
}

.commi-tile-bar {
    position: absolute;
    left: 0;
    right: 0;
    bottom: 0;
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 8px;
    padding: 4px 8px;
    background: rgba(0, 0, 0, 0.55);
    color: #fff;
    font-size: 0.85rem;
}

.commi-tile-name {
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.commi-tile-badges i {
    margin-left: 6px;
    color: #ffc107;
}

/* Konuşan kişi */
.commi-tile.speaking {
    border-color: #00e05a;
    box-shadow: 0 0 18px rgba(0, 224, 90, 0.6);
}

#participantsList .badge.speaking {
    animation: commi-pulse 0.6s infinite alternate;
}

@keyframes commi-pulse {
    from { transform: scale(1); }
    to   { transform: scale(1.08); }
}

.commi-control {
    width: 50px;
    height: 50px;
}

/* Bağlantı kaplaması */
.commi-overlay {
    position: fixed;
    inset: 0;
    background: rgba(0, 0, 0, 0.8);
    display: none;
    justify-content: center;
    align-items: center;
    z-index: 9999;
}

.commi-overlay-box {
    text-align: center;
    color: #fff;
}

/* Kısa bildirim — alert() yerine, görüşmeyi kesmeyen bir şerit */
.commi-toast {
    position: fixed;
    top: 16px;
    left: 50%;
    transform: translateX(-50%);
    background: rgba(0, 0, 0, 0.85);
    color: #fff;
    padding: 10px 18px;
    border-radius: 20px;
    z-index: 1080;
    display: none;
    max-width: 90vw;
}

.commi-online-dot {
    width: 10px;
    height: 10px;
}

.commi-hidden {
    display: none;
}

/* ============================================================
   CommI mesajlaşma ekranı
   ============================================================ */

.commi-chat,
.commi-chat-row {
    height: calc(100vh - 120px);
}

.commi-chat-side,
.commi-chat-main {
    height: 100%;
    min-height: 0;
}

.commi-conversation.active {
    background: #e7f1ff;
}

.commi-conversation-main {
    min-width: 0;   /* text-truncate ancak bu varsa çalışır */
}

/* Konuşma balonları */
.commi-bubble-row {
    display: flex;
    margin-bottom: 8px;
}

.commi-bubble-row.mine {
    justify-content: flex-end;
}

.commi-bubble {
    max-width: 70%;
    padding: 8px 12px;
    border-radius: 12px;
    background: #fff;
    border: 1px solid #dee2e6;
    word-break: break-word;
}

.commi-bubble-row.mine .commi-bubble {
    background: #d1f4d0;
    border-color: #b7e6b5;
}

.commi-bubble-sender {
    font-size: 0.8rem;
    font-weight: 600;
    color: #0d6efd;
    margin-bottom: 2px;
}

.commi-bubble-text {
    white-space: pre-wrap;
}

.commi-bubble-image {
    max-width: 260px;
    max-height: 260px;
    border-radius: 8px;
    display: block;
}

.commi-bubble-meta {
    font-size: 0.72rem;
    color: #6c757d;
    text-align: right;
    margin-top: 2px;
}

.commi-receipt {
    margin-left: 4px;
}
