:root {
  --primary: #0f2a56;
  --accent: #bb8a35;
  --text: #1a2233;
  --light: #f5f7fb;
  --white: #ffffff;
  --shadow: 0 10px 24px rgba(15, 42, 86, 0.08);
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  padding: 0;
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
  color: var(--text);
  background: var(--white);
  line-height: 1.6;
  display: flex;
  flex-direction: column;
  min-height: 100vh;
}

main {
  flex: 1;
}

.container {
  width: min(1120px, 92%);
  margin: 0 auto;
}

.site-header {
  position: sticky;
  top: 0;
  z-index: 100;
  background: var(--primary);
  box-shadow: 0 2px 10px rgba(0, 0, 0, 0.15);
}

.nav-wrap {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 1rem;
  padding: 0.9rem 0;
}

.brand {
  color: var(--white);
  text-decoration: none;
  font-weight: 700;
  letter-spacing: 0.03em;
}

.brand-with-logo {
  display: inline-flex;
  align-items: center;
  gap: 0.75rem;
}

.brand-text {
  color: var(--white);
  font-weight: 800;
  letter-spacing: 0.02em;
  font-size: 1.05rem;
}

.nav-logo {
  width: 78px;
  height: 78px;
  object-fit: contain;
  background: #ffffff;
  border-radius: 50%;
  padding: 0.35rem;
  box-shadow: 0 10px 24px rgba(0, 0, 0, 0.22);
  display: block;
}

.logo-fallback-nav {
  display: none;
}

.main-nav {
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem;
}

.main-nav a {
  color: var(--white);
  text-decoration: none;
  padding: 0.4rem 0.65rem;
  border-radius: 999px;
  font-size: 0.95rem;
}

.main-nav a:hover {
  background: rgba(255, 255, 255, 0.16);
}

.hero {
  position: relative;
  background: linear-gradient(120deg, #132f63 0%, #264d8d 60%, #2f5ca6 100%);
  color: var(--white);
  padding: 5rem 0 4rem;
  overflow: hidden;
}

.eyebrow {
  text-transform: uppercase;
  letter-spacing: 0.1em;
  font-size: 0.8rem;
  margin: 0 0 0.6rem;
  color: #e9d4a9;
}

.hero-logo-wrap {
  margin: 0.9rem auto 1.2rem;
  padding: 0.6rem 1rem;
  background: rgba(255, 255, 255, 0.10);
  border: 1px solid rgba(255, 255, 255, 0.18);
  border-radius: 18px;
  display: flex;
  align-items: center;
  justify-content: center;
  width: 100%;
}

.hero-logo {
  width: auto;
  max-width: 92vw;
  height: auto;
  display: block;
  object-fit: contain;
}

.logo-fallback {
  display: none;
}

h1 {
  margin: 0;
  font-size: clamp(1.9rem, 4.5vw, 3.1rem);
  line-height: 1.15;
}

.tagline {
  font-size: clamp(1rem, 2.3vw, 1.25rem);
  margin-top: 0.75rem;
  max-width: 780px;
}

.overview {
  max-width: 860px;
  margin-top: 1rem;
}

.hero-actions {
  margin-top: 1.4rem;
  display: flex;
  flex-wrap: wrap;
  gap: 0.7rem;
}

.muted {
  color: rgba(26, 34, 51, 0.75);
  max-width: 780px;
}

.law-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 1rem;
  margin-top: 1.2rem;
}

.law-card {
  text-decoration: none;
  color: inherit;
  border: 1px solid #e6ebf3;
  border-radius: 12px;
  overflow: hidden;
  background: var(--white);
  box-shadow: var(--shadow);
  display: flex;
  flex-direction: column;
  transition: transform 160ms ease, border-color 160ms ease;
}

.law-card img {
  width: 100%;
  height: 165px;
  object-fit: cover;
  background: #e9eefb;
  display: block;
}

.law-card h3 {
  padding: 0.9rem 1rem 1rem;
  margin: 0;
  color: #102748;
  font-size: 1.05rem;
}

.law-card:hover {
  transform: translateY(-3px);
  border-color: rgba(187, 138, 53, 0.7);
}

.law-card:focus-visible {
  outline: 3px solid rgba(187, 138, 53, 0.6);
  outline-offset: 2px;
}

.btn {
  display: inline-block;
  text-decoration: none;
  font-weight: 600;
  border-radius: 8px;
  padding: 0.72rem 1rem;
}

.btn-primary {
  background: var(--accent);
  color: #1e1b11;
}

.btn-outline {
  border: 1px solid rgba(255, 255, 255, 0.65);
  color: var(--white);
}

.section {
  padding: 3.4rem 0;
}

.section-alt {
  background: var(--light);
}

h2 {
  margin-top: 0;
  color: var(--primary);
  font-size: clamp(1.4rem, 2.7vw, 2rem);
}

h3 {
  margin-top: 0;
  color: #102748;
}

.subheading {
  margin-top: 1.8rem;
}

.about-grid,
.service-cards,
.practice-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 1rem;
  margin-top: 1.1rem;
}

.card {
  background: var(--white);
  border: 1px solid #e6ebf3;
  border-radius: 12px;
  padding: 1rem;
  box-shadow: var(--shadow);
}

.value-list {
  margin: 0.75rem 0 0;
  padding-left: 1.2rem;
}

