/**
 * Mafar Group - Contact Page Styles
 * 
 * Matches elementor-html/contact structure exactly
 * Uses mafar- prefix for all class names
 * 
 * Structure:
 * 1. Contact Hero (dark background, grid pattern, gold glow)
 * 2. Contact Info + Map (cards, map, business hours)
 * 3. Combined Inquiry Forms (partnership + general, side by side)
 * 4. What Happens Next (dark, horizontal timeline, CTA buttons)
 * 
 * @package Mafar
 * @version 3.1.0
 */

/* ============================================================
   BLOCK 1: CONTACT HERO
   ============================================================ */

.mafar-contact-hero {
  font-family: var(--font-primary);
  background: var(--mafar-black);
  padding: 100px 0 80px;
  position: relative;
  overflow: hidden;
}


.mafar-contact-hero-line {
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  height: 1px;
  background: linear-gradient(90deg, transparent, var(--mafar-gold), transparent);
  opacity: 0.3;
}

.mafar-contact-hero .mafar-container {
  max-width: 900px;
  margin: 0 auto;
  padding: 0 5%;
  position: relative;
  z-index: 2;
  text-align: center;
}

.mafar-contact-hero-label {
  font-size: 0.8rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.15em;
  color: var(--mafar-gold);
  margin-bottom: 20px;
}

.mafar-contact-hero-title {
  font-family: var(--font-serif);
  font-size: clamp(2.4rem, 5vw, 3.6rem);
  font-weight: 400;
  line-height: 1.15;
  color: var(--mafar-white);
  margin-bottom: 24px;
}

.mafar-contact-hero-title em {
  font-style: normal;
  color: var(--mafar-gold);
}

.mafar-contact-hero-desc {
  font-size: 1.1rem;
  line-height: 1.7;
  color: var(--text-tertiary);
  max-width: 600px;
  margin: 0 auto;
}

@media (max-width: 768px) {
  .mafar-contact-hero {
    padding: 80px 0 60px;
  }
}

/* ============================================================
   BLOCK 2: CONTACT INFO + MAP
   ============================================================ */

.mafar-contact-info {
  font-family: var(--font-primary);
  background: var(--mafar-white);
  padding: 100px 0;
}

.mafar-contact-info .mafar-container {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 5%;
}

.mafar-contact-info-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 60px;
  align-items: start;
}

/* Left: Contact details */
.mafar-contact-left-label {
  font-size: 0.75rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.15em;
  color: var(--mafar-gold);
  margin-bottom: 12px;
}

.mafar-contact-left-title {
  font-family: var(--font-serif);
  font-size: clamp(1.8rem, 3.5vw, 2.4rem);
  font-weight: 400;
  color: var(--text-primary);
  line-height: 1.2;
  margin-bottom: 16px;
}

.mafar-contact-left-desc {
  font-size: 1rem;
  line-height: 1.7;
  color: var(--text-secondary);
  margin-bottom: 40px;
}

.mafar-contact-cards {
  display: flex;
  flex-direction: column;
  gap: 20px;
}

.mafar-contact-card {
  display: flex;
  align-items: flex-start;
  gap: 20px;
  padding: 28px;
  background: var(--background-light);
  border: 1px solid var(--border-default);
  border-radius: var(--radius-card);
  transition: all 0.3s ease;
}

.mafar-contact-card:hover {
  border-color: var(--mafar-gold);
  box-shadow: 0 4px 20px rgba(212,175,55,0.08);
}

.mafar-contact-card-icon {
  width: 48px;
  height: 48px;
  min-width: 48px;
  background: var(--mafar-gold-light);
  border-radius: 12px;
  display: flex;
  align-items: center;
  justify-content: center;
}

.mafar-contact-card-icon svg {
  width: 22px;
  height: 22px;
  color: var(--mafar-gold);
  stroke: var(--mafar-gold);
  fill: none;
}

.mafar-contact-card-content h4 {
  font-size: 1rem;
  font-weight: 600;
  color: var(--text-primary);
  margin-bottom: 6px;
}

.mafar-contact-card-content p {
  font-size: 0.9rem;
  line-height: 1.6;
  color: var(--text-secondary);
}

.mafar-contact-card-content a {
  color: var(--mafar-gold);
  text-decoration: none;
  font-weight: 500;
  transition: opacity 0.2s;
}

.mafar-contact-card-content a:hover {
  opacity: 0.8;
}

