/* ═══════════════════════════════════════════
   Stone Elegance — Luxury Minimal CSS
   ═══════════════════════════════════════════ */

/* ── Reset & Variables ── */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

:root {
    --accent: #c9a96e;
    --primary: #2c2c2c;
    --bg: #faf9f7;
    --bg2: #f0eee9;
    --surface: #ffffff;
    --text: #2c2c2c;
    --text2: #6b6560;
    --text3: #a09890;
    --border: #e8e4de;
    --shadow: 0 4px 24px rgba(0,0,0,0.06);
    --shadow-lg: 0 16px 48px rgba(0,0,0,0.10);
    --radius: 2px;
    --ff-display: 'Cormorant Garamond', Georgia, serif;
    --ff-body: 'Sarabun', sans-serif;
    --transition: 0.4s cubic-bezier(0.22, 1, 0.36, 1);
}

[data-theme="dark"] {
    --bg: #1a1916;
    --bg2: #252320;
    --surface: #2a2826;
    --text: #e8e4de;
    --text2: #a09890;
    --text3: #6b6560;
    --border: #3a3835;
    --shadow: 0 4px 24px rgba(0,0,0,0.25);
    --shadow-lg: 0 16px 48px rgba(0,0,0,0.35);
}

html { scroll-behavior: smooth; }
body {
    font-family: var(--ff-body);
    font-weight: 300;
    color: var(--text);
    background: var(--bg);
    line-height: 1.7;
    -webkit-font-smoothing: antialiased;
    transition: background var(--transition), color var(--transition);
    overflow-x: hidden;
}

img { max-width: 100%; display: block; }
a { color: inherit; text-decoration: none; }

.container { max-width: 1200px; margin: 0 auto; padding: 0 24px; }

h1, h2, h3, h4 { font-family: var(--ff-display); font-weight: 500; line-height: 1.2; }

