/* IMPORTS */
@import url('https://fonts.googleapis.com/css2?family=Averia+Serif+Libre&family=Inter&display=swap');

/* THEME TOKENS */
:root {
  --lth-title-font-size: 4.5rem;
  --lth-heading-font-size: 2.3rem;
  --lth-cta-font-size: 1.1rem;
  --lth-body-font-size: 1.1rem;
  --lth-helper-font-size: 0.8rem;

  --gold: #D3BE87;
  --d-grey: #2A292B;
  --white: #F3EDE6;
  --m-green: #ECEEE7;
  --b-blue: #87CED3;
  --d-blue: #1A4E9C;
  --teal: #1A9C9C;
  --orange: #d86b05;
  --l-grey: #888888;

  --serif-font: 'Averia Serif Libre', serif;
  --sans-font: 'Inter', sans-serif;

  /* font-weight helpers used below */
  --regular: 400;
  --medium: 600;
}

/* 1) Contain horizontal overflow */
*,
*::before,
*::after {
  box-sizing: border-box;
}

html,
body {
  margin: 0;
  width: 100%;
  max-width: 100%;
  overflow-x: hidden;
}

/* Media should never exceed viewport width */
img,
video,
canvas,
svg {
  max-width: 100%;
  height: auto;
  display: block;
}

/* Ensure direct children of flex body don’t exceed width */
body.main>* {
  width: 100%;
}

/* A11y helper */
.visually-hidden {
  position: absolute !important;
  height: 1px;
  width: 1px;
  overflow: hidden;
  clip: rect(1px, 1px, 1px, 1px);
  white-space: nowrap;
  border: 0;
  padding: 0;
  margin: -1px;
}

/* FONTS */
.font-title {
  font-family: var(--serif-font);
  font-size: var(--lth-title-font-size);
  font-weight: var(--regular);
}

.font-body {
  font-family: var(--sans-font);
  font-size: var(--lth-body-font-size);
  font-weight: var(--regular);
  line-height: 2.2rem;
}

.font-small {
  font-family: var(--sans-font);
  font-size: var(--lth-helper-font-size);
  font-weight: var(--light);
  line-height: 1.2rem;
}

.font-cta {
  font-family: var(--sans-font);
  font-size: var(--lth-cta-font-size);
  font-weight: var(--medium);
}

.font-header {
  font-family: var(--serif-font);
  font-size: var(--lth-heading-font-size);
  font-weight: var(--regular);
}

/* Font Colors */
.font-white {
  color: var(--white);
}

.font-gold {
  color: var(--gold);
}

.font-black {
  color: var(--d-grey);
}

.font-mgreen {
  color: var(--m-green);
}

.font-blue {
  color: var(--b-blue);
}

.font-dblue {
  color: var(--d-blue);
}

.font-teal {
  color: var(--teal);
}

.font-orange {
  color: var(--orange);
}

.font-grey {
  color: var(--l-grey);
}

/* Background Colors */
.bg-white {
  background-color: var(--white);
}

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

.bg-black {
  background-color: var(--d-grey);
}

.bg-mgreen {
  background-color: var(--m-green);
}

.bg-blue {
  background-color: var(--b-blue);
}

.bg-dblue {
  background-color: var(--d-blue);
}

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

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

.bg-grey {
  background-color: var(--l-grey);
}

/* ===== Text Shadows ===== */
.text-shadow-sm {
  text-shadow: 1px 1px 2px rgba(0,0,0,0.25);
}

.text-shadow-md {
  text-shadow: 2px 2px 4px rgba(0,0,0,0.35);
}

.text-shadow-lg {
  text-shadow: 3px 3px 6px rgba(0,0,0,0.45);
}

.text-shadow-none {
  text-shadow: none;
}

/* ===== Box Shadows ===== */
.shadow-sm {
  box-shadow: 0 1px 3px rgba(0,0,0,0.15);
}

