/* --- Google Fonts & Root Variables --- */
@import url("https://fonts.googleapis.com/css2?family=Inter:wght@300;400;700&family=Lora:wght@400;700&display=swap");

:root {
  /*--primary-color: #2c3e50; /* Deep Slate Blue */
  --primary-color: #104070; /* Deep Slate Blue */
  --secondary-color: #88a096; /* Sage Green */
  --background-color: #f9f9f7; /* Alabaster / Warm White */
  --accent-color: #c5a065; /* Muted Gold */
  --text-color-light: #ffffff;
  --text-color-dark: #333333;
}

/* --- Logos Section --- */
#logos {
  background-color: #fff; /* Slightly different background */
  padding: 3em 0;
}

#logos .section-title {
  margin-bottom: 2em;
}

.scrolling-logos-section {
  overflow: hidden;
  position: relative;
  white-space: nowrap;
}

.logos-row {
  display: flex;
  flex-wrap: nowrap;
  min-width: fit-content;
  padding: 12px 0;
  align-items: center; /* This replaces vertical-align on the images */
}

/* This is the new magic code */
.logos-row:hover {
  animation-play-state: paused;
}

.logos-row-1 {
  animation: 60s scroll-left infinite linear;
}

.logos-row-2 {
  animation: 60s scroll-right infinite linear;
}

.logos-row img {
  height: 80px;
  width: auto;
  margin: 0 40px;
  vertical-align: middle;
  filter: grayscale(100%) contrast(1);
  /* opacity: 0.6; */
  transition: all 0.3s ease;
}

.logos-row img:hover {
  filter: grayscale(0) contrast(1);
  opacity: 1;
}

@keyframes scroll-left {
  from {
    transform: translateX(0);
  }
  to {
    transform: translateX(-50%);
  } /* Scrolls one full set of logos to the left */
}

@keyframes scroll-right {
  from {
    transform: translateX(-50%);
  } /* Starts one full set of logos to the left */
  to {
    transform: translateX(0);
  } /* Scrolls back to the original position */
}

/* --- Video Section --- */

.video-wrapper {
  max-width: 900px;
  margin: 0 auto;
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.1);
  border-radius: 10px;
  overflow: hidden;
}

.video-responsive {
  position: relative;
  padding-bottom: 56.25%; /* 16:9 */
  height: 0;
}

.video-responsive iframe {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
}

#video p {
  margin-top: 1em;
}

/* --- Topics Section --- */
.topics-grid {
  display: flex;
  flex-direction: row;
  flex-wrap: wrap;
  justify-content: center;
  gap: 2em;
}

.topic-card {
  flex: 1 1 400px;
  background-color: #fff;
  padding: 2em;
  border-radius: 10px;
  box-shadow: 0 5px 20px rgba(0, 0, 0, 0.1);
  text-align: center;
  transition: box-shadow 0.2s ease-in-out;
}

.topic-card:hover {
  box-shadow: 10px 15px 25px rgba(0, 0, 0, 0.1);
}

.topic-card h3 {
  display: block;
  min-height: 5re;
}

.topic-card p,
.topic-card li {
  text-align: justify;
}

/* --- Speaking Section --- */
.speaking-grid {
  display: flex;
  flex-direction: column;
  flex-wrap: wrap;
  justify-content: center;
  gap: 2em;
}

.speaking-card {
  flex: 1 1 400px;
  background-color: #fff;
  padding: 2em;
  border-radius: 10px;
  box-shadow: 0 5px 20px rgba(0, 0, 0, 0.05);
  text-align: center;
}

.speaking-card p,
.speaking-card li {
  text-align: justify;
}

.speaking-card div {
  width: 90%;
  margin: 0 auto;
}

/* --- Stats section --- */
#stats {
  background-image:
    linear-gradient(rgba(0, 0, 0, 0.5), rgba(0, 0, 0, 0.5)),
    url("./img/globe.jpg");
  background-size: cover;
  background-position: center;
  color: var(--text-color-light);
  text-align: center;
  font-size: 2rem;
  padding: 4em 2em;
}

/* --- Bio section --- */
#kevin-bio {
  display: flex;
  flex-direction: row;
  flex-wrap: wrap;
  justify-content: space-around;
  gap: 2rem;
  margin: 0 10dvw;
}

#kevin-bio #sunset {
  flex: 0 1;
  width: min-content;
}

