/* ============================================
   HERO SPECIFIC STYLES - Greenix WordPress Theme
   ============================================ */

/* Hero Section */
.hero {
  position: relative;
  width: 100%;
  height: 1080px;
  display: flex;
  align-items: center;
  overflow: hidden;
}

/* Hero Background */
.hero__bg {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background-size: cover;
  background-position: center;
  background-repeat: no-repeat;
  z-index: 0;
}

/* Hero Wrapper - Flex Container */
.hero__wrapper {
  position: relative;
  z-index: 1;
  display: flex;
  align-items: center;
  min-height: 820px;
  width: 100%;
}

/* Hero Left - Container içinde */
.hero__left {
  flex: 0 0 50%;
  max-width: 50%;
  display: flex;
  align-items: center;
  min-height: 820px;
  padding-right: 40px;
  position: relative;
  z-index: 1;
}

.hero__left.container {
  margin-left: auto;
  margin-right: 0;
  max-width: calc(1530px / 2);
}

/* Hero Title */
.hero__title {
  font-size: 64px;
  font-weight: 300;
  color: var(--color-gray-dark);
  text-wrap: nowrap;
}

/* Hero Description */
.hero__desc {
  font-size: 16px;
  font-weight: 300;
  color: var(--color-gray-dark);
  margin-bottom: 88px;
}

/* CTA Label */
.hero__cta-label {
  display: block;
  font-weight: bold;
  color: var(--color-gray-dark);
  margin-bottom: 40px;
}

/* Hero Form */
.hero__form {
  display: flex;
  align-items: center;
  gap: 20px;
  max-width: 520px;
}

/* Hero Input */
.hero__input {
  flex: 1;
  border: none;
  outline: none;
  font-size: 16px;
  font-weight: 400;
  color: var(--color-gray-dark);
  background: #fff;
  padding: 21px 20px;
  min-width: 420px;
  border-radius: 50px;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.03);
  border: 1px solid transparent;
}

.hero__input::placeholder {
  color: #a8d5a2;
  opacity: 1;
}

.hero__input:focus {
  outline: none;
  border-color: var(--color-green);
}

/* Tel input için varsayılan stilleri override et (ikon olmasın) */
.hero__input[type="tel"],
.hero__input[type="number"] {
  -webkit-appearance: none;
  -moz-appearance: textfield;
  appearance: none;
}

/* Chrome/Safari number input spinner'larını gizle */
.hero__input[type="number"]::-webkit-inner-spin-button,
.hero__input[type="number"]::-webkit-outer-spin-button {
  -webkit-appearance: none;
  margin: 0;
}

/* Firefox number input spinner'larını gizle */
.hero__input[type="number"] {
  appearance: textfield;
  -moz-appearance: textfield;
}

.hero__input--error {
  border-color: #ff6666 !important;
}

/* Hero Form Field Error - Minimal */
.hero__form-field-error {
  display: none;
  margin-top: 8px;
  padding: 0 14px;
  color: var(--color-red);
  border-radius: 4px;
  font-size: 13px;
  line-height: 1.5;
  animation: slideDownFade 0.3s ease-out;
}

.hero__form-field-error.is-visible {
  display: block;
}

/* Hero Button */
.hero__button {
  flex-shrink: 0;
  background: var(--color-green);
  color: #fff;
  border: none;
  border-radius: 50px;
  padding: 16px 20px;
  font-size: 20px;
  font-weight: 600;
  cursor: pointer;
  transition: background 0.3s ease, box-shadow 0.3s ease;
}

.hero__button:hover {
  background: #2fa53e;
}

.hero__button:active {
  transform: translateY(0);
}

/* Hero Right - Görsel Alanı */
.hero__right {
  flex: 0 0 50%;
  max-width: 50%;
  display: flex;
  align-items: center;
  justify-content: flex-start;
  height: 820px;
  margin-left: -180px;
}