.shadow-md {
  box-shadow: 0 3px 6px rgba(0,0,0,0.2);
}

.shadow-lg {
  box-shadow: 0 6px 12px rgba(0,0,0,0.25);
}

.shadow-xl {
  box-shadow: 0 10px 20px rgba(0,0,0,0.3);
}

.shadow-none {
  box-shadow: none;
}


/* Layout utilities */
.main {
  display: flex;
  flex-direction: column;
  justify-content: flex-start;
  align-items: center;
}

.container {
  width: 100%;
  max-width: 1440px;
}

.wrapper {
  width: 100%;
}

.spacer {
  margin-top: 2rem;
}

/* NAVIGATION */
#nav {
  display: flex;
  flex-direction: column;
  align-items: center;
  margin-top:2rem;
}

#nav-list {
  display: flex;
  flex-direction: row;
  justify-content: space-around;
  align-items: flex-end;
  gap: 2.5rem;
}

#nav-container {
  display: flex;
  justify-content: space-between;
  align-items: center;
  width: 100%;
}

#nav-toggle {
  display: none;
  background: none;
  border: none;
  font-size: 1.8rem;
  color: var(--white);
  cursor: pointer;
}

#nav-mobile {
  display: none;
  flex-direction: column;
  background: var(--d-grey);
  width: 100%;
  text-align: center;
}

#nav-mobile.open {
  display: flex;
}

.nav-mobile-item {
  padding: 1rem;
  border-top: 1px solid var(--gold);
}

/* Mobile breakpoint */
@media (max-width: 1220px) {
  #nav-list {
    display: none;
  }
  #nav-toggle {
    display: block;
  }
}


/* FOOTER */
#footer {
  display: flex;
  flex-direction: column;
  justify-content: flex-start;
  align-items: center;
  margin-bottom:2rem;
}

#footer-container {
  border-top: solid 2px var(--gold);
}

#footer-top {
  display: flex;
  flex-direction: row;
  justify-content: space-between;
  align-items: flex-start;
  margin-top: 2rem;
}

#footer-branding-box {
  border: 2px solid var(--gold);
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  padding: 2rem;
  background-color: #2e2d2f;
}

#footer-links {
  display: flex;
  flex-direction: row;
  justify-content: space-between;
  align-items: flex-start;
  gap: 8rem;
}

.footer-link-col {
  display: flex;
  flex-direction: column;
  justify-content: flex-start;
  align-items: flex-start;
  gap: 0.7rem;
}

.footer-col-header {
  margin-bottom: 1rem;
}

/* FIELDS */
.lth-input {
  width: 100%;
  margin-bottom: 1rem;
  background-color: #fff;
  border: 2px solid var(--l-grey);
  border-radius: 0.5rem;
  padding: 0 1rem;
  min-height: 3rem;
  font-family: var(--sans-font);
  font-size: var(--lth-body-font-size);
  font-weight: var(--regular);
  transition: border-color 160ms ease, box-shadow 160ms ease;
}

.lth-input::placeholder {
  color: #9ba3aa;
}

.lth-input:focus {
  outline: none;
  border-color: var(--teal);
  box-shadow: 0 0 0 3px color-mix(in srgb, var(--teal) 25%, transparent);
}

/* BUTTONS */
.lth-button {
  min-width: 10rem;
  padding: 0.7rem;
  height: 3rem;
  min-height: 3rem;
  font-family: var(--sans-font);
  font-size: var(--lth-cta-font-size);
  font-weight: var(--medium);
  border-radius: 0.5rem;
  border: 2px solid transparent;
  line-height: 1;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  cursor: pointer;
  transition: transform 80ms ease, box-shadow 160ms ease, background-color 160ms ease, border-color 160ms ease;
  width:auto;
}

.btn--primary {
  background: var(--d-blue);
  color: var(--white);
  border-color: var(--d-blue);
}

