/* OF Enterprises Ltd - component styles (plain CSS, works alongside the Tailwind CDN) */

html {
  scroll-padding-top: 5.5rem;
  scroll-behavior: smooth;
}

body {
  font-family: 'Inter', system-ui, -apple-system, 'Segoe UI', Roboto, sans-serif;
}

/* Skip link */
.skip-link {
  position: absolute;
  left: 1rem;
  top: -4rem;
  z-index: 100;
  padding: 0.75rem 1.25rem;
  border-radius: 0.75rem;
  background: #2B211C;
  color: #FFF8EE;
  font-weight: 600;
  text-decoration: none;
  transition: top 0.15s ease;
}
.skip-link:focus {
  top: 1rem;
}

main:focus {
  outline: none;
}

/* Focus states */
a:focus-visible,
button:focus-visible,
[tabindex]:focus-visible {
  outline: 3px solid #F2A93B;
  outline-offset: 3px;
  border-radius: 0.5rem;
}
#why a:focus-visible,
footer a:focus-visible,
footer button:focus-visible {
  outline-color: #F2A93B;
}
.btn-primary:focus-visible,
.mobile-link:focus-visible {
  outline-color: #2B211C;
}

/* Navigation */
.nav-link {
  display: inline-flex;
  align-items: center;
  padding: 0.5rem 0.9rem;
  border-radius: 9999px;
  font-size: 0.95rem;
  font-weight: 500;
  color: #2B211C;
  text-decoration: none;
  transition: background-color 0.15s ease, color 0.15s ease;
}
.nav-link:hover {
  background: rgba(200, 68, 47, 0.08);
  color: #A9361F;
}

.mobile-link {
  display: block;
  padding: 0.85rem 1rem;
  border-radius: 0.85rem;
  font-weight: 600;
  color: #2B211C;
  text-decoration: none;
}
.mobile-link:hover {
  background: rgba(43, 33, 28, 0.06);
}

/* Buttons */
.btn-primary,
.btn-secondary {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  min-height: 3.25rem;
  padding: 0.85rem 1.75rem;
  border-radius: 9999px;
  font-weight: 600;
  text-decoration: none;
  transition: background-color 0.15s ease, color 0.15s ease, transform 0.15s ease, box-shadow 0.15s ease;
}
.btn-primary {
  background: #C8442F;
  color: #FFFFFF;
  box-shadow: 0 10px 24px -10px rgba(200, 68, 47, 0.6);
}
.btn-primary:hover {
  background: #A9361F;
  transform: translateY(-1px);
}
.btn-secondary {
  background: #FFFFFF;
  color: #2B211C;
  border: 2px solid rgba(43, 33, 28, 0.15);
}
.btn-secondary:hover {
  border-color: #2B211C;
}

/* Section headings */
.eyebrow {
  font-size: 0.875rem;
  font-weight: 600;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: #C8442F;
}
.section-title {
  margin-top: 0.75rem;
  font-family: 'Rubik', system-ui, sans-serif;
  font-size: 1.875rem;
  line-height: 1.15;
  font-weight: 700;
  letter-spacing: -0.01em;
  color: #2B211C;
}
@media (min-width: 640px) {
  .section-title { font-size: 2.25rem; }
}

/* Service cards */
.service-card {
  display: flex;
  flex-direction: column;
  padding: 1.75rem;
  border-radius: 1.5rem;
  background: #FFFFFF;
  border: 1px solid rgba(43, 33, 28, 0.08);
  box-shadow: 0 12px 30px -18px rgba(43, 33, 28, 0.35);
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}
.service-card:hover {
  transform: translateY(-3px);
  box-shadow: 0 18px 36px -18px rgba(43, 33, 28, 0.45);
}
.icon-tile {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 3.5rem;
  height: 3.5rem;
  border-radius: 1rem;
}

/* Footer */
.footer-link {
  color: inherit;
  text-decoration: none;
  background: none;
  border: 0;
  padding: 0;
  font: inherit;
  cursor: pointer;
}
.footer-link:hover {
  color: #F2A93B;
}

/* Legal modals */
.legal-modal {
  width: min(44rem, calc(100% - 2rem));
  max-height: calc(100vh - 2rem);
  margin: auto;
  padding: 0;
  border: 0;
  border-radius: 1.5rem;
  background: #FFF8EE;
  color: #2B211C;
  box-shadow: 0 30px 60px -20px rgba(0, 0, 0, 0.5);
}
.legal-modal::backdrop {
  background: rgba(43, 33, 28, 0.6);
}
.legal-modal__inner {
  display: flex;
  flex-direction: column;
  max-height: calc(100vh - 2rem);
}
.legal-modal__head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  padding: 1.25rem 1.5rem;
  border-bottom: 1px solid rgba(43, 33, 28, 0.1);
}
.legal-modal__body {
  overflow-y: auto;
  padding: 1.25rem 1.5rem 1.75rem;
  line-height: 1.65;
}
.legal-modal__body h3 {
  margin-top: 1.25rem;
  font-family: 'Rubik', system-ui, sans-serif;
  font-size: 1.1rem;
  font-weight: 600;
}
.legal-modal__body p {
  margin-top: 0.4rem;
}
.modal-close {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 2.75rem;
  height: 2.75rem;
  border-radius: 9999px;
  background: transparent;
  border: 0;
  color: #2B211C;
  cursor: pointer;
}
.modal-close:hover {
  background: rgba(43, 33, 28, 0.08);
}
body.modal-open {
  overflow: hidden;
}

/* Reduced motion */
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *,
  *::before,
  *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
    scroll-behavior: auto !important;
  }
  .service-card:hover,
  .btn-primary:hover {
    transform: none;
  }
}
