222 lines
4.5 KiB
CSS
222 lines
4.5 KiB
CSS
/* Application shell — global (unscoped) layout breakpoints */
|
|
|
|
.app-shell {
|
|
height: 100dvh;
|
|
display: flex;
|
|
width: 100%;
|
|
background: var(--color-shell-bg);
|
|
overflow: hidden;
|
|
}
|
|
|
|
.app-layout {
|
|
display: flex;
|
|
flex-direction: row;
|
|
width: 100%;
|
|
height: 100%;
|
|
min-height: 0;
|
|
}
|
|
|
|
.app-frame {
|
|
width: 100%;
|
|
height: 100%;
|
|
background: var(--color-bg);
|
|
color: var(--color-text);
|
|
display: flex;
|
|
flex-direction: column;
|
|
overflow: hidden;
|
|
min-width: 0;
|
|
flex: 1;
|
|
}
|
|
|
|
.app-main {
|
|
flex: 1;
|
|
display: flex;
|
|
flex-direction: column;
|
|
min-height: 0;
|
|
overflow: hidden;
|
|
}
|
|
|
|
.app-main__content {
|
|
flex: 1;
|
|
display: flex;
|
|
flex-direction: column;
|
|
min-height: 0;
|
|
overflow: hidden;
|
|
}
|
|
|
|
.app-content {
|
|
flex: 1;
|
|
display: flex;
|
|
flex-direction: column;
|
|
min-height: 0;
|
|
width: 100%;
|
|
max-width: var(--content-max-width);
|
|
margin-inline: auto;
|
|
padding-inline: var(--page-padding);
|
|
position: relative;
|
|
}
|
|
|
|
.page-transition {
|
|
flex: 1;
|
|
min-height: 0;
|
|
display: flex;
|
|
flex-direction: column;
|
|
width: 100%;
|
|
overflow: hidden;
|
|
}
|
|
|
|
@media (min-width: 768px) {
|
|
.app-content {
|
|
padding-inline: var(--page-padding-tablet);
|
|
}
|
|
}
|
|
|
|
@media (min-width: 1200px) {
|
|
.app-content {
|
|
padding-inline: var(--page-padding-desktop);
|
|
}
|
|
}
|
|
|
|
/* ── Mobile: full-width native app (< 768px) ── */
|
|
.app-shell--with-nav {
|
|
justify-content: stretch;
|
|
}
|
|
|
|
.app-shell--with-nav .app-frame {
|
|
max-width: 100%;
|
|
margin: 0;
|
|
border-radius: 0;
|
|
box-shadow: none;
|
|
}
|
|
|
|
/* ── Tablet + Desktop: sidebar + header shell (>= 768px) ── */
|
|
@media (min-width: 768px) {
|
|
.app-shell--with-nav {
|
|
background: var(--color-page-background);
|
|
}
|
|
|
|
.app-shell--with-nav .app-frame {
|
|
background: var(--color-page-background);
|
|
}
|
|
|
|
.app-shell--with-nav .app-layout {
|
|
position: relative;
|
|
}
|
|
|
|
/* One continuous divider under sidebar brand + top header */
|
|
.app-shell--with-nav .app-layout::after {
|
|
content: '';
|
|
position: absolute;
|
|
top: var(--header-height);
|
|
inset-inline: 0;
|
|
height: 1px;
|
|
background: var(--color-border);
|
|
z-index: 30;
|
|
pointer-events: none;
|
|
}
|
|
|
|
/*
|
|
* Scroll lives on app-main__content. Children must not shrink+clip
|
|
* (flex + overflow:hidden), or short viewports hide the bottom of pages.
|
|
*/
|
|
.app-shell--with-nav .app-main__content {
|
|
overflow-x: hidden;
|
|
overflow-y: auto;
|
|
overscroll-behavior: contain;
|
|
-webkit-overflow-scrolling: touch;
|
|
}
|
|
|
|
.app-shell--with-nav .app-content,
|
|
.app-shell--with-nav .page-transition {
|
|
flex: 1 0 auto;
|
|
min-height: min-content;
|
|
overflow: visible;
|
|
}
|
|
|
|
/* Let route roots grow with content so the shell scroll area can work */
|
|
.app-shell--with-nav .page-transition > * {
|
|
flex: 1 0 auto;
|
|
min-height: min-content;
|
|
height: auto;
|
|
max-height: none;
|
|
overflow: visible;
|
|
}
|
|
}
|
|
|
|
/* ── Guest pages (login, register, checkout) — all breakpoints ── */
|
|
.app-shell--no-nav {
|
|
align-items: center;
|
|
justify-content: center;
|
|
padding: 16px;
|
|
background: var(--color-page-background);
|
|
}
|
|
|
|
.app-shell--no-nav .app-layout {
|
|
max-width: var(--form-max-width);
|
|
width: 100%;
|
|
height: auto;
|
|
max-height: calc(100dvh - 32px);
|
|
min-height: 0;
|
|
overflow: hidden;
|
|
}
|
|
|
|
.app-shell--no-nav .app-frame {
|
|
max-width: var(--form-max-width);
|
|
width: 100%;
|
|
height: auto;
|
|
max-height: calc(100dvh - 32px);
|
|
min-height: 0;
|
|
border-radius: var(--radius-lg);
|
|
box-shadow: var(--shadow-frame);
|
|
background: var(--color-surface);
|
|
overflow-x: hidden;
|
|
overflow-y: auto;
|
|
overscroll-behavior: contain;
|
|
-webkit-overflow-scrolling: touch;
|
|
}
|
|
|
|
.app-shell--no-nav .app-main,
|
|
.app-shell--no-nav .app-main__content,
|
|
.app-shell--no-nav .app-content,
|
|
.app-shell--no-nav .page-transition {
|
|
flex: 1 0 auto;
|
|
min-height: min-content;
|
|
overflow: visible;
|
|
height: auto;
|
|
}
|
|
|
|
.app-shell--no-nav .app-content {
|
|
padding-inline: var(--page-padding);
|
|
}
|
|
|
|
.app-shell--no-nav .page {
|
|
background: transparent;
|
|
overflow: visible;
|
|
min-height: auto;
|
|
}
|
|
|
|
.app-shell--no-nav.app-shell--wide .app-layout,
|
|
.app-shell--no-nav.app-shell--wide .app-frame {
|
|
max-width: min(var(--content-max-width), calc(100vw - 32px));
|
|
}
|
|
|
|
.app-shell--no-nav.app-shell--wide .app-frame {
|
|
background: var(--color-bg);
|
|
}
|
|
|
|
@media (min-width: 768px) {
|
|
.app-shell--no-nav {
|
|
padding: 24px;
|
|
}
|
|
|
|
.app-shell--no-nav .app-layout,
|
|
.app-shell--no-nav .app-frame {
|
|
max-height: calc(100dvh - 48px);
|
|
}
|
|
|
|
.app-shell--no-nav.app-shell--wide .app-layout,
|
|
.app-shell--no-nav.app-shell--wide .app-frame {
|
|
max-width: min(var(--content-max-width), calc(100vw - 48px));
|
|
}
|
|
}
|