body {
  font-family: 'Helvetica', sans-serif;
  margin: 0;
  padding: 0;
  background-color: #393939; 
  color: #ffffff; 
  transition: background-color 0.3s ease;
  scroll-behavior: smooth;
  overflow-x: hidden;
}

/* Ensure all elements use Helvetica font */
* {
  font-family: 'Helvetica', sans-serif;
}

.hidden {
  opacity: 0;
  transition: opacity 0.5s ease; /* Adjust the duration as needed */
}

.visible {
  opacity: 1;
  transition: opacity 0.5s ease; /* Ensure the transition matches */
}

.container {
  display: flex;
  justify-content: center;
  align-items: center;
  height: 100vh;
  background-color: #222; 
  transition: background-color 0.3s ease;
}

h1 {
  font-size: 24px;
  font-weight: normal;
  color: #ffffff; 
  margin-bottom: 20px;
  text-align: center;
  letter-spacing: 2px;
}

.logo {
  width: 300px;
  height: auto;
  font-size: 18px;
  border-radius: 7px;
  font-weight: normal;
  transition: filter 0.3s ease;
  background-color: none; 
  outline: none;
}

.logo:hover {
  filter: grayscale(100%);
}

.sphere {
  position: flex;
  width: "auto";
  height: 70px;
  margin-right: -25px;
  margin-top: 10px;
  border-radius: 90%;
}

.loader-placeholder {
  display: flex;
  align-items: center;
  justify-content: center;
  margin-top: 10px;
}

.loader-placeholder img {
  width: 60px; 
  height: 60px;
  border-radius: 50%;
  margin-right: 70%;
}

.main-container {
  display: flex;
  margin-top: auto;
}

.sidebar {
  display: flex;
  position: fixed;
  flex-direction: column;
  justify-content: space-between;
  width: 350px;
  background-color: #333333;
  border-right: 1px solid #222;
  color: #fff;
  padding: 10px;
  height: 100vh;
  margin-top: 0;
  margin-bottom: 0;
  left: 0;
}

.sidebar h2 {
  font-size: 16px;
  margin-bottom: 20px;
  margin-left: 20px;
}

.sidebar ul {
  list-style-type: none;
  padding: 0;
}

.sidebar ul li {
  margin-bottom: 10px;
}

.sidebar ul li a {
  color: #fff;
  text-decoration: none;
  margin-left: 20px;
}

.sidebar ul li a:hover {
  text-decoration: underline;
}

.quit-button {
  background-color: transparent;
  color: #727070;
  border: 1px solid #727070;
  padding: 10px 20px;
  cursor: pointer;
  text-transform: uppercase;
  border-radius: 5px;
  margin-top: 10%;
  margin-bottom: 10%;
  margin-left: 20px;
  margin-right: 20px;
  box-shadow: none;
  transition: all 0.3s ease-in-out;
}

.quit-button:hover {
  background-color: rgba(119, 119, 119, 0.1);
  transform: scale(1.05);
}

.quit-button:active {
  transform: scale(0.95);
}

.finish-button {
  display: none;
  background-color: #222;
  border: 5px solid #FF8266;
  position: flex;
  color: #FFFFFF;
  border: none;
  padding: 45px 25px;
  cursor: pointer;
  text-transform: uppercase;
  border-radius: 5px;
  margin-left: 20px;
  margin-right: 20px;
  margin-bottom: auto;
  box-shadow: 5px 5px 7px rgba(0, 0, 0, 0.6);
  transition: all 0.3s ease-in-out;
}

.finish-button:hover {
  background-color: #FF8266;
  transform: scale(1.05);
}

.finish-button:active {
  transform: scale(0.95);
}


.command-button {
  position: absolute;
  display: flex;
  flex-direction: column;
  padding: none;
  margin-bottom: 10px;
  top: 30%;
  background-color: transparent;
  color: #FFFFFF;
  cursor: pointer;
  text-transform: none;
  border-radius: 5px;
  margin-left: 20px;
  margin-right: 20px;
  box-shadow: 0 2px 2px rgba(0, 0, 0, 0.2);
  transition: all 0.3s ease-in-out;
}

.command-button:active {
  transform: scale(0.95);
}

.command-button button {
  border: 5px solid #FF8266;
}

.command-button p {
  margin-top: 25px; 
  margin-bottom: 25px;
  font-size: 15px;
  text-transform: none;
}

.command-instructions {
  background-color: transparent;
  position: absolute;
  color: #FFFFFF;
  border: none;
  padding: 25px 25px;
  cursor: pointer;
  text-transform: none;
  border-radius: 5px;
  margin-left: 20px;
  margin-right: 20px;
  margin-top: 0;
  margin-bottom: 0;
  box-shadow: 0 2px 2px rgba(0, 0, 0, 0.2);
  transition: all 0.3s ease-in-out;
}

#quit-prompt {
  display: none;
  position: fixed;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  background-color: white;
  padding: 20px;
  border: 1px solid black;
  z-index: 1000;
}

#quit-prompt p {
  margin: 0 0 10px;
  color: #222;
}

#quit-prompt button {
  margin-right: 10px;
}

#finish-prompt {
  display: none;
  position: fixed;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  background-color: white;
  padding: 20px;
  border: 1px solid black;
  z-index: 1000;
}

#finish-prompt p {
  margin: 0 0 10px;
  color: #222;
}

#finish-prompt button {
  margin-right: 10px;
}

#post-chat-popup {
  position: fixed;
  left: 400px; /* 350px sidebar + 50px spacing */
  top: calc(10vh + 50px); /* header height + 50px spacing */
  right: 50px; /* 50px spacing from right edge */
  width: auto;
  margin: 0;
  padding: 20px;
  border-radius: 10px;
  color: #e9e9e9;
  background-color: #222;
  box-shadow: 0 4px 8px rgba(0, 0, 0, 0.1);
  overflow-y: auto;
  max-height: 80vh;
}

#post-chat-popup p {
  margin: 0 0 20px;
  color: #969393;
  font-size: 16px;
  text-align: left;
}

.popup-buttons {
  display: flex;
  flex-direction: column;
  gap: 15px;
  align-items: center;
}

.popup-button {
  padding: 15px 20px;
  font-size: 14px;
  border: 1px solid #FF8266;
  background-color: #222;
  cursor: pointer;
  border-radius: 4px;
  max-width: 100%;
  word-wrap: break-word;
  white-space: normal;
  text-align: center;
  line-height: 1.4;
  min-height: 50px;
  display: flex;
  align-items: center;
  justify-content: center;
}

.popup-button:hover {
  background-color: #333;
}

.popup-button:active {
  background-color: #d0d0d0;
}

.redirection-button {
  display: none;
  background-color: #222;
  color: #ffffff;
  position: flex;
  border: 10px solid #de222c;
  padding: 130px 20px;
  cursor: pointer;
  text-transform: none;
  font-weight: bold;
  border-radius: 5px;
  font-size: 16px;
  box-shadow: none;
  transition: all 1.5s ease-in-out;
  margin-bottom: auto;
  margin-left: 20px;
  margin-right: 20px;
}

.redirection-button:hover {
  background-color: rgba(12, 8, 7, 0.1);
  transform: scale(1.05);
}

.redirection-button:active {
  transform: scale(0.95);
}

.right-container {
  display: flex;
  flex-direction: column;
  flex-grow: 1;
  height:90vh;
}

.header {
  display: flex;
  position: fixed;
  justify-content: right;
  justify-items: right;
  align-items: right;
  padding: 10px;
  background-color: #333333;
  color: #FFFFFF;
  width: 100%;
  height: 10vh;
  border-bottom: 1px solid #222;
}

.website-name h1 {
  font-size: 12px;
  font-weight: normal;
  margin-top: 20px;
  margin-right: 20%;
  text-align: right;
}

.Research-Dashboard-Header {
  font-size: 18px;
  font-weight: normal;
  margin-right: 5%;
  text-align: right;
  margin-top: -10px;
}


button {
  background-color: #222;
  color: #FFFFFF;
  border: none;
  padding: 15px 25px;
  cursor: pointer;
  text-transform: uppercase;
  border-radius: 5px;
  margin-top: 5px;
  box-shadow: 0 2px 2px rgba(0, 0, 0, 0.2);
  transition: all 0.3s ease-in-out;
  font-family: 'Helvetica', sans-serif;
}

button:hover {
  background-color: #FF8266;
  transform: scale(1.05);
}

button:active {
  transform: scale(0.95);
}

.login-form {
  display: flex;
  flex-direction: column;
  align-items: center;
  padding-bottom: 30px;
  padding-top: 30px;
  padding-left: 30px;
  padding-right: 30px;
  background-color: #313131;
  border-radius: 10px;
  box-shadow: 0 4px 8px rgba(0, 0, 0, 0.1);
  transition: box-shadow 0.3s ease;
}

.login-form:hover {
  box-shadow: 0 8px 16px rgba(0, 0, 0, 0.2);
}

.login-form h2 {
  font-size: 18px;
  font-weight: normal;
  color: #de222c;
  margin-bottom: 20px;
}

.login-form label {
  font-size: 14px;
  font-weight: bold;
  color: #333333;
  margin-bottom: 10px;
}

.login-form .input-field {
  display: block;
  width: 80%;
  padding: 10px;
  border: 1px solid #cccccc;
  border-radius: 3px;
  font-size: 14px;
  color: #333333;
  margin-bottom: 20px;
  transition: border-color 0.3s ease;
}

.login-form .input-field:focus {
  border-color: #de222c;
}

.login-form button[type="submit"] {
  background-color: #761414;
  color: #ffffff;
  border: none;
  padding: 10px 20px;
  cursor: pointer;
  text-transform: uppercase;
  font-size: 14px;
  border-radius: 3px;
  transition: all 0.3s ease-in-out;
}

.login-form button[type="submit"]:hover {
  background-color: #de222c;
}

.bottom-left-corner {
  position: fixed;
  bottom: 20px;
  left: 20px;
  color: white;
  font-size: 16px;
}
.tiny-text {
  color: grey;
  font-size: 12px;
}
.highlighted-text {
  font-size: 16px;
  color: grey;
}

.password-table {
  position: absolute;
  right: 20%;
  top: 50%;
  transform: translateY(-50%);
  font-size: 14px;
  max-height: 40vh;
  overflow-y: auto;
}

.password-table td, .password-table th {
  padding: 0 10px; /* Adjust the value as needed */
}

.researcher-about {
  position: fixed;
  left: 400px; /* 350px sidebar + 50px spacing */
  top: calc(10vh + 50px); /* header height + 50px spacing */
  right: 400px; /* 50px spacing from right edge */
  width: auto;
  margin: 0;
  font-size: 16px;
  color: #e7e4e4;
  line-height: 1.6;
  padding: 80px;
  background-color: #222;
  border-radius: 5px;
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.1);
  overflow-y: auto;
  max-height: calc(90vh - 100px); /* Prevent overflow beyond viewport */
}

.researcher-about a {
  color: #FF8C00; /* Dark orange color */
  text-decoration: none;
  font-size: 18px; /* Slightly larger */
}

.researcher-about a:hover {
  background-color: #FF8C00; /* Highlighted dark orange */
  color: #222; /* Text color change on hover */
}

.researcher-button {
  position: fixed;
  bottom: 20px;
  right: 20px;
  background-color: #4c4c4c;
  color: #FFFFFF;
  border: none;
  padding: 10px 20px;
  cursor: pointer;
  font-size: 14px;
  border-radius: 5px;
  transition: background-color 0.3s ease, transform 0.3s ease;
  z-index: 10;
}

.researcher-button:hover {
  background-color: #FF8266;
  transform: scale(1.05);
}

#researcher-popup {
  position: fixed;
  top: 70%;
  left: 80%;
  transform: translate(-50%, -50%);
  background-color: #4c4c4c;
  padding: 50px;
  padding-top: 25px;
  padding-bottom: 25px;
  padding-left: 50px;
  padding-right: 50px;
  box-shadow: 0 0 10px rgba(0,0,0,0.5);
  z-index: 9999;
  opacity: 0;
  transition: opacity 0.5s ease;
}

#researcher-popup.visible {
  opacity: 1;
}

.researcher-popup.invisible {
  display: none;
}

.researcher-form {
  display: flex;
  flex-direction: column;
  align-items: center;
  width: 100%; 
}

.researcher-form input {
  margin-bottom: 10px;
}

#agent {
  background-color: #dedede;
}

#agent-creation {
  position: fixed;
  left: 400px; /* 350px sidebar + 50px spacing */
  top: calc(10vh + 50px); /* header height + 50px spacing */
  right: 50px; /* 50px spacing from right edge */
  width: auto;
  margin: 0;
  padding: 20px;
  border-radius: 10px;
  color: #e9e9e9;
  background-color: #222;
  box-shadow: 0 4px 8px rgba(0, 0, 0, 0.1);
  overflow-y: auto;
  max-height: calc(90vh - 100px); /* Prevent overflow beyond viewport */
}

#agent-creation h2 {
  color: #e6e6e6;
  text-align: left;
}

