/**
 * WordPress shell — prevent theme CSS from breaking the app layout & dark mode.
 *
 * @package FT120
 */

html.ft120-html {
  margin: 0 !important;
  margin-top: 0 !important;
  padding: 0 !important;
  height: auto !important;
  min-height: 100%;
  overflow-x: clip !important;
  overflow-y: auto !important;
  -webkit-overflow-scrolling: touch;
}

body.ft120-app-page {
  margin: 0 !important;
  padding: 0 !important;
  background: #000000 !important;
  color: #f7f5f3 !important;
  height: auto !important;
  min-height: 100%;
  overflow-x: clip !important;
  overflow-y: visible !important;
}

body.ft120-app-page.admin-bar {
  padding-top: 0 !important;
}

body.ft120-app-page #wpadminbar {
  display: none !important;
}

/* Neutralise theme wrappers that trap scroll (overflow/height only — no transform/position overrides) */
body.ft120-app-page .site,
body.ft120-app-page #page,
body.ft120-app-page #content,
body.ft120-app-page .site-content,
body.ft120-app-page .entry-content,
body.ft120-app-page .wp-block-group,
body.ft120-app-page .post,
body.ft120-app-page article,
body.ft120-app-page .hentry {
  margin: 0 !important;
  padding: 0 !important;
  max-width: none !important;
  width: 100% !important;
  height: auto !important;
  max-height: none !important;
  overflow: visible !important;
  background: transparent !important;
  box-shadow: none !important;
}

#ft120-root,
.ft120-app-root {
  display: block;
  width: 100%;
  min-height: 100vh;
  min-height: 100dvh;
  position: relative;
  z-index: 1;
  overflow: visible;
}

/* Neutralise common theme overrides inside the app mount. */
#ft120-root *,
#ft120-root *::before,
#ft120-root *::after {
  box-sizing: border-box;
}

#ft120-root a {
  text-decoration: none;
}

/* Do NOT use max-width:100% on all images — it blows up the header logo on WP. */
#ft120-root .nav-logo img {
  display: block;
  height: 40px !important;
  width: auto !important;
  max-width: 64px !important;
  object-fit: contain;
}

#ft120-root .footer-brand img {
  display: block;
  height: 54px !important;
  width: auto !important;
  max-width: 96px !important;
  object-fit: contain;
}

#ft120-root .auth-card img,
#ft120-root .menu-card img,
#ft120-root .cart-line img {
  max-width: 100%;
  height: auto;
}

html.ft120-html[data-theme="light"] body.ft120-app-page {
  background: #fbf8f6 !important;
  color: #1c1112 !important;
}

@media (max-width: 860px) {
  #ft120-root .nav-logo img {
    height: 30px !important;
    max-width: 48px !important;
  }
}
