/*

INDEX
1. GLOBAL STYLES
2. TEXT STYLES
3. SECTIONS
4. USER INTERFACE
5. GRAPHIC ELEMENTS
6. RESPONSIVE - DESKTOP RULES
7. ACCESSIBILITY

*/

/* 1. GLOBAL STYLES */

@font-face {
  font-family: "LavazzaTXT";
  src: url("fonts/lavazzatxt_bold-webfont.woff2") format("woff2");
  font-weight: normal;
  font-style: normal;
  font-display: swap;
}

:root {
  --forest: #006938;
  --forest_dark: #00361b;
  --clay: #634f42;
  --clay_light: #845245;
  --cream: #ded3bb;
  --cream_light: #e4dbc5;
  --cream_dark: #c5b198;
}

::selection {
  background-color: var(--cream_dark);
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
  overflow-x: hidden;
}

body {
  margin: 0;
  background: var(--cream_light);
  color: var(--clay);
  font-family: "LavazzaTXT", Helvetica, sans-serif;
  overflow-x: hidden;
}

main {
  margin: max(1rem, env(safe-area-inset-top)) 1rem max(1rem, env(safe-area-inset-bottom));
}

header {
  margin-top: max(1rem, env(safe-area-inset-top));
}

/* 2. TEXT STYLES */

h1,
h2,
h3,
.title {
  font-family: "active", Arial, sans-serif;
  font-style: normal;
  text-transform: uppercase;
  margin: 0;
}

h1 {
  font-size: 4.5rem;
  line-height: 1;
  letter-spacing: -0.01em;
  color: var(--forest);
}

h2,
h3,
.title {
  font-size: 2rem;
  line-height: 1.05;
  letter-spacing: -0.01em;
}

.episode-number {
  color: var(--forest);
  letter-spacing: 0.15px;
  text-transform: uppercase;
  margin: 0 0 0.5rem 0;
}

.text-green {
  color: var(--forest);
}

.text-center {
  text-align: center;
}
/* 3. SECTIONS */

.img-container img {
  width: 100%;
}

.hero {
  display: flex;
  flex-direction: column;
  justify-content: flex-start;
  align-items: center;
  text-align: center;
}

.hero-content {
  position: relative;
  margin-top: 2rem;
}

.hero-content > :not(:first-child) {
  margin-top: 1rem;
}

section > :not(:first-child) {
  margin-top: 1.5rem;
}

.intro {
  padding: 1rem 0;
  font-size: 1.5rem;
  line-height: 1.25;
  text-transform: uppercase;
  border-top: 2px solid var(--clay);
  border-bottom: 2px solid var(--clay);
}

.intro > p {
  margin: 0;
}

.episodes {
  position: relative;
  z-index: 1;
}

section:not(:first-child) {
  margin-top: 5rem;
}

.episode-card > div {
  margin-bottom: 1rem;
}

/* 4. USER INTERFACE */

.hero-button {
  border: 0px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 16px 24px;
  background-color: var(--forest);
  color: var(--cream_light);
  border-radius: 30px;
  text-decoration: none;
  font-size: 0.75rem;
  letter-spacing: 1px;
  text-transform: uppercase;
  transition:
    background-color 0.05s ease,
    transform 0.05s ease;
}

.hero-button:active {
  background-color: var(--clay_light);
  transition: 0s;
}

.hero-button:hover {
  background-color: var(--forest_dark);
}

.episode-card {
  min-height: 275px;
  display: flex;
  flex-direction: column;
  padding: 1.5rem;
  border-radius: 24px;
  border: none;
  background: var(--cream);
  transition:
    transform 0.25s ease,
    box-shadow 0.25s ease;
  justify-content: space-between;
}

/* 5. GRAPHIC ELEMENTS */

.logo-lifegate {
  height: 0.75em;
  display: inline;
  position: relative;
}

.rainforest-icons > img {
  padding: 0.5rem;
  height: 120px;
  display: inline-block;
}

/* 6. RESPONSIVE - DESKTOP RULES */

@media (min-width: 768px) {
  :root {
    font-size: 20px;
  }

  main {
    max-width: 480px;
    margin: 1rem auto;
  }

  .episode-card {
    min-height: 380px;
  }
}

/* 7. ACCESSIBILITY */

@media (prefers-reduced-motion: reduce) {
  html {
    scroll-behavior: auto;
  }

  .episode-card,
  .hero-button {
    transition: none;
  }
}
