/* Dobby Writer Options Page Styles */
* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

body {
  font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen, Ubuntu, Cantarell, sans-serif;
  background: linear-gradient(135deg, #FFFAF4 0%, #FFF4E8 100%);
  color: #000000;
  line-height: 1.6;
  min-height: 100vh;
}

.options-container {
  max-width: 1000px;
  margin: 0 auto;
  background: #FFFAF4;
  min-height: 100vh;
  box-shadow: 0 0 50px rgba(0, 0, 0, 0.1);
}

/* Header */
.options-header {
  background: linear-gradient(135deg, #EF4D32 0%, #fed18e 100%);
  color: #FFFAF4;
  padding: 30px;
  position: relative;
  overflow: hidden;
}

.options-header::before {
  content: '';
  position: absolute;
  top: -50%;
  right: -50%;
  width: 200%;
  height: 200%;
  background: radial-gradient(circle, rgba(255,255,255,0.1) 0%, transparent 70%);
  animation: headerShimmer 4s ease-in-out infinite;
}

@keyframes headerShimmer {
  0%, 100% { transform: translateX(-100%) translateY(-100%) rotate(0deg); }
  50% { transform: translateX(0%) translateY(0%) rotate(180deg); }
}

.header-content {
  display: flex;
  justify-content: space-between;
  align-items: center;
  position: relative;
  z-index: 1;
}

.logo-section {
  display: flex;
  align-items: center;
  gap: 20px;
}

.dobby-logo {
  width: 60px;
  height: 60px;
  border-radius: 12px;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.2);
  animation: logoFloat 3s ease-in-out infinite;
}

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

.header-text h1 {
  font-size: 32px;
  font-weight: 700;
  margin-bottom: 5px;
  text-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
}

.header-text p {
  font-size: 16px;
  opacity: 0.9;
  font-weight: 300;
}

.version-badge {
  background: rgba(255, 255, 255, 0.2);
  padding: 6px 12px;
  border-radius: 20px;
  font-size: 12px;
  font-weight: 600;
  backdrop-filter: blur(10px);
}

/* Main Content */
.options-main {
  padding: 40px;
  background: #FFFAF4;
}

/* Settings Sections */
.settings-section {
  background: #FFF4E8;
  border-radius: 16px;
  padding: 30px;
  margin-bottom: 30px;
  border: 1px solid #ECECEC;
  position: relative;
  overflow: hidden;
}

.settings-section::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  width: 4px;
  height: 100%;
  background: linear-gradient(135deg, #EF4D32 0%, #fed18e 100%);
}

.section-header {
  margin-bottom: 25px;
}

.section-header h2 {
  font-size: 22px;
  font-weight: 700;
  color: #000000;
  margin-bottom: 8px;
}

.section-header p {
  color: #9B9B9B;
  font-size: 14px;
}

/* Setting Groups */
.setting-group {
  display: flex;
  flex-direction: column;
  gap: 20px;
}

.setting-item {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 20px;
  background: #FFFAF4;
  border-radius: 12px;
  border: 1px solid #ECECEC;
  transition: all 0.2s ease;
}

.setting-item:hover {
  transform: translateY(-1px);
  box-shadow: 0 4px 12px rgba(239, 77, 50, 0.1);
}

.setting-label {
  flex: 1;
}

.label-text {
  display: block;
  font-weight: 600;
  color: #000000;
  margin-bottom: 4px;
}

.label-description {
  font-size: 13px;
  color: #9B9B9B;
}

/* Form Controls */
.setting-select,
.setting-input {
  min-width: 200px;
  padding: 10px 12px;
  border: 1px solid #ECECEC;
  border-radius: 8px;
  background: #FFFAF4;
  color: #000000;
  font-size: 14px;
  transition: border-color 0.2s ease;
}

.setting-select:focus,
.setting-input:focus {
  outline: none;
  border-color: #EF4D32;
  box-shadow: 0 0 0 3px rgba(239, 77, 50, 0.1);
}

.setting-input::placeholder {
  color: #9B9B9B;
}

/* Toggle Switch */
.toggle-switch {
  position: relative;
  display: inline-block;
  width: 50px;
  height: 26px;
}

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

.toggle-slider {
  position: absolute;
  cursor: pointer;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background-color: #ECECEC;
  transition: 0.3s;
  border-radius: 26px;
}

.toggle-slider:before {
  position: absolute;
  content: "";
  height: 20px;
  width: 20px;
  left: 3px;
  bottom: 3px;
  background-color: #FFFAF4;
  transition: 0.3s;
  border-radius: 50%;
  box-shadow: 0 2px 4px rgba(0,0,0,0.2);
}

input:checked + .toggle-slider {
  background-color: #EF4D32;
}

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

/* Input Group */
.input-group {
  display: flex;
  align-items: center;
  gap: 8px;
}

.toggle-btn {
  background: #EF4D32;
  color: #FFFAF4;
  border: none;
  padding: 8px 12px;
  border-radius: 6px;
  cursor: pointer;
  font-size: 12px;
  transition: background 0.2s ease;
}

.toggle-btn:hover {
  background: #fed18e;
  color: #000000;
}

/* Status Indicators */
.status-indicator {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 10px 15px;
  background: #FFF4E8;
  border-radius: 8px;
  border: 1px solid #ECECEC;
}

.status-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: #fed18e;
  animation: pulse 2s infinite;
}

.status-dot.success {
  background: #fed18e;
}

