:root {
  --text-color: #000000;
  --bg-color: #ffffff;
  --scrollbar-width: 0px;
}

h1 {
  font-family: "Libre Caslon Text", "Times New Roman", serif;
  font-size: 32px;
  margin-top: 32px;
  font-weight: 600;
  line-height: normal;
  margin-bottom: 16px;
  color: var(--text-color);
}

h2 {
  font-family: "Libre Caslon Text", "Times New Roman", serif;
  font-size: 24px;
  font-weight: 600;
  line-height: normal;
  margin-top: 32px;
  margin-bottom: 18px;
  color: var(--text-color);
}

.post-content .diamond {
  display: flex;
  justify-content: center;
}

.site-header {
  background: #ffffff;
  box-shadow: inset 0px -1px 0px 0px #ddd;
  height: auto;
  min-height: 80px;
  position: sticky;
  top: 0;
  z-index: 150;
}

.site-header-inner {
  max-width: 700px;
  min-height: 80px;
  margin: 0 auto;
  padding-top: 1rem;
  padding-bottom: 1rem;
  padding-left: 2rem;
  padding-right: 2rem;
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  flex-direction: row;
  justify-content: space-between;
  gap: 1rem;
}

.site-title {
  font-family: "Libre Caslon Text", "Times New Roman", serif;
  font-size: 24px;
  font-weight: 600;
  letter-spacing: 0.08em;
  text-decoration: none;
  color: #111;
}

.site-title,
.site-title:visited,
.site-title:hover,
.site-title:active {
  color: #111;
  text-decoration: none;
  font-weight: 600;
}

.post-dropdown {
  position: relative;
  display: inline-flex;
  align-items: center;
  flex: 0 1 auto;
}

.post-dropdown-toggle {
  appearance: none;
  -webkit-appearance: none;
  -moz-appearance: none;
  font: inherit;
  background: #fff;
  color: #111;
  border: 1px solid #ddd;
  padding: 0.55rem 2.4rem 0.55rem 1rem;
  cursor: pointer;
  line-height: 1.2;
  position: relative;
  min-width: 200px;
  text-align: left;
}

.post-dropdown-toggle::after {
  content: "";
  position: absolute;
  right: 0.85rem;
  top: 50%;
  transform: translateY(-50%);
  border-left: 5px solid transparent;
  border-right: 5px solid transparent;
  border-top: 6px solid #555;
}

.post-dropdown-menu {
  position: absolute;
  inset: calc(100% + 18px) 0 auto;
  list-style: none;
  margin: 0;
  padding: 0.4rem 0;
  background: #fff;
  border: 1px solid #ddd;
  border-top: 0;
  display: none;
  max-height: 500px;
  overflow: auto;
  z-index: 100;
}

.post-dropdown.is-open .post-dropdown-menu {
  display: block;
}

.post-dropdown-menu li {
  margin: 0;
}

.post-dropdown-menu a {
  display: block;
  padding: 0.6rem 1rem;
  color: #111;
  text-decoration: none;
}

/* Body */

body {
  margin: 0;
  font-family: "Inter", system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI",
    sans-serif;
  line-height: normal;
  color: #111;
  background: var(--bg-color);
  font-size: 18px;
  line-height: 1.5em;
}

body.modal-open {
  overflow: hidden;
  padding-right: var(--scrollbar-width);
}

.site-main {
  max-width: 100%;
  margin: auto;
}

.post-content img {
  width: 100%;
  height: 100%;
  padding-top: 18px;
  padding-bottom: 18px;
  box-shadow: inset 0 1px 0 #ddd, inset 0 -1px 0 #ddd;
}

hr {
  margin: 18px 0;
  border: 0;
  height: 1px;
  width: 100%;
  background: transparent;
  box-shadow: inset 0 -1px 0 #ddd; /* matches your divider */
}

/* Post hero layout */

.post-hero-section {
  display: grid;
  grid-template-columns: 1fr 1fr;
  align-items: stretch;
  width: 100%;
  height: auto;
  min-height: calc(100vh - 80px);
  overflow: visible;
}

.post-hero-left,
.post-hero-right {
  height: 100%;
  min-height: 0;
}

.post-hero-left {
  background: var(--bg-color);
  display: grid;
  grid-template-rows: 1fr auto 2fr;
  justify-items: center;
  width: 100%;
  box-shadow: inset 0 1px 0 #ddd, inset 0 -1px 0 #ddd;
  position: relative;
}
.post.is-topmost .post-hero-left {
  box-shadow: inset 0 -1px 0 #ddd;
}

.post-hero-text {
  grid-row: 2;
  width: 50%;
}

.post-hero-links {
  display: flex;
  gap: 16px;
  align-items: center;
}

.post-link {
  margin: 0px;
}

.post-link a {
  display: inline-flex;
  align-items: center;
  justify-content: center;
}

a {
  color: var(--text-color);
  cursor: pointer;
}

