/*
Theme Name: Ali Balhaf Law Firm
Theme URI: https://alibalhaflawcom.com/
Author: Ali Balhaf Law Firm
Description: Custom WordPress theme converted from the existing Ali Balhaf Law Firm static website.
Version: 1.0.0
Text Domain: balhaf
*/

:root {
  --ink: #171717;
  --charcoal: #242323;
  --soft-black: #101010;
  --ivory: #f8f4ea;
  --paper: #fffaf0;
  --muted: #6d675e;
  --line: rgba(23, 23, 23, 0.14);
  --gold: #b58a42;
  --gold-dark: #7f642e;
  --white: #ffffff;
  --max: 1180px;
  --top-contact-height: 34px;
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  background: var(--ivory);
  color: var(--ink);
  font-family: Inter, Arial, sans-serif;
  line-height: 1.65;
}

a {
  color: inherit;
  text-decoration: none;
}

img {
  display: block;
  max-width: 100%;
}

.top-contact-bar {
  position: fixed;
  z-index: 40;
  top: 0;
  left: 0;
  right: 0;
  min-height: var(--top-contact-height);
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: clamp(14px, 3vw, 30px);
  padding: 6px clamp(20px, 5vw, 64px);
  background: var(--soft-black);
  color: rgba(255, 255, 255, 0.82);
  font-size: 12px;
  font-weight: 600;
}

.top-contact-bar a,
.footer-contact a {
  display: inline-flex;
  align-items: center;
  gap: 8px;
}

.top-contact-bar svg,
.footer-contact svg {
  width: 15px;
  height: 15px;
  flex: 0 0 15px;
  fill: none;
  stroke: currentColor;
  stroke-linecap: round;
  stroke-linejoin: round;
  stroke-width: 1.8;
}

.top-contact-bar a:hover,
.footer-contact a:hover {
  color: var(--gold);
}

.site-header {
  position: fixed;
  z-index: 20;
  top: var(--top-contact-height);
  left: 0;
  right: 0;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  padding: 22px clamp(20px, 5vw, 64px);
  color: var(--white);
  background: linear-gradient(180deg, rgba(0, 0, 0, 0.72), rgba(0, 0, 0, 0));
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 0;
  min-width: 0;
}

.brand-mark {
  display: grid;
  width: 44px;
  height: 44px;
  place-items: center;
}

.brand-mark {
  border: 1px solid rgba(255, 255, 255, 0.55);
  color: var(--gold);
  font-family: "Cormorant Garamond", Georgia, serif;
  font-size: 19px;
  font-weight: 700;
}

.brand-logo {
  display: block;
  width: 230px;
  height: 120px;
  padding: 0;
  overflow: visible;
  flex: 0 0 230px;
}

.brand-logo img {
  display: block;
  width: 100%;
  height: 100%;
  max-width: 100%;
  max-height: 100%;
  object-fit: contain;
}

.brand strong,
.brand small {
  display: block;
  line-height: 1.15;
}

.brand strong {
  font-family: "Cormorant Garamond", Georgia, serif;
  font-size: 23px;
  letter-spacing: 0;
}

.brand small {
  color: rgba(255, 255, 255, 0.72);
  font-size: 12px;
  font-weight: 600;
  text-transform: uppercase;
}

.nav-links {
  display: flex;
  align-items: center;
  gap: clamp(14px, 2.8vw, 34px);
  font-size: 13px;
  font-weight: 700;
  letter-spacing: 0;
  text-transform: uppercase;
}

.nav-links ul {
  display: flex;
  align-items: center;
  gap: clamp(14px, 2.8vw, 34px);
  margin: 0;
  padding: 0;
  list-style: none;
}

.nav-links li {
  margin: 0;
  padding: 0;
}

.nav-links a {
  color: rgba(255, 255, 255, 0.86);
}

.nav-links a:hover {
  color: var(--white);
}

.hero {
  position: relative;
  min-height: 92vh;
  display: grid;
  align-items: center;
  overflow: hidden;
  color: var(--white);
  padding: 250px clamp(20px, 6vw, 84px) 92px;
}

.hero-media,
.hero-overlay {
  position: absolute;
  inset: 0;
}

.hero-media img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.hero-overlay {
  background:
    linear-gradient(90deg, rgba(0, 0, 0, 0.84), rgba(0, 0, 0, 0.42) 46%, rgba(0, 0, 0, 0.2)),
    linear-gradient(180deg, rgba(0, 0, 0, 0.38), rgba(0, 0, 0, 0.74));
}

