:root {
  --primary: #7c3aed;
  --secondary: #a855f7;
  --accent: #ec4899;
  --text-dark: #1f2937;
  --text-gray: #4b5563;
  --bg-light: #f8f9ff;
  --bg-dark: #0f0f23;
  --shadow: 0 10px 30px rgba(0, 0, 0, 0.1);
  --glass-bg: rgba(255, 255, 255, 0.15);
  --glass-border: rgba(255, 255, 255, 0.2);
}

[data-theme="dark"] {
  --bg-light: #1a1a3a;
  --text-dark: #e5e7eb;
  --text-gray: #9ca3af;
  --glass-bg: rgba(30, 30, 50, 0.3);
  --glass-border: rgba(255, 255, 255, 0.1);
}

.contact-hero {
  min-height: 60vh;
  display: flex;
  align-items: center;
  position: relative;
  padding: 8rem 2rem 4rem;
  background: linear-gradient(
    135deg,
    var(--bg-dark) 0%,
    #1a1a3a 50%,
    #2d1b69 100%
  );
  overflow: hidden;
}

.contact-hero-container {
  max-width: 1200px;
  margin: 0 auto;
  text-align: center;
  z-index: 2;
}

.contact-hero h1 {
  font-size: 3rem;
  font-weight: 700;
  color: white;
  margin-bottom: 1.5rem;
}

.gradient-text {
  background: linear-gradient(
    135deg,
    var(--primary),
    var(--secondary),
    var(--accent)
  );
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  animation: gradient-shift 3s ease-in-out infinite;
}

@keyframes gradient-shift {
  0%,
  100% {
    background-position: 0% 50%;
  }
  50% {
    background-position: 100% 50%;
  }
}

.contact-hero p {
  font-size: 1.1rem;
  color: rgba(255, 255, 255, 0.7);
  max-width: 600px;
  margin: 0 auto 2rem;
}

.floating-elements {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  pointer-events: none;
}

.float-element-2 {
  position: absolute;
  color: rgba(255, 255, 255, 0.1);
  font-size: 2rem;
  animation: float 10s infinite ease-in-out;
}

@keyframes float {
  0%,
  100% {
    transform: translateY(0);
  }
  50% {
    transform: translateY(-20px);
  }
}