/* Right: Map + Address */
.mafar-contact-map-wrap {
  border-radius: var(--radius-card);
  overflow: hidden;
  border: 1px solid var(--border-default);
  background: var(--background-light);
}

.mafar-contact-map-wrap iframe {
  width: 100%;
  height: 360px;
  display: block;
}

.mafar-contact-address-bar {
  padding: 24px 28px;
  background: var(--mafar-white);
  border-top: 1px solid var(--border-default);
}

.mafar-contact-address-bar h4 {
  font-size: 0.95rem;
  font-weight: 600;
  color: var(--text-primary);
  margin-bottom: 8px;
}

.mafar-contact-address-bar p {
  font-size: 0.88rem;
  line-height: 1.6;
  color: var(--text-secondary);
}

.mafar-contact-hours {
  margin-top: 20px;
  padding: 20px 24px;
  background: var(--mafar-gold-light);
  border-radius: 12px;
}

.mafar-contact-hours h4 {
  font-size: 0.88rem;
  font-weight: 600;
  color: var(--text-primary);
  margin-bottom: 8px;
}

.mafar-contact-hours-row {
  display: flex;
  justify-content: space-between;
  font-size: 0.85rem;
  color: var(--text-secondary);
  padding: 4px 0;
}

.mafar-contact-hours-row span:last-child {
  font-weight: 500;
  color: var(--text-primary);
}

@media (max-width: 900px) {
  .mafar-contact-info-grid {
    grid-template-columns: 1fr;
    gap: 48px;
  }
}

@media (max-width: 480px) {
  .mafar-contact-card {
    flex-direction: column;
    gap: 14px;
    padding: 22px;
  }
}

/* ============================================================
   BLOCK 3: COMBINED INQUIRY FORMS
   ============================================================ */

.mafar-combined-forms {
  font-family: var(--font-primary);
  background: var(--background-light);
  padding: 100px 0;
}

.mafar-combined-forms .mafar-container {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 5%;
}

.mafar-combined-forms-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 60px;
  align-items: start;
}

.mafar-combined-form-column {
  display: flex;
  flex-direction: column;
}

.mafar-combined-form-card {
  background: var(--mafar-white);
  border: 1px solid var(--border-default);
  border-radius: var(--radius-card);
  padding: 40px;
}

.mafar-combined-form-label {
  font-size: 0.75rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.15em;
  color: var(--mafar-gold);
  margin-bottom: 12px;
}

.mafar-combined-form-card h3 {
  font-family: var(--font-serif);
  font-size: clamp(1.5rem, 3vw, 2rem);
  font-weight: 400;
  color: var(--text-primary);
  line-height: 1.2;
  margin-bottom: 12px;
}

.mafar-combined-form-card h3 em {
  font-style: normal;
  color: var(--mafar-gold);
}

.mafar-combined-form-card > p {
  font-size: 0.95rem;
  line-height: 1.7;
  color: var(--text-secondary);
  margin-bottom: 28px;
}

/* Form elements - shared styles */
.mafar-form-row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 16px;
  margin-bottom: 16px;
}

.mafar-form-group {
  display: flex;
  flex-direction: column;
}

.mafar-form-group.full-width {
  grid-column: 1 / -1;
}

.mafar-form-group label {
  font-size: 0.82rem;
  font-weight: 600;
  color: var(--text-primary);
  margin-bottom: 6px;
}

.mafar-form-group label .mafar-required {
  color: #ef4444;
}

.mafar-form-group input,
.mafar-form-group select,
.mafar-form-group textarea {
  font-family: var(--font-primary);
  font-size: 0.92rem;
  padding: 12px 16px;
  border: 1px solid var(--border-default);
  border-radius: 10px;
  background: var(--mafar-white);
  color: var(--text-primary);
  transition: border-color 0.2s;
  outline: none;
  width: 100%;
}

.mafar-form-group input:focus,
.mafar-form-group select:focus,
.mafar-form-group textarea:focus {
  border-color: var(--mafar-gold);
  box-shadow: 0 0 0 3px var(--mafar-gold-shadow);
}

.mafar-form-group input::placeholder,
.mafar-form-group textarea::placeholder {
  color: var(--text-tertiary);
}

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

.mafar-form-group select {
  appearance: none;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='16' height='16' viewBox='0 0 24 24' fill='none' stroke='%2394a3b8' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='m6 9 6 6 6-6'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 14px center;
  padding-right: 40px;
}

/* Radio group */
.mafar-form-radio-group {
  display: flex;
  gap: 12px;
  flex-wrap: wrap;
}

