@import "tbm-variables.css";

html {
  font-size: 14px;
}

@media (min-width: 768px) {
  html {
    font-size: 16px;
  }
}

span.avoidwrap {
  display: inline-block;
}

.card.plaincard {
  --bs-card-border-width: 0px;
  box-shadow: none;
  padding-left: 2rem;
  padding-right: 2rem;
}
@media (max-width: 900px) {
  .card.plaincard {
    padding-left: 1rem;
    padding-right: 1rem;
  }
}

.mb-3 {
  margin-bottom: 0rem !important;
}

.logo {
  max-width: 235px;
}
.headericons {
  text-align: center;
  max-height: 136px;
}

.photo-credit {
  font-size: 0.5rem;
  color: rgb(128, 128, 128);
  margin-top: 2px;
  margin-bottom: 0.5rem;
}

.photo-caption {
  font-size: var(--feature-body-size);
  color: rgb(60, 60, 60);
  margin-bottom: 1rem;
}

/* Add spacing for images without credits to maintain alignment */
.tbm-image-wrapper + :not(.photo-credit) {
  margin-top: 0.5rem;
}

/* Image caption corner rollover */
.tbm-image-wrapper {
  position: relative;
  display: inline-block;
  width: 100%;
}

.tbm-image-wrapper img {
  display: block;
  width: 100%;
}

.tbm-caption-corner {
  position: absolute;
  bottom: 0;
  right: 0;
  width: 60px;
  height: 60px;
  cursor: pointer;
  transition: all 0.3s ease;
  z-index: 10;
}

.tbm-caption-corner-icon {
  width: 100%;
  height: 100%;
  background: url("/images/page-corner.svg") no-repeat bottom right;
  background-size: contain;
  opacity: 0.9;
  transition:
    opacity 0.3s ease,
    transform 0.3s ease;
  transform-origin: bottom right;
}

.tbm-image-wrapper:hover .tbm-caption-corner-icon {
  opacity: 1;
  transform: scale(1.2);
}

.tbm-caption-overlay {
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  background: rgba(0, 0, 0, 0.85);
  color: white;
  padding: 12px 16px;
  padding-right: 80px;
  font-size: 0.875rem;
  line-height: 1.4;
  opacity: 0;
  visibility: hidden;
  transition:
    opacity 0.3s ease,
    visibility 0.3s ease;
  z-index: 5;
  max-height: 70%;
  overflow-y: auto;
}

.tbm-image-wrapper:hover .tbm-caption-overlay {
  opacity: 1;
  visibility: visible;
}

.tbm-caption-overlay .photo-caption {
  color: white;
  margin-bottom: 0;
}

@media (max-width: 576px) {
  .headericons {
    max-height: 136px;
  }
  .logo {
    max-width: 100px;
  }
  .card.plaincard {
    padding-left: 1rem;
    padding-right: 1rem;
  }
}

.merriweather {
  font-family: "Merriweather", serif;
}

.news-cycle {
  font-family: "News Cycle", sans-serif;
}

.newsreader {
  font-family: "Newsreader", serif;
}

.tbm-sans-serif {
  font-family: Arial, Helvetica, sans-serif;
}

.tbm-serif {
  font-family: "Times New Roman", Times, serif;
}

.tbm-areas-heading {
  margin-bottom: 0.5rem !important;
}

.tbm-heading,
.tbm-san-serif-bold {
  font-family: var(--heading-font);
  font-weight: var(--heading-weight);
  font-size: var(--heading-size);
  line-height: var(--heading-line-height);
}

.tbm-headline {
  font-family: var(--headline-font);
  font-weight: var(--headline-weight);
  line-height: var(--headline-line-height);
}

.tbm-feature-headline {
  font-family: var(--heading-font);
  font-weight: var(--feature-heading-weight);
  font-size: var(--feature-heading-size);
  line-height: var(--feature-heading-line-height);
  color: var(--feature-heading-color);
  margin-bottom: var(--feature-heading-space-after);
}

.tbm-feature-body {
  font-family: var(--feature-body-font);
  font-weight: var(--feature-body-weight);
  font-size: var(--feature-body-size);
  line-height: var(--feature-body-line-height);
  text-align: left;
  color: var(--dark-gray);
}

blockquote {
  font-family: var(--blockquote-font);
  font-size: var(--blockquote-size);
  font-weight: var(--blockquote-weight);
  line-height: var(--blockquote-line-height);
  margin: var(--blockquote-margin);
}