#kevin-bio #sunset img {
  width: 60dvw;
  max-width: 600px;
}

#kevin-bio #kevin-bio-text {
  flex: 1 1 300px;
  text-align: justify;
}

#why-book-list {
  margin: 0 1rem 2rem auto;
  /* display: flex;
  flex-direction: row;
  flex-wrap: wrap;
  justify-content: left;
  gap: 3rem; */
}

#why-book-list li {
  /* max-width: 350px; */
  font-weight: 700;
  font-size: 17px;
  text-align: left;
}

/* --- Testimonials Section --- */
#testimonials {
  background-color: var(--primary-color);
  color: var(--text-color-light);
  padding: 2em;
}

.testimonial-card {
  max-width: 800px;
  margin: 0 auto 3em auto;
  text-align: center;
}

.testimonial-card:last-child {
  margin-bottom: 0;
}

.testimonial-card blockquote {
  font-family: "Lora", serif;
  font-size: 1.5em;
  font-style: italic;
  border: none;
  margin: 0 0 0.5em 0;
  padding: 0;
}

.testimonial-card cite {
  font-family: "Inter", sans-serif;
  font-weight: 700;
  color: var(--accent-color);
}

/* --- Book Section --- */
.book-wrapper {
  display: grid;
  grid-template-columns: 1fr 2fr;
  gap: 3em;
  align-items: center;
}

.book-cover img {
  width: 100%;
  height: auto;
  border-radius: 5px;
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.15);
}

.book-description h2 {
  text-align: left;
}

/* --- Hero Section --- */
#hero {
  background-image:
    linear-gradient(rgba(0, 0, 0, 0.5), rgba(0, 0, 0, 0.5)),
    url("./img/briggs-ted.jpg");
  background-size: cover;
  background-position: top;
  color: var(--text-color-light);
  text-align: center;
  padding: 4em 2em;
}

.hero-content h1 {
  color: var(--text-color-light);
  margin-bottom: 0.5em;
}

.hero-content p {
  font-size: 1.4em;
  max-width: 600px;
  margin: 0 auto 2em auto;
}

.hero-text-bg {
  background: #777;
  background: linear-gradient(
    90deg,
    rgba(16, 64, 112, 0.8) 0%,
    rgba(16, 64, 112, 0.02) 50%
  );
  padding-left: 2rem;
}

.sunken-image-container {
  /* Set the image as a background */
  background-image: url("./img/sitting.jpg");
  background-size: cover;
  background-position: center;

  /* Define the dimensions of your container */
  width: 90%; /* Adjust as needed */
  max-width: 900px;
  height: auto; /* Adjust as needed */
  aspect-ratio: 5 / 3;

  /* Apply the inset shadow for the sunken effect */
  box-shadow: inset 0 0 20px rgba(0, 0, 0, 0.8); /* Adjust values and color for desired depth */
  margin: 1rem auto 0 auto;

  /* Optional: Add a border for a more defined edge */
  border: 1px solid #ccc;
}

/* --- Global Styles --- */
html {
  scroll-behavior: smooth;
}

body {
  /* background-color: var(--background-color); */
  background: #cccccc;
  background: linear-gradient(
    90deg,
    rgba(204, 204, 204, 1) 0%,
    rgba(255, 255, 255, 1) 50%,
    rgba(204, 204, 204, 1) 100%
  );
  color: var(--text-color-dark);
  font-family: "Inter", "Open Sans", sans-serif;
  font-size: 18px;
  margin: 0;
  padding: 0;
}

main {
  display: block; /* For older browsers */
}

section {
  padding: 4em 2em;
}

.container {
  max-width: 1200px;
  margin: 0 auto;
  padding: 3rem 2em;
}

h1,
h2,
h3,
h4,
h5,
h6 {
  font-family: "Lora", serif;
  color: var(--primary-color);
  margin: 0 0 0.5em 0;
}

h1 {
  font-size: 3em;
}
h2 {
  font-size: 2.5em;
  text-align: center;
  margin-bottom: 1.5em;
}
h3 {
  font-size: 1.8em;
}

p {
  line-height: 1.6;
  margin-bottom: 1em;
}

a {
  color: var(--accent-color);
  text-decoration: none;
  transition: color 0.3s ease;
}

a:hover {
  color: var(--primary-color);
}

.button {
  display: inline-block;
  background-color: var(--accent-color);
  color: var(--text-color-light);
  padding: 0.8em 1.5em;
  border-radius: 5px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 1px;
  transition:
    background-color 0.3s ease,
    transform 0.3s ease;
}

