@import url('https://fonts.googleapis.com/css2?family=Lato:wght@400;700&family=Open+Sans:wght@400;700&display=swap');

/* One side margin shared by header, main and footer so their edges align. */
:root {
  --gutter: 10%;
}

* {
  box-sizing: border-box;
}

html {
  font-family: 'Open Sans', 'Lato', sans-serif;
}

body {
  background-color: #e2d5c5;
  color: #6b5344;
  display: flex;
  flex-direction: column;
  min-height: 100vh;
  margin: 0;
}

img {
  max-width: 100%;
}

header {
  background-color: #f5eee8;
}

footer {
  background: #f5eee8;
  border-top: 1px solid rgba(107, 83, 68, 0.2);
  display: flex;
  flex-direction: column;
  padding: 0.9rem var(--gutter);
}

footer h3 {
  font-size: 0.9rem;
  letter-spacing: 0.15em;
  margin: 0 0 0.35rem;
  text-transform: uppercase;
}

footer a {
  color: inherit;
  margin: 0;
  text-decoration: none;
}

main {
  flex: 1;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 2rem;
  margin: 1rem 0;
  padding: 0 var(--gutter);
  width: 100%;
}

h1, h2, h3 {
  color: #6b5344;
  font-family: 'Lato', sans-serif;
  font-weight: bold;
}

p {
  color: #4a3b2a;
  margin: 1rem auto 2rem auto;
  font-family: sans-serif;
  font-size: 1rem;
  line-height: 1.6;
  text-align: justify;
  letter-spacing: 0.02em;
}

li p {
  margin: 0.6rem auto;
}

li:last-child p {
    margin-bottom: 2rem;
}

nav {
  display: flex;
  flex-wrap: wrap;
  justify-content: flex-end;
  row-gap: 0.5rem;
}

nav a {
  text-decoration: none;
  padding: 0 12px;
  border-left: 1px solid rgba(114,98,108,.5);
}

nav a:first-child {
  border-left: none;
}

nav a:last-child {
  padding-right: 0;
}

button,
.button {
  display: inline-block;
  text-align: center;
  padding: 0.8rem 1.8rem;
  font-family: 'Lato', sans-serif;
  font-size: 1rem;
  font-weight: 600;
  color: #f5eee8;
  background-color: #6b5344;
  border: none;
  border-radius: 50px;
  cursor: pointer;
  text-decoration: none;
  transition: all 0.3s ease;
  box-shadow: 0 4px 10px rgba(107, 83, 68, 0.3);
  letter-spacing: 0.5px;
}

button:hover,
.button:hover {
  background-color: #8c6b5a;
  transform: translateY(-2px);
  box-shadow: 0 6px 14px rgba(107, 83, 68, 0.4);
}

button:active,
.button:active {
  transform: translateY(0);
  box-shadow: 0 2px 6px rgba(107, 83, 68, 0.3);
}

#main-navigation {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 0 var(--gutter);
  width: 100%;
  gap: 2rem;
}

#main-navigation a {
  text-decoration: none;
  color: #6b5344;
  font-weight: bold;
}

#main-navigation a:hover,
#main-navigation a:active {
  color: #8c6b5a;
}

#logo {
  display: block;
  height: 92px;
  margin: 0.4rem 0;
  width: auto;
}

#welcome-img {
  flex: 1;
  max-width: 640px;
  min-width: 0;
  width: 50%;
  aspect-ratio: 4 / 3;
  object-fit: cover;
  object-position: center 15%;
  border-radius: 15px;
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.5);
}

#copyright {
  display: block;
  margin-top: 0.6rem;
  text-align: center;
  color: #8c6b5a;
  font-size: 0.85rem;
}

#contact {
  text-align: left;
}

#contact-links a {
  display: flex;
  align-items: center;
  justify-content: flex-start;
  gap: 0.5rem;
  margin: 0.15rem 0;
  color: #4a3b2a;
  text-decoration: none;
  transition: color 0.2s ease;
}

#contact-links a:hover {
  color: #8c6b5a;
}

#contact-links svg {
  flex: none;
  width: 1rem;
  height: 1rem;
  fill: none;
  stroke: currentColor;
  stroke-width: 2;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.hero {
  display: flex;
  flex-direction: column;
  gap: 1.25rem;
}

.hero .title,
.hero .subtitle {
  margin: 0;
}

.hero .title {
  line-height: 1.05;
}

.hero .subtitle {
  font-size: 1.2rem;
  font-weight: 400;
  letter-spacing: 0.02em;
  line-height: 1.5;
  max-width: 34ch;
}

.hero .subtitle::before {
  content: '';
  display: block;
  width: 3rem;
  height: 2px;
  margin-bottom: 1.25rem;
  background-color: #8c6b5a;
}

.actions {
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem;
  margin-top: 0.5rem;
}

.actions .button {
  padding: 0.75rem 1.4rem;
}

.button.secondary {
  background-color: transparent;
  box-shadow: inset 0 0 0 2px #6b5344;
  color: #6b5344;
}

.button.secondary:hover {
  background-color: #6b5344;
  box-shadow: inset 0 0 0 2px #6b5344, 0 6px 14px rgba(107, 83, 68, 0.3);
  color: #f5eee8;
}

.content {
  flex: 1;
  min-width: 0;
  margin: 1rem 0;
  /* Keeps long text, like the about page, at a readable line length. */
  max-width: 75ch;
}

.prose {
  margin-inline: auto;
}

.title {
  font-size: clamp(2rem, 6vw, 3rem);
  font-weight: 700;
  letter-spacing: -1px;
  margin-bottom: 10px;
  line-height: 1;
  text-align: left;
}

.subtitle {
  font-size: 1.5rem;
  font-weight: 300;
  color: #5a4436;
  letter-spacing: 0.1rem;
  text-align: left;
}

@media (max-width: 768px) {
  :root {
    --gutter: 1rem;
  }

  #main-navigation {
    flex-direction: column;
    gap: 0.5rem;
    padding: 1rem var(--gutter);
  }

  #logo {
    height: 80px;
  }

  nav {
    justify-content: center;
  }

  main {
    flex-direction: column;
    justify-content: flex-start;
  }

  .content {
    flex: none;
    width: 100%;
  }

  /* Justified text leaves wide gaps between words on narrow screens. */
  p {
    text-align: left;
  }

  .subtitle {
    font-size: 1.25rem;
  }

  .actions .button {
    flex: 1 1 auto;
  }

  #welcome-img {
    flex: none;
    width: 100%;
  }

  footer {
    align-items: center;
  }

  #contact {
    text-align: center;
  }

  #contact-links a {
    justify-content: center;
  }
}