/* Hero Main Image */
.hero__image-main {
  width: auto;
  max-height: 1080px;
  object-fit: contain;
  display: block;
  margin-top: -50px;
}

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

/* 1536px'den küçük ekranlarda görseli img-fluid gibi responsive yap */
@media (max-width: 1536px) {
  .hero__right {
    justify-content: center;
    margin-left: 0;
  }

  .hero__image-main {
    width: 100%;
    max-width: 100%;
    height: auto;
    object-fit: contain;
  }
  .hero__title {
    font-size: 56px;
  }
}

@media (max-width: 1240px) {
  .hero {
    height: 900px;
  }

  .hero__wrapper {
    gap: 20px;
  }

  .hero__left {
    padding-right: 20px;
    flex: 0 0 48%;
    max-width: 48%;
  }

  .hero__right {
    flex: 0 0 52%;
    max-width: 52%;
    margin-left: 0;
    padding: 0 15px;
  }

  .hero__image-main {
    max-height: 860px;
    max-width: 100%;
    width: 100%;
    height: auto;
  }

  .hero__title {
    font-size: 56px;
  }

  .hero__input {
    min-width: 360px;
  }
}

@media (max-width: 1150px) {
  .hero__left {
    flex: 0 0 45%;
    max-width: 45%;
    padding-right: 16px;
  }

  .hero__right {
    flex: 0 0 55%;
    max-width: 55%;
    margin-left: -80px;
    padding: 0 12px;
  }

  .hero__image-main {
    width: 100%;
    max-width: 100%;
    height: auto;
  }

  .hero__title {
    font-size: 48px;
  }

  .hero__input {
    min-width: 320px;
  }
}

@media (max-width: 1080px) {
  .hero__left {
    flex: 0 0 42%;
    max-width: 42%;
    padding-right: 12px;
  }

  .hero__right {
    flex: 0 0 58%;
    max-width: 58%;
    margin-left: -60px;
    padding: 0 10px;
  }

  .hero__title {
    font-size: 42px;
  }

  .hero__input {
    min-width: 280px;
  }

  .hero__image-main {
    width: 100%;
    max-width: 100%;
    max-height: 800px;
    height: auto;
  }
}

@media (max-width: 1040px) {
  .hero__left {
    flex: 0 0 40%;
    max-width: 40%;
    padding-right: 8px;
  }

  .hero__right {
    flex: 0 0 60%;
    max-width: 60%;
    margin-left: -40px;
    padding: 0 8px;
  }

  .hero__title {
    font-size: 38px;
  }

  .hero__input {
    min-width: 240px;
    font-size: 15px;
  }

  .hero__image-main {
    width: 100%;
    max-width: 100%;
    max-height: 750px;
    height: auto;
  }
}

@media (max-width: 1023px) {
  .hero {
    height: auto;
    min-height: auto;
    padding: 0;
  }

  .hero__bg {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-size: cover;
    background-position: center;
    background-repeat: no-repeat;
  }

  .hero__wrapper {
    flex-direction: column;
    align-items: stretch;
    min-height: auto;
    padding: 0 !important;
    gap: 0;
    max-width: 100%;
  }

  /* Görsel en üstte - tam genişlik */
  .hero__right {
    order: -1;
    flex: 0 0 auto;
    max-width: 100%;
    width: 100%;
    height: auto;
    margin-left: 0;
    margin-bottom: 0;
    display: flex;
    align-items: flex-start;
    justify-content: center;
    padding: 0;
    margin-left: calc(-50vw + 50%);
    margin-right: calc(-50vw + 50%);
    width: 100vw;
    max-width: 100vw;
  }

  .hero__image-main {
    width: 100%;
    max-width: 100%;
    height: auto;
    object-fit: cover;
    margin-top: 0;
    display: block;
  }

  .hero__left {
    flex: 0 0 auto;
    max-width: 100%;
    width: 100%;
    min-height: auto;
    padding: 24px 20px 40px;
    display: flex;
    align-items: flex-start;
    background: transparent;
    position: relative;
    z-index: 1;
    margin-top: -100px;
  }

  .hero__content {
    width: 100%;
  }

  .hero__title {
    font-size: 28px;
    text-wrap: wrap;
    margin-bottom: 16px;
    color: var(--color-gray-dark);
  }

  .hero__desc {
    font-size: 14px;
    line-height: 1.6;
    margin-bottom: 32px;
    color: var(--color-gray-dark);
  }

  .hero__cta-label {
    font-size: 16px;
    margin-bottom: 16px;
    color: var(--color-gray-dark);
  }

  .hero__form {
    max-width: 100%;
    flex-direction: row;
    gap: 8px;
  }

  .hero__input {
    flex: 1;
    min-width: 0;
    padding: 14px 16px;
    font-size: 14px;
    border-radius: 50px;
  }

  .hero__button {
    flex-shrink: 0;
    padding: 14px 24px;
    font-size: 14px;
    border-radius: 50px;
    white-space: nowrap;
  }
}