.button:hover {
  background-color: #d1b17a; /* Lighter accent */
  transform: translateY(-2px);
  color: var(--text-color-light);
}

.button-primary {
  background-color: var(--accent-color);
  color: var(--text-color-light);
}

.text-center {
  text-align: center;
}

/* --- Navigation --- */
nav#top {
  position: sticky;
  top: 0;
  z-index: 1000;
  background-color: var(--primary-color);
  box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
  position: relative; /* Added for positioning nav-toggle */
}

/* Hide nav-toggle by default on desktop */
.nav-toggle {
  display: none;
}

nav ul {
  display: flex;
  list-style: none;
  margin: 0;
  padding: 0;
  align-items: center;
  max-width: 1200px;
  margin: 0 auto;
}

nav li {
  padding: 0;
}

nav a {
  display: block;
  padding: 0.5em 1em;
  color: var(--text-color-light);
  font-weight: 700;
  font-size: 1.4rem;
  transition: all 0.3s ease-in-out;
  text-shadow: 0px 0px 0px rgba(0, 0, 0, 0.7);
}

nav li a:hover {
  /* background-color: rgba(255, 255, 255, 0.1); */
  color: var(--text-color-light);
  text-decoration: underline;
  text-shadow: 6px 6px 4px rgba(0, 0, 0, 0.7);
}

nav li#current a {
  /* background-color: var(--accent-color); Changed to accent color */
  text-decoration: underline;
  text-shadow: 8px 8px 8px rgba(0, 0, 0, 0.7);
}

.nav-logo {
  margin-right: auto;
  padding: 0.5em 1em;
}

.nav-logo img {
  height: 50px;
  width: auto;
  vertical-align: middle;
}

/* --- Footer --- */
#footer {
  background-color: var(--primary-color);
  color: rgba(255, 255, 255, 0.7);
}

.footer-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
  gap: 2em;
  max-width: 1200px;
  margin: 0 auto;
}

.footer-col h3 {
  color: var(--text-color-light);
  font-size: 1.2em;
  margin-bottom: 1em;
}

.footer-col ul {
  list-style: none;
  padding: 0;
}

.footer-col li a {
  color: rgba(255, 255, 255, 0.7);
  transition: color 0.3s ease;
}

.footer-col a:hover {
  color: var(--text-color-light) !important;
}

.social-links a {
  font-size: 1.5em;
  margin-right: 1em;
  color: rgba(255, 255, 255, 0.7);
  transition: color 0.3s ease;
}

.social-links a:hover {
  color: var(--text-color-light);
}

@media (max-width: 768px) {
  .footer-grid {
    text-align: center;
  }
}

/* Responsive adjustments */
@media (max-width: 768px) {
  h1 {
    font-size: 2.5em;
  }
  h2 {
    font-size: 2em;
  }

  .nav-toggle {
    display: block;
    position: absolute;
    top: 1em;
    right: 1em;
    background: transparent;
    border: 0;
    cursor: pointer;
    z-index: 1001;
    height: 2em;
  }

  .hamburger {
    display: block;
    position: relative;
    width: 2em;
    height: 3px;
    background: var(--text-color-light);
    transition: transform 0.3s ease;
  }

  .hamburger::before,
  .hamburger::after {
    content: "";
    position: absolute;
    left: 0;
    width: 100%;
    height: 3px;
    background: var(--text-color-light);
    transition: transform 0.3s ease;
  }

  .hamburger::before {
    top: -8px;
  }

  .hamburger::after {
    bottom: -8px;
  }

  nav ul {
    display: none;
    flex-direction: column;
    align-items: stretch;
    text-align: center;
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    background-color: var(--primary-color);
  }

  .nav-open nav ul {
    display: flex;
  }

  .nav-open .hamburger {
    transform: rotate(45deg); /* Rotate to form part of X */
  }

  .nav-open .hamburger::before {
    transform: rotate(-90deg) translateX(1px); /* Rotate and move into X position */
    top: 0;
  }

  .nav-open .hamburger::after {
    opacity: 0; /* Hide the bottom bar */
  }

  .nav-logo {
    margin: 0.5em auto;
  }

  .book-wrapper {
    grid-template-columns: 1fr;
    text-align: center;
  }

  .book-description h2 {
    text-align: center;
  }
}

