/* Studio Bessette Auto Warranty — Carserv-inspired theme */
:root {
  --primary: #0056b3;
  --primary-dark: #004494;
  --primary-light: #0d6efd;
  --dark: #333333;
  --dark-footer: #1a1a1a;
  --text: #666666;
  --text-dark: #222222;
  --white: #ffffff;
  --section-bg: #f8f9fa;
  --border: #e5e5e5;
  --success: #198754;
  --font: "Roboto", "Segoe UI", system-ui, sans-serif;
}

*,
*::before,
*::after {
  box-sizing: border-box;
}

body {
  margin: 0;
  font-family: var(--font);
  color: var(--text);
  line-height: 1.7;
  font-size: 15px;
}

h1, h2, h3, h4, h5, h6 {
  color: var(--text-dark);
  font-weight: 700;
  line-height: 1.3;
}

a {
  color: var(--primary);
  text-decoration: none;
  transition: color 0.2s;
}

a:hover {
  color: var(--primary-dark);
}

img {
  max-width: 100%;
  height: auto;
  display: block;
}

.container {
  width: 100%;
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 15px;
}

/* Top bar */
.top-bar {
  background: var(--primary-dark);
  color: var(--white);
  font-size: 13px;
  padding: 10px 0;
}

.top-bar-inner {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}

.top-bar a {
  color: var(--white);
}

.top-bar a:hover {
  opacity: 0.85;
}

.top-contacts {
  display: flex;
  flex-wrap: wrap;
  gap: 20px;
  align-items: center;
}

.top-contacts span,
.top-contacts a {
  display: inline-flex;
  align-items: center;
  gap: 8px;
}

.top-social {
  display: flex;
  gap: 12px;
  align-items: center;
}

.top-social a {
  width: 32px;
  height: 32px;
  border: 1px solid rgba(255, 255, 255, 0.35);
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 2px;
  font-size: 14px;
}

/* Free Quote — must override .top-social a icon sizing */
.top-social a.btn-quote,
a.btn-quote {
  width: auto;
  height: auto;
  min-height: 36px;
  padding: 9px 22px;
  background: var(--white);
  color: var(--primary) !important;
  font-weight: 700;
  font-size: 13px;
  line-height: 1.2;
  letter-spacing: 0.02em;
  text-transform: uppercase;
  border-radius: 2px;
  border: none;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  white-space: nowrap;
  flex-shrink: 0;
  box-shadow: 0 2px 6px rgba(0, 0, 0, 0.12);
  transition: background 0.2s, color 0.2s, box-shadow 0.2s;
}

.top-social a.btn-quote:hover,
a.btn-quote:hover {
  opacity: 1;
  background: #f0f4f8;
  color: var(--primary-dark) !important;
  box-shadow: 0 3px 10px rgba(0, 0, 0, 0.16);
}

/* Header */
.main-header {
  background: var(--white);
  box-shadow: 0 2px 12px rgba(0, 0, 0, 0.08);
  position: sticky;
  top: 0;
  z-index: 1000;
}

.header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 12px 0;
  gap: 20px;
}

.logo-link {
  display: flex;
  align-items: center;
  gap: 12px;
}

.logo-link img.logo-img {
  height: 52px;
  width: auto;
}

.logo-text {
  font-size: 22px;
  font-weight: 800;
  color: var(--text-dark);
  line-height: 1.1;
}

.logo-text small {
  display: block;
  font-size: 11px;
  font-weight: 600;
  color: var(--primary);
  letter-spacing: 0.5px;
  text-transform: uppercase;
}

.nav-toggle {
  display: none;
  background: none;
  border: none;
  font-size: 26px;
  color: var(--primary);
  cursor: pointer;
  padding: 4px 8px;
}

.main-nav ul {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  flex-wrap: wrap;
  gap: 4px;
}

.main-nav a {
  color: var(--text-dark);
  font-weight: 500;
  padding: 10px 14px;
  display: block;
  font-size: 14px;
  text-transform: capitalize;
}

.main-nav a:hover,
.main-nav a.active {
  color: var(--primary);
}

/* Buttons */
.btn {
  display: inline-block;
  padding: 12px 28px;
  font-weight: 600;
  font-size: 14px;
  border-radius: 2px;
  border: 2px solid transparent;
  cursor: pointer;
  text-align: center;
  transition: all 0.2s;
  font-family: inherit;
}