.mafar-form-radio-option {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 10px 18px;
  border: 1px solid var(--border-default);
  border-radius: 10px;
  cursor: pointer;
  transition: all 0.2s;
  flex: 1;
  min-width: 160px;
}

.mafar-form-radio-option:hover {
  border-color: var(--mafar-gold);
  background: var(--mafar-gold-light);
}

.mafar-form-radio-option input[type="radio"] {
  width: 16px;
  height: 16px;
  accent-color: var(--mafar-gold);
}

.mafar-form-radio-option span {
  font-size: 0.88rem;
  font-weight: 500;
  color: var(--text-primary);
}

.mafar-form-submit {
  margin-top: 24px;
}

.mafar-form-submit button,
.mafar-form-submit input[type="submit"] {
  font-family: var(--font-primary);
  font-size: 0.95rem;
  font-weight: 600;
  padding: 14px 36px;
  background: var(--mafar-gold);
  color: var(--mafar-black);
  border: none;
  border-radius: var(--radius-btn);
  cursor: pointer;
  transition: all 0.3s;
  width: 100%;
}

.mafar-form-submit button:hover,
.mafar-form-submit input[type="submit"]:hover {
  background: #c9a432;
  box-shadow: 0 6px 24px var(--mafar-gold-shadow);
  transform: translateY(-1px);
}

.mafar-form-note {
  font-size: 0.78rem;
  color: var(--text-tertiary);
  margin-top: 14px;
  text-align: center;
  line-height: 1.5;
}

@media (max-width: 900px) {
  .mafar-combined-forms-grid {
    grid-template-columns: 1fr;
    gap: 48px;
  }
  
  .mafar-combined-forms {
    padding: 80px 0;
  }
}

@media (max-width: 560px) {
  .mafar-form-row {
    grid-template-columns: 1fr;
  }
  .mafar-combined-form-card {
    padding: 28px 22px;
  }
  .mafar-form-radio-option {
    min-width: 100%;
  }
  .mafar-combined-forms {
    padding: 60px 0;
  }
}

/* ============================================================
   BLOCK 4: WHAT HAPPENS NEXT + CTA
   ============================================================ */

.mafar-next-steps {
  font-family: var(--font-primary);
  background: var(--mafar-black);
  padding: 100px 0;
  position: relative;
  overflow: hidden;
}

.mafar-next-steps::before {
  content: '';
  position: absolute;
  inset: 0;
  background-image:
    linear-gradient(rgba(255,255,255,0.02) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255,255,255,0.02) 1px, transparent 1px);
  background-size: 60px 60px;
  pointer-events: none;
}

.mafar-next-steps-glow {
  position: absolute;
  bottom: -200px;
  left: 50%;
  transform: translateX(-50%);
  width: 900px;
  height: 500px;
  border-radius: 50%;
  background: radial-gradient(circle, rgba(212,175,55,0.06) 0%, transparent 60%);
  pointer-events: none;
}

.mafar-next-steps .mafar-container {
  max-width: 1100px;
  margin: 0 auto;
  padding: 0 5%;
  position: relative;
  z-index: 2;
}

.mafar-next-steps-header {
  text-align: center;
  margin-bottom: 60px;
}

.mafar-next-steps-header-label {
  font-size: 0.75rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.15em;
  color: var(--mafar-gold);
  margin-bottom: 12px;
}

.mafar-next-steps-header h2 {
  font-family: var(--font-serif);
  font-size: clamp(1.8rem, 3.5vw, 2.4rem);
  font-weight: 400;
  color: var(--mafar-white);
  line-height: 1.2;
  margin-bottom: 14px;
}

.mafar-next-steps-header h2 em {
  font-style: normal;
  color: var(--mafar-gold);
}

.mafar-next-steps-header p {
  font-size: 1rem;
  line-height: 1.7;
  color: var(--text-tertiary);
  max-width: 580px;
  margin: 0 auto;
}

.mafar-next-steps-timeline {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 0;
  position: relative;
}

/* Connecting line */
.mafar-next-steps-timeline::before {
  content: '';
  position: absolute;
  top: 32px;
  left: calc(12.5%);
  right: calc(12.5%);
  height: 2px;
  background: linear-gradient(90deg, var(--mafar-gold), rgba(212,175,55,0.3));
}

.mafar-next-step-item {
  text-align: center;
  position: relative;
  padding: 0 16px;
}