.btn--primary:hover {
  box-shadow: 0 3px 10px rgba(26, 78, 156, 0.25);
}

.btn--primary:active {
  transform: translateY(1px);
}

.btn--primary:focus-visible {
  outline: 0;
  box-shadow: 0 0 0 3px color-mix(in srgb, var(--d-blue) 30%, transparent);
}

.btn--ghost {
  background: transparent;
  color: var(--d-grey);
  border-color: var(--gold);
}

.btn--ghost:hover {
  background: color-mix(in srgb, var(--gold) 12%, transparent);
}

.btn--ghost:active {
  transform: translateY(1px);
}

/* REVIEWS */
#reviews {
  display: flex;
  flex-wrap: wrap;
  gap: 2rem;
  justify-content: space-between;
  margin-top: 2rem;
  max-width:1400px;
}

.review-card {
  background-color: var(--white);
  border: 1px solid var(--l-grey);
  padding: 1.5rem;
  flex: 1;
  font-family: var(--sans-font);
  box-shadow: 0 2px 6px rgba(0, 0, 0, 0.05);
  border-radius: 0.5rem;
  min-height: 12rem;
}

.review-stars {
  color: var(--gold);
  font-size: 1.4rem;
  margin-bottom: 0.5rem;
}

.review-words {
  font-size: 1.1rem;
  margin-bottom: 0.75rem;
  font-style: italic;
  color: var(--d-grey);
}

.review-name {
  text-align: right;
  font-weight: bold;
  color: var(--l-grey);
}

/* Home eval */
.home-eval-banner {
  width: 100%;
  height: 5rem;
  background-color: var(--gold);
  display: flex;
  flex-direction: row;
  justify-content: center;
  align-items: center;
}

.home-eval-inner {
  width: 90%;
  display: flex;
  flex-direction: row;
  justify-content: space-between;
  align-items: center;
}

.home-eval-banner-text {
  font-size: 2rem !important;
}

.home-eval-banner-input {
  width: 30rem;
  margin-bottom: 0;
}

.home-eval-field-wrapper {
  display: flex;
  flex-direction: row;
  gap: 0.5rem;
}

/* Base: side-by-side */
.lr-section {
  display: flex;
  flex-direction: row;
  justify-content: space-between;
  align-items: flex-start;
  height: 40rem;
  min-height: 40rem;
  gap:3rem;
}

.lr-image {
  height: 40rem;
  width: 40rem;
  flex-shrink: 0;
}

.lr-content {
  display: flex;
  flex-direction: column;
  justify-content: flex-start;
  align-items: flex-start;
  padding: 4rem 0;
  gap: 1rem;
  width: 60rem;
}

.lr-right {
  margin-left: auto;
  margin-right: calc((100vw - 1440px) / 2);
}

.lr-left {
  margin-right: auto;
  margin-left: calc((100vw - 1440px) / 2);
}


/* ===== SEARCH BAR / FILTERS ===== */
.search-bar {
  width: 100%;
  margin: 1rem 0 2rem;
}

.search-filters {
  border: 2px solid var(--gold);
  border-radius: 0.5rem;
  background: var(--m-green);
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.05);
}

.search-filters__summary {
  list-style: none;
  user-select: none;
  cursor: pointer;
  padding: 0.85rem 1.2rem;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.75rem;
  font-family: var(--sans-font);
  font-weight: 600;
  color: var(--d-grey);
  position: relative;
}

.search-filters__summary::-webkit-details-marker {
  display: none;
}

.search-filters__summary::after {
  content: '';
  width: 0.55rem;
  height: 0.55rem;
  border-right: 2px solid var(--d-grey);
  border-bottom: 2px solid var(--d-grey);
  transform: rotate(45deg);
  transition: transform 180ms ease;
}

.search-filters[open] .search-filters__summary::after {
  transform: rotate(-135deg);
}