.btn-primary {
  background: var(--primary);
  color: var(--white) !important;
  border-color: var(--primary);
}

.btn-primary:hover {
  background: var(--primary-dark);
  border-color: var(--primary-dark);
  color: var(--white) !important;
}

.btn-outline {
  background: transparent;
  color: var(--primary) !important;
  border-color: var(--primary);
}

.btn-outline:hover {
  background: var(--primary);
  color: var(--white) !important;
}

.btn-white {
  background: var(--white);
  color: var(--primary) !important;
}

.btn-white:hover {
  background: #eee;
}

/* Hero */
.hero {
  position: relative;
  min-height: 520px;
  display: flex;
  align-items: center;
  background-size: cover;
  background-position: center;
  color: var(--white);
}

.hero::before {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(90deg, rgba(0, 40, 90, 0.88) 0%, rgba(0, 86, 179, 0.55) 100%);
}

.hero .container {
  position: relative;
  z-index: 1;
  padding: 80px 15px;
}

.hero h1 {
  color: var(--white);
  font-size: clamp(28px, 5vw, 48px);
  margin: 0 0 16px;
  text-transform: uppercase;
  letter-spacing: 1px;
}

.hero p {
  font-size: 16px;
  max-width: 560px;
  margin-bottom: 28px;
  opacity: 0.95;
}

.hero-badges {
  display: flex;
  flex-wrap: wrap;
  gap: 24px;
  margin-top: 36px;
}

.hero-badge {
  display: flex;
  align-items: center;
  gap: 12px;
}

.hero-badge i {
  font-size: 36px;
  color: #7ec8ff;
}

.hero-badge strong {
  display: block;
  font-size: 20px;
  color: var(--white);
}

/* Section */
.section {
  padding: 70px 0;
}

.section-alt {
  background: var(--section-bg);
}

.section-dark {
  background: var(--dark);
  color: #ccc;
}

.section-dark h2,
.section-dark h3 {
  color: var(--white);
}

.section-title {
  text-align: center;
  max-width: 720px;
  margin: 0 auto 48px;
}

.section-title span.sub {
  color: var(--primary);
  font-weight: 600;
  font-size: 14px;
  text-transform: uppercase;
  letter-spacing: 1px;
  display: block;
  margin-bottom: 8px;
}

.section-title h2 {
  font-size: clamp(24px, 4vw, 36px);
  margin: 0 0 12px;
}

.section-title p {
  margin: 0;
}

/* About grid */
.two-col {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 40px;
  align-items: center;
}

.about-images {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 12px;
}

.about-images img:first-child {
  grid-column: 1 / -1;
}

/* Feature cards */
.feature-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 24px;
}

.feature-card {
  background: var(--white);
  padding: 32px 24px;
  text-align: center;
  border: 1px solid var(--border);
  border-radius: 2px;
  transition: box-shadow 0.25s, transform 0.25s;
}

.feature-card:hover {
  box-shadow: 0 12px 30px rgba(0, 86, 179, 0.12);
  transform: translateY(-4px);
}

.feature-icon {
  width: 64px;
  height: 64px;
  margin: 0 auto 18px;
  background: rgba(0, 86, 179, 0.08);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 28px;
  color: var(--primary);
}

.feature-card h4 {
  margin: 0 0 10px;
  font-size: 18px;
}

.feature-card p {
  margin: 0;
  font-size: 14px;
}

/* Stats */
.stats-section {
  position: relative;
  background-size: cover;
  background-position: center;
  padding: 70px 0;
}

.stats-section::before {
  content: "";
  position: absolute;
  inset: 0;
  background: rgba(51, 51, 51, 0.92);
}

.stats-grid {
  position: relative;
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 24px;
  text-align: center;
}

.stat-item i {
  font-size: 40px;
  color: var(--primary-light);
  margin-bottom: 12px;
}

.stat-item h3 {
  color: var(--white);
  font-size: 36px;
  margin: 0 0 6px;
}

.stat-item p {
  color: #aaa;
  margin: 0;
  text-transform: uppercase;
  font-size: 13px;
  letter-spacing: 0.5px;
}

/* Service cards */
.service-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 28px;
}