.g-6,
.gy-6 {
  --bs-gutter-y: 5rem;
}

.g-6,
.gx-6 {
  --bs-gutter-x: 5rem;
}

.text-danger {
  color: var(--highlight) !important;
}

.btn:focus,
.btn:active:focus,
.btn-link.nav-link:focus,
.form-control:focus,
.form-check-input:focus {
  box-shadow:
    0 0 0 0.1rem white,
    0 0 0 0.25rem #258cfb;
}

html {
  position: relative;
  min-height: 100%;
}

body {
  margin-bottom: 60px;
}

.bg-bible-magazine {
  background-color: #002a42 !important;
}

.bg-bible-magazine-light {
  background-color: #003c5a !important;
}

.btn-bible-magazine {
  color: #fff;
  background-color: #002a42;
  border-color: #002a42;
}

hr.s9 {
  height: 7px;
  border-top: 1px solid rgb(140, 140, 140);
  border-bottom: 1px solid rgb(140, 140, 140);
}

/* 
#tbm-topic-nav li {
  display: none;
}

 @media (min-width: 576px) {
  #tbm-topic-nav li:nth-child(1n):not(:nth-last-child(-n+2))
  {
    display: block;
  }
} 

@media (min-width: 768px) {
  #tbm-topic-nav li:nth-child(1n):not(:nth-last-child(-n+0))
  {
    display: block;
  }
}

@media (min-width: 992px) {
  #tbm-topic-nav li:nth-child(1n):not(:nth-last-child(-n+2))
  {
    display: block;
  }
}

@media (min-width: 1200px) {
  #tbm-topic-nav li:nth-child(1n):not(:nth-last-child(-n+4))
  {
    display: block;
  }
}

@media (min-width: 1400px) {
  #tbm-topic-nav li:nth-child(1n):not(:nth-last-child(-n+6))
  {
    display: block;
  }
} */
/* 
@media (min-width: 1600px) {
  #tbm-topic-nav li:nth-child(1n):not(:nth-last-child(-n+8))
  {
    display: block;
  }
}

*/
@media (min-width: 1600px) {
  .container,
  .container-lg,
  .container-md,
  .container-sm,
  .container-xl,
  .container-xxl {
    max-width: 1600px;
  }
}

/* Increase horizontal margins on larger screens */
@media (min-width: 992px) {
  .container-xxl {
    padding-left: 2rem;
    padding-right: 2rem;
  }
}

@media (min-width: 1200px) {
  .container-xxl {
    padding-left: 3rem;
    padding-right: 3rem;
  }
}

@media (min-width: 1400px) {
  .container-xxl {
    padding-left: 4rem;
    padding-right: 4rem;
  }
}

/* @media (min-width: 1400px) {
  .container, .container-lg, .container-md, .container-sm, .container-xl, .container-xxl {
      max-width: 100%;
  }
}  */

.stb-scripture-words a {
  text-decoration: none;
  color: #333;
  cursor: default;
}

.bible {
  font-family: Georgia, "Noto Serif", serif;

  font-size: 1.3rem;
  line-height: 2.1rem;
}

.btn-file {
  position: relative;
  overflow: hidden;
}

.btn-file input[type="file"] {
  position: absolute;
  top: 0;
  right: 0;
  min-width: 100%;
  min-height: 100%;
  font-size: 100px;
  text-align: right;
  filter: alpha(opacity=0);
  opacity: 0;
  outline: none;
  background: white;
  cursor: inherit;
  display: block;
}

h5 {
  font-size: 1.1rem;
}

.nav-link {
  font-family: var(--condensed-font);
  font-size: 1.1rem;
}

body {
  font-size: 0.85rem;
}

/* Inline article image figures */
.tbm-article-figure {
  margin: 1rem 0;
  max-width: 100%;
}

.tbm-article-figure img {
  display: block;
  max-width: 100%;
  height: auto;
  border-radius: 4px;
}

.tbm-article-figure figcaption {
  margin-top: 4px;
  font-family: "Public Sans", Arial, Helvetica, sans-serif;
  font-size: 0.85rem;
  line-height: 1.4;
}

.tbm-article-figure figcaption .photo-credit {
  font-size: 0.5rem;
  color: rgb(128, 128, 128);
  margin-top: 2px;
  margin-bottom: 0.5rem;
}