.status-dot.error {
  background: #EF4D32;
}

@keyframes pulse {
  0% {
    box-shadow: 0 0 0 0 rgba(254, 209, 142, 0.7);
  }
  70% {
    box-shadow: 0 0 0 10px rgba(254, 209, 142, 0);
  }
  100% {
    box-shadow: 0 0 0 0 rgba(254, 209, 142, 0);
  }
}

.status-text {
  font-size: 13px;
  color: #9B9B9B;
  font-weight: 500;
}

/* Buttons */
.test-btn,
.add-btn,
.primary-btn,
.secondary-btn,
.danger-btn {
  padding: 10px 20px;
  border-radius: 8px;
  font-size: 14px;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.2s ease;
  border: none;
}

.test-btn,
.primary-btn {
  background: linear-gradient(135deg, #EF4D32 0%, #fed18e 100%);
  color: #FFFAF4;
}

.test-btn:hover,
.primary-btn:hover {
  transform: translateY(-1px);
  box-shadow: 0 4px 12px rgba(239, 77, 50, 0.3);
}

.add-btn,
.secondary-btn {
  background: #FFF4E8;
  color: #000000;
  border: 1px solid #ECECEC;
}

.add-btn:hover,
.secondary-btn:hover {
  background: #ECECEC;
  transform: translateY(-1px);
}

.danger-btn {
  background: #EF4D32;
  color: #FFFAF4;
}

.danger-btn:hover {
  background: #fed18e;
  color: #000000;
  transform: translateY(-1px);
}

/* Statistics */
.stats-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  gap: 20px;
  margin-bottom: 25px;
}

.stat-card {
  background: #FFFAF4;
  padding: 25px 20px;
  border-radius: 12px;
  text-align: center;
  border: 1px solid #ECECEC;
  transition: transform 0.2s ease;
}

.stat-card:hover {
  transform: translateY(-2px);
  box-shadow: 0 4px 12px rgba(239, 77, 50, 0.1);
}

.stat-number {
  font-size: 32px;
  font-weight: 700;
  color: #EF4D32;
  margin-bottom: 8px;
  display: block;
}

.stat-label {
  font-size: 14px;
  color: #9B9B9B;
  font-weight: 500;
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

.stats-actions {
  display: flex;
  gap: 15px;
  justify-content: center;
}

/* Site Management */
.disabled-sites-container {
  width: 100%;
  max-width: 400px;
}

.disabled-sites-list {
  max-height: 200px;
  overflow-y: auto;
  margin-bottom: 15px;
  border: 1px solid #ECECEC;
  border-radius: 8px;
  background: #FFFAF4;
}

.site-item {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 12px 15px;
  border-bottom: 1px solid #ECECEC;
}

.site-item:last-child {
  border-bottom: none;
}

.site-url {
  font-size: 13px;
  color: #000000;
  font-weight: 500;
}

.remove-site-btn {
  background: #EF4D32;
  color: #FFFAF4;
  border: none;
  padding: 4px 8px;
  border-radius: 4px;
  font-size: 11px;
  cursor: pointer;
  transition: background 0.2s ease;
}

.remove-site-btn:hover {
  background: #fed18e;
  color: #000000;
}

.add-site-form {
  display: flex;
  gap: 10px;
}

.add-site-form .setting-input {
  flex: 1;
  min-width: 0;
}

/* Footer */
.options-footer {
  background: #FFF4E8;
  padding: 30px 40px;
  border-top: 1px solid #ECECEC;
}

.footer-content {
  display: flex;
  justify-content: space-between;
  align-items: center;
  max-width: 920px;
  margin: 0 auto;
}

.footer-actions {
  display: flex;
  gap: 15px;
}

.footer-info {
  text-align: center;
}

.footer-info p {
  color: #9B9B9B;
  font-size: 14px;
  margin-bottom: 10px;
}

.footer-links {
  display: flex;
  gap: 20px;
  justify-content: center;
}

.footer-links a {
  color: #EF4D32;
  text-decoration: none;
  font-size: 13px;
  font-weight: 500;
  transition: color 0.2s ease;
}

.footer-links a:hover {
  color: #fed18e;
}

/* Toast Notifications */
.toast-container {
  position: fixed;
  top: 20px;
  right: 20px;
  z-index: 10000;
}

.toast {
  background: #000000;
  color: #FFFAF4;
  padding: 12px 20px;
  border-radius: 8px;
  margin-bottom: 10px;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.3);
  animation: toastSlideIn 0.3s ease;
  max-width: 300px;
}

.toast.success {
  background: #fed18e;
  color: #000000;
}

.toast.error {
  background: #EF4D32;
  color: #FFFAF4;
}

@keyframes toastSlideIn {
  from {
    opacity: 0;
    transform: translateX(100%);
  }
  to {
    opacity: 1;
    transform: translateX(0);
  }
}

/* Responsive Design */
@media (max-width: 768px) {
  .options-container {
    margin: 0;
    min-height: 100vh;
  }
  
  .options-header,
  .options-main,
  .options-footer {
    padding: 20px;
  }
  
  .setting-item {
    flex-direction: column;
    align-items: flex-start;
    gap: 15px;
  }
  
  .setting-select,
  .setting-input {
    min-width: 100%;
  }
  
  .stats-grid {
    grid-template-columns: 1fr;
  }
  
  .footer-content {
    flex-direction: column;
    gap: 20px;
  }
}

