/* =========================
   MODERNE FORMULAR-STYLES
   ========================= */

/* CSS Custom Properties für konsistente Farben */
:root {
  --form-primary: #007bff;
  --form-success: #28a745;
  --form-warning: #ffc107;
  --form-info: #17a2b8;
  --form-secondary: #6c757d;
  --form-light: #f8f9fa;
  --form-white: #ffffff;
  --form-border: #ddd;
  --form-text: #333;
  --form-text-muted: #666;
  --form-shadow: rgba(0, 0, 0, 0.1);
  --form-radius: 8px;
  --form-transition: all 0.3s ease;
}

/* =========================
   FORMULAR CONTAINER
   ========================= */

.form-intro {
  margin-bottom: 2rem;
}

.form-intro img {
  display: block;
  margin: 0 auto 1.5rem;
  max-height: 150px;
  width: 200px;
  height: auto;
}

.benefits-box,
.form-welcome-box {
  text-align: center;
  margin-bottom: 2rem;
  padding: 1.5rem;
  background: var(--form-light);
  border-radius: var(--form-radius);
  border-left: 4px solid var(--form-primary);
}

.benefits-box h3,
.form-welcome-box h3 {
  margin-bottom: 1rem;
  color: var(--form-primary);
}

.benefits-box p,
.form-welcome-box p {
  margin-bottom: 0;
  color: var(--form-text-muted);
  line-height: 1.6;
}

.benefits-layout {
  display: flex;
  flex-wrap: wrap;
  gap: 1rem;
  margin-top: 1rem;
}

.benefits-column {
  flex: 1;
  min-width: 280px;
}

/* =========================
   FORMULAR ELEMENTE
   ========================= */

.modern-form form {
  max-width: 800px;
  margin: 0 auto;
}

.modern-form h2 {
  text-align: center;
  margin-bottom: 2rem;
  color: var(--form-text);
  font-size: 2rem;
}

.form-row {
  display: flex;
  flex-wrap: wrap;
  gap: 1rem;
  margin-bottom: 1.5rem;
}

.form-group {
  flex: 1;
  min-width: 250px;
}

.form-group-half {
  flex: 1;
  min-width: 250px;
}

.form-group-full {
  width: 100%;
}

.modern-form label {
  display: block;
  font-weight: bold;
  color: var(--form-text);
  margin-bottom: 0.5rem;
}

.modern-form input,
.modern-form textarea,
.modern-form select {
  width: 100%;
  padding: 0.75rem;
  border: 1px solid var(--form-border);
  border-radius: var(--form-radius);
  font-size: 1rem;
  transition: var(--form-transition);
  box-sizing: border-box;
}

.modern-form input:focus,
.modern-form textarea:focus,
.modern-form select:focus {
  outline: none;
  border-color: var(--form-primary);
  box-shadow: 0 0 0 3px rgba(0, 123, 255, 0.1);
}

.modern-form input::placeholder,
.modern-form textarea::placeholder {
  color: #999;
}

/* =========================
   BUTTONS
   ========================= */

.modern-form button,
.form-btn {
  padding: 0.75rem 1.5rem;
  border: none;
  border-radius: var(--form-radius);
  font-size: 1rem;
  font-weight: 500;
  cursor: pointer;
  transition: var(--form-transition);
  text-decoration: none;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 150px;
}

.modern-form button[type="submit"],
.form-btn-primary {
  background: var(--form-primary);
  color: white;
}

.modern-form button[type="submit"]:hover,
.form-btn-primary:hover {
  background: #0056b3;
  transform: translateY(-1px);
}

.form-btn-success {
  background: var(--form-success);
  color: white;
}

.form-btn-success:hover {
  background: #218838;
}

.form-btn-secondary {
  background: var(--form-secondary);
  color: white;
}

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

.form-btn-group {
  display: flex;
  flex-wrap: wrap;
  gap: 1rem;
  justify-content: center;
  margin: 1.5rem 0;
}

/* =========================
   SOCIAL LOGIN
   ========================= */

.social-login-section {
  margin: 2rem 0;
  text-align: center;
}

.social-divider {
  display: flex;
  align-items: center;
  margin-bottom: 1rem;
}

.social-divider-line {
  flex: 1;
  height: 1px;
  background: var(--form-border);
}

.social-divider-text {
  padding: 0 1rem;
  color: var(--form-text-muted);
  font-size: 0.9rem;
}

.social-buttons {
  display: flex;
  flex-wrap: wrap;
  gap: 1rem;
  justify-content: center;
}

.social-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0.75rem 1.5rem;
  border-radius: var(--form-radius);
  text-decoration: none;
  color: white;
  font-weight: 500;
  transition: var(--form-transition);
  border: none;
  min-width: 200px;
}