.search-form {
  padding: 1rem 1.2rem 1.25rem;
  border-top: 2px solid var(--gold);
  background: var(--white);
  border-bottom-left-radius: 0.5rem;
  border-bottom-right-radius: 0.5rem;
}

/* Grid for fields */
.search-form__grid {
  display: grid;
  gap: 1rem;
  grid-template-columns: 2fr 1fr 1fr 1fr;
}

.search-form__field label {
  display: block;
  margin-bottom: 0.35rem;
  font-family: var(--sans-font);
  font-size: 0.95rem;
  color: var(--d-grey);
  letter-spacing: 0.02em;
}

.search-form__field--search {
  grid-column: span 2;
}

/* Actions row */
.search-form__actions {
  display: flex;
  gap: 0.75rem;
  justify-content: flex-end;
  margin-top: 0.75rem;
  flex-wrap: wrap;
}

/* Results empty helper */
.empty {
  font-family: var(--sans-font);
  color: var(--d-grey);
  background: var(--m-green);
  border: 2px dashed var(--gold);
  border-radius: 0.5rem;
  padding: 1rem;
  text-align: center;
}




@media (max-width: 1480px){
  #footer-container{
    width: 96%;
  }
}


/* Responsive breakpoint */
@media (max-width: 1460px) {
  .lr-section {
    align-items: center;
    justify-content: center;
    gap:0;
  }

  .lr-content {
    margin: auto;
    padding: 2rem;
  }

  #nav{
    width:96%;
    margin-left:auto;
    margin-right:auto;
  }

  .lr-content p {
    font-size: clamp(0.9rem, 1.2vw, 1.1rem);
  }

  .lr-content .lth-button {
    font-size: clamp(0.9rem, 1vw, 1.1rem);
  }

  #reviews {
    max-width: 1200px;;
  }

}


@media (max-width: 1300px){
  #footer-top{
    flex-direction: column;
    gap:2rem;
    align-self:center;
  }
}


@media (max-width: 1240px){
  .lr-content p {
    line-height:2;
  }
}




@media (max-width: 1220px){
  #nav-list{
    display:none;
  }

  .home-eval-banner{
    height:auto;
  }

  .home-eval-inner{
    flex-direction: column;
    gap:2rem;
    margin-top:2rem;
    margin-bottom:2rem;
  }

  #reviews {
    max-width:1000px;
  }

  .lr-section {
    flex-direction: column;
    align-items: center;
    height: auto;
    min-height: auto;
  }

  .lr-image {
    order: -1; /* image always goes first */
    width: 100%;
    height: auto;
    max-width: 100%;
    margin-top:3rem;
  }

  .lr-content {
    width: 100%;
    padding: 2rem 1rem;
    margin: 0;
  }

  .lr-right,
  .lr-left {
    margin: 0;
  }

  #hero-squares{
    display:none;
  }
}




/* RESPONSIVE */
@media (max-width:1024px) {
  .search-form__grid {
    grid-template-columns: 1.5fr 1fr 1fr;
  }

  .search-form__field--search {
    grid-column: 1 / -1;
  }

  #reviews {
    flex-direction:column;
    max-width:600px;
  }
  
}


@media (max-width:940px){
  #footer-links{
    gap:2rem;
    flex-direction: column;
  }

  .footer-link-col{
    gap:0;
  }
}

@media (max-width:704px) {
  .home-eval-field-wrapper{
    flex-direction: column;
    align-items: center;
  }

  .lr-section{
    gap:0;
  }

  .lr-image{
    margin-top:0;
  }

  #footer-top{
    margin-left:auto;
    margin-right:auto;
    width:80%;
  }

  #footer-branding-box{
    align-self:center;
  }
}

@media (max-width:680px) {
  .search-form__grid {
    grid-template-columns: 1fr;
  }

  .search-form__actions {
    justify-content: stretch;
  }

  #reviews {
    max-width:350px;
  }
}