.hero-content {
  position: relative;
  z-index: 1;
  max-width: 760px;
}

.eyebrow,
.section-kicker,
.statement-label {
  margin: 0 0 18px;
  color: var(--gold);
  font-size: 12px;
  font-weight: 800;
  letter-spacing: 0.16em;
  text-transform: uppercase;
}

h1,
h2,
h3 {
  margin: 0;
  font-family: "Cormorant Garamond", Georgia, serif;
  font-weight: 600;
  line-height: 1.04;
  letter-spacing: 0;
}

h1 {
  max-width: 720px;
  font-size: clamp(54px, 9vw, 110px);
}

h2 {
  color: var(--ink);
  font-size: clamp(34px, 5vw, 62px);
}

h3 {
  font-size: 31px;
}

.hero-content p:not(.eyebrow) {
  max-width: 580px;
  margin: 24px 0 0;
  color: rgba(255, 255, 255, 0.82);
  font-size: clamp(17px, 2vw, 21px);
}

.hero-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 14px;
  margin-top: 38px;
}

.button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 50px;
  padding: 13px 22px;
  border: 1px solid rgba(255, 255, 255, 0.34);
  font-size: 13px;
  font-weight: 800;
  letter-spacing: 0.06em;
  text-transform: uppercase;
}

.button.primary {
  border-color: var(--gold);
  background: var(--gold);
  color: var(--soft-black);
}

.button.secondary {
  color: var(--white);
}

[data-reveal] {
  opacity: 0;
  transform: translateY(76px) scale(0.96);
  transition:
    opacity 900ms cubic-bezier(0.2, 0.75, 0.18, 1),
    transform 900ms cubic-bezier(0.2, 0.75, 0.18, 1);
  transition-delay: var(--reveal-delay, 0ms);
  will-change: opacity, transform;
}

[data-reveal].is-visible {
  opacity: 1;
  transform: translateY(0) scale(1);
}

.hero-content .eyebrow,
.hero-content h1,
.hero-content p:not(.eyebrow),
.hero-actions {
  opacity: 0;
  animation: heroSlideIn 950ms cubic-bezier(0.2, 0.75, 0.18, 1) forwards;
}

.hero-content h1 {
  animation-delay: 130ms;
}

.hero-content p:not(.eyebrow) {
  animation-delay: 260ms;
}

.hero-actions {
  animation-delay: 390ms;
}