.social-btn-google {
  background-color: #DB4437;
}

.social-btn-google:hover {
  opacity: 0.9;
}

.social-btn-facebook {
  background-color: #4267B2;
}

.social-btn-facebook:hover {
  opacity: 0.9;
}

.social-btn svg {
  margin-right: 8px;
}

/* =========================
   NAVIGATION LINKS
   ========================= */

.form-navigation {
  text-align: center;
  margin-top: 2rem;
  padding-top: 1.5rem;
  border-top: 1px solid #eee;
}

.form-navigation p {
  margin-bottom: 0.5rem;
}

.form-navigation a {
  color: var(--form-primary);
  text-decoration: none;
  font-weight: 500;
}

.form-navigation a:hover {
  text-decoration: underline;
}

/* =========================
   MULTI-STEP FORMS
   ========================= */

.multi-step-form .step {
  display: none;
}

.multi-step-form .step.active {
  display: block;
}

.step-header {
  color: var(--form-primary);
  border-bottom: 2px solid var(--form-primary);
  padding-bottom: 0.5rem;
  margin-bottom: 1.5rem;
}

.step-navigation {
  display: flex;
  justify-content: space-between;
  gap: 1rem;
  margin-top: 2rem;
}

.bot-check {
  margin-top: 1.5rem;
  padding: 1rem;
  background: var(--form-light);
  border-radius: var(--form-radius);
}

.bot-check input {
  max-width: 100px;
}

/* =========================
   CHECKBOX STYLING
   ========================= */

.checkbox-group {
  margin: 1.5rem 0;
}

.checkbox-label {
  display: flex;
  align-items: flex-start;
  gap: 0.75rem;
  cursor: pointer;
}

.checkbox-label input[type="checkbox"] {
  margin-top: 0.25rem;
  width: auto;
}

/* =========================
   PROFILE COMPONENTS
   ========================= */

.profile-container {
  max-width: 1000px;
  margin: 0 auto;
  padding: 2rem;
}

.profile-container h2 {
  text-align: center;
  margin-bottom: 2rem;
  color: var(--form-text);
}

/* Profile Tabs - ORIGINAL KLASSENNAMEN für JavaScript-Kompatibilität */
.profile-container .tabs {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
  margin-bottom: 2rem;
  border-bottom: 2px solid #eee;
  padding-bottom: 1rem;
}

.profile-container .tablink {
  flex: 1;
  min-width: 150px;
  padding: 0.75rem 1rem;
  border: none;
  border-radius: var(--form-radius);
  cursor: pointer;
  font-weight: 500;
  transition: var(--form-transition);
  background: white;
  color: var(--form-text-muted);
  border: 1px solid var(--form-border);
}

.profile-container .tablink.active {
  background: var(--form-primary);
  color: white;
  border: 1px solid var(--form-primary);
}

.profile-container .tablink:not(.active):hover {
  background: var(--form-light);
}

/* Profile Content - ORIGINAL KLASSENNAMEN */
.profile-container .tabcontent {
  display: none;
}

.profile-container .tabcontent[style*="display: block"] {
  display: block !important;
}

.profile-section-header {
  color: var(--form-primary);
  border-bottom: 2px solid var(--form-primary);
  padding-bottom: 0.5rem;
  margin-bottom: 1.5rem;
}

.profile-fields {
  display: flex;
  flex-wrap: wrap;
  gap: 1rem;
  margin-bottom: 1.5rem;
}

.profile-field {
  flex: 1;
  min-width: 250px;
  padding: 1rem;
  background: var(--form-light);
  border-radius: var(--form-radius);
  border-left: 4px solid var(--form-primary);
}

.profile-field.address {
  border-left-color: var(--form-success);
}

.profile-field.contact {
  border-left-color: var(--form-warning);
}

.profile-field.full-width {
  width: 100%;
  flex: none;
}

.profile-field-label {
  display: block;
  font-weight: bold;
  color: var(--form-text);
  margin-bottom: 0.5rem;
}

.profile-field-value {
  display: block;
  padding: 0.5rem;
  background: white;
  border-radius: 4px;
  min-height: 1.2rem;
  border: 1px solid var(--form-border);
}

/* Profile Actions */
.profile-actions {
  margin-top: 2rem;
  padding: 1.5rem;
  background: var(--form-light);
  border-radius: var(--form-radius);
  border-top: 3px solid var(--form-primary);
}

.profile-actions h4 {
  margin-bottom: 1rem;
  color: var(--form-primary);
}

.profile-actions .form-btn-group {
  justify-content: center;
}

/* Styling für dynamisch eingefügte Profile-Action-Buttons */
.profile-actions button {
  padding: 0.75rem 1.5rem;
  border: none;
  border-radius: var(--form-radius);
  font-size: 1rem;
  font-weight: 500;
  cursor: pointer;
  transition: var(--form-transition);
  text-decoration: none;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 150px;
  margin: 0.25rem;
}