.contact-section {
  padding: 6rem 2rem;
  position: relative;
  overflow: hidden;
  background: linear-gradient(135deg, var(--bg-light) 0%, #e8f0ff 100%);
  transition: background 0.3s ease;
}

.contact-section::before {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: url('data:image/svg+xml,%3Csvg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 1440 320"%3E%3Cpath fill="rgba(124,58,237,0.05)" d="M0,160L48,176C96,192,192,224,288,213.3C384,203,480,149,576,138.7C672,128,768,160,864,181.3C960,203,1056,213,1152,197.3C1248,181,1344,139,1392,117.3L1440,96L1440,320L1392,320C1344,320,1248,320,1152,320C1056,320,960,320,864,320C768,320,672,320,576,320C480,320,384,320,288,320C192,320,96,320,48,320L0,320Z"%3E%3C/path%3E%3C/svg%3E')
    bottom no-repeat;
  pointer-events: none;
}

.particles {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  pointer-events: none;
}

.particle {
  position: absolute;
  width: 8px;
  height: 8px;
  background: radial-gradient(circle, rgba(124, 58, 237, 0.3), transparent);
  border-radius: 50%;
  animation: particle-float 15s infinite ease-in-out;
}

@keyframes particle-float {
  0% {
    transform: translate(0, 0);
    opacity: 0.8;
  }
  50% {
    transform: translate(calc(100px * var(--dx)), calc(100px * var(--dy)));
    opacity: 0.4;
  }
  100% {
    transform: translate(0, 0);
    opacity: 0.8;
  }
}

.contact-container {
  max-width: 1200px;
  margin: 0 auto;
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 3rem;
  position: relative;
}

.contact-form {
  background: var(--glass-bg);
  backdrop-filter: blur(10px);
  border: 1px solid var(--glass-border);
  border-radius: 20px;
  padding: 2.5rem;
  box-shadow: var(--shadow);
  position: relative;
  overflow: hidden;
}

.contact-form::before {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: linear-gradient(135deg, var(--primary), var(--secondary));
  opacity: 0.05;
  pointer-events: none;
}

.contact-form h2 {
  font-size: 2rem;
  font-weight: 600;
  color: var(--text-dark);
  margin-bottom: 1.5rem;
  position: relative;
  z-index: 1;
}

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

.form-group label {
  position: absolute;
  top: 50%;
  left: 3rem;
  transform: translateY(-50%);
  font-size: 0.9rem;
  color: var(--text-gray);
  pointer-events: none;
  transition: all 0.3s ease;
}

.form-group input:not(:placeholder-shown) + label,
.form-group input:focus + label,
.form-group select:not(:placeholder-shown) + label,
.form-group select:focus + label,
.form-group textarea:not(:placeholder-shown) + label,
.form-group textarea:focus + label {
  top: -10px;
  left: 1rem;
  font-size: 0.75rem;
  background: var(--glass-bg);
  padding: 0 0.5rem;
  color: var(--primary);
}

.form-group input,
.form-group select,
.form-group textarea {
  width: 100%;
  padding: 0.75rem 0.75rem 0.75rem 3rem;
  border: none;
  border-bottom: 2px solid rgba(124, 58, 237, 0.2);
  background: transparent;
  font-size: 0.9rem;
  color: var(--text-dark);
  transition: all 0.3s ease;
  border-radius: 0;
}

.form-group input:focus,
.form-group select:focus,
.form-group textarea:focus {
  outline: none;
  border-bottom-color: var(--primary);
  box-shadow: 0 2px 10px rgba(124, 58, 237, 0.2);
}

.form-group select {
  appearance: none;
  background: url('data:image/svg+xml,%3Csvg xmlns="http://www.w3.org/2000/svg" width="12" height="12" viewBox="0 0 24 24" fill="none" stroke="%237c3aed" stroke-width="2" stroke-linecap="round" stroke-linejoin="round"%3E%3Cpolyline points="6 9 12 15 18 9"%3E%3C/polyline%3E%3C/svg%3E')
    no-repeat right 1rem center;
  background-size: 12px;
}

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

.form-group i {
  position: absolute;
  top: 50%;
  left: 1rem;
  transform: translateY(-50%);
  color: var(--text-gray);
  font-size: 1rem;
  transition: all 0.3s ease;
}

.form-group input:focus ~ i,
.form-group select:focus ~ i,
.form-group textarea:focus ~ i {
  color: var(--primary);
  animation: pulse 1s infinite;
}

@keyframes pulse {
  0%,
  100% {
    transform: translateY(-50%) scale(1);
  }
  50% {
    transform: translateY(-50%) scale(1.2);
  }
}

.form-group.valid i::after {
  content: "\f058";
  font-family: "Font Awesome 6 Free";
  font-weight: 900;
  color: #059669;
  position: absolute;
  right: 1.5rem;
  top: 50%;
  transform: translateY(-50%);
}

.form-group.invalid i::after {
  content: "\f057";
  font-family: "Font Awesome 6 Free";
  font-weight: 900;
  color: #dc2626;
  position: absolute;
  right: 1.5rem;
  top: 50%;
  transform: translateY(-50%);
}

.character-count {
  font-size: 0.75rem;
  color: var(--text-gray);
  text-align: right;
  margin-top: 0.25rem;
}

.character-count.exceeded {
  color: #dc2626;
}

.form-btn {
  padding: 1rem 2rem;
  background: linear-gradient(135deg, var(--primary), var(--secondary));
  color: white;
  border: none;
  border-radius: 12px;
  font-size: 1rem;
  font-weight: 600;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  box-shadow: var(--shadow);
  transition: all 0.3s ease;
  position: relative;
  overflow: hidden;
}

.form-btn:hover {
  transform: translateY(-2px);
  box-shadow: 0 8px 30px rgba(124, 58, 237, 0.4);
}

.form-btn::after {
  content: "";
  position: absolute;
  top: 50%;
  left: 50%;
  width: 0;
  height: 0;
  background: rgba(255, 255, 255, 0.3);
  border-radius: 50%;
  transform: translate(-50%, -50%);
  transition: width 0.6s ease, height 0.6s ease;
}

.form-btn:active::after {
  width: 200px;
  height: 200px;
}

.form-btn.loading::before {
  content: "";
  display: inline-block;
  width: 16px;
  height: 16px;
  border: 2px solid white;
  border-top: 2px solid transparent;
  border-radius: 50%;
  animation: spin 0.8s linear infinite;
  margin-right: 8px;
}

.form-btn.loading .progress-bar {
  position: absolute;
  bottom: 0;
  left: 0;
  width: 0;
  height: 4px;
  background: var(--accent);
  animation: progress 2s linear infinite;
}

@keyframes progress {
  to {
    width: 100%;
  }
}

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

.toast-container {
  position: fixed;
  top: 2rem;
  right: 2rem;
  z-index: 1000;
  max-width: 400px;
}

.toast {
  padding: 1rem;
  border-radius: 8px;
  margin-bottom: 0.5rem;
  color: white;
  font-size: 0.9rem;
  display: flex;
  align-items: center;
  gap: 0.5rem;
  animation: slideIn 0.3s ease forwards, slideOut 0.3s ease 4.7s forwards;
}

.toast.success {
  background: #059669;
}
.toast.error {
  background: #dc2626;
}

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

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

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

.info-item {
  background: white;
  border-radius: 12px;
  padding: 1.5rem;
  display: flex;
  align-items: flex-start;
  gap: 1rem;
  box-shadow: var(--shadow);
  transition: all 0.3s ease;
}

.info-item:hover {
  transform: translateY(-5px);
  box-shadow: 0 15px 40px rgba(0, 0, 0, 0.15);
}

.info-icon {
  font-size: 1.5rem;
  color: var(--primary);
  margin-top: 0.2rem;
}

.info-content h3 {
  font-size: 1.2rem;
  font-weight: 600;
  color: var(--text-dark);
  margin-bottom: 0.5rem;
}

.info-content p {
  font-size: 0.9rem;
  color: var(--text-gray);
}

.info-content a {
  color: var(--primary);
  text-decoration: none;
}

.info-content a:hover {
  text-decoration: underline;
}

.theme-toggle {
  position: absolute;
  top: 1rem;
  right: 1rem;
  background: none;
  border: none;
  font-size: 1.5rem;
  color: var(--text-gray);
  cursor: pointer;
  transition: all 0.3s ease;
}

.theme-toggle:hover {
  color: var(--primary);
  transform: rotate(15deg);
}

/* Map Section (unchanged) */
.map-section {
  padding: 4rem 2rem;
  background: linear-gradient(
    135deg,
    var(--bg-dark) 0%,
    #1a1a3a 50%,
    #2d1b69 100%
  );
}

.map-container {
  max-width: 1200px;
  margin: 0 auto;
  text-align: center;
}

.map-container h2 {
  font-size: 2.5rem;
  font-weight: 700;
  color: white;
  margin-bottom: 1rem;
}

.map-container p {
  font-size: 1rem;
  color: rgba(255, 255, 255, 0.7);
  max-width: 600px;
  margin: 0 auto 1.5rem;
}

.map-wrapper {
  position: relative;
  width: 100%;
  height: 400px;
  border-radius: 16px;
  overflow: hidden;
  box-shadow: var(--shadow);
}

.map-wrapper iframe {
  width: 100%;
  height: 100%;
  border: none;
}

.map-actions {
  margin-top: 1.5rem;
  display: flex;
  justify-content: center;
  gap: 1rem;
}

/* .back-to-top {
  position: fixed;
  bottom: 2rem;
  right: 50%;
  transform: translateX(50%);
  background: var(--primary);
  color: white;
  width: 50px;
  height: 50px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: var(--shadow);
  opacity: 0;
  visibility: hidden;
  transition: all 0.3s ease;
  z-index: 1000;
}

.back-to-top.show {
  opacity: 1;
  visibility: visible;
} */

/* .back-to-top:hover {
  transform: translateY(-5px);
} */

@media (max-width: 768px) {
  .contact-info {
    flex-direction: column;
  }
  .contact-hero h1 {
    font-size: 2.5rem;
  }

  .contact-container {
    grid-template-columns: 1fr;
  }

  .map-wrapper {
    height: 300px;
  }

  .footer-content {
    grid-template-columns: 1fr;
    text-align: center;
  }

  .newsletter-form {
    flex-direction: column;
    align-items: center;
  }

  .newsletter-input {
    max-width: 100%;
  }

  .toast-container {
    top: 1rem;
    right: 1rem;
    width: calc(100% - 2rem);
  }
}
