/* ==========================================================
   CONTACT FORM
   VayuCon Renewables
========================================================== */

:root {
  --primary: #003b6d;
  --primary-light: #00569b;

  --accent: #3cb043;
  --accent-light: #61d36b;

  --text: #1b2a3d;
  --text-light: #6a7380;

  --background: #ffffff;

  --border: #d7dee7;
  --border-focus: #3cb043;

  --error: #e74c3c;
  --success: #3cb043;

  --radius: 22px;

  --shadow: 0 25px 60px rgba(0, 0, 0, 0.08);

  --transition: 0.35s cubic-bezier(0.4, 0, 0.2, 1);
}

/* ==========================================================
SECTION
========================================================== */

.contact-section {
  width: 100%;
  padding: 60px 20px;
  display: flex;
  flex-direction: column;
  align-items: center;
  box-sizing: border-box;
}

.contact-container {
  width: min(1200px, 100%);
}

.contact-section .contact-info-box {
  width: 100%;
  max-width: none;
  margin-top: 45px;
  align-items: flex-start;
}

.contact-section .contact-info-item {
  flex: 1 1 220px;
  min-width: 200px;
}

.contact-section .contact-info-item:last-child {
  flex: 0 0 100%;
  min-width: 0;
}

.contact-section .contact-info-heading {
  text-align: center;
}

@media (max-width: 768px) {
  .contact-section .contact-info-item {
    flex: none;
    min-width: 0;
  }
}

/* ==========================================================
HEADER
========================================================== */

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

.section-tag {
  display: inline-block;

  color: var(--accent);

  font-size: 0.85rem;

  font-weight: 700;

  letter-spacing: 3px;

  margin-bottom: 18px;
}

.section-header h1 {
  color: var(--primary);

  font-size: 2.7rem;

  margin-bottom: 18px;

  font-family: "Arimo", sans-serif;
}

.section-header p {
  max-width: 650px;

  margin: auto;

  line-height: 1.9;

  color: var(--text-light);
}

/* ==========================================================
FORM
========================================================== */

.contact-form {
  background: var(--background);

  border-radius: var(--radius);

  padding: 55px;

  box-shadow: var(--shadow);

  border: 1px solid rgba(0, 59, 109, 0.05);
  padding-bottom: 0;
  position: relative;
}

/* ==========================================================
INPUTS
========================================================== */

.input-group {
  position: relative;

  margin-bottom: 38px;
}

.input-group input,
.input-group textarea,
.input-group select {
  width: 100%;
  box-sizing: border-box;

  padding: 16px 0 14px;

  border: none;

  outline: none;

  border-bottom: 2px solid var(--border);

  background: transparent;

  font-size: 1rem;

  color: var(--text);

  transition: var(--transition);
}

textarea {
  resize: none;

  min-height: 150px;
}

select {
  cursor: pointer;
}

/* ==========================================================
LABELS
========================================================== */

.input-group label,
.select-label {
  position: absolute;

  top: 16px;

  left: 0;

  color: var(--text-light);

  pointer-events: none;

  transition: var(--transition);
}

.input-group input:focus + label,
.input-group input:not(:placeholder-shown) + label,
.input-group input:valid + label,
.input-group textarea:focus + label,
.input-group textarea:valid + label,
.input-group select:focus + .select-label,
.input-group select:valid + .select-label {
  top: -12px;

  font-size: 0.78rem;

  letter-spacing: 1px;
}

.input-group input:focus + label,
.input-group input:placeholder-shown + label,
.input-group input:valid + label,
.input-group textarea:focus + label,
.input-group textarea:valid + label,
.input-group select:focus + .select-label,
.input-group select:valid + .select-label {
  top: -12px;

  font-size: 0.78rem;

  letter-spacing: 1px;
  color: var(--accent);
}

/* ==========================================================
BOTTOM LINE
========================================================== */

