/* ==========================================================================
   The Juris Firm - Austin Personal Injury Lawyers
   Main Stylesheet
   ========================================================================== */

/* CSS Variables */
:root {
  --primary-color: #1a365d;
  --primary-dark: #0f2440;
  --secondary-color: #c9a227;
  --accent-color: #2c5282;
  --text-color: #2d3748;
  --text-light: #718096;
  --bg-light: #f7fafc;
  --bg-dark: #1a202c;
  --white: #ffffff;
  --border-color: #e2e8f0;
  --success-color: #38a169;
  --font-primary: 'Georgia', 'Times New Roman', serif;
  --font-secondary: 'Helvetica Neue', Arial, sans-serif;
  --shadow-sm: 0 1px 2px 0 rgba(0, 0, 0, 0.05);
  --shadow-md: 0 4px 6px -1px rgba(0, 0, 0, 0.1);
  --shadow-lg: 0 10px 15px -3px rgba(0, 0, 0, 0.1);
  --transition: all 0.3s ease;
}

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

html {
  font-size: 16px;
  scroll-behavior: smooth;
}

body {
  font-family: var(--font-secondary);
  font-size: 1rem;
  line-height: 1.7;
  color: var(--text-color);
  background-color: var(--white);
}

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

a {
  color: var(--primary-color);
  text-decoration: none;
  transition: var(--transition);
}

a:hover {
  color: var(--secondary-color);
}

ul, ol {
  padding-left: 1.5rem;
}

/* Typography */
h1, h2, h3, h4, h5, h6 {
  font-family: var(--font-primary);
  color: var(--primary-color);
  line-height: 1.3;
  margin-bottom: 1rem;
}

h1 {
  font-size: 2.5rem;
  font-weight: 700;
}

h2 {
  font-size: 2rem;
  font-weight: 600;
  margin-top: 2.5rem;
}

h3 {
  font-size: 1.5rem;
  font-weight: 600;
  margin-top: 2rem;
}

h4 {
  font-size: 1.25rem;
  font-weight: 600;
}

p {
  margin-bottom: 1rem;
}

/* Container */
.container {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 1.5rem;
}

.container-narrow {
  max-width: 800px;
  margin: 0 auto;
  padding: 0 1.5rem;
}

/* Header */
.site-header {
  background-color: var(--white);
  box-shadow: var(--shadow-md);
  position: sticky;
  top: 0;
  z-index: 1000;
}

.header-top {
  background-color: var(--primary-dark);
  color: var(--white);
  padding: 0.5rem 0;
  font-size: 0.875rem;
}

.header-top-inner {
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 0.5rem;
}

.header-top a {
  color: var(--white);
}

.header-top a:hover {
  color: var(--secondary-color);
}

.header-main {
  padding: 1rem 0;
}