/* ── Buttons ── */
.btn {
    display: inline-flex; align-items: center; gap: 8px;
    padding: 14px 36px;
    font-family: var(--ff-body); font-size: 13px; font-weight: 500;
    letter-spacing: 1.5px; text-transform: uppercase;
    border: 1px solid transparent; border-radius: var(--radius);
    cursor: pointer; transition: all var(--transition);
    background: transparent; color: var(--text);
}
.btn--accent { background: var(--accent); color: #fff; border-color: var(--accent); }
.btn--accent:hover { background: transparent; color: var(--accent); }
.btn--outline { border-color: var(--accent); color: var(--accent); }
.btn--outline:hover { background: var(--accent); color: #fff; }
.btn--sm { padding: 8px 20px; font-size: 11px; }
.btn--lg { padding: 16px 48px; font-size: 14px; }

.badge { display: inline-block; padding: 4px 12px; font-size: 10px; font-weight: 600; letter-spacing: 1.5px; text-transform: uppercase; border-radius: var(--radius); }
.badge--new { background: var(--accent); color: #fff; }

/* ═══ NAVBAR ═══ */
.nav {
    position: fixed; top: 0; left: 0; right: 0; z-index: 100;
    padding: 20px 0;
    transition: all var(--transition);
}
.nav.scrolled {
    background: var(--surface); padding: 12px 0;
    box-shadow: 0 1px 0 var(--border);
}
/* Solid navbar for inner pages (dark bg, always visible) */
.nav--solid {
    background: var(--primary); padding: 12px 0;
    box-shadow: 0 2px 8px rgba(0,0,0,0.15);
}
.nav--solid .nav__logo { color: #fff; }
.nav--solid .nav__link { color: rgba(255,255,255,0.7); }
.nav--solid .nav__link:hover { color: #fff; }
.nav--solid .nav__link.active { color: var(--accent); }
.nav--solid .nav__link.active::after { width: 100%; }
.nav--solid .theme-toggle { border-color: rgba(255,255,255,0.3); color: rgba(255,255,255,0.8); }
.nav--solid .nav__hamburger span { background: #fff; }
.nav__inner {
    max-width: 1200px; margin: 0 auto; padding: 0 24px;
    display: flex; align-items: center; justify-content: space-between;
}
.nav__logo {
    display: flex; align-items: center; gap: 10px;
    font-family: var(--ff-display); font-size: 22px; font-weight: 500;
    letter-spacing: 2px; color: #fff;
    transition: color var(--transition);
}
.nav.scrolled .nav__logo { color: var(--text); }
.nav__logo-icon { color: var(--accent); font-size: 14px; }
.nav__logo-img { display: block; height: auto; object-fit: contain; }

/* Logo switch: show dark variant on transparent nav, light variant on scrolled */
.nav__logo--has-switch .nav__logo--light { display: none; }
.nav__logo--has-switch .nav__logo--dark  { display: flex; align-items: center; }
.nav.scrolled .nav__logo--has-switch .nav__logo--light { display: flex; align-items: center; }
.nav.scrolled .nav__logo--has-switch .nav__logo--dark  { display: none; }

/* Dark theme: always show dark variant (light colored logo) */
[data-theme="dark"] .nav.scrolled .nav__logo--has-switch .nav__logo--light { display: none; }
[data-theme="dark"] .nav.scrolled .nav__logo--has-switch .nav__logo--dark  { display: flex; align-items: center; }

.nav__links { display: flex; gap: 32px; }
.nav__link {
    font-size: 12px; font-weight: 500; letter-spacing: 2px; text-transform: uppercase;
    color: rgba(255,255,255,0.75); transition: color var(--transition);
    position: relative;
}
.nav__link::after {
    content: ''; position: absolute; bottom: -4px; left: 0; width: 0; height: 1px;
    background: var(--accent); transition: width var(--transition);
}
.nav__link:hover { color: #fff; }
.nav__link:hover::after { width: 100%; }
.nav.scrolled .nav__link { color: var(--text2); }
.nav.scrolled .nav__link:hover { color: var(--text); }

.nav__actions { display: flex; align-items: center; gap: 16px; }

.theme-toggle {
    background: none; border: 1px solid rgba(255,255,255,0.3); border-radius: 50%;
    width: 38px; height: 38px; cursor: pointer;
    display: flex; align-items: center; justify-content: center;
    color: rgba(255,255,255,0.8); transition: all var(--transition);
}
.nav.scrolled .theme-toggle { border-color: var(--border); color: var(--text2); }
.theme-toggle:hover { border-color: var(--accent); color: var(--accent); }
[data-theme="light"] .icon-moon { display: none; }
[data-theme="dark"] .icon-sun { display: none; }

.nav__hamburger {
    display: none; background: none; border: none; cursor: pointer;
    width: 28px; height: 20px; position: relative; z-index: 101;
}
.nav__hamburger span {
    display: block; width: 100%; height: 2px; background: #fff;
    position: absolute; left: 0; transition: all 0.3s;
}
.nav.scrolled .nav__hamburger span { background: var(--text); }
.nav__hamburger span:nth-child(1) { top: 0; }
.nav__hamburger span:nth-child(2) { top: 9px; }
.nav__hamburger span:nth-child(3) { top: 18px; }
.nav__hamburger.open span:nth-child(1) { top: 9px; transform: rotate(45deg); }
.nav__hamburger.open span:nth-child(2) { opacity: 0; }
.nav__hamburger.open span:nth-child(3) { top: 9px; transform: rotate(-45deg); }

/* ═══ HERO ═══ */
.hero { position: relative; height: 100vh; min-height: 600px; overflow: hidden; }
.hero__slide {
    position: absolute; inset: 0;
    background-size: cover; background-position: center;
    opacity: 0; transition: opacity 1.2s ease;
}
.hero__slide.active { opacity: 1; }
.hero__overlay { position: absolute; inset: 0; background: linear-gradient(to bottom, rgba(0,0,0,0.35), rgba(0,0,0,0.6)); }
.hero__content {
    position: relative; z-index: 2; height: 100%;
    display: flex; flex-direction: column; justify-content: center; align-items: center;
    text-align: center; padding: 0 24px; color: #fff;
}
.hero__sub { font-size: 12px; font-weight: 500; letter-spacing: 4px; text-transform: uppercase; color: var(--accent); margin-bottom: 16px; }
.hero__title { font-family: var(--ff-display); font-size: clamp(36px, 7vw, 72px); font-weight: 300; margin-bottom: 20px; }
.hero__desc { font-size: 16px; max-width: 550px; color: rgba(255,255,255,0.8); margin-bottom: 36px; line-height: 1.8; }

.hero__dots { position: absolute; bottom: 40px; left: 50%; transform: translateX(-50%); z-index: 3; display: flex; gap: 10px; }
.hero__dot { width: 8px; height: 8px; border-radius: 50%; background: rgba(255,255,255,0.3); border: none; cursor: pointer; transition: all 0.4s; }
.hero__dot.active { background: var(--accent); width: 28px; border-radius: 4px; }

.hero__scroll { position: absolute; bottom: 40px; right: 40px; z-index: 3; display: flex; flex-direction: column; align-items: center; gap: 8px; color: rgba(255,255,255,0.5); font-size: 10px; letter-spacing: 2px; text-transform: uppercase; }
.hero__scroll-line { width: 1px; height: 40px; background: rgba(255,255,255,0.3); position: relative; overflow: hidden; }
.hero__scroll-line::after { content: ''; position: absolute; top: -100%; left: 0; width: 100%; height: 100%; background: var(--accent); animation: scrollLine 2s infinite; }
@keyframes scrollLine { 0%{top:-100%} 100%{top:100%} }

.animate-up { opacity: 0; transform: translateY(30px); animation: animUp 0.8s forwards; }
@keyframes animUp { to { opacity: 1; transform: translateY(0); } }

/* ═══ SECTIONS ═══ */
.section { padding: 100px 0; }
.section--dark { background: var(--bg2); }
.section--about { overflow: hidden; }
.section__header { text-align: center; margin-bottom: 60px; }
.section__sub { font-size: 12px; font-weight: 500; letter-spacing: 4px; text-transform: uppercase; color: var(--accent); margin-bottom: 12px; }
.section__title { font-size: clamp(28px, 4vw, 44px); font-weight: 300; }
.section__line { width: 60px; height: 1px; background: var(--accent); margin: 20px auto 0; }

/* ═══ CATEGORY GRID ═══ */
.cat-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(200px, 1fr)); gap: 16px; }
.cat-card {
    display: flex; flex-direction: column; align-items: center;
    padding: 40px 20px; background: var(--surface); border: 1px solid var(--border);
    text-align: center; transition: all var(--transition); position: relative; overflow: hidden;
}
.cat-card::after { content: ''; position: absolute; bottom: 0; left: 0; right: 0; height: 2px; background: var(--accent); transform: scaleX(0); transition: transform var(--transition); }
.cat-card:hover { transform: translateY(-4px); box-shadow: var(--shadow); }
.cat-card:hover::after { transform: scaleX(1); }
.cat-card__icon { font-size: 36px; margin-bottom: 16px; }
.cat-card__name { font-family: var(--ff-body); font-size: 15px; font-weight: 600; margin-bottom: 4px; }
.cat-card__en { font-size: 11px; color: var(--text3); letter-spacing: 1px; text-transform: uppercase; }
.cat-card__arrow { margin-top: 16px; font-size: 18px; color: var(--accent); opacity: 0; transition: all var(--transition); }
.cat-card:hover .cat-card__arrow { opacity: 1; transform: translateX(4px); }

/* ═══ PRODUCT GRID ═══ */
.product-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(270px, 1fr)); gap: 24px; }
.product-card { background: var(--surface); border: 1px solid var(--border); overflow: hidden; transition: all var(--transition); }
.product-card:hover { box-shadow: var(--shadow-lg); transform: translateY(-4px); }
.product-card__img { height: 280px; background-size: cover; background-position: center; position: relative; overflow: hidden; }
.product-card__hover { position: absolute; inset: 0; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 8px; background: rgba(0,0,0,0.55); opacity: 0; transition: opacity var(--transition); }
.product-card:hover .product-card__hover { opacity: 1; }
.product-card__body { padding: 20px; }
.product-card__cat { font-size: 10px; letter-spacing: 2px; text-transform: uppercase; color: var(--accent); margin-bottom: 6px; }
.product-card__name { font-family: var(--ff-display); font-size: 20px; font-weight: 500; margin-bottom: 8px; }
.product-card__price { font-size: 13px; color: var(--text2); }

/* ═══ ARRIVALS ═══ */
.arrivals-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(260px, 1fr)); gap: 24px; }
.arrival-card { display: flex; gap: 16px; background: var(--surface); border: 1px solid var(--border); padding: 16px; cursor: pointer; transition: all var(--transition); }
.arrival-card:hover { box-shadow: var(--shadow); transform: translateY(-2px); }
.arrival-card__img { width: 100px; min-height: 100px; background-size: cover; background-position: center; flex-shrink: 0; }
.arrival-card__body h3 { font-family: var(--ff-display); font-size: 18px; margin: 8px 0 6px; }
.arrival-card__body p { font-size: 12px; color: var(--text2); line-height: 1.6; }

/* ═══ ABOUT ═══ */
.about-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 60px; align-items: center; }
.about-img img { width: 100%; height: 450px; object-fit: cover; }
.about-text p { color: var(--text2); margin-bottom: 32px; font-size: 15px; }
.about-stats { display: flex; gap: 32px; }
.about-stat { text-align: center; }
.about-stat__num { display: block; font-family: var(--ff-display); font-size: 40px; font-weight: 700; color: var(--accent); }
.about-stat__label { font-size: 12px; color: var(--text2); letter-spacing: 1px; text-transform: uppercase; }

