/* ============================================
   Murphree Law Firm — Stylesheet
   ============================================ */

:root {
  --navy: #1a3a52;
  --dark-gray: #2d3e50;
  --gold: #d4af37;
  --gold-hover: #c19f2e;
  --light-gray: #f5f5f5;
  --white: #ffffff;
  --text: #2d3e50;
  --text-muted: #6b7280;
  --border: #e5e7eb;
}

* { box-sizing: border-box; margin: 0; padding: 0; }

html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; }

body {
  font-family: 'Inter', system-ui, -apple-system, sans-serif;
  font-size: 16px;
  line-height: 1.6;
  color: var(--text);
  background: var(--white);
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

h1, h2, h3, h4, h5, h6 {
  font-family: 'Merriweather', Georgia, serif;
  font-weight: 700;
  color: var(--navy);
  line-height: 1.2;
}

a { color: var(--gold); text-decoration: none; transition: color .3s ease; }
a:hover { color: var(--navy); }

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

.container {
  max-width: 1280px;
  margin: 0 auto;
  padding: 0 1.25rem;
}

@media (min-width: 640px) { .container { padding: 0 1.5rem; } }
@media (min-width: 1024px) { .container { padding: 0 2rem; } }

/* ============================================
   NAVIGATION
   ============================================ */
.nav {
  position: sticky;
  top: 0;
  z-index: 50;
  background: var(--navy);
  box-shadow: 0 4px 6px -1px rgba(0,0,0,0.1);
}

.nav-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 80px;
  max-width: 1280px;
  margin: 0 auto;
  padding: 0 1.25rem;
}

.nav-logo {
  display: flex;
  align-items: center;
  gap: .5rem;
  color: var(--white);
  font-family: 'Merriweather', serif;
  font-size: 1.5rem;
  font-weight: 700;
}

.nav-logo:hover { color: var(--white); }
.nav-logo svg { width: 32px; height: 32px; color: var(--gold); transition: transform .3s; }
.nav-logo:hover svg { transform: scale(1.1); }

.nav-links {
  display: none;
  align-items: center;
  gap: 2rem;
  list-style: none;
}

.nav-links a {
  color: var(--white);
  font-weight: 500;
  position: relative;
  padding: 4px 0;
  transition: color .3s;
}

.nav-links a:hover, .nav-links a.active { color: var(--gold); }
.nav-links a.active::after {
  content: '';
  position: absolute;
  left: 0; right: 0; bottom: -4px;
  height: 2px;
  background: var(--gold);
}

.nav-cta { display: none; }

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: .5rem;
  font-weight: 600;
  padding: .75rem 1.5rem;
  border-radius: .5rem;
  border: 2px solid transparent;
  cursor: pointer;
  transition: all .3s ease;
  text-align: center;
  line-height: 1.4;
  font-size: 1rem;
}

.btn-gold { background: var(--gold); color: var(--white); box-shadow: 0 4px 6px rgba(0,0,0,.1); }
.btn-gold:hover { background: var(--gold-hover); color: var(--white); transform: scale(1.03); }

.btn-navy { background: var(--navy); color: var(--white); }
.btn-navy:hover { background: var(--dark-gray); color: var(--white); transform: scale(1.03); }

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

.btn-lg { padding: 1rem 2rem; font-size: 1.125rem; }

.nav-toggle {
  display: flex;
  background: transparent;
  border: 0;
  color: var(--white);
  cursor: pointer;
  padding: .5rem;
}
.nav-toggle svg { width: 24px; height: 24px; }
.nav-toggle:hover { color: var(--gold); }

.mobile-menu {
  display: none;
  background: var(--dark-gray);
  padding: 1rem 1.25rem;
}
.mobile-menu.open { display: block; }
.mobile-menu a {
  display: block;
  color: var(--white);
  font-weight: 500;
  padding: .75rem 1rem;
  border-radius: .5rem;
  margin-bottom: .25rem;
  transition: all .3s;
}
.mobile-menu a:hover, .mobile-menu a.active { background: var(--navy); color: var(--gold); }
.mobile-menu .btn { width: 100%; margin-top: .5rem; }

