/* Modern Interactive Contact Section */

.contact-section {
  padding: 8rem 2rem;
  position: relative;
  overflow: hidden;
  background: var(--primary-color);
  background-image: url("data:image/svg+xml,%3Csvg width='60' height='60' viewBox='0 0 60 60' xmlns='http://www.w3.org/2000/svg'%3E%3Cg fill='none' fill-rule='evenodd'%3E%3Cg fill='%239C92AC' fill-opacity='0.03'%3E%3Cpath d='M36 34v-4h-2v4h-4v2h4v4h2v-4h4v-2h-4zm0-30V0h-2v4h-4v2h4v4h2V6h4V4h-4zM6 34v-4H4v4H0v2h4v4h2v-4h4v-2H6zM6 4V0H4v4H0v2h4v4h2V6h4V4H6z'/%3E%3C/g%3E%3C/g%3E%3C/svg%3E");
  background-attachment: fixed;
}

.contact-section::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: radial-gradient(circle at 85% 30%, rgba(255, 51, 102, 0.08) 0%, transparent 50%);
  z-index: 0;
  pointer-events: none;
}

.contact-section::after {
  content: '';
  position: absolute;
  bottom: 0;
  left: 0;
  width: 100%;
  height: 200px;
  background: linear-gradient(to top, var(--primary-color) 0%, transparent 100%);
  z-index: 0;
  pointer-events: none;
}

.contact-container {
  max-width: 1200px;
  margin: 0 auto;
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(350px, 1fr));
  gap: 3rem;
  position: relative;
  z-index: 1;
}

.contact-info {
  display: flex;
  flex-direction: column;
  gap: 2rem;
}

.contact-title {
  font-size: 2.5rem;
  font-weight: 700;
  margin-bottom: 0.5rem;
  background: linear-gradient(90deg, #fff, rgba(255, 255, 255, 0.9));
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
  position: relative;
}

.contact-title::after {
  content: '';
  position: absolute;
  width: 60px;
  height: 4px;
  background: var(--accent-color);
  bottom: -10px;
  left: 0;
  border-radius: 2px;
}

.contact-subtitle {
  font-size: 1.2rem;
  color: rgba(255, 255, 255, 0.6);
  margin-bottom: 2rem;
  margin-top: 1.5rem;
  line-height: 1.6;
}

.contact-method {
  display: flex;
  align-items: center;
  gap: 1.5rem;
  padding: 1.5rem;
  background: rgba(255, 255, 255, 0.02);
  border: 1px solid rgba(255, 255, 255, 0.03);
  border-radius: 12px;
  transition: all 0.3s ease;
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  position: relative;
  overflow: hidden;
}

.contact-method::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 2px;
  background: linear-gradient(to right, transparent, var(--accent-color), transparent);
  opacity: 0;
  transition: opacity 0.3s ease;
}

.contact-method:hover::before {
  opacity: 1;
}

.contact-method:hover {
  transform: translateY(-5px);
  background: rgba(255, 255, 255, 0.05);
  border-color: rgba(255, 255, 255, 0.08);
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.15);
}

.contact-icon {
  width: 50px;
  height: 50px;
  background: rgba(255, 51, 102, 0.1);
  border-radius: 12px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.5rem;
  color: var(--accent-color);
  transition: all 0.3s ease;
}

.contact-method:hover .contact-icon {
  background: var(--accent-color);
  color: white;
  transform: scale(1.1);
  box-shadow: 0 0 15px rgba(255, 51, 102, 0.4);
}

.contact-method-details h3 {
  font-size: 1.2rem;
  font-weight: 600;
  margin-bottom: 0.3rem;
  color: rgba(255, 255, 255, 0.9);
}

.contact-method-details p, .contact-method-details a {
  font-size: 1rem;
  color: rgba(255, 255, 255, 0.6);
  text-decoration: none;
  transition: color 0.3s ease;
}

.contact-method-details a:hover {
  color: var(--accent-color);
}

.contact-form-container {
  background: rgba(255, 255, 255, 0.03);
  border: 1px solid rgba(255, 255, 255, 0.05);
  border-radius: 16px;
  padding: 2.5rem;
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  transition: all 0.5s cubic-bezier(0.16, 1, 0.3, 1);
  height: fit-content;
  position: relative;
  overflow: hidden;
}