/* ═══ CONTACT ═══ */
.contact-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 48px; }
.contact-info { display: flex; flex-direction: column; gap: 24px; }
.contact-item { display: flex; gap: 16px; align-items: flex-start; }
.contact-item__icon { font-size: 24px; flex-shrink: 0; margin-top: 2px; }
.contact-item strong { display: block; font-size: 14px; margin-bottom: 2px; }
.contact-item p { font-size: 13px; color: var(--text2); }
.contact-social { display: flex; gap: 16px; margin-top: 16px; }
.contact-social a { padding: 8px 20px; border: 1px solid var(--border); font-size: 12px; letter-spacing: 1px; transition: all var(--transition); }
.contact-social a:hover { border-color: var(--accent); color: var(--accent); }

.contact-form { display: flex; flex-direction: column; gap: 16px; }
.contact-form input, .contact-form textarea {
    width: 100%; padding: 14px 18px;
    background: var(--surface); border: 1px solid var(--border);
    color: var(--text); font-family: var(--ff-body); font-size: 14px;
    transition: border var(--transition); border-radius: var(--radius);
    box-sizing: border-box;
}
.contact-form input:focus, .contact-form textarea:focus { outline: none; border-color: var(--accent); }
.contact-form .form-row { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; }
.form-msg { font-size: 13px; text-align: center; color: var(--accent); min-height: 20px; }

