/* ==========================================================================
   Theme glue (hand written, not generated).
   Places page content under the fixed promo bar + header at exactly the offsets
   measured on the original studiotreta.in (1440px viewport), and gives the shop,
   cart and account pages the 1140px content column the original used.
   ========================================================================== */

/* Default: content starts 42px from the top (original: 22px page offset + 20px header placeholder). */
#page {
  padding-top: 42px;
}

body.home #page                { padding-top: 102px; }
body.st-about #page            { padding-top: 72px; }
body.st-contact #page,
body.st-collection #page,
body.woocommerce-cart #page,
body.woocommerce-account #page { padding-top: 52px; }
/* Shop / category archives: the toolbar's own 120px top margin collapses through <main>, giving 162px. */

/* 1140px column for the shop, cart and account pages. */
body.woocommerce-shop .site-main,
body.tax-product_cat .site-main,
body.woocommerce-cart .site-main,
body.woocommerce-account .site-main {
  width: 100%;
  max-width: 1140px;
  margin-inline: auto;
}

/* Keep the fixed bars below the WordPress admin bar while you are logged in. */
.admin-bar .st-promo-bar {
  top: 32px;
}

.admin-bar .st-header-wrapper {
  top: calc(var(--st-promo-height, 36px) + 32px);
}

@media (max-width: 782px) {
  .admin-bar .st-promo-bar {
    top: 46px;
  }

  .admin-bar .st-header-wrapper {
    top: calc(var(--st-promo-height, 36px) + 46px);
  }
}

/* Skip link */
.skip-link:focus {
  z-index: 100001;
}

/* Collection page: reproduces the original layout and typography.
   The original markup had an unclosed <em> that made the image column content-sized (about 62.5% of the
   row) and set the lower sections in italic; both are done on purpose here. The footer stays upright. */
@media (min-width: 1025px) {
  .stc-page .stc-story-hero .stc-story-img-col {
    flex: 0 0 auto;
    width: calc((100% - 60px) * 0.625);
  }
}

.stc-page .stc-toolbar,
.stc-page .stc-products,
.stc-page .stc-closing {
  font-style: italic;
}

/* Footer: the original sat 10px in from each side, 10px below the content (20px under the About/Contact pages). */
.st-footer {
  margin: 10px 10px 0;
}

body.st-about .st-footer,
body.st-contact .st-footer {
  margin-top: 20px;
}

body.single-product .st-footer {
  margin-top: 38px;
}

body.woocommerce-cart .st-footer {
  margin-top: 20px;
}
