/* Google Fonts Import */
@import url("https://fonts.googleapis.com/css2?family=Open+Sans:ital,wght@0,300..800;1,300..800&family=Playfair+Display:ital,wght@0,400..900;1,400..900&display=swap");

/* Global Styles */

/* Variables */
:root {
  --primary-color: #000000;
  --secondary-color: #ffffff;
  --accent-color: #cc2d25;
  --offset-color: #fcfbf8;
  --light-grey: #e0dfd9;
  --font-family: "Open Sans", sans-serif;
  --font-family-alt: "Playfair Display", serif;
}

body {
  background-color: var(--secondary-color);
  font-family: var(--font-family);
  font-size: 26px;
  text-align: center;
  padding: 0;
  margin: 0;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
}

main {
  flex: 1;
}

h1 {
  font-family: var(--font-family-alt);
  font-size: 60px;
  font-weight: 400;
  margin-top: 5px;
  margin-bottom: 10px;
  padding: 0;
  text-transform: uppercase;
}

h2 {
  font-family: var(--font-family-alt);
  font-size: 25px;
  font-weight: 400;
  text-transform: uppercase;
  margin-top: 0;
}

.header-about {
  text-align: center;
  font-size: 18px;
  overflow: hidden;
  margin-left: 15%;
  margin-right: 15%;
  color: #464545;
  font-family: var(--font-family-alt);
}

.navbar {
  font-family: var(--font-family);
  font-size: 16px;

  font-weight: 500;
  text-transform: uppercase;
  display: flex;
  justify-content: center;
  align-items: center;
  max-width: 90%;
  margin: 0 auto;
  overflow: hidden;
}

.nav-row {
  display: contents;
}

.nav-item {
  position: relative;
  padding: 0 clamp(1rem, 2vw, 2rem);
}

.nav-item::before {
  content: "|";
  position: absolute;
  left: 0;
  top: 40%;
  transform: translate(-50%, -50%);
  color: var(--accent-color);
  font-weight: 600;
  pointer-events: none;
}

.navbar > .nav-row:first-child > .nav-item:first-child::before {
  content: none;
  /* no separator before the very first item, ever */
}

.navbar a {
  text-decoration: none;
  color: inherit;
  white-space: nowrap;
}

@media (hover: hover) and (pointer: fine) {
  .navbar a:hover {
    color: var(--accent-color);
    text-decoration: underline;
  }
}

.line {
  height: 1px;
  background-color: var(--light-grey);
  margin: 20px 0;
  overflow: hidden;
  margin-left: 5%;
  margin-right: 5%;
  box-shadow: 0 1px 0 var(--light-grey);
}

section h2 {
  text-align: left;
  margin-left: 5%;
  margin-top: 30px;
  text-decoration: underline;
  text-underline-offset: 8px;
  text-decoration-thickness: 1px;
}

/* ------------------------------------------- */
/* ----  Articles Section Styles --------------- */
/* ------------------------------------------- */

.articles-row {
  margin: 30px auto;
  max-width: 90%;
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 20px;
  padding: 0 20px;
}

.article-card {
  padding: 0 20px 0 0;
  border-right: 2px solid var(--light-grey);
  display: flex;
  flex-direction: column;
}

.article-card > a {
  display: flex;
  flex-direction: column;
  flex: 1;
}

.article-card img {
  width: 100%;
  height: auto;
  display: block;
  object-fit: cover;
}

.article-card a {
  display: flex;
  flex-direction: column;
  flex: 1;
  color: inherit;
  text-decoration: none;
}

.article-card h3 {
  text-align: left;
  margin-left: 0;
  margin-top: 15px;
  margin-bottom: 10px;
  font-family: var(--font-family-alt);
  font-size: 21px;
  font-weight: 400;
}

.article-card p {
  text-align: left;
  margin-left: 0;
  margin-top: 10px;
  font-family: var(--font-family);
  font-size: 15px;
}

.article-card h4 {
  text-align: left;
  margin-left: 0;
  font-family: var(--font-family);
  font-size: 15px;
  font-weight: 500;
  margin-top: auto;
  color: #464545;
}

.row-divider {
  display: none;
  /* shown selectively below, per breakpoint */
  grid-column: 1 / -1;
  height: 2px;
  border: none;
  margin: 0;
  padding: 0;
  background-color: var(--light-grey);
}