/* ═══ FOOTER ═══ */
.footer { padding: 20px 0; border-top: 1px solid var(--border); }
.footer__inner { display: flex; justify-content: space-between; align-items: center; }
.footer__brand { font-family: var(--ff-display); font-size: 18px; letter-spacing: 2px; }
.footer__copy { font-size: 12px; color: var(--text3); }

/* ═══ MODAL ═══ */
.modal { position: fixed; inset: 0; z-index: 200; display: flex; align-items: center; justify-content: center; opacity: 0; visibility: hidden; transition: all 0.3s; }
.modal.open { opacity: 1; visibility: visible; }
.modal__backdrop { position: absolute; inset: 0; background: rgba(0,0,0,0.6); }
.modal__content { position: relative; background: var(--surface); width: 90%; max-width: 800px; max-height: 85vh; overflow-y: auto; padding: 40px; transform: translateY(20px); transition: transform 0.3s; }
.modal.open .modal__content { transform: translateY(0); }
.modal__close { position: absolute; top: 16px; right: 20px; background: none; border: none; font-size: 28px; cursor: pointer; color: var(--text2); transition: color var(--transition); }
.modal__close:hover { color: var(--accent); }

.modal-product { display: grid; grid-template-columns: 1fr 1fr; gap: 32px; }
.modal-product__img { width: 100%; height: 350px; object-fit: cover; }
.modal-product__cat { font-size: 11px; color: var(--accent); letter-spacing: 2px; text-transform: uppercase; margin-bottom: 8px; }
.modal-product__name { font-family: var(--ff-display); font-size: 28px; font-weight: 500; margin-bottom: 12px; }
.modal-product__price { font-size: 15px; color: var(--accent); font-weight: 600; margin-bottom: 16px; }
.modal-product__desc { font-size: 14px; color: var(--text2); line-height: 1.8; margin-bottom: 20px; }
.modal-product__features { list-style: none; margin-bottom: 24px; }
.modal-product__features li { padding: 6px 0; font-size: 13px; color: var(--text2); border-bottom: 1px solid var(--border); }
.modal-product__features li::before { content: '✦ '; color: var(--accent); }