@keyframes heroSlideIn {
  from {
    opacity: 0;
    transform: translateY(46px);
  }

  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.motion-ready .motion-child {
  opacity: 0;
  transform: translateY(48px);
  transition:
    opacity 780ms cubic-bezier(0.2, 0.75, 0.18, 1),
    transform 780ms cubic-bezier(0.2, 0.75, 0.18, 1);
  transition-delay: var(--motion-delay, 0ms);
}

.motion-ready .is-visible .motion-child,
.motion-ready .motion-child.is-visible {
  opacity: 1;
  transform: translateY(0);
}

.hero-media img,
.debt-visual img {
  transform: translateY(var(--image-shift, 0)) scale(1.06);
  transition: transform 180ms linear;
  will-change: transform;
}

.team-photo img {
  transition: transform 180ms linear;
}

.practice-card,
.intro-item {
  --tilt-x: 0deg;
  --tilt-y: 0deg;
  --card-lift: 0px;
  transition:
    opacity 900ms cubic-bezier(0.2, 0.75, 0.18, 1),
    transform 220ms ease,
    background-color 220ms ease,
    box-shadow 220ms ease;
}

.practice-card.is-visible,
.intro-item.is-visible {
  transform: perspective(900px) rotateX(var(--tilt-x)) rotateY(var(--tilt-y)) translateY(var(--card-lift));
}

.practice-card:hover,
.intro-item:hover {
  --card-lift: -10px;
}

.practice-card:hover {
  background: rgba(255, 255, 255, 0.62);
  box-shadow: 0 26px 58px rgba(23, 23, 23, 0.16);
}

.intro-item:hover {
  background: rgba(255, 255, 255, 0.06);
}

.intro-band {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  background: var(--soft-black);
  color: var(--white);
  border-top: 1px solid rgba(255, 255, 255, 0.12);
}

.intro-item {
  min-height: 190px;
  padding: clamp(26px, 4vw, 46px);
  border-right: 1px solid rgba(255, 255, 255, 0.12);
}

.intro-item:last-child {
  border-right: 0;
}

.intro-item span,
.practice-card span {
  color: var(--gold);
  font-family: "Cormorant Garamond", Georgia, serif;
  font-size: 30px;
  font-weight: 700;
}

.intro-item strong {
  display: block;
  margin-top: 12px;
  font-family: "Cormorant Garamond", Georgia, serif;
  font-size: 29px;
  line-height: 1.12;
}

.intro-item p,
.section-heading p,
.body-copy p,
.practice-card p,
.site-footer p,
.footer-contact {
  color: var(--muted);
}

.intro-item p {
  margin: 12px 0 0;
  color: rgba(255, 255, 255, 0.66);
}

.section {
  max-width: var(--max);
  margin: 0 auto;
  padding: clamp(74px, 10vw, 132px) clamp(20px, 5vw, 44px);
}

.split {
  display: grid;
  grid-template-columns: minmax(0, 0.92fr) minmax(0, 1.08fr);
  gap: clamp(34px, 7vw, 92px);
  align-items: start;
}

.body-copy p {
  margin: 0 0 20px;
  font-size: 16px;
}

.body-copy p:last-child {
  margin-bottom: 0;
}

.about-section {
  border-bottom: 1px solid var(--line);
}

.team-section {
  max-width: none;
  padding-left: 0;
  padding-right: 0;
}

.team-section > .section-kicker,
.team-layout {
  max-width: var(--max);
  margin-left: auto;
  margin-right: auto;
}

.team-section > .section-kicker {
  padding-left: clamp(20px, 5vw, 44px);
  padding-right: clamp(20px, 5vw, 44px);
}

.team-layout {
  display: grid;
  grid-template-columns: minmax(300px, 0.9fr) minmax(0, 1.1fr);
  gap: clamp(34px, 6vw, 78px);
  align-items: stretch;
  padding-left: clamp(20px, 5vw, 44px);
  padding-right: clamp(20px, 5vw, 44px);
}

.team-photo {
  position: relative;
  min-height: 0;
  overflow: hidden;
  aspect-ratio: 2 / 3;
  background: transparent;
}

.team-photo img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  min-height: 0;
  object-fit: cover;
  object-position: center bottom;
}

.team-copy h2 {
  margin-bottom: 28px;
}

.statement {
  background: var(--charcoal);
  color: var(--white);
  padding: clamp(72px, 9vw, 118px) clamp(20px, 6vw, 84px);
}

.statement > div {
  max-width: 1040px;
  margin: 0 auto;
}

.statement h2 {
  max-width: 930px;
  color: var(--white);
}

.section-heading {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 360px;
  gap: 40px;
  align-items: end;
  margin-bottom: 44px;
}

.section-heading p {
  margin: 0;
}

.practice-section {
  max-width: none;
  background: var(--paper);
}

.practice-section > * {
  max-width: var(--max);
  margin-left: auto;
  margin-right: auto;
}

.practice-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  border-top: 1px solid var(--line);
  border-left: 1px solid var(--line);
}

.practice-card {
  min-height: 330px;
  padding: clamp(28px, 3vw, 40px);
  border-right: 1px solid var(--line);
  border-bottom: 1px solid var(--line);
  background: rgba(255, 255, 255, 0.38);
}

.practice-card h3 {
  margin-top: 28px;
}

.practice-card p {
  margin: 20px 0 0;
}

.debt-section {
  padding-top: 0;
}

.debt-panel {
  display: grid;
  grid-template-columns: minmax(0, 0.9fr) minmax(0, 1.1fr);
  align-items: stretch;
  border: 1px solid var(--line);
  background: var(--white);
}

.debt-visual {
  position: relative;
  min-height: 100%;
  overflow: hidden;
  background: var(--charcoal);
}

.debt-visual::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg, rgba(0, 0, 0, 0.34), rgba(0, 0, 0, 0.72));
}

.debt-visual img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.debt-visual-copy {
  position: relative;
  z-index: 1;
  display: flex;
  min-height: 100%;
  flex-direction: column;
  justify-content: flex-start;
  padding: clamp(34px, 5vw, 58px);
}

.debt-visual-copy h2 {
  color: var(--white);
}

.debt-panel .body-copy {
  padding: clamp(34px, 5vw, 58px);
}

.site-footer {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(260px, 360px);
  gap: 40px;
  padding: clamp(46px, 7vw, 76px) clamp(20px, 6vw, 84px);
  background: var(--soft-black);
  color: var(--white);
}