/* ------------------------------------------- */
/* ----  Books Section Styles -----------------*/
/* ------------------------------------------- */

.book-row-container {
  grid-template-columns: repeat(2, 1fr);
  display: grid;
  width: 70%;
  margin: 50px auto 60px;
  gap: 10px;
}

.book-cover-1 img {
  width: 300px;
}

.book-cover-2 img {
  width: 300px;
}

.book-cover-1-text {
  text-align: left;
  margin-left: 0;
  font-family: var(--font-family);
  font-size: 15px;
}

.book-cover-1-text h3 {
  font-family: var(--font-family-alt);
  font-size: 25px;
  text-transform: uppercase;
  font-weight: 400;
}

.book-cover-1-text h4 {
  font-family: var(--font-family);
  font-size: 18px;
  text-transform: uppercase;
  font-weight: 400;
}

.book-cover-2-text {
  text-align: left;
  margin-left: 0;
  font-family: var(--font-family);
  font-size: 15px;
}

.book-cover-2-text h3 {
  font-family: var(--font-family-alt);
  font-size: 25px;
  text-transform: uppercase;
  font-weight: 300;
}

.book-cover-2-text h4 {
  font-family: var(--font-family);
  font-size: 18px;
  text-transform: uppercase;
  font-weight: 400;
}

.buy-now-button {
  background-color: var(--primary-color);
  border: none;
  border-radius: 5px;
  padding: 10px 20px;
  font-size: 16px;
  cursor: pointer;
  text-decoration: none;
  color: var(--secondary-color);
  display: inline-block;
}

.buy-now-button a {
  color: var(--secondary-color);
  text-decoration: none;
}

@media (hover: hover) and (pointer: fine) {
  .buy-now-button:hover {
    background-color: var(--accent-color);
    transition:
      background-color 0.2s ease,
      transform 0.2s ease;
  }
}

/* ------------------------------------------- */
/* ----  Media Section Styles ----------------- */
/* ------------------------------------------- */

.media-row-container {
  max-width: 90%;
  margin: 0 auto;
  padding: 0 20px;
}

.media-row-container h3 {
  text-align: left;
  font-family: var(--font-family-alt);
  font-size: 19px;
  font-weight: 400;
  text-transform: uppercase;
  text-decoration: underline;
  text-underline-offset: 8px;
  margin: 40px 0 40px 0;
}

.media-intro {
  text-align: left;
  font-family: var(--font-family);
  font-size: 15px;
  margin: 30px auto 50px auto;
}

/* Two-column layout: speaking highlights left, media/podcast right */
.media-columns {
  display: grid;
  grid-template-columns: 1fr auto 1fr;
  gap: 40px;
  align-items: start;
}

.media-col {
  min-width: 0;
}

.media-col-divider {
  width: 1px;
  background-color: var(--light-grey);
  align-self: stretch;
}

.media-columns h3 {
  margin-top: 0;
}

/* Speaking events: image left, text right, stacked within left column */
.speaking-event {
  display: grid;
  grid-template-columns: 140px 1fr;
  gap: 20px;
  align-items: start;
  margin-bottom: 50px;
}

.speaking-event img {
  width: 140px;
  height: 140px;
  object-fit: cover;
  display: block;
}

.speaking-event-text {
  text-align: left;
}

.speaking-event-text .event-name {
  font-family: var(--font-family-alt);
  font-size: 17px;
  margin: 0 0 6px 0;
}

.speaking-event-text .event-desc {
  font-family: var(--font-family);
  font-size: 14px;
  color: #464545;
  margin: 0;
  line-height: 1.5;
}

/* In the media */
.media-mention {
  text-align: left;
  max-width: 700px;
  margin-bottom: 30px;
}

.media-outlet {
  font-family: var(--font-family-alt);
  font-size: 17px;
  margin: 0 0 6px 0;
}

.media-desc {
  font-family: var(--font-family);
  font-size: 14px;
  color: #464545;
  margin: 0 0 8px 0;
}

.media-link {
  font-family: var(--font-family);
  font-size: 14px;
  color: var(--accent-color);
  text-decoration: none;
}

.media-link:hover {
  text-decoration: underline;
}