/* ═══ PRODUCTS PAGE ═══ */
.page-hero { padding: 140px 0 60px; background: var(--bg2); text-align: center; }
.filter-bar { display: flex; gap: 12px; flex-wrap: wrap; justify-content: center; padding: 32px 0; }
.filter-btn {
    padding: 10px 24px; background: var(--surface); border: 1px solid var(--border);
    font-family: var(--ff-body); font-size: 12px; letter-spacing: 1px; text-transform: uppercase;
    cursor: pointer; transition: all var(--transition); color: var(--text2);
}
.filter-btn:hover, .filter-btn.active { background: var(--accent); color: #fff; border-color: var(--accent); }

/* ═══ REVEAL ═══ */
.reveal { opacity: 0; transform: translateY(24px); transition: all 0.7s cubic-bezier(0.22, 1, 0.36, 1); }
.reveal.visible { opacity: 1; transform: translateY(0); }

/* ═══ RESPONSIVE FRONTEND ═══ */
@media (max-width: 1024px) {
    .about-grid { grid-template-columns: 1fr; gap: 32px; }
    .about-img img { height: 300px; }
}
@media (max-width: 768px) {
    .nav__links {
        position: fixed; top: 0; right: -100%; width: 280px; height: 100vh;
        background: var(--surface); flex-direction: column;
        padding: 80px 32px 32px; gap: 0;
        transition: right 0.4s; box-shadow: var(--shadow-lg);
    }
    .nav__links.open { right: 0; }
    .nav__link { color: var(--text) !important; padding: 14px 0; border-bottom: 1px solid var(--border); font-size: 13px; }
    .nav__hamburger { display: block; }
    .hero__scroll { display: none; }
    .contact-grid { grid-template-columns: 1fr; }
    .contact-form .form-row { grid-template-columns: 1fr; }
    .modal-product { grid-template-columns: 1fr; }
    .modal-product__img { height: 220px; }
    .footer__inner { flex-direction: column; gap: 12px; text-align: center; }
    .about-stats { justify-content: center; }
}


/* ═══════════════════════════════════════════
   ADMIN STYLES — Fixed Layout
   ═══════════════════════════════════════════ */

.admin-layout {
    display: grid;
    grid-template-columns: 240px 1fr;
    min-height: 100vh;
}

/* Sidebar */
.admin-sidebar {
    background: var(--primary); color: #fff;
    padding: 24px 0;
    position: fixed; left: 0; top: 0;
    width: 240px; height: 100vh;
    overflow-y: auto; z-index: 50;
}
.admin-sidebar__logo {
    padding: 0 24px 24px;
    font-family: var(--ff-display); font-size: 18px;
    letter-spacing: 2px;
    border-bottom: 1px solid rgba(255,255,255,0.1);
    display: flex; justify-content: space-between; align-items: center;
}
.admin-sidebar__logo-inner { display: flex; align-items: center; overflow: hidden; }
.admin-sidebar__logo-inner img { max-height: 30px; max-width: 160px; object-fit: contain; }
.admin-sidebar__nav { padding: 16px 0; }
.admin-sidebar__link {
    display: flex; align-items: center; gap: 10px;
    padding: 12px 24px; color: rgba(255,255,255,0.6);
    font-size: 13px; transition: all 0.2s;
}
.admin-sidebar__link:hover,
.admin-sidebar__link.active {
    background: rgba(255,255,255,0.08); color: #fff;
}

/* Main content area — KEY FIX: proper width constraint */
.admin-main {
    grid-column: 2;
    padding: 24px 32px;
    min-height: 100vh;
    background: var(--bg);
    width: 100%;
    min-width: 0;           /* prevent grid blowout */
    overflow-x: hidden;
}

.admin-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 24px;
    flex-wrap: wrap;
    gap: 12px;
}
.admin-header h1 { font-size: 24px; }

