/*
Theme Name: LOFP
Description: Тема сайту Львівської обласної федерації пауерліфтингу. Вигляд перенесено зі старої теми сайту (ті самі кольори, розміри й відступи), код написано наново: без сторонніх скриптів, з підтримкою телефонів.
Version: 1.0.0
Requires at least: 6.4
Requires PHP: 7.4
Text Domain: lofp
*/

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; text-size-adjust: 100%; }
body {
  margin: 0;
  background: #333;
  color: #666;
  font-family: Arial, Helvetica, sans-serif;
  font-size: 0.8em;
  line-height: 175%;
}
img { border: 0; max-width: 100%; height: auto; }
p, h1, h2, h3, h4, h5, h6 { margin: 0; padding: 0 0 20px; }
h1, h2, h3, h4, h5, h6 { color: #333; font-weight: normal; }
h1 a, h2 a, h3 a, h4 a, h5 a, h6 a { text-decoration: none; }
h1, h2 { font-size: 1.8em; }
h3 { font-size: 1.7em; }
h4 { font-size: 1.5em; }
h5 { font-size: 1.3em; }
h6 { font-size: 1em; }
ul, ol { padding: 0 0 0 20px; margin: 0 0 20px; }
li { padding-top: 5px; padding-bottom: 5px; }
a { color: #d81417; }
a:hover { color: #333; }
a:active { color: #000; }
a:focus-visible, button:focus-visible { outline: 2px solid #d81417; outline-offset: 2px; }
hr { border: 0; border-top: 1px solid #e9e9e9; border-bottom: 1px solid #fff; height: 0; margin: 20px 0; }

.skip-link { position: absolute; left: -9999px; top: 0; z-index: 10; padding: 8px 14px; background: #fff; color: #d81417; font-weight: bold; }
.skip-link:focus { left: 10px; top: 10px; }

/* --- frame ----------------------------------------------------------------------------- */
#main {
  background: #f7f7f7 linear-gradient(to bottom, #f2f2f2 0, #f7f7f7 110px) no-repeat top left;
  margin-top: 10px;
  border-top: 1px solid #fff;
  border-bottom: 1px solid #fff;
}
.container { max-width: 960px; margin: 0 auto; padding: 0 10px; }
#main .container { padding-bottom: 40px; }
#header { padding: 20px 0 16px; }
.site-title { padding: 0 0 20px; text-align: center; font-size: 35px; line-height: 22px; color: #333; text-transform: uppercase; }
.site-title a { color: #d81417; text-decoration: none; }
.site-title a:hover { color: #333; }

.menu-horizontal { border-top: 1px solid #ccc; border-bottom: 1px solid #ccc; margin: 5px 0; }
.sf-menu { display: flex; flex-wrap: wrap; margin: 0; padding: 0; list-style: none; line-height: 1; font-weight: bold; }
.sf-menu li { padding: 0; }
.sf-menu a { display: block; padding: 1.2em 2em; font-size: 0.95em; color: #d81417; text-decoration: none; }
.sf-menu a:hover, .sf-menu a:focus-visible, .sf-menu a[aria-current],
.sf-menu .current-menu-item > a, .sf-menu .current-page-ancestor > a,
.sf-menu .current_page_item > a, .sf-menu .current_page_ancestor > a { background: #fbfbfb; box-shadow: 0 0 2px #eee; }
.sf-menu a:active { background: #eee; }

.columns { display: flex; align-items: flex-start; gap: 20px; margin-top: 42px; }
.col-main { flex: 1 1 auto; min-width: 0; }
.col-side { flex: 0 0 140px; padding-top: 30px; font-size: 85%; text-align: center; }
.col-side a { display: block; }
.col-side img { vertical-align: bottom; }

#footer { background: #333; color: #999; padding: 15px 0; font-size: 0.85em; }
#footer p { margin: 0 10px; }
#footer a { color: #aaa; }

/* --- slideshow ------------------------------------------------------------------------- */
.slideshow { position: relative; max-width: 940px; margin: 0 auto; line-height: 0; }
.slideshow__clip { position: relative; aspect-ratio: 940 / 390; overflow: hidden; background: #2b2b2b; }
.slide { position: absolute; top: 0; left: 0; width: 100%; height: 100%; object-fit: cover; opacity: 0; visibility: hidden; transition: opacity 1s linear, visibility 0s linear 1s; }
.slide.is-active { opacity: 1; visibility: visible; transition: opacity 1s linear; }
.slideshow__buttons { position: absolute; left: 0; bottom: -15px; display: flex; gap: 3px; height: 9px; }
.slideshow__buttons button { position: relative; width: 9px; height: 9px; padding: 0; border: 1px solid #b1b0b0; border-radius: 50%; background: transparent; cursor: pointer; }
.slideshow__buttons button::before { content: ""; position: absolute; top: -8px; right: -2px; bottom: -8px; left: -2px; }
.slideshow__buttons button:hover, .slideshow__buttons button.is-active { background: #b1b0b0; }

/* --- news and pages -------------------------------------------------------------------- */
.post { display: flow-root; }
.post ul, .post ol { margin-left: 30px; }
.posttitle { padding-bottom: 5px; }
.postmeta { padding: 2px 10px; line-height: 150%; margin-bottom: 8px; text-transform: uppercase; background: #f0f0f0; font-size: 80%; }
.pagenavigation { display: flex; justify-content: space-between; gap: 10px; }
.pagenavigation a { display: inline-block; text-decoration: none; padding: 5px 10px; background: #f0f0f0; border: 1px solid #ddd; border-radius: 3px; font-size: 90%; }

.aligncenter { display: block; margin-left: auto; margin-right: auto; }
.alignleft { float: left; }
.alignright { float: right; }
img.alignleft { margin: 5px 20px 20px 0; }
img.alignright { margin: 5px 0 20px 20px; }
.wp-caption { border: 1px solid #ddd; text-align: center; background: #fff; padding: 8px 3px; margin: 10px; border-radius: 3px; max-width: 100%; }
.wp-caption img { margin: 0; padding: 0 0 5px; }
.wp-caption-text { font-size: 11px; line-height: 17px; padding: 0; margin: 0; }
blockquote { margin: 0 0 20px 30px; }

.table-scroll { overflow-x: auto; margin-bottom: 20px; }
/* the old tables are 820-840px wide and used to run under the side column: let them shrink
   to the column, and scroll sideways only where the screen is narrower than their content */
.table-scroll table { margin: 0; max-width: 100%; }
td h1, td h2, td h3, td h4, td h5, td h6, td p { padding-bottom: 20px; }

/* --- WordPress ------------------------------------------------------------------------- */
.screen-reader-text { border: 0; clip-path: inset(50%); height: 1px; margin: -1px; overflow: hidden; padding: 0; position: absolute; width: 1px; word-wrap: normal !important; }
.post-thumbnail img { display: block; margin: 0 0 20px; }
.col-side .widget { margin-bottom: 30px; }
.col-side .widget:last-child { margin-bottom: 0; }
.col-side .widget ul { list-style: none; margin: 0; padding: 0; }
.col-side .widget li { padding: 1px 0; }
h2.widgettitle { padding-bottom: 10px; margin-bottom: 5px; font-size: 175%; border-bottom: 1px solid #eee; }
figure { margin: 0 0 20px; max-width: 100%; }
figcaption { font-size: 11px; line-height: 17px; text-align: center; }
iframe, video { max-width: 100%; }
.sticky, .bypostauthor, .gallery-caption { /* classes WordPress adds; no special look */ }
.page-links { clear: both; padding-bottom: 20px; }
.searchform { margin-bottom: 20px; }

/* --- narrow screens -------------------------------------------------------------------- */
@media (max-width: 820px) {
  body { font-size: 0.9375em; }
  #header { padding-top: 16px; }
  .site-title { font-size: 26px; line-height: 1.2; padding-bottom: 14px; }
  .sf-menu { justify-content: center; }
  .sf-menu a { padding: 1em 1.1em; }
  .columns { display: block; }
  .col-side { margin-top: 30px; padding-top: 0; }
  .col-side .textwidget { display: flex; flex-wrap: wrap; justify-content: center; align-items: center; gap: 24px; }
  .col-side .widget { margin-bottom: 20px; }
  h1, h2 { font-size: 1.5em; line-height: 1.25; }
  h3 { font-size: 1.4em; line-height: 1.25; }
  h4 { font-size: 1.3em; line-height: 1.25; }
  h5 { font-size: 1.15em; line-height: 1.3; }
  img.alignleft, img.alignright { float: none; display: block; margin: 5px auto 20px; }
  .post ul, .post ol { margin-left: 10px; }
}
@media (max-width: 480px) {
  .site-title { font-size: 21px; }
  .sf-menu a { padding: 0.9em 0.8em; }
}
@media (prefers-reduced-motion: reduce) {
  .slide, .slide.is-active { transition: none; }
}
@media print {
  body { background: #fff; color: #000; font-size: 12pt; }
  #main { background: none; border: 0; margin: 0; }
  .menu-horizontal, .slideshow, .col-side, .pagenavigation, .skip-link { display: none; }
  .columns { display: block; }
  #footer { background: none; color: #000; }
  a { color: #000; }
  .table-scroll { overflow: visible; }
}
