/* ═══════════════════════════════════════════════
   Magni Realty — TurboHome-inspired theme
   ═══════════════════════════════════════════════ */

/* ── Reset & base ── */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

:root {
  --green:        #16a34a;
  --green-dark:   #15803d;
  --green-light:  #dcfce7;
  --navy:         #0f172a;
  --navy-mid:     #1e293b;
  --slate:        #475569;
  --slate-light:  #94a3b8;
  --bg-white:     #ffffff;
  --bg-gray:      #f8fafc;
  --bg-dark:      #0f172a;
  --border:       #e2e8f0;
  --shadow-sm:    0 1px 3px rgba(0,0,0,.08), 0 1px 2px rgba(0,0,0,.06);
  --shadow-md:    0 4px 6px -1px rgba(0,0,0,.1), 0 2px 4px -1px rgba(0,0,0,.06);
  --shadow-lg:    0 10px 15px -3px rgba(0,0,0,.1), 0 4px 6px -2px rgba(0,0,0,.05);
  --radius:       .75rem;
  --radius-sm:    .5rem;
  --font:         'Inter', -apple-system, BlinkMacSystemFont, sans-serif;
}

html { scroll-behavior: smooth; }

body {
  font-family: var(--font);
  color: var(--navy);
  background: var(--bg-white);
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}

img { max-width: 100%; display: block; }
a { text-decoration: none; color: inherit; }

/* ── Layout helpers ── */
.th-container {
  max-width: 1160px;
  margin: 0 auto;
  padding: 0 1.5rem;
}
.th-container--narrow { max-width: 780px; }

/* ── Buttons ── */
.th-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: .5rem;
  font-family: var(--font);
  font-weight: 600;
  font-size: .95rem;
  border-radius: var(--radius-sm);
  cursor: pointer;
  transition: all .2s;
  border: 2px solid transparent;
  white-space: nowrap;
}
.th-btn--sm  { padding: .45rem 1rem; font-size: .875rem; }
.th-btn--lg  { padding: .85rem 2rem; font-size: 1rem; }
.th-btn:not(.th-btn--sm):not(.th-btn--lg) { padding: .6rem 1.4rem; }

.th-btn--primary {
  background: var(--green);
  color: #fff;
  border-color: var(--green);
}
.th-btn--primary:hover { background: var(--green-dark); border-color: var(--green-dark); }

.th-btn--outline {
  background: transparent;
  color: var(--navy);
  border-color: var(--border);
}
.th-btn--outline:hover { border-color: var(--slate); }

/* ── Navbar ── */
.th-nav {
  position: fixed;
  top: 0; left: 0; right: 0;
  z-index: 1000;
  background: rgba(255,255,255,.95);
  backdrop-filter: blur(8px);
  border-bottom: 1px solid transparent;
  transition: border-color .2s, box-shadow .2s;
}
.th-nav--scrolled {
  border-bottom-color: var(--border);
  box-shadow: var(--shadow-sm);
}
.th-nav__inner {
  max-width: 1160px;
  margin: 0 auto;
  padding: 0 1.5rem;
  height: 64px;
  display: flex;
  align-items: center;
  gap: 2rem;
}
.th-nav__brand {
  font-weight: 800;
  font-size: 1.15rem;
  color: var(--navy);
  letter-spacing: -.02em;
  flex-shrink: 0;
}
.th-nav__links {
  display: flex;
  list-style: none;
  gap: .25rem;
  margin-left: auto;
}
.th-nav__links a {
  padding: .4rem .75rem;
  font-size: .9rem;
  font-weight: 500;
  color: var(--slate);
  border-radius: var(--radius-sm);
  transition: color .15s, background .15s;
}
.th-nav__links a:hover { color: var(--navy); background: var(--bg-gray); }

.th-nav__toggle {
  display: none;
  flex-direction: column;
  gap: 5px;
  background: none;
  border: none;
  cursor: pointer;
  margin-left: auto;
  padding: .5rem;
}
.th-nav__toggle span {
  display: block;
  width: 22px; height: 2px;
  background: var(--navy);
  border-radius: 2px;
  transition: all .2s;
}