#agent-form label {
  color: #e6e6e6;
  text-decoration: none;
  text-transform: none;
}

.agent-creation-form {
  display: flex;
  flex-direction: column;
  align-items: left;
  padding: 20px;
  margin-left: 0;
}

.agent-creation-form label {
  margin-top: 10px;
  margin-bottom: 10px;
  font-weight: bold;
  color: #333;
  max-width: 50%;
}

.agent-creation-form textarea,
.agent-creation-form input {
  width: 80%;
  padding: 10px;
  border: 1px solid #ddd;
  border-radius: 5px;
  font-size: 16px;
  align-items: center;
  font-family: 'Helvetica', sans-serif;
}

/* Model select dropdown styling to match survey selects */
.agent-creation-form select,
#model {
  width: 60%;
  padding: 12px 16px;
  color: #e9e9e9 !important;
  background: #444 !important;
  background-image: url("data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' fill='%23e9e9e9' viewBox='0 0 16 16'%3e%3cpath d='m7.247 4.86-4.796 5.481c-.566.647-.106 1.659.753 1.659h9.592a1 1 0 0 0 .753-1.659l-4.796-5.48a1 1 0 0 0-1.506 0z'/%3e%3c/svg%3e") !important;
  background-repeat: no-repeat !important;
  background-position: right 12px center !important;
  background-size: 12px !important;
  padding-right: 40px !important;
  appearance: none !important;
  border: 1px solid #555 !important;
  font-size: 16px;
  border-radius: 4px;
  font-family: 'Helvetica', sans-serif;
  margin-top: 10px;
}

#model:focus {
  outline: none;
  border-color: #FF8266 !important;
  box-shadow: 0 0 5px rgba(255, 130, 102, 0.3);
}

/* Add spacing for model selection label */
.agent-creation-form label[for="model"] {
  margin-bottom: 5px;
  display: block;
}

.agent-creation-form textarea {
  min-height: 100px;
}

.agent-creation-form button {
  margin-top: 15px;
  padding: 10px;
  background-color: #818181;
  color: #fff;
  border: none;
  border-radius: 5px;
  cursor: pointer;
  font-size: 16px;
  width: 150px;
}

.agent-creation-form button:hover {
  background-color: #FF8266;
}

/* Enhanced Agent Review Section */
.agent-review-section {
  position: fixed;
  left: 400px; /* 350px sidebar + 50px spacing */
  top: calc(10vh + 50px); /* header height + 50px spacing */
  right: 50px; /* 50px spacing from right edge */
  width: auto;
  margin: 0;
  padding: 20px;
  border-radius: 10px;
  color: #e9e9e9;
  background-color: #222;
  box-shadow: 0 4px 8px rgba(0, 0, 0, 0.1);
  overflow-y: auto;
  max-height: calc(90vh - 100px); /* Prevent overflow beyond viewport */
}

.randomised-password-config {
  background-color: #2a2a2a;
  border-radius: 10px;
  padding: 25px;
  margin-bottom: 30px;
  border-left: 4px solid #4CAF50;
}

.randomised-password-config h3 {
  color: #ffffff;
  margin-top: 0;
  margin-bottom: 15px;
  font-size: 18px;
}

.config-description {
  color: #bbb;
  font-size: 14px;
  margin-bottom: 20px;
  line-height: 1.5;
}

.password-setting-group {
  display: flex;
  gap: 15px;
  align-items: center;
  margin-bottom: 15px;
  flex-wrap: wrap;
}

.password-setting-group label {
  color: #ffffff;
  font-weight: 500;
  min-width: 180px;
}

.password-setting-group input[type="text"] {
  flex: 1;
  min-width: 200px;
  padding: 10px;
  border: 2px solid #555;
  border-radius: 5px;
  background-color: #1a1a1a;
  color: #ffffff;
  font-size: 14px;
}

.password-setting-group input[type="text"]:focus {
  outline: none;
  border-color: #4CAF50;
}

.config-button {
  padding: 10px 20px;
  background-color: #4CAF50;
  color: white;
  border: none;
  border-radius: 5px;
  cursor: pointer;
  font-size: 14px;
  transition: background-color 0.3s ease;
}

.config-button:hover {
  background-color: #45a049;
}

.config-button.secondary {
  background-color: #818181;
}

.config-button.secondary:hover {
  background-color: #666;
}

.current-password-display {
  color: #bbb;
  font-size: 14px;
  font-style: italic;
}

.current-password-display span {
  color: #4CAF50;
  font-weight: 500;
}

.agents-list-container {
  background-color: #2a2a2a;
  border-radius: 10px;
  padding: 25px;
  border-left: 4px solid #FF8266;
}

.agents-list-container h3 {
  color: #ffffff;
  margin-top: 0;
  margin-bottom: 15px;
  font-size: 18px;
}

.agents-description {
  color: #bbb;
  font-size: 14px;
  margin-bottom: 25px;
  line-height: 1.5;
}

.agents-list {
  display: flex;
  flex-direction: column;
  gap: 15px;
}

.agent-card {
  background-color: #333;
  border-radius: 8px;
  padding: 20px;
  border-left: 4px solid #4CAF50;
  transition: all 0.3s ease;
}

.agent-card.inactive {
  opacity: 0.6;
  border-left-color: #7f8c8d;
}

.agent-card-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 15px;
}

.agent-info {
  flex: 1;
}

.agent-name {
  color: #ffffff;
  font-size: 16px;
  font-weight: 600;
  margin: 0 0 5px 0;
}

.agent-password {
  color: #4CAF50;
  font-size: 14px;
  font-family: 'Courier New', monospace;
  margin: 0;
}

.agent-toggle-container {
  display: flex;
  align-items: center;
  gap: 15px;
}

.agent-toggle-label {
  color: #ffffff;
  font-size: 14px;
  font-weight: 500;
}

.agent-switch {
  position: relative;
  display: inline-block;
  width: 60px;
  height: 34px;
}

.agent-switch input {
  opacity: 0;
  width: 0;
  height: 0;
}

.agent-switch .slider-switch {
  position: absolute;
  cursor: pointer;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background-color: #7f8c8d;
  transition: .4s;
  border-radius: 34px;
  box-shadow: inset 0 2px 4px rgba(0, 0, 0, 0.2);
}

.agent-switch .slider-switch:before {
  position: absolute;
  content: "";
  height: 26px;
  width: 26px;
  left: 4px;
  bottom: 4px;
  background-color: white;
  transition: .4s;
  border-radius: 50%;
  box-shadow: 0 2px 4px rgba(0, 0, 0, 0.2);
}

.agent-switch input:checked + .slider-switch {
  background-color: #27ae60;
  box-shadow: inset 0 2px 4px rgba(0, 0, 0, 0.2), 0 0 8px rgba(39, 174, 96, 0.3);
}

.agent-switch input:focus + .slider-switch {
  box-shadow: 0 0 0 3px rgba(39, 174, 96, 0.3);
}

.agent-switch input:checked + .slider-switch:before {
  transform: translateX(26px);
}

.expand-toggle {
  background: none;
  border: none;
  color: #4CAF50;
  cursor: pointer;
  font-size: 18px;
  padding: 5px;
  border-radius: 3px;
  transition: background-color 0.3s ease;
}

.expand-toggle:hover {
  background-color: rgba(76, 175, 80, 0.1);
}

.delete-agent-btn {
  background-color: #e74c3c;
  border: none;
  color: white;
  cursor: pointer;
  font-size: 12px;
  padding: 6px 12px;
  border-radius: 4px;
  transition: all 0.3s ease;
  font-weight: 500;
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

.delete-agent-btn:hover {
  background-color: #c0392b;
  transform: translateY(-1px);
  box-shadow: 0 2px 4px rgba(0, 0, 0, 0.2);
}

.delete-agent-btn:active {
  transform: translateY(0);
  box-shadow: 0 1px 2px rgba(0, 0, 0, 0.2);
}

.agent-details {
  display: none;
  margin-top: 15px;
  padding-top: 15px;
  border-top: 1px solid #444;
}

.agent-details.expanded {
  display: block;
}

.agent-config {
  background-color: #1a1a1a;
  border-radius: 6px;
  padding: 15px;
  margin-top: 10px;
}

.config-section {
  margin-bottom: 15px;
}

.config-section:last-child {
  margin-bottom: 0;
}

.config-label {
  color: #4CAF50;
  font-size: 12px;
  font-weight: 600;
  text-transform: uppercase;
  margin-bottom: 5px;
  display: block;
}

.config-value {
  color: #e9e9e9;
  font-size: 14px;
  word-break: break-word;
}

.config-value.pre-prompt {
  background-color: #2a2a2a;
  padding: 10px;
  border-radius: 4px;
  font-family: 'Courier New', monospace;
  font-size: 12px;
  line-height: 1.4;
  max-height: 200px;
  overflow-y: auto;
}

.config-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  gap: 15px;
}

.special-back-button {  
  padding: 25px 25px;
  background-color: #555;
  color: #fff;
  text-decoration: none;
  border-radius: 5px;
  transition: all 0.3s ease-in-out;
  text-align: center;
}

#file-content-popup {
  position: fixed;
  top: 25%;
  right: 10%;
  color: #222;
  padding: 20px;
  z-index: 1000;
  width: 30%;
  border-radius: 10px;
  background-color: #e0e0e0;
  box-shadow: 0 4px 8px rgba(0, 0, 0, 0.1);
}

#file-list {
  margin-top: 5%;
  margin-left: 25%;
}

#file-list li {
  color: #fff;
  background-color: #222;
  border: 2px solid #222;
  border-radius: 5px;
  padding: 10px;
  margin-bottom: 10px;
  list-style: none;
  text-align: center;
  width: 30%;
  cursor: pointer;
}

#file-list li:hover {
  background-color: #FF8266;
}

#review-conditions h2 {
  color: #e14040;
}

#edit-passwords {
  position: fixed;
  left: 400px; /* 350px sidebar + 50px spacing */
  top: calc(10vh + 50px); /* header height + 50px spacing */
  right: 50px; /* 50px spacing from right edge */
  width: auto;
  margin: 0;
  padding: 20px;
  border-radius: 10px;
  color: #e9e9e9;
  background-color: #222;
  box-shadow: 0 4px 8px rgba(0, 0, 0, 0.1);
  overflow-y: auto;
  max-height: calc(90vh - 100px); /* Prevent overflow beyond viewport */
}

#edit-passwords h2 {
  color: #e8e8e8;
  text-align: center;
}

#edit-passwords-form {
  display: flex;
  flex-direction: column;
  align-items: center;
  color: #e8e8e8;
  margin-left: 0;
}

#edit-passwords-form label {
  margin-top: 10px;
  font-weight: bold;
  color: #e3e3e3;
}

#edit-passwords-form input,
#edit-passwords-form select {
  width: 60%;
  padding: 10px;
  border: 1px solid #ddd;
  border-radius: 5px;
  font-size: 16px;
}

#edit-passwords-form button {
  margin-top: 15px;
  padding: 10px;
  width: 150px;
  background-color: #818181;
  color: #fff;
  border: none;
  border-radius: 5px;
  cursor: pointer;
  font-size: 16px;
}

#edit-passwords-form button:hover {
  background-color: #FF8266;
}

.data-download-section {
  position: fixed;
  left: 400px; /* 350px sidebar + 50px spacing */
  top: calc(10vh + 50px); /* header height + 50px spacing */
  right: 50px; /* 50px spacing from right edge */
  width: auto;
  margin: 0;
  padding: 20px;
  border-radius: 10px;
  color: #e9e9e9;
  background-color: #333;
  box-shadow: 0 4px 8px rgba(0, 0, 0, 0.1);
  overflow-y: auto;
  max-height: calc(90vh - 100px); /* Prevent overflow beyond viewport */
}

.data-download-section h2 {
  color: #e6e6e6;
  text-align: left;
}

.download-button {
  margin-top: 15px;
  align-items: center;
  margin-bottom: 10px;
  padding: 10px;
  background-color: #555;
  color: #fff;
  border: none;
  border-radius: 5px;
  cursor: pointer;
  font-size: 16px;
  width: 50%;
}

.download-button:hover {
  background-color: #FF8266;
}

.api-selection-section {
  position: fixed;
  left: 400px; /* 350px sidebar + 50px spacing */
  top: calc(10vh + 50px); /* header height + 50px spacing */
  right: 50px; /* 50px spacing from right edge */
  width: auto;
  margin: 0;
  padding: 20px;
  border-radius: 10px;
  color: #e9e9e9;
  background-color: #222;
  box-shadow: 0 4px 8px rgba(0, 0, 0, 0.1);
  overflow-y: auto;
  max-height: calc(90vh - 100px); /* Prevent overflow beyond viewport */
}

.api-selection-section h2 {
  color: #e6e6e6;
  text-align: center;
}

.api-selection-section h3 {
  color: #e6e6e6;
  text-align: center;
  margin-top: 30px;
  margin-bottom: 15px;
  border-top: 1px solid #444;
  padding-top: 20px;
}

