/* Custom improvements for Pelin Batu Law Firm Website */

/* ========================================
   HEADER LOGO TEXT STYLING IMPROVEMENTS
   ======================================== */

/* Professional logo text styling */
.main-header__logo a {
  font-family: "Marcellus", serif !important;
  font-size: 28px !important;
  font-weight: 400 !important;
  color: #19223a !important;
  text-decoration: none !important;
  letter-spacing: 0.5px;
  position: relative;
  display: inline-block;
  padding: 12px 24px;
  background: #ffffff;
  border: 2px solid #c7954a;
  border-radius: 8px;
  box-shadow: 0 4px 12px rgba(199, 149, 74, 0.15);
  text-transform: uppercase;
  line-height: 1.2;
}

/* Logo styling for sticky header */
.sticky-header--one-page.stricky-fixed .main-header__logo a {
  background: #19223a;
  color: #ffffff !important;
  border-color: #c7954a;
}

/* Responsive adjustments for logo */
@media (max-width: 1199px) {
  .main-header__logo a {
    font-size: 24px !important;
    padding: 10px 20px;
  }
}

@media (max-width: 767px) {
  .main-header__logo a {
    font-size: 20px !important;
    padding: 8px 16px;
    letter-spacing: 0.3px;
  }
}

@media (max-width: 480px) {
  .main-header__logo a {
    font-size: 18px !important;
    padding: 6px 12px;
  }
}

/* ========================================
   CONTACT FORM PHONE NUMBER FIELD IMPROVEMENTS
   ======================================== */

/* Enhanced phone number input styling */
.contact-one__form input[type="tel"] {
  position: relative;
  background-color: transparent !important;
  border: none !important;
  border-bottom: 2px solid #d9d9d9 !important;
  border-radius: 0 !important;
  padding: 15px 0 15px 0 !important;
  font-size: 16px !important;
  font-weight: 500 !important;
  color: #19223a !important;
  outline: none !important;
  height: 60px !important;
}

/* Phone input focus state */
.contact-one__form input[type="tel"]:focus {
  border-bottom-color: #c7954a !important;
  color: #19223a !important;
  box-shadow: 0 2px 0 0 rgba(199, 149, 74, 0.2) !important;
}

/* Phone input placeholder styling */
.contact-one__form input[type="tel"]::placeholder {
  color: #838790 !important;
  font-weight: 400 !important;
  opacity: 0.8;
}

.contact-one__form input[type="tel"]:focus::placeholder {
  opacity: 0.5;
}

/* Phone input validation states */
.contact-one__form input[type="tel"].valid {
  border-bottom-color: #28a745 !important;
}

.contact-one__form input[type="tel"].invalid {
  border-bottom-color: #dc3545 !important;
}

/* Phone input container enhancement */
.contact-one__form .form-one__control:has(input[type="tel"]) {
  position: relative;
  margin-bottom: 25px;
}

/* Fallback for browsers without :has() support */
.contact-one__form .form-one__control {
  position: relative;
}

.contact-one__form input[type="tel"] {
  margin-bottom: 5px;
}

/* Add phone icon to input */
.contact-one__form .form-one__control:has(input[type="tel"])::before {
  content: "\f095";
  font-family: "Font Awesome 5 Free";
  font-weight: 900;
  position: absolute;
  right: 0;
  top: 50%;
  transform: translateY(-50%);
  color: #c7954a;
  font-size: 16px;
  z-index: 2;
  opacity: 0.7;
}

/* Fallback phone icon for browsers without :has() support */
.contact-one__form input[type="tel"] + .phone-icon {
  content: "\f095";
  font-family: "Font Awesome 5 Free";
  font-weight: 900;
  position: absolute;
  right: 0;
  top: 20px;
  color: #c7954a;
  font-size: 16px;
  z-index: 2;
  opacity: 0.7;
  pointer-events: none;
}

.contact-one__form .form-one__control:has(input[type="tel"]:focus)::before,
.contact-one__form input[type="tel"]:focus + .phone-icon {
  opacity: 1;
}

/* Phone input formatting helper text */
.phone-format-helper {
  font-size: 12px;
  color: #838790;
  margin-top: 5px;
  opacity: 0;
  font-style: italic;
}

.contact-one__form
  .form-one__control:has(input[type="tel"]:focus)
  .phone-format-helper,
.contact-one__form input[type="tel"]:focus ~ .phone-format-helper {
  opacity: 1;
}

/* Mobile responsive adjustments for phone input */
@media (max-width: 767px) {
  .contact-one__form input[type="tel"] {
    font-size: 16px !important; /* Prevent zoom on iOS */
    padding: 12px 0 !important;
    height: 55px !important;
  }

  .contact-one__form .form-one__control:has(input[type="tel"])::before {
    font-size: 14px;
  }
}

/* ========================================
   GENERAL FORM IMPROVEMENTS
   ======================================== */

/* Consistent styling for all form inputs in contact form */
.contact-one__form input[type="text"],
.contact-one__form input[type="email"],
.contact-one__form textarea {
  font-weight: 500 !important;
  color: #19223a !important;
}

.contact-one__form input[type="text"]:focus,
.contact-one__form input[type="email"]:focus,
.contact-one__form textarea:focus {
  color: #19223a !important;
  box-shadow: 0 2px 0 0 rgba(199, 149, 74, 0.2) !important;
}

/* Form validation feedback */
.form-feedback {
  font-size: 12px;
  margin-top: 5px;
}

.form-feedback.valid {
  color: #28a745;
}

.form-feedback.invalid {
  color: #dc3545;
}

/* ========================================
   ACCESSIBILITY IMPROVEMENTS
   ======================================== */

/* Focus indicators for better accessibility */
.main-header__logo a:focus {
  outline: 2px solid #c7954a;
  outline-offset: 2px;
}

.contact-one__form input:focus,
.contact-one__form textarea:focus {
  outline: none;
  position: relative;
}

/* High contrast mode support */
@media (prefers-contrast: high) {
  .main-header__logo a {
    border-width: 3px !important;
    font-weight: 600 !important;
  }

  .contact-one__form input[type="tel"] {
    border-bottom-width: 3px !important;
  }
}
