/* ========================================
   📧 CONTACT SECTION - Experience Theme
   ======================================== */

.contact-section {
  padding: 100px 0;
  background: linear-gradient(135deg, #0a0a0a 0%, #1a1a2e 50%, #0a0a0a 100%);
  position: relative;
  overflow: hidden;
  min-height: 100vh;
}

/* ==========================================
   ✨ BACKGROUND ANIMÉ
   ========================================== */

.contact-section::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background-image: 
    linear-gradient(rgba(0, 212, 255, 0.03) 1px, transparent 1px),
    linear-gradient(90deg, rgba(0, 212, 255, 0.03) 1px, transparent 1px);
  background-size: 50px 50px;
  animation: gridMove 20s linear infinite;
  z-index: 1;
}

@keyframes gridMove {
  0% { transform: translate(0, 0); }
  100% { transform: translate(50px, 50px); }
}

.contact-section::after {
  content: '';
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  width: 1000px;
  height: 1000px;
  background: radial-gradient(
    circle,
    rgba(0, 212, 255, 0.08) 0%,
    rgba(123, 44, 191, 0.06) 40%,
    transparent 70%
  );
  animation: pulseGlow 6s ease-in-out infinite;
  z-index: 1;
}

@keyframes pulseGlow {
  0%, 100% { 
    opacity: 0.4;
    transform: translate(-50%, -50%) scale(1);
  }
  50% { 
    opacity: 0.7;
    transform: translate(-50%, -50%) scale(1.1);
  }
}

.contact-section > .container {
  position: relative;
  z-index: 10;
}

/* ==========================================
   📋 SECTION HEADER
   ========================================== */

.section-header {
  text-align: center;
  margin-bottom: 70px;
}

