/**
 * 3D Expres theme styles.
 *
 * Visual style follows the original www.3dexpres.cz site: grey page
 * background, centred white page, red phone bar, black/red service menu,
 * red sidebar block titles. Layout itself is handled by Bootstrap 5 classes
 * in templates; this file only adds colours, typography and menu styling.
 */

:root {
  --x3d-red: #ff0e00;
  --x3d-red-dark: #d00b00;
  --x3d-black: #0d0d0d;
  --x3d-grey: #d9d9d9;
  --x3d-grey-line: #c8c8c8;
  --x3d-page-bg: #dddddd;
  --bs-link-color: var(--x3d-black);
  --bs-link-color-rgb: 13, 13, 13;
  --bs-link-hover-color: var(--x3d-red);
  --bs-link-hover-color-rgb: 255, 14, 0;
}

/* == Base == */
body {
  background-color: var(--x3d-page-bg);
  color: #000;
  font-family: Arial, Helvetica, sans-serif;
  font-size: 1rem;
  line-height: 1.5;
}
a {
  color: var(--x3d-black);
  font-weight: 700;
  text-decoration: underline;
}
a:hover,
a:focus {
  color: var(--x3d-red);
}
h1, .h1 {
  color: var(--x3d-red);
  font-size: 1.5rem;
  font-weight: 700;
  margin: 1rem 0 0.75rem;
}
h2, .h2 { font-size: 1.25rem; font-weight: 700; }
h3, .h3 { font-size: 1.1rem; font-weight: 700; }
h4, h5, h6 { font-size: 1rem; font-weight: 700; }
img {
  max-width: 100%;
  height: auto;
}
.no-underline,
.no-underline:hover,
.no-underline:focus {
  text-decoration: none !important;
}

/* == Page wrapper (white box on grey background) == */
.x3d-page {
  background-color: #fff;
  box-shadow: 0 0 12px rgba(0, 0, 0, 0.15);
  max-width: 1140px;
  /* Prevent wide content (galleries, embeds) from causing horizontal scroll. */
  overflow-x: clip;
}

/* == Phone bar == */
.x3d-topbar {
  padding: 0 0.75rem;
}
.x3d-topbar__link {
  display: inline-block;
  background-color: var(--x3d-red);
  color: var(--x3d-black);
  font-size: 1.1rem;
  font-weight: 700;
  text-transform: uppercase;
  text-decoration: none;
  padding: 0.35rem 1.5rem;
  border-radius: 0 0 1rem 1rem;
}
.x3d-topbar__link:hover,
.x3d-topbar__link:focus {
  color: var(--x3d-black);
  background-color: var(--x3d-red-dark);
  text-decoration: none;
}
.x3d-topbar__phone {
  color: #fff;
  white-space: nowrap;
}

/* == Logo and slogan == */
.x3d-brand {
  padding-top: 0.75rem;
  padding-bottom: 0.5rem;
  border-bottom: 3px solid var(--x3d-grey-line);
  margin: 0 0.75rem;
}
.x3d-brand__logo .block {
  margin: 0;
}
.x3d-brand__logo img {
  display: block;
  width: 270px;
  max-width: 100%;
  height: auto;
  padding: 0;
}
.x3d-brand__slogan {
  color: var(--x3d-red);
  font-size: 1.5rem;
  font-weight: 700;
  line-height: 1.2;
}

/* == Secondary menu (O nás | Poradna | ...) == */
.x3d-secondary {
  padding-top: 0.4rem;
  padding-bottom: 0.4rem;
}
.x3d-secondary .block {
  margin: 0;
}
.x3d-secondary__menu ul {
  display: flex;
  flex-wrap: wrap;
  flex-direction: row;
  list-style: none;
  margin: 0;
  padding: 0;
}
.x3d-secondary__menu li {
  display: flex;
  align-items: center;
}
.x3d-secondary__menu li + li::before {
  content: "|";
  padding: 0 0.6rem;
  color: var(--x3d-black);
  font-weight: 700;
}
.x3d-secondary__menu a,
.x3d-secondary__menu .nav-link {
  padding: 0.15rem 0;
  color: var(--x3d-black);
  font-weight: 700;
  text-decoration: none;
}
.x3d-secondary__menu a:hover,
.x3d-secondary__menu a.is-active,
.x3d-secondary__menu a.active {
  color: var(--x3d-red);
  text-decoration: underline;
}
.x3d-secondary__extra img {
  padding: 0;
}