/* Admin Cards — KEY FIX: proper width & overflow */
.admin-card {
    background: var(--surface);
    border: 1px solid var(--border);
    border-radius: 8px;
    padding: 24px;
    margin-bottom: 20px;
    width: 100%;
    min-width: 0;
    overflow: hidden;
}
.admin-card > .admin-table {
    display: block;
    width: 100%;
    overflow-x: auto;
}

/* Admin Table */
.admin-table {
    width: 100%;
    border-collapse: collapse;
    font-size: 13px;
}
.admin-table th {
    text-align: left; padding: 12px 14px;
    background: var(--bg2); font-weight: 600;
    font-size: 11px; letter-spacing: 1px; text-transform: uppercase;
    color: var(--text2); border-bottom: 1px solid var(--border);
    white-space: nowrap;
}
.admin-table td {
    padding: 12px 14px;
    border-bottom: 1px solid var(--border);
    vertical-align: middle;
    word-break: break-word;
}
.admin-table tr:hover { background: var(--bg2); }
.admin-table img { width: 60px; height: 45px; object-fit: cover; border-radius: 4px; }

/* Admin Form — constrained width */
.admin-form {
    max-width: 100%;
}
.admin-form label {
    display: block; font-size: 12px; font-weight: 600;
    letter-spacing: 0.5px; color: var(--text2);
    margin-bottom: 6px; margin-top: 16px;
}
.admin-form input,
.admin-form select,
.admin-form textarea {
    width: 100%;
    padding: 10px 14px;
    border: 1px solid var(--border);
    border-radius: 6px;
    font-family: var(--ff-body);
    font-size: 14px;
    color: var(--text);
    background: var(--surface);
    transition: border 0.2s;
    box-sizing: border-box;
}
.admin-form input:focus,
.admin-form select:focus,
.admin-form textarea:focus { outline: none; border-color: var(--accent); }

.admin-form .form-row {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 16px;
}

