/* Light and dark mode base */
body {
  font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
}

body.light-mode {
  background-color: #f9f9f9;
  color: #111;
}

body.dark-mode {
  background-color: #1e1e1e;
  color: #eee;
}

/* Main title styling with tech font */
.main-title {
  font-family: 'Orbitron', monospace !important;
  font-weight: 900 !important;
  letter-spacing: 2px !important;
  text-transform: uppercase !important;
  background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  display: flex;
  align-items: center;
  gap: 15px;
  text-shadow: none;
}

.main-title i {
  background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  font-size: 1.2em;
  stroke-width: 2;
}

body.dark-mode .main-title {
  background: linear-gradient(135deg, #4facfe 0%, #00f2fe 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

body.dark-mode .main-title i {
  background: linear-gradient(135deg, #4facfe 0%, #00f2fe 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  stroke-width: 2;
}

/* Responsive title */
@media (max-width: 768px) {
  .main-title {
    font-size: 1.5rem !important;
    letter-spacing: 1px !important;
    gap: 10px;
  }
  
  .main-title i {
    font-size: 1.1em;
  }
}

body.dark-mode .box {
  background-color: #2a2a2a;
  color: #eee;
}

body.dark-mode .input,
body.dark-mode .textarea {
  background-color: #333;
  color: #eee;
  border-color: #555;
}

/* Label and title in dark mode */
body.dark-mode .label,
body.dark-mode .title {
  color: #ffffff;
}

/* YAML preview style */
pre code {
  padding: 1em;
  border-radius: 5px;
  overflow-x: auto;
  font-size: 0.95rem;
}

body.dark-mode .input,
body.dark-mode .button,
body.dark-mode .footer,
body.dark-mode .file-cta,
body.dark-mode .strong {
  background-color: #1e1e1e;
  color: #e0e0e0;
  border-color: #333;
}

/* Floating button group (always visible) */
#floatingButtons {
  position: fixed;
  bottom: 24px;
  right: 24px;
  display: flex;
  flex-direction: column;
  gap: 12px;
  z-index: 100;
}

/* Buttons (dark mode aware) */
#floatingButtons button {
  background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
  color: white;
  border: none;
  border-radius: 50%;
  width: 50px;
  height: 50px;
  font-size: 20px;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all 0.3s ease;
  box-shadow: 0 4px 15px rgba(0,0,0,0.2);
}

#floatingButtons button:hover {
  transform: translateY(-2px);
  box-shadow: 0 6px 20px rgba(0,0,0,0.3);
}

body.dark-mode #floatingButtons button {
  background: linear-gradient(135deg, #4facfe 0%, #00f2fe 100%);
}

#floatingButtons button i {
  font-size: 20px;
  width: 20px;
  height: 20px;
}

/* Remove scroll-triggered show/hide */
#floatingButtons button.active {
  display: flex;
}

.footer-icons a {
  margin: 0 10px;
  color: #000;
  text-decoration: none;
  transition: all 0.3s ease;
}

body.dark-mode .footer-icons a {
  color: #fff;
}

.footer-icons a:hover {
  transform: translateY(-2px);
}

#github:hover {
  color: #333 !important;
  filter: drop-shadow(0 2px 4px rgba(51, 51, 51, 0.3));
}

#linkedin:hover {
  color: #0077b5 !important;
  filter: drop-shadow(0 2px 4px rgba(0, 119, 181, 0.3));
}

/* Tabler Icons proper styling */
.ti {
  display: inline-block;
  width: 1em;
  height: 1em;
  stroke-width: 1.5;
  vertical-align: -0.125em;
}

/* Icon specific sizing */
.file-icon .ti,
.icon .ti {
  font-size: inherit;
}

/* Footer social icons */
.footer-icons .ti {
  font-size: 2rem !important;
}

/* Improved file upload styling */
.file.is-boxed {
  display: flex;
  justify-content: center;
}

.file.is-boxed .file-cta {
  transition: all 0.3s ease;
  background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
  color: white;
  border: none;
  border-radius: 8px;
  padding: 0.75rem 1.5rem;
  font-weight: 500;
  box-shadow: 0 2px 8px rgba(102, 126, 234, 0.2);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: auto;
}

.file.is-boxed:hover .file-cta {
  transform: translateY(-2px);
  box-shadow: 0 4px 12px rgba(102, 126, 234, 0.3);
  background: linear-gradient(135deg, #5a6fd8 0%, #6a5acd 100%);
}

.file.is-boxed .file-icon {
  margin-right: 0.5rem;
  font-size: 1.2rem;
}

.file.is-boxed .file-label {
  font-size: 0.95rem;
  letter-spacing: 0.3px;
}

body.dark-mode .file.is-boxed .file-cta {
  background: linear-gradient(135deg, #4facfe 0%, #00f2fe 100%);
  box-shadow: 0 2px 8px rgba(79, 172, 254, 0.2);
}

body.dark-mode .file.is-boxed:hover .file-cta {
  background: linear-gradient(135deg, #3d8bfe 0%, #00d4ff 100%);
  box-shadow: 0 4px 12px rgba(79, 172, 254, 0.3);
}

/* Improved button styling */
.button {
  transition: all 0.3s ease;
}

.button:hover {
  transform: translateY(-1px);
  box-shadow: 0 2px 4px rgba(0,0,0,0.1);
}

/* YAML paste area styling */
#yamlTextarea {
  background-color: #f8f9fa;
  border: 2px dashed #dee2e6;
  border-radius: 8px;
  transition: all 0.3s ease;
  resize: vertical;
  min-height: 150px;
}

#yamlTextarea:focus {
  border-color: #667eea;
  border-style: solid;
  box-shadow: 0 0 0 0.125rem rgba(102, 126, 234, 0.25);
  background-color: #ffffff;
}

#yamlTextarea::placeholder {
  color: #6c757d;
  font-style: italic;
}

