/* Options page styles */
body {
  font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
  margin: 0;
  padding: 0;
  background-color: #f5f5f5;
  color: #333;
}

.container {
  max-width: 800px;
  margin: 0 auto;
  padding: 20px;
}

header {
  text-align: center;
  margin-bottom: 30px;
}

h1 {
  font-size: 24px;
  margin: 0 0 10px 0;
  color: #2c3e50;
}

h2 {
  font-size: 18px;
  margin: 15px 0;
  color: #2c3e50;
  border-bottom: 1px solid #eee;
  padding-bottom: 5px;
}

header p {
  color: #7f8c8d;
  margin: 0;
}

.global-settings, .site-settings {
  background-color: #fff;
  border-radius: 5px;
  padding: 20px;
  margin-bottom: 20px;
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.1);
}

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

.toggle-container span {
  margin-left: 10px;
}

.site-card {
  border: 1px solid #eee;
  border-radius: 5px;
  padding: 15px;
  margin-bottom: 15px;
  background-color: #f9f9f9;
}

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

.site-title {
  font-weight: bold;
  font-size: 16px;
}

.site-body {
  margin-top: 15px;
}

.instance-selector {
  margin-top: 10px;
}

.instance-selector select {
  width: 100%;
  padding: 8px;
  border-radius: 4px;
  border: 1px solid #ddd;
  background-color: #fff;
}

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

.actions-top {
  margin-bottom: 20px;
  margin-top: 0;
}

.primary-btn, .secondary-btn {
  padding: 10px 20px;
  border: none;
  border-radius: 4px;
  cursor: pointer;
  font-size: 14px;
  transition: background-color 0.3s;
}

.primary-btn {
  background-color: #3498db;
  color: white;
}

.primary-btn:hover {
  background-color: #2980b9;
}

.secondary-btn {
  background-color: #e74c3c;
  color: white;
}

.secondary-btn:hover {
  background-color: #c0392b;
}

footer {
  text-align: center;
  margin-top: 30px;
  color: #7f8c8d;
  font-size: 12px;
}

footer a {
  color: #3498db;
  text-decoration: none;
}

footer a:hover {
  text-decoration: underline;
}

/* Switch styling */
.switch {
  position: relative;
  display: inline-block;
  width: 40px;
  height: 20px;
}

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

.slider {
  position: absolute;
  cursor: pointer;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background-color: #ccc;
  transition: .4s;
}

.slider:before {
  position: absolute;
  content: "";
  height: 16px;
  width: 16px;
  left: 2px;
  bottom: 2px;
  background-color: white;
  transition: .4s;
}

input:checked + .slider {
  background-color: #2ecc71;
}

input:focus + .slider {
  box-shadow: 0 0 1px #2ecc71;
}

input:checked + .slider:before {
  transform: translateX(10px);
}

.slider.round {
  border-radius: 20px;
}

.slider.round:before {
  border-radius: 50%;
}

/* Custom Instance Styling */
.custom-instance-section {
  margin-top: 15px;
  padding-top: 10px;
  border-top: 1px solid #ecf0f1;
}

.add-custom-btn {
  background-color: #27ae60;
  color: white;
  border: none;
  padding: 8px 12px;
  border-radius: 4px;
  cursor: pointer;
  font-size: 12px;
  transition: background-color 0.3s;
}

.add-custom-btn:hover {
  background-color: #219a52;
}

.custom-input-container {
  display: flex;
  gap: 8px;
  margin-top: 10px;
  align-items: center;
}

.custom-instance-input {
  flex: 1;
  padding: 8px 12px;
  border: 1px solid #bdc3c7;
  border-radius: 4px;
  font-size: 12px;
}

.custom-instance-input:focus {
  outline: none;
  border-color: #3498db;
  box-shadow: 0 0 5px rgba(52, 152, 219, 0.3);
}

.custom-add-btn, .custom-cancel-btn {
  padding: 8px 12px;
  border: none;
  border-radius: 4px;
  cursor: pointer;
  font-size: 12px;
  transition: background-color 0.3s;
}

.custom-add-btn {
  background-color: #3498db;
  color: white;
}

.custom-add-btn:hover {
  background-color: #2980b9;
}

.custom-cancel-btn {
  background-color: #95a5a6;
  color: white;
}

.custom-cancel-btn:hover {
  background-color: #7f8c8d;
}

.custom-instances-list {
  margin-top: 10px;
}

.custom-instances-title {
  font-weight: bold;
  font-size: 12px;
  color: #34495e;
  margin-bottom: 8px;
}

.custom-instance-item {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 6px 10px;
  background-color: #f8f9fa;
  border: 1px solid #e9ecef;
  border-radius: 4px;
  margin-bottom: 4px;
  font-size: 12px;
}

.remove-custom-btn {
  background-color: #e74c3c;
  color: white;
  border: none;
  border-radius: 50%;
  width: 20px;
  height: 20px;
  cursor: pointer;
  font-size: 14px;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: background-color 0.3s;
}

.remove-custom-btn:hover {
  background-color: #c0392b;
}

.custom-option {
  font-style: italic;
  background-color: #f8f9fa;
}
