/* ==========================================================================
   Little Button Chair Company
   All colours, fonts and spacing live in the :root block below.
   Change a value there and it updates everywhere on the site.
   ========================================================================== */

:root {
  --teal:        #00abaf;
  --yellow:      #fab51d;
  --dark:        #1a1a1a;
  --white:       #ffffff;
  --text:        #666666;
  --text-strong: #383838;
  --heading:     #333333;

  --font-head: "Playfair Display", Georgia, "Times New Roman", serif;
  --font-body: "Open Sans", Arial, Helvetica, sans-serif;

  --container: 1080px;
  --section-pad: 100px;
}

/* --- base ---------------------------------------------------------------- */

*, *::before, *::after { box-sizing: border-box; }

html { -webkit-text-size-adjust: 100%; }

body {
  margin: 0;
  font-family: var(--font-body);
  font-size: 18px;
  line-height: 1.8;
  color: var(--text);
  background: var(--white);
  overflow-x: hidden;
}

img { max-width: 100%; height: auto; display: block; }

a { color: inherit; }

h1, h2, h3 {
  font-family: var(--font-head);
  color: var(--heading);
  margin: 0 0 20px;
}

h1 { font-size: 50px; line-height: 1.4; font-weight: 700; }
h2 { font-size: 50px; line-height: 1.4; font-weight: 500; }

p { margin: 0 0 1.6em; }
p:last-child { margin-bottom: 0; }

.container {
  width: 80%;
  max-width: var(--container);
  margin: 0 auto;
}

.ico { width: 1em; height: 1em; fill: currentColor; vertical-align: -0.12em; }

/* --- contact bar --------------------------------------------------------- */

.topbar {
  background: var(--teal);
  color: var(--white);
  font-size: 14px;
  line-height: 1;
  padding: 12px 0;
}
.topbar__inner {
  display: flex;
  align-items: center;
  gap: 24px;
  flex-wrap: wrap;
}
.topbar__item { display: inline-flex; align-items: center; gap: 8px; }
.topbar a { text-decoration: none; }
.topbar a:hover { text-decoration: underline; }
.topbar__social { margin-left: auto; font-size: 16px; display: inline-flex; }

/* --- header -------------------------------------------------------------- */

.header {
  background: var(--teal);
  box-shadow: 0 1px 0 rgba(0,0,0,.1);
  position: relative;
  z-index: 20;
}
.header__inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 30px;
  min-height: 66px;
}
.header__logo img { max-height: 54px; width: auto; }

.nav__menu {
  list-style: none;
  display: flex;
  gap: 26px;
  margin: 0;
  padding: 0;
}
.nav__menu a {
  font-size: 16px;
  font-weight: 600;
  color: var(--white);
  text-decoration: none;
  opacity: .9;
}
.nav__menu a:hover, .nav__menu a.is-current { opacity: 1; }
.nav__toggle { display: none; }

/* --- sections ------------------------------------------------------------ */

.section {
  position: relative;
  padding: var(--section-pad) 0;
}
.section--flush { padding: 0; }
.section--white  { background: var(--white); }
.section--yellow { background: var(--yellow); padding-top: 0; }
.section--teal   { background: var(--teal); padding: 50px 0; }
.section--dark   { background: var(--dark); }

/* angled dividers between sections */
.divider {
  position: absolute;
  left: 0;
  width: 100%;
  height: 100px;
  z-index: 1;
  pointer-events: none;
}
.divider--top { top: 0; }
.divider--flip { transform: scaleX(-1); }

.grid { display: grid; gap: 60px; }
.grid--2 { grid-template-columns: 1fr 1fr; }
.grid--middle { align-items: center; }

/* --- hero ---------------------------------------------------------------- */

.hero { padding-bottom: 100px; overflow: hidden; }
.hero .container { position: relative; z-index: 2; }
.hero__copy { align-self: center; padding-top: 40px; }
.hero__logo { width: 260px; margin: 0 0 30px -30px; }
.hero h1 { color: var(--heading); }
.hero p { color: var(--text-strong); }
.hero__image { align-self: end; }
.hero__image img { margin: 0 auto; }