@media (min-width: 768px) {
  .nav-links, .nav-cta { display: flex; }
  .nav-toggle { display: none; }
  .mobile-menu { display: none !important; }
}

/* ============================================
   HERO
   ============================================ */
.hero {
  position: relative;
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
  color: var(--white);
}

.hero-bg {
  position: absolute;
  inset: 0;
  z-index: 0;
}
.hero-bg img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}
.hero-overlay {
  position: absolute;
  inset: 0;
  background: linear-gradient(to right, rgba(26,58,82,.95), rgba(26,58,82,.85) 50%, rgba(26,58,82,.75));
}

.hero-content {
  position: relative;
  z-index: 2;
  text-align: center;
  padding: 4rem 1.25rem;
  max-width: 1024px;
}

.hero h1 {
  font-size: clamp(2.5rem, 6vw, 4.5rem);
  color: var(--white);
  margin-bottom: 1.5rem;
  font-weight: 700;
  letter-spacing: -.02em;
}

.hero-subtitle {
  font-size: clamp(1.125rem, 2vw, 1.5rem);
  font-weight: 300;
  margin-bottom: 2rem;
  color: rgba(255,255,255,.9);
}

.hero-fade {
  position: absolute;
  left: 0; right: 0; bottom: 0;
  height: 8rem;
  background: linear-gradient(to top, var(--white), transparent);
  z-index: 1;
  pointer-events: none;
}

/* ============================================
   PAGE HEADER (interior pages)
   ============================================ */
.page-header {
  background: var(--navy);
  color: var(--white);
  padding: 5rem 0;
  text-align: center;
}
.page-header h1 {
  color: var(--white);
  font-size: clamp(2.25rem, 5vw, 3.75rem);
  margin-bottom: 1.5rem;
}
.page-header p {
  font-size: 1.25rem;
  color: rgba(255,255,255,.9);
  max-width: 768px;
  margin: 0 auto;
  line-height: 1.6;
}

/* ============================================
   SECTIONS
   ============================================ */
section { padding: 4rem 0; }

.section-title {
  text-align: center;
  margin-bottom: 3rem;
}
.section-title h2 {
  font-size: clamp(2rem, 4vw, 3rem);
  margin-bottom: 1rem;
}
.section-title p {
  font-size: 1.125rem;
  color: var(--text);
  max-width: 768px;
  margin: 0 auto;
}

.bg-light { background: var(--light-gray); }
.bg-white { background: var(--white); }
.bg-navy { background: var(--navy); color: var(--white); }
.bg-navy h2 { color: var(--white); }
.bg-gold { background: var(--gold); color: var(--white); }
.bg-gold h2 { color: var(--white); }

/* ============================================
   GRID
   ============================================ */
.grid {
  display: grid;
  gap: 2rem;
  grid-template-columns: 1fr;
}
@media (min-width: 768px) {
  .grid-2 { grid-template-columns: repeat(2, 1fr); }
  .grid-3 { grid-template-columns: repeat(3, 1fr); }
  .grid-4 { grid-template-columns: repeat(4, 1fr); }
}

/* ============================================
   CARDS
   ============================================ */
.card {
  background: var(--white);
  padding: 2rem;
  border-radius: .5rem;
  box-shadow: 0 4px 6px -1px rgba(0,0,0,.1);
  transition: all .3s ease;
}
.card:hover { box-shadow: 0 20px 25px -5px rgba(0,0,0,.1); transform: translateY(-4px); }
.card h3 { font-size: 1.5rem; margin-bottom: .75rem; color: var(--navy); }
.card p { color: var(--text); line-height: 1.7; }
.card .icon { width: 48px; height: 48px; color: var(--gold); margin-bottom: 1rem; }
.card-light { background: var(--light-gray); }

