:root{
  --bg:#05070b;
  --card:#070a10;
  --border:rgba(255,60,60,0.28);
  --text:#e6e6e6;
  --muted:#a6a6a6;

  --t-red:#ff2b2b;
  --t-red2:#b30000;
  --t-green:#3bff7a;

  --mono:"Montserrat", Arial, Helvetica, sans-serif;
}

/* RESET / BASE */
*{ box-sizing:border-box; }
html,body{ height:100%; margin:0; padding:0; }

body{
  color:var(--text);
  font-family:var(--mono);
  background:
    url("images/background.png") center top no-repeat fixed,
    radial-gradient(1200px 700px at 20% -10%, rgba(255,43,43,0.18), transparent 60%),
    radial-gradient(900px 600px at 100% 0%, rgba(59,255,122,0.08), transparent 55%),
    linear-gradient(180deg, #02040a, #06070b 60%, #02040a);
  background-size: cover, auto, auto, auto;
}

/* ===== TOP KOVINSKI LOGO PANEL ===== */
/* ===== TOP KOVINSKI LOGO PANEL ===== */
.tb-coin-header{
  max-width:980px;
  margin:16px auto 8px;
  padding:0 16px;
  display:flex;
  justify-content:center;   /* centriramo coin */
}

.tb-coin-img{
  width:360px;              /* manjše na desktopu */
  max-width:100%;
  display:block;
  border-radius:18px;
  box-shadow:0 18px 40px rgba(0,0,0,0.85);
}




/* ================= HERO VIDEO PANEL ================= */

.chat-hero{
  max-width: 980px;
  margin: 24px auto 0;
  padding: 0 16px;
}

.chat-hero-inner{
  position: relative;
  height: 260px;
  border-radius: 18px;
  overflow: hidden;
  border: 1px solid var(--border);
  box-shadow: 0 18px 40px rgba(15,23,42,0.9);
  background: url("images/background.png") center center no-repeat;
  background-size: cover;
}

.chat-hero-video{
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.chat-hero-overlay{
  position: absolute;
  inset: 0;
  background:
    radial-gradient(circle at center, rgba(255,0,0,0.25), rgba(0,0,0,0.9)),
    linear-gradient(to bottom, rgba(0,0,0,0.2), rgba(0,0,0,0.95));
}

.chat-hero-content{
  position: relative;
  z-index: 2;
  height: 100%;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
  padding: 0 16px;
}

.chat-hero-content h1{
  margin: 0;
  font-size: 26px;
  text-transform: uppercase;
  letter-spacing: 2px;
  font-weight: 900;
  text-shadow: 0 0 16px rgba(0,0,0,0.9);
  font-family: "Bebas Neue", sans-serif;
}

.chat-hero-content p{
  margin-top: 8px;
  font-size: 14px;
  color: #ff4a4a;
  letter-spacing: 1px;
  font-family: "Montserrat", sans-serif;
}

/* ================ LAYOUT & CARD ================= */

main{
  max-width: 980px;
  margin: 16px auto 40px auto; /* razmak med video panelom in chat panelom */
  padding: 0 16px;
}

.layout{
  display:flex;
  flex-direction:column;
  gap:16px;
  margin-top:18px;
}

.card{
  width:100%;
  background:var(--card);
  border-radius:18px;
  border:1px solid var(--border);
  box-shadow:0 18px 40px rgba(15,23,42,0.9);
  overflow:hidden;
}

.card-inner{
  padding:16px 16px 14px;
  display:flex;
  flex-direction:column;
  gap:10px;
}

/* ================ HEADER ================= */

.chat-header{
  display:flex;
  align-items:flex-start;
  justify-content:space-between;
  gap:10px;
  border-bottom:1px solid rgba(148,163,184,0.35);
  padding-bottom:10px;
}

.chat-header-left{
  display:flex;
  gap:10px;
  align-items:flex-start;
}

.bot-avatar{
  width:80px;
  height:80px;
  border-radius:999px;
  display:grid;
  place-items:center;
  font-weight:700;
  font-size:16px;
  color:#ffeaea;
  background:linear-gradient(135deg,var(--t-red),var(--t-red2));
  border:1px solid rgba(255,43,43,0.65);
  box-shadow:
    0 0 30px rgba(255,43,43,0.6),
    inset 0 0 10px rgba(255,43,43,0.4);
  overflow:hidden;
  position:relative;
}

/* TIGERBLOOD KOVINSKI AVATAR */
.terminator-avatar{
  width:100%;
  height:100%;
  border-radius:50%;
  background:
    url("/images/tigerblood-coin.png") center center no-repeat;
  background-size:cover;
  background-color:#000;
}

.chat-header-main strong{
  font-size:18px;
  letter-spacing:.8px;
  font-family:"Bebas Neue", sans-serif;
}

.chat-header-main small{
  display:block;
  font-size:12px;
  color:var(--muted);
  margin-top:3px;
  letter-spacing:.4px;
  font-family:"Montserrat", sans-serif;
}

.chat-tags{
  margin-top:6px;
  display:flex;
  flex-wrap:wrap;
  gap:6px;
}

.chat-tags .tag{
  font-size:10px;
  padding:3px 7px;
  border-radius:999px;
  background:rgba(15,23,42,0.9);
  border:1px solid rgba(148,163,184,0.6);
  color:#e5e7eb;
  letter-spacing:.5px;
}

.chat-header-right{
  display:flex;
  flex-direction:column;
  align-items:flex-end;
  gap:6px;
  font-size:11px;
  color:var(--muted);
  min-width:170px;
}

.status-pill{
  display:inline-flex;
  align-items:center;
  gap:6px;
  font-size:11px;
  padding:3px 8px;
  border-radius:999px;
  background:rgba(255,43,43,0.10);
  border:1px solid rgba(255,43,43,0.65);
  color:#ffd0d0;
  letter-spacing:.6px;
}

.status-pill .dot{
  width:7px;
  height:7px;
  border-radius:999px;
  background:var(--t-red);
}

.chat-header-right .tiny{
  font-size:10px;
  opacity:.85;
}

/* ================ CHAT BODY ================= */

.chat-body{
  margin-top:6px;
  border-radius:14px;
  padding:10px 10px 12px;
  background:radial-gradient(circle at top,rgba(15,23,42,0.95),rgba(2,6,23,0.98));
  border:1px solid rgba(255,43,43,0.35);
  box-shadow:0 0 0 1px rgba(255,43,43,0.10) inset, 0 18px 44px rgba(0,0,0,0.55);
  position:relative;
  overflow:hidden;
}

.chat-body::before{
  content:"";
  position:absolute;
  inset:0;
  pointer-events:none;
  background:repeating-linear-gradient(
    to bottom,
    rgba(255,255,255,0) 0px,
    rgba(255,255,255,0) 2px,
    rgba(255,255,255,0.03) 3px
  );
  mix-blend-mode:overlay;
  opacity:.55;
  border-radius:14px;
}

.chat-body::after{
  content:"";
  position:absolute;
  inset:0;
  pointer-events:none;
  background:radial-gradient(circle at 50% 0%, rgba(255,43,43,0.10), transparent 55%);
  opacity:.9;
  border-radius:14px;
}

.msg-row{
  display:flex;
  margin-bottom:8px;
  position:relative;
  z-index:1;
}

.msg{
  display:flex;
  gap:8px;
  font-size:13px;
  line-height:1.55;
  max-width:100%;
}

.msg .avatar{
  width:26px;
  height:26px;
  border-radius:999px;
  display:grid;
  place-items:center;
  font-size:11px;
  font-weight:600;
  flex-shrink:0;
}

.from-bot .avatar{
  background:rgba(255,43,43,0.92);
  color:#ffeaea;
  box-shadow:0 0 14px rgba(255,43,43,0.25);
}

.from-user .avatar{
  background:rgba(59,255,122,0.85);
  color:#08110a;
}

/* avatar za AI s tiger logom v mehurčkih */
.avatar.ai-avatar{
  width:26px;
  height:26px;
  min-width:26px;
  min-height:26px;
  border-radius:999px;
  overflow:hidden;
  display:grid;
  place-items:center;
  background:radial-gradient(circle at center, #220000, #000);
  box-shadow:
    0 0 6px rgba(255,43,43,.6),
    0 0 14px rgba(255,43,43,.35);
}

.avatar.ai-avatar img{
  width:100%;
  height:100%;
  object-fit:cover;
  border-radius:999px;
  display:block;
}

.bubble{
  padding:8px 10px;
  border-radius:14px;
  background:rgba(10,12,16,0.92);
  border:1px solid rgba(255,43,43,0.32);
  color:#e5e7eb;
  max-width:100%;
  word-wrap:break-word;
  white-space:pre-wrap;
  letter-spacing:.35px;
}

.from-user .bubble{
  background:rgba(10,18,12,0.92);
  border-color:rgba(59,255,122,0.45);
  color:#d9ffe6;
}

/* AI text glow */
.from-bot .bubble{
  color: #ff3b3b;
  text-shadow:
    0 0 6px rgba(255, 43, 43, .35),
    0 0 14px rgba(255, 43, 43, .22),
    0 0 22px rgba(255, 43, 43, .12);
}

.from-bot .bubble.glow{
  animation: tPulse 1.35s ease-in-out infinite;
}

@keyframes tPulse{
  0%, 100%{
    filter: brightness(1);
    text-shadow:
      0 0 6px rgba(255, 43, 43, .35),
      0 0 14px rgba(255, 43, 43, .22),
      0 0 22px rgba(255, 43, 43, .12);
  }
  50%{
    filter: brightness(1.18);
    text-shadow:
      0 0 7px rgba(255, 43, 43, .60),
      0 0 18px rgba(255, 43, 43, .34),
      0 0 28px rgba(255, 43, 43, .20);
  }
}

.chat-welcome{
  margin:0 0 6px;
  font-weight:600;
  font-size:14px;
}

/* typewriter cursor */
.tw-cursor{
  display:inline-block;
  width:10px;
  margin-left:2px;
  color: var(--t-red);
  animation: twblink .85s step-end infinite;
}

@keyframes twblink { 50% { opacity: 0; } }

/* typing indicator */
.typing{
  display:inline-flex;
  gap:4px;
}

.typing .dot{
  width:6px;
  height:6px;
  border-radius:999px;
  background:var(--t-red);
  opacity:.6;
  animation:bounce 1s infinite ease-in-out;
}

.typing .dot:nth-child(2){ animation-delay:.15s; }
.typing .dot:nth-child(3){ animation-delay:.3s; }

@keyframes bounce{
  0%,80%,100%{ transform:scale(.7); opacity:.4; }
  40%{ transform:scale(1); opacity:1; }
}

/* ================ COMPOSER ================= */

.composer{
  margin-top:8px;
  border-radius:14px;
  background:rgba(15,23,42,0.96);
  border:1px solid rgba(55,65,81,0.9);
  padding:8px;
  display:flex;
  flex-direction:column;
  gap:6px;
}

#composer{
  width:100%;
  min-height:60px;
  max-height:160px;
  resize:vertical;
  border-radius:10px;
  border:1px solid rgba(31,41,55,0.9);
  background:#020617;
  color:#e5e7eb;
  font-size:13px;
  font-family:var(--mono);
  letter-spacing:.35px;
  padding:7px 9px;
}

.composer-tools{
  display:flex;
  align-items:flex-end;
  justify-content:space-between;
  gap:10px;
  flex-wrap:wrap;
  font-size:11px;
  color:var(--muted);
}

.btn-icon{
  width:30px;
  height:30px;
  border-radius:999px;
  border:0;
  background:linear-gradient(135deg,var(--t-red),var(--t-red2));
  display:grid;
  place-items:center;
  cursor:pointer;
  color:#ffeaea;
  box-shadow:0 12px 28px rgba(255,43,43,0.35);
}

.btn-icon svg{
  width:16px;
  height:16px;
}

/* ================ FOOTER ================= */

footer{
  margin-top:18px;
  padding:16px 0 10px;
  font-size:11px;
  color:var(--muted);
  text-align:center;
}
/* SEND BUTTON → right aligned */
.cta-row{
  width:100%;
  display:flex;
  align-items:center;
}

#sendBtn{
  margin-left:auto;
}
/* ===== BACK TO TRAINER SELECT BUTTON ===== */

.tb-top-bar{
  max-width:980px;
  margin:10px auto 0 auto;
  padding:0 16px;
  display:flex;
  justify-content:flex-start;
}

.tb-back-btn{
  border-radius:999px;
  border:1px solid rgba(148,163,184,0.55);
  background:rgba(10,15,25,0.95);
  color:#e5e7eb;
  font-size:12px;
  padding:6px 12px;
  cursor:pointer;
  display:inline-flex;
  align-items:center;
  gap:6px;
  letter-spacing:.4px;
}

.tb-back-btn:hover{
  border-color:#ff2b2b;
  color:#ffe2e2;
  box-shadow:0 0 14px rgba(255,43,43,0.35);
}

/* mobile: full width / lažji klik */
@media (max-width:768px){
  .tb-top-bar{
    max-width:none;
    padding:0 8px;
  }
  .tb-back-btn{
    width:100%;
    justify-content:center;
    font-size:13px;
    padding:8px 10px;
  }
}

/* ===== TRAINER HEADER ===== */

.tb-trainer-header{
  max-width:980px;
  margin:10px auto 12px auto;
  padding:0 16px;
  display:flex;
  align-items:center;
  gap:12px;
}

.tb-trainer-img{
  height:70px;
  width:70px;
  border-radius:14px;
  object-fit:cover;
  border:1px solid rgba(255,43,43,0.55);
  box-shadow:0 0 18px rgba(255,43,43,0.35);
}

.tb-trainer-label{
  font-size:12px;
  color:#ddd;
  letter-spacing:.5px;
}

.tb-trainer-label strong{
  display:block;
  color:#ff3b3b;
  font-size:15px;
  letter-spacing:1px;
}

/* mobile */
@media(max-width:768px){
  .tb-trainer-header{
    padding:0 8px;
    margin-top:4px;
  }

  .tb-trainer-img{
    width:60px;
    height:60px;
  }
}



@media (max-width:768px){

  /* === 1. KOVANEC – FULL WIDTH, BREZ RADIUS === */
  .tb-coin-header{
    max-width:none;
    margin:0;
    padding:0;
  }

  .tb-coin-img{
    width:100%;
    border-radius:0;
    box-shadow:0 8px 20px rgba(0,0,0,0.9);
  }

  /* === 2. OZADJE – BREZ TEŽKE SLIKE, SAMO ENOSTAVNO DARK === */
  body{
    background:#05070b;
  }

  /* === 3. LAYOUT – VSE OD ROBA DO ROBA === */
  main{
    max-width:none;
    margin:0;
    padding:0;
  }

  .layout{
    margin-top:0;
    gap:10px;
  }

  .card{
    border-radius:0;
    box-shadow:none;
    border-left:0;
    border-right:0;
  }

  .card-inner{
    padding:10px 8px 8px;
  }

  .chat-header{
    padding-bottom:6px;
  }

  /* === 4. CHAT BODY – BREZ OVERLAYEV, BREZ HUD EFEKTOV === */
  .chat-body{
    border-radius:0;
    padding:8px;
    box-shadow:none;
  }

  .chat-body::before,
  .chat-body::after{
    display:none;
  }

  /* === 5. AVATARJI SKRITI – VEČ PROSTORA ZA TEXT === */
  .msg{
    gap:6px;
    font-size:14px;
  }

  .msg .avatar{
    display:none;
  }

  .bubble{
    font-size:14px;
    letter-spacing:0;
  }

  .from-bot .bubble{
    text-shadow:none;
  }

  .from-bot .bubble.glow{
    animation:none;
  }

  /* === 6. COMPOSER – SIMPLE INPUT OD ROBA DO ROBA === */
  .composer{
    border-radius:0;
    border-top:1px solid rgba(55,65,81,0.9);
    border-left:0;
    border-right:0;
    padding:8px;
  }

  #composer{
    min-height:50px;
    max-height:140px;
    font-size:14px;
    box-shadow:none !important;
    text-shadow:none !important;
    background:#020617 !important;
    letter-spacing:0 !important;
  }

  .composer-tools{
    font-size:11px;
  }

  /* manjši avatar v headerju (če ga še kdaj pokažemo) */
  .bot-avatar{
    width:60px;
    height:60px;
  }

  footer{
    padding:10px 8px;
    font-size:10px;
  }
}