.btn {
  display: inline-block;
  margin-top: 10px;
  padding: 14px 26px;
  background: var(--teal);
  color: var(--white);
  font-size: 17px;
  font-weight: 700;
  text-decoration: none;
  border-radius: 3px;
  transition: background .2s ease, transform .2s ease;
}
.btn:hover { background: #00979b; transform: translateY(-1px); }
.btn__arrow { margin-left: 6px; }

/* --- our story (photo background) --------------------------------------- */

.section--story {
  padding-top: 200px;
  padding-bottom: 100px;
  background-image: url("../img/story-bg.webp");
  background-size: cover;
  background-position: center top;
  background-attachment: fixed;
  background-color: var(--dark);
}
/* dark wash so the copy stays readable over the photo; lighter on the right so the chair still shows */
.section--story { position: relative; }
.section--story::before {
  content: "";
  position: absolute;
  inset: 0;
  z-index: 0;
  background: linear-gradient(90deg, rgba(0,0,0,.82) 0%, rgba(0,0,0,.68) 50%, rgba(0,0,0,.15) 100%);
}
.section--story .container { position: relative; z-index: 2; }
.story__copy { color: var(--white); text-shadow: 0 1px 4px rgba(0,0,0,.7); }
.story__copy h2 { color: var(--white); }

/* --- what we do ---------------------------------------------------------- */

.h2--dark { color: var(--heading); }
.img-block { width: 100%; }

/* --- testimonials -------------------------------------------------------- */

.testimonials { padding-top: 120px; }
.testimonials .container { position: relative; z-index: 2; }

.slider { position: relative; padding: 20px 50px 60px; }
.slider__track { position: relative; }

.slide {
  margin: 0;
  text-align: center;
  font-family: var(--font-head);
  font-size: 27px;
  line-height: 1.9;
  color: var(--white);
  display: none;
}
.slide.is-active { display: block; animation: fade .5s ease; }
@keyframes fade { from { opacity: 0; } to { opacity: 1; } }

.slider__arrow {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  background: none;
  border: 0;
  color: var(--white);
  font-size: 44px;
  line-height: 1;
  cursor: pointer;
  padding: 0 10px;
  opacity: .6;
  transition: opacity .2s ease;
}
.slider__arrow:hover { opacity: 1; }
.slider__arrow--prev { left: 0; }
.slider__arrow--next { right: 0; }

.slider__dots {
  position: absolute;
  bottom: 20px;
  left: 0;
  right: 0;
  display: flex;
  justify-content: center;
  gap: 10px;
}
.slider__dots button {
  width: 10px; height: 10px;
  padding: 0;
  border: 0;
  border-radius: 50%;
  background: rgba(255,255,255,.45);
  cursor: pointer;
}
.slider__dots button.is-active { background: var(--white); }

/* --- promo (dark section) ------------------------------------------------ */

.promo { text-align: center; }
.promo h2 { font-size: 40px; color: var(--white); }
.promo p { color: rgba(255,255,255,.55); }

/* --- gallery ------------------------------------------------------------- */

.gallery { display: grid; grid-template-columns: repeat(3, 1fr); }
.gallery figure { margin: 0; overflow: hidden; }
.gallery img { width: 100%; height: 100%; object-fit: cover; transition: transform .6s ease; }
.gallery figure:hover img { transform: scale(1.04); }

/* --- footer -------------------------------------------------------------- */

.footer { background: #111111; color: rgba(255,255,255,.5); }
.footer__inner {
  display: flex;
  align-items: center;
  gap: 20px;
  padding: 22px 0;
  font-size: 15px;
}
.footer__social { display: inline-flex; font-size: 18px; text-decoration: none; }
.footer__copy { margin: 0; margin-left: auto; }

/* --- scroll reveal ------------------------------------------------------- */

.reveal { opacity: 0; transform: translateY(30px); transition: opacity .9s ease, transform .9s ease; }
.reveal.is-visible { opacity: 1; transform: none; }

/* --- responsive ---------------------------------------------------------- */

@media (max-width: 980px) {
  h1, h2 { font-size: 38px; }
  .promo h2 { font-size: 32px; }
  .slide { font-size: 22px; line-height: 1.7; }
  .grid--2 { grid-template-columns: 1fr; gap: 40px; }
  .hero__copy { text-align: center; }
  .hero__logo { margin: 0 auto 24px; }
  .section--story { padding-top: 140px; background-attachment: scroll; }
  .section--story::before { background: rgba(0,0,0,.72); }
  .story__copy { text-align: center; }
  .promo { text-align: center; }
}

@media (max-width: 782px) {
  .container { width: 88%; }

  .topbar__inner { justify-content: center; font-size: 13px; gap: 14px; }
  .topbar__social { margin-left: 0; }

  .nav { position: relative; }
  .nav__toggle {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    background: none;
    border: 0;
    color: var(--white);
    font-family: var(--font-body);
    font-size: 16px;
    font-weight: 600;
    cursor: pointer;
    padding: 0;
  }
  .nav__bars { width: 20px; height: 2px; background: currentColor; box-shadow: 0 6px 0 currentColor, 0 -6px 0 currentColor; }
  .nav__menu {
    display: none;
    position: absolute;
    right: 0;
    top: calc(100% + 14px);
    background: var(--white);
    flex-direction: column;
    gap: 0;
    min-width: 220px;
    padding: 6px 0;
    border-radius: 3px;
    box-shadow: 0 2px 10px rgba(0,0,0,.15);
  }
  .nav__menu.is-open { display: flex; }
  .nav__menu a { display: block; padding: 12px 20px; color: var(--text); }

  h1, h2 { font-size: 30px; }
  .btn { font-size: 15px; padding: 14px 20px; line-height: 1.4; }
  .slider { padding: 10px 34px 56px; }
  .slide { font-size: 19px; }
  .gallery { grid-template-columns: 1fr; }
  .footer__inner { flex-direction: column; text-align: center; }
  .footer__copy { margin-left: 0; }
}

@media (prefers-reduced-motion: reduce) {
  .reveal { opacity: 1; transform: none; transition: none; }
  * { animation-duration: .001ms !important; transition-duration: .001ms !important; }
}