.header-main-inner {
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.logo {
  font-family: var(--font-primary);
  font-size: 1.75rem;
  font-weight: 700;
  color: var(--primary-color);
}

.logo span {
  color: var(--secondary-color);
}

/* Navigation */
.main-nav {
  display: flex;
  align-items: center;
}

.nav-list {
  display: flex;
  list-style: none;
  padding: 0;
  margin: 0;
  gap: 0.25rem;
}

.nav-list a {
  display: block;
  padding: 0.5rem 1rem;
  color: var(--text-color);
  font-weight: 500;
  border-radius: 4px;
}

.nav-list a:hover,
.nav-list a.active {
  background-color: var(--bg-light);
  color: var(--primary-color);
}

/* Dropdown */
.nav-item {
  position: relative;
}

.dropdown {
  position: absolute;
  top: 100%;
  left: 0;
  background: var(--white);
  box-shadow: var(--shadow-lg);
  border-radius: 4px;
  min-width: 250px;
  opacity: 0;
  visibility: hidden;
  transform: translateY(10px);
  transition: var(--transition);
  z-index: 100;
}

.nav-item:hover .dropdown {
  opacity: 1;
  visibility: visible;
  transform: translateY(0);
}

.dropdown a {
  display: block;
  padding: 0.75rem 1rem;
  border-bottom: 1px solid var(--border-color);
}

.dropdown a:last-child {
  border-bottom: none;
}

.dropdown a:hover {
  background-color: var(--bg-light);
}

/* Mobile Menu Toggle */
.menu-toggle {
  display: none;
  background: none;
  border: none;
  font-size: 1.5rem;
  cursor: pointer;
  padding: 0.5rem;
  color: var(--primary-color);
}

/* Buttons */
.btn {
  display: inline-block;
  padding: 0.875rem 2rem;
  font-size: 1rem;
  font-weight: 600;
  text-align: center;
  border-radius: 4px;
  cursor: pointer;
  transition: var(--transition);
  border: none;
}

.btn-primary {
  background-color: var(--secondary-color);
  color: var(--white);
}

.btn-primary:hover {
  background-color: #b8911f;
  color: var(--white);
}

.btn-secondary {
  background-color: var(--primary-color);
  color: var(--white);
}

.btn-secondary:hover {
  background-color: var(--primary-dark);
  color: var(--white);
}

.btn-outline {
  background-color: transparent;
  border: 2px solid var(--primary-color);
  color: var(--primary-color);
}

.btn-outline:hover {
  background-color: var(--primary-color);
  color: var(--white);
}

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

.btn-sm {
  padding: 0.5rem 1rem;
  font-size: 0.875rem;
}

/* Hero Section */
.hero {
  background: linear-gradient(135deg, var(--primary-dark) 0%, var(--primary-color) 100%);
  color: var(--white);
  padding: 4rem 0;
  position: relative;
}

.hero-home {
  padding: 6rem 0;
}

.hero h1 {
  color: var(--white);
  margin-bottom: 1.5rem;
}

.hero p {
  font-size: 1.25rem;
  margin-bottom: 2rem;
  opacity: 0.95;
}

.hero .btn-primary {
  margin-right: 1rem;
  margin-bottom: 0.5rem;
}

.hero-features {
  display: flex;
  gap: 2rem;
  margin-top: 3rem;
  flex-wrap: wrap;
}

.hero-feature {
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.hero-feature svg {
  width: 24px;
  height: 24px;
  color: var(--secondary-color);
}

/* Sections */
.section {
  padding: 4rem 0;
}

.section-light {
  background-color: var(--bg-light);
}

.section-dark {
  background-color: var(--primary-dark);
  color: var(--white);
}

.section-dark h2,
.section-dark h3 {
  color: var(--white);
}

.section-header {
  text-align: center;
  max-width: 700px;
  margin: 0 auto 3rem;
}

.section-header h2 {
  margin-top: 0;
}

/* Cards */
.card {
  background: var(--white);
  border-radius: 8px;
  box-shadow: var(--shadow-md);
  padding: 2rem;
  transition: var(--transition);
}

.card:hover {
  box-shadow: var(--shadow-lg);
  transform: translateY(-2px);
}

.card-title {
  font-size: 1.25rem;
  margin-bottom: 1rem;
}

.card-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  gap: 2rem;
}

/* Practice Areas Grid */
.practice-areas-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 1.5rem;
}

.practice-area-card {
  background: var(--white);
  border: 1px solid var(--border-color);
  border-radius: 8px;
  padding: 1.5rem;
  text-align: center;
  transition: var(--transition);
}

.practice-area-card:hover {
  border-color: var(--secondary-color);
  box-shadow: var(--shadow-md);
}

.practice-area-card h3 {
  margin-top: 1rem;
  font-size: 1.125rem;
}

.practice-area-card p {
  color: var(--text-light);
  font-size: 0.9375rem;
}

