/* Social Media User Profile Styles */

.user-social-media {
  display: flex;
  gap: 10px;
  margin: 15px 0;
  flex-wrap: wrap;
}

.social-link {
  display: inline-flex !important;
  align-items: center;
  justify-content: center;
  width: 40px;
  height: 40px;
  border-radius: 7px;
  color: #fff;
  text-decoration: none;
  transition: all 0.3s ease;
  font-size: 16px;
  background-color: #000000;
}

.social-link:hover {
  transform: translateY(-2px);
  box-shadow: 0 4px 8px rgba(0, 0, 0, 0.2);
  text-decoration: none;
  color: #fff;
}

/* Platform-specific colors */
.social-facebook {
  background-color: #1877f2;
}

.social-facebook:hover {
  background-color: #166fe5;
}

.social-twitter {
  background-color: #1da1f2;
}

.social-twitter:hover {
  background-color: #0d8bd9;
}

.social-instagram {
  background: linear-gradient(
    45deg,
    #f09433 0%,
    #e6683c 25%,
    #dc2743 50%,
    #cc2366 75%,
    #bc1888 100%
  );
}

.social-instagram:hover {
  background: linear-gradient(
    45deg,
    #e8832a 0%,
    #d85d33 25%,
    #d31e3a 50%,
    #c31a5d 75%,
    #b30f7f 100%
  );
}

.social-linkedin {
  background-color: #0077b5;
}

.social-linkedin:hover {
  background-color: #005885;
}

.social-youtube {
  background-color: #ff0000;
}

.social-youtube:hover {
  background-color: #cc0000;
}

.social-tiktok {
  background-color: #000000;
}

.social-tiktok:hover {
  background-color: #333333;
}

/* Screen reader only text */
.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

/* Admin profile page styling */
.form-table .social-media-fields input[type="url"] {
  width: 100%;
  max-width: 400px;
}

/* Responsive design */
@media (max-width: 768px) {
  .user-social-media {
    justify-content: center;
  }

  .social-link {
    width: 35px;
    height: 35px;
    font-size: 14px;
  }
}

/* User profile page integration */
.user-profile-social {
  background: #f9f9f9;
  padding: 20px;
  border-radius: 8px;
  margin: 20px 0;
  border: 1px solid #e0e0e0;
}

.user-profile-social h4 {
  margin-bottom: 15px;
  color: #333;
  font-size: 18px;
}

.social-media-empty {
  color: #666;
  font-style: italic;
  text-align: center;
  padding: 20px;
}