.contact-form-container::before {
  content: '';
  position: absolute;
  top: -50%;
  left: -50%;
  width: 200%;
  height: 200%;
  background: radial-gradient(circle at center, rgba(255, 51, 102, 0.05) 0%, transparent 40%);
  opacity: 0;
  transition: opacity 0.5s ease;
  z-index: -1;
  transform: translate3d(0, 0, 0);
}

.contact-form-container:hover::before {
  opacity: 1;
  animation: pulse 2s infinite;
}

@keyframes pulse {
  0% {
    transform: scale(0.95);
  }
  50% {
    transform: scale(1);
  }
  100% {
    transform: scale(0.95);
  }
}

.contact-form-container:hover {
  border-color: rgba(255, 255, 255, 0.1);
  box-shadow: 0 15px 35px rgba(0, 0, 0, 0.15);
}

.form-title {
  font-size: 1.5rem;
  font-weight: 600;
  margin-bottom: 1.5rem;
  color: rgba(255, 255, 255, 0.9);
  position: relative;
  display: inline-block;
}

.form-title::after {
  content: '';
  position: absolute;
  width: 80%;
  height: 2px;
  background: var(--accent-color);
  bottom: -10px;
  left: 0;
  border-radius: 1px;
}

.form-group {
  margin-bottom: 1.5rem;
  position: relative;
}

.input-wrapper {
  position: relative;
  transition: all 0.3s ease;
}

.input-wrapper .input-icon {
  position: absolute;
  left: 15px;
  top: 50%;
  transform: translateY(-50%);
  font-size: 1.2rem;
  color: rgba(255, 255, 255, 0.3);
  transition: all 0.3s ease;
  z-index: 1;
  pointer-events: none;
}

textarea ~ .input-icon {
  top: 25px;
}

.input-wrapper.focused .input-icon,
.input-wrapper.has-content .input-icon {
  color: var(--accent-color);
}

.input-wrapper input,
.input-wrapper textarea {
  width: 100%;
  padding: 1rem 1rem 1rem 3rem;
  background: rgba(255, 255, 255, 0.02);
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 12px;
  color: rgba(255, 255, 255, 0.9);
  font-size: 1rem;
  transition: all 0.3s ease;
  font-family: inherit;
  box-shadow: 0 4px 6px rgba(0, 0, 0, 0.05);
}

.input-wrapper input:focus,
.input-wrapper textarea:focus {
  outline: none;
  border-color: rgba(255, 51, 102, 0.3);
  background: rgba(255, 255, 255, 0.05);
  box-shadow: 0 0 0 3px rgba(255, 51, 102, 0.1);
}

.input-wrapper input::placeholder,
.input-wrapper textarea::placeholder {
  color: rgba(255, 255, 255, 0.3);
  transition: opacity 0.3s ease;
}

.input-wrapper.focused input::placeholder,
.input-wrapper.focused textarea::placeholder {
  opacity: 0.5;
}

.input-wrapper textarea {
  min-height: 150px;
  resize: vertical;
  padding-top: 1.2rem;
}

.error-message {
  display: none;
  color: #ff3366;
  font-size: 0.85rem;
  margin-top: 0.5rem;
  padding-left: 0.5rem;
  animation: errorShake 0.5s cubic-bezier(.36,.07,.19,.97) both;
}

@keyframes errorShake {
  0%, 100% { transform: translateX(0); }
  10%, 30%, 50%, 70%, 90% { transform: translateX(-2px); }
  20%, 40%, 60%, 80% { transform: translateX(2px); }
}

.character-counter {
  position: absolute;
  bottom: 10px;
  right: 10px;
  font-size: 0.75rem;
  color: rgba(255, 255, 255, 0.4);
  transition: all 0.3s ease;
}

.approaching-limit {
  color: #ff9900;
}

.submit-btn {
  width: 100%;
  padding: 1.2rem;
  background: var(--accent-color);
  color: white;
  border: none;
  border-radius: 12px;
  font-size: 1.1rem;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.3s ease;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 1rem;
  position: relative;
  overflow: hidden;
}

.submit-btn::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: linear-gradient(to right, transparent, rgba(255, 255, 255, 0.2), transparent);
  transform: translateX(-100%);
  transition: transform 0.6s ease;
}

.submit-btn:hover::before {
  transform: translateX(100%);
}