.model-selection-container {
  background-color: #333;
  padding: 20px;
  border-radius: 8px;
  margin-bottom: 20px;
}

.model-selection-container label {
  display: block;
  margin-bottom: 10px;
  color: #e6e6e6;
  font-weight: bold;
}

.model-dropdown {
  width: 100%;
  padding: 10px;
  margin-bottom: 15px;
  background-color: #444;
  color: #fff;
  border: 1px solid #666;
  border-radius: 5px;
  font-size: 14px;
  max-height: 200px;
  overflow-y: auto;
}

.model-dropdown:focus {
  outline: none;
  border-color: #FF8266;
  box-shadow: 0 0 5px rgba(255, 130, 102, 0.3);
}

.current-model-info {
  background-color: #2a2a2a;
  padding: 10px;
  border-radius: 5px;
  margin-top: 15px;
  text-align: center;
  color: #e6e6e6;
  border-left: 4px solid #FF8266;
}

.current-model-info span {
  font-weight: bold;
  color: #FF8266;
}

.provider-buttons {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 8px;
  margin-top: 10px;
}

@media (max-width: 768px) {
  .provider-buttons {
    grid-template-columns: 1fr;
  }
}

.api-button {
  margin-top: 15px;
  margin-bottom: 10px;
  padding: 10px;
  background-color: #818181;
  color: #fff;
  border: none;
  border-radius: 5px;
  cursor: pointer;
  font-size: 16px;
  width: 100%;
  text-transform: none;
}

.api-button:hover {
  background-color: #FF8266;
}

.researcher-sidebar {
  display: flex;
  position: fixed;
  flex-direction: column;
  align-items: flex-start;
  gap: 10px;
  width: 350px;
  background-color: #333333;
  border-right: 1px solid #222;
  color: #fff;
  padding: 10px;
  height: 100vh;
  margin: 0;
  left: 0;
  top: 0;
}

.researcher-sidebar-content {
  margin-left: 15%;
  width: 250px;
  height: auto;
}

.active-button {
  background-color: #FF8266;
  padding: 20px;
  transition: padding 0.2s ease-in-out;
}

.special-back-button:hover {
  background-color: #FF8266;
  transform: scale(1.05);
}

.input-field {
  width: 100%;
  padding: 10px;
  margin: 0;
  border: 1px solid #ccc;
  border-radius: 5px;
  background-color: rgba(255, 255, 255, 0.8);
  box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
  transition: all 1.2s ease;
  outline: none;
  font-family: 'Helvetica', sans-serif;
}

.input-field:focus {
  background-color: rgba(255, 255, 255, 1);
}

.chat-area {
  background-color: #393939;
  padding: 20px;
  overflow-y: auto;
  overflow-x: hidden;
  height: 85vh;
  margin-top: 10vh;
  margin-left: 280px;
  scroll-behavior: smooth;
  flex-grow: 1;
}

.chat-messages-container {
  display: flex;
  flex-direction: column;
  overflow-y: auto;
  max-height: 100%;
}

.chat-bubble {
  width: 60%;
  font-size: 16px;
  padding: 15px;
  border-radius: 10px;
  background-color: transparent;
  transition: background-color 0.3s ease, border-color 0.3s ease;
}

.chat-bubble:hover {
  background-color: rgba(255, 255, 255, 0.1);
}

.chat-bubble.user-message {
  margin-left: 20%;
  margin-right: auto;
  margin-top: 2%;
  border: 1px solid #444;
}

.chat-bubble.user-message:hover {
  border-color: #ffffff;
}

.user-label {
  font-weight: bold;
  color: #888;
  margin-right: 10px;
}

.chat-bubble.llm-message {
  margin-left: auto;
  margin-right: 20%;
  border: 1px solid transparent;
}

.chat-bubble.llm-message:hover {
  border-color: #ffffff;
}

.assistant-label {
  font-weight: bold;
  color: #888;
  margin-right: 10px;
}

.chat-bubble p {
  margin: 0;
  line-height: 1.5;
}

.user-message {
  align-self: flex-end;
}

.llm-message {
  color: #ffffff;
  margin-left: auto;
  align-self: flex-start;
}

.chat-input {
  display: flex;
  justify-content: space-evenly;
  align-items: center;
  padding: 20px;
  background-color: #393939;
  transition: all 1.6s ease;
  height: 5vh;
  color: #ffffff;
}

.text-input {
  flex-grow: 1;
  padding: 20px;
  margin-left: 280px;
  margin-top: auto;
  width: 25vw;
  outline: none;
  border: none;
  background-color: #5a5a5a;
  border-radius: 4px; 
  color: #ffffff; 
  font-size: 14px;
  transition: all 1.2s ease;
  font-family: 'Helvetica', sans-serif;
}

.text-input:focus {
  outline: none;
  border-radius: 30px;
  color: #222;
  background-color: #e4e4e4;
}

.submit-button {
  position: flex;
  width: 120px;
  height: 50px;
  right: 18%;
  bottom: 11.8%;
  text-transform: none;
}

select {
  appearance: none;
  border: none;
  background-color: transparent;
  padding: 10px;
  font-size: 16px;
  color: #333333;
  font-family: 'Helvetica', sans-serif;
  cursor: pointer;
  display: inline-block;
  position: relative;
}

select:after {
  content: '';
  display: block;
  position: absolute;
  top: calc(50% - 5px);
  right: 10px;
  width: 10px;
  height: 10px;
  border-right: 1px solid #333333;
  border-bottom: 1px solid #333333;
  transform: rotate(45deg);
  pointer-events: none;
}

select:focus {
  outline: none;
}

select option {
  background-color: #ffffff;
  color: #333333;
  font-size: 16px;
  border: none;
  padding: 10px;
  cursor: pointer;
}

select option:checked {
  background-color: #333333;
  color: #ffffff;
}

::-webkit-scrollbar {
  width: 12px;
}

::-webkit-scrollbar-track {
  background: #333;
}

::-webkit-scrollbar-thumb {
  background-color: #555;
  border-radius: 10px;
  border: 3px solid #333;
}

::-webkit-scrollbar-thumb:hover {
  background-color: #777;
}

@keyframes bounce {
  0%, 100% {
      transform: translateY(0);
  }
  50% {
      transform: translateY(-10px);
  }
}

.bounce {
  animation: bounce 0.5s infinite alternate;
}

.progress {
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  width: 70%;
  height: 35%;
  position: relative;
  margin: 2.5rem 3rem;
  text-align: center;
  background: none;
  border-radius: 10%;
}

.progress svg {
  position: absolute;
  width: 220px;
  height: 220px;
  transform: rotate(-90deg);
}

.progress circle {
  fill: none;
  stroke-width: 10;
  stroke-dasharray: 628;
  stroke-linecap: round;
}

.circle-bg {
  stroke: #FF8266;
  opacity: 0.1;
}

.circle-progress {
  stroke: #FF8266;
  stroke-dashoffset: 628; /* 2πr, start fully offset */
}

.timer-display {
  font-size: 3.5rem;
  margin: 20px auto;
}

.time {
  font-size: 3.5rem !important;
  margin: 20px auto;
}

#timer-message {
  color: white;
  background-color: tomato;
  display: none;
  padding: .5rem;
  font-size: 1rem;
  text-align: center;
  border-radius: 1rem;
}

/* Timer Settings Styles */
.timer-settings-section,
.url-configuration-section {
  position: fixed;
  left: 400px; /* 350px sidebar + 50px spacing */
  top: calc(10vh + 50px); /* header height + 50px spacing */
  right: 50px; /* 50px spacing from right edge */
  width: auto;
  margin: 0;
  padding: 20px;
  border-radius: 10px;
  color: #e9e9e9;
  background-color: #222;
  box-shadow: 0 4px 8px rgba(0, 0, 0, 0.1);
  overflow-y: auto;
  max-height: calc(90vh - 100px); /* Prevent overflow beyond viewport */
}

.timer-settings-container,
.url-settings-container {
  background-color: #2a2a2a;
  border-radius: 10px;
  padding: 30px;
  margin-top: 50px;
}

.setting-group {
  margin-bottom: 25px;
}

.setting-group label {
  display: block;
  font-size: 16px;
  font-weight: 500;
  margin-bottom: 8px;
  color: #ffffff;
}

.setting-group input[type="number"],
.setting-group input[type="url"] {
  width: 100%;
  max-width: 300px;
  padding: 10px;
  border: 2px solid #555;
  border-radius: 5px;
  background-color: #1a1a1a;
  color: #ffffff;
  font-size: 14px;
}

.setting-group input[type="number"]:focus,
.setting-group input[type="url"]:focus {
  outline: none;
  border-color: #4CAF50;
}

.setting-group input[type="checkbox"] {
  margin-right: 10px;
  transform: scale(1.2);
}

.setting-note {
  display: block;
  font-size: 12px;
  color: #aaa;
  margin-top: 5px;
  font-style: italic;
}

/* Enhanced URL Configuration Styles */
.config-row {
  display: flex;
  gap: 20px;
  margin-bottom: 15px;
  align-items: flex-start;
}

/* For URL and button text layout */
.config-row.url-button-row {
  display: block;
}

.config-row.url-button-row .config-column {
  margin-bottom: 15px;
}

.config-column {
  flex: 1;
  min-width: 250px;
}

.config-column label {
  display: block;
  font-size: 14px;
  font-weight: 500;
  margin-bottom: 5px;
  color: #ffffff;
}

.config-column input[type="text"],
.config-column input[type="url"] {
  width: 100%;
  padding: 10px;
  border: 2px solid #555;
  border-radius: 5px;
  background-color: #1a1a1a;
  color: #ffffff;
  font-size: 14px;
}

.config-toggle {
  background-color: #333;
  padding: 15px;
  border-radius: 8px;
  border-left: 4px solid #7f8c8d;
}

/* Post-Interaction Survey Toggle Switch Styling */
.config-toggle .post-survey-switch {
  position: relative;
  display: inline-block;
  width: 60px;
  height: 34px;
  margin-right: 10px;
}

.config-toggle .post-survey-switch input {
  opacity: 0;
  width: 0;
  height: 0;
}

.config-toggle .post-survey-switch .slider-switch {
  position: absolute;
  cursor: pointer;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background-color: #7f8c8d;
  transition: .4s;
  border-radius: 34px;
  box-shadow: inset 0 2px 4px rgba(0, 0, 0, 0.2);
}

.config-toggle .post-survey-switch .slider-switch:before {
  position: absolute;
  content: "";
  height: 26px;
  width: 26px;
  left: 4px;
  bottom: 4px;
  background-color: white;
  transition: .4s;
  border-radius: 50%;
  box-shadow: 0 2px 4px rgba(0, 0, 0, 0.2);
}

.config-toggle .post-survey-switch input:checked + .slider-switch {
  background-color: #27ae60;
  box-shadow: inset 0 2px 4px rgba(0, 0, 0, 0.2), 0 0 8px rgba(39, 174, 96, 0.3);
}

.config-toggle .post-survey-switch input:focus + .slider-switch {
  box-shadow: 0 0 0 3px rgba(39, 174, 96, 0.3);
}

.config-toggle .post-survey-switch input:checked + .slider-switch:before {
  transform: translateX(26px);
}

.config-toggle .toggle-container {
  display: flex;
  align-items: center;
  margin-bottom: 10px;
}

.config-toggle label {
  font-weight: 600;
  color: #ffffff;
  margin: 0;
}

.toggle-note {
  display: block;
  font-size: 12px;
  color: #bbb;
  margin-top: 5px;
  margin-left: 25px;
  font-style: italic;
}

.trigger-conditions {
  margin-top: 20px;
  padding: 20px;
  background-color: #333;
  border-radius: 8px;
  border-left: 4px solid #7f8c8d;
}

.trigger-conditions h4 {
  color: #ffffff;
  margin-top: 0;
  margin-bottom: 15px;
  font-size: 16px;
}

.trigger-conditions h5 {
  color: #e0e0e0;
  margin-bottom: 10px;
  font-size: 14px;
}

.trigger-type-selector {
  margin-bottom: 20px;
}

.trigger-type-selector label {
  display: block;
  margin-bottom: 8px;
  cursor: pointer;
  font-weight: normal;
}

.trigger-type-selector input[type="radio"] {
  margin-right: 8px;
  transform: scale(1.2);
  accent-color: #4CAF50;
}

.trigger-config {
  background-color: #2a2a2a;
  padding: 15px;
  border-radius: 6px;
  margin-top: 15px;
}

.trigger-stages {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  gap: 15px;
}

.stage-config {
  background-color: #1a1a1a;
  padding: 12px;
  border-radius: 4px;
  border-left: 3px solid #FF8266;
}

.stage-config label {
  display: block;
  font-size: 12px;
  font-weight: 500;
  margin-bottom: 5px;
  color: #e0e0e0;
}

.stage-config input[type="number"] {
  width: 100%;
  padding: 8px;
  border: 1px solid #555;
  border-radius: 3px;
  background-color: #333;
  color: #ffffff;
  font-size: 13px;
}