/* Admin Buttons */
.admin-btn {
    display: inline-flex; align-items: center; gap: 6px;
    padding: 8px 18px; font-size: 12px;
    border: 1px solid var(--border); background: var(--surface);
    cursor: pointer; border-radius: 6px; transition: all 0.2s;
    font-family: var(--ff-body); color: var(--text);
    white-space: nowrap;
}
.admin-btn:hover { border-color: var(--accent); color: var(--accent); }
.admin-btn--primary { background: var(--accent); color: #fff; border-color: var(--accent); }
.admin-btn--primary:hover { background: #b8964e; }
.admin-btn--danger { color: #e53e3e; border-color: #e53e3e; }
.admin-btn--danger:hover { background: #e53e3e; color: #fff; }
.admin-btn--sm { padding: 5px 12px; font-size: 11px; }

/* Admin Stats */
.admin-stats {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(160px, 1fr));
    gap: 16px; margin-bottom: 24px;
}
.admin-stat {
    background: var(--surface); border: 1px solid var(--border);
    border-radius: 8px; padding: 20px; text-align: center;
}
.admin-stat__num { font-family: var(--ff-display); font-size: 32px; font-weight: 700; color: var(--accent); }
.admin-stat__label { font-size: 11px; color: var(--text2); text-transform: uppercase; letter-spacing: 1px; margin-top: 4px; }

/* Admin Responsive — Mobile Hamburger + Slide-in Sidebar */

/* Top bar: hidden on desktop, visible on mobile */
.admin-topbar {
    display: none;
    position: fixed; top: 0; left: 0; right: 0; z-index: 60;
    height: 56px;
    background: var(--primary); color: #fff;
    padding: 0 16px;
    align-items: center; justify-content: space-between;
}
.admin-topbar__title {
    font-family: var(--ff-display);
    font-size: 15px; letter-spacing: 1px;
    overflow: hidden; text-overflow: ellipsis; white-space: nowrap;
    max-width: 60%;
}
.admin-topbar__user { font-size: 18px; }

/* Hamburger button */
.admin-hamburger {
    background: none; border: none; cursor: pointer;
    width: 24px; height: 18px; position: relative;
    padding: 0; flex-shrink: 0;
}
.admin-hamburger span {
    display: block; width: 100%; height: 2px;
    background: #fff; position: absolute; left: 0;
    transition: all 0.3s;
}
.admin-hamburger span:nth-child(1) { top: 0; }
.admin-hamburger span:nth-child(2) { top: 8px; }
.admin-hamburger span:nth-child(3) { top: 16px; }
.admin-hamburger.open span:nth-child(1) { top: 8px; transform: rotate(45deg); }
.admin-hamburger.open span:nth-child(2) { opacity: 0; }
.admin-hamburger.open span:nth-child(3) { top: 8px; transform: rotate(-45deg); }

/* Overlay */
.admin-overlay {
    display: none;
    position: fixed; inset: 0; z-index: 69;
    background: rgba(0,0,0,0.5);
    opacity: 0; transition: opacity 0.3s;
}
.admin-overlay.open { opacity: 1; }

/* Sidebar close button (mobile only) */
.admin-sidebar__close {
    display: none;
    background: none; border: none;
    color: rgba(255,255,255,0.6); font-size: 20px;
    cursor: pointer; padding: 0;
    transition: color 0.2s;
}
.admin-sidebar__close:hover { color: #fff; }

@media (max-width: 900px) {
    /* Show mobile top bar */
    .admin-topbar { display: flex; }

    /* Grid becomes single column */
    .admin-layout { grid-template-columns: 1fr; }

    /* Sidebar: slide in from left */
    .admin-sidebar {
        position: fixed; left: -280px; top: 0;
        width: 270px; height: 100vh;
        z-index: 70;
        transition: left 0.3s cubic-bezier(0.22, 1, 0.36, 1);
        display: block;
    }
    .admin-sidebar.open { left: 0; }
    .admin-overlay.open { display: block; }

    /* Show close button & adjust logo */
    .admin-sidebar__close { display: block; }
    .admin-sidebar__logo {
        display: flex; justify-content: space-between; align-items: center;
    }

    /* Main content: full width + top padding for topbar */
    .admin-main {
        grid-column: 1;
        margin-left: 0;
        padding: 72px 16px 24px;
    }

    /* Forms single column */
    .admin-form .form-row { grid-template-columns: 1fr; }
    .admin-stats { grid-template-columns: repeat(2, 1fr); }
}