.service-card {
  background: var(--white);
  border: 1px solid var(--border);
  overflow: hidden;
  border-radius: 2px;
}

.service-card img {
  width: 100%;
  height: 220px;
  object-fit: cover;
}

.service-card-body {
  padding: 24px;
}

.service-card h4 {
  margin: 0 0 10px;
}

.service-card p {
  margin: 0 0 16px;
  font-size: 14px;
}

/* Pricing */
.pricing-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 20px;
  align-items: stretch;
}

.price-card {
  background: var(--white);
  border: 1px solid var(--border);
  padding: 36px 24px;
  text-align: center;
  border-radius: 2px;
}

.price-card.featured {
  background: var(--primary);
  color: var(--white);
  transform: scale(1.03);
  box-shadow: 0 16px 40px rgba(0, 86, 179, 0.35);
}

.price-card.featured h3,
.price-card.featured .price,
.price-card.featured li {
  color: var(--white);
}

.price-card h3 {
  margin: 0 0 8px;
  font-size: 22px;
}

.price {
  font-size: 42px;
  font-weight: 800;
  color: var(--primary);
  margin: 16px 0;
}

.price span {
  font-size: 16px;
  font-weight: 400;
}

.price-card ul {
  list-style: none;
  padding: 0;
  margin: 24px 0;
  text-align: left;
  font-size: 14px;
}

.price-card li {
  padding: 8px 0;
  border-bottom: 1px solid var(--border);
  display: flex;
  align-items: flex-start;
  gap: 8px;
}

.price-card.featured li {
  border-color: rgba(255, 255, 255, 0.2);
}

.price-card li i {
  color: var(--primary);
  margin-top: 3px;
}

.price-card.featured li i {
  color: #7ec8ff;
}

/* Team */
.team-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 24px;
}

.team-card {
  background: var(--white);
  border: 1px solid var(--border);
  text-align: center;
  overflow: hidden;
  border-radius: 2px;
}

.team-card img {
  width: 100%;
  height: 280px;
  object-fit: cover;
}

.team-card-body {
  padding: 20px;
}

.team-card h4 {
  margin: 0 0 4px;
}

.team-role {
  color: var(--primary);
  font-size: 13px;
  font-weight: 600;
  margin-bottom: 12px;
}

.team-social {
  display: flex;
  justify-content: center;
  gap: 10px;
}

.team-social a {
  width: 34px;
  height: 34px;
  border: 1px solid var(--border);
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--text);
  border-radius: 2px;
}

.team-social a:hover {
  background: var(--primary);
  color: var(--white);
  border-color: var(--primary);
}

/* Video CTA */
.video-cta {
  position: relative;
  min-height: 380px;
  display: flex;
  align-items: center;
  justify-content: center;
  text-align: center;
  background-size: cover;
  background-position: center;
}

.video-cta::before {
  content: "";
  position: absolute;
  inset: 0;
  background: rgba(33, 33, 33, 0.82);
}

.video-cta .container {
  position: relative;
  z-index: 1;
}

.play-btn {
  width: 80px;
  height: 80px;
  border-radius: 50%;
  background: var(--primary);
  color: var(--white);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-size: 28px;
  margin-bottom: 20px;
  border: 4px solid rgba(255, 255, 255, 0.3);
}

.video-cta h2 {
  color: var(--white);
  margin: 0;
}

/* Gallery */
.gallery-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 12px;
}

.gallery-grid img {
  width: 100%;
  height: 200px;
  object-fit: cover;
  border-radius: 2px;
}

/* Testimonials */
.testimonial-section {
  background: var(--white) url("data:image/svg+xml,%3Csvg width='60' height='60' viewBox='0 0 60 60' xmlns='http://www.w3.org/2000/svg'%3E%3Cg fill='none' fill-rule='evenodd'%3E%3Cg fill='%230056b3' fill-opacity='0.04'%3E%3Cpath d='M36 34v-4h-2v4h-4v2h4v4h2v-4h4v-2h-4zm0-30V0h-2v4h-4v2h4v4h2V6h4V4h-4zM6 34v-4H4v4H0v2h4v4h2v-4h4v-2H6zM6 4V0H4v4H0v2h4v4h2V6h4V4H6z'/%3E%3C/g%3E%3C/g%3E%3C/svg%3E");
}