.mafar-next-step-number {
  width: 64px;
  height: 64px;
  border-radius: 50%;
  background: var(--mafar-black);
  border: 2px solid var(--mafar-gold);
  display: flex;
  align-items: center;
  justify-content: center;
  margin: 0 auto 24px;
  position: relative;
  z-index: 2;
}

.mafar-next-step-number span {
  font-family: var(--font-serif);
  font-size: 1.3rem;
  color: var(--mafar-gold);
}

.mafar-next-step-item h4 {
  font-family: var(--font-primary);
  font-size: 1rem;
  font-weight: 600;
  color: var(--mafar-white);
  margin-bottom: 10px;
}

.mafar-next-step-item p {
  font-size: 0.88rem;
  line-height: 1.6;
  color: var(--text-tertiary);
}

/* Bottom CTA */
.mafar-next-steps-cta {
  text-align: center;
  margin-top: 72px;
  padding-top: 48px;
  border-top: 1px solid rgba(255,255,255,0.06);
}

.mafar-next-steps-cta p {
  font-family: var(--font-serif);
  font-size: 1.3rem;
  font-style: italic;
  color: rgba(255,255,255,0.6);
  margin-bottom: 28px;
  line-height: 1.5;
}

.mafar-next-steps-cta-links {
  display: flex;
  justify-content: center;
  gap: 20px;
  flex-wrap: wrap;
}

.mafar-next-steps-cta-links a {
  font-family: var(--font-primary);
  font-size: 0.92rem;
  font-weight: 600;
  padding: 14px 32px;
  border-radius: var(--radius-btn);
  text-decoration: none;
  transition: all 0.3s;
  display: inline-block;
}

.mafar-btn-gold {
  background: var(--mafar-gold);
  color: var(--mafar-black);
}

.mafar-btn-gold:hover {
  background: #c9a432;
  box-shadow: 0 6px 24px var(--mafar-gold-shadow);
  transform: translateY(-1px);
}

.mafar-btn-outline {
  background: transparent;
  color: var(--mafar-white);
  border: 1.5px solid rgba(255,255,255,0.2);
}

.mafar-btn-outline:hover {
  border-color: var(--mafar-gold);
  color: var(--mafar-gold);
}

@media (max-width: 768px) {
  .mafar-next-steps-timeline {
    grid-template-columns: 1fr 1fr;
    gap: 40px 20px;
  }
  .mafar-next-steps-timeline::before {
    display: none;
  }
  .mafar-next-steps-cta p {
    font-size: 1.1rem;
  }
}

@media (max-width: 480px) {
  .mafar-next-steps-timeline {
    grid-template-columns: 1fr;
    gap: 36px;
  }
  .mafar-next-steps {
    padding: 80px 0;
  }
  .mafar-next-steps-cta-links {
    flex-direction: column;
    align-items: center;
  }
  .mafar-next-steps-cta-links a {
    width: 100%;
    max-width: 300px;
    text-align: center;
  }
}

/* ============================================================
   CONTACT FORM 7 INTEGRATION
   Bridge styles to maintain mafar design with CF7 output
   ============================================================ */

/* CF7 Form Container */
.wpcf7-form {
  width: 100%;
}

/* CF7 form control wrappers inherit mafar grid structure */
.wpcf7-form .mafar-form-row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 16px;
  margin-bottom: 16px;
}

.wpcf7-form .mafar-form-group {
  display: flex;
  flex-direction: column;
}

.wpcf7-form .mafar-form-group.full-width {
  grid-column: 1 / -1;
}

/* CF7 Input styling - inherit from mafar form styles */
.wpcf7-form-control-wrap {
  display: flex;
  flex-direction: column;
}

.wpcf7-form input[type="text"],
.wpcf7-form input[type="email"],
.wpcf7-form input[type="tel"],
.wpcf7-form select,
.wpcf7-form textarea {
  font-family: var(--font-primary);
  font-size: 0.92rem;
  padding: 12px 16px;
  border: 1px solid var(--border-default);
  border-radius: 10px;
  background: var(--mafar-white);
  color: var(--text-primary);
  transition: border-color 0.2s;
  outline: none;
  width: 100%;
}

/* Focus states */
.wpcf7-form input:focus,
.wpcf7-form select:focus,
.wpcf7-form textarea:focus {
  border-color: var(--mafar-gold);
  box-shadow: 0 0 0 3px var(--mafar-gold-shadow);
}

/* Placeholder styling */
.wpcf7-form input::placeholder,
.wpcf7-form textarea::placeholder {
  color: var(--text-tertiary);
}

/* Textarea specific */
.wpcf7-form textarea {
  resize: vertical;
  min-height: 110px;
}