.th-nav__phone {
  display: flex;
  align-items: center;
  gap: .5rem;
  color: var(--slate);
  margin-left: .75rem;
  white-space: nowrap;
  transition: color .15s;
  text-decoration: none;
}
.th-nav__phone:hover { color: var(--green-dark); }
.th-nav__phone i { font-size: .85rem; }
.th-nav__phone-wrap {
  display: flex;
  flex-direction: column;
}
.th-nav__phone-label {
  font-size: .68rem;
  font-weight: 500;
  color: var(--slate-light);
  line-height: 1;
}
.th-nav__phone-number {
  font-size: .82rem;
  font-weight: 700;
  color: var(--navy);
  line-height: 1.3;
}
.th-nav__phone:hover .th-nav__phone-number,
.th-nav__phone:hover .th-nav__phone-label { color: var(--green-dark); }

@media (max-width: 768px) {
  .th-nav__toggle { display: flex; }
  .th-nav__cta { display: none; }
  .th-nav__phone { display: none; }
  .th-nav__links {
    display: none;
    position: absolute;
    top: 64px; left: 0; right: 0;
    background: #fff;
    border-bottom: 1px solid var(--border);
    flex-direction: column;
    padding: 1rem 1.5rem;
    gap: 0;
    margin-left: 0;
  }
  .th-nav__links.is-open { display: flex; }
  .th-nav__links a { display: block; padding: .65rem .75rem; }
}