.tbm-article-figure figcaption .photo-caption {
  font-size: var(--feature-body-size);
  color: rgb(60, 60, 60);
  margin-bottom: 1rem;
}

/* Float right */
.tbm-article-figure-right {
  float: right;
  margin: 0.25rem 0 1rem 1.5rem;
  max-width: 45%;
}

/* Float left */
.tbm-article-figure-left {
  float: left;
  margin: 0.25rem 1.5rem 1rem 0;
  max-width: 45%;
}

/* Center */
.tbm-article-figure-center {
  margin: 1.5rem auto;
  text-align: center;
  max-width: 70%;
}

.tbm-article-figure-center img {
  margin: 0 auto;
}

/* Full width */
.tbm-article-figure-full {
  margin: 1.5rem 0;
  max-width: 100%;
}

/* Responsive: stack floated images on small screens */
@media (max-width: 576px) {
  .tbm-article-figure-left,
  .tbm-article-figure-right {
    float: none;
    margin: 1rem 0;
    max-width: 100%;
  }

  .tbm-article-figure-center {
    max-width: 100%;
  }
}

.topic-landing-hr {
  margin-top: 3rem;
  margin-bottom: 0.5rem;
}

/* ── Focus layout: logo row full-width on mobile, auto on desktop so nav fills remaining space ── */
@media (min-width: 1200px) {
  .tbm-nav-logo-row {
    width: auto !important;
    flex-shrink: 0;
  }
  .tbm-nav-logo-row ~ .navbar-collapse {
    flex-grow: 1;
  }
}

/* ── Nav: nested dropdown submenus ── */
.dropdown-submenu {
  position: relative;
}
.dropdown-submenu > .dropdown-menu {
  top: 0;
  left: 100%;
  margin-top: -6px;
  display: none;
}
.dropdown-submenu.show > .dropdown-menu {
  display: block;
}
@media (min-width: 768px) {
  .dropdown-submenu:hover > .dropdown-menu {
    display: block;
  }
}
@media (max-width: 767px) {
  .dropdown-submenu > .dropdown-menu {
    left: 0;
    top: 100%;
    margin-top: 0;
  }
}
.dropdown-submenu > .submenu-header {
  display: flex;
  align-items: center;
}
.dropdown-submenu > .submenu-header > a {
  flex-grow: 1;
}
.submenu-toggle {
  background: none;
  border: none;
  padding: 2px 6px;
  cursor: pointer;
  color: inherit;
  line-height: 1;
}
#tbm-topic-nav .dropdown-menu {
  width: max-content;
  min-width: 10rem;
}
#tbm-topic-nav .nav-link,
#tbm-topic-nav .nav-item > a {
  white-space: nowrap;
}

/* ── Nav: hover-open desktop dropdowns ── */
.tbm-hover-dropdown {
  position: relative;
}
.tbm-hover-dropdown > .dropdown-menu {
  display: none;
}
@media (min-width: 1200px) {
  .tbm-hover-dropdown:hover > .dropdown-menu {
    display: block;
  }
}
.tbm-hover-dropdown.show > .dropdown-menu {
  display: block;
}
.tbm-hover-dropdown .nav-link-split {
  display: flex;
  align-items: center;
  gap: 2px;
}

/* ── Article drop-cap ── */
article::first-letter {
  initial-letter: 3;
  font-weight: bold;
  padding-right: 0.5rem;
}

/* ── Article Bible references heading ── */
.tbm-bible-refs-heading {
  letter-spacing: 0.05em;
}

/* ── Mobile nav icons ── */
.tbm-nav-icon {
  height: 40px;
}

/* ── Bible two-column dropdown menu ── */
.tbm-bible-menu-inner {
  min-width: 520px;
}

/* ── Admin topic/verse editor scrollable lists ── */
.tbm-editor-list-available {
  max-height: 200px;
  overflow-y: auto;
}

.tbm-editor-list-selected {
  min-height: 40px;
  max-height: 200px;
  overflow-y: auto;
}

.tbm-editor-list-item-available {
  cursor: pointer;
}

.tbm-editor-list-item-header {
  pointer-events: none;
  font-style: italic;
}

.tbm-verse-list {
  min-height: 60px;
  max-height: 160px;
  overflow-y: auto;
}

.tbm-verse-picker-view {
  min-height: 200px;
  max-height: 400px;
  overflow-y: auto;
}

.tbm-verse-picker-dropdown {
  max-height: 300px;
  overflow-y: auto;
}