a:hover {
  color: black;
  font-weight: 500;
}

.post-summary {
  color: #111;
}

.post-hero-right {
  display: flex;
  align-items: stretch;
  overflow: hidden;
}

.post-hero-right .post-hero {
  margin: 0;
  width: 100%;
  height: 100%;
  max-height: 100%;
  display: flex;
  flex-direction: column;
  overflow: hidden;
}

.post-hero img {
  display: block;
  width: 100%;
  object-fit: cover;
}

.post-hero-right .post-hero img {
  flex: 1;
  height: 100%;
  width: 100%;
  max-height: 100%;
  object-fit: cover;
  object-position: center;
}

@media (max-width: 900px) {
  .post-hero-section {
    grid-template-columns: 1fr;
    grid-template-rows: auto auto;
    height: auto;
    min-height: 0;
    width: auto;
    max-width: 700px;
    margin: 0 auto;
    padding: 0 2rem;
  }

  h1.post-title {
    margin: 0;
  }

  h1 {
    margin-top: 0;
  }

  .post-hero-left {
    box-shadow: none !important;
    display: block;
  }

  .post-hero-left,
  .post-hero-right {
    height: auto;
  }

  .post-hero-text {
    position: static;
    transform: none;
    width: 100%;
    padding: 2rem 0;
    box-sizing: border-box;
  }

  .post-hero-right {
    height: auto;
    padding-left: 0;
    padding-right: 0;
  }

  .post-hero img {
    width: 100%;
    height: 100%;
    padding-top: 18px;
    padding-bottom: 18px;
    box-shadow: inset 0 1px 0 #ddd, inset 0 -1px 0 #ddd;
  }
}

.post-content {
  max-width: 700px;
  padding: 8px 2rem 32px;
  margin: auto;
  scroll-margin-top: 80px;
}

.post-video-modal {
  position: fixed;
  inset: 0;
  display: none;
  align-items: center;
  justify-content: center;
  z-index: 200;
}

.post-video-modal.is-open {
  display: flex;
}

.post-subscribe-modal {
  position: fixed;
  inset: 0;
  display: none;
  align-items: center;
  justify-content: center;
  z-index: 200;
}

.post-subscribe-modal.is-open {
  display: flex;
}

.post-video-backdrop {
  position: absolute;
  inset: 0;
  background: rgba(0, 0, 0, 0.6);
}

.post-subscribe-backdrop {
  position: absolute;
  inset: 0;
  background: rgba(0, 0, 0, 0.6);
}

.post-video-dialog {
  position: relative;
  background: var(--bg-color);
  padding: 0;
  width: 70vw;
}

.post-subscribe-dialog {
  position: relative;
  background: var(--bg-color);
  padding: 2rem;
  width: 400px;
}

.post-video-frame {
  position: relative;
  width: 100%;
  aspect-ratio: 16 / 9;
  background: #000;
}

.post-video-frame iframe {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  border: 0;
}

.post-video-close {
  position: absolute;
  top: 0.35rem;
  right: 0.35rem;
  border: none;
  background: rgba(255, 255, 255, 0.12);
  color: #000000;
  font-size: 1rem;
  width: 2rem;
  height: 2rem;
  border-radius: 999px;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  justify-content: center;
}

.post-video-close:hover {
  background: rgba(255, 255, 255, 0.25);
}

.post-subscribe-close {
  position: absolute;
  top: 0.35rem;
  right: 0.35rem;
  border: none;
  background: rgba(255, 255, 255, 0.12);
  color: #000000;
  font-size: 1rem;
  width: 2rem;
  height: 2rem;
  border-radius: 999px;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  justify-content: center;
}

.post-subscribe-close:hover {
  background: rgba(255, 255, 255, 0.25);
}

.post-footer {
  padding-top: 18px;
  padding-bottom: 18px;
  box-shadow: inset 0 1px 0 #ddd, inset 0 -1px 0 #ddd;
}

.post-subscribe-frame {
  width: 100%;
  max-width: none;
  align-items: center;
  display: grid;
  gap: 1rem;
  line-height: 1.4;
  margin: 0 auto;
  text-align: center;
}

.post-subscribe-frame form {
  display: grid;
  gap: 1rem;
  width: 100%;
}

.post-subscribe-frame form > * {
  margin: 0;
}

.post-subscribe-frame input[type="email"] {
  padding: 1rem 1rem;
  border: 1px solid #ddd;
  font: inherit;
  text-align: left;
  width: 100%;
  box-sizing: border-box;
}

.post-subscribe-frame button {
  padding: 1rem 1rem;
  border: 1px solid #ddd;
  background: #f8f8f8;
  color: #111;
  font: inherit;
  cursor: pointer;
  width: 100%;
  box-sizing: border-box;
}

.post-subscribe-frame button:hover {
  background: #ececec;
}

.post-subscribe-status {
  min-height: 0;
  color: #111;
  margin: 0;
}

.post-subscribe-status:empty {
  display: none;
}
