/* CHAT */
    .chat-box {
      background: rgba(2, 8, 20, .8);
      border: 1px solid var(--sk2);
      border-radius: var(--r2);
      padding: 16px;
      min-height: 160px;
      max-height: 280px;
      overflow-y: auto;
      display: flex;
      flex-direction: column;
      gap: 10px;
    }

    .msg {
      display: flex;
      gap: 10px;
      align-items: flex-start;
    }

    .msg.usr {
      flex-direction: row-reverse;
    }

    .av {
      width: 30px;
      height: 30px;
      border-radius: 9px;
      display: grid;
      place-items: center;
      font-size: 13px;
      flex-shrink: 0;
    }

    .msg.ai .av {
      background: linear-gradient(135deg, #1a56db, #06b6d4);
      box-shadow: 0 0 12px rgba(59, 130, 246, .28);
    }

    .msg.usr .av {
      background: rgba(30, 50, 90, .8);
      border: 1px solid rgba(148, 163, 184, .18);
    }

    .bubble {
      max-width: 85%;
      padding: 10px 14px;
      border-radius: 12px;
      font-size: 12.5px;
      line-height: 1.6;
    }

    .msg.ai .bubble {
      background: rgba(12, 24, 50, .9);
      border: 1px solid rgba(59, 130, 246, .15);
      color: var(--tx);
    }

    .msg.usr .bubble {
      background: rgba(26, 50, 90, .8);
      border: 1px solid rgba(59, 130, 246, .2);
      color: #dbeafe;
    }

    .bubble b {
      color: #93c5fd;
    }

    .chat-row {
      display: flex;
      gap: 9px;
      margin-top: 10px;
    }

    .chat-inp {
      flex: 1;
      background: rgba(4, 10, 24, .9);
      border: 1px solid rgba(148, 163, 184, .15);
      border-radius: var(--r3);
      padding: 10px 14px;
      color: var(--tx);
      font-size: 13px;
      font-family: inherit;
      outline: none;
      transition: all .18s;
    }

    .chat-inp:focus {
      border-color: rgba(96, 165, 250, .44);
    }

    .chat-inp::placeholder {
      color: var(--mu);
    }

    .send-btn {
      padding: 10px 18px;
      border-radius: var(--r3);
      border: none;
      background: linear-gradient(135deg, #1a56db, #0891b2);
      color: #fff;
      font-size: 12.5px;
      font-weight: 700;
      cursor: pointer;
      transition: all .18s;
      font-family: inherit;
      white-space: nowrap;
    }

    .send-btn:hover {
      box-shadow: 0 4px 16px rgba(59, 130, 246, .38);
      transform: translateY(-1px);
    }

    .send-btn:disabled {
      opacity: .4;
      cursor: not-allowed;
      transform: none;
    }

    .gen-bar {
      display: flex;
      align-items: center;
      justify-content: space-between;
      gap: 16px;
      flex-wrap: wrap;
      margin-top: 16px;
      padding-top: 16px;
      border-top: 1px solid var(--sk2);
    }

    .gen-note {
      font-size: 12px;
      color: var(--mu);
    }

    .gen-btn {
      display: inline-flex;
      align-items: center;
      gap: 10px;
      padding: 13px 26px;
      border-radius: var(--r2);
      border: none;
      background: linear-gradient(135deg, #1a56db 0%, #0891b2 55%, #06b6d4 100%);
      color: #fff;
      font-family: 'Syne', sans-serif;
      font-size: 14px;
      font-weight: 700;
      cursor: pointer;
      box-shadow: 0 6px 24px rgba(59, 130, 246, .34);
      transition: all .22s;
    }

    .gen-btn:hover {
      box-shadow: 0 10px 34px rgba(59, 130, 246, .48);
      transform: translateY(-2px);
    }

    .gen-btn:disabled {
      opacity: .4;
      cursor: not-allowed;
      transform: none;
      box-shadow: none;
    }