.line {
  position: absolute;

  bottom: 0;

  left: 0;

  width: 0;

  height: 2px;

  background: var(--accent);

  transition: 0.4s;
}

.input-group:focus-within .line {
  width: 100%;
}

/* ==========================================================
VALIDATION STATES
========================================================== */

.input-group.success input,
.input-group.success textarea,
.input-group.success select {
  border-bottom-color: var(--success);
}

.input-group.error input,
.input-group.error textarea,
.input-group.error select {
  border-bottom-color: var(--error);
}

.input-group.error label {
  color: var(--error);
}

/* ==========================================================
CHARACTER COUNTER
========================================================== */

.message-info {
  display: flex;

  justify-content: flex-end;

  margin-top: -20px;

  margin-bottom: 30px;

  font-size: 0.85rem;

  color: var(--text-light);
}

/* ==========================================================
BUTTON
========================================================== */

.submit-btn {
  width: 100%;

  height: 60px;

  border: none;

  border-radius: 999px;

  background: var(--primary);

  color: #fff;

  font-size: 1rem;

  font-weight: 600;

  cursor: pointer;

  display: flex;

  align-items: center;

  justify-content: center;

  gap: 12px;

  transition: var(--transition);

  overflow: hidden;
}

.submit-btn svg {
  width: 18px;

  fill: none;

  stroke: white;

  stroke-width: 2;

  transition: 0.3s;
}

.submit-btn:hover {
  background: var(--accent);

  transform: translateY(-3px);

  box-shadow: 0 18px 40px rgba(60, 176, 67, 0.25);
}

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

.submit-btn:disabled {
  cursor: not-allowed;

  opacity: 0.8;

  transform: none;
}

/* ==========================================================
STATUS
========================================================== */

.form-status {
  text-align: center;

  margin-top: 22px;

  font-size: 0.95rem;

  min-height: 22px;

  color: var(--text-light);
}

/* ==========================================================
LOADING BUTTON
========================================================== */

.submit-btn.loading {
  pointer-events: none;
}

.submit-btn.loading::after {
  content: "";

  width: 18px;

  height: 18px;

  border-radius: 50%;

  border: 2px solid rgba(255, 255, 255, 0.3);

  border-top-color: #fff;

  animation: spin 0.8s linear infinite;
}

/* ==========================================================
SHAKE
========================================================== */

.shake {
  animation: shake 0.4s;
}

/* ==========================================================
REVEAL
========================================================== */

.reveal {
  opacity: 0;

  transform: translateY(50px);

  transition: 1s ease;
}

.reveal.active {
  opacity: 1;

  transform: none;
}

/* ==========================================================
ANIMATIONS
========================================================== */

@keyframes spin {
  from {
    transform: rotate(0deg);
  }

  to {
    transform: rotate(360deg);
  }
}

@keyframes shake {
  0% {
    transform: translateX(0);
  }

  20% {
    transform: translateX(-6px);
  }

  40% {
    transform: translateX(6px);
  }

  60% {
    transform: translateX(-5px);
  }

  80% {
    transform: translateX(5px);
  }

  100% {
    transform: translateX(0);
  }
}

/* ==========================================================
SCROLLBAR
========================================================== */

textarea::-webkit-scrollbar {
  width: 6px;
}

textarea::-webkit-scrollbar-thumb {
  background: rgba(0, 59, 109, 0.2);

  border-radius: 20px;
}

/* ==========================================================
REDUCED MOTION
========================================================== */

@media (prefers-reduced-motion: reduce) {
  * {
    animation: none !important;

    transition: none !important;
  }
}

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

@media (max-width: 900px) {
  .contact-form {
    padding: 40px;
  }
}

@media (max-width: 768px) {
  .section-header h1 {
    font-size: 2rem;
  }

  .contact-form {
    padding: 35px 28px;
  }
}

@media (max-width: 480px) {
  .section-header h1 {
    font-size: 1.75rem;
  }

  .submit-btn {
    height: 56px;
  }
}