/* Select dropdown styling */
.wpcf7-form select {
  appearance: none;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='16' height='16' viewBox='0 0 24 24' fill='none' stroke='%2394a3b8' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='m6 9 6 6 6-6'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 14px center;
  padding-right: 40px;
}

/* Validation error states */
.wpcf7-form .wpcf7-not-valid {
  border-color: #ef4444 !important;
}

.wpcf7-form .wpcf7-not-valid-tip {
  font-size: 0.8rem;
  color: #ef4444;
  margin-top: 4px;
  display: block;
}

/* Radio button styling */
.wpcf7-form .mafar-form-radio-group {
  display: flex;
  gap: 12px;
  flex-wrap: wrap;
}

.wpcf7-radio {
  display: flex;
  gap: 12px;
  flex-wrap: wrap;
}

.wpcf7-radio .wpcf7-list-item {
  margin: 0;
  padding: 0;
}

.wpcf7-radio .wpcf7-list-item label {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 10px 18px;
  border: 1px solid var(--border-default);
  border-radius: 10px;
  cursor: pointer;
  transition: all 0.2s;
  flex: 1;
  min-width: 160px;
  font-size: 0.88rem;
  font-weight: 500;
  color: var(--text-primary);
}

.wpcf7-radio .wpcf7-list-item label:hover {
  border-color: var(--mafar-gold);
  background: var(--mafar-gold-light);
}

.wpcf7-radio input[type="radio"] {
  width: 16px;
  height: 16px;
  accent-color: var(--mafar-gold);
  margin: 0;
}

/* Submit button styling - SCOPED BY FORM TYPE */

/* Partnership form - gold button */
.mafar-partner-form-card .wpcf7-submit {
  font-family: var(--font-primary);
  font-size: 0.95rem;
  font-weight: 600;
  padding: 14px 36px;
  background: var(--mafar-gold);
  color: var(--mafar-black);
  border: none;
  border-radius: var(--radius-btn);
  cursor: pointer;
  transition: all 0.3s;
  width: 100%;
}

.mafar-partner-form-card .wpcf7-submit:hover {
  background: #c9a432;
  box-shadow: 0 6px 24px var(--mafar-gold-shadow);
  transform: translateY(-1px);
}

/* General form - dark button */
.mafar-general-form-card .wpcf7-submit {
  font-family: var(--font-primary);
  font-size: 0.95rem;
  font-weight: 600;
  padding: 14px 36px;
  background: var(--mafar-black);
  color: var(--mafar-white);
  border: none;
  border-radius: var(--radius-btn);
  cursor: pointer;
  transition: all 0.3s;
  width: 100%;
}

.mafar-general-form-card .wpcf7-submit:hover {
  background: #2d2d2d;
  box-shadow: 0 6px 24px rgba(0,0,0,0.15);
  transform: translateY(-1px);
}

/* Response output styling */
.wpcf7-response-output {
  margin: 20px 0 0;
  padding: 12px 20px;
  border-radius: 10px;
  font-size: 0.9rem;
  border-width: 1px;
  border-style: solid;
}

.wpcf7-response-output.wpcf7-mail-sent-ok {
  border-color: #22c55e;
  background: #f0fdf4;
  color: #166534;
}

.wpcf7-response-output.wpcf7-validation-errors {
  border-color: #ef4444;
  background: #fef2f2;
  color: #991b1b;
}

.wpcf7-response-output.wpcf7-spam-blocked {
  border-color: #f59e0b;
  background: #fffbeb;
  color: #92400e;
}

/* AJAX loader styling */
.wpcf7-spinner {
  margin-left: 10px;
  width: 20px;
  height: 20px;
  border: 2px solid var(--border-default);
  border-top-color: var(--mafar-gold);
  border-radius: 50%;
  display: inline-block;
  animation: wpcf7-spinner-rotate 1s linear infinite;
}

@keyframes wpcf7-spinner-rotate {
  from { transform: rotate(0deg); }
  to { transform: rotate(360deg); }
}

/* Form note styling */
.wpcf7-form .mafar-form-note {
  font-size: 0.78rem;
  color: var(--text-tertiary);
  margin-top: 14px;
  text-align: center;
  line-height: 1.5;
}

/* CF7 Responsive adjustments */
@media (max-width: 560px) {
  .wpcf7-form .mafar-form-row {
    grid-template-columns: 1fr;
  }
  
  .wpcf7-radio .wpcf7-list-item label {
    min-width: 100%;
  }
}