.site-footer > div {
  max-width: 760px;
}

.footer-brand {
  margin-bottom: 22px;
}

.site-footer p {
  max-width: 620px;
  margin: 0;
  color: rgba(255, 255, 255, 0.68);
}

.footer-contact {
  display: grid;
  gap: 10px;
  justify-items: start;
  color: rgba(255, 255, 255, 0.68);
}

.footer-contact p {
  color: var(--gold);
  font-size: 12px;
  font-weight: 800;
  letter-spacing: 0.16em;
  text-transform: uppercase;
}

.whatsapp-float {
  position: fixed;
  z-index: 50;
  right: 22px;
  bottom: 22px;
  display: grid;
  width: 54px;
  height: 54px;
  place-items: center;
  border-radius: 50%;
  background: transparent;
  box-shadow: 0 18px 38px rgba(0, 0, 0, 0.28);
}

.whatsapp-float img {
  width: 54px;
  height: 54px;
  object-fit: contain;
}

@media (max-width: 900px) {
  body {
    padding-bottom: 58px;
  }

  .top-contact-bar {
    justify-content: center;
    gap: 8px 14px;
    padding: 6px 12px;
    font-size: 10px;
  }

  .site-header {
    position: fixed;
    display: flex;
    flex-wrap: nowrap;
    align-items: center;
    padding: 14px 18px;
    background: rgba(0, 0, 0, 0.84);
  }

  .nav-links {
    position: fixed;
    left: 0;
    right: 0;
    bottom: 0;
    z-index: 30;
    display: flex !important;
    flex-wrap: nowrap;
    justify-content: space-around;
    align-items: center;
    gap: 0;
    max-width: none;
    width: 100%;
    margin: 0;
    padding: 10px 8px;
    border-top: 1px solid rgba(181, 138, 66, 0.42);
    background: rgba(16, 16, 16, 0.98);
  }

  .nav-links ul {
    width: 100%;
    justify-content: space-around;
    gap: 0;
  }

  .nav-links li {
    flex: 1 1 0;
    min-width: 0;
  }

  .whatsapp-float {
    right: 14px;
    bottom: 74px;
    width: 48px;
    height: 48px;
  }

  .whatsapp-float img {
    width: 48px;
    height: 48px;
  }

  .nav-links a {
    display: block;
    min-width: 0;
    padding: 8px 6px;
    border-bottom: 0;
    color: var(--white);
    font-size: 10px;
    line-height: 1.2;
    text-align: center;
    white-space: nowrap;
  }

  .intro-band,
  .practice-grid,
  .split,
  .team-layout,
  .section-heading,
  .debt-panel,
  .site-footer {
    grid-template-columns: 1fr;
  }

  .intro-item {
    border-right: 0;
    border-bottom: 1px solid rgba(255, 255, 255, 0.12);
  }

  .section-heading {
    align-items: start;
  }

  .team-photo {
    aspect-ratio: 2 / 3;
  }

  .debt-visual {
    min-height: 360px;
  }
}

@media (max-width: 620px) {
  .site-header {
    padding: 12px 14px;
  }

  .brand {
    min-width: 0;
  }

  .hero {
    min-height: 760px;
    padding: 220px 18px 58px;
  }

  h1 {
    font-size: 52px;
  }

  h2 {
    font-size: 37px;
  }

  .hero-actions {
    display: grid;
  }

  .button {
    width: 100%;
  }

  .section {
    padding-left: 18px;
    padding-right: 18px;
  }

  .team-section {
    padding-left: 0;
    padding-right: 0;
  }

  .team-section > .section-kicker,
  .team-layout {
    padding-left: 18px;
    padding-right: 18px;
  }

  .team-photo,
  .team-photo img {
    min-height: 0;
  }

  .debt-panel {
    padding: 0;
  }

  .debt-panel .body-copy {
    padding: 28px 22px;
  }

  .debt-visual {
    min-height: 340px;
  }

  .debt-visual-copy {
    padding: 28px 22px;
  }
}

@media (prefers-reduced-motion: reduce) {
  html {
    scroll-behavior: auto;
  }

  [data-reveal],
  .motion-ready .motion-child,
  .hero-content .eyebrow,
  .hero-content h1,
  .hero-content p:not(.eyebrow),
  .hero-actions,
  .hero-media img,
  .debt-visual img,
  .practice-card,
  .intro-item {
    opacity: 1;
    transform: none;
    animation: none;
    transition: none;
  }
}

.strong-title {
  font-weight: 900;
}
