/*
 * RSVP Catering site styles. Layout comes from Bootstrap 5.3 (grid, spacing,
 * display and text utilities); this file only holds brand styles and the
 * handful of components Bootstrap doesn't cover.
 */

/* ---------- Brand tokens ---------- */

@font-face {
  font-family: 'Pierson';
  src: url('../fonts/pierson-regular.woff') format('woff');
  font-weight: 400;
}

@font-face {
  font-family: 'Pierson';
  src: url('../fonts/pierson-light.woff') format('woff');
  font-weight: 300;
}

:root {
  --rsvp-teal: #00666E;
  --rsvp-brown: #2E1008;
  --rsvp-gray: #4b4b4b;
  --rsvp-font-display: 'Pierson', serif;

  --bs-body-font-family: 'Open Sans', sans-serif;
  --bs-body-color: #000;
  --bs-link-color-rgb: inherit;
  --bs-link-hover-color-rgb: inherit;
  --bs-link-decoration: none;
}

.bg-teal { background-color: var(--rsvp-teal) !important; }
.text-teal { color: var(--rsvp-teal) !important; }
.font-display { font-family: var(--rsvp-font-display); }

/* ---------- Base typography ---------- */

/* Clip sections that start off-screen for the scroll reveal */
body { overflow-x: clip; }

a { color: inherit; text-decoration: none; }
a:hover { color: inherit; }

p {
  font-weight: 300;
  font-size: 1.1em;
  line-height: 1.75;
  letter-spacing: .1em;
  margin-bottom: 0;
}

address { font-size: inherit; }

/* Display headings, all in Pierson. Use on h1-h4 or spans. */
.heading-hero,
.heading-xl,
.heading-lg,
.heading,
.heading-sm,
.heading-xs {
  font-family: var(--rsvp-font-display);
  font-weight: 400;
  line-height: 1.75;
  margin: 0;
}

.heading-hero { font-size: 2.25em; letter-spacing: .1em; }
.heading-xl { font-size: 3.5em; line-height: 1; }
.heading-lg { font-size: 2.5em; }
.heading { font-size: 2em; }
.heading-sm { font-size: 1.8em; font-weight: 300; }
.heading-xs { font-size: 1em; }

.lead-xl { font-size: 1.5em; letter-spacing: .2em; }

/* Thin divider under a heading; takes the colour of the surrounding text. */
.rule {
  display: block;
  border: 0;
  border-bottom: 1px solid currentColor;
  opacity: 1;
  margin: 0 15% 20px;
}

@media (min-width: 731px) {
  .heading-hero { font-size: 2.6em; }
  .heading { letter-spacing: .1em; }
  .heading-xs { font-size: 1.5em; }
  .lead-xl { font-size: 1.75em; }
}

/* ---------- Layout ---------- */

.site-main {
  width: 90%;
  margin: 0 auto 3rem;
}

.section-title {
  margin-top: 40px;
  text-align: center;
}

/* Teal block with white text: page intros, section banners. */
.panel {
  background-color: var(--rsvp-teal);
  color: #fff;
  text-align: center;
  padding: 20px;
}

@media (min-width: 731px) {
  .panel { padding: 80px 150px; }
  .panel-sm { padding: 20px; }
}

/* Full-width page banner photo */
.hero-img {
  width: 100%;
  min-height: 400px;
  max-height: 650px;
  object-fit: cover;
  margin: 3em 0;
}

/* Photo that fills its grid cell */
.cover-img {
  width: 100%;
  height: 100%;
  min-height: 350px;
  max-height: 600px;
  object-fit: cover;
}

/* ---------- Header ---------- */

.site-header { padding-top: 1%; }

/* SVG logo: width sets the size, height follows its 2.36:1 aspect ratio. */
.site-brand { position: relative; }
.site-brand > a { vertical-align: top; }

.site-logo { width: 300px; max-width: 100%; height: auto; }

@media (max-width: 991.98px) {
  .site-brand { margin-top: .75rem; }
  .site-logo { width: 156px; }
}

@media (max-width: 650px) {
  .site-logo { width: 111px; }
}

/* Desktop menu */
.site-nav {
  font-size: 1.2rem;
  font-weight: 300;
  letter-spacing: .2em;
}

.site-nav .nav-link {
  background: none;
  border: 0;
  padding: 0 5px;
  color: var(--rsvp-gray);
  white-space: nowrap;
  letter-spacing: inherit;
}

