feat: add responsive mobile navigation, fix horizontal scroll overflow, and add toggleable real corporate login view with demo autofill
This commit is contained in:
@@ -22,6 +22,11 @@
|
||||
box-sizing: border-box;
|
||||
}
|
||||
|
||||
html {
|
||||
overflow-x: hidden;
|
||||
width: 100%;
|
||||
}
|
||||
|
||||
body {
|
||||
font-family: var(--font-family);
|
||||
background-color: var(--bg-primary);
|
||||
@@ -30,6 +35,9 @@ body {
|
||||
min-height: 100vh;
|
||||
display: flex;
|
||||
flex-direction: column;
|
||||
overflow-x: hidden;
|
||||
width: 100%;
|
||||
position: relative;
|
||||
}
|
||||
|
||||
.container {
|
||||
@@ -51,6 +59,7 @@ body {
|
||||
position: sticky;
|
||||
top: 0;
|
||||
z-index: 50;
|
||||
width: 100%;
|
||||
}
|
||||
|
||||
.nav-content {
|
||||
@@ -60,6 +69,51 @@ body {
|
||||
height: 64px;
|
||||
}
|
||||
|
||||
/* Mobile Toggle Hamburger */
|
||||
.mobile-toggle {
|
||||
display: none;
|
||||
background: transparent;
|
||||
border: 1px solid var(--border-color);
|
||||
border-radius: var(--radius-md);
|
||||
cursor: pointer;
|
||||
padding: 8px;
|
||||
width: 42px;
|
||||
height: 42px;
|
||||
flex-direction: column;
|
||||
justify-content: center;
|
||||
align-items: center;
|
||||
gap: 5px;
|
||||
z-index: 100;
|
||||
transition: background 0.2s, border-color 0.2s;
|
||||
}
|
||||
|
||||
.mobile-toggle:hover, .mobile-toggle:focus-visible {
|
||||
background: rgba(255, 255, 255, 0.08);
|
||||
border-color: var(--accent);
|
||||
outline: none;
|
||||
}
|
||||
|
||||
.mobile-toggle .bar {
|
||||
width: 20px;
|
||||
height: 2px;
|
||||
background-color: var(--text-main);
|
||||
border-radius: 2px;
|
||||
transition: transform 0.25s ease, opacity 0.25s ease;
|
||||
}
|
||||
|
||||
.mobile-toggle.open .bar:nth-child(1) {
|
||||
transform: translateY(7px) rotate(45deg);
|
||||
}
|
||||
|
||||
.mobile-toggle.open .bar:nth-child(2) {
|
||||
opacity: 0;
|
||||
transform: scaleX(0);
|
||||
}
|
||||
|
||||
.mobile-toggle.open .bar:nth-child(3) {
|
||||
transform: translateY(-7px) rotate(-45deg);
|
||||
}
|
||||
|
||||
.brand {
|
||||
font-size: 1.25rem;
|
||||
font-weight: 700;
|
||||
@@ -1177,6 +1231,317 @@ body {
|
||||
.empty-icon {
|
||||
font-size: 3rem;
|
||||
margin-bottom: 16px;
|
||||
/* Demo Toggle & Credentials Box */
|
||||
.demo-toggle-wrapper {
|
||||
margin: 16px 0 12px;
|
||||
text-align: center;
|
||||
}
|
||||
|
||||
.btn-demo-toggle {
|
||||
background: rgba(255, 255, 255, 0.05);
|
||||
border: 1px dashed var(--border-color);
|
||||
border-radius: 9999px;
|
||||
color: var(--text-muted);
|
||||
padding: 6px 14px;
|
||||
font-size: 0.82rem;
|
||||
font-weight: 600;
|
||||
cursor: pointer;
|
||||
transition: all 0.2s;
|
||||
}
|
||||
|
||||
.btn-demo-toggle:hover {
|
||||
background: rgba(56, 189, 248, 0.1);
|
||||
color: var(--accent);
|
||||
border-color: var(--accent);
|
||||
}
|
||||
|
||||
.demo-credentials-card {
|
||||
background: rgba(56, 189, 248, 0.06);
|
||||
border: 1px solid rgba(56, 189, 248, 0.25);
|
||||
border-radius: var(--radius-md);
|
||||
padding: 14px 16px;
|
||||
margin-bottom: 20px;
|
||||
animation: fadeInNav 0.2s ease forwards;
|
||||
}
|
||||
|
||||
.demo-card-header {
|
||||
font-size: 0.85rem;
|
||||
color: var(--accent);
|
||||
margin-bottom: 10px;
|
||||
}
|
||||
|
||||
.demo-creds-list {
|
||||
display: flex;
|
||||
flex-direction: column;
|
||||
gap: 10px;
|
||||
}
|
||||
|
||||
.demo-cred-item {
|
||||
display: flex;
|
||||
justify-content: space-between;
|
||||
align-items: center;
|
||||
background: rgba(11, 15, 25, 0.6);
|
||||
border: 1px solid var(--border-color);
|
||||
padding: 8px 12px;
|
||||
border-radius: 6px;
|
||||
font-size: 0.85rem;
|
||||
gap: 10px;
|
||||
flex-wrap: wrap;
|
||||
}
|
||||
|
||||
.demo-cred-item code {
|
||||
background: rgba(255, 255, 255, 0.08);
|
||||
padding: 2px 6px;
|
||||
border-radius: 4px;
|
||||
color: var(--text-main);
|
||||
font-size: 0.82rem;
|
||||
}
|
||||
|
||||
.btn-fill-small {
|
||||
padding: 4px 10px;
|
||||
background: rgba(56, 189, 248, 0.15);
|
||||
border: 1px solid rgba(56, 189, 248, 0.35);
|
||||
color: var(--accent);
|
||||
border-radius: 6px;
|
||||
font-size: 0.78rem;
|
||||
font-weight: 700;
|
||||
cursor: pointer;
|
||||
transition: all 0.15s;
|
||||
white-space: nowrap;
|
||||
}
|
||||
|
||||
.btn-fill-small:hover {
|
||||
background: var(--accent);
|
||||
color: #0b0f19;
|
||||
}
|
||||
|
||||
/* ================= COMPREHENSIVE RESPONSIVE MOBILE STYLES ================= */
|
||||
@media (max-width: 768px) {
|
||||
.mobile-toggle {
|
||||
display: flex;
|
||||
}
|
||||
|
||||
.nav-links {
|
||||
display: none;
|
||||
position: fixed;
|
||||
top: 64px;
|
||||
left: 0;
|
||||
width: 100%;
|
||||
height: calc(100vh - 64px);
|
||||
background: rgba(11, 15, 25, 0.98);
|
||||
backdrop-filter: blur(20px);
|
||||
-webkit-backdrop-filter: blur(20px);
|
||||
border-bottom: 1px solid var(--border-color);
|
||||
flex-direction: column;
|
||||
padding: 24px 20px 40px;
|
||||
gap: 16px;
|
||||
overflow-y: auto;
|
||||
z-index: 90;
|
||||
align-items: stretch;
|
||||
box-shadow: 0 20px 40px rgba(0, 0, 0, 0.8);
|
||||
}
|
||||
|
||||
.nav-links.open {
|
||||
display: flex;
|
||||
animation: fadeInNav 0.22s ease forwards;
|
||||
}
|
||||
|
||||
.nav-links a {
|
||||
font-size: 1.05rem;
|
||||
padding: 12px 14px;
|
||||
border-radius: var(--radius-md);
|
||||
display: block;
|
||||
text-align: left;
|
||||
border: 1px solid transparent;
|
||||
}
|
||||
|
||||
.nav-links a:hover {
|
||||
background: rgba(56, 189, 248, 0.1);
|
||||
border-color: rgba(56, 189, 248, 0.25);
|
||||
}
|
||||
|
||||
.user-greeting {
|
||||
padding: 12px 14px;
|
||||
font-size: 0.95rem;
|
||||
display: block;
|
||||
text-align: left;
|
||||
background: rgba(255, 255, 255, 0.05);
|
||||
border-radius: var(--radius-md);
|
||||
}
|
||||
|
||||
.container {
|
||||
padding: 0 14px;
|
||||
}
|
||||
|
||||
/* Header & Top Actions in Admin */
|
||||
.admin-header {
|
||||
flex-direction: column;
|
||||
align-items: stretch;
|
||||
gap: 14px;
|
||||
}
|
||||
|
||||
.admin-header h1 {
|
||||
font-size: 1.35rem;
|
||||
}
|
||||
|
||||
.admin-actions-top {
|
||||
display: grid;
|
||||
grid-template-columns: 1fr 1fr;
|
||||
gap: 8px;
|
||||
width: 100%;
|
||||
}
|
||||
|
||||
.admin-actions-top button,
|
||||
.admin-actions-top a {
|
||||
width: 100%;
|
||||
text-align: center;
|
||||
justify-content: center;
|
||||
font-size: 0.8rem;
|
||||
padding: 9px 6px;
|
||||
white-space: normal;
|
||||
}
|
||||
|
||||
/* Tabs Navigation */
|
||||
.admin-nav-tabs {
|
||||
overflow-x: auto;
|
||||
-webkit-overflow-scrolling: touch;
|
||||
display: flex;
|
||||
flex-wrap: nowrap;
|
||||
gap: 4px;
|
||||
padding-bottom: 2px;
|
||||
}
|
||||
|
||||
.admin-tab-btn {
|
||||
padding: 10px 14px;
|
||||
font-size: 0.88rem;
|
||||
flex-shrink: 0;
|
||||
}
|
||||
|
||||
/* Events Ribbon */
|
||||
.events-ribbon {
|
||||
padding: 10px 14px;
|
||||
gap: 10px;
|
||||
flex-direction: column;
|
||||
align-items: flex-start;
|
||||
}
|
||||
|
||||
.events-ribbon-list {
|
||||
overflow-x: auto;
|
||||
-webkit-overflow-scrolling: touch;
|
||||
width: 100%;
|
||||
}
|
||||
|
||||
/* Event Action Bar */
|
||||
.event-action-bar {
|
||||
flex-direction: column;
|
||||
align-items: stretch;
|
||||
gap: 12px;
|
||||
padding: 14px 16px;
|
||||
}
|
||||
|
||||
.event-actions-right {
|
||||
width: 100%;
|
||||
}
|
||||
|
||||
.event-actions-right button {
|
||||
width: 100%;
|
||||
text-align: center;
|
||||
}
|
||||
|
||||
/* Stats Cards */
|
||||
.stats-grid {
|
||||
grid-template-columns: 1fr 1fr;
|
||||
gap: 10px;
|
||||
}
|
||||
|
||||
.stat-card {
|
||||
padding: 14px 12px;
|
||||
}
|
||||
|
||||
.stat-value {
|
||||
font-size: 1.25rem;
|
||||
}
|
||||
|
||||
/* Admin Cards & Tables */
|
||||
.admin-columns {
|
||||
grid-template-columns: 1fr;
|
||||
gap: 18px;
|
||||
}
|
||||
|
||||
.admin-card {
|
||||
padding: 18px 14px;
|
||||
}
|
||||
|
||||
.shopping-table-wrapper,
|
||||
.orders-table-wrapper {
|
||||
overflow-x: auto;
|
||||
-webkit-overflow-scrolling: touch;
|
||||
width: 100%;
|
||||
display: block;
|
||||
}
|
||||
|
||||
.data-table th, .data-table td {
|
||||
padding: 8px 6px;
|
||||
font-size: 0.82rem;
|
||||
}
|
||||
|
||||
/* Form rows on mobile */
|
||||
.form-row-2, .form-row-3 {
|
||||
grid-template-columns: 1fr;
|
||||
gap: 12px;
|
||||
}
|
||||
|
||||
/* Order Page Banner & Grid */
|
||||
.banner {
|
||||
padding: 18px 14px;
|
||||
}
|
||||
|
||||
.banner h1 {
|
||||
font-size: 1.4rem;
|
||||
}
|
||||
|
||||
.banner-top-row {
|
||||
flex-direction: column;
|
||||
align-items: flex-start;
|
||||
gap: 8px;
|
||||
}
|
||||
|
||||
.form-grid {
|
||||
grid-template-columns: 1fr;
|
||||
gap: 20px;
|
||||
}
|
||||
|
||||
.product-card {
|
||||
padding: 14px 12px;
|
||||
}
|
||||
|
||||
.product-info h3 {
|
||||
font-size: 1rem;
|
||||
}
|
||||
|
||||
.modal-card {
|
||||
width: 95%;
|
||||
padding: 20px 16px;
|
||||
max-height: 90vh;
|
||||
overflow-y: auto;
|
||||
}
|
||||
|
||||
.footer-inner {
|
||||
flex-direction: column;
|
||||
text-align: center;
|
||||
gap: 12px;
|
||||
}
|
||||
}
|
||||
|
||||
@keyframes fadeInNav {
|
||||
from {
|
||||
opacity: 0;
|
||||
transform: translateY(-8px);
|
||||
}
|
||||
to {
|
||||
opacity: 1;
|
||||
transform: translateY(0);
|
||||
}
|
||||
}
|
||||
|
||||
/* ================= PRINT MEDIA QUERY (1-PAGE A4) ================= */
|
||||
|
||||
Reference in New Issue
Block a user