/* Standard Profile-Button (Bearbeiten) */
.profile-actions button:not([style*="background"]) {
  background: var(--form-primary);
  color: white;
}

.profile-actions button:not([style*="background"]):hover {
  background: #0056b3;
  transform: translateY(-1px);
}

/* Passwort Reset Button (wird oft gelb/orange gestylt) */
.profile-actions button[style*="orange"],
.profile-actions button[style*="#ff8c00"],
.profile-actions button[style*="background-color: orange"] {
  background: var(--form-warning) !important;
  color: #333 !important;
}

.profile-actions button[style*="orange"]:hover,
.profile-actions button[style*="#ff8c00"]:hover,
.profile-actions button[style*="background-color: orange"]:hover {
  background: #e0a800 !important;
  transform: translateY(-1px);
}

/* Delete Button (wird oft rot gestylt) */
.profile-actions button[style*="red"],
.profile-actions button[style*="#dc3545"],
.profile-actions button[style*="background-color: red"] {
  background: #dc3545 !important;
  color: white !important;
}

.profile-actions button[style*="red"]:hover,
.profile-actions button[style*="#dc3545"]:hover,
.profile-actions button[style*="background-color: red"]:hover {
  background: #c82333 !important;
  transform: translateY(-1px);
}

/* Fallback für alle Buttons im Profile-Actions Container */
#profileActions button {
  padding: 0.75rem 1.5rem;
  border: none;
  border-radius: var(--form-radius);
  font-size: 1rem;
  font-weight: 500;
  cursor: pointer;
  transition: var(--form-transition);
  min-width: 150px;
  margin: 0.25rem;
}

#profileActions button:not([style]) {
  background: var(--form-primary);
  color: white;
}

#profileActions button:not([style]):hover {
  background: #0056b3;
  transform: translateY(-1px);
}

/* Profile Info Boxes */
.profile-info-box {
  margin-top: 2rem;
  padding: 1rem;
  border-radius: var(--form-radius);
  border-left: 4px solid var(--form-info);
}

.profile-info-box.communication {
  background: #e8f4fd;
}

.profile-info-box.help {
  background: #e8f4fd;
}

.profile-info-box h4 {
  margin-bottom: 1rem;
  color: var(--form-info);
}

.profile-info-box p {
  margin-bottom: 0.5rem;
  color: var(--form-text-muted);
}

.profile-info-box p:last-child {
  margin-bottom: 0;
}

/* =========================
   MODAL STYLING
   ========================= */

.form-modal {
  display: none;
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: rgba(0, 0, 0, 0.7);
  z-index: 1000;
  align-items: center;
  justify-content: center;
}

.form-modal.show {
  display: flex;
}

.form-modal-content {
  background: white;
  padding: 2rem;
  max-width: 400px;
  margin: auto;
  border-radius: 10px;
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.3);
}

.form-modal h3 {
  margin-bottom: 1.5rem;
  text-align: center;
}

/* =========================
   RESPONSIVE DESIGN
   ========================= */

@media (max-width: 768px) {
  .profile-container {
    padding: 1rem;
  }
  
  .form-row {
    flex-direction: column;
  }
  
  .form-group,
  .form-group-half {
    min-width: 100%;
  }
  
  .benefits-layout {
    flex-direction: column;
  }
  
  .benefits-column {
    min-width: 100%;
  }
  
  .profile-tabs {
    flex-direction: column;
  }
  
  .profile-tab {
    min-width: 100%;
  }
  
  .profile-fields {
    flex-direction: column;
  }
  
  .profile-field {
    min-width: 100%;
  }
  
  .social-buttons {
    flex-direction: column;
    align-items: center;
  }
  
  .social-btn {
    min-width: 250px;
  }
  
  .step-navigation {
    flex-direction: column;
  }
  
  .form-btn-group {
    flex-direction: column;
    align-items: center;
  }
  
  .modern-form button,
  .form-btn {
    min-width: 200px;
  }
}

@media (max-width: 480px) {
  .profile-container {
    padding: 0.5rem;
  }
  
  .modern-form h2 {
    font-size: 1.5rem;
  }
  
  .form-intro img {
    width: 150px;
    max-height: 120px;
  }
  
  .benefits-box,
  .form-welcome-box {
    padding: 1rem;
  }
  
  .social-btn {
    min-width: 100%;
  }
}

/* =========================
   UTILITY CLASSES
   ========================= */

.text-center { text-align: center; }
.text-left { text-align: left; }
.text-right { text-align: right; }