/* CTA Sections */
.cta-section {
  background: linear-gradient(135deg, var(--secondary-color) 0%, #d4a82a 100%);
  color: var(--white);
  text-align: center;
  padding: 4rem 0;
}

.cta-section h2 {
  color: var(--white);
  margin-top: 0;
}

.cta-section .btn {
  background-color: var(--primary-dark);
  color: var(--white);
  margin-top: 1rem;
}

.cta-section .btn:hover {
  background-color: var(--white);
  color: var(--primary-dark);
}

/* Content Sections */
.content-section {
  padding: 3rem 0;
}

.content-section h2:first-child {
  margin-top: 0;
}

/* Lists */
.check-list {
  list-style: none;
  padding: 0;
}

.check-list li {
  position: relative;
  padding-left: 1.75rem;
  margin-bottom: 0.75rem;
}

.check-list li::before {
  content: "✓";
  position: absolute;
  left: 0;
  color: var(--success-color);
  font-weight: 700;
}

.numbered-list {
  counter-reset: item;
  list-style: none;
  padding: 0;
}

.numbered-list li {
  counter-increment: item;
  position: relative;
  padding-left: 3rem;
  margin-bottom: 1.5rem;
}

.numbered-list li::before {
  content: counter(item);
  position: absolute;
  left: 0;
  width: 2rem;
  height: 2rem;
  background-color: var(--primary-color);
  color: var(--white);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 700;
  font-size: 0.875rem;
}

/* Two Column Layout */
.two-column {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 3rem;
  align-items: start;
}

.two-column-content {
  display: grid;
  grid-template-columns: 2fr 1fr;
  gap: 3rem;
}

/* Sidebar */
.sidebar {
  position: sticky;
  top: 100px;
}

.sidebar-card {
  background: var(--bg-light);
  border-radius: 8px;
  padding: 1.5rem;
  margin-bottom: 1.5rem;
}

.sidebar-card h3 {
  font-size: 1.125rem;
  margin-top: 0;
  padding-bottom: 0.75rem;
  border-bottom: 2px solid var(--secondary-color);
}

.sidebar-card ul {
  list-style: none;
  padding: 0;
}

.sidebar-card li {
  padding: 0.5rem 0;
  border-bottom: 1px solid var(--border-color);
}

.sidebar-card li:last-child {
  border-bottom: none;
}

/* FAQ Accordion */
.faq-item {
  border: 1px solid var(--border-color);
  border-radius: 8px;
  margin-bottom: 1rem;
}

.faq-question {
  width: 100%;
  background: var(--white);
  border: none;
  padding: 1.25rem 1.5rem;
  text-align: left;
  font-size: 1.0625rem;
  font-weight: 600;
  color: var(--primary-color);
  cursor: pointer;
  display: flex;
  justify-content: space-between;
  align-items: center;
  border-radius: 8px;
}

.faq-question:hover {
  background-color: var(--bg-light);
}

.faq-question::after {
  content: "+";
  font-size: 1.5rem;
  color: var(--secondary-color);
}

.faq-item.active .faq-question::after {
  content: "−";
}

.faq-answer {
  padding: 0 1.5rem 1.25rem;
  display: none;
}

.faq-item.active .faq-answer {
  display: block;
}

/* Testimonials */
.testimonial {
  background: var(--white);
  border-radius: 8px;
  padding: 2rem;
  box-shadow: var(--shadow-md);
  position: relative;
}

.testimonial::before {
  content: """;
  font-family: var(--font-primary);
  font-size: 4rem;
  color: var(--secondary-color);
  opacity: 0.3;
  position: absolute;
  top: 0.5rem;
  left: 1rem;
}

.testimonial-content {
  font-style: italic;
  margin-bottom: 1rem;
  padding-left: 1rem;
}

.testimonial-author {
  font-weight: 600;
  color: var(--primary-color);
}

.testimonial-case {
  color: var(--text-light);
  font-size: 0.875rem;
}

/* Stats */
.stats-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  gap: 2rem;
  text-align: center;
}

.stat-item {
  padding: 1.5rem;
}

.stat-number {
  font-family: var(--font-primary);
  font-size: 3rem;
  font-weight: 700;
  color: var(--secondary-color);
  line-height: 1;
}

.stat-label {
  font-size: 1rem;
  color: var(--text-light);
  margin-top: 0.5rem;
}

/* Forms */
.form-group {
  margin-bottom: 1.5rem;
}

.form-label {
  display: block;
  font-weight: 600;
  margin-bottom: 0.5rem;
  color: var(--text-color);
}

.form-input,
.form-select,
.form-textarea {
  width: 100%;
  padding: 0.875rem 1rem;
  font-size: 1rem;
  border: 1px solid var(--border-color);
  border-radius: 4px;
  transition: var(--transition);
}

.form-input:focus,
.form-select:focus,
.form-textarea:focus {
  outline: none;
  border-color: var(--primary-color);
  box-shadow: 0 0 0 3px rgba(26, 54, 93, 0.1);
}

.form-textarea {
  min-height: 150px;
  resize: vertical;
}

/* Contact Form */
.contact-form {
  background: var(--white);
  padding: 2rem;
  border-radius: 8px;
  box-shadow: var(--shadow-md);
}

.contact-info {
  background: var(--primary-color);
  color: var(--white);
  padding: 2rem;
  border-radius: 8px;
}

.contact-info h3 {
  color: var(--white);
  margin-top: 0;
}

.contact-info-item {
  display: flex;
  align-items: flex-start;
  gap: 1rem;
  margin-bottom: 1.5rem;
}

.contact-info-item svg {
  width: 24px;
  height: 24px;
  flex-shrink: 0;
  color: var(--secondary-color);
}

/* Tables */
.table-responsive {
  overflow-x: auto;
}

table {
  width: 100%;
  border-collapse: collapse;
  margin: 1.5rem 0;
}

th, td {
  padding: 1rem;
  text-align: left;
  border-bottom: 1px solid var(--border-color);
}

th {
  background-color: var(--primary-color);
  color: var(--white);
  font-weight: 600;
}

tr:hover {
  background-color: var(--bg-light);
}

/* Breadcrumbs */
.breadcrumbs {
  padding: 1rem 0;
  font-size: 0.875rem;
  color: var(--text-light);
}

.breadcrumbs a {
  color: var(--text-light);
}

.breadcrumbs a:hover {
  color: var(--primary-color);
}

.breadcrumbs span {
  margin: 0 0.5rem;
}

/* Footer */
.site-footer {
  background-color: var(--bg-dark);
  color: var(--white);
  padding: 4rem 0 2rem;
}

.footer-grid {
  display: grid;
  grid-template-columns: 2fr 1fr 1fr 1fr;
  gap: 3rem;
  margin-bottom: 3rem;
}

.footer-about {
  max-width: 300px;
}

.footer-logo {
  font-family: var(--font-primary);
  font-size: 1.5rem;
  font-weight: 700;
  color: var(--white);
  margin-bottom: 1rem;
}

.footer-logo span {
  color: var(--secondary-color);
}

.footer-about p {
  color: rgba(255, 255, 255, 0.7);
  font-size: 0.9375rem;
}

.footer-heading {
  font-family: var(--font-secondary);
  font-size: 1rem;
  font-weight: 600;
  color: var(--white);
  margin-bottom: 1.5rem;
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

.footer-links {
  list-style: none;
  padding: 0;
}

.footer-links li {
  margin-bottom: 0.75rem;
}

.footer-links a {
  color: rgba(255, 255, 255, 0.7);
  font-size: 0.9375rem;
}

.footer-links a:hover {
  color: var(--secondary-color);
}

.footer-bottom {
  border-top: 1px solid rgba(255, 255, 255, 0.1);
  padding-top: 2rem;
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 1rem;
  font-size: 0.875rem;
  color: rgba(255, 255, 255, 0.6);
}

.footer-bottom a {
  color: rgba(255, 255, 255, 0.6);
}

.footer-bottom a:hover {
  color: var(--secondary-color);
}

.footer-legal {
  display: flex;
  gap: 1.5rem;
}

/* Schema/Structured Data Styling */
.schema-hidden {
  display: none;
}

/* Print Styles */
@media print {
  .site-header,
  .site-footer,
  .cta-section,
  .sidebar {
    display: none;
  }

  body {
    font-size: 12pt;
  }

  a {
    color: var(--text-color);
  }
}

/* Responsive Design */
@media (max-width: 1024px) {
  .footer-grid {
    grid-template-columns: 1fr 1fr;
  }

  .two-column,
  .two-column-content {
    grid-template-columns: 1fr;
  }

  .sidebar {
    position: static;
  }
}

@media (max-width: 768px) {
  html {
    font-size: 15px;
  }

  h1 {
    font-size: 2rem;
  }

  h2 {
    font-size: 1.625rem;
  }

  h3 {
    font-size: 1.25rem;
  }

  .header-top-inner {
    justify-content: center;
    text-align: center;
  }

  .header-main-inner {
    flex-wrap: wrap;
  }

  .menu-toggle {
    display: block;
  }

  .main-nav {
    display: none;
    width: 100%;
    margin-top: 1rem;
  }

  .main-nav.active {
    display: block;
  }

  .nav-list {
    flex-direction: column;
    gap: 0;
  }

  .nav-list a {
    padding: 0.75rem 0;
    border-bottom: 1px solid var(--border-color);
  }

  .dropdown {
    position: static;
    opacity: 1;
    visibility: visible;
    transform: none;
    box-shadow: none;
    padding-left: 1rem;
    display: none;
  }

  .nav-item:hover .dropdown,
  .nav-item.active .dropdown {
    display: block;
  }

  .hero {
    padding: 3rem 0;
  }

  .hero-home {
    padding: 4rem 0;
  }

  .hero-features {
    flex-direction: column;
    gap: 1rem;
  }

  .section {
    padding: 3rem 0;
  }

  .footer-grid {
    grid-template-columns: 1fr;
    gap: 2rem;
  }

  .footer-about {
    max-width: none;
  }

  .footer-bottom {
    flex-direction: column;
    text-align: center;
  }

  .stats-grid {
    grid-template-columns: repeat(2, 1fr);
  }

  .card-grid {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 480px) {
  .container {
    padding: 0 1rem;
  }

  .btn {
    display: block;
    width: 100%;
  }

  .btn + .btn {
    margin-top: 0.75rem;
    margin-left: 0;
  }

  .hero .btn-primary {
    margin-right: 0;
  }

  .stats-grid {
    grid-template-columns: 1fr;
  }
}

/* Utility Classes */
.text-center { text-align: center; }
.text-left { text-align: left; }
.text-right { text-align: right; }
.mb-0 { margin-bottom: 0; }
.mb-1 { margin-bottom: 0.5rem; }
.mb-2 { margin-bottom: 1rem; }
.mb-3 { margin-bottom: 1.5rem; }
.mb-4 { margin-bottom: 2rem; }
.mt-0 { margin-top: 0; }
.mt-1 { margin-top: 0.5rem; }
.mt-2 { margin-top: 1rem; }
.mt-3 { margin-top: 1.5rem; }
.mt-4 { margin-top: 2rem; }
.py-2 { padding-top: 1rem; padding-bottom: 1rem; }
.py-3 { padding-top: 1.5rem; padding-bottom: 1.5rem; }
.py-4 { padding-top: 2rem; padding-bottom: 2rem; }

/* Content Images */
.content-image {
  margin: 2rem 0;
  border-radius: 8px;
  overflow: hidden;
  box-shadow: var(--shadow-md);
}

.content-image img {
  width: 100%;
  height: auto;
  display: block;
}

.content-image figcaption {
  padding: 0.75rem 1rem;
  background-color: var(--bg-light);
  font-size: 0.875rem;
  color: var(--text-light);
  text-align: center;
}

.image-float-right {
  float: right;
  max-width: 400px;
  margin: 0 0 1.5rem 2rem;
}

.image-float-left {
  float: left;
  max-width: 400px;
  margin: 0 2rem 1.5rem 0;
}

.hero-image {
  margin-top: 2rem;
  border-radius: 8px;
  overflow: hidden;
  box-shadow: var(--shadow-lg);
}

.hero-image img {
  width: 100%;
  height: auto;
  display: block;
}

.image-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 1.5rem;
  margin: 2rem 0;
}

.image-grid figure {
  margin: 0;
  border-radius: 8px;
  overflow: hidden;
  box-shadow: var(--shadow-md);
}

.image-grid img {
  width: 100%;
  height: 200px;
  object-fit: cover;
}

@media (max-width: 768px) {
  .image-float-right,
  .image-float-left {
    float: none;
    max-width: 100%;
    margin: 1.5rem 0;
  }
}

/* Photo Attribution */
.photo-credits {
  font-size: 0.75rem;
  color: var(--text-light);
  margin-top: 3rem;
  padding-top: 1rem;
  border-top: 1px solid var(--border-color);
}

.photo-credits a {
  color: var(--text-light);
}

.photo-credits a:hover {
  color: var(--primary-color);
}