body.dark-mode #yamlTextarea {
  background-color: #2a2a2a;
  border-color: #444;
  color: #eee;
}

body.dark-mode #yamlTextarea:focus {
  background-color: #333;
  border-color: #4facfe;
  box-shadow: 0 0 0 0.125rem rgba(79, 172, 254, 0.25);
}

body.dark-mode #yamlTextarea::placeholder {
  color: #999;
}

/* OR divider styling */
.tag.is-light.is-medium {
  background: linear-gradient(135deg, #f1f3f4 0%, #e8eaed 100%);
  color: #5f6368;
  font-weight: 600;
  padding: 8px 16px;
  border-radius: 20px;
}

body.dark-mode .tag.is-light.is-medium {
  background: linear-gradient(135deg, #3a3a3a 0%, #2a2a2a 100%);
  color: #ccc;
}

/* Footer version styling */
.footer-version .tag {
  font-size: 0.85rem;
  border-radius: 8px;
  transition: all 0.3s ease;
}

.footer-version .tag:hover {
  transform: translateY(-1px);
  box-shadow: 0 2px 8px rgba(0,0,0,0.1);
}

body.dark-mode .footer-version .tag.is-info.is-light {
  background-color: rgba(79, 172, 254, 0.1);
  color: #4facfe;
}

body.dark-mode .footer-version .tag.is-link.is-light {
  background-color: rgba(50, 115, 220, 0.1);
  color: #3273dc;
}

body.dark-mode .footer-version .tag.is-warning.is-light {
  background-color: rgba(255, 193, 7, 0.1);
  color: #ffc107;
}

/* Field spacing */
.field + .field {
  margin-top: 1rem;
}

/* Responsive improvements */
@media (max-width: 768px) {
  #floatingButtons {
    bottom: 16px;
    right: 16px;
  }
  
  #floatingButtons button {
    width: 45px;
    height: 45px;
    font-size: 18px;
  }
  
  #floatingButtons button i {
    font-size: 18px;
  }
  
  .container {
    padding: 0 1rem;
  }
}

/* Notification system improvements */
.notification-toast {
  position: fixed;
  top: 20px;
  right: 20px;
  z-index: 1000;
  min-width: 350px;
  max-width: 450px;
  border-radius: 12px;
  box-shadow: 0 10px 25px rgba(0,0,0,0.1), 0 5px 15px rgba(0,0,0,0.05);
  backdrop-filter: blur(10px);
  border: 1px solid rgba(255,255,255,0.1);
  animation: slideInRight 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

.notification-toast.is-success {
  background: linear-gradient(135deg, #48bb78 0%, #38a169 100%);
  color: white;
}

.notification-toast.is-info {
  background: linear-gradient(135deg, #4299e1 0%, #3182ce 100%);
  color: white;
}

.notification-toast.is-warning {
  background: linear-gradient(135deg, #ed8936 0%, #dd6b20 100%);
  color: white;
}

.notification-toast.is-danger {
  background: linear-gradient(135deg, #f56565 0%, #e53e3e 100%);
  color: white;
}

/* Dark mode notification adjustments */
body.dark-mode .notification-toast {
  border: 1px solid rgba(255,255,255,0.2);
  box-shadow: 0 10px 25px rgba(0,0,0,0.3), 0 5px 15px rgba(0,0,0,0.1);
}

/* Notification animations */
@keyframes slideInRight {
  from { 
    transform: translateX(100%); 
    opacity: 0; 
  }
  to { 
    transform: translateX(0); 
    opacity: 1; 
  }
}

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

@keyframes fadeInUp {
  from {
    transform: translateY(20px);
    opacity: 0;
  }
  to {
    transform: translateY(0);
    opacity: 1;
  }
}

/* Progress bar for notifications */
.notification-progress {
  position: absolute;
  bottom: 0;
  left: 0;
  height: 3px;
  background: rgba(255,255,255,0.3);
  border-radius: 0 0 12px 12px;
  animation: progressBar 3s linear;
}

@keyframes progressBar {
  from { width: 100%; }
  to { width: 0%; }
}

/* Notification icon styling */
.notification-toast .ti {
  font-size: 1.25rem;
  margin-right: 8px;
  vertical-align: middle;
}

/* Responsive notifications */
@media (max-width: 768px) {
  .notification-toast {
    top: 10px;
    right: 10px;
    left: 10px;
    min-width: auto;
    max-width: none;
  }
}

/* Loading state */
.is-loading::after {
  animation: spinAround 500ms infinite linear;
  border: 2px solid #dbdbdb;
  border-radius: 50%;
  border-right-color: transparent;
  border-top-color: transparent;
  content: "";
  display: block;
  height: 1em;
  position: relative;
  width: 1em;
}

@keyframes spinAround {
  from { transform: rotate(0deg); }
  to { transform: rotate(359deg); }
}