/* ── Hero ── */
.th-hero {
  padding: 7rem 0 5rem;
  background: linear-gradient(160deg, #f0fdf4 0%, #fff 55%);
  text-align: center;
}
.th-hero__eyebrow {
  display: inline-block;
  background: var(--green-light);
  color: var(--green-dark);
  font-size: .8rem;
  font-weight: 700;
  letter-spacing: .06em;
  text-transform: uppercase;
  padding: .35rem .9rem;
  border-radius: 999px;
  margin-bottom: 1.5rem;
}
.th-hero__headline {
  font-size: clamp(2.2rem, 5vw, 3.75rem);
  font-weight: 800;
  line-height: 1.1;
  letter-spacing: -.03em;
  color: var(--navy);
  margin-bottom: 1.25rem;
}
.th-hero__sub {
  max-width: 580px;
  margin: 0 auto 2.5rem;
  font-size: 1.1rem;
  color: var(--slate);
  line-height: 1.7;
}
.th-hero__actions {
  display: flex;
  gap: 1rem;
  justify-content: center;
  flex-wrap: wrap;
  margin-bottom: 4rem;
}
.th-hero__stats {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0;
  flex-wrap: wrap;
  background: #fff;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  box-shadow: var(--shadow-sm);
  padding: 1.5rem 2rem;
  max-width: 680px;
  margin: 0 auto;
}
.th-stat {
  display: flex;
  flex-direction: column;
  align-items: center;
  padding: .5rem 2rem;
}
.th-stat__num {
  font-size: 1.75rem;
  font-weight: 800;
  color: var(--navy);
  letter-spacing: -.03em;
}
.th-stat__label {
  font-size: .78rem;
  color: var(--slate-light);
  font-weight: 500;
  margin-top: .1rem;
}
.th-stat__divider {
  width: 1px;
  height: 40px;
  background: var(--border);
}
@media (max-width: 600px) {
  .th-stat__divider { display: none; }
  .th-hero__stats { gap: 1rem; }
}

/* ── Sections ── */
.th-section { padding: 5rem 0; }
.th-section--gray { background: var(--bg-gray); }
.th-section--dark {
  background: var(--bg-dark);
  color: #fff;
}
.th-section__header {
  text-align: center;
  margin-bottom: 3.5rem;
}
.th-section__header h2 {
  font-size: clamp(1.6rem, 3vw, 2.25rem);
  font-weight: 800;
  letter-spacing: -.03em;
  margin-bottom: .5rem;
}
.th-section__header p {
  color: var(--slate);
  font-size: 1rem;
  max-width: 480px;
  margin: 0 auto;
}
.th-section__eyebrow {
  display: inline-block;
  color: var(--green);
  font-size: .8rem;
  font-weight: 700;
  letter-spacing: .06em;
  text-transform: uppercase;
  margin-bottom: .75rem;
}

/* ── How It Works steps ── */
.th-steps {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 1.5rem;
}
@media (max-width: 900px) { .th-steps { grid-template-columns: repeat(2, 1fr); } }
@media (max-width: 500px) { .th-steps { grid-template-columns: 1fr; } }

.th-step {
  background: #fff;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 2rem 1.5rem;
  text-align: center;
  box-shadow: var(--shadow-sm);
  transition: box-shadow .2s, transform .2s;
}
.th-step:hover { box-shadow: var(--shadow-md); transform: translateY(-2px); }
.th-step__icon {
  width: 52px; height: 52px;
  background: var(--green-light);
  color: var(--green-dark);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.2rem;
  margin: 0 auto 1.25rem;
}
.th-step h3 {
  font-size: 1rem;
  font-weight: 700;
  margin-bottom: .5rem;
  color: var(--navy);
}
.th-step p { font-size: .9rem; color: var(--slate); line-height: 1.6; }

/* ── About ── */
.th-about {
  display: grid;
  grid-template-columns: 300px 1fr;
  gap: 4rem;
  align-items: center;
}
@media (max-width: 768px) {
  .th-about { grid-template-columns: 1fr; gap: 2.5rem; }
}
.th-about__image-wrap { display: flex; justify-content: center; }
.th-about__photo {
  width: 260px;
  height: 320px;
  object-fit: cover;
  object-position: center top;
  border-radius: var(--radius);
  box-shadow: var(--shadow-lg);
}

.th-about__image-placeholder {
  width: 260px; height: 320px;
  background: var(--bg-gray);
  border: 2px dashed var(--border);
  border-radius: var(--radius);
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: .75rem;
  color: var(--slate-light);
  font-size: .85rem;
}
.th-about__image-placeholder i { font-size: 3rem; }
.th-about h2 {
  font-size: 2rem;
  font-weight: 800;
  letter-spacing: -.03em;
  margin-bottom: .25rem;
}
.th-about__role {
  color: var(--slate);
  font-size: .9rem;
  margin-bottom: 1rem;
}
.th-about__badges {
  display: flex;
  flex-wrap: wrap;
  gap: .5rem;
  margin-bottom: 1.5rem;
}
.th-badge {
  background: var(--green-light);
  color: var(--green-dark);
  font-size: .75rem;
  font-weight: 600;
  padding: .3rem .75rem;
  border-radius: 999px;
}
.th-about__quote {
  border-left: 3px solid var(--green);
  padding-left: 1rem;
  color: var(--slate);
  font-size: .95rem;
  line-height: 1.7;
  font-style: italic;
  margin-bottom: 1.75rem;
}

/* ── Testimonials ── */
.th-testimonials {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1.5rem;
}
@media (max-width: 768px) { .th-testimonials { grid-template-columns: 1fr; } }

.th-testimonial {
  background: var(--bg-gray);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 1.75rem;
}
.th-testimonial__stars {
  color: #f59e0b;
  font-size: 1rem;
  margin-bottom: .75rem;
  letter-spacing: .1em;
}
.th-testimonial p {
  font-size: .93rem;
  color: var(--navy);
  line-height: 1.7;
  margin-bottom: 1.25rem;
}
.th-testimonial__author {
  display: flex;
  align-items: center;
  gap: .75rem;
}
.th-testimonial__avatar {
  width: 40px; height: 40px;
  background: var(--green-light);
  color: var(--green-dark);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: .75rem;
  font-weight: 700;
  flex-shrink: 0;
}
.th-testimonial__author strong { display: block; font-size: .9rem; color: var(--navy); }
.th-testimonial__author span { font-size: .8rem; color: var(--slate-light); }

/* ── Why Sarah (dark) ── */
.th-why {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 5rem;
  align-items: center;
}
@media (max-width: 768px) { .th-why { grid-template-columns: 1fr; gap: 2.5rem; } }

.th-why h2 {
  font-size: clamp(1.6rem, 3vw, 2.25rem);
  font-weight: 800;
  letter-spacing: -.03em;
  color: #fff;
  line-height: 1.2;
  margin-bottom: .75rem;
}
.th-why p { color: #94a3b8; font-size: 1rem; }

.th-checklist {
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: .85rem;
}
.th-checklist li {
  display: flex;
  align-items: center;
  gap: .75rem;
  font-size: .95rem;
  color: #e2e8f0;
}
.th-checklist i { color: var(--green); font-size: 1.1rem; flex-shrink: 0; }

/* ── FAQ ── */
.th-faq { display: flex; flex-direction: column; gap: 0; }
.th-faq__item {
  border-bottom: 1px solid var(--border);
}
.th-faq__item:first-child { border-top: 1px solid var(--border); }

.th-faq__q {
  width: 100%;
  background: none;
  border: none;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  padding: 1.25rem 0;
  font-family: var(--font);
  font-size: .97rem;
  font-weight: 600;
  color: var(--navy);
  text-align: left;
}
.th-faq__q i {
  color: var(--slate-light);
  transition: transform .25s;
  flex-shrink: 0;
}
.th-faq__item.is-open .th-faq__q i { transform: rotate(180deg); color: var(--green); }
.th-faq__item.is-open .th-faq__q { color: var(--green-dark); }

.th-faq__a {
  max-height: 0;
  overflow: hidden;
  transition: max-height .35s ease, padding .25s;
}
.th-faq__item.is-open .th-faq__a { max-height: 300px; padding-bottom: 1.25rem; }
.th-faq__a p { font-size: .93rem; color: var(--slate); line-height: 1.75; }

/* ── Contact ── */
.th-contact__cards {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1rem;
  margin-bottom: 2rem;
}
@media (max-width: 600px) { .th-contact__cards { grid-template-columns: 1fr; } }

.th-contact__card {
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 1.75rem 1.25rem;
  text-align: center;
  box-shadow: var(--shadow-sm);
}
.th-contact__card i {
  font-size: 1.5rem;
  color: var(--green);
  margin-bottom: .75rem;
  display: block;
}
.th-contact__card h4 {
  font-size: .8rem;
  font-weight: 700;
  letter-spacing: .06em;
  text-transform: uppercase;
  color: var(--slate-light);
  margin-bottom: .4rem;
}
.th-contact__card p { font-size: .9rem; color: var(--navy); line-height: 1.5; }
.th-contact__card a { color: var(--green-dark); font-weight: 500; }
.th-contact__card a:hover { text-decoration: underline; }

.th-contact__social {
  display: flex;
  gap: .75rem;
  justify-content: center;
}
.th-social-link {
  width: 42px; height: 42px;
  border: 1px solid var(--border);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--slate);
  font-size: 1rem;
  transition: border-color .15s, color .15s, background .15s;
}
.th-social-link:hover { border-color: var(--green); color: var(--green-dark); background: var(--green-light); }

/* ── Modal ── */
.th-modal-overlay {
  display: none;
  position: fixed;
  inset: 0;
  z-index: 2000;
  background: rgba(15, 23, 42, 0.6);
  backdrop-filter: blur(4px);
  align-items: center;
  justify-content: center;
  padding: 1.5rem;
}
.th-modal-overlay.is-open {
  display: flex;
  animation: modalFadeIn .2s ease;
}
@keyframes modalFadeIn {
  from { opacity: 0; }
  to   { opacity: 1; }
}

.th-modal {
  background: #fff;
  border-radius: var(--radius);
  box-shadow: 0 25px 50px -12px rgba(0,0,0,.35);
  padding: 2.5rem;
  width: 100%;
  max-width: 480px;
  position: relative;
  overflow: hidden;
  animation: modalSlideUp .25s ease;
}
@keyframes modalSlideUp {
  from { transform: translateY(16px); opacity: 0; }
  to   { transform: translateY(0);    opacity: 1; }
}

.th-modal__close {
  position: absolute;
  top: 1rem; right: 1rem;
  background: none;
  border: none;
  font-size: 1.5rem;
  line-height: 1;
  color: var(--slate-light);
  cursor: pointer;
  padding: .25rem .5rem;
  border-radius: var(--radius-sm);
  transition: color .15s, background .15s;
}
.th-modal__close:hover { color: var(--navy); background: var(--bg-gray); }

.th-modal__header { margin-bottom: 1.75rem; }
.th-modal__header h2 {
  font-size: 1.5rem;
  font-weight: 800;
  letter-spacing: -.03em;
  color: var(--navy);
  margin-bottom: .35rem;
}
.th-modal__header p { font-size: .9rem; color: var(--slate); }

.th-form-row {
  display: grid;
  grid-template-columns: 1fr;
  gap: 0;
}

.th-form-group {
  display: flex;
  flex-direction: column;
  gap: .4rem;
  margin-bottom: 1rem;
}
.th-form-group label {
  font-size: .82rem;
  font-weight: 600;
  color: var(--navy);
}
.th-form-group input {
  font-family: var(--font);
  font-size: .95rem;
  color: var(--navy);
  background: var(--bg-white);
  border: 1.5px solid var(--border);
  border-radius: var(--radius-sm);
  padding: .65rem .9rem;
  transition: border-color .15s, box-shadow .15s;
  outline: none;
}
.th-form-group input::placeholder { color: var(--slate-light); }
.th-form-group input:focus {
  border-color: var(--green);
  box-shadow: 0 0 0 3px rgba(22,163,74,.12);
}

.th-modal__submit {
  width: 100%;
  margin-top: .5rem;
  padding: .8rem;
  font-size: 1rem;
}

.th-modal__success {
  text-align: center;
  padding: 1.5rem 0 .5rem;
}
.th-modal__success-icon {
  font-size: 3rem;
  color: var(--green);
  margin-bottom: 1rem;
}
.th-modal__success h3 {
  font-size: 1.4rem;
  font-weight: 800;
  color: var(--navy);
  margin-bottom: .4rem;
}
.th-modal__success p { color: var(--slate); font-size: .95rem; }

.th-modal__error {
  margin-top: 1rem;
  padding: .85rem 1rem;
  background: #fef2f2;
  border: 1px solid #fecaca;
  border-radius: var(--radius-sm);
  color: #b91c1c;
  font-size: .85rem;
  text-align: center;
}
.th-modal__error a { color: #b91c1c; font-weight: 700; text-decoration: underline; }

/* ── Footer ── */
.th-footer {
  background: var(--navy);
  color: #94a3b8;
  padding: 2.5rem 0 2rem;
}
.th-footer__top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 2rem;
  flex-wrap: wrap;
  margin-bottom: 1.5rem;
  padding-bottom: 1.5rem;
  border-bottom: 1px solid rgba(255,255,255,.08);
}
.th-footer__brand {
  font-weight: 800;
  font-size: 1.1rem;
  color: #fff;
  letter-spacing: -.02em;
}
.th-footer__links {
  display: flex;
  gap: 1.5rem;
  flex-wrap: wrap;
}
.th-footer__links a {
  font-size: .85rem;
  color: #94a3b8;
  transition: color .15s;
}
.th-footer__links a:hover { color: #fff; }
.th-footer__bottom p { font-size: .82rem; margin-bottom: .3rem; }
.th-footer__legal { color: #475569; }