.mb-1 { margin-bottom: 0.5rem; }
.mb-2 { margin-bottom: 1rem; }
.mb-3 { margin-bottom: 1.5rem; }
.mb-4 { margin-bottom: 2rem; }

.mt-1 { margin-top: 0.5rem; }
.mt-2 { margin-top: 1rem; }
.mt-3 { margin-top: 1.5rem; }
.mt-4 { margin-top: 2rem; }

.p-1 { padding: 0.5rem; }
.p-2 { padding: 1rem; }
.p-3 { padding: 1.5rem; }
.p-4 { padding: 2rem; }

.w-100 { width: 100%; }
.flex-1 { flex: 1; }

/* =========================
   FILE UPLOAD STYLES
   ========================= */

.file-upload-group {
  margin-top: 1rem;
}

.file-upload-container {
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
}

.file-upload-button {
  display: inline-flex;
  align-items: center;
  padding: 0.75rem 1.5rem;
  background: var(--gradient-primary);
  color: white;
  border: none;
  border-radius: 8px;
  cursor: pointer;
  transition: all 0.3s ease;
  font-weight: 500;
  text-decoration: none;
  justify-content: center;
  max-width: 250px;
}

.file-upload-button:hover {
  background: var(--gradient-hover);
  transform: translateY(-2px);
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
}

.file-selection-display {
  min-height: 1.5rem;
  padding: 0.5rem 0;
}

.file-selection-display .file-count {
  color: var(--success-color);
  font-weight: 500;
  font-size: 0.9rem;
}

.file-selection-display .file-name {
  color: var(--text-secondary);
  font-size: 0.9rem;
  word-break: break-all;
}

.file-upload-info {
  font-size: 0.85rem;
  color: var(--text-muted);
  font-style: italic;
}

/* Category Info Display */
.category-info {
  font-size: 0.85rem;
  color: var(--text-muted);
  margin-top: 0.25rem;
  font-style: italic;
  padding: 0.25rem 0.5rem;
  background: rgba(74, 144, 226, 0.1);
  border-radius: 4px;
  border-left: 3px solid var(--primary-color);
}

/* Mobile Responsiveness für File Upload */
@media (max-width: 768px) {
  .file-upload-button {
    max-width: 100%;
  }
  
  .file-selection-display .file-name {
    font-size: 0.8rem;
  }
}

/* =========================
   DESIGN REQUEST SLIDESHOW
   ========================= */

/* Slideshow Container */
.slideshow-container {
  display: flex;
  flex-wrap: wrap;
  gap: 1rem;
  margin-top: 1rem;
  padding: 1rem;
  background: #f8f9fa;
  border-radius: 8px;
  border: 2px dashed #dee2e6;
}

.slideshow-container:empty {
  display: none;
}

/* Slideshow Media Items */
.slideshow-media-item {
  position: relative;
  width: 120px;
  height: 100px;
  overflow: hidden;
  border-radius: 8px;
  border: 2px solid #dee2e6;
  background: white;
  transition: all 0.3s ease;
}

.slideshow-media-item:hover {
  border-color: var(--primary-color);
  transform: scale(1.05);
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
}

/* Media Elements */
.slideshow-media-image,
.slideshow-media-video {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

/* Remove Button */
.remove-media-btn {
  position: absolute;
  top: 4px;
  right: 4px;
  width: 24px;
  height: 24px;
  border: none;
  border-radius: 50%;
  background: rgba(220, 53, 69, 0.9);
  color: white;
  font-size: 14px;
  font-weight: bold;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all 0.3s ease;
  z-index: 2;
}

.remove-media-btn:hover {
  background: #dc3545;
  transform: scale(1.1);
}

/* Mobile Responsive für Slideshow */
@media (max-width: 768px) {
  .slideshow-container {
    gap: 0.75rem;
    padding: 0.75rem;
  }
  
  .slideshow-media-item {
    width: 100px;
    height: 80px;
  }
  
  .remove-media-btn {
    width: 20px;
    height: 20px;
    font-size: 12px;
    top: 2px;
    right: 2px;
  }
}

@media (max-width: 480px) {
  .slideshow-container {
    justify-content: center;
  }
  
  .slideshow-media-item {
    width: 80px;
    height: 64px;
  }
  
  .remove-media-btn {
    width: 18px;
    height: 18px;
    font-size: 10px;
  }
}

/* Auto-sizing für Textarea in Design-Form */
.design-request-form textarea {
  resize: vertical;
  min-height: 80px;
  transition: height 0.3s ease;
}

/* Date Picker Container */
.date-picker-container {
  position: relative;
  display: flex;
  align-items: center;
}

.picker-icon {
  position: absolute;
  right: 10px;
  color: var(--text-muted);
  cursor: pointer;
  font-size: 1.1rem;
  z-index: 2;
}

.picker-icon:hover {
  color: var(--primary-color);
}