/* =============================================================================
   CMS PAGES
   Helpers and content blocks for rendered CMS pages
============================================================================= */

/* -----------------------------------------------------------------------------
   Safe defaults
----------------------------------------------------------------------------- */
img,
.img-fluid,
.w-100 {
  max-width: 100%;
  height: auto;
}

hr,
.divider {
  border: 0;
  border-top: 1px solid #e5e7eb;
}

hr {
  margin: 16px 0;
}

.cms-p {
  margin: 0 0 12px;
}

/* -----------------------------------------------------------------------------
   Editor interoperability
----------------------------------------------------------------------------- */
.tox.tox-tinymce-aux,
.tox .tox-menu,
.tox .tox-toolbar,
.tox .tox-toolbar__primary {
  z-index: 99999;
}

/* -----------------------------------------------------------------------------
   Layout helpers
----------------------------------------------------------------------------- */
.cols {
  display: grid;
  gap: 14px;
  margin: 14px 0;
}

.cols--2 {
  grid-template-columns: repeat(2, minmax(0, 1fr));
}

.cols--3 {
  grid-template-columns: repeat(3, minmax(0, 1fr));
}

.cols--2-1 {
  grid-template-columns: 2fr 1fr;
}

.cols--1-2 {
  grid-template-columns: 1fr 2fr;
}

.col {
  min-width: 0;
}

/* -----------------------------------------------------------------------------
   Text helpers
----------------------------------------------------------------------------- */
.txt-small {
  font-size: 0.875em;
  opacity: 0.9;
}

.txt-highlight {
  padding: 0 0.15em;
  border-radius: 4px;
  background: #fff2a8;
}

.lettrine {
  display: inline;
  margin: 5px 5px 0 0;
  padding: 5px;
  border: 1px solid #900;
  vertical-align: text-bottom;
  font: bold 20px Matura_MT;
  color: #900;
}

/* CMS font sizes */
.fs-xs { font-size: 12px; }
.fs-sm { font-size: 14px; }
.fs-md { font-size: 16px; }
.fs-lg { font-size: 18px; }
.fs-xl { font-size: 22px; }
.fs-xxl { font-size: 28px; }

/* -----------------------------------------------------------------------------
   Badges
----------------------------------------------------------------------------- */
.badge {
  display: inline-block;
  padding: 2px 8px;
  border: 1px solid #e5e7eb;
  border-radius: 999px;
  background: #f3f4f6;
  font-size: 0.85em;
  line-height: 1.4;
}

.badge--info {
  border-color: #cfe3ff;
  background: #eef6ff;
}

.badge--warn {
  border-color: #ffd0d6;
  background: #fff1f2;
}

/* -----------------------------------------------------------------------------
   Callouts
----------------------------------------------------------------------------- */
.callout {
  margin: 14px 0;
  padding: 14px 16px;
  border-left: 4px solid #9ca3af;
  border-radius: 12px;
  background: #f9fafb;
}

.callout--note {
  border-left-color: #3b82f6;
  background: #eff6ff;
}

.callout--warn {
  border-left-color: #ef4444;
  background: #fff1f2;
}

/* -----------------------------------------------------------------------------
   Cards
----------------------------------------------------------------------------- */
.card {
  margin: 14px 0;
  padding: 16px;
  border-radius: 16px;
  background: #fff;
  box-shadow: 0 10px 25px rgba(0, 0, 0, 0.06);
}

.card--soft {
  background: #f9fafb;
  box-shadow: none;
}

.card--border {
  border: 1px solid #e5e7eb;
  box-shadow: none;
}

/* -----------------------------------------------------------------------------
   Buttons on links
----------------------------------------------------------------------------- */
a.btn--primary {
  border-color: #111;
  background: #111;
  color: #fff;
}

a.btn--ghost {
  background: transparent;
}

/* -----------------------------------------------------------------------------
   Image helpers
----------------------------------------------------------------------------- */
.rounded {
  border-radius: 16px;
}

.shadow {
  box-shadow: 0 10px 25px rgba(0, 0, 0, 0.10);
}

.float-left {
  float: left;
  margin: 0 14px 10px 0;
  max-width: 50%;
}

.float-right {
  float: right;
  margin: 0 0 10px 14px;
  max-width: 50%;
}

/* -----------------------------------------------------------------------------
   Responsive
----------------------------------------------------------------------------- */
@media (max-width: 720px) {
  .cols--2,
  .cols--3,
  .cols--2-1,
  .cols--1-2 {
    grid-template-columns: 1fr;
  }

  .float-left,
  .float-right {
    float: none;
    margin: 0 0 12px;
    max-width: 100%;
  }
}