.stage-config input[type="number"]:focus {
  outline: none;
  border-color: #FF8266;
  box-shadow: 0 0 3px rgba(255, 130, 102, 0.3);
}

.quit-study-config {
  border-left: 4px solid #e74c3c;
}

.external-redirect-config {
  border-left: 4px solid #3498db;
}

.timer-preview {
  background-color: #1a1a1a;
  border-radius: 10px;
  padding: 20px;
  margin: 20px 0;
  text-align: center;
}

.timer-preview h3 {
  margin-top: 0;
  color: #ffffff;
  font-size: 18px;
}

.preview-progress {
  position: relative;
  display: inline-block;
  width: 120px;
  height: 120px;
}

.preview-progress svg {
  width: 120px;
  height: 120px;
  transform: rotate(-90deg);
}

.preview-circle-bg {
  fill: none;
  stroke: #333;
  stroke-width: 8;
}

.preview-circle-progress {
  fill: none;
  stroke: #4CAF50;
  stroke-width: 8;
  stroke-linecap: round;
  stroke-dasharray: 314;
  stroke-dashoffset: 0;
  transition: stroke-dashoffset 0.3s ease;
}

.preview-timer-display {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  font-size: 16px;
  font-weight: bold;
  color: #ffffff;
}

.timer-button {
  background-color: #4CAF50;
  color: white;
  border: none;
  padding: 12px 24px;
  font-size: 16px;
  border-radius: 5px;
  cursor: pointer;
  margin-top: 20px;
  transition: background-color 0.3s;
}

.timer-button:hover {
  background-color: #45a049;
}

.url-button {
  background-color: #4CAF50;
  color: white;
  border: none;
  padding: 12px 24px;
  font-size: 16px;
  border-radius: 5px;
  cursor: pointer;
  margin-top: 20px;
  margin-right: 10px;
  transition: background-color 0.3s;
}

.url-button:hover {
  background-color: #45a049;
}

.url-button.secondary {
  background-color: #f44336;
}

.url-button.secondary:hover {
  background-color: #da190b;
}

.current-url-display {
  background-color: #1a1a1a;
  border-radius: 5px;
  padding: 10px;
  margin-top: 10px;
  font-family: 'Helvetica', sans-serif;
  font-size: 14px;
  border-left: 4px solid #4CAF50;
}

.current-url-display span {
  color: #4CAF50;
  font-weight: bold;
}

/* Enhanced Agent Creation Form Styles */
.form-section {
  margin: 30px 0;
  padding: 20px;
  background-color: #2a2a2a;
  border-radius: 8px;
  border-left: 4px solid #FF8266;
}

.form-section h3 {
  color: #FF8266;
  margin-top: 0;
  margin-bottom: 15px;
  font-size: 18px;
}

.form-section h4 {
  color: #e6e6e6;
  margin: 15px 0 10px 0;
  font-size: 16px;
}

.form-section small {
  color: #b0b0b0;
  font-size: 12px;
  display: block;
  margin-top: 5px;
}

.model-quick-select {
  margin-top: 20px;
}

.provider-buttons {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  gap: 10px;
  margin-top: 15px;
}

.provider-buttons .api-button {
  padding: 12px 16px;
  background-color: #555;
  color: #fff;
  border: none;
  border-radius: 6px;
  cursor: pointer;
  font-size: 14px;
  transition: all 0.3s ease;
  border: 2px solid transparent;
}

.provider-buttons .api-button:hover {
  background-color: #FF8266;
  transform: translateY(-2px);
}

.provider-buttons .api-button.selected {
  background-color: #FF8266;
  border-color: #fff;
  box-shadow: 0 0 10px rgba(255, 130, 102, 0.5);
}

/* Provider Status Display Styles */
.provider-status-container {
  background-color: #f8f9fa;
  border: 1px solid #dee2e6;
  border-radius: 8px;
  padding: 20px;
  margin: 20px 0;
  color: #333;
}

.provider-status-container h4 {
  color: #2c3e50;
  margin-top: 0;
  margin-bottom: 15px;
  font-size: 1.1em;
  font-weight: 600;
  border-bottom: 2px solid #e9ecef;
  padding-bottom: 8px;
}

.provider-category {
  margin-bottom: 15px;
}