/* == Main service menu (black bar with red edges) == */
.x3d-mainnav {
  background-color: var(--x3d-black);
  border-top: 8px solid var(--x3d-red);
  border-bottom: 8px solid var(--x3d-red);
  box-shadow: inset 0 1px 0 #777;
}
.x3d-mainnav__menu > .region,
.x3d-mainnav__menu .block,
.x3d-mainnav__menu .block > nav,
.x3d-mainnav__menu .content {
  width: 100%;
  margin: 0;
}
.x3d-mainnav ul {
  list-style: none;
  margin: 0;
  padding: 0;
}
.x3d-mainnav .sf-menu {
  float: none;
  display: flex;
  width: 100%;
  margin: 0;
}
.x3d-mainnav .sf-menu li {
  float: none;
  background: transparent;
}
.x3d-mainnav .sf-menu a,
.x3d-mainnav .sf-menu span.nolink {
  display: block;
  color: #fff;
  font-weight: 700;
  text-transform: uppercase;
  text-decoration: none;
  border: 0;
  line-height: 1.2;
  padding: 0.6rem 0.5rem;
}
.x3d-mainnav .sf-menu a:hover,
.x3d-mainnav .sf-menu a:focus,
.x3d-mainnav .sf-menu li.sfHover > a,
.x3d-mainnav .sf-menu a.is-active,
.x3d-mainnav .sf-menu li.active-trail > a {
  background-color: var(--x3d-red);
  color: #fff;
  text-decoration: none;
}
.x3d-mainnav .sf-menu ul {
  background-color: var(--x3d-black);
  min-width: 14em;
}
.x3d-mainnav .sf-menu ul a {
  text-transform: none;
  border-top: 1px solid #333;
}
.x3d-mainnav .sf-sub-indicator {
  filter: invert(1);
}