/* --- About Page Specific Styles --- */
#about-hero {
  padding: 6em 0; /* Adjust padding for about page hero */
}

.bio-section {
  display: flex;
  flex-direction: row;
  justify-content: center;
  flex-wrap: wrap;
  align-items: center;
  gap: 2em;
  margin: 3em 0;
}

/* Reverse column order for even-numbered bio sections */
.bio-section-reverse {
  flex-wrap: wrap-reverse;
}

.bio-section .bio-text {
  flex: 1 1;
  min-width: 350px;
}

.bio-image {
  max-width: 400px;
  width: 100%;
  height: auto;
  border-radius: 10px;
  box-shadow: 0 5px 20px rgba(0, 0, 0, 0.1);
}

hr {
  border: 0;
  height: 1px;
  background-image: linear-gradient(
    to right,
    rgba(0, 0, 0, 0),
    var(--secondary-color),
    rgba(0, 0, 0, 0)
  );
}

.full-width-image {
  width: 100%;
  height: auto;
  border-radius: 10px;
  margin-bottom: 1em;
}

.caption-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 1em;
  font-size: 0.9em;
  color: #777;
}

.image-description {
  max-width: 800px;
  margin: 1em auto 0 auto;
  font-size: 1em;
  color: #555;
}

@media (max-width: 768px) {
  .bio-section,
  .bio-section:nth-child(even) {
    grid-template-columns: 1fr;
  }

  .bio-section:nth-child(even) .bio-image {
    grid-column: 1;
  }
}

/* --- Speaking Page Specific Styles --- */
#speaking-hero {
  padding: 6em 0; /* Adjust padding for speaking page hero */
}

#workshops {
  background-color: #f0f0f0;
  border-radius: 10px;
  padding: 3em;
}

/* --- Media Page Specific Styles --- */
#media-hero {
  padding: 6em 0; /* Adjust padding for media page hero */
}

.media-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  gap: 2em;
}

.media-item {
  background-color: #fff;
  border-radius: 10px;
  box-shadow: 0 5px 20px rgba(0, 0, 0, 0.05);
  overflow: hidden;
}

.media-item img {
  width: 100%;
  height: auto;
  display: block;
}

.media-caption {
  padding: 1em;
  font-weight: 700;
  color: #555;
  text-align: center;
}

.media-list {
  list-style: none;
  padding: 0;
  margin: 0;
  display: grid;
  gap: 1em;
}

.media-list li a {
  display: block;
  background-color: #fff;
  padding: 1.5em;
  border-radius: 5px;
  box-shadow: 0 2px 5px rgba(0, 0, 0, 0.05);
  font-weight: 700;
  transition: all 0.3s ease;
}

.media-list li a:hover {
  transform: translateY(-2px);
  box-shadow: 0 5px 15px rgba(0, 0, 0, 0.1);
  color: var(--primary-color);
}

.photo-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(250px, 1fr));
  gap: 1em;
}

.photo-grid img {
  width: 100%;
  height: auto;
  border-radius: 5px;
  transition:
    transform 0.3s ease,
    box-shadow 0.3s ease;
}

.photo-grid a:hover img {
  transform: scale(1.05);
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.2);
}

/* --- Contact Page Specific Styles --- */
#contact-hero {
  padding: 6em 2em; /* Adjust padding for contact page hero */
}

.contact-methods {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  gap: 2em;
  margin-top: 2em;
}

.contact-card {
  background-color: #fff;
  padding: 2em;
  border-radius: 10px;
  box-shadow: 0 5px 20px rgba(0, 0, 0, 0.05);
  text-align: center;
}

.contact-card h3 {
  font-size: 1.5em;
  margin-bottom: 1em;
}

.contact-card .fa {
  margin-right: 0.5em;
}

.social-media-links a {
  font-size: 3em;
  margin: 0 0.2em;
  color: var(--accent-color);
  transition: color 0.3s ease;
}

.social-media-links a:hover {
  color: var(--primary-color);
}

#need-help {
  background-color: #f0f0f0;
  border-radius: 10px;
  padding: 3em;
}

.help-links {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  align-items: center;
  gap: 2em;
  margin-top: 2em;
}

.help-link-item img {
  max-width: 300px;
  height: auto;
  border-radius: 10px;
  transition:
    transform 0.3s ease,
    box-shadow 0.3s ease;
}

.help-link-item:hover img {
  transform: scale(1.05);
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.1);
}