.value-list li + li {
  margin-top: 0.45rem;
}

.site-footer {
  background: #0b1e40;
  color: #e9eefb;
  padding: 2.6rem 0;
}

.site-footer h2 {
  color: #ffffff;
}

.site-footer a {
  color: #f1cc82;
  text-decoration: none;
}

.site-footer a:hover {
  text-decoration: underline;
}

.home-link {
  display: inline-block;
  margin-top: 0.25rem;
  padding: 0.42rem 0.75rem;
  border-radius: 8px;
  border: 1px solid rgba(241, 204, 130, 0.5);
}

/* Contact Form Styles */
.contact-intro {
  font-size: 1.05rem;
  color: #5a6a7a;
  max-width: 700px;
  margin-bottom: 2.5rem;
}

.contact-wrapper {
  display: grid;
  grid-template-columns: 2fr 1fr;
  gap: 2rem;
  margin-top: 2rem;
}

.contact-form {
  background: var(--white);
  padding: 2rem;
  border-radius: 14px;
  border: 1px solid #e6ebf3;
  box-shadow: var(--shadow);
}

.form-group {
  margin-bottom: 1.5rem;
  display: flex;
  flex-direction: column;
}

.form-group label {
  font-weight: 600;
  color: var(--primary);
  margin-bottom: 0.5rem;
  font-size: 0.95rem;
}

.form-group input,
.form-group textarea {
  padding: 0.85rem 1rem;
  border: 1.5px solid #e6ebf3;
  border-radius: 8px;
  font-family: inherit;
  font-size: 0.95rem;
  transition: border-color 200ms ease, box-shadow 200ms ease;
  color: var(--text);
}

.form-group input::placeholder,
.form-group textarea::placeholder {
  color: #a0aab8;
}

.form-group input:focus,
.form-group textarea:focus {
  outline: none;
  border-color: var(--accent);
  box-shadow: 0 0 0 3px rgba(187, 138, 53, 0.1);
}

.btn-submit {
  background: linear-gradient(135deg, var(--accent) 0%, #d4a574 100%);
  color: #1e1b11;
  padding: 1rem 2rem;
  border: none;
  border-radius: 8px;
  font-weight: 700;
  font-size: 1rem;
  cursor: pointer;
  transition: transform 150ms ease, box-shadow 150ms ease;
  width: 100%;
  letter-spacing: 0.5px;
}

.btn-submit:hover {
  transform: translateY(-2px);
  box-shadow: 0 8px 20px rgba(187, 138, 53, 0.3);
}

.btn-submit:active {
  transform: translateY(0);
}

.form-message {
  margin-top: 1rem;
  padding: 1rem;
  border-radius: 8px;
  text-align: center;
  font-weight: 500;
  display: none;
}

.form-message.success {
  background: #d4edda;
  color: #155724;
  border: 1px solid #c3e6cb;
  display: block;
}

.form-message.error {
  background: #f8d7da;
  color: #721c24;
  border: 1px solid #f5c6cb;
  display: block;
}

.form-message.info {
  background: #d1ecf1;
  color: #0c5460;
  border: 1px solid #bee5eb;
  display: block;
}

.contact-info {
  display: flex;
  flex-direction: column;
  gap: 1.2rem;
}

.info-card {
  background: linear-gradient(135deg, rgba(15, 42, 86, 0.05) 0%, rgba(187, 138, 53, 0.05) 100%);
  padding: 1.5rem;
  border-radius: 12px;
  border-left: 4px solid var(--accent);
}

.info-card h3 {
  color: var(--primary);
  font-size: 1.1rem;
  margin-bottom: 0.5rem;
}

.info-card p {
  color: #5a6a7a;
  margin: 0;
  line-height: 1.5;
}

.info-card a {
  color: var(--accent);
  text-decoration: none;
  font-weight: 600;
}

.info-card a:hover {
  text-decoration: underline;
}

@media (max-width: 768px) {
  .nav-wrap {
    flex-direction: column;
    align-items: flex-start;
    gap: 1rem;
  }

  .main-nav {
    width: 100%;
    flex-direction: column;
  }

  .main-nav a {
    display: block;
    width: 100%;
  }

  .nav-logo {
    width: 62px;
    height: 62px;
  }

  .hero {
    padding-top: 4rem;
    padding-bottom: 3rem;
  }

  .hero-logo-wrap {
    border-radius: 14px;
    padding: 0.45rem 0.8rem;
    margin: 0.75rem auto 1rem;
  }

  h1 {
    font-size: 1.8rem;
  }

  .law-grid,
  .about-grid,
  .service-cards,
  .practice-grid {
    grid-template-columns: 1fr;
  }

  .law-card h3 {
    font-size: 0.95rem;
  }

  .container {
    width: 95%;
  }
}

@media (min-width: 769px) and (max-width: 1024px) {
  .law-grid,
  .about-grid,
  .service-cards,
  .practice-grid {
    grid-template-columns: repeat(2, 1fr);
  }

  h1 {
    font-size: 2.2rem;
  }
}

@media (max-width: 480px) {
  .hero {
    padding: 2rem 0;
  }

  .hero-actions {
    flex-direction: column;
  }

  .btn {
    width: 100%;
    text-align: center;
  }

  .main-nav a {
    padding: 0.5rem 0;
    font-size: 0.9rem;
  }
}

@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
    scroll-behavior: auto !important;
  }
}