.provider-category h5 {
  color: #495057;
  margin: 0 0 8px 0;
  font-size: 0.95em;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

.provider-list {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-left: 10px;
}

.provider-badge {
  padding: 6px 12px;
  border-radius: 20px;
  font-size: 0.85em;
  font-weight: 500;
  cursor: default;
  transition: all 0.2s ease;
  display: inline-block;
}

.provider-badge.configured {
  background-color: #d4edda;
  color: #155724;
  border: 1px solid #c3e6cb;
}

.provider-badge.configured:hover {
  background-color: #c3e6cb;
  transform: translateY(-1px);
  box-shadow: 0 2px 4px rgba(21, 87, 36, 0.2);
}

.provider-badge.not-configured {
  background-color: #f8d7da;
  color: #721c24;
  border: 1px solid #f5c6cb;
}

.provider-badge.not-configured:hover {
  background-color: #f5c6cb;
  transform: translateY(-1px);
  box-shadow: 0 2px 4px rgba(114, 28, 36, 0.2);
}

.provider-status-container p em {
  font-style: italic;
  color: #6c757d;
}

/* Security note styling */
.provider-status-container p:last-child {
  margin-bottom: 0;
  padding-top: 15px;
  border-top: 1px solid #e9ecef;
  text-align: center;
}

.provider-status-container p:last-child em {
  color: #28a745;
  font-size: 0.9em;
}

/* Responsive design for provider status */
@media (max-width: 768px) {
  .provider-status-container {
    padding: 15px;
    margin: 15px 0;
  }
  
  .provider-list {
    margin-left: 0;
  }
  
  .provider-badge {
    font-size: 0.8em;
    padding: 5px 10px;
  }
}

.form-actions {
  margin-top: 30px;
  display: flex;
  gap: 15px;
  justify-content: center;
}

.form-actions button {
  padding: 15px 30px;
  font-size: 16px;
  border: none;
  border-radius: 8px;
  cursor: pointer;
  transition: all 0.3s ease;
  max-width: 400px;
  background-color: #FF8266;
  color: white;
}

/* Override for pre-interaction survey buttons to make them narrower */
.pre-interaction-survey-form .form-actions button {
  min-width: 180px;
  padding: 12px 20px;
  font-size: 14px;
}

.form-actions button:hover {
  background-color: #e56b4a;
  transform: translateY(-2px);
  box-shadow: 0 4px 12px rgba(255, 130, 102, 0.4);
}

.creation-feedback {
  margin: 20px 0;
  padding: 15px;
  border-radius: 8px;
  font-weight: bold;
  text-align: center;
}

.feedback-success {
  background-color: #4CAF50;
  color: white;
  border-left: 5px solid #2E7D32;
}

.feedback-error {
  background-color: #f44336;
  color: white;
  border-left: 5px solid #c62828;
}

.feedback-info {
  background-color: #2196F3;
  color: white;
  border-left: 5px solid #1565C0;
}

.sphere_research_dashboard {
  position: fixed;
  height: 350px;
  border-radius: 10px;
  width: auto;
  top: 30%;
  left: 75%;
  overflow: hidden;
}

.sphere_research_dashboard:hover {
    filter: grayscale(100%);
    transform: scale(1.01);
    cursor: pointer;
}

/* Survey page styling */
/* Survey Page Body Styling */
body.survey-page {
  font-family: 'Helvetica', sans-serif;
  margin: 0;
  padding: 0;
  background: #222;
  color: #2c3e50;
  line-height: 1.6;
}

/* Survey Container and Layout */
.survey-container {
  max-width: 1000px;
  margin: 0 auto;
  background: #cccccd;
  box-shadow: 0 10px 30px rgba(0,0,0,0.1);
  min-height: 100vh;
  overflow-x: hidden;
}

.survey-header {
  background: linear-gradient(135deg, #2c3e50 0%, #34495e 100%);
  color: white;
  padding: 40px 30px;
  text-align: center;
  border-radius: 0;
  border-bottom: 3px solid #3498db;
}

.survey-header h1 {
  margin: 0;
  font-size: 2.5em;
  font-weight: 300;
  letter-spacing: 1px;
  font-family: 'Helvetica', sans-serif;
}

.survey-content {
  padding: 40px 50px;
}

/* Survey Section Styles - Updated for Qualtrics Look */
.survey-section { 
  margin-bottom: 40px; 
  padding: 30px; 
  background: #ffffff;
  border: 1px solid #e1e8ed;
  border-radius: 12px;
  box-shadow: 0 2px 10px rgba(0,0,0,0.05);
  transition: all 0.3s ease;
  overflow-x: auto;
  width: 90%;
}

.survey-section:hover {
  box-shadow: 0 5px 20px rgba(0,0,0,0.1);
  transform: translateY(-2px);
}

.survey-section-title { 
  font-size: 1.8em;
  font-weight: 600;
  color: #2c3e50;
  margin-bottom: 20px;
  padding-bottom: 12px;
  border-bottom: 3px solid #667eea;
  display: inline-block;
}

.survey-section-description {
  font-size: 1.1em;
  color: #1a1a1a;
  margin-bottom: 25px;
  line-height: 1.6;
  font-weight: 500;
}

/* Survey Form Elements */
.survey-section label {
  display: block;
  font-weight: 600;
  color: #1a1a1a !important;
  margin-bottom: 8px;
  font-size: 1.1em;
  font-family: 'Helvetica', sans-serif;
}

.survey-section input[type="number"], 
.survey-section input[type="text"], 
.survey-section select, 
.survey-section textarea {
  width: 100%;
  padding: 15px 18px;
  border: 2px solid #e1e8ed;
  border-radius: 8px;
  font-size: 16px;
  font-family: 'Helvetica', sans-serif;
  transition: all 0.3s ease;
  background: #fafbfc;
  margin-bottom: 20px;
  box-sizing: border-box;
}

.survey-section select {
  color: white;
  background: #2c3e50 !important;
  background-image: url("data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' fill='white' viewBox='0 0 16 16'%3e%3cpath d='m7.247 4.86-4.796 5.481c-.566.647-.106 1.659.753 1.659h9.592a1 1 0 0 0 .753-1.659l-4.796-5.48a1 1 0 0 0-1.506 0z'/%3e%3c/svg%3e") !important;
  background-repeat: no-repeat !important;
  background-position: right 12px center !important;
  background-size: 12px !important;
  padding-right: 40px !important;
  appearance: none !important;
  border: 2px solid #34495e !important;
  font-size: 16px;
  border-radius: 8px;
}

/* Custom section radio buttons and checkboxes styling */
.survey-section input[type="radio"],
.survey-section input[type="checkbox"] {
  width: auto;
  margin: 8px 8px 8px 0;
  transform: scale(1.2);
  cursor: pointer;
}

.survey-section input[type="radio"] + label,
.survey-section input[type="checkbox"] + label {
  color: #1a1a1a !important;
  margin-left: 8px;
  margin-right: 20px;
  cursor: pointer;
  font-weight: 600;
  padding: 5px 0;
  display: inline-block;
}

/* New Section Types Styling */

/* Slider Section Styling */
.slider-container {
  margin: 20px 0;
  padding: 20px;
  background: rgba(255, 255, 255, 0.1);
  border-radius: 8px;
}

.slider-labels {
  display: flex;
  justify-content: space-between;
  margin-bottom: 15px;
  font-weight: bold;
  color: #1a1a1a !important;
}

.slider-min, .slider-max {
  font-size: 14px;
  color: #2c3e50 !important;
  font-weight: 600;
}

.survey-slider {
  width: 100%;
  height: 8px;
  border-radius: 4px;
  background: #ddd;
  outline: none;
  margin: 15px 0;
  -webkit-appearance: none;
  appearance: none;
}

.survey-slider::-webkit-slider-thumb {
  -webkit-appearance: none;
  appearance: none;
  width: 24px;
  height: 24px;
  border-radius: 50%;
  background: #2c3e50;
  cursor: pointer;
  border: 3px solid white;
  box-shadow: 0 3px 6px rgba(0, 0, 0, 0.3);
  transition: all 0.2s ease;
}

.survey-slider::-webkit-slider-thumb:hover,
.survey-slider:active::-webkit-slider-thumb {
  background: #1a252f;
  transform: scale(1.1);
  box-shadow: 0 4px 8px rgba(0, 0, 0, 0.4);
}

.survey-slider::-moz-range-thumb {
  width: 24px;
  height: 24px;
  border-radius: 50%;
  background: #2c3e50;
  cursor: pointer;
  border: 3px solid white;
  box-shadow: 0 3px 6px rgba(0, 0, 0, 0.3);
  transition: all 0.2s ease;
}

.survey-slider::-moz-range-thumb:hover,
.survey-slider:active::-moz-range-thumb {
  background: #1a252f;
  transform: scale(1.1);
  box-shadow: 0 4px 8px rgba(0, 0, 0, 0.4);
}

.slider-value-display {
  text-align: center;
  margin-top: 10px;
  font-weight: bold;
  color: white;
  font-size: 18px;
  background: rgba(102, 126, 234, 0.2);
  padding: 8px;
  border-radius: 4px;
  display: none; /* Hide the step number display */
}

/* Dropdown Section Enhanced Styling */
.survey-section select {
  color: white;
  background: #2c3e50 !important;
  background-image: url("data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' fill='white' viewBox='0 0 16 16'%3e%3cpath d='m7.247 4.86-4.796 5.481c-.566.647-.106 1.659.753 1.659h9.592a1 1 0 0 0 .753-1.659l-4.796-5.48a1 1 0 0 0-1.506 0z'/%3e%3c/svg%3e") !important;
  background-repeat: no-repeat !important;
  background-position: right 12px center !important;
  background-size: 12px !important;
  padding-right: 40px !important;
  appearance: none !important;
  font-size: 16px;
  border: 2px solid #34495e !important;
  border-radius: 8px;
}

/* Checkbox Section Enhanced Styling */
.survey-section input[type="checkbox"] {
  width: auto;
  margin: 8px 8px 8px 0;
  transform: scale(1.3);
  cursor: pointer;
  accent-color: #667eea;
}

.survey-section input[type="checkbox"] + label {
  color: #1a1a1a !important;
  margin-left: 10px;
  margin-right: 25px;
  cursor: pointer;
  font-weight: 600;
  padding: 8px 12px;
  display: inline-block;
  font-size: 16px;
  line-height: 1.4;
  background-color: rgba(255, 255, 255, 0.1);
  border-radius: 4px;
}

/* Section Description Styling */
.survey-section-description {
  color: #1a1a1a !important;
  font-size: 16px;
  margin-bottom: 20px;
  line-height: 1.5;
  font-style: italic;
  font-weight: 500;
}

.survey-section input[type="number"]:focus, 
.survey-section input[type="text"]:focus, 
.survey-section select:focus, 
.survey-section textarea:focus {
  outline: none;
  border-color: #667eea;
  background: #ffffff;
  box-shadow: 0 0 0 3px rgba(102, 126, 234, 0.1);
  transform: translateY(-1px);
}

/* Likert Scale Styling */
.survey-likert-table {
  width: 100%;
  max-width: 100%;
  table-layout: fixed;
  border-collapse: separate;
  border-spacing: 0;
  margin: 20px 0;
  border-radius: 12px;
  overflow: hidden;
  box-shadow: 0 4px 15px rgba(0,0,0,0.1);
}

.survey-likert-table th {
  background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
  color: white;
  padding: 12px 6px;
  text-align: center;
  font-weight: 600;
  font-size: 0.85em;
  border: none;
  word-wrap: break-word;
  overflow-wrap: break-word;
}

.survey-likert-table th:first-child {
  width: 40%;
  min-width: 200px;
}

.survey-likert-table th:not(:first-child) {
  width: 12%;
  min-width: 80px;
}

.survey-likert-table td {
  padding: 15px 8px;
  text-align: center;
  background: #fafbfc;
  border-bottom: 1px solid #e1e8ed;
  transition: background-color 0.3s ease;
  word-wrap: break-word;
  overflow-wrap: break-word;
}

.survey-likert-table tr:hover td {
  background: #f1f3f4;
}

.survey-likert-table td:first-child {
  text-align: left;
  font-weight: 500;
  color: #2c3e50;
  padding-left: 15px;
  padding-right: 15px;
}

.survey-likert-table input[type="radio"] {
  width: 18px;
  height: 18px;
  margin: 0;
  cursor: pointer;
  accent-color: #667eea;
}

/* Responsive adjustments for smaller screens */
@media (max-width: 768px) {
  .survey-likert-table {
    font-size: 0.9em;
  }
  
  .survey-likert-table th,
  .survey-likert-table td {
    padding: 8px 4px;
  }
  
  .survey-likert-table th {
    font-size: 0.75em;
  }
  
  .survey-likert-table td:first-child {
    padding-left: 8px;
    padding-right: 8px;
  }
  
  .survey-likert-table input[type="radio"] {
    width: 16px;
    height: 16px;
  }
}

/* Survey Button Styling */
.survey-btn {
  padding: 15px 30px;
  border: none;
  border-radius: 8px;
  font-size: 16px;
  font-weight: 600;
  font-family: 'Helvetica', sans-serif;
  cursor: pointer;
  transition: all 0.3s ease;
  margin: 10px;
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

.survey-btn-agree {
  background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
  color: white;
  box-shadow: 0 4px 15px rgba(102, 126, 234, 0.3);
}

.survey-btn-agree:hover {
  transform: translateY(-2px);
  box-shadow: 0 6px 20px rgba(102, 126, 234, 0.4);
}

.survey-btn-quit {
  background: linear-gradient(135deg, #e74c3c 0%, #c0392b 100%);
  color: white;
  box-shadow: 0 4px 15px rgba(231, 76, 60, 0.3);
}

.survey-btn-quit:hover {
  transform: translateY(-2px);
  box-shadow: 0 6px 20px rgba(231, 76, 60, 0.4);
}

.survey-btn-cancel {
  background: linear-gradient(135deg, #95a5a6 0%, #7f8c8d 100%);
  color: white;
  box-shadow: 0 4px 15px rgba(149, 165, 166, 0.3);
}

.survey-btn-cancel:hover {
  transform: translateY(-2px);
  box-shadow: 0 6px 20px rgba(149, 165, 166, 0.4);
}

/* Submit Section */
.submit-section {
  text-align: center;
  padding: 40px 0;
  background: linear-gradient(135deg, #2c3e50 0%, #34495e 100%);
  margin: 40px -50px -40px -50px;
  border-radius: 0 0 12px 12px;
  border-top: 3px solid #3498db;
}

#submit-btn {
  padding: 18px 50px;
  font-size: 18px;
  background: linear-gradient(135deg, #28a745 0%, #20c997 100%);
  color: white;
  border: none;
  border-radius: 50px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 1px;
  cursor: pointer;
  transition: all 0.3s ease;
  box-shadow: 0 6px 20px rgba(40, 167, 69, 0.3);
  font-family: 'Helvetica', sans-serif;
}

#submit-btn:hover {
  transform: translateY(-3px);
  box-shadow: 0 10px 30px rgba(40, 167, 69, 0.4);
}

/* Next Button Styling */
#next-btn {
  padding: 18px 50px;
  font-size: 18px;
  background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
  color: white;
  border: none;
  border-radius: 50px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 1px;
  cursor: pointer;
  transition: all 0.3s ease;
  box-shadow: 0 6px 20px rgba(102, 126, 234, 0.3);
  font-family: 'Helvetica', sans-serif;
}

#next-btn:hover {
  transform: translateY(-3px);
  box-shadow: 0 10px 30px rgba(102, 126, 234, 0.4);
}

#next-disclaimer {
  color: #7f8c8d;
  font-style: italic;
  margin-bottom: 25px;
  font-size: 1.1em;
  text-align: center;
}

/* Enhanced Survey Popup Styles - Qualtrics Design */
.survey-consent-popup, .survey-quit-confirm-popup {
  position: fixed; 
  top: 0; 
  left: 0; 
  width: 100vw; 
  height: 100vh;
  background: rgba(0,0,0,0.7); 
  display: flex; 
  align-items: center; 
  justify-content: center;
  z-index: 9999;
  backdrop-filter: blur(5px);
}

.survey-popup-content {
  background: #ffffff; 
  padding: 40px 50px;
  border-radius: 15px; 
  max-width: 600px;
  width: 90%;
  text-align: center;
  box-shadow: 0 20px 60px rgba(0,0,0,0.3);
  border: 1px solid #e1e8ed;
}

.survey-popup-content h2 {
  color: #2c3e50;
  font-size: 2em;
  margin-bottom: 20px;
  font-weight: 600;
}

.survey-popup-content h3 {
  color: #e74c3c;
  font-size: 1.6em;
  margin-bottom: 15px;
  font-weight: 600;
}

.survey-popup-content p {
  color: #34495e;
  font-size: 1.1em;
  line-height: 1.6;
  margin-bottom: 15px;
}

.consent-content {
  text-align: left;
  margin: 20px 0;
  padding: 20px;
  background: #f8f9fa;
  border-radius: 8px;
  border-left: 4px solid #667eea;
  max-height: 300px;
  overflow-y: auto;
}

.form-downloads {
  margin: 25px 0;
  padding: 20px;
  background: #f1f3f4;
  border-radius: 8px;
  text-align: center;
}

.download-link {
  display: inline-block;
  margin: 8px 15px;
  padding: 12px 20px;
  background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
  color: white !important;
  text-decoration: none;
  border-radius: 25px;
  font-size: 14px;
  font-weight: 600;
  transition: all 0.3s ease;
  box-shadow: 0 4px 15px rgba(102, 126, 234, 0.3);
}

.download-link:hover {
  transform: translateY(-2px);
  box-shadow: 0 6px 20px rgba(102, 126, 234, 0.4);
  text-decoration: none;
}

.survey-hidden { 
  display: none !important; 
}

/* Survey Submission Modal Styles */
.survey-submission-modal {
  position: fixed; 
  top: 0; 
  left: 0; 
  width: 100vw; 
  height: 100vh;
  background: rgba(0,0,0,0.8); 
  display: flex; 
  align-items: center; 
  justify-content: center;
  z-index: 10000;
  backdrop-filter: blur(5px);
}

.submission-content {
  text-align: center;
  padding: 20px;
}

.submission-spinner {
  width: 40px;
  height: 40px;
  margin: 0 auto 20px auto;
  border: 4px solid #f3f3f3;
  border-top: 4px solid #667eea;
  border-radius: 50%;
  animation: spin 1s linear infinite;
}

@keyframes spin {
  0% { transform: rotate(0deg); }
  100% { transform: rotate(360deg); }
}

.submission-content h3 {
  color: #28a745;
  font-size: 1.8em;
  margin-bottom: 10px;
  font-weight: 600;
}

.submission-content p {
  color: #6c757d;
  font-size: 1.1em;
  line-height: 1.4;
}

.survey-btn { 
  padding: 15px 30px; 
  margin: 15px 10px; 
  border: none; 
  border-radius: 25px; 
  cursor: pointer;
  font-size: 16px;
  font-weight: 600;
  font-family: 'Helvetica', sans-serif;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  transition: all 0.3s ease;
  min-width: 160px;
}

.survey-btn-agree { 
  background: linear-gradient(135deg, #28a745 0%, #20c997 100%);
  color: #fff;
  box-shadow: 0 4px 15px rgba(40, 167, 69, 0.3);
}

.survey-btn-agree:hover {
  transform: translateY(-2px);
  box-shadow: 0 6px 20px rgba(40, 167, 69, 0.4);
}

.survey-btn-quit { 
  background: linear-gradient(135deg, #dc3545 0%, #c82333 100%);
  color: #fff;
  box-shadow: 0 4px 15px rgba(220, 53, 69, 0.3);
}

.survey-btn-quit:hover {
  transform: translateY(-2px);
  box-shadow: 0 6px 20px rgba(220, 53, 69, 0.4);
}

.survey-btn-cancel { 
  background: linear-gradient(135deg, #6c757d 0%, #5a6268 100%);
  color: #fff;
  box-shadow: 0 4px 15px rgba(108, 117, 125, 0.3);
}

.survey-btn-cancel:hover {
  transform: translateY(-2px);
  box-shadow: 0 6px 20px rgba(108, 117, 125, 0.4);
}

/* Pre-Interaction Survey Researcher Dashboard */
.pre-interaction-survey-form {
  position: fixed;
  left: 400px; /* 350px sidebar + 50px spacing */
  top: calc(10vh + 50px); /* header height + 50px spacing */
  right: 50px; /* 50px spacing from right edge */
  width: auto;
  margin: 0;
  padding: 20px;
  border-radius: 10px;
  color: #e9e9e9;
  background-color: #222;
  box-shadow: 0 4px 8px rgba(0, 0, 0, 0.1);
  overflow-y: auto;
  max-height: calc(90vh - 100px); /* Prevent overflow beyond viewport */
}

.pre-interaction-survey-form.active {
  display: block;
}

.form-subsection {
  background: #222;
  padding: 15px;
  margin: 10px 0;
  border-radius: 5px;
}

.survey-sections-container {
  border-radius: 5px;
  padding: 15px;
}

.add-section-control {
  margin-bottom: 20px;
  padding: 15px;
  background: #222;
  border: 2px solid #28a745;
  border-radius: 5px;
  width: 60%;
}

.section-type-selector {
  display: flex;
  align-items: center;
  gap: 15px;
}

.section-type-selector label {
  color: #e0e0e0;
  font-weight: bold;
}

.section-type-selector select {
  padding: 8px 12px;
  background: #393939;
  color: white;
  border: 1px solid #555;
  border-radius: 3px;
  min-width: 200px;
}

.survey-section-config {
  margin-bottom: 20px;
  border: 3px solid #555;
  border-radius: 5px;
  background: #222;
}

.section-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 15px;
  background: #222;
  cursor: pointer;
}

.section-header h4 {
  margin: 0;
  color: #e0e0e0;
}

.section-controls {
  display: flex;
  align-items: center;
  gap: 10px;
}

.section-content {
  padding: 15px;
  display: none;
}

.section-content.expanded {
  display: block;
}

.field-config {
  display: flex;
  align-items: center;
  gap: 10px;
  margin: 10px 0;
  padding: 8px;
  background: #222;
  border-radius: 3px;
}

.field-config select {
  color: white;
  background: #4a5568 !important;
  background-image: url("data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' fill='white' viewBox='0 0 16 16'%3e%3cpath d='m7.247 4.86-4.796 5.481c-.566.647-.106 1.659.753 1.659h9.592a1 1 0 0 0 .753-1.659l-4.796-5.48a1 1 0 0 0-1.506 0z'/%3e%3c/svg%3e") !important;
  background-repeat: no-repeat !important;
  background-position: right 8px center !important;
  background-size: 12px !important;
  padding: 8px 30px 8px 12px !important;
  border: 1px solid #555 !important;
  border-radius: 3px !important;
  min-width: 150px !important;
  appearance: none !important;
}

.demographics-fields, .likert-items-container, .freetext-questions {
  margin-top: 15px;
}

.likert-item, .freetext-question {
  display: flex;
  align-items: center;
  gap: 10px;
  margin: 10px 0;
  padding: 10px;
  background: #222;
  border-radius: 3px;
  border: 1px solid #e0e0e0;
}

.likert-item input[type="text"], .freetext-question input[type="text"] {
  flex: 1;
}

.btn-small {
  padding: 5px 10px;
  font-size: 12px;
  background: #222;
  color: white;
  border: none;
  border-radius: 3px;
  cursor: pointer;
}

.btn-add {
  padding: 8px 15px;
  background: #28a745;
  color: white;
  border: none;
  border-radius: 3px;
  cursor: pointer;
  margin: 10px 0;
}

.btn-remove {
  padding: 5px 8px;
  background: #dc3545;
  color: white;
  border: none;
  border-radius: 3px;
  cursor: pointer;
  font-weight: bold;
}

.btn-primary {
  padding: 10px 20px;
  background: #FF8266;
  color: white;
  border: none;
  border-radius: 5px;
  cursor: pointer;
  margin: 5px;
}

.btn-secondary {
  padding: 10px 20px;
  background: #6c757d;
  color: white;
  border: none;
  border-radius: 5px;
  cursor: pointer;
  margin: 5px;
}

/* Ensure proper button colors in pre-interaction survey */
.pre-interaction-survey-form .btn-primary {
  background: #FF8266;
}

.pre-interaction-survey-form .btn-primary:hover {
  background: #fd6745;
}

.pre-interaction-survey-form .btn-secondary {
  background: #6c757d;
}

.pre-interaction-survey-form .btn-secondary:hover {
  background: #545b62;
}

.file-upload-section {
  margin: 15px 0;
  padding: 15px;
  background: #222;
  border-radius: 5px;
  border: 2px dashed #ddd;
}

.file-status {
  margin-top: 10px;
  padding: 8px;
  border-radius: 3px;
  font-size: 14px;
}

.file-status.success {
  background: #d4edda;
  color: #155724;
  border: 1px solid #c3e6cb;
}

.file-status.error {
  background: #f8d7da;
  color: #721c24;
  border: 1px solid #f5c6cb;
}

.setting-group {
  margin: 15px 0;
  padding: 10px;
  background: #222;
  border-radius: 5px;
}

.setting-group label {
  display: block;
  margin-bottom: 5px;
  font-weight: bold;
}

.survey-preview {
  margin-top: 30px;
  border-top: 2px solid #007bff;
  padding-top: 20px;
}

.preview-container {
  border: 1px solid #ddd;
  border-radius: 5px;
  overflow: hidden;
}

.gender-options input {
  width: 100%;
  margin-top: 5px;
}

.likert-scale-config {
  margin: 15px 0;
  padding: 10px;
  background: #222;
  border-radius: 5px;
  border: 2px dashed #ddd;
}

.likert-scale-config select {
  color: white;
  background: #4a5568 !important;
  background-image: url("data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' fill='white' viewBox='0 0 16 16'%3e%3cpath d='m7.247 4.86-4.796 5.481c-.566.647-.106 1.659.753 1.659h9.592a1 1 0 0 0 .753-1.659l-4.796-5.48a1 1 0 0 0-1.506 0z'/%3e%3c/svg%3e") !important;
  background-repeat: no-repeat !important;
  background-position: right 8px center !important;
  background-size: 12px !important;
  padding: 8px 30px 8px 12px !important;
  border: 1px solid #555 !important;
  border-radius: 3px !important;
  min-width: 200px !important;
  appearance: none !important;
}

/* Survey form download links */
.form-downloads {
  margin: 15px 0;
  padding: 15px;
  background: #f8f9fa;
  border-radius: 5px;
  text-align: center;
}

.download-link {
  display: inline-block;
  margin: 5px 10px;
  padding: 8px 15px;
  background: #007bff;
  color: white !important;
  text-decoration: none;
  border-radius: 5px;
  font-size: 14px;
  transition: background-color 0.3s;
}

.download-link:hover {
  background: #0056b3;
  text-decoration: none;
}

.consent-content {
  text-align: left;
  margin: 15px 0;
  padding: 15px;
  background: #f8f9fa;
  border-radius: 5px;
  max-height: 300px;
  overflow-y: auto;
}

.consent-content ul {
  margin: 10px 0;
  padding-left: 20px;
}

.consent-content li {
  margin: 5px 0;
}

/* Enhanced input box styles for survey configuration */
#information-title,
#information-content,
#completion-message,
#consent-content,
#survey-title,
#post-survey-title,
#completion-popup-message,
#finish-button-text {
  display: block;
  width: 80%;
  max-width: none;
  margin: 10px 0 20px 0;
  padding: 15px 20px;
  background: linear-gradient(135deg, #2a2a2a 0%, #1a1a1a 100%);
  border: 2px solid #444;
  border-radius: 12px;
  color: #ffffff;
  font-size: 16px;
  font-family: 'Helvetica', sans-serif;
  line-height: 1.5;
  box-shadow: 
    0 4px 12px rgba(0, 0, 0, 0.3),
    inset 0 1px 0 rgba(255, 255, 255, 0.1),
    inset 0 -1px 0 rgba(0, 0, 0, 0.3);
  transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
  resize: vertical;
  min-height: 20px;
  position: relative;
}

/* Add subtle inner shadow and texture for input appearance */
#information-title:before,
#information-content:before,
#completion-message:before,
#consent-content:before,
#survey-title:before,
#post-survey-title:before,
#completion-popup-message:before,
#finish-button-text:before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: 
    repeating-linear-gradient(
      90deg,
      transparent,
      transparent 2px,
      rgba(255, 255, 255, 0.01) 2px,
      rgba(255, 255, 255, 0.01) 4px
    );
  border-radius: 12px;
  pointer-events: none;
  opacity: 0.3;
}

#information-title,
#survey-title,
#post-survey-title,
#finish-button-text {
  min-height: 50px;
}

#information-content,
#completion-message,
#consent-content,
#completion-popup-message {
  min-height: 120px;
  resize: vertical;
}

#information-title:focus,
#information-content:focus,
#completion-message:focus,
#consent-content:focus,
#survey-title:focus,
#post-survey-title:focus,
#completion-popup-message:focus,
#finish-button-text:focus {
  outline: none;
  border-color: #FF8266;
  background: linear-gradient(135deg, #333333 0%, #222222 100%);
  box-shadow: 
    0 6px 20px rgba(0, 0, 0, 0.4),
    0 0 0 3px rgba(255, 130, 102, 0.2),
    inset 0 1px 0 rgba(255, 255, 255, 0.15),
    inset 0 -1px 0 rgba(0, 0, 0, 0.2);
  transform: translateY(-2px);
}

#information-title:hover,
#information-content:hover,
#completion-message:hover,
#consent-content:hover,
#survey-title:hover,
#post-survey-title:hover,
#completion-popup-message:hover,
#finish-button-text:hover {
  border-color: #666;
  background: linear-gradient(135deg, #2d2d2d 0%, #1d1d1d 100%);
  box-shadow: 
    0 6px 16px rgba(0, 0, 0, 0.35),
    inset 0 1px 0 rgba(255, 255, 255, 0.12),
    inset 0 -1px 0 rgba(0, 0, 0, 0.25);
  cursor: text;
}

#information-title::placeholder,
#information-content::placeholder,
#completion-message::placeholder,
#consent-content::placeholder,
#survey-title::placeholder,
#post-survey-title::placeholder,
#completion-popup-message::placeholder,
#finish-button-text::placeholder {
  color: #888;
  font-style: italic;
  opacity: 0.8;
}