/* Podcast embed, narrower */
.podcast-embed {
  max-width: 90%;
  margin: 0;
  margin-top: 30px;
}

.podcast-embed iframe {
  width: 100%;
  display: block;
}

/* CTA line */
.media-cta {
  text-align: left;
  font-family: var(--font-family);
  font-size: 15px;
  margin-top: 30px;
  margin-bottom: 30px;
}

.media-cta a {
  color: var(--accent-color);
  text-decoration: none;
}

.media-cta a:hover {
  text-decoration: underline;
}

/* ------------------------------------------- */
/* ----  About Section Styles ----------------- */
/* ------------------------------------------- */

.about-container {
  max-width: 700px;
  margin: 30px auto 60px auto;
  padding: 0 60px;
  text-align: center;
}

.about-image {
  float: left;
  width: 90px;
  margin: 10px 20px 20px 0;
}

.about-image img {
  width: 100%;
  aspect-ratio: 1 / 1;
  object-fit: cover;
  border-radius: 50%;
  filter: grayscale(100%);
  display: block;
}

.about-text {
  text-align: left;
}

.about-text p {
  font-family: var(--font-family);
  font-size: 15px;
  line-height: 1.7;
  margin: 0 0 18px 0;
}

.about-text p:last-child {
  margin-bottom: 0;
}

/* Accent lead-in on the opening name */
.about-text .lead-name {
  color: var(--accent-color);
  font-family: var(--font-family);
  font-weight: 600;
}

/* Clear the float so following sections aren't affected */
.about-container::after {
  content: "";
  display: table;
  clear: both;
}

/* ------------------------------------------- */
/* ---- Contact Section Styles ----------------------- */

#contact {
  max-width: 90%;
  margin: 0 auto 60px auto;
  padding: 0 20px;
}

.contact-intro {
  display: grid;
  gap: 18px;
  margin-top: 30px;
  margin-left: 25%;
  margin-right: 25%;
  font-family: var(--font-family);
  font-size: 15px;
  text-align: left;

  margin-bottom: 10px;
}

p.contact-intro {
  font-weight: 400;
}

p.contact-text {
  gap: 18px;
  margin-top: 30px;
  margin-left: 25%;
  margin-right: 25%;
  font-family: var(--font-family);
  font-size: 15px;
  text-align: left;
  margin-top: 0;
  margin-bottom: 30px;
}

p.contact-text a {
  color: var(--accent-color);
  text-decoration: none;
}

#contact-form {
  display: grid;
  gap: 18px;
  margin-top: 30px;
  margin-left: 25%;
  margin-right: 25%;
  align-items: center;
}

#contact-form div {
  display: grid;
  gap: 8px;
}

#contact-form label {
  font-family: var(--font-family);
  font-size: 14px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  color: var(--primary-color);
}

#contact-form input,
#contact-form textarea {
  width: 100%;
  box-sizing: border-box;
  border: 1px solid #212121;
  background: #ffffff;
  color: var(--primary-color);
  font-family: var(--font-family);
  font-size: 15px;
  padding: 14px 16px;
  border-radius: 10px;
  transition:
    border-color 0.2s ease,
    box-shadow 0.2s ease;
}

#contact-form input::placeholder,
#contact-form textarea::placeholder {
  color: #212121;
}

#contact-form input:focus,
#contact-form textarea:focus {
  outline: none;
  border-color: var(--accent-color);
  box-shadow: 0 0 0 2px rgba(204, 45, 37, 0.1);
}

#contact-form textarea {
  min-height: 180px;
  resize: vertical;
}

#contact-form button {
  width: fit-content;
  background-color: var(--primary-color);
  color: var(--secondary-color);
  border: none;
  border-radius: 5px;
  padding: 12px 22px;
  font-family: var(--font-family);
  font-size: 16px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  cursor: pointer;
  transition:
    background-color 0.2s ease,
    transform 0.2s ease;
}

@media (hover: hover) and (pointer: fine) {
  #contact-form button:hover {
    background-color: var(--accent-color);
    transform: translateY(-1px);
  }
}

footer {
  text-align: center;
  font-family: var(--font-family);
  font-size: 14px;
  color: #464545;
  margin-top: 40px;
  margin-bottom: 20px;

  width: 100%;
}