.card-bordered {
  background: var(--white);
  padding: 2rem;
  border-radius: .5rem;
  border: 2px solid var(--navy);
  transition: all .3s ease;
}
.card-bordered:hover { border-color: var(--gold); box-shadow: 0 20px 25px -5px rgba(0,0,0,.1); }
.card-bordered .icon { width: 48px; height: 48px; color: var(--navy); margin-bottom: 1rem; transition: color .3s; }
.card-bordered:hover .icon { color: var(--gold); }

.card-value {
  background: var(--white);
  padding: 2rem;
  border-radius: .5rem;
  border-top: 4px solid var(--gold);
  box-shadow: 0 4px 6px -1px rgba(0,0,0,.1);
  transition: all .3s ease;
}
.card-value:hover { box-shadow: 0 20px 25px -5px rgba(0,0,0,.1); transform: translateY(-4px); }
.card-value .icon { width: 48px; height: 48px; color: var(--gold); margin-bottom: 1rem; }
.card-value h3 { font-size: 1.5rem; margin-bottom: .75rem; }

/* ============================================
   SERVICES (detailed)
   ============================================ */
.service-block {
  background: var(--white);
  padding: 2rem;
  border-radius: .5rem;
  border: 2px solid var(--navy);
  transition: all .3s ease;
  margin-bottom: 2rem;
}
.service-block:hover { border-color: var(--gold); box-shadow: 0 20px 40px -10px rgba(0,0,0,.15); }

.service-block-inner {
  display: flex;
  flex-direction: column;
  gap: 2rem;
}
@media (min-width: 768px) {
  .service-block-inner { flex-direction: row; }
  .service-block { padding: 3rem; }
}

.service-icon-box {
  width: 80px;
  height: 80px;
  background: var(--navy);
  border-radius: .5rem;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  transition: background .3s;
}
.service-block:hover .service-icon-box { background: var(--gold); }
.service-icon-box svg { width: 40px; height: 40px; color: var(--white); }

.service-content { flex-grow: 1; }
.service-content h2 { font-size: 1.875rem; margin-bottom: 1rem; }
.service-content p { font-size: 1.125rem; line-height: 1.7; margin-bottom: 1.5rem; }
.service-content h3 { font-size: 1.25rem; margin-bottom: .75rem; }

.feature-list {
  list-style: none;
  display: grid;
  gap: .5rem;
  grid-template-columns: 1fr;
  margin-bottom: 1.5rem;
}
@media (min-width: 768px) { .feature-list { grid-template-columns: repeat(2, 1fr); } }
.feature-list li {
  display: flex;
  align-items: center;
  gap: .5rem;
  color: var(--text);
}
.feature-list li::before {
  content: '';
  width: 6px;
  height: 6px;
  background: var(--gold);
  border-radius: 50%;
  flex-shrink: 0;
}

/* ============================================
   ABOUT PAGE
   ============================================ */
.mission-grid {
  display: grid;
  gap: 3rem;
  grid-template-columns: 1fr;
  align-items: center;
}
@media (min-width: 1024px) {
  .mission-grid { grid-template-columns: 1fr 1fr; }
}
.mission-text h2 { font-size: 2.25rem; margin-bottom: 1.5rem; }
.mission-text p { font-size: 1.125rem; line-height: 1.7; margin-bottom: 1rem; }
.mission-image {
  position: relative;
  border-radius: .5rem;
  overflow: hidden;
  box-shadow: 0 25px 50px -12px rgba(0,0,0,.25);
}
.mission-image img {
  width: 100%;
  height: 500px;
  object-fit: cover;
}

.credentials-box {
  background: var(--navy);
  color: var(--white);
  padding: 2rem;
  border-radius: .5rem;
}
@media (min-width: 768px) { .credentials-box { padding: 3rem; } }
.credentials-box h3 {
  color: var(--gold);
  font-size: 1.5rem;
  margin-bottom: 1rem;
}
.credentials-box ul { list-style: none; }
.credentials-box li {
  display: flex;
  gap: .75rem;
  align-items: flex-start;
  margin-bottom: .75rem;
  color: rgba(255,255,255,.9);
}
.credentials-box li::before {
  content: '';
  width: 8px;
  height: 8px;
  background: var(--gold);
  border-radius: 50%;
  flex-shrink: 0;
  margin-top: 9px;
}