.testimonial-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 30px;
}

.testimonial-box {
  background: var(--white);
  border: 1px solid var(--border);
  padding: 32px;
  border-radius: 2px;
  position: relative;
}

.testimonial-box::before {
  content: "\201C";
  font-size: 64px;
  color: var(--primary);
  opacity: 0.25;
  position: absolute;
  top: 8px;
  left: 20px;
  line-height: 1;
}

.testimonial-author {
  display: flex;
  align-items: center;
  gap: 14px;
  margin-top: 20px;
}

.testimonial-author img {
  width: 56px;
  height: 56px;
  border-radius: 50%;
  object-fit: cover;
}

/* Blog cards */
.blog-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 28px;
}

.blog-card {
  border: 1px solid var(--border);
  background: var(--white);
  overflow: hidden;
}

.blog-card img {
  height: 200px;
  width: 100%;
  object-fit: cover;
}

.blog-card-body {
  padding: 22px;
}

.blog-date {
  color: var(--primary);
  font-size: 13px;
  font-weight: 600;
}

/* Page banner */
.page-banner {
  background: var(--primary);
  color: var(--white);
  padding: 48px 0;
  text-align: center;
}

.page-banner h1 {
  color: var(--white);
  margin: 0 0 8px;
  font-size: 36px;
}

.breadcrumb {
  font-size: 14px;
  opacity: 0.9;
}

.breadcrumb a {
  color: var(--white);
}

/* Contact */
.contact-grid {
  display: grid;
  grid-template-columns: 1fr 1.2fr;
  gap: 40px;
}

.contact-info-item {
  display: flex;
  gap: 16px;
  margin-bottom: 28px;
}

.contact-info-item i {
  width: 48px;
  height: 48px;
  background: rgba(0, 86, 179, 0.1);
  color: var(--primary);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 20px;
  flex-shrink: 0;
  border-radius: 2px;
}

/* Forms */
.form-group {
  margin-bottom: 18px;
}

.form-group label {
  display: block;
  margin-bottom: 6px;
  font-weight: 600;
  color: var(--text-dark);
  font-size: 14px;
}

.form-control {
  width: 100%;
  padding: 12px 14px;
  border: 1px solid var(--border);
  border-radius: 2px;
  font-family: inherit;
  font-size: 15px;
  transition: border-color 0.2s;
}

.form-control:focus {
  outline: none;
  border-color: var(--primary);
  box-shadow: 0 0 0 3px rgba(0, 86, 179, 0.12);
}

.form-control.is-invalid {
  border-color: #dc3545;
}

.invalid-feedback {
  color: #dc3545;
  font-size: 13px;
  margin-top: 4px;
  display: none;
}

.form-control.is-invalid + .invalid-feedback,
.checkbox-group.is-invalid .invalid-feedback {
  display: block;
}

.form-row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 18px;
}

.checkbox-group {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  margin-bottom: 18px;
}

.checkbox-group input[type="checkbox"] {
  width: 18px;
  height: 18px;
  margin: 3px 0 0;
  flex-shrink: 0;
  accent-color: var(--primary);
  cursor: pointer;
}

.checkbox-group label {
  margin: 0;
  font-weight: 400;
  font-size: 14px;
  line-height: 1.5;
  cursor: pointer;
}

.form-success {
  display: none;
  background: #d1e7dd;
  border: 1px solid #badbcc;
  color: #0f5132;
  padding: 16px 20px;
  border-radius: 2px;
  margin-bottom: 20px;
  font-weight: 600;
}

.form-success.show {
  display: block;
}

/* Legal content */
.legal-content {
  max-width: 900px;
  margin: 0 auto;
}

.legal-content h2 {
  font-size: 22px;
  margin-top: 36px;
}

.legal-content h3 {
  font-size: 18px;
  margin-top: 24px;
}

.legal-content ul,
.legal-content ol {
  padding-left: 24px;
}

.legal-content li {
  margin-bottom: 8px;
}

/* Project cards */
.project-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 24px;
}

.project-card {
  position: relative;
  overflow: hidden;
  border-radius: 2px;
}

.project-card img {
  width: 100%;
  height: 260px;
  object-fit: cover;
  transition: transform 0.4s;
}