/* Toggler shown on small screens. */
.x3d-mainnav__toggler {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  width: 100%;
  padding: 0.5rem 0.75rem;
  color: #fff;
  font-weight: 700;
  text-transform: uppercase;
  border: 0;
  border-radius: 0;
}
.x3d-mainnav__toggler:focus {
  box-shadow: inset 0 0 0 2px var(--x3d-red);
}
.x3d-mainnav__toggler .navbar-toggler-icon {
  width: 1.5rem;
  height: 1.1rem;
  background-image:
    linear-gradient(#fff, #fff),
    linear-gradient(#fff, #fff),
    linear-gradient(#fff, #fff);
  background-position: 0 0, 0 50%, 0 100%;
  background-size: 100% 2px;
  background-repeat: no-repeat;
}

@media (min-width: 992px) {
  .x3d-mainnav .sf-menu > li {
    flex: 1 1 0;
    text-align: center;
  }
  .x3d-mainnav .sf-menu > li + li {
    border-left: 1px solid #333;
  }
  .x3d-mainnav .sf-menu ul {
    text-align: left;
  }
}

@media (max-width: 991.98px) {
  .x3d-mainnav .sf-menu {
    flex-direction: column;
  }
  .x3d-mainnav .sf-menu li {
    width: 100%;
  }
  .x3d-mainnav .sf-menu a,
  .x3d-mainnav .sf-menu span.nolink {
    border-top: 1px solid #333;
  }
  /* Show submenus inline instead of as dropdowns. */
  .x3d-mainnav .sf-menu ul {
    position: static !important;
    display: block !important;
    visibility: visible !important;
    opacity: 1 !important;
    width: 100% !important;
    min-width: 0;
    box-shadow: none;
  }
  .x3d-mainnav .sf-menu ul a {
    padding-left: 1.75rem;
    font-weight: 400;
  }
  .x3d-mainnav .sf-sub-indicator {
    display: none;
  }
}

/* == Tools bar (search, sitemap, print) == */
.x3d-tools {
  padding-top: 0.5rem;
}
.x3d-tools .block {
  margin: 0;
}
.x3d-tools__search form,
.x3d-tools__search .form-actions,
.x3d-tools__search .js-form-item {
  display: flex;
  align-items: center;
  margin: 0;
}
.x3d-tools__search .form-control {
  width: 200px;
  max-width: 100%;
  height: 1.9rem;
  padding: 0.15rem 0.5rem;
  font-size: 0.9rem;
  border: 1px solid #bbb;
  border-radius: 0;
  background-color: #f2f2f2;
}
.x3d-tools__search .form-control:focus {
  border-color: var(--x3d-red);
  box-shadow: 0 0 0 0.15rem rgba(255, 14, 0, 0.2);
  background-color: #fff;
}
/* Icon-only submit; the "Hledat" text stays for screen readers. */
.x3d-tools__search .x3d-search-submit {
  width: 1.9rem;
  height: 1.9rem;
  margin: 0 0 0 0.25rem;
  padding: 0;
  overflow: hidden;
  color: transparent;
  font-size: 0;
  border: 0;
  background: transparent url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 16 16' fill='%230d0d0d'%3E%3Cpath d='M11.742 10.344a6.5 6.5 0 1 0-1.397 1.398h-.001c.03.04.062.078.098.115l3.85 3.85a1 1 0 0 0 1.415-1.414l-3.85-3.85a1.007 1.007 0 0 0-.115-.1zM12 6.5a5.5 5.5 0 1 1-11 0 5.5 5.5 0 0 1 11 0z'/%3E%3C/svg%3E") center / 18px no-repeat;
  cursor: pointer;
}
.x3d-tools__search .x3d-search-submit:hover,
.x3d-tools__search .x3d-search-submit:focus {
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 16 16' fill='%23ff0e00'%3E%3Cpath d='M11.742 10.344a6.5 6.5 0 1 0-1.397 1.398h-.001c.03.04.062.078.098.115l3.85 3.85a1 1 0 0 0 1.415-1.414l-3.85-3.85a1.007 1.007 0 0 0-.115-.1zM12 6.5a5.5 5.5 0 1 1-11 0 5.5 5.5 0 0 1 11 0z'/%3E%3C/svg%3E");
}
.x3d-tools__icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 1.9rem;
  height: 1.9rem;
  padding: 0;
  color: var(--x3d-black);
  background: none;
  border: 0;
  cursor: pointer;
}
.x3d-tools__icon:hover,
.x3d-tools__icon:focus {
  color: var(--x3d-red);
}

/* == Main content == */
.x3d-main {
  padding-top: 0.75rem;
  padding-bottom: 1.5rem;
  min-height: 400px;
}
.x3d-content {
  text-align: left;
}
.x3d-content .breadcrumb {
  margin-bottom: 0.25rem;
  font-size: 0.9rem;
}
.x3d-content .breadcrumb a {
  font-weight: 700;
}
.x3d-content ul {
  padding-left: 1.5rem;
}

/* == Contact forms (Poptávka, Nový dotaz) == */
.contact-message-form .form-control:focus {
  border-color: var(--x3d-red);
  box-shadow: 0 0 0 0.15rem rgba(255, 14, 0, 0.2);
}
.contact-message-form .form-submit {
  background-color: var(--x3d-red);
  border: 0;
  border-radius: 0;
  color: #fff;
  font-weight: 700;
  text-transform: uppercase;
  padding: 0.5rem 1.75rem;
}
.contact-message-form .form-submit:hover,
.contact-message-form .form-submit:focus {
  background-color: var(--x3d-black);
  color: #fff;
}
.contact-message-form .captcha__image-wrapper img {
  padding: 0;
}

/* == Sidebar blocks (red title, grey box) == */
.x3d-sidebar > .region > .block,
.x3d-sidebar .block {
  background-color: var(--x3d-grey);
  border-radius: 0.6rem;
  margin-bottom: 1.25rem;
  padding: 0 0.6rem 0.75rem;
  overflow: hidden;
}
.x3d-sidebar .block > h2 {
  background-color: var(--x3d-red);
  color: #fff;
  font-size: 1.05rem;
  font-weight: 700;
  text-align: center;
  text-transform: uppercase;
  margin: 0 -0.6rem 0.6rem;
  padding: 0.4rem 0.5rem;
}
.x3d-sidebar .block > h2 a {
  color: #fff;
  text-decoration: none;
}
.x3d-sidebar .block > :not(h2) {
  background-color: #fff;
  padding: 0.4rem 0.5rem;
}
.x3d-sidebar .block > :not(h2):empty {
  display: none;
}
.x3d-sidebar ul {
  padding-left: 1rem;
  margin-bottom: 0;
}

/* Latest Poradna / FAQ items (view x3d_poradna). */
.x3d-teaser + .x3d-teaser {
  border-top: 1px solid #e5e5e5;
  margin-top: 0.4rem;
  padding-top: 0.4rem;
}
.x3d-teaser__title {
  font-size: 0.95rem;
  line-height: 1.3;
}
.x3d-teaser__text {
  font-size: 0.9rem;
  line-height: 1.35;
  margin-top: 0.15rem;
}
.x3d-sidebar .more-link {
  font-size: 0.9rem;
  margin-top: 0.5rem;
  text-align: right;
}
.x3d-sidebar .view-footer {
  margin-top: 0.25rem;
}
.x3d-newask {
  color: var(--x3d-red);
  font-size: 0.95rem;
}
.x3d-newask::before {
  content: "› ";
  text-decoration: none;
  display: inline-block;
  margin-right: 0.2rem;
}

/* == Footer == */
.x3d-footer {
  background-color: var(--x3d-black);
  border-top: 8px solid var(--x3d-red);
  color: #fff;
}
.x3d-footer a {
  color: #fff;
}
.x3d-footer a:hover,
.x3d-footer a:focus {
  color: var(--x3d-red);
}
.x3d-footer h2 {
  color: #fff;
  font-size: 1.1rem;
}
/* Footer menus as a compact link column aligned with the text blocks. */
.x3d-footer .nav-link {
  padding: 0.15rem 0;
}
.x3d-footer .nav-link::before {
  content: "› ";
  color: var(--x3d-red);
}
.x3d-copyright {
  font-size: 0.8rem;
  border-top: 1px solid #333;
}
.x3d-footer > .x3d-copyright:first-child {
  border-top: 0;
}

/* == Mobile tweaks == */
@media (max-width: 575.98px) {
  .x3d-topbar__link {
    width: 100%;
    font-size: 1rem;
    padding: 0.4rem 0.75rem;
  }
  .x3d-brand {
    justify-content: center !important;
    text-align: center;
  }
  .x3d-brand__logo img {
    width: 220px;
    margin: 0 auto;
  }
  .x3d-brand__slogan {
    font-size: 1.1rem;
    width: 100%;
  }
  .x3d-secondary {
    justify-content: center !important;
  }
}

@media (max-width: 575.98px) {
  .x3d-tools__search {
    flex: 1 1 auto;
  }
  .x3d-tools__search form,
  .x3d-tools__search .js-form-item,
  .x3d-tools__search .form-control {
    width: 100%;
  }
  .x3d-tools__search .js-form-item {
    flex: 1 1 auto;
  }
}

/* == Print: only the page content == */
@media print {
  body,
  .x3d-page {
    background: #fff !important;
    box-shadow: none !important;
  }
  body {
    font-size: 11pt;
    padding-top: 0 !important;
  }
  .x3d-page {
    max-width: none !important;
    overflow: visible !important;
  }
  .x3d-header,
  .x3d-carousel,
  .x3d-sponsors,
  .x3d-sponsors-bw,
  .x3d-sidebar,
  .x3d-news,
  .x3d-footer,
  .x3d-content .breadcrumb,
  .x3d-content nav[aria-label="breadcrumb"],
  .x3d-content [data-drupal-messages],
  .x3d-content .tabs,
  .x3d-content .nav-tabs,
  .x3d-content .action-links,
  .x3d-content .contextual,
  #toolbar-administration,
  .skip-link {
    display: none !important;
  }
  .x3d-main {
    padding: 0 !important;
    min-height: 0;
  }
  .x3d-content {
    flex: 0 0 100% !important;
    max-width: 100% !important;
    width: 100% !important;
  }
  .x3d-content a {
    color: #000;
    text-decoration: none;
  }
  .x3d-content img {
    max-width: 100% !important;
    break-inside: avoid;
  }
  h1, h2, h3 {
    break-after: avoid;
  }
}

/* == Content helpers (kept from the original theme) == */
.social-media-sharing {
  text-align: right !important;
}
.field--item {
  display: inline;
}
.field--name-name {
  font-size: 20px;
  padding-top: 15px;
}
.field--name-field-media-image {
  padding: 10px;
}
.field--name-field-link .field--item {
  display: block !important;
}
.field--name-field-image img {
  padding: 10px !important;
}
.w-10 {
  width: 10%;
}
#sponsors {
  background-color: #eeeeee;
}
.views-view-responsive-grid__item-inner {
  display: flex;
  align-items: center;
  justify-content: center;
  height: 100%;
  text-align: center;
}
.view-duplicate-of-sponsors .views-view-responsive-grid {
  margin-left: auto;
  margin-right: auto;
}
.field--name-field-gallery .field__item {
  float: left !important;
  padding-right: 5px;
  padding-bottom: 5px;
}