.site-nav .nav-link:hover,
.site-nav .nav-link:focus,
.site-nav .nav-link.show { color: #000; }

.site-nav .dropdown-menu {
  font-size: .75em;
  line-height: 1.5;
  text-align: center;
  padding: .75rem;
  border: 0;
  box-shadow: 0 2px 5px rgba(0, 0, 0, .1);
}

.site-nav .dropdown-item {
  color: var(--rsvp-gray);
  font-weight: 300;
  letter-spacing: .2em;
  padding: 0 5px;
}

.site-nav .dropdown-item + .dropdown-item { margin-top: .25rem; }

.site-nav .dropdown-item:hover,
.site-nav .dropdown-item:active { background: none; color: #000; }

/* Mobile menu: the toggle is vertically centred on the logo */
.menu-toggle {
  position: absolute;
  top: 50%;
  right: 4%;
  transform: translateY(-50%);
  padding: .5rem;
  border: 0;
  background: none;
  color: var(--rsvp-gray);
}

.mobile-nav {
  --bs-offcanvas-width: min(320px, 85vw);
  font-weight: 300;
  letter-spacing: .15em;
}

.mobile-nav-link {
  display: block;
  width: 100%;
  padding: .75rem 0;
  border: 0;
  border-bottom: 1px solid rgba(0, 0, 0, .08);
  background: none;
  text-align: left;
  color: var(--rsvp-gray);
  letter-spacing: inherit;
}

.mobile-nav-link:hover,
.mobile-nav-link[aria-current] { color: #000; }

.mobile-nav-link[aria-current] { font-weight: 500; }

/* Section toggle with a chevron that flips when open */
.mobile-nav-toggle {
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.mobile-nav-toggle::after {
  content: "";
  width: .5rem;
  height: .5rem;
  margin-right: .25rem;
  border-right: 1.5px solid currentColor;
  border-bottom: 1.5px solid currentColor;
  transform: translateY(-25%) rotate(45deg);
  transition: transform .2s;
}

.mobile-nav-toggle:not(.collapsed)::after { transform: translateY(25%) rotate(-135deg); }

.mobile-nav-sub {
  padding: .55rem 0 .55rem 1rem;
  font-size: .9em;
}

/* ---------- Buttons ---------- */

/* Brown button with double white border, used for every call to action. */
.btn-rsvp {
  display: inline-block;
  font-family: var(--rsvp-font-display);
  font-size: 1.125em;
  padding: 10px 15px;
  color: #fff;
  background-color: var(--rsvp-brown);
  border: 6px double #fff;
  border-radius: 0;
  text-align: center;
  cursor: pointer;
}

.btn-rsvp:hover,
.btn-rsvp:focus {
  color: #fff;
  background-color: rgba(200, 200, 200, .5);
}

/* Smaller header variant */
.btn-cta {
  font-size: 1rem;
  letter-spacing: .05em;
  padding: .5rem .75rem;
  color: #fff;
  background-color: var(--rsvp-brown);
  border: 4px double #fff;
  border-radius: 0;
}

.btn-cta:hover,
.btn-cta:focus { color: #fff; background-color: var(--rsvp-brown); opacity: .85; }

/* ---------- Scroll reveal (desktop only) ---------- */

@media (min-width: 600px) {
  .reveal {
    transform: translateX(100px);
    opacity: 0;
    transition: transform 1s, opacity 1s;
  }

  .reveal.show {
    transform: none;
    opacity: 1;
  }
}

/* ---------- Galleries ---------- */

/* Square thumbnail; a teal overlay (and optional caption) fades in on hover. */
.tile {
  position: relative;
  display: block;
  aspect-ratio: 1 / 1;
  overflow: hidden;
}

.tile img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.tile::after,
.tile-caption {
  position: absolute;
  inset: 0;
  opacity: 0;
  transition: opacity 100ms ease-in-out;
}

.tile::after {
  content: "";
  background-color: var(--rsvp-teal);
}

.tile:hover::after,
.tile:focus::after { opacity: .8; }

/* Magnifying glass on photos that open in the lightbox */
.tile[data-lightbox]::before {
  content: "";
  position: absolute;
  inset: 0;
  z-index: 1;
  opacity: 0;
  transition: opacity 100ms ease-in-out;
  background: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='white' stroke-width='1.75' stroke-linecap='round'%3E%3Ccircle cx='10.5' cy='10.5' r='6.5'/%3E%3Cpath d='M15.5 15.5 21 21M10.5 7.5v6M7.5 10.5h6'/%3E%3C/svg%3E") center / clamp(2rem, 25%, 4rem) no-repeat;
}

.tile[data-lightbox]:hover::before,
.tile[data-lightbox]:focus::before { opacity: 1; }

.tile-caption {
  z-index: 1;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: .5rem;
  color: #fff;
  font-family: var(--rsvp-font-display);
  font-weight: 300;
  font-size: clamp(1rem, 3vw, 2.5rem);
  text-transform: uppercase;
  text-align: center;
}

.tile:hover .tile-caption,
.tile:focus .tile-caption { opacity: 1; }

.lightbox .modal-content {
  background-color: rgba(0, 0, 0, .8);
  align-items: center;
  justify-content: center;
  cursor: pointer;
}

.lightbox-img {
  max-width: 80vw;
  max-height: 80vh;
}

.lightbox-nav {
  position: fixed;
  top: 48vh;
  padding: 6px 10px;
  border: 0;
  border-radius: 4px;
  background-color: #010101;
  color: #fff;
  font-family: Arial, sans-serif;
}

.lightbox-nav:hover { opacity: .8; }
.lightbox-prev { left: 5%; }
.lightbox-next { right: 5%; }

/* ---------- Team ---------- */

.team-card { width: 180px; }

.team-card img { width: 100%; height: auto; }

.team-name {
  font-family: var(--rsvp-font-display);
  font-weight: 400;
  font-size: 1em;
  line-height: 1;
  letter-spacing: normal;
  margin: .25rem 0;
}

.team-title {
  font-size: .8em;
  line-height: 1;
  letter-spacing: normal;
}

@media (min-width: 731px) {
  .team-card { width: 250px; }
  .team-name { font-size: 1.2em; }
  .team-title { font-size: .7em; }
}

/* ---------- Home ---------- */

/* Testimonial carousel */
.quotes .carousel-item {
  padding: 80px;
  min-height: 100%;
}

.quotes .carousel-control-prev,
.quotes .carousel-control-next { width: 3rem; }

.quotes .carousel-indicators {
  position: static;
  margin: 20px 0 0;
}

.quotes .carousel-indicators [data-bs-target] {
  width: 15px;
  height: 15px;
  border: 0;
  border-radius: 50%;
  background-color: #bbb;
  opacity: 1;
}

.quotes .carousel-indicators .active { background-color: #717171; }

/* Divider between the two home intro columns */
@media (min-width: 768px) {
  .col-divider { border-left: 1px solid #000; }
}

/* "Power Players" recognition popup */
.pp-modal .modal-content {
  border: 6px double #62231C;
  border-radius: 0;
  overflow: hidden;
}

.pp-modal .pp-header {
  position: relative;
  background-color: #62231C;
  padding: 2.5em 2em 1.5em;
}

.pp-modal .pp-body {
  background-color: #FEF5EE;
  padding: 1.5em 2em 2em;
}

.pp-modal .btn-close {
  position: absolute;
  top: .75em;
  right: .75em;
}

.pp-modal .pp-badge { max-width: 150px; width: 100%; }

.pp-modal .pp-headline {
  font-family: var(--rsvp-font-display);
  font-size: 1.6em;
  color: #FEF5EE;
  line-height: 1.15;
}

.pp-modal .pp-copy { font-size: 1.05em; color: #62231C; }
.pp-modal .btn-rsvp { background-color: #62231C; }
.pp-modal .btn-rsvp:hover { background-color: #7c2e24; }

@media (min-width: 577px) {
  .pp-modal .pp-headline { font-size: 2em; }
}

/* ---------- Workplace FAQ ---------- */

.faq {
  --bs-accordion-border-color: #000;
  --bs-accordion-btn-focus-box-shadow: none;
  --bs-accordion-active-bg: transparent;
  --bs-accordion-active-color: rgba(0, 0, 0, .8);
  --bs-accordion-btn-color: rgba(0, 0, 0, .8);
}

.faq .accordion-button { font-size: .9rem; }
.faq .accordion-body p { font-size: .95rem; }

/* ---------- Forms ---------- */

.form-control {
  border: 1px solid #000;
  border-radius: 0;
}

.form-control:focus {
  border-color: #000;
  background-color: rgba(8, 104, 131, .1);
  box-shadow: none;
}

.required::after { content: ' *'; }

/* ---------- Footer ---------- */

.site-footer {
  font-size: 12px;
  font-weight: 200;
}

.site-footer p { font-size: inherit; letter-spacing: normal; }