.confirmation-message {
  text-align: center;
  font-family: var(--font-family);
  font-size: 19px;
  margin-top: 60px;
  margin-bottom: 30px;
}

.confirmation-message a {
  color: var(--accent-color);
  text-decoration: none;
}

.confirmation-message a:hover {
  text-decoration: underline;
}

.error-message {
  text-align: center;
  font-family: var(--font-family);
  font-size: 19px;
  margin-top: 60px;
  margin-bottom: 30px;
}

.error-message a {
  color: var(--accent-color);
  text-decoration: none;
}

.error-message a:hover {
  text-decoration: underline;
}

/* ------------------------------------------- */
/* ----  Responsive Styles --------------------- */
/* ------------------------------------------- */

@media (max-width: 900px) {
  h1 {
    font-size: 50px;
  }

  h2 {
    font-size: 22px;
  }

  .header-about {
    font-size: 16px;
    margin-left: 5%;
    margin-right: 5%;
  }

  .about-image {
    width: 80px;
    margin: 10px 25px 11px 0;
  }

  #contact-form {
    margin-left: 5%;
    margin-right: 5%;
  }

  p.contact-intro {
    margin-left: 5%;
    margin-right: 5%;
    text-align: left;
    font-size: 14px;
  }

  p.contact-text {
    margin-left: 5%;
    margin-right: 5%;
    margin-top: 30px;
    text-align: left;
    font-size: 14px;
  }

  .book-row-container {
    grid-template-columns: 1fr;
    width: 85%;
    text-align: center;
  }

  .book-cover-1,
  .book-cover-2 {
    display: flex;
    justify-content: center;
  }

  .book-cover-2 {
    order: 1;
  }

  .book-cover-2-text {
    order: 2;
  }

  .book-cover-1-text,
  .book-cover-2-text {
    text-align: left;
  }
}

@media (max-width: 800px) {
  .media-columns {
    grid-template-columns: 1fr;
    gap: 10px;
  }

  .media-col-divider {
    width: 100%;
    height: 1px;
    margin: 10px 0 30px 0;
  }
}

@media (max-width: 600px) {
  .navbar {
    flex-direction: column;
    row-gap: 14px;
  }

  .nav-row {
    display: flex;
    justify-content: center;
    align-items: center;
  }

  .nav-row:nth-child(2) > .nav-item:first-child::before {
    content: none;
    /* row 2 starts fresh — no separator on mobile only */
  }

  .about-container {
    padding: 0 5%;
  }

  .about-image {
    margin: 20px 20px 10px auto;
    width: 80px;
  }

  .about-text p {
    font-size: 14px;
  }

  .speaking-event {
    grid-template-columns: 1fr;
    margin-bottom: 20px;
  }

  .speaking-event img {
    width: 100%;
    height: 200px;
  }

  .podcast-embed {
    max-width: 100%;
  }

  .articles-row {
    grid-template-columns: 1fr;
    padding: 0 20px;
  }

  .article-card {
    border-right: none;
    padding: 0;
  }

  .row-divider {
    display: block;
  }

  .book-row-container {
    max-width: 100%;
    padding: 0 20px;
    gap: 20px;
    margin-bottom: 40px;
  }

  .book-cover-1 img,
  .book-cover-2 img {
    width: 100%;
    max-width: 260px;
    height: auto;
  }

  .book-cover-1-text,
  .book-cover-2-text {
    font-size: 15px;
  }

  .buy-now-button:active {
    background-color: var(--accent-color);
    transition: background-color 0.1s;
  }

  .speaking-event-text .event-desc {
    margin-bottom: 20px;
  }

  #arco-speaking img {
    object-position: top;
  }

  .speaking-event img {
    object-position: bottom;
  }

  #contact-form input,
  #contact-form textarea {
    font-size: 14px;
    padding: 12px 14px;
  }
}

@media (min-width: 1000px) {
  .article-card:nth-of-type(4n) {
    border-right: none;
  }

  .row-divider:nth-of-type(4n) {
    display: block;
  }
}

@media (min-width: 601px) and (max-width: 999px) {
  .articles-row {
    grid-template-columns: repeat(2, 1fr);
  }

  .article-card:nth-of-type(2n) {
    border-right: none;
  }

  .row-divider:nth-of-type(2n) {
    display: block;
  }
}