/* Registration Form Social Media Styles */
.social-media-section {
  background: linear-gradient(135deg, #f8f9fa 0%, #e9ecef 100%);
  border: 2px solid #007bff;
  border-radius: 12px;
  padding: 20px;
  margin: 20px 0;
  position: relative;
}

.social-media-section::before {
  content: "";
  position: absolute;
  top: -1px;
  left: -1px;
  right: -1px;
  bottom: -1px;
  background: linear-gradient(45deg, #007bff, #0056b3, #007bff);
  border-radius: 12px;
  z-index: -1;
  animation: borderGlow 3s ease-in-out infinite;
}

@keyframes borderGlow {
  0%,
  100% {
    opacity: 0.8;
  }
  50% {
    opacity: 1;
  }
}

.social-media-header {
  display: block !important;
  font-size: 18px;
  font-weight: bold;
  color: #2c3e50;
  margin-bottom: 15px;
  text-align: center;
}

.social-media-header .required-notice {
  color: #e74c3c;
  font-size: 14px;
  font-weight: normal;
  font-style: italic;
}

.social-media-fields-wrapper {
  background: white;
  border-radius: 8px;
  padding: 15px;
  border: 1px solid #dee2e6;
}

.social-media-input {
  border: 2px solid #e9ecef !important;
  border-radius: 8px !important;
  padding: 12px 15px !important;
  font-size: 14px !important;
  transition: all 0.3s ease !important;
  background: #fff !important;
}

.social-media-input:focus {
  border-color: #007bff !important;
  box-shadow: 0 0 0 0.2rem rgba(0, 123, 255, 0.25) !important;
  outline: none !important;
}

.social-media-input.filled {
  border-color: #28a745 !important;
  background: #f8fff9 !important;
}

.social-media-input.error {
  border-color: #dc3545 !important;
  background: #fff5f5 !important;
}

.social-media-validation-error {
  background: #f8d7da;
  color: #721c24;
  padding: 10px 15px;
  border-radius: 6px;
  border: 1px solid #f5c6cb;
  font-weight: bold;
  text-align: center;
  animation: shake 0.5s ease-in-out;
}

@keyframes shake {
  0%,
  100% {
    transform: translateX(0);
  }
  25% {
    transform: translateX(-5px);
  }
  75% {
    transform: translateX(5px);
  }
}

.social-media-validation-success {
  background: #d4edda;
  color: #155724;
  padding: 10px 15px;
  border-radius: 6px;
  border: 1px solid #c3e6cb;
  font-weight: bold;
  text-align: center;
  margin-top: 10px;
}

/* Platform icons in labels */
.social-media-fields-wrapper label {
  display: flex;
  align-items: center;
  gap: 8px;
  font-weight: 600;
  color: #495057;
  margin-bottom: 8px;
}

.social-media-fields-wrapper label::before {
  font-family: "Font Awesome 5 Brands";
  font-size: 16px;
  width: 20px;
  text-align: center;
}

label[for="facebook"]::before {
  content: "\f39e";
  color: #1877f2;
}

label[for="twitter"]::before {
  content: "\f099";
  color: #1da1f2;
}

label[for="instagram"]::before {
  content: "\f16d";
  color: #e4405f;
}

label[for="linkedin"]::before {
  content: "\f0e1";
  color: #0077b5;
}

label[for="youtube"]::before {
  content: "\f167";
  color: #ff0000;
}

label[for="tiktok"]::before {
  content: "\e07b";
  color: #000000;
}

/* Counter for filled fields */
.social-media-counter {
  text-align: center;
  margin-top: 15px;
  padding: 10px;
  background: #e9ecef;
  border-radius: 6px;
  font-size: 14px;
  color: #6c757d;
}

.social-media-counter.valid {
  background: #d4edda;
  color: #155724;
}

/* Responsive design for registration form */
@media (max-width: 768px) {
  .social-media-section {
    margin: 15px 0;
    padding: 15px;
  }

  .social-media-fields-wrapper {
    padding: 10px;
  }

  .social-media-fields-wrapper .row .col-md-6 {
    margin-bottom: 15px;
  }

  .social-media-header {
    font-size: 16px;
  }
}

/* Integration with AdForest theme forms */
.sign-in-account .social-media-section,
.register__account .social-media-section {
  margin: 20px 0;
}

.sign-in-account .social-media-input,
.register__account .social-media-input {
  height: auto !important;
  min-height: 45px !important;
}

/* Form validation styling */
.parsley-errors-list {
  margin: 5px 0 0 0;
  padding: 0;
  list-style: none;
}

.parsley-errors-list li {
  color: #dc3545;
  font-size: 12px;
  margin-top: 5px;
}

.social-media-input.parsley-error {
  border-color: #dc3545 !important;
  background: #fff5f5 !important;
}

.social-media-input.parsley-success {
  border-color: #28a745 !important;
  background: #f8fff9 !important;
}

/* Loading state for social media validation */
.social-media-validating {
  position: relative;
  opacity: 0.7;
  pointer-events: none;
}

.social-media-validating::after {
  content: "";
  position: absolute;
  top: 50%;
  left: 50%;
  width: 20px;
  height: 20px;
  margin: -10px 0 0 -10px;
  border: 2px solid #007bff;
  border-top-color: transparent;
  border-radius: 50%;
  animation: spin 1s linear infinite;
}

@keyframes spin {
  to {
    transform: rotate(360deg);
  }
}

/* Help text for social media fields */
.social-media-help {
  font-size: 12px;
  color: #6c757d;
  margin-top: 5px;
  font-style: italic;
}

.social-media-help strong {
  color: #495057;
}

/* Social media preview (optional) */
.social-media-preview {
  margin-top: 15px;
  padding: 10px;
  background: white;
  border-radius: 6px;
  border: 1px solid #dee2e6;
  display: none;
}

.social-media-preview.show {
  display: block;
}

.social-media-preview h6 {
  margin-bottom: 10px;
  color: #495057;
  font-size: 14px;
}

.social-media-preview .user-social-media {
  margin: 0;
  justify-content: flex-start;
}

.social-media-preview .social-link {
  width: 30px;
  height: 30px;
  font-size: 12px;
}

/* Error states for validation */
.social-media-section.has-error {
  border: 1px solid #dc3545;
  padding: 15px;
  border-radius: 5px;
  background-color: #f8d7da;
  margin-bottom: 15px;
}

.social-media-section.has-error label {
  color: #721c24;
}

.social-media-section.has-error .form-control {
  border-color: #dc3545;
}

.social-media-section.has-error .form-control:focus {
  border-color: #dc3545;
  box-shadow: 0 0 0 0.2rem rgba(220, 53, 69, 0.25);
}

/* Success state */
.social-media-section.has-success {
  border: 1px solid #28a745;
  padding: 15px;
  border-radius: 5px;
  background-color: #d4edda;
  margin-bottom: 15px;
}

.social-media-section.has-success label {
  color: #155724;
}

/* Required indicator styling */
.text-danger {
  color: #dc3545 !important;
  font-weight: bold;
}