.section-title {
  font-size: 3rem;
  font-weight: 700;
  background: linear-gradient(135deg, #00d4ff 0%, #7b2cbf 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  margin-bottom: 20px;
  text-shadow: 0 0 30px rgba(0, 212, 255, 0.3);
}

.section-subtitle {
  font-size: 1.2rem;
  color: rgba(255, 255, 255, 0.8);
  max-width: 750px;
  margin: 0 auto;
  text-shadow: 0 2px 10px rgba(0, 0, 0, 0.5);
}

/* ==========================================
   📞 CONTACT WRAPPER
   ========================================== */

.contact-wrapper {
  display: grid;
  grid-template-columns: 40% 1fr;
  gap: 50px;
  margin-bottom: 60px;
}

/* ==========================================
   ℹ️ CONTACT INFO
   ========================================== */

.contact-info {
  background: rgba(26, 26, 26, 0.9);
  backdrop-filter: blur(15px);
  border: 2px solid rgba(0, 212, 255, 0.2);
  border-radius: 28px;
  padding: 40px;
  box-shadow: 
    0 15px 50px rgba(0, 0, 0, 0.5),
    inset 0 0 40px rgba(0, 212, 255, 0.05);
}

.info-header {
  margin-bottom: 35px;
  padding-bottom: 25px;
  border-bottom: 2px solid rgba(0, 212, 255, 0.2);
}

.info-header h3 {
  font-size: 1.8rem;
  font-weight: 700;
  color: #ffffff;
  margin-bottom: 10px;
  text-shadow: 0 0 20px rgba(0, 212, 255, 0.5);
}

.info-header p {
  font-size: 1rem;
  color: rgba(255, 255, 255, 0.7);
  margin: 0;
}

/* ==========================================
   📌 INFO ITEMS
   ========================================== */

.info-item {
  display: flex;
  align-items: flex-start;
  gap: 20px;
  padding: 25px;
  background: rgba(255, 255, 255, 0.03);
  border: 2px solid rgba(255, 255, 255, 0.08);
  border-radius: 16px;
  margin-bottom: 20px;
  transition: all 0.4s ease;
}

.info-item:hover {
  background: rgba(0, 212, 255, 0.08);
  border-color: rgba(0, 212, 255, 0.4);
  transform: translateX(10px);
  box-shadow: 0 10px 30px rgba(0, 212, 255, 0.2);
}

.info-icon {
  width: 55px;
  height: 55px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 14px;
  font-size: 1.6rem;
  flex-shrink: 0;
  transition: all 0.4s ease;
}

.info-icon.location {
  background: linear-gradient(135deg, rgba(255, 107, 107, 0.25), rgba(255, 107, 107, 0.1));
  color: #ff6b6b;
}

.info-icon.phone {
  background: linear-gradient(135deg, rgba(0, 212, 255, 0.25), rgba(0, 212, 255, 0.1));
  color: #00d4ff;
}

.info-icon.email {
  background: linear-gradient(135deg, rgba(123, 44, 191, 0.25), rgba(123, 44, 191, 0.1));
  color: #7b2cbf;
}

.info-icon.linkedin {
  background: linear-gradient(135deg, rgba(0, 119, 181, 0.25), rgba(0, 119, 181, 0.1));
  color: #0077b5;
}

.info-item:hover .info-icon {
  transform: rotate(360deg) scale(1.1);
}

.info-content h4 {
  font-size: 1.1rem;
  font-weight: 700;
  color: #ffffff;
  margin-bottom: 8px;
}

.info-content p {
  font-size: 1rem;
  color: rgba(255, 255, 255, 0.7);
  margin: 0;
  line-height: 1.6;
}

.info-content a {
  color: #00d4ff;
  text-decoration: none;
  transition: all 0.3s ease;
}

.info-content a:hover {
  color: #ffffff;
  text-shadow: 0 0 10px rgba(0, 212, 255, 0.8);
}

/* ==========================================
   🔗 SOCIAL LINKS
   ========================================== */

.info-social {
  margin-top: 35px;
  padding-top: 30px;
  border-top: 2px solid rgba(0, 212, 255, 0.2);
}

.info-social h4 {
  font-size: 1.1rem;
  font-weight: 700;
  color: #ffffff;
  margin-bottom: 20px;
}

.social-links {
  display: flex;
  gap: 15px;
}

.social-link {
  width: 50px;
  height: 50px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 12px;
  font-size: 1.4rem;
  text-decoration: none;
  transition: all 0.3s ease;
  position: relative;
  overflow: hidden;
}

.social-link::before {
  content: '';
  position: absolute;
  inset: 0;
  border-radius: 12px;
  padding: 2px;
  -webkit-mask: linear-gradient(#fff 0 0) content-box, linear-gradient(#fff 0 0);
  -webkit-mask-composite: xor;
  mask-composite: exclude;
  transition: all 0.3s ease;
}

.social-link.linkedin {
  background: rgba(0, 119, 181, 0.15);
  color: #0077b5;
}

.social-link.linkedin::before {
  background: linear-gradient(135deg, #0077b5, #00a0dc);
}

.social-link.github {
  background: rgba(255, 255, 255, 0.08);
  color: #ffffff;
}

.social-link.github::before {
  background: linear-gradient(135deg, #ffffff, #d0d0d0);
}

.social-link.email {
  background: rgba(0, 212, 255, 0.15);
  color: #00d4ff;
}

.social-link.email::before {
  background: linear-gradient(135deg, #00d4ff, #7b2cbf);
}

.social-link:hover {
  transform: translateY(-5px);
  box-shadow: 0 10px 30px rgba(0, 212, 255, 0.4);
}

.social-link:hover::before {
  animation: borderRotate 2s linear infinite;
}

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

/* ==========================================
   ✅ AVAILABILITY BADGE
   ========================================== */

.availability-badge {
  display: flex;
  align-items: center;
  gap: 15px;
  padding: 20px 25px;
  background: rgba(0, 255, 170, 0.1);
  border: 2px solid rgba(0, 255, 170, 0.3);
  border-radius: 50px;
  margin-top: 35px;
  animation: badgePulse 3s ease-in-out infinite;
}

@keyframes badgePulse {
  0%, 100% { box-shadow: 0 0 20px rgba(0, 255, 170, 0.3); }
  50% { box-shadow: 0 0 40px rgba(0, 255, 170, 0.6); }
}

.status-indicator {
  width: 14px;
  height: 14px;
  background: #00ffaa;
  border-radius: 50%;
  animation: indicatorBlink 2s ease-in-out infinite;
  box-shadow: 0 0 10px #00ffaa;
}

@keyframes indicatorBlink {
  0%, 100% { opacity: 1; }
  50% { opacity: 0.5; }
}

.availability-badge span {
  font-size: 0.95rem;
  font-weight: 600;
  color: #00ffaa;
}

/* ==========================================
   📝 CONTACT FORM
   ========================================== */

.contact-form-wrapper {
  background: rgba(26, 26, 26, 0.9);
  backdrop-filter: blur(15px);
  border: 2px solid rgba(0, 212, 255, 0.2);
  border-radius: 28px;
  padding: 45px;
  box-shadow: 
    0 15px 50px rgba(0, 0, 0, 0.5),
    inset 0 0 40px rgba(0, 212, 255, 0.05);
}

.contact-form {
  display: flex;
  flex-direction: column;
  gap: 25px;
}

/* ==========================================
   🔖 FORM GROUP
   ========================================== */

.form-group {
  position: relative;
}

.form-group label {
  display: flex;
  align-items: center;
  gap: 10px;
  font-size: 1rem;
  font-weight: 600;
  color: #ffffff;
  margin-bottom: 12px;
}

.form-group label i {
  color: #00d4ff;
  font-size: 1.1rem;
}

.form-group input,
.form-group textarea {
  width: 100%;
  padding: 16px 20px;
  background: rgba(255, 255, 255, 0.05);
  backdrop-filter: blur(5px);
  border: 2px solid rgba(255, 255, 255, 0.1);
  border-radius: 14px;
  color: #ffffff;
  font-size: 1rem;
  font-family: inherit;
  transition: all 0.3s ease;
}

.form-group input:focus,
.form-group textarea:focus {
  outline: none;
  border-color: #00d4ff;
  background: rgba(0, 212, 255, 0.08);
  box-shadow: 0 0 20px rgba(0, 212, 255, 0.3);
}

.form-group input::placeholder,
.form-group textarea::placeholder {
  color: rgba(255, 255, 255, 0.4);
}

.form-group textarea {
  resize: vertical;
  min-height: 150px;
}

/* ==========================================
   ⚠️ FORM ERROR
   ========================================== */

.form-error {
  display: none;
  margin-top: 8px;
  font-size: 0.85rem;
  color: #ff6b6b;
}

.form-group.error input,
.form-group.error textarea {
  border-color: #ff6b6b;
}

.form-group.error .form-error {
  display: block;
}

/* ==========================================
   🔢 CHAR COUNTER
   ========================================== */

.char-counter {
  margin-top: 8px;
  font-size: 0.85rem;
  color: rgba(255, 255, 255, 0.5);
  text-align: right;
}

#char-count {
  color: #00d4ff;
  font-weight: 600;
}

/* ==========================================
   📊 FORM STATUS
   ========================================== */

.form-status {
  margin: 20px 0;
}

.form-status > div {
  display: none;
  align-items: center;
  gap: 12px;
  padding: 16px 20px;
  border-radius: 14px;
  font-size: 0.95rem;
  font-weight: 600;
  animation: fadeInUp 0.5s ease;
}

.form-status.loading .status-loading {
  display: flex;
}

.form-status.success .status-success {
  display: flex;
}

.form-status.error .status-error {
  display: flex;
}

.status-loading {
  background: rgba(0, 212, 255, 0.15);
  border: 2px solid rgba(0, 212, 255, 0.3);
  color: #00d4ff;
}

.status-success {
  background: rgba(0, 255, 170, 0.15);
  border: 2px solid rgba(0, 255, 170, 0.3);
  color: #00ffaa;
}

.status-error {
  background: rgba(255, 107, 107, 0.15);
  border: 2px solid rgba(255, 107, 107, 0.3);
  color: #ff6b6b;
}

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

/* ==========================================
   ⏳ SPINNER
   ========================================== */

.spinner {
  width: 20px;
  height: 20px;
  border: 3px solid rgba(0, 212, 255, 0.3);
  border-top-color: #00d4ff;
  border-radius: 50%;
  animation: spin 0.8s linear infinite;
}

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

/* ==========================================
   🚀 SUBMIT BUTTON
   ========================================== */

.submit-btn {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 15px;
  padding: 18px 35px;
  background: linear-gradient(135deg, #00d4ff, #7b2cbf);
  border: none;
  border-radius: 50px;
  color: #ffffff;
  font-size: 1.1rem;
  font-weight: 700;
  cursor: pointer;
  transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
  box-shadow: 0 8px 30px rgba(0, 212, 255, 0.4);
  position: relative;
  overflow: hidden;
}

.submit-btn::before {
  content: '';
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  width: 0;
  height: 0;
  background: rgba(255, 255, 255, 0.2);
  border-radius: 50%;
  transition: width 0.6s, height 0.6s;
}

.submit-btn:hover::before {
  width: 300px;
  height: 300px;
}

.submit-btn:hover {
  transform: translateY(-5px);
  box-shadow: 0 15px 45px rgba(0, 212, 255, 0.6);
}

.submit-btn:active {
  transform: translateY(-2px);
}

.btn-text {
  display: flex;
  align-items: center;
  gap: 10px;
}

.btn-icon {
  transition: transform 0.3s ease;
}

.submit-btn:hover .btn-icon {
  transform: translateX(5px);
}

/* ==========================================
   ℹ️ CONTACT FOOTER
   ========================================== */

.contact-footer {
  display: flex;
  justify-content: center;
  flex-wrap: wrap;
  gap: 40px;
  padding: 40px;
  background: rgba(26, 26, 26, 0.8);
  backdrop-filter: blur(10px);
  border: 2px solid rgba(0, 212, 255, 0.2);
  border-radius: 24px;
  box-shadow: 
    0 10px 40px rgba(0, 0, 0, 0.5),
    inset 0 0 30px rgba(0, 212, 255, 0.05);
}

.footer-item {
  display: flex;
  align-items: center;
  gap: 12px;
  font-size: 1rem;
  font-weight: 600;
  color: rgba(255, 255, 255, 0.8);
}

.footer-item i {
  font-size: 1.5rem;
  color: #00d4ff;
}

/* ==========================================
   📱 RESPONSIVE
   ========================================== */

@media (max-width: 991.98px) {
  .contact-wrapper {
    grid-template-columns: 1fr;
    gap: 40px;
  }

  .section-title {
    font-size: 2.5rem;
  }

  .contact-info,
  .contact-form-wrapper {
    padding: 35px;
  }
}

@media (max-width: 767.98px) {
  .contact-section {
    padding: 60px 0;
  }

  .section-title {
    font-size: 2rem;
  }

  .section-subtitle {
    font-size: 1rem;
  }

  .contact-info,
  .contact-form-wrapper {
    padding: 30px 25px;
  }

  .info-item {
    padding: 20px;
  }

  .contact-footer {
    flex-direction: column;
    align-items: center;
    gap: 20px;
    padding: 30px;
  }
}

@media (max-width: 575.98px) {
  .section-title {
    font-size: 1.8rem;
  }

  .info-header h3 {
    font-size: 1.5rem;
  }

  .social-links {
    justify-content: center;
  }

  .submit-btn {
    padding: 16px 28px;
    font-size: 1rem;
  }

  .availability-badge {
    flex-direction: column;
    text-align: center;
    gap: 10px;
  }
}

/* ==========================================
   ♿ ACCESSIBILITÉ
   ========================================== */

@media (prefers-reduced-motion: reduce) {
  .contact-section::before,
  .contact-section::after,
  .spinner,
  .status-indicator,
  .badgePulse {
    animation: none;
  }
}