.achievement {
  text-align: center;
}
.achievement-number {
  font-family: 'Merriweather', serif;
  font-weight: 700;
  font-size: clamp(2.5rem, 6vw, 4rem);
  color: var(--white);
  margin-bottom: .5rem;
  line-height: 1;
}
.achievement-label {
  font-size: 1.125rem;
  color: rgba(255,255,255,.9);
}

/* ============================================
   CONTACT PAGE
   ============================================ */
.contact-grid {
  display: grid;
  gap: 3rem;
  grid-template-columns: 1fr;
}
@media (min-width: 1024px) { .contact-grid { grid-template-columns: 1fr 1fr; } }

.form-group { margin-bottom: 1.5rem; }
.form-group label {
  display: block;
  font-size: .875rem;
  font-weight: 600;
  color: var(--navy);
  margin-bottom: .5rem;
}
.form-group input,
.form-group select,
.form-group textarea {
  width: 100%;
  padding: .75rem 1rem;
  border: 2px solid #d1d5db;
  border-radius: .5rem;
  font-family: inherit;
  font-size: 1rem;
  color: #111827;
  background: var(--white);
  transition: border-color .2s;
}
.form-group input:focus,
.form-group select:focus,
.form-group textarea:focus {
  outline: none;
  border-color: var(--gold);
}
.form-group textarea { resize: vertical; min-height: 130px; }
.form-error { color: #dc2626; font-size: .875rem; margin-top: .25rem; display: none; }
.form-group.has-error input,
.form-group.has-error select,
.form-group.has-error textarea { border-color: #dc2626; }
.form-group.has-error .form-error { display: block; }
.form-success {
  display: none;
  padding: 1rem;
  background: #d1fae5;
  border: 1px solid #10b981;
  color: #065f46;
  border-radius: .5rem;
  margin-bottom: 1rem;
}
.form-success.show { display: block; }

.contact-info-card {
  display: flex;
  gap: 1rem;
  padding: 1.5rem;
  background: var(--light-gray);
  border-radius: .5rem;
  margin-bottom: 1.5rem;
  align-items: flex-start;
  transition: box-shadow .3s;
}
.contact-info-card:hover { box-shadow: 0 4px 6px rgba(0,0,0,.1); }
.contact-info-card svg { width: 24px; height: 24px; color: var(--gold); flex-shrink: 0; margin-top: 4px; }
.contact-info-card h3 { font-family: 'Inter', sans-serif; font-size: 1rem; font-weight: 600; margin-bottom: .25rem; }
.contact-info-card p, .contact-info-card a { color: var(--text); }
.contact-info-card a:hover { color: var(--gold); }

.emergency-box {
  background: var(--navy);
  color: var(--white);
  padding: 1.5rem;
  border-radius: .5rem;
  margin-top: 1.5rem;
}
.emergency-box h3 { color: var(--white); font-size: 1.25rem; margin-bottom: .75rem; }
.emergency-box p { color: rgba(255,255,255,.9); }

/* ============================================
   RESOURCES / BLOG GRID
   ============================================ */
.filters {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 1rem;
  margin-bottom: 3rem;
}
.filter-btn {
  padding: .5rem 1.5rem;
  border-radius: 9999px;
  font-weight: 500;
  background: var(--white);
  color: var(--navy);
  border: 1px solid rgba(26,58,82,.2);
  cursor: pointer;
  font-family: inherit;
  transition: all .3s;
}
.filter-btn:hover { border-color: var(--gold); color: var(--gold); }
.filter-btn.active {
  background: var(--gold);
  color: var(--white);
  border-color: var(--gold);
  box-shadow: 0 4px 6px rgba(0,0,0,.1);
  transform: scale(1.05);
}

.blog-grid {
  display: grid;
  gap: 2rem;
  grid-template-columns: 1fr;
}
@media (min-width: 768px) { .blog-grid { grid-template-columns: repeat(2, 1fr); } }
@media (min-width: 1024px) { .blog-grid { grid-template-columns: repeat(3, 1fr); } }

.blog-card {
  background: var(--white);
  border-radius: .75rem;
  box-shadow: 0 4px 6px rgba(0,0,0,.05);
  border: 1px solid #f3f4f6;
  overflow: hidden;
  display: flex;
  flex-direction: column;
  transition: box-shadow .3s;
}
.blog-card:hover { box-shadow: 0 20px 25px -5px rgba(0,0,0,.1); }
.blog-card-body { padding: 2rem; display: flex; flex-direction: column; flex-grow: 1; }
.blog-tag {
  display: inline-block;
  background: rgba(26,58,82,.05);
  color: var(--navy);
  padding: .25rem .75rem;
  border-radius: 9999px;
  font-size: .75rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: .05em;
  border: 1px solid rgba(26,58,82,.1);
  margin-bottom: 1rem;
  width: fit-content;
}
.blog-card h2 {
  font-size: 1.5rem;
  margin-bottom: .75rem;
  line-height: 1.3;
}
.blog-card h2 a { color: var(--navy); }
.blog-card h2 a:hover { color: var(--gold); }
.blog-meta {
  display: flex;
  align-items: center;
  gap: .5rem;
  color: var(--text-muted);
  font-size: .875rem;
  margin-bottom: 1rem;
}
.blog-meta svg { width: 16px; height: 16px; color: var(--gold); }
.blog-card p {
  color: var(--text);
  line-height: 1.7;
  margin-bottom: 1.5rem;
  flex-grow: 1;
  display: -webkit-box;
  -webkit-line-clamp: 3;
  -webkit-box-orient: vertical;
  overflow: hidden;
}
.blog-card .btn { margin-top: auto; width: 100%; }

/* ============================================
   BLOG POST (single)
   ============================================ */
.blog-post-wrap {
  background: var(--light-gray);
  padding: 3rem 0 5rem;
  min-height: 100vh;
}
.blog-post-container {
  max-width: 900px;
  margin: 0 auto;
  padding: 0 1.25rem;
}
.back-link {
  display: inline-flex;
  align-items: center;
  gap: .5rem;
  color: var(--navy);
  font-weight: 500;
  margin-bottom: 2rem;
  transition: color .3s;
}
.back-link:hover { color: var(--gold); }
.back-link svg { width: 16px; height: 16px; }

.blog-article {
  background: var(--white);
  border-radius: .75rem;
  box-shadow: 0 10px 25px rgba(0,0,0,.08);
  border: 1px solid #f3f4f6;
  padding: 2rem;
  margin-bottom: 3rem;
}
@media (min-width: 768px) { .blog-article { padding: 3rem; } }

.blog-article-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 1rem;
  align-items: center;
  margin-bottom: 1.5rem;
}
.meta-item {
  display: inline-flex;
  align-items: center;
  gap: .5rem;
  color: var(--text-muted);
  font-size: .875rem;
}
.meta-item svg { width: 16px; height: 16px; color: var(--gold); }
.meta-tag {
  background: rgba(212,175,55,.1);
  color: var(--dark-gray);
  padding: .375rem 1rem;
  border-radius: 9999px;
  font-size: .875rem;
  font-weight: 700;
  border: 1px solid rgba(212,175,55,.2);
  display: inline-flex;
  align-items: center;
  gap: .5rem;
}
.meta-tag svg { width: 12px; height: 12px; color: var(--gold); }

.blog-article h1 {
  font-size: clamp(1.875rem, 4vw, 3rem);
  margin-bottom: 2rem;
  line-height: 1.2;
}

.blog-content { color: var(--text); line-height: 1.8; font-size: 1.0625rem; }
.blog-content p { margin-bottom: 1rem; }
.blog-content h2 {
  font-size: 1.5rem;
  margin-top: 2rem;
  margin-bottom: .75rem;
  color: var(--navy);
}
.blog-content h3 {
  font-size: 1.25rem;
  margin-top: 1.5rem;
  margin-bottom: .5rem;
  color: var(--navy);
}
.blog-content a {
  color: var(--gold);
  text-decoration: underline;
}
.blog-content a:hover { color: var(--navy); }
.blog-content strong { color: var(--navy); font-weight: 700; }

.related-title {
  font-size: 1.5rem;
  margin-bottom: 1.5rem;
  padding-left: .75rem;
  border-left: 4px solid var(--gold);
}

.related-grid {
  display: grid;
  gap: 1.5rem;
  grid-template-columns: 1fr;
}
@media (min-width: 768px) { .related-grid { grid-template-columns: repeat(3, 1fr); } }

.related-card {
  background: var(--white);
  border-radius: .5rem;
  border: 1px solid #f3f4f6;
  box-shadow: 0 4px 6px rgba(0,0,0,.05);
  padding: 1.5rem;
  transition: all .3s;
  display: flex;
  flex-direction: column;
}
.related-card:hover { box-shadow: 0 20px 25px -5px rgba(0,0,0,.1); transform: translateY(-4px); }
.related-cat {
  font-size: .75rem;
  font-weight: 700;
  color: var(--gold);
  text-transform: uppercase;
  letter-spacing: .05em;
  margin-bottom: .5rem;
}
.related-card h4 {
  font-size: 1.125rem;
  margin-bottom: .5rem;
  color: var(--navy);
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}
.related-card:hover h4 { color: var(--gold); }
.related-link {
  display: inline-flex;
  align-items: center;
  gap: .25rem;
  color: var(--navy);
  font-weight: 500;
  font-size: .875rem;
  margin-top: auto;
}
.related-link svg { width: 12px; height: 12px; }

/* ============================================
   FOOTER
   ============================================ */
.footer {
  background: var(--navy);
  color: var(--white);
  padding: 4rem 0 2rem;
}
.footer-grid {
  display: grid;
  gap: 3rem;
  margin-bottom: 3rem;
  grid-template-columns: 1fr;
}
@media (min-width: 768px) { .footer-grid { grid-template-columns: repeat(3, 1fr); } }

.footer-brand {
  display: flex;
  align-items: center;
  gap: .5rem;
  margin-bottom: 1rem;
}
.footer-brand svg { width: 32px; height: 32px; color: var(--gold); }
.footer-brand-name {
  font-family: 'Merriweather', serif;
  font-size: 1.5rem;
  font-weight: 700;
  color: var(--white);
}
.footer p { color: rgba(255,255,255,.8); line-height: 1.7; }
.footer h3 {
  color: var(--gold);
  font-size: 1.25rem;
  margin-bottom: 1rem;
}
.footer ul { list-style: none; }
.footer ul li { margin-bottom: .75rem; }
.footer ul a { color: rgba(255,255,255,.8); }
.footer ul a:hover { color: var(--gold); }
.footer-contact-item {
  display: flex;
  gap: .75rem;
  align-items: flex-start;
  margin-bottom: .75rem;
  color: rgba(255,255,255,.8);
}
.footer-contact-item svg { width: 20px; height: 20px; color: var(--gold); flex-shrink: 0; margin-top: 3px; }
.footer-bottom {
  padding-top: 2rem;
  border-top: 1px solid rgba(255,255,255,.2);
  text-align: center;
}
.footer-bottom p { color: rgba(255,255,255,.6); }
.footer-bottom a { color: rgba(255,255,255,.6); }
.footer-bottom a:hover { color: var(--gold); }

/* ============================================
   UTILS / ANIMATIONS
   ============================================ */
.text-center { text-align: center; }
.mb-12 { margin-bottom: 3rem; }
.mt-12 { margin-top: 3rem; }

@keyframes fadeUp {
  from { opacity: 0; transform: translateY(20px); }
  to { opacity: 1; transform: translateY(0); }
}
.fade-up { animation: fadeUp .6s ease-out both; }

/* Reduce motion */
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    animation-duration: .01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: .01ms !important;
    scroll-behavior: auto !important;
  }
}