/* Add subtle typing indicator when focused */
#information-title:focus::after,
#information-content:focus::after,
#completion-message:focus::after,
#consent-content:focus::after,
#survey-title:focus::after,
#post-survey-title:focus::after,
#completion-popup-message:focus::after,
#finish-button-text:focus::after {
  content: '';
  position: absolute;
  right: 15px;
  top: 50%;
  width: 2px;
  height: 20px;
  background: #FF8266;
  transform: translateY(-50%);
  animation: blink 1s infinite;
}

@keyframes blink {
  0%, 50% { opacity: 1; }
  51%, 100% { opacity: 0; }
}

/* Label styling for these inputs */
label[for="information-title"],
label[for="information-content"],
label[for="completion-message"],
label[for="consent-content"],
label[for="survey-title"],
label[for="post-survey-title"],
label[for="completion-popup-message"],
label[for="finish-button-text"] {
  display: block;
  font-weight: 600;
  font-size: 14px;
  color: #FF8266;
  margin-bottom: 8px;
  margin-top: 25px;
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

/* Media Section Styles for Survey */

/* Image Display Styles */
.image-display {
  margin: 20px 0;
  text-align: center;
}

.image-display.left {
  text-align: left;
}

.image-display.right {
  text-align: right;
}

.image-display.center {
  text-align: center;
}

.image-small {
  max-width: 300px;
  height: auto;
  border-radius: 8px;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
}

.image-medium {
  max-width: 500px;
  height: auto;
  border-radius: 8px;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
}

.image-large {
  max-width: 700px;
  height: auto;
  border-radius: 8px;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
}

.image-full {
  max-width: 100%;
  height: auto;
  border-radius: 8px;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
}

.image-placeholder {
  background: #f8f9fa;
  color: #6c757d;
  text-align: center;
  padding: 60px 20px;
  border: 2px dashed #dee2e6;
  border-radius: 8px;
  margin: 20px 0;
  font-style: italic;
}

/* Video Display Styles */
.video-display {
  margin: 20px 0;
  text-align: center;
}

.video-display video,
.video-display iframe {
  border-radius: 8px;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
  max-width: 100%;
  height: auto;
}

.video-placeholder {
  background: #f8f9fa;
  color: #6c757d;
  text-align: center;
  padding: 60px 20px;
  border: 2px dashed #dee2e6;
  border-radius: 8px;
  margin: 20px 0;
  font-style: italic;
}

/* PDF Display Styles */
.pdf-display {
  margin: 20px 0;
  text-align: center;
}

.pdf-display iframe {
  border: 1px solid #dee2e6;
  border-radius: 8px;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
}

.pdf-download {
  margin: 15px 0;
  text-align: center;
}

.pdf-download .download-link {
  display: inline-block;
  padding: 12px 24px;
  background: linear-gradient(135deg, #007bff 0%, #0056b3 100%);
  color: white;
  text-decoration: none;
  border-radius: 6px;
  font-weight: 600;
  transition: all 0.3s ease;
  box-shadow: 0 4px 15px rgba(0, 123, 255, 0.3);
}

.pdf-download .download-link:hover {
  transform: translateY(-2px);
  box-shadow: 0 6px 20px rgba(0, 123, 255, 0.4);
  text-decoration: none;
  color: white;
}

.pdf-placeholder {
  background: #f8f9fa;
  color: #6c757d;
  text-align: center;
  padding: 60px 20px;
  border: 2px dashed #dee2e6;
  border-radius: 8px;
  margin: 20px 0;
  font-style: italic;
}

/* Response Section Styles */
.response-section {
  margin-top: 25px;
  padding: 20px;
  background: #f8f9fa;
  border-radius: 8px;
  border-left: 4px solid #007bff;
}

.response-section label {
  font-weight: 600;
  color: #2c3e50;
  margin-bottom: 10px;
  display: block;
}

/* PDF Response specific styling for better visibility */
.pdf-response-section .response-section label,
.response-section label[for*="pdf"],
.response-section .checkbox-option label {
  color: #1a1a1a !important;
  font-weight: 700 !important;
}

.response-section select,
.response-section textarea {
  width: 100%;
  max-width: 500px;
  padding: 12px;
  border: 2px solid #34495e !important;
  border-radius: 6px;
  font-size: 16px;
  color: white !important;
  background: #2c3e50 !important;
  transition: all 0.3s ease;
}

.response-section select:focus,
.response-section textarea:focus {
  outline: none;
  border-color: #667eea !important;
  box-shadow: 0 0 0 3px rgba(102, 126, 234, 0.2);
}

/* Checkbox Options in Response Sections */
.response-section .checkbox-option {
  margin: 12px 0;
  display: flex;
  align-items: center;
}

.response-section .checkbox-option input[type="checkbox"] {
  margin-right: 12px;
  transform: scale(1.2);
  accent-color: #007bff;
}

.response-section .checkbox-option label {
  margin-bottom: 0;
  font-weight: normal;
  cursor: pointer;
}

/* Section Description Styles */
.section-description {
  margin: 15px 0 25px 0;
  padding: 15px;
  background: #e3f2fd;
  border-left: 4px solid #2196f3;
  border-radius: 4px;
  color: #1565c0;
  font-size: 15px;
  line-height: 1.5;
}

/* File Upload Section Styles for Dashboard */
.file-upload-section {
  margin: 15px 0;
  width: 60%;
  padding: 15px;
  background: #333;
  border-radius: 8px;
  border: 1px solid #444;
}

.file-upload-section label {
  display: block;
  margin-bottom: 8px;
  color: #e9e9e9;
  font-weight: 600;
}

.file-upload-section input[type="file"] {
  width: 50%;
  padding: 10px;
  background: #444;
  border: 2px solid #555;
  border-radius: 4px;
  color: #e9e9e9;
  font-family: 'Helvetica', sans-serif;
}

.file-upload-section input[type="file"]:focus {
  border-color: #FF8266;
  outline: none;
}

.file-status {
  margin-top: 8px;
  font-size: 14px;
}

.file-status.success {
  color: #28a745;
}

.file-status.error {
  color: #dc3545;
}

.file-status.uploading {
  color: #ffc107;
}

.file-success {
  color: #28a745;
}

.file-error {
  color: #dc3545;
}

.file-uploading {
  color: #ffc107;
}

/* Media Configuration Options */
.image-display-options,
.video-display-options,
.pdf-display-options {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 15px;
  margin: 15px 0;
}

.image-display-options label,
.video-display-options label,
.pdf-display-options label {
  display: block;
  margin-bottom: 5px;
  color: #e9e9e9;
  font-weight: 600;
}

.image-display-options select,
.video-display-options select,
.pdf-display-options select {
  width: 100%;
  padding: 8px;
  background: #444;
  border: 1px solid #555;
  border-radius: 4px;
  color: #e9e9e9;
}

.video-controls {
  display: flex;
  gap: 15px;
  align-items: center;
  margin-top: 10px;
}

.video-controls input[type="checkbox"] {
  transform: scale(1.2);
  accent-color: #FF8266;
}

.pdf-options {
  margin: 15px 0;
}

.pdf-options input[type="checkbox"] {
  transform: scale(1.2);
  accent-color: #FF8266;
  margin-right: 8px;
}

.pdf-options label {
  color: #e9e9e9;
  margin-left: 8px;
}

/* Response Configuration Styles */
.response-options {
  margin-top: 20px;
  padding: 15px;
  background: #333;
  border-radius: 8px;
  border: 1px solid #444;
}

.response-options input[type="checkbox"] {
  transform: scale(1.2);
  accent-color: #FF8266;
  margin-right: 8px;
}

.response-options label {
  color: #e9e9e9;
  font-weight: 600;
}

.response-config {
  margin-top: 15px;
  padding: 15px;
  background: #444;
  border-radius: 4px;
  border-left: 3px solid #FF8266;
}

.response-config label {
  display: block;
  margin-bottom: 5px;
  color: #e9e9e9;
  font-weight: 600;
}

.response-config select,
.response-config input,
.response-config textarea {
  width: 100%;
  max-width: 300px;
  padding: 8px;
  background: #555;
  border: 1px solid #666;
  border-radius: 4px;
  color: #e9e9e9;
  margin-bottom: 10px;
}

.response-config select:focus,
.response-config input:focus,
.response-config textarea:focus {
  border-color: #FF8266;
  outline: none;
}

.response-details {
  margin-top: 15px;
}

/* Video Source Type Toggles */
.video-source-options {
  margin: 15px 0;
}

.video-source-options label {
  display: block;
  margin-bottom: 5px;
  color: #e9e9e9;
  font-weight: 600;
}

.video-source-options select {
  width: 100%;
  max-width: 300px;
  padding: 8px;
  background: #444;
  border: 1px solid #555;
  border-radius: 4px;
  color: #e9e9e9;
}

.video-url-section {
  margin-top: 15px;
}

.video-url-section label {
  display: block;
  margin-bottom: 5px;
  color: #e9e9e9;
  font-weight: 600;
}

.video-url-section input {
  width: 100%;
  padding: 10px;
  background: #444;
  border: 2px solid #555;
  border-radius: 4px;
  color: #e9e9e9;
}

.video-url-section small {
  display: block;
  margin-top: 5px;
  color: #aaa;
  font-size: 12px;
}

/* Alt text styling */
.image-alt-text {
  margin: 15px 0;
}

.image-alt-text label {
  display: block;
  margin-bottom: 5px;
  color: #e9e9e9;
  font-weight: 600;
}

.image-alt-text input {
  width: 100%;
  padding: 8px;
  background: #444;
  border: 1px solid #555;
  border-radius: 4px;
  color: #e9e9e9;
}

/* Master Survey Toggle Switch */
.master-survey-toggle {
  margin: 20px 0 30px 0;
  padding: 20px;
  background: #2c3e50;
  border-radius: 8px;
  border: 2px solid #34495e;
  box-shadow: 0 4px 8px rgba(0, 0, 0, 0.1);
}

.toggle-container {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 10px;
}

.toggle-label {
  font-size: 18px;
  font-weight: 600;
  color: #ecf0f1;
  font-family: 'Helvetica', sans-serif;
}

.toggle-description {
  font-size: 14px;
  color: #bdc3c7;
  margin: 0;
  font-style: italic;
}

/* Custom Toggle Switch */
.switch {
  position: relative;
  display: inline-block;
  width: 60px;
  height: 34px;
}

.switch input {
  opacity: 0;
  width: 0;
  height: 0;
}

.slider-switch {
  position: absolute;
  cursor: pointer;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background-color: #7f8c8d;
  transition: .4s;
  border-radius: 34px;
  box-shadow: inset 0 2px 4px rgba(0, 0, 0, 0.2);
}

.slider-switch:before {
  position: absolute;
  content: "";
  height: 26px;
  width: 26px;
  left: 4px;
  bottom: 4px;
  background-color: white;
  transition: .4s;
  border-radius: 50%;
  box-shadow: 0 2px 4px rgba(0, 0, 0, 0.2);
}

input:checked + .slider-switch {
  background-color: #27ae60;
  box-shadow: inset 0 2px 4px rgba(0, 0, 0, 0.2), 0 0 8px rgba(39, 174, 96, 0.3);
}

input:focus + .slider-switch {
  box-shadow: 0 0 0 3px rgba(39, 174, 96, 0.3);
}

input:checked + .slider-switch:before {
  transform: translateX(26px);
}

/* Survey Config Content - Disabled State */
.survey-config-content.disabled {
  opacity: 0.4;
  pointer-events: none;
  transition: opacity 0.3s ease;
  position: relative;
}

.survey-config-content.disabled::after {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background-color: rgba(0, 0, 0, 0.1);
  pointer-events: none;
  z-index: 1;
}

/* Post-Survey Section Styles - Mirror Pre-Survey Styles */
.master-post-survey-toggle {
  margin: 20px 0 30px 0;
  padding: 20px;
  background: #2c3e50;
  border-radius: 8px;
  border: 2px solid #34495e;
  box-shadow: 0 4px 8px rgba(0, 0, 0, 0.1);
}

.master-post-survey-toggle .toggle-container {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 10px;
}

.master-post-survey-toggle .toggle-label {
  font-size: 18px;
  font-weight: 600;
  color: #ecf0f1;
  font-family: 'Helvetica', sans-serif;
}

.master-post-survey-toggle .toggle-description {
  font-size: 14px;
  color: #bdc3c7;
  margin: 0;
  font-style: italic;
}

/* Post-Survey Config Content - Disabled State */
.post-survey-config-content.disabled {
  opacity: 0.4;
  pointer-events: none;
  transition: opacity 0.3s ease;
  position: relative;
}

.post-survey-config-content.disabled::after {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background-color: rgba(0, 0, 0, 0.1);
  pointer-events: none;
  z-index: 1;
}

/* Post-Interaction Survey Form Styles - Identical to Pre-Interaction Survey */
.post-interaction-survey-form {
  position: fixed;
  left: 400px; /* 350px sidebar + 50px spacing */
  top: calc(10vh + 50px); /* header height + 50px spacing */
  right: 50px; /* 50px spacing from right edge */
  width: auto;
  margin: 0;
  padding: 20px;
  border-radius: 10px;
  color: #e9e9e9;
  background-color: #222;
  box-shadow: 0 4px 8px rgba(0, 0, 0, 0.1);
  overflow-y: auto;
  max-height: calc(90vh - 100px); /* Prevent overflow beyond viewport */
}

.post-interaction-survey-form.active {
  display: block;
}

.post-interaction-survey-form .form-subsection {
  background: #222;
  padding: 15px;
  margin: 10px 0;
  border-radius: 5px;
}

.post-interaction-survey-form .post-survey-sections-container {
  border-radius: 5px;
  padding: 15px;
}

.post-interaction-survey-form .add-section-control {
  margin-bottom: 20px;
  padding: 15px;
  background: #222;
  border: 2px solid #28a745;
  border-radius: 5px;
}

.post-interaction-survey-form .section-type-selector {
  display: flex;
  align-items: center;
  gap: 15px;
}

.post-interaction-survey-form .section-type-selector label {
  color: #e0e0e0;
  font-weight: bold;
}

.post-interaction-survey-form .section-type-selector select {
  padding: 8px 12px;
  background: #393939;
  color: white;
  border: 1px solid #555;
  border-radius: 3px;
  min-width: 200px;
}

.post-interaction-survey-form .survey-section-config {
  margin-bottom: 20px;
  border: 3px solid #555;
  border-radius: 5px;
  background: #222;
}

.post-interaction-survey-form .section-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 15px;
  background: #222;
  cursor: pointer;
}

.post-interaction-survey-form .section-header h4 {
  margin: 0;
  color: #e0e0e0;
}

.post-interaction-survey-form .section-controls {
  display: flex;
  align-items: center;
  gap: 10px;
}

.post-interaction-survey-form .section-content {
  padding: 15px;
  display: none;
}

.post-interaction-survey-form .section-content.expanded {
  display: block;
}

.post-interaction-survey-form .field-config {
  display: flex;
  align-items: center;
  gap: 10px;
  margin: 10px 0;
  padding: 8px;
  background: #222;
  border-radius: 3px;
}

.post-interaction-survey-form .field-config select {
  color: white;
  background: #4a5568 !important;
  background-image: url("data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' fill='white' viewBox='0 0 16 16'%3e%3cpath d='m7.247 4.86-4.796 5.481c-.566.647-.106 1.659.753 1.659h9.592a1 1 0 0 0 .753-1.659l-4.796-5.48a1 1 0 0 0-1.506 0z'/%3e%3c/svg%3e") !important;
  background-repeat: no-repeat !important;
  background-position: right 8px center !important;
  background-size: 12px !important;
  padding: 8px 30px 8px 12px !important;
  border: 1px solid #555 !important;
  border-radius: 3px !important;
  min-width: 150px !important;
  appearance: none !important;
}

.post-interaction-survey-form .demographics-fields, 
.post-interaction-survey-form .likert-items-container, 
.post-interaction-survey-form .freetext-questions {
  margin-top: 15px;
}

.post-interaction-survey-form .likert-item, 
.post-interaction-survey-form .freetext-question {
  display: flex;
  align-items: center;
  gap: 10px;
  margin: 10px 0;
  padding: 10px;
  background: #222;
  border-radius: 3px;
  border: 1px solid #e0e0e0;
}

.post-interaction-survey-form .likert-item input[type="text"], 
.post-interaction-survey-form .freetext-question input[type="text"] {
  flex: 1;
}

.post-interaction-survey-form .btn-small {
  padding: 5px 10px;
  font-size: 12px;
  background: #222;
  color: white;
  border: none;
  border-radius: 3px;
  cursor: pointer;
}

.post-interaction-survey-form .btn-add {
  padding: 8px 15px;
  background: #28a745;
  color: white;
  border: none;
  border-radius: 3px;
  cursor: pointer;
  margin: 10px 0;
}

.post-interaction-survey-form .btn-remove {
  padding: 5px 8px;
  background: #dc3545;
  color: white;
  border: none;
  border-radius: 3px;
  cursor: pointer;
  font-weight: bold;
}

/* Ensure proper button colors in post-interaction survey - identical to pre-interaction */
.post-interaction-survey-form .btn-primary {
  background: #FF8266;
}

.post-interaction-survey-form .btn-primary:hover {
  background: #fd6745;
}

.post-interaction-survey-form .btn-secondary {
  background: #6c757d;
}

.post-interaction-survey-form .btn-secondary:hover {
  background: #545b62;
}

.post-interaction-survey-form .file-upload-section {
  margin: 15px 0;
  padding: 15px;
  background: #222;
  border-radius: 5px;
  border: 2px dashed #ddd;
}

.post-interaction-survey-form .file-status {
  margin-top: 10px;
  padding: 8px;
  border-radius: 3px;
  font-size: 14px;
}

.post-interaction-survey-form .file-status.success {
  background: #d4edda;
  color: #155724;
  border: 1px solid #c3e6cb;
}

.post-interaction-survey-form .file-status.error {
  background: #f8d7da;
  color: #721c24;
  border: 1px solid #f5c6cb;
}

.post-interaction-survey-form .setting-group {
  margin: 15px 0;
  padding: 10px;
  background: #222;
  border-radius: 5px;
}

.post-interaction-survey-form .setting-group label {
  display: block;
  margin-bottom: 5px;
  font-weight: bold;
}

.post-interaction-survey-form .survey-preview {
  margin-top: 30px;
  border-top: 2px solid #007bff;
  padding-top: 20px;
}

.post-interaction-survey-form .preview-container {
  border: 1px solid #ddd;
  border-radius: 5px;
  overflow: hidden;
}

.post-interaction-survey-form .gender-options input {
  width: 100%;
  margin-top: 5px;
}

.post-interaction-survey-form .likert-scale-config {
  margin: 15px 0;
  padding: 10px;
  background: #222;
  border-radius: 5px;
  border: 2px dashed #ddd;
}

.post-interaction-survey-form .likert-scale-config select {
  color: white;
  background: #4a5568 !important;
  background-image: url("data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' fill='white' viewBox='0 0 16 16'%3e%3cpath d='m7.247 4.86-4.796 5.481c-.566.647-.106 1.659.753 1.659h9.592a1 1 0 0 0 .753-1.659l-4.796-5.48a1 1 0 0 0-1.506 0z'/%3e%3c/svg%3e") !important;
  background-repeat: no-repeat !important;
  background-position: right 8px center !important;
  background-size: 12px !important;
  padding: 8px 30px 8px 12px !important;
  border: 1px solid #555 !important;
  border-radius: 3px !important;
  min-width: 200px !important;
  appearance: none !important;
}

/* Override for post-interaction survey buttons to make them narrower like pre-interaction */
.post-interaction-survey-form .form-actions button {
  min-width: 180px;
  padding: 12px 20px;
  font-size: 14px;
}

/* ========================================
   POST-SURVEY COMPATIBILITY STYLES
   Make post-survey elements look exactly like pre-survey
   ======================================== */

/* Make survey-popup (post-survey) look like survey-consent-popup (pre-survey) */
.survey-popup {
  position: fixed; 
  top: 0; 
  left: 0; 
  width: 100vw; 
  height: 100vh;
  background: rgba(0,0,0,0.7); 
  display: flex; 
  align-items: center; 
  justify-content: center;
  z-index: 9999;
  backdrop-filter: blur(5px);
}

/* Make survey-consent-button (post-survey) look like survey-btn (pre-survey) */
.survey-consent-button {
  padding: 15px 30px;
  border: none;
  border-radius: 8px;
  font-size: 16px;
  font-weight: 600;
  font-family: 'Helvetica', sans-serif;
  cursor: pointer;
  transition: all 0.3s ease;
  margin: 10px;
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

.survey-consent-button.agree {
  background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
  color: white;
  box-shadow: 0 4px 15px rgba(102, 126, 234, 0.3);
}

.survey-consent-button.agree:hover {
  transform: translateY(-2px);
  box-shadow: 0 6px 20px rgba(102, 126, 234, 0.4);
}

.survey-consent-button.quit {
  background: linear-gradient(135deg, #e74c3c 0%, #c0392b 100%);
  color: white;
  box-shadow: 0 4px 15px rgba(231, 76, 60, 0.3);
}

.survey-consent-button.quit:hover {
  transform: translateY(-2px);
  box-shadow: 0 6px 20px rgba(231, 76, 60, 0.4);
}

/* Make consent-buttons and quit-confirm-buttons have same layout */
.consent-buttons, .quit-confirm-buttons {
  text-align: center;
  margin-top: 30px;
}

/* Make survey-main hidden by default and styled properly */
.survey-main {
  display: block;
}

.survey-main.survey-hidden {
  display: none;
}

/* Style survey-navigation (post-survey) like submit-section (pre-survey) */
.survey-navigation {
  text-align: center;
  padding: 40px 0;
  background: linear-gradient(135deg, #2c3e50 0%, #34495e 100%);
  margin: 40px -50px -40px -50px;
  border-radius: 0 0 12px 12px;
  border-top: 3px solid #3498db;
}

/* Make progress-indicator elements properly styled */
.progress-indicator {
  text-align: center;
  margin: 20px 0;
  padding: 15px;
  background: linear-gradient(135deg, #f8f9fa 0%, #e9ecef 100%);
  border-radius: 8px;
  border-left: 4px solid #667eea;
}

.progress-bar {
  width: 100%;
  height: 8px;
  background-color: #e9ecef;
  border-radius: 4px;
  overflow: hidden;
  margin-bottom: 10px;
}

.progress-fill {
  height: 100%;
  background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
  border-radius: 4px;
  transition: width 0.3s ease;
}

#progress-text {
  color: #2c3e50;
  font-size: 14px;
  font-weight: 600;
}

/* Make quit-confirm-content styled properly */
.quit-confirm-content {
  text-align: center;
  padding: 20px;
}

.quit-confirm-content h3 {
  color: #e74c3c;
  font-size: 1.6em;
  margin-bottom: 15px;
  font-weight: 600;
}

.quit-confirm-content p {
  color: #34495e;
  font-size: 1.1em;
  line-height: 1.6;
  margin-bottom: 25px;
}

/* Make completion-content styled properly */
.completion-content {
  text-align: center;
  padding: 20px;
}

.completion-content h3 {
  color: #28a745;
  font-size: 1.8em;
  margin-bottom: 15px;
  font-weight: 600;
}

.completion-content p {
  color: #34495e;
  font-size: 1.1em;
  line-height: 1.6;
  margin-bottom: 25px;
}

/* Style information-content div */
.information-content {
  text-align: left;
  margin: 10px 0;
  padding: 15px;
  background: #f8f9fa;
  border-radius: 8px;
  border-left: 4px solid #667eea;
}

.information-content p {
  color: #34495e;
  font-size: 1.1em;
  line-height: 1.6;
  margin-bottom: 10px;
}

/* Ensure survey-form class is properly styled */
.survey-form {
  background: #ffffff;
  padding: 0;
  margin: 0;
}

/* Make sure all elements use the same background and text colors */
.survey-main .survey-header h1 {
  color: #2c3e50;
  font-size: 2em;
  margin-bottom: 20px;
  font-weight: 600;
  text-align: center;
}

/* Branding Configuration Styles */
.branding-section {
  position: fixed;
  left: 400px; /* 350px sidebar + 50px spacing */
  top: calc(10vh + 50px); /* header height + 50px spacing */
  right: 50px; /* 50px spacing from right edge */
  width: auto;
  margin: 0;
  padding: 20px;
  border-radius: 10px;
  color: #e9e9e9;
  background-color: #222;
  box-shadow: 0 4px 8px rgba(0, 0, 0, 0.1);
  overflow-y: auto;
  max-height: calc(90vh - 100px); /* Prevent overflow beyond viewport */
}

.branding-container {
  background-color: #2a2a2a;
  border-radius: 10px;
  padding: 30px;
  margin-top: 50px;
}

.branding-form {
  color: #ffffff;
}

.branding-form .form-section {
  margin: 30px 0;
  padding: 20px;
  background-color: #2a2a2a;
  border-radius: 8px;
  border-left: 4px solid #FF8266;
}

.branding-form .setting-group {
  margin: 20px 0;
}

.branding-form .setting-group label {
  display: block;
  color: #e6e6e6;
  font-weight: 600;
  margin-bottom: 8px;
  font-size: 14px;
}

.branding-form .setting-group input[type="text"] {
  width: 100%;
  padding: 12px;
  background-color: #333;
  border: 2px solid #555;
  border-radius: 6px;
  color: #fff;
  font-size: 14px;
  transition: border-color 0.3s ease;
}

.branding-form .setting-group input[type="text"]:focus {
  outline: none;
  border-color: #FF8266;
  box-shadow: 0 0 5px rgba(255, 130, 102, 0.3);
}

.branding-form .setting-group small {
  color: #b0b0b0;
  font-size: 12px;
  display: block;
  margin-top: 5px;
}

.current-branding-display {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 20px;
  margin-top: 20px;
}

.current-section {
  background-color: #333;
  padding: 15px;
  border-radius: 6px;
  border-left: 3px solid #FF8266;
}

.current-section h4 {
  color: #FF8266;
  margin: 0 0 15px 0;
  font-size: 16px;
}

.current-values {
  color: #e6e6e6;
}

.current-values div {
  margin-bottom: 8px;
  font-size: 13px;
}

.current-values span {
  color: #b0b0b0;
  font-style: italic;
}

.branding-button {
  background-color: #4CAF50;
  color: white;
  border: none;
  padding: 12px 24px;
  font-size: 16px;
  border-radius: 5px;
  cursor: pointer;
  margin-top: 20px;
  margin-right: 10px;
  transition: background-color 0.3s;
}

.branding-button:hover {
  background-color: #45a049;
}

.branding-button.secondary {
  background-color: #555;
  color: #fff;
}

.branding-button.secondary:hover {
  background-color: #666;
}

/* Post-Chat Popup Section Styles */
.post-chat-popup-section {
  position: fixed;
  left: 400px; /* 350px sidebar + 50px spacing */
  top: calc(10vh + 50px); /* header height + 50px spacing */
  right: 50px; /* 50px spacing from right edge */
  width: auto;
  margin: 0;
  padding: 20px;
  border-radius: 10px;
  color: #e9e9e9;
  background-color: #222;
  box-shadow: 0 4px 8px rgba(0, 0, 0, 0.1);
  overflow-y: auto;
  max-height: calc(90vh - 100px); /* Prevent overflow beyond viewport */
}

.post-chat-popup-container {
  background-color: #2a2a2a;
  border-radius: 10px;
  padding: 30px;
  margin-top: 50px;
}

/* Master Post-Chat Popup Toggle */
.master-popup-toggle {
  margin: 20px 0 30px 0;
  padding: 20px;
  background: #2c3e50;
  border-radius: 8px;
  border: 2px solid #34495e;
  box-shadow: 0 4px 8px rgba(0, 0, 0, 0.1);
}

/* Post-Chat Popup Configuration Content */
.popup-config-content {
  margin-top: 20px;
}

.popup-config-content .form-section {
  margin: 30px 0;
  padding: 20px;
  background-color: #2a2a2a;
  border-radius: 8px;
  border-left: 4px solid #FF8266;
}

.popup-config-content .setting-group {
  margin: 20px 0;
}

.popup-config-content .setting-group label {
  display: block;
  color: #e6e6e6;
  font-weight: 600;
  margin-bottom: 8px;
  font-size: 14px;
}

.popup-config-content .setting-group textarea {
  width: 100%;
  padding: 12px;
  background-color: #333;
  border: 2px solid #555;
  border-radius: 6px;
  color: #fff;
  font-size: 14px;
  font-family: inherit;
  resize: vertical;
  box-sizing: border-box;
  transition: border-color 0.3s ease;
}

.popup-config-content .setting-group textarea:focus {
  outline: none;
  border-color: #FF8266;
  box-shadow: 0 0 5px rgba(255, 130, 102, 0.3);
}

.current-popup-display {
  background-color: #333;
  padding: 15px;
  border-radius: 6px;
  border-left: 3px solid #FF8266;
}

.current-popup-display .current-section {
  background-color: transparent;
  padding: 0;
  border: none;
}

.current-popup-display .current-section h4 {
  color: #FF8266;
  margin: 0 0 15px 0;
  font-size: 16px;
}

.current-popup-display .current-values {
  color: #e6e6e6;
}

.current-popup-display .current-values div {
  margin-bottom: 8px;
}

/* Popup Config Content - Disabled State */
.popup-config-content.disabled {
  opacity: 0.4;
  pointer-events: none;
  transition: opacity 0.3s ease;
  position: relative;
}

.popup-config-content.disabled::after {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background-color: rgba(0, 0, 0, 0.3);
  border-radius: 10px;
  z-index: 1;
}

.form-actions {
  margin-top: 30px;
  padding-top: 20px;
  border-top: 1px solid #444;
}