.project-card:hover img {
  transform: scale(1.05);
}

.project-overlay {
  position: absolute;
  inset: 0;
  background: linear-gradient(to top, rgba(0, 86, 179, 0.9), transparent);
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
  padding: 24px;
  color: var(--white);
}

.project-overlay h4 {
  color: var(--white);
  margin: 0 0 6px;
}

/* Newsletter bar */
.newsletter-bar {
  background: var(--primary);
  padding: 36px 0;
  color: var(--white);
}

.newsletter-inner {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
}

.newsletter-inner h3 {
  color: var(--white);
  margin: 0;
}

.newsletter-form {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  flex: 1;
  max-width: 480px;
  align-items: flex-start;
}

.newsletter-form .invalid-feedback {
  flex: 1 1 100%;
}

.newsletter-form input {
  flex: 1;
  min-width: 200px;
  padding: 12px 14px;
  border: none;
  border-radius: 2px;
}

/* Footer */
.main-footer {
  background: var(--dark-footer);
  color: #aaa;
  padding: 60px 0 0;
  font-size: 14px;
}

.footer-grid {
  display: grid;
  grid-template-columns: 1.3fr 1fr 1fr 1fr;
  gap: 36px;
  padding-bottom: 40px;
}

.footer-grid h4 {
  color: var(--white);
  margin: 0 0 20px;
  font-size: 18px;
}

.footer-about p {
  margin: 16px 0;
}

.footer-social {
  display: flex;
  gap: 10px;
}

.footer-social a {
  width: 36px;
  height: 36px;
  background: rgba(255, 255, 255, 0.08);
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--white);
  border-radius: 2px;
}

.footer-social a:hover {
  background: var(--primary);
}

.footer-links {
  list-style: none;
  padding: 0;
  margin: 0;
}

.footer-links li {
  margin-bottom: 10px;
}

.footer-links a {
  color: #aaa;
}

.footer-links a:hover {
  color: var(--white);
}

.footer-news-item {
  display: flex;
  gap: 12px;
  margin-bottom: 16px;
}

.footer-news-item img {
  width: 64px;
  height: 64px;
  object-fit: cover;
  border-radius: 2px;
  flex-shrink: 0;
}

.footer-bottom {
  border-top: 1px solid rgba(255, 255, 255, 0.08);
  padding: 18px 0;
  text-align: center;
  font-size: 13px;
}

.footer-legal {
  margin-top: 8px;
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 16px;
}

.footer-legal a {
  color: #888;
}

.footer-legal a:hover {
  color: var(--white);
}

/* Work steps */
.steps-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 24px;
  text-align: center;
}

.step-num {
  width: 56px;
  height: 56px;
  background: var(--primary);
  color: var(--white);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 800;
  font-size: 20px;
  margin: 0 auto 16px;
}

/* Responsive */
@media (max-width: 992px) {
  .two-col,
  .contact-grid {
    grid-template-columns: 1fr;
  }

  .feature-grid,
  .service-grid,
  .blog-grid,
  .project-grid,
  .gallery-grid {
    grid-template-columns: repeat(2, 1fr);
  }

  .stats-grid,
  .team-grid,
  .pricing-grid {
    grid-template-columns: repeat(2, 1fr);
  }

  .price-card.featured {
    transform: none;
  }

  .footer-grid {
    grid-template-columns: 1fr 1fr;
  }

  .steps-grid {
    grid-template-columns: repeat(2, 1fr);
  }
}

@media (max-width: 768px) {
  .nav-toggle {
    display: block;
  }

  .main-nav {
    display: none;
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    background: var(--white);
    box-shadow: 0 8px 20px rgba(0, 0, 0, 0.1);
    padding: 12px;
  }

  .main-nav.open {
    display: block;
  }

  .main-nav ul {
    flex-direction: column;
  }

  .main-header .container {
    position: relative;
  }

  .feature-grid,
  .service-grid,
  .blog-grid,
  .testimonial-grid,
  .project-grid,
  .gallery-grid,
  .stats-grid,
  .team-grid,
  .pricing-grid,
  .steps-grid,
  .form-row {
    grid-template-columns: 1fr;
  }

  .footer-grid {
    grid-template-columns: 1fr;
  }

  .hero {
    min-height: 420px;
  }
}