@media (max-width: 767px) {
  .hero__left {
    padding: 20px 16px 32px;
  }

  .hero__content {
    display: flex;
    flex-direction: column;
  }

  .hero__desc {
    font-size: 13px;
    margin-bottom: 24px;
  }

  .hero__form {
    gap: 6px;
    order: 2;
  }

  .hero__input {
    padding: 12px 14px;
    font-size: 13px;
  }

  .hero__button {
    padding: 12px 20px;
    font-size: 13px;
  }

  /* Mobilde mesajı formun üstüne taşı */
  #hero-form-success-message,
  .hero__form-message {
    order: 1;
    margin-top: 0;
    margin-bottom: 10px;
  }
}

/* Hero Form Message */
.hero__form-message {
  margin-top: 10px;
  border-radius: 8px;
  font-size: 15px;
  font-weight: 400;
  text-align: left;
  line-height: 1.6;
  position: relative;
  z-index: 10;
  width: 100%;
  max-width: 520px;
  box-sizing: border-box;
  display: none;
  visibility: hidden;
  opacity: 0;
  transition: all 0.3s ease-out;
  align-items: flex-start;
  gap: 12px;
}

/* Success Mesajı - Sade ve Minimal */
.hero__form-message--success {
  color: var(--color-green);
  display: flex;
  visibility: visible;
  opacity: 1;
  animation: slideDownFade 0.4s ease-out;
}

.hero__form-message--success::before {
  content: "✓";
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 24px;
  height: 24px;
  border-radius: 50%;
  background-color: var(--color-green);
  color: white;
  font-size: 14px;
  font-weight: 600;
  flex-shrink: 0;
  margin-top: 2px;
}

/* Error Mesajı */
.hero__form-message--error {
  background-color: #fef2f2;
  color: var(--color-red);
  display: flex;
  visibility: visible;
  opacity: 1;
  animation: slideDownFade 0.4s ease-out;
}

.hero__form-message--error::before {
  content: "✕";
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 24px;
  height: 24px;
  border-radius: 50%;
  background-color: var(--color-red);
  color: white;
  font-size: 14px;
  font-weight: 600;
  flex-shrink: 0;
  margin-top: 2px;
}

@keyframes slideDownFade {
  from {
    opacity: 0;
    transform: translateY(-8px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

/* Hero Button Loading State */
.hero__button:disabled {
  opacity: 0.7;
  cursor: not-allowed;
}

.hero__button-loader {
  display: inline-block;
}

@media (max-width: 1023px) {
  .hero__form-message {
    margin-top: 12px;
    padding: 10px 16px;
    font-size: 13px;
  }
}

@media (max-width: 767px) {
  .hero__form-message {
    margin-top: 10px;
    padding: 8px 14px;
    font-size: 12px;
  }
}
