/* ===== Basisstijl ===== */
*,
*::before,
*::after {
  box-sizing: border-box;
}

html, body {
  margin: 0;
  padding: 0;
  font-family: "Segoe UI", Arial, sans-serif;
  background: linear-gradient(135deg, #fdfbfb, #ebedee);
  color: #2e3a44;
  font-size: 20px;
  line-height: 1.6;
}

/* ===== Header ===== */
.header {
  background: #0077b6;
  color: white;
  padding: 20px 24px;
}
.header-inner {
  max-width: 1500px;
  margin: 0 auto;
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap; /* zorgt dat inhoud kan afbreken */
}

/* Titeltekst */
.header .tagline {
  margin: 0;
  font-size: 36px;
  font-style: italic;
  line-height: 1.2;
}

/* Logo */
.logo {
  height: 120px;
  width: auto;
  border-radius: 20px;
  box-shadow: 0 4px 8px rgba(0,0,0,0.2);
}

/* Responsive voor mobiel */
@media (max-width: 768px) {
  .header-inner {
    flex-direction: column;   /* titel boven logo */
    align-items: center;      /* centreren */
    text-align: center;
  }

  .header .tagline {
    font-size: 24px;          /* iets kleiner voor mobiel */
    margin-bottom: 12px;
  }

  .logo {
    height: 80px;             /* logo kleiner */
  }
}


/* ===== Checkbox inline ===== */
/* Checkbox naast de tekst */
.checkbox-inline {
  display: inline-flex;     /* naast elkaar */
  align-items: center;      /* verticaal centreren */
  gap: 10px;                /* ruimte tussen tekst en vinkje */
}

.checkbox-inline span {
  font-size: 18px;
  color: #6b3d00;
}

.checkbox-inline input[type="checkbox"] {
  width: 22px;
  height: 22px;
  transform: none;          /* normale grootte */
  cursor: pointer;
}




/* ===== Container Layout ===== */
.container {
  max-width: 1500px;
  margin: 20px auto;
  padding: 20px;
  display: grid;
  grid-template-columns: 260px 1fr 340px;
  gap: 20px;
}

/* ===== Persona links ===== */
.persona {
  background: #f1f8ff;
  border: 2px solid #cce4ff;
  border-radius: 16px;
  padding: 16px;
  text-align: center;
}
.persona img {
  width: 100%;
  max-width: 220px;
  height: auto;
  border-radius: 14px;
  margin-bottom: 12px;
}
.persona h3 {
  margin: 6px 0 16px;
  font-size: 22px;
  color: #245b8a;
}
.persona select {
  width: 100%;
  font-size: 18px;
  padding: 10px;
  border-radius: 10px;
  border: 2px solid #aac8e6;
}

/* ===== Chat midden ===== */
.chat-area {
  display: flex;
  flex-direction: column;
  background: #fafafa;
  border: 2px solid #dde7ee;
  border-radius: 16px;
  padding: 18px;
}

.chatbox {
  flex: 1;
  min-height: 500px;
  max-height: 70vh;
  overflow-y: auto;
  background: #ffffff;
  border: 2px solid #0077b6;
  border-radius: 16px;
  padding: 20px;
  font-size: 22px;

  /* Belangrijk: kolom-opmaak */
  display: flex;
  flex-direction: column;
  gap: 12px;  /* ruimte tussen bubbels */
}


.chat-bubble {
  display: block;          /* elk bericht op eigen regel */
  max-width: 75%;
  padding: 12px 16px;
  border-radius: 14px;
  line-height: 1.6;
  word-wrap: break-word;
  white-space: pre-wrap;
}

.chat-bubble.from-user {
  background: #d1ecf1;
  align-self: flex-end;
  text-align: right;
}

.chat-bubble.from-ai {
  background: #fff3cd;
  align-self: flex-start;
  text-align: left;
}

.chat-label {
  display: block;          /* naam altijd boven */
  font-weight: bold;
  margin-bottom: 4px;
}

/* Praatballonnen */
.user,
.ai {
  position: relative;
  display: inline-block;
  padding: 14px 18px;
  margin: 12px 0;
  border-radius: 18px;
  max-width: 85%;
  word-wrap: break-word;
  white-space: pre-wrap;
  font-size: 22px;
  line-height: 1.6;
}

.user {
  background: #d1e8ff;
  color: #0f3f7a;
  margin-left: auto;
}
.user::after {
  content: "";
  position: absolute;
  right: -12px;
  top: 12px;
  border-width: 12px 0 12px 12px;
  border-style: solid;
  border-color: transparent transparent transparent #d1e8ff;
}

.ai {
  background: #d6f5ec;
  color: #0d5e54;
  margin-right: auto;
}
.ai::after {
  content: "";
  position: absolute;
  left: -12px;
  top: 12px;
  border-width: 12px 12px 12px 0;
  border-style: solid;
  border-color: transparent #d6f5ec transparent transparent;
}

/* Chat invoer */
.chat-form {
  display: grid;
  grid-template-columns: 1fr 150px;
  gap: 12px;
  margin-top: 18px;
}
.chat-form input[type="text"] {
  font-size: 22px;
  padding: 16px;
  border: 2px solid #b9c6cf;
  border-radius: 12px;
  outline: none;
  min-height: 60px;
}
.chat-form input[type="text"]:focus {
  border-color: #0077b6;
  box-shadow: 0 0 0 3px rgba(0,119,182,0.2);
}
.chat-form button {
  font-size: 22px;
  font-weight: 700;
  border: none;
  border-radius: 12px;
  background: linear-gradient(180deg, #ffb74d, #ff9800);
  color: white;
  cursor: pointer;
  transition: 0.2s;
}
.chat-form button:hover {
  filter: brightness(1.05);
}
.chat-form button:active {
  transform: scale(0.97);
}

/* ===== Sidebar rechts (context) ===== */
.sidebar {
  background: #fff9f0;
  border: 2px solid #ffd699;
  border-radius: 16px;
  padding: 16px;
}
.sidebar h3 {
  margin-top: 0;
  color: #a65b00;
  font-size: 22px;
}
.field {
  display: grid;
  gap: 6px;
  margin-bottom: 14px;
}
.field span {
  font-size: 18px;
  color: #6b3d00;
}
.sidebar input[type="text"] {
  width: 100%;
  font-size: 20px;
  padding: 12px;
  border: 2px solid #d7c5a9;
  border-radius: 10px;
  background: #fff;
}
.sidebar input[type="text"]:focus {
  border-color: #ff9800;
  box-shadow: 0 0 0 3px rgba(255,152,0,0.2);
  outline: none;
}

/* ===== Responsiveness ===== */
@media (max-width: 1000px) {
  .container {
    grid-template-columns: 1fr;
  }
  .persona,
  .chat-area,
  .sidebar {
    order: unset;
  }
  .chatbox {
    min-height: 400px;
  }
  .chat-form {
    grid-template-columns: 1fr;
  }
}


fieldset.field {
  border: none;
  margin: 0 0 14px;
  padding: 0;
}

fieldset.field legend {
  font-size: 18px;
  margin-bottom: 6px;
  color: #6b3d00;
}

.radio-inline {
  margin-right: 15px;
  font-size: 18px;
  cursor: pointer;
}

.radio-inline input[type="radio"] {
  margin-right: 6px;
  transform: scale(1.3); /* groter voor betere klikbaarheid */
}

.mic-btn {
  font-size: 24px;
  border: none;
  border-radius: 12px;
  background: #e6f0ff;
  cursor: pointer;
  padding: 0 16px;
  margin-right: 8px;
  transition: background 0.2s;
}
.mic-btn:hover {
  background: #c9e2ff;
}

.user b,
.ai b {
  display: block;
  margin-bottom: 4px;
  font-size: 18px;
}

.message-text {
  white-space: pre-wrap;
  line-height: 1.6;
}