.submit-btn:hover {
  background: linear-gradient(to right, var(--accent-color), rgba(255, 51, 102, 0.8));
  transform: translateY(-3px);
  box-shadow: 0 10px 20px rgba(255, 51, 102, 0.2);
}

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

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

.submit-btn.loading {
  background: var(--accent-color);
  opacity: 0.8;
  cursor: wait;
}

.submit-btn.loading i {
  animation: spinner 1s linear infinite;
}

.submit-btn.disabled {
  opacity: 0.6;
  cursor: not-allowed;
}

@keyframes spinner {
  0% { transform: rotate(0deg); }
  100% { transform: rotate(360deg); }
}

.form-status {
  margin-top: 1.5rem;
  padding: 1rem;
  border-radius: 10px;
  background: rgba(0, 0, 0, 0.2);
  display: flex;
  align-items: center;
  gap: 0.8rem;
  opacity: 0;
  transform: translateY(10px);
  transition: all 0.3s ease;
  height: 0;
  overflow: hidden;
}

.form-status.show {
  opacity: 1;
  transform: translateY(0);
  height: auto;
}

.success-message {
  color: #4cd964;
  display: flex;
  align-items: center;
  gap: 0.5rem;
  font-weight: 500;
}

.error-message {
  color: #ff3366;
  display: flex;
  align-items: center;
  gap: 0.5rem;
  font-weight: 500;
}

.is-invalid {
  border-color: rgba(255, 51, 102, 0.4) !important;
  background: rgba(255, 51, 102, 0.05) !important;
}

/* Animation for contact section elements */
.contact-animate {
  opacity: 0;
  transform: translateY(30px);
  transition: all 0.8s cubic-bezier(0.16, 1, 0.3, 1);
}

.contact-animate.in-view {
  opacity: 1;
  transform: translateY(0);
}

/* Social media links */
.social-links {
  display: flex;
  gap: 1rem;
  margin-top: 1.5rem;
}

.social-link {
  width: 45px;
  height: 45px;
  background: rgba(255, 255, 255, 0.03);
  border: 1px solid rgba(255, 255, 255, 0.05);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  color: rgba(255, 255, 255, 0.7);
  font-size: 1.2rem;
  transition: all 0.3s ease;
}

.social-link:hover {
  background: var(--accent-color);
  color: white;
  transform: translateY(-5px);
  box-shadow: 0 8px 16px rgba(var(--accent-rgb), 0.2);
}

/* Responsive styles */
@media (max-width: 768px) {
  .contact-container {
    grid-template-columns: 1fr;
  }
  
  .contact-info {
    order: 2;
  }
  
  .contact-form-container {
    order: 1;
    margin-bottom: 2rem;
  }
  
  .contact-title {
    font-size: 2rem;
  }
}

@media (max-width: 480px) {
  .contact-method {
    flex-direction: column;
    text-align: center;
    padding: 1.5rem 1rem;
  }
  
  .contact-method-details {
    align-items: center;
  }
  
  .contact-form-container {
    padding: 1.5rem;
  }
}

/* Message handling improvements */
.form-status.success {
  background: rgba(76, 217, 100, 0.1);
  border-left: 3px solid #4cd964;
}

.form-status.error {
  background: rgba(255, 59, 48, 0.1);
  border-left: 3px solid #ff3b30;
}

.success-message, .error-message {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  width: 100%;
}

.success-message i, .error-message i {
  font-size: 1.5rem;
}

.error-message {
  color: #ff3b30;
}

/* Improved form field validation styles */
.input-wrapper input.is-invalid,
.input-wrapper textarea.is-invalid {
  border-color: #ff3b30;
  box-shadow: 0 0 0 1px rgba(255, 59, 48, 0.2);
}

.error-message {
  font-size: 0.75rem;
  padding: 0.25rem 0;
  color: #ff3b30;
  display: none;
  transition: all 0.3s ease;
}

.error-message:not(:empty) {
  display: block;
  margin-top: 0.25rem;
}

/* Spinner animation */
@keyframes spinner {
  0% { transform: rotate(0deg); }
  100% { transform: rotate(360deg); }
}

/* Improved form animations */
.contact-animate {
  opacity: 0;
  transform: translateY(30px);
  transition: opacity 0.5s ease, transform 0.5s ease;
}

.contact-animate.visible {
  opacity: 1;
  transform: translateY(0);
}
