:root {
    --bg: #f7f7f4;
    --surface: rgba(255, 255, 255, 0.88);
    --surface-solid: #ffffff;
    --border: rgba(15, 23, 42, 0.08);
    --border-strong: rgba(15, 23, 42, 0.16);
    --text: #111318;
    --muted: #5f6b7a;
    --accent: #0a84ff;
    --accent-soft: rgba(10, 132, 255, 0.12);
    --success: #12825d;
    --warning: #c56f10;
    --danger: #b42318;
    --shadow: 0 12px 35px rgba(15, 23, 42, 0.07);
    --radius-xl: 28px;
    --radius-lg: 22px;
    --radius-md: 16px;
    --radius-sm: 12px;
    --wrapper: min(1220px, calc(100vw - 32px));
}

* {
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
}

body {
    margin: 0;
    font-family: 'Manrope', sans-serif;
    color: var(--text);
    background:
        radial-gradient(circle at top left, rgba(10, 132, 255, 0.09), transparent 28%),
        radial-gradient(circle at 100% 0%, rgba(190, 192, 193, 0.18), transparent 25%),
        var(--bg);
}

a {
    color: inherit;
    text-decoration: none;
}

img {
    max-width: 100%;
    display: block;
}

button,
input,
select,
textarea {
    font: inherit;
}

button {
    cursor: pointer;
}

.wrapper {
    width: var(--wrapper);
    margin: 0 auto;
}

.site-shell {
    min-height: 100vh;
}

.top-strip {
    border-bottom: 1px solid var(--border);
    background: rgba(255, 255, 255, 0.8);
    backdrop-filter: blur(14px);
}

.top-strip-inner {
    padding: 10px 0;
    display: flex;
    justify-content: space-between;
    gap: 12px;
    font-size: 0.86rem;
    color: var(--muted);
}

.site-header {
    position: sticky;
    top: 0;
    z-index: 20;
    backdrop-filter: blur(24px);
    background: linear-gradient(180deg, rgba(255, 255, 255, 0.96) 0%, rgba(255, 255, 255, 0.96) 56%, rgba(248, 248, 245, 0.96) 80%, rgba(244, 244, 240, 0.98) 100%);
}

.header-bar {
    position: relative;
    z-index: 2;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
    padding: 18px 0 10px;
}

.brand {
    display: inline-flex;
    align-items: center;
    gap: 12px;
    font-weight: 700;
}

.header-brand-group {
    display: flex;
    align-items: center;
    gap: 10px;
    min-width: 0;
}

.brand img {
    height: 42px;
    width: auto;
    max-width: 180px;
    object-fit: contain;
}

.brand-mark {
    width: 42px;
    height: 42px;
    border-radius: 14px;
    display: grid;
    place-items: center;
    background: linear-gradient(145deg, #111318, #2f3540);
    color: #fff;
    font-weight: 800;
    letter-spacing: 0.08em;
}

.brand-text {
    font-size: 1.12rem;
    letter-spacing: -0.03em;
}

.brand-text span {
    color: var(--muted);
}

.header-nav {
    display: flex;
    align-items: center;
    gap: 6px;
    color: var(--muted);
}

.header-nav a,
.header-nav .nav-link-button {
    padding: 7px 12px;
    border-radius: 999px;
    font-weight: 600;
    font-size: 0.8rem;
    letter-spacing: -0.01em;
    white-space: nowrap;
    border: 1px solid transparent;
    transition: color 180ms ease, background 180ms ease, box-shadow 180ms ease, border-color 180ms ease;
}

.header-nav a:hover,
.header-nav .nav-link-button:hover {
    color: var(--accent);
    background: rgba(10, 132, 255, 0.05);
}

.cart-link.cart-link {
    color: var(--text);
    font-weight: 700;
    background: rgba(255, 255, 255, 0.82);
    border: 1px solid var(--border);
    box-shadow: 0 4px 14px rgba(15, 23, 42, 0.05);
    backdrop-filter: blur(10px);
}

.cart-link.cart-link:hover {
    background: rgba(255, 255, 255, 1);
    border-color: rgba(10, 132, 255, 0.22);
    box-shadow: 0 8px 20px rgba(10, 132, 255, 0.08);
}

.nav-cta-secondary.nav-cta-secondary {
    color: #E07000;
    font-weight: 700;
    background: rgba(224, 112, 0, 0.06);
    border-color: rgba(224, 112, 0, 0.10);
    backdrop-filter: blur(8px);
}

.nav-cta-secondary.nav-cta-secondary:hover {
    color: #C06000;
    background: rgba(224, 112, 0, 0.10);
    border-color: rgba(224, 112, 0, 0.18);
    box-shadow: 0 4px 16px rgba(224, 112, 0, 0.08);
}

.nav-store.nav-store {
    color: #0066CC;
    font-weight: 700;
    background: rgba(0, 102, 204, 0.06);
    border-color: rgba(0, 102, 204, 0.10);
    backdrop-filter: blur(8px);
}

.nav-store.nav-store:hover {
    color: #004C99;
    background: rgba(0, 102, 204, 0.10);
    border-color: rgba(0, 102, 204, 0.18);
    box-shadow: 0 4px 16px rgba(0, 102, 204, 0.08);
}

.nav-branch.nav-branch {
    color: #8a5a2b;
    font-weight: 700;
    background: rgba(138, 90, 43, 0.08);
    border-color: rgba(138, 90, 43, 0.12);
    backdrop-filter: blur(8px);
}

.nav-branch.nav-branch:hover {
    color: #70461f;
    background: rgba(138, 90, 43, 0.14);
    border-color: rgba(138, 90, 43, 0.20);
    box-shadow: 0 4px 16px rgba(138, 90, 43, 0.08);
}

.nav-shipping.nav-shipping {
    color: #f97316;
    font-weight: 700;
    background: rgba(249, 115, 22, 0.06);
    border-color: rgba(249, 115, 22, 0.10);
    backdrop-filter: blur(8px);
}

.nav-shipping.nav-shipping:hover {
    color: #ea580c;
    background: rgba(249, 115, 22, 0.10);
    border-color: rgba(249, 115, 22, 0.18);
    box-shadow: 0 4px 16px rgba(249, 115, 22, 0.08);
}

.nav-auth.nav-auth {
    color: #16a34a;
    font-weight: 700;
    background: rgba(22, 163, 74, 0.06);
    border-color: rgba(22, 163, 74, 0.10);
    backdrop-filter: blur(8px);
}

.nav-auth.nav-auth:hover {
    color: #15803d;
    background: rgba(22, 163, 74, 0.10);
    border-color: rgba(22, 163, 74, 0.18);
    box-shadow: 0 4px 16px rgba(22, 163, 74, 0.08);
}

.nav-admin.nav-admin {
    color: #ca8a04;
    font-weight: 700;
    background: rgba(202, 138, 4, 0.06);
    border-color: rgba(202, 138, 4, 0.10);
    backdrop-filter: blur(8px);
}

.nav-admin.nav-admin:hover {
    color: #a16207;
    background: rgba(202, 138, 4, 0.10);
    border-color: rgba(202, 138, 4, 0.18);
    box-shadow: 0 4px 16px rgba(202, 138, 4, 0.08);
}

.nav-logout-form,
.admin-logout-form {
    margin: 0;
}

.header-branch-link,
.header-store-link {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-height: 40px;
    padding: 7px 12px;
    border-radius: 999px;
    font-size: 0.8rem;
    font-weight: 600;
    letter-spacing: -0.01em;
    white-space: nowrap;
    border: 1px solid transparent;
    transition: color 180ms ease, background 180ms ease, box-shadow 180ms ease, border-color 180ms ease;
}

.header-nav .nav-primary-link {
    display: none;
}

.nav-link-button,
.admin-link-button {
    padding: 0;
    margin: 0;
    border: 0;
    background: transparent;
    color: inherit;
    font: inherit;
    cursor: pointer;
}

.admin-nav a:hover,
.admin-link-button:hover,
.store-tab:hover {
    color: var(--text);
}

.cart-link span {
    display: inline-grid;
    place-items: center;
    min-width: 22px;
    height: 22px;
    padding: 0 6px;
    border-radius: 999px;
    background: var(--accent-soft);
    color: var(--accent);
    margin-left: 6px;
    font-size: 0.76rem;
}

.menu-toggle {
    display: none;
    border: 1px solid var(--border);
    background: var(--surface-solid);
    border-radius: 12px;
    width: 44px;
    height: 44px;
    color: var(--text);
}

.store-tabs {
    position: relative;
    top: 9px;
    display: flex;
    gap: 14px;
    padding: 6px 0 20px;
    overflow-x: auto;
    align-items: stretch;
    scrollbar-width: none;
    -webkit-overflow-scrolling: touch;
}

.store-tabs-toolbar {
    display: flex;
    align-items: center;
    gap: 28px;
}

.store-tabs-toolbar .store-tabs {
    flex: 1 1 auto;
    min-width: 0;
}

.store-global-search-form {
    position: relative;
    top: 1px;
    flex: 0 0 clamp(260px, 28vw, 360px);
    margin-left: auto;
}

.store-global-search-form .search-input {
    position: relative;
    top: 1px;
    min-width: 0;
    width: 100%;
    padding: 12px 14px;
}

.store-global-search-form .btn {
    position: relative;
    top: 1px;
    min-height: 40px;
    padding: 0 11px;
    font-size: 0.9rem;
    font-weight: 600;
    border-radius: 13px;
}

.store-tabs::-webkit-scrollbar {
    display: none;
}

.store-tab,
.pill,
.badge {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border-radius: 999px;
    padding: 10px 16px;
    border: 1px solid var(--border);
    background: rgba(255, 255, 255, 0.7);
    color: var(--muted);
    white-space: nowrap;
}

.store-tab {
    flex: 0 0 auto;
    position: relative;
    overflow: hidden;
    min-height: 44px;
    padding: 0 18px;
    font-size: 0.8rem;
    font-weight: 700;
    letter-spacing: -0.01em;
    background: rgba(255, 255, 255, 0.92);
    color: #344252;
    box-shadow: 0 8px 20px rgba(17, 19, 24, 0.04);
    transition: transform 180ms ease, box-shadow 180ms ease, border-color 180ms ease, color 180ms ease, background 180ms ease;
}

.store-tab::after {
    content: '';
    position: absolute;
    left: 50%;
    bottom: 8px;
    width: 34px;
    height: 3px;
    border-radius: 999px;
    background: linear-gradient(90deg, rgba(10, 132, 255, 0.65), rgba(10, 132, 255, 1));
    opacity: 0;
    transform: translateX(-50%) scaleX(0.6);
    transition: opacity 180ms ease, transform 180ms ease;
}

.store-tab.active,
.pill.active,
.badge-accent {
    background: var(--surface-solid);
    border-color: rgba(10, 132, 255, 0.22);
    color: var(--accent);
    box-shadow: 0 10px 24px rgba(10, 132, 255, 0.08);
}

.store-tab.active {
    background: linear-gradient(180deg, rgba(255, 255, 255, 1) 0%, rgba(245, 250, 255, 1) 100%);
    border-color: rgba(10, 132, 255, 0.38);
    color: var(--text);
    box-shadow: inset 0 0 0 1px rgba(10, 132, 255, 0.14), inset 0 10px 18px rgba(10, 132, 255, 0.06);
}

.store-tab.active::after {
    opacity: 1;
    transform: translateX(-50%) scaleX(1);
}

.store-tab:not(.active):hover {
    transform: translateY(-1px);
    background: linear-gradient(180deg, rgba(255, 255, 255, 1) 0%, rgba(249, 251, 254, 1) 100%);
    border-color: rgba(10, 132, 255, 0.2);
    color: var(--text);
    box-shadow: 0 12px 26px rgba(17, 19, 24, 0.08);
}

.store-tab:not(.active):hover::after {
    opacity: 0.4;
    transform: translateX(-50%) scaleX(0.82);
}

.store-tab.active:hover {
    transform: none;
    box-shadow: inset 0 0 0 1px rgba(10, 132, 255, 0.16), inset 0 12px 20px rgba(10, 132, 255, 0.07);
}

.page-content {
    padding: 28px 0 80px;
}

.store-layout,
.two-column,
.checkout-layout,
.product-layout,
.account-layout {
    width: var(--wrapper);
    margin: 0 auto;
    display: grid;
    gap: 24px;
}

.store-layout {
    grid-template-columns: 238px minmax(0, 1fr);
    align-items: start;
}

.store-sidebar {
    display: grid;
    gap: 0;
    align-self: start;
    position: relative;
    top: -13px;
}

.store-sidebar .filter-panel {
    margin-top: 0px;
}

.store-sidebar-title {
    margin: -7px 0 0;
    font-family: 'Fraunces', serif;
    font-size: clamp(1.3rem, 2vw, 1.7rem);
    font-weight: 700;
    letter-spacing: 0.08em;
    text-transform: uppercase;
    color: #0066CC;
}

.account-column {
    display: grid;
    gap: 24px;
}

.panel,
.card,
.metric,
.summary-card,
.filter-panel,
.checkout-panel,
.admin-table-wrap,
.product-card,
.product-gallery,
.product-copy,
.account-section {
    background: var(--surface);
    border: 1px solid var(--border);
    border-radius: var(--radius-xl);
    box-shadow: var(--shadow);
    backdrop-filter: blur(18px);
}

.filter-panel,
.checkout-panel,
.summary-card,
.account-section,
.admin-table-wrap,
.product-copy,
.product-gallery {
    padding: 24px;
}

.panel-title,
.section-title,
.product-copy h1,
.page-title,
.hero-title,
.admin-topbar h1,
.auth-hero h1,
.checkout-title {
    font-family: 'Fraunces', serif;
    letter-spacing: -0.03em;
    margin: 0;
}

.eyebrow {
    margin: 0 0 10px;
    color: #0066CC;
    font-size: 0.84rem;
    font-weight: 700;
    letter-spacing: 0.08em;
    text-transform: uppercase;
}

.hero-block,
.auth-hero {
    display: grid;
    gap: 16px;
    padding: 24px 0 10px;
}

.hero-title {
    font-size: clamp(2rem, 3vw, 3.1rem);
    max-width: 12ch;
}

.hero-text,
.muted,
.product-meta,
.meta-line,
.legal-body p,
.summary-list span,
.admin-empty,
.table-meta {
    color: var(--muted);
}

.form-stack,
.inline-form,
.filters-grid,
.auth-form,
.checkout-form,
.admin-form,
.product-meta-grid {
    display: grid;
    gap: 16px;
}

.filters-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
}

.field {
    display: grid;
    gap: 8px;
}

.field-full {
    grid-column: 1 / -1;
}

.field label,
.field .label {
    font-size: 0.88rem;
    font-weight: 700;
}

.field input,
.field select,
.field textarea,
.search-input {
    width: 100%;
    border: 1px solid var(--border);
    background: rgba(255, 255, 255, 0.95);
    border-radius: 16px;
    padding: 11px 16px;
    color: var(--text);
    transition: border-color 0.2s ease, box-shadow 0.2s ease;
}

.field textarea {
    min-height: 140px;
    resize: vertical;
}

.password-toggle-field {
    position: relative;
    display: flex;
    align-items: center;
}

.password-toggle-field > input {
    padding-right: 54px;
}

.password-toggle-button {
    position: absolute;
    top: 50%;
    right: 14px;
    transform: translateY(-50%);
    border: 0;
    background: transparent;
    color: var(--muted);
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 32px;
    height: 32px;
    padding: 0;
    border-radius: 999px;
    z-index: 1;
}

.password-toggle-button svg {
    width: 18px;
    height: 18px;
    display: block;
}

.password-toggle-button:hover,
.password-toggle-button[aria-pressed="true"] {
    color: var(--accent);
}

.password-toggle-button:focus-visible {
    outline: none;
    color: var(--accent);
    box-shadow: 0 0 0 4px rgba(10, 132, 255, 0.12);
}

.field input:focus,
.field select:focus,
.field textarea:focus,
.search-input:focus {
    outline: none;
    border-color: rgba(10, 132, 255, 0.35);
    box-shadow: 0 0 0 5px rgba(10, 132, 255, 0.12);
}

.btn,
button.btn,
a.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    min-height: 40px;
    padding: 0 12px;
    border-radius: 13px;
    border: 1px solid transparent;
    background: linear-gradient(140deg, #111318, #2a3039);
    color: #fff;
    font-size: 0.9rem;
    font-weight: 600;
    transition: transform 0.2s ease, box-shadow 0.2s ease, opacity 0.2s ease;
}

.btn:hover,
button.btn:hover,
a.btn:hover {
    transform: translateY(-1px);
    box-shadow: 0 12px 24px rgba(17, 19, 24, 0.18);
}

.btn-secondary {
    background: #fff;
    color: var(--text);
    border-color: var(--border);
}

.btn-soft {
    background: var(--accent-soft);
    color: var(--accent);
    border-color: transparent;
}

.btn.btn-success,
button.btn.btn-success,
a.btn.btn-success {
    background: linear-gradient(140deg, var(--success), #0e6b4c);
    color: #fff;
    border-color: transparent;
}

.btn-danger {
    background: rgba(180, 35, 24, 0.08);
    color: var(--danger);
}

.btn[disabled] {
    opacity: 0.55;
    cursor: not-allowed;
    transform: none;
    box-shadow: none;
}

.product-grid {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 20px;
    position: relative;
    top: -17px;
}

.product-card {
    padding: 18px;
    display: flex;
    flex-direction: column;
    gap: 16px;
}

.product-card-footer {
    flex-direction: column;
    margin-top: auto;
}

.product-card-bottom {
    margin-top: auto;
    display: grid;
    gap: 12px;
}

.product-card > .product-card-bottom .price-row {
    margin: 0;
}

.product-card > .product-card-bottom .product-card-footer {
    margin-top: 0;
}

.product-card-footer .btn {
    width: 100%;
    text-align: center;
    box-sizing: border-box;
    min-height: 38px;
    padding: 0 12px;
    font-size: 0.9rem;
    font-weight: 600;
    border-radius: 13px;
}

.product-card-footer form {
    width: 100%;
}

.filter-panel .product-card-footer {
    flex-direction: row;
}

.filter-panel .product-card-footer .btn {
    flex: 1;
}

.filter-panel .btn {
    min-height: 40px;
    padding: 0 12px;
    font-size: 0.9rem;
    font-weight: 600;
    border-radius: 13px;
}

.product-image {
    aspect-ratio: 0.82;
    overflow: hidden;
    border-radius: 22px;
    background: linear-gradient(160deg, #f6f3ee, #eceff4);
    border: 1px solid rgba(15, 23, 42, 0.06);
}

.product-image img {
    width: 100%;
    height: 100%;
    object-fit: contain;
}

.product-title {
    margin: 0;
    font-size: 0.95rem;
    line-height: 1.35;
}

.product-author {
    margin: 3px 0 0;
    color: var(--muted);
    font-size: 0.88rem;
}

.price-row,
.summary-row,
.inline-row,
.meta-line,
.cart-line-price {
    display: flex;
    align-items: center;
    gap: 10px;
    justify-content: space-between;
}

.price-current {
    font-size: 0.90rem;
    font-weight: 800;
}

.price-old {
    font-size: 0.85rem;
    color: var(--muted);
    text-decoration: line-through;
}

.product-card-footer,
.summary-actions,
.cart-actions,
.auth-actions,
.checkout-actions {
    display: flex;
    gap: 12px;
    align-items: center;
    flex-wrap: wrap;
}

.product-layout {
    grid-template-columns: minmax(0, 0.92fr) minmax(0, 1.08fr);
    align-items: start;
}

.product-gallery img {
    width: 100%;
    aspect-ratio: 0.84;
    object-fit: contain;
    border-radius: 24px;
}

.product-copy {
    display: grid;
    gap: 20px;
}

.product-layout .product-copy .product-card-footer {
    flex-direction: row;
    align-items: stretch;
    flex-wrap: nowrap;
}

.product-layout .product-copy .product-card-footer form,
.product-layout .product-copy .product-card-footer > a.btn {
    flex: 1 1 0;
    width: auto;
}

.product-copy h1 {
    font-size: clamp(2rem, 3vw, 3rem);
}

.product-meta-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
}

.meta-card {
    padding: 16px;
    border-radius: 18px;
    background: rgba(15, 23, 42, 0.03);
    border: 1px solid var(--border);
}

.meta-card strong {
    display: block;
    margin-bottom: 4px;
}

.search-row {
    display: grid;
    grid-template-columns: 1.5fr repeat(3, minmax(0, 1fr));
    gap: 12px;
}

.cart-layout,
.checkout-layout,
.two-column,
.auth-layout,
.account-layout {
    grid-template-columns: minmax(0, 1.2fr) minmax(320px, 0.8fr);
}

.cart-item,
.order-card,
.admin-list-item,
.review-item {
    padding: 20px;
    border-radius: 22px;
    border: 1px solid var(--border);
    background: rgba(255, 255, 255, 0.8);
}

.cart-item {
    display: grid;
    grid-template-columns: 110px 1fr;
    gap: 18px;
}

.cart-item img {
    width: 100%;
    aspect-ratio: 0.78;
    object-fit: contain;
    border-radius: 18px;
}

.qty-control {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    border: 1px solid var(--border);
    border-radius: 14px;
    padding: 8px 10px;
}

.qty-control input {
    width: 58px;
    padding: 0;
    border: none;
    text-align: center;
    background: transparent;
}

.qty-control input:focus {
    box-shadow: none;
}

.summary-list {
    display: grid;
    gap: 16px;
    margin: 18px 0;
}

.summary-row.total {
    padding-top: 18px;
    border-top: 1px solid var(--border);
    font-size: 1.08rem;
    font-weight: 800;
}

.flash-stack {
    display: grid;
    gap: 10px;
    margin-top: 0;
    margin-bottom: 20px;
}

.page-content > .flash-stack {
    width: var(--wrapper);
    margin-left: auto;
    margin-right: auto;
}

.page-content:has(> .auth-layout) > .flash-stack {
    width: min(980px, calc(100vw - 32px));
}

.admin-main .flash-stack {
    margin-bottom: 16px;
}

.flash {
    padding: 14px 18px;
    border-radius: 18px;
    border: 1px solid transparent;
}

.checkout-panel > .flash {
    margin-bottom: 18px;
}

.payment-status-card {
    display: grid;
    gap: 18px;
}

.flash-success {
    background: rgba(18, 130, 93, 0.08);
    color: var(--success);
    border-color: rgba(18, 130, 93, 0.14);
}

.flash-error {
    background: rgba(180, 35, 24, 0.08);
    color: var(--danger);
    border-color: rgba(180, 35, 24, 0.14);
}

.flash-info {
    background: rgba(10, 132, 255, 0.08);
    color: var(--accent);
    border-color: rgba(10, 132, 255, 0.14);
}

.warning-actions {
    margin-top: 14px;
    margin-bottom: 22px;
    padding-left: 4px;
}

.form-warning-box {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 16px;
    margin-bottom: 18px;
    padding: 16px 18px;
    border-radius: 18px;
    border: 1px solid rgba(180, 35, 24, 0.18);
    background: rgba(180, 35, 24, 0.08);
}

.form-warning-box[hidden] {
    display: none;
}

.form-warning-copy {
    display: grid;
    gap: 6px;
}

.form-warning-copy strong {
    color: var(--danger);
}

.form-warning-copy p {
    margin: 0;
    color: rgba(122, 28, 21, 0.92);
}

.form-warning-dismiss {
    border: none;
    background: rgba(255, 255, 255, 0.65);
    color: var(--danger);
    border-radius: 999px;
    padding: 7px 12px;
    font: inherit;
    font-weight: 700;
    cursor: pointer;
    white-space: nowrap;
}

.site-footer {
    border-top: 1px solid var(--border);
    padding: 32px 0 48px;
    background: rgba(255, 255, 255, 0.75);
}

.footer-grid {
    display: grid;
    grid-template-columns: 1.18fr 1fr 1fr;
    gap: 32px;
    align-items: start;
}

.footer-grid h4 {
    margin: 0 0 12px;
}

.footer-grid div,
.footer-grid a {
    display: grid;
    gap: 10px;
}

.footer-brand-column {
    display: flex !important;
    align-items: center;
    justify-content: flex-start;
    align-self: stretch;
}

.footer-brand {
    display: inline-flex;
    align-items: center;
    width: max-content;
}

.footer-brand-image {
    height: 128px;
    width: auto;
    max-width: min(320px, 100%);
    object-fit: contain;
}

.footer-brand .brand-mark {
    width: 56px;
    height: 56px;
    border-radius: 18px;
}

.footer-brand .brand-text {
    font-size: 1.5rem;
}

.footer-signature {
    display: flex;
    width: 100%;
    justify-content: center;
    margin-top: 28px;
    padding-inline: 12px;
    overflow: visible;
}

.footer-signature a {
    display: inline-block;
}

.footer-signature-image {
    width: auto;
    max-width: 100%;
    height: 48px;
    display: block;
    transition: transform 400ms ease;
}

.footer-signature a:hover .footer-signature-image {
    animation: orchidee-float 2s ease-in-out infinite;
}

@keyframes orchidee-float {
    0%   { transform: translateY(0); }
    50%  { transform: translateY(-6px); }
    100% { transform: translateY(0); }
}

.auth-layout {
    width: min(980px, calc(100vw - 32px));
    margin: 0 auto;
    display: grid;
    gap: 24px;
}

.auth-hero,
.auth-card {
    padding: 28px;
    border-radius: var(--radius-xl);
    background: rgba(255, 255, 255, 0.9);
    border: 1px solid var(--border);
    box-shadow: var(--shadow);
}

.auth-card {
    display: grid;
    gap: 20px;
}

.legal-wrap {
    width: min(920px, calc(100vw - 32px));
    margin: 0 auto;
}

.legal-card {
    padding: 32px;
}

.branch-page {
    width: var(--wrapper);
    margin: 0 auto;
    display: grid;
    gap: 24px;
}

.branch-intro,
.branch-gallery-panel {
    padding: 24px;
}

.branch-gallery {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 18px;
}

.branch-placeholder {
    min-height: 220px;
    padding: 22px;
    display: grid;
    place-items: center;
    gap: 10px;
    text-align: center;
    border-radius: var(--radius-lg);
    border: 1px dashed rgba(138, 90, 43, 0.24);
    background: linear-gradient(180deg, rgba(255, 255, 255, 0.92), rgba(247, 243, 238, 0.96));
    color: var(--muted);
}

.branch-placeholder strong {
    color: #70461f;
    font-size: 1rem;
}

.branch-placeholder span {
    font-size: 0.9rem;
}

.branch-placeholder-title {
    display: inline-block;
    color: #70461f;
    font-size: 1.14rem;
    letter-spacing: 0.02em;
    text-shadow: 0 8px 18px rgba(112, 70, 31, 0.10);
    animation: branch-placeholder-float 4.8s ease-in-out infinite;
}

.branch-placeholder-note {
    display: inline-block;
    color: rgba(112, 70, 31, 0.76);
    animation: branch-placeholder-glow 5.2s ease-in-out infinite;
    animation-delay: 0.35s;
}

@keyframes branch-placeholder-float {
    0%,
    100% {
        transform: translateY(0);
        opacity: 0.92;
    }
    50% {
        transform: translateY(-4px);
        opacity: 1;
    }
}

@keyframes branch-placeholder-glow {
    0%,
    100% {
        opacity: 0.72;
    }
    50% {
        opacity: 1;
    }
}

@media (prefers-reduced-motion: reduce) {
    .branch-placeholder-title,
    .branch-placeholder-note {
        animation: none;
    }
}

.legal-body {
    display: grid;
    gap: 16px;
}

.legal-body h2 {
    margin: 18px 0 0;
}

.admin-shell {
    min-height: 100vh;
    display: grid;
    grid-template-columns: 280px 1fr;
    overflow-x: hidden;
}

.admin-sidebar {
    padding: 28px 22px;
    border-right: 1px solid var(--border);
    background: rgba(255, 255, 255, 0.82);
    backdrop-filter: blur(24px);
    position: sticky;
    top: 0;
    height: 100vh;
}

.admin-nav {
    display: grid;
    gap: 8px;
    margin-top: 26px;
}

.admin-sidebar-head {
    display: block;
}

.admin-menu-toggle {
    display: none;
}

.admin-nav a {
    border-radius: 16px;
    padding: 14px 16px;
    color: var(--muted);
}

.admin-link-button {
    width: 100%;
    text-align: left;
    border-radius: 16px;
    padding: 14px 16px;
}

.admin-nav a.active {
    background: rgba(10, 132, 255, 0.1);
    color: var(--accent);
    font-weight: 700;
}

.admin-main {
    padding: 28px;
    min-width: 0;
    overflow-x: hidden;
}

.admin-main .wrapper {
    width: 100%;
    margin-left: 0;
    margin-right: 0;
}

.admin-topbar {
    display: flex;
    justify-content: space-between;
    gap: 18px;
    align-items: start;
    margin-bottom: 24px;
}

.admin-topbar-meta {
    display: grid;
    gap: 6px;
    text-align: right;
    color: var(--muted);
}

.admin-orders-page .admin-shell,
.admin-orders-page .admin-sidebar,
.admin-orders-page .admin-brand img,
.admin-orders-page .admin-brand .brand-mark,
.admin-orders-page .admin-brand .brand-text,
.admin-orders-page .admin-nav a,
.admin-orders-page .admin-link-button {
    transition: grid-template-columns 220ms ease, padding 220ms ease, transform 220ms ease, opacity 220ms ease, max-width 220ms ease, background 220ms ease, color 220ms ease, box-shadow 220ms ease;
}

.metrics-grid {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 18px;
    margin-bottom: 24px;
}

.dashboard-metrics-grid > * {
    min-width: 0;
}

.dashboard-settings-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 24px;
    margin-bottom: 24px;
}

.metric {
    padding: 22px;
}

.metric strong {
    display: block;
    font-size: 1.8rem;
    margin-top: 10px;
}

.metric-button {
    width: 100%;
    padding: 22px;
    appearance: none;
    color: inherit;
    text-align: left;
    cursor: pointer;
    display: grid;
    gap: 10px;
    align-content: start;
}

.metric-button-security {
    text-align: left;
    justify-items: stretch;
    align-content: center;
    gap: 8px;
}

.metric-button-security .eyebrow {
    margin-bottom: 0;
    text-align: left;
}

.metric-button-security .metric-button-cta {
    width: max-content;
    margin-inline: auto;
    justify-self: center;
    pointer-events: none;
    min-height: 36px;
    padding: 0 12px;
    border-radius: 14px;
    font-size: 0.9rem;
}

.metric-button:focus-visible {
    outline: 2px solid rgba(10, 132, 255, 0.45);
    outline-offset: 3px;
}

.admin-modal[hidden] {
    display: none;
}

.admin-modal {
    position: fixed;
    inset: 0;
    z-index: 120;
    display: grid;
    place-items: center;
    padding: 24px;
}

.admin-modal-backdrop {
    position: absolute;
    inset: 0;
    border: 0;
    background: rgba(17, 19, 24, 0.48);
    cursor: pointer;
}

.admin-modal-panel {
    position: relative;
    width: min(100%, 560px);
    max-height: calc(100vh - 48px);
    overflow: auto;
}

.admin-table-wrap {
    overflow-x: auto;
}

.admin-table {
    width: 100%;
    border-collapse: collapse;
}

.admin-table th,
.admin-table td {
    padding: 14px 12px;
    text-align: left;
    border-bottom: 1px solid var(--border);
    vertical-align: top;
}

.admin-table th {
    font-size: 0.88rem;
    color: var(--muted);
    font-weight: 700;
}

.table-actions,
.inline-actions,
.badge-row {
    display: flex;
    gap: 10px;
    align-items: center;
    flex-wrap: wrap;
}

.isbn-actions input {
    flex: 1 1 220px;
    min-width: 0;
}

.isbn-actions .btn-isbn-mini {
    padding: 7px 10px;
    font-size: 0.82rem;
    min-height: 34px;
    flex: 0 0 auto;
    white-space: nowrap;
}

.field-isbn {
    gap: 6px;
}

.field-isbn > .muted {
    margin: 0;
}

.isbn-market-panel {
    margin-top: 12px;
    padding: 14px 16px;
    display: grid;
    gap: 10px;
    border: 1px solid var(--border);
    border-radius: var(--radius-md);
    background: rgba(255, 255, 255, 0.72);
}

.isbn-market-panel-head {
    display: grid;
    gap: 4px;
}

.isbn-market-panel-title {
    color: var(--text);
}

.isbn-market-panel-list {
    list-style: none;
    margin: 0;
    padding: 0;
    display: grid;
    gap: 8px;
}

.isbn-market-panel-list[hidden] {
    display: none;
}

.isbn-market-panel-item {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    padding-top: 8px;
    border-top: 1px solid var(--border);
}

.isbn-market-panel-item:first-child {
    padding-top: 0;
    border-top: none;
}

.isbn-market-panel-source {
    color: var(--text);
}

.isbn-market-panel-price {
    color: var(--text);
    white-space: nowrap;
}

.isbn-market-panel-link {
    width: fit-content;
    font-weight: 600;
}

.isbn-market-panel-link[hidden] {
    display: none;
}

.scanner-panel {
    margin-top: 12px;
    padding: 16px;
    display: grid;
    gap: 12px;
    border: 1px solid var(--border);
    border-radius: var(--radius-lg);
    background: rgba(255, 255, 255, 0.72);
}

.scanner-panel[hidden] {
    display: none;
}

.scanner-stage {
    position: relative;
    overflow: hidden;
    border-radius: var(--radius-md);
    background: #101114;
    aspect-ratio: 4 / 3;
}

.scanner-reader {
    width: 100%;
    height: 100%;
    background: #000;
}

.scanner-reader video {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.scanner-reader img {
    display: none !important;
}

.scanner-reader > div > div {
    border: none !important;
}

.scanner-overlay {
    position: absolute;
    inset: 0;
    z-index: 10;
    display: flex;
    align-items: center;
    justify-content: center;
    pointer-events: none;
}

.scanner-frame {
    width: 70%;
    aspect-ratio: 2;
    border: 2px solid rgba(255, 255, 255, 0.82);
    border-radius: 16px;
    position: relative;
    box-shadow: 0 0 0 999px rgba(0, 0, 0, 0.16);
}

.scanner-line {
    position: absolute;
    left: 5%;
    right: 5%;
    height: 2px;
    background: var(--accent);
    box-shadow: 0 0 8px var(--accent);
    top: 50%;
    animation: scan-pulse 2s ease-in-out infinite;
}

.scanner-hint {
    position: absolute;
    left: 0;
    right: 0;
    bottom: 14px;
    z-index: 11;
    text-align: center;
    color: rgba(255, 255, 255, 0.86);
    font-size: 0.86rem;
    font-weight: 600;
    pointer-events: none;
}

.scanner-status {
    margin: 0;
}

@keyframes scan-pulse {
    0%,
    100% {
        top: 10%;
        opacity: 1;
    }

    50% {
        top: 84%;
        opacity: 0.72;
    }
}

.image-url-preview {
    display: grid;
    place-items: center;
    width: min(180px, 100%);
    min-height: 220px;
    padding: 12px;
    border: 1px solid var(--border);
    border-radius: var(--radius-md);
    background: rgba(255, 255, 255, 0.78);
}

.image-url-preview-img {
    display: none;
    width: 100%;
    aspect-ratio: 0.78;
    object-fit: contain;
    border-radius: 12px;
    background: #fff;
}

.image-url-preview-placeholder {
    text-align: center;
    font-size: 0.88rem;
    line-height: 1.5;
}

.image-helper-links {
    margin-top: 10px;
    display: flex;
    flex-wrap: wrap;
    gap: 10px 14px;
}

.image-helper-link {
    font-size: 0.9rem;
    font-weight: 600;
}

.field-publisher,
.field-image-upload {
    align-self: start;
}

.badge {
    padding: 8px 12px;
    font-size: 0.83rem;
}

.product-card .badge-row {
    justify-content: space-between;
    align-items: center;
    flex-wrap: nowrap;
    margin: 0 0 8px;
}

.product-card .badge-row .badge {
    padding: 6px 10px;
    font-size: 0.65rem;
    line-height: 1.15;
}

.badge-success {
    background: rgba(18, 130, 93, 0.08);
    color: var(--success);
}

.badge-warning {
    background: rgba(197, 111, 16, 0.1);
    color: var(--warning);
}

.badge-danger {
    background: rgba(180, 35, 24, 0.08);
    color: var(--danger);
}

.tracking-code {
    display: inline-block;
    padding: 6px 10px;
    border-radius: 12px;
    background: rgba(17, 19, 24, 0.05);
    font-family: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, "Liberation Mono", monospace;
    font-size: 0.9rem;
    letter-spacing: 0.03em;
}

.status-timeline {
    display: grid;
    gap: 14px;
}

.timeline-item {
    display: grid;
    grid-template-columns: 18px minmax(0, 1fr);
    gap: 12px;
    align-items: start;
}

.timeline-dot {
    width: 12px;
    height: 12px;
    margin-top: 8px;
    border-radius: 999px;
    background: var(--accent);
    box-shadow: 0 0 0 5px rgba(10, 132, 255, 0.12);
}

.timeline-copy {
    padding-bottom: 14px;
    border-bottom: 1px solid var(--border);
}

.timeline-copy p {
    margin: 8px 0 0;
}

.table-search,
.admin-toolbar {
    display: flex;
    gap: 12px;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 18px;
    flex-wrap: wrap;
}

.admin-toolbar-title {
    display: grid;
    gap: 8px;
}

.store-layout .admin-toolbar-title {
    display: flex;
    align-items: baseline;
    gap: 12px;
    flex-wrap: wrap;
    position: relative;
    top: 2px;
}

.store-layout .admin-toolbar-title .eyebrow {
    margin: 0;
}

.store-layout .admin-toolbar {
    padding-top: 5px;
    margin-bottom: 37px;
    align-items: flex-start;
}

.store-layout .section-title {
    font-size: 0.88rem;
}

.store-layout .admin-toolbar-actions {
    align-self: flex-start;
    margin-top: -11px;
}

.admin-toolbar-heading {
    display: flex;
    align-items: center;
    gap: 12px;
    flex-wrap: wrap;
}

.admin-toolbar-actions {
    display: flex;
    align-items: center;
    gap: 12px;
    margin-left: auto;
}

.results-sort-form {
    display: flex;
    align-items: center;
    gap: 10px;
    margin-left: auto;
    transform: translateY(-5px);
}

.results-sort-form select {
    min-width: 200px;
}

.pagination-nav {
    margin-top: 28px;
    display: grid;
    gap: 12px;
    justify-items: center;
}

.pagination-links {
    display: flex;
    gap: 10px;
    align-items: center;
    justify-content: center;
    flex-wrap: wrap;
}

.pagination-ellipsis {
    color: var(--muted);
    font-weight: 700;
}

.search-compact-group {
    display: inline-flex;
    align-items: stretch;
    gap: 0;
}

.search-compact-group .search-input {
    min-width: 280px;
    border-top-right-radius: 0;
    border-bottom-right-radius: 0;
}

.search-compact-group .btn {
    border-top-left-radius: 0;
    border-bottom-left-radius: 0;
    min-height: 40px;
    padding: 0 12px;
    font-size: 0.9rem;
    font-weight: 600;
}

.sr-only {
    position: absolute;
    width: 1px;
    height: 1px;
    padding: 0;
    margin: -1px;
    overflow: hidden;
    clip: rect(0, 0, 0, 0);
    white-space: nowrap;
    border: 0;
}

.toast-stack {
    position: fixed;
    right: 20px;
    bottom: 20px;
    z-index: 40;
    display: grid;
    gap: 10px;
}

.toast {
    min-width: 260px;
    max-width: 320px;
    padding: 14px 16px;
    border-radius: 16px;
    background: rgba(17, 19, 24, 0.92);
    color: #fff;
    box-shadow: 0 18px 36px rgba(0, 0, 0, 0.18);
}

.order-timeline,
.checkout-summary,
.account-orders {
    display: grid;
    gap: 16px;
}

.embed-wrap {
    overflow: hidden;
    border-radius: 24px;
    border: 1px solid var(--border);
    background: #fff;
    min-height: 520px;
}

.empty-state {
    padding: 18px;
    text-align: center;
    color: var(--muted);
}

@media (min-width: 1101px) {
    .store-layout {
        position: relative;
        top: -2px;
    }

    .dashboard-metrics-grid {
        grid-template-columns: repeat(3, minmax(0, 1fr));
    }

    .admin-orders-page .orders-layout {
        width: 100%;
        margin: 0;
        grid-template-columns: minmax(0, 1fr);
        align-items: stretch;
    }

    .admin-orders-page.admin-orders-detail-open .admin-shell {
        grid-template-columns: 96px minmax(0, 1fr);
    }

    .admin-orders-page.admin-orders-detail-open .admin-sidebar {
        padding: 24px 12px;
    }

    .admin-orders-page.admin-orders-detail-open .admin-sidebar-head {
        display: grid;
        justify-items: center;
        gap: 16px;
    }

    .admin-orders-page.admin-orders-detail-open .admin-brand {
        width: 100%;
        justify-content: center;
        gap: 0;
    }

    .admin-orders-page.admin-orders-detail-open .admin-brand img {
        max-width: 44px;
    }

    .admin-orders-page.admin-orders-detail-open .admin-brand .brand-text {
        opacity: 0;
        max-width: 0;
        overflow: hidden;
    }

    .admin-orders-page.admin-orders-detail-open .admin-nav {
        gap: 10px;
    }

    .admin-orders-page.admin-orders-detail-open .admin-nav a,
    .admin-orders-page.admin-orders-detail-open .admin-link-button {
        position: relative;
        display: grid;
        place-items: center;
        min-height: 52px;
        padding: 0;
        font-size: 0;
        line-height: 1;
        text-align: center;
    }

    .admin-orders-page.admin-orders-detail-open .admin-nav a::before,
    .admin-orders-page.admin-orders-detail-open .admin-link-button::before {
        display: grid;
        place-items: center;
        width: 38px;
        height: 38px;
        border-radius: 14px;
        background: rgba(255, 255, 255, 0.82);
        box-shadow: inset 0 0 0 1px rgba(197, 205, 216, 0.88);
        color: currentColor;
        font-size: 0.84rem;
        font-weight: 800;
    }

    .admin-orders-page.admin-orders-detail-open .admin-nav a::before {
        content: attr(data-short);
    }

    .admin-orders-page.admin-orders-detail-open .admin-link-button::before {
        content: attr(data-short);
    }

    .footer-grid {
        display: grid;
        grid-template-columns: 1fr max-content 1fr;
        align-items: flex-start;
        width: 100%;
        margin: 0 auto;
        gap: 0;
    }

    .footer-brand-column {
        justify-self: end;
        align-self: start;
        align-items: flex-start;
        margin-right: clamp(40px, 18vw, 324px);
    }

    .footer-grid > div:nth-child(2) {
        justify-self: center;
    }

    .footer-grid > div:last-child {
        justify-self: start;
        margin-left: clamp(40px, 18vw, 324px);
    }

    .store-tabs {
        align-items: center;
    }

    .store-sidebar-title {
        position: relative;
        top: 6px;
    }

    .store-layout .admin-toolbar {
        padding-top: 0px;
    }

    .store-sidebar .filter-panel {
        margin-top: 37px;
    }
}

@media (min-width: 1101px) and (max-width: 1170px) {
    .store-layout {
        top: 0;
    }
}


@media (min-width: 1280px) {
    .store-layout .product-grid {
        grid-template-columns: repeat(5, minmax(0, 1fr));
    }

    .store-layout .product-card {
        padding: 16px;
    }
}
@media (min-width: 1361px) {
    .dashboard-metrics-grid {
        grid-template-columns: repeat(4, minmax(0, 1fr));
    }
}

.admin-orders-page.admin-orders-detail-open {
    overflow: hidden;
}

.orders-layout {
    width: 100%;
    margin: 0;
    grid-template-columns: minmax(0, 1fr);
    align-items: stretch;
}

.orders-layout > .admin-table-wrap {
    min-width: 0;
    align-self: start;
}

.orders-detail-drawer {
    position: fixed;
    inset: 0;
    z-index: 140;
}

.orders-detail-backdrop {
    position: absolute;
    inset: 0;
    background: rgba(17, 19, 24, 0.34);
    backdrop-filter: blur(4px);
    transition: opacity 220ms ease;
}

.orders-detail-panel {
    position: absolute;
    top: 0;
    right: 0;
    width: min(100vw - 24px, 460px);
    max-width: 100%;
    height: 100%;
    max-height: 100vh;
    margin: 0;
    overflow-y: auto;
    border-radius: 28px 0 0 28px;
    box-shadow: -18px 0 42px rgba(17, 19, 24, 0.18);
    transform: translateX(0);
    transition: transform 220ms ease, box-shadow 220ms ease;
}

.orders-detail-drawer.is-closing .orders-detail-backdrop {
    opacity: 0;
}

.orders-detail-drawer.is-closing .orders-detail-panel {
    transform: translateX(calc(100% + 24px));
}

.orders-detail-head {
    position: sticky;
    top: -24px;
    z-index: 1;
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 16px;
    margin: -24px -24px 20px;
    padding: 24px;
    background: linear-gradient(180deg, rgba(255, 255, 255, 0.98), rgba(255, 255, 255, 0.92));
    border-bottom: 1px solid rgba(197, 205, 216, 0.65);
    border-radius: 28px 0 0 0;
}

.orders-detail-close-button {
    flex: 0 0 auto;
}

.orders-detail-panel .summary-row {
    align-items: flex-start;
}

.orders-detail-panel .summary-row > strong {
    min-width: 0;
    overflow-wrap: anywhere;
    word-break: break-word;
    white-space: normal;
    text-align: right;
}

.orders-list-table-wrap {
    overflow-x: auto;
    overflow-y: hidden;
}

.orders-list-table {
    width: 100%;
}

.orders-list-table th,
.orders-list-table td {
    padding-inline: 10px;
}

.orders-list-table th {
    font-size: 0.76rem;
    line-height: 1.15;
    white-space: nowrap;
}

.orders-list-table td {
    padding-block: 12px;
}

.orders-list-table th:nth-child(4),
.orders-list-table th:nth-child(5),
.orders-list-table td:nth-child(4),
.orders-list-table td:nth-child(5) {
    white-space: nowrap;
}

.orders-list-table th:last-child,
.orders-list-table td:last-child {
    width: 1%;
    white-space: nowrap;
    text-align: right;
}

.orders-list-table .badge {
    padding: 4px 8px;
    font-size: 0.76rem;
    line-height: 1.1;
    white-space: nowrap;
    text-align: center;
}

.orders-list-table tbody tr:nth-child(odd) {
    background: rgba(17, 19, 24, 0.025);
}

.orders-list-detail-link {
    min-height: 40px;
    padding: 0 14px;
    border-radius: 14px;
    font-size: 0.92rem;
}

.operations-list-table-wrap {
    overflow-x: auto;
    overflow-y: hidden;
}

.operations-list-table {
    width: 100%;
}

.operations-list-table th,
.operations-list-table td {
    padding-inline: 10px;
}

.operations-list-table th {
    font-size: 0.78rem;
    line-height: 1.1;
}

.operations-list-table td {
    padding-block: 11px;
}

.operations-list-table th:nth-child(5),
.operations-list-table th:nth-child(6) {
    white-space: nowrap;
}

.operations-list-table th:last-child,
.operations-list-table td:last-child {
    width: 1%;
    white-space: nowrap;
    text-align: right;
}

.operations-list-order,
.operations-list-customer,
.operations-list-shipping,
.operations-list-next-step {
    min-width: 0;
}

.operations-list-table .badge-row {
    gap: 4px;
}

.operations-list-table .badge {
    padding: 3px 7px;
    font-size: 0.74rem;
    line-height: 1;
    white-space: nowrap;
    text-align: center;
}

.operations-list-table .table-meta {
    font-size: 0.84rem;
    line-height: 1.35;
    white-space: normal;
    overflow-wrap: anywhere;
    word-break: break-word;
}

.operations-list-table tbody tr:nth-child(odd) {
    background: rgba(17, 19, 24, 0.025);
}

.operations-list-detail-link {
    min-height: 40px;
    padding: 0 14px;
    border-radius: 14px;
    font-size: 0.92rem;
}

.products-list-table tbody tr:nth-child(odd) {
    background: rgba(17, 19, 24, 0.025);
}

.dashboard-recent-orders-table tbody tr:nth-child(odd) {
    background: rgba(17, 19, 24, 0.025);
}

@media (max-width: 1100px) {
    .orders-detail-panel {
        width: min(100vw, 640px);
        border-radius: 0;
    }

    .orders-detail-head {
        top: -24px;
        border-radius: 0;
    }

    .store-layout {
        gap: 10px;
    }

    .store-sidebar {
        top: 0;
    }

    .store-layout .admin-toolbar {
        padding-top: 0;
        gap: 12px;
        margin-top: -2px;
        margin-bottom: 22px;
    }

    .results-sort-form {
        transform: none;
        margin-top: -4px;
    }

    .product-grid {
        top: 0;
    }

    .store-layout,
    .product-layout,
    .cart-layout,
    .checkout-layout,
    .auth-layout,
    .account-layout,
    .footer-grid,
    .metrics-grid,
    .two-column,
    .admin-shell,
    .search-row,
    .filters-grid,
    .product-meta-grid {
        grid-template-columns: 1fr;
    }

    .product-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    .store-layout .product-grid {
        grid-template-columns: repeat(3, minmax(0, 1fr));
    }

    .account-layout {
        gap: 16px;
    }

    .account-column {
        gap: 16px;
    }

    .account-layout .summary-card {
        padding: 18px;
        border: 1px solid var(--border);
        border-radius: var(--radius-xl);
    }

    .account-layout .summary-card .eyebrow {
        margin-bottom: 12px;
    }

    .footer-grid {
        text-align: center;
        justify-items: center;
    }

    .footer-brand-column {
        justify-content: center;
    }

    .footer-grid div,
    .footer-grid a {
        justify-items: center;
    }

    .admin-main .two-column {
        width: 100%;
        margin: 0;
    }

    .dashboard-settings-grid {
        grid-template-columns: 1fr;
    }

    .admin-main > .metrics-grid + .two-column {
        margin-bottom: 24px;
    }

    .admin-sidebar {
        position: static;
        height: auto;
        padding: 14px 18px;
        border-right: none;
        border-bottom: 1px solid var(--border);
    }

    .admin-shell {
        grid-template-rows: auto 1fr;
    }

    .admin-sidebar-head {
        display: flex;
        align-items: center;
        justify-content: space-between;
        gap: 16px;
        width: 100%;
    }

    .admin-menu-toggle {
        display: inline-flex;
        align-items: center;
        justify-content: center;
        width: 44px;
        height: 44px;
        margin-top: 0;
        padding: 0 0 4px 0;
        border-radius: 14px;
        border-color: rgba(197, 205, 216, 0.95);
        background: rgba(255, 255, 255, 0.98);
        box-shadow: 0 14px 30px rgba(17, 19, 24, 0.12);
        font-size: 1.15rem;
        font-weight: 800;
        line-height: 1;
        backdrop-filter: blur(18px);
        transition: transform 180ms ease, box-shadow 180ms ease, border-color 180ms ease, background 180ms ease;
    }

    .admin-menu-toggle:hover,
    .admin-menu-toggle[aria-expanded="true"] {
        transform: translateY(-1px);
        border-color: rgba(10, 132, 255, 0.28);
        background: rgba(255, 255, 255, 1);
        box-shadow: 0 18px 34px rgba(10, 132, 255, 0.16);
    }

    .admin-nav {
        display: none;
        margin-top: 16px;
    }

    .admin-nav.is-open {
        display: grid;
    }

    .store-sidebar .filter-panel {
        margin-top: 14px;
    }

    .admin-toolbar-actions {
        width: 100%;
        margin-left: 0;
    }

    .results-sort-form {
        width: 100%;
        margin-left: 0;
    }

    .results-sort-form select {
        width: 100%;
        min-width: 0;
    }

    .search-compact-group {
        width: 100%;
    }

    .search-compact-group .search-input {
        min-width: 0;
        width: 100%;
    }
}

@media (max-width: 860px) {
    .store-layout .product-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    .header-bar-store {
        flex-wrap: wrap;
        align-items: center;
        gap: 12px 14px;
    }

    .header-bar-store .header-brand-group {
        flex: 1 1 auto;
        min-width: 0;
    }

    .header-bar-store .store-global-search-form {
        order: 3;
        flex: 1 1 100%;
        width: 100%;
        min-width: 0;
        margin: 0;
        top: 0;
        transform: none;
    }

    .header-bar-store .store-global-search-form .search-input,
    .header-bar-store .store-global-search-form .btn {
        top: 0;
    }

    .header-bar-store .menu-toggle {
        flex: 0 0 auto;
        margin-left: auto;
    }

    .header-nav {
        display: none;
        position: absolute;
        top: calc(100% + 12px);
        left: 16px;
        right: 16px;
        z-index: 30;
        padding: 20px;
        border-radius: 26px;
        background: rgba(255, 255, 255, 0.985);
        border: 1px solid rgba(201, 209, 220, 0.96);
        box-shadow: 0 24px 48px rgba(17, 19, 24, 0.14);
        backdrop-filter: blur(28px);
        flex-direction: column;
        align-items: stretch;
    }

    .header-nav a,
    .header-nav .nav-link-button {
        display: flex;
        align-items: center;
        justify-content: flex-start;
        width: 100%;
        min-height: 48px;
        padding: 0 6px;
        font-weight: 700;
        text-align: left;
        border-radius: var(--radius-md);
    }

    .header-nav .nav-store {
        color: #0066CC;
        background: rgba(0, 102, 204, 0.06);
        border-color: rgba(0, 102, 204, 0.10);
    }

    .header-nav .nav-store:hover,
    .header-nav .nav-store:focus-visible {
        color: #004C99;
        background: rgba(0, 102, 204, 0.10);
        border-color: rgba(0, 102, 204, 0.18);
        box-shadow: 0 4px 16px rgba(0, 102, 204, 0.08);
    }

    .header-nav .nav-branch {
        color: #8a5a2b;
        background: rgba(138, 90, 43, 0.08);
        border-color: rgba(138, 90, 43, 0.12);
    }

    .header-nav .nav-branch:hover,
    .header-nav .nav-branch:focus-visible {
        color: #70461f;
        background: rgba(138, 90, 43, 0.14);
        border-color: rgba(138, 90, 43, 0.20);
        box-shadow: 0 4px 16px rgba(138, 90, 43, 0.08);
    }

    .header-nav .nav-auth {
        color: #16a34a;
        background: rgba(22, 163, 74, 0.06);
        border-color: rgba(22, 163, 74, 0.10);
    }

    .header-nav .nav-auth:hover,
    .header-nav .nav-auth:focus-visible {
        color: #15803d;
        background: rgba(22, 163, 74, 0.10);
        border-color: rgba(22, 163, 74, 0.18);
        box-shadow: 0 4px 16px rgba(22, 163, 74, 0.08);
    }

    .header-nav .nav-admin {
        color: #ca8a04;
        background: rgba(202, 138, 4, 0.06);
        border-color: rgba(202, 138, 4, 0.10);
    }

    .header-nav .nav-admin:hover,
    .header-nav .nav-admin:focus-visible {
        color: #a16207;
        background: rgba(202, 138, 4, 0.10);
        border-color: rgba(202, 138, 4, 0.18);
        box-shadow: 0 4px 16px rgba(202, 138, 4, 0.08);
    }

    .header-nav .nav-cta-secondary {
        color: #E07000;
        background: rgba(224, 112, 0, 0.06);
        border-color: rgba(224, 112, 0, 0.10);
        text-align: left;
        justify-content: flex-start;
    }

    .header-nav .nav-cta-secondary:hover,
    .header-nav .nav-cta-secondary:focus-visible {
        color: #C06000;
        background: rgba(224, 112, 0, 0.10);
        border-color: rgba(224, 112, 0, 0.18);
        box-shadow: 0 4px 16px rgba(224, 112, 0, 0.08);
    }

    .header-nav .cart-link {
        color: var(--text);
        background: rgba(255, 255, 255, 0.82);
        border-color: var(--border);
        box-shadow: 0 4px 14px rgba(15, 23, 42, 0.05);
    }

    .header-nav .cart-link:hover,
    .header-nav .cart-link:focus-visible {
        background: rgba(255, 255, 255, 1);
        border-color: rgba(10, 132, 255, 0.22);
        box-shadow: 0 8px 20px rgba(10, 132, 255, 0.08);
    }

    .header-brand-group .header-branch-link,
    .header-brand-group .header-store-link {
        display: none;
    }

    .header-nav .nav-primary-link {
        display: flex;
    }

    .header-nav .nav-logout-form {
        display: flex;
        width: 100%;
    }

    .header-nav .nav-logout-form .nav-link-button {
        width: 100%;
    }

    .header-nav.is-open {
        display: flex;
    }

    .menu-toggle {
        display: inline-flex;
        align-items: center;
        justify-content: center;
        width: 50px;
        height: 50px;
        padding: 0 0 4px 0;
        border-radius: 16px;
        border-color: rgba(197, 205, 216, 0.95);
        background: rgba(255, 255, 255, 0.98);
        box-shadow: 0 14px 30px rgba(17, 19, 24, 0.12);
        font-size: 1.15rem;
        font-weight: 800;
        line-height: 1;
        backdrop-filter: blur(18px);
        transition: transform 180ms ease, box-shadow 180ms ease, border-color 180ms ease, background 180ms ease;
    }

    .menu-toggle:hover,
    .menu-toggle[aria-expanded="true"] {
        transform: translateY(-1px);
        border-color: rgba(10, 132, 255, 0.28);
        background: rgba(255, 255, 255, 1);
        box-shadow: 0 18px 34px rgba(10, 132, 255, 0.16);
    }

    .store-tabs {
        gap: 12px;
        padding: 14px 0 24px;
    }

    .store-tabs-toolbar {
        display: grid;
        gap: 12px;
    }

    .store-global-search-form {
        width: 100%;
        margin-left: 0;
        transform: translateY(-14px);
    }

    .store-tab {
        min-height: 42px;
        padding: 0 16px;
        font-size: 0.8rem;
        font-weight: 800;
        box-shadow: 0 10px 24px rgba(17, 19, 24, 0.07);
    }


    .top-strip-inner {
        flex-direction: column;
    }

    .cart-item {
        grid-template-columns: 1fr;
    }
}

@media (max-width: 640px) {
    .orders-detail-head {
        top: -18px;
        margin: -18px -18px 18px;
        padding: 18px;
    }

    :root {
        --wrapper: calc(100vw - 20px);
    }

    .filter-panel,
    .checkout-panel,
    .summary-card,
    .account-section,
    .admin-table-wrap,
    .product-copy,
    .product-gallery,
    .auth-card,
    .auth-hero,
    .legal-card,
    .metric,
    .product-card {
        padding: 18px;
    }

    .admin-main {
        padding: 10px 18px 14px;
    }

    .admin-topbar {
        flex-direction: row;
        align-items: flex-start;
        margin-bottom: 10px;
    }

    .admin-topbar .eyebrow {
        margin-bottom: 4px;
    }

    .admin-topbar-meta {
        align-self: flex-start;
        justify-items: end;
        margin-left: auto;
        margin-top: 10px;
    }

    .store-tabs {
        display: grid;
        grid-template-columns: repeat(4, minmax(0, 1fr));
    }

    .store-tab {
        min-width: 0;
        min-height: 46px;
        padding: 6px 8px;
        font-size: 0.8rem;
        font-weight: 750;
        line-height: 1.15;
        white-space: normal;
        text-align: center;
        box-shadow: 0 8px 20px rgba(17, 19, 24, 0.06);
    }

    .store-tab::after {
        display: none;
    }

    .store-tab.active {
        background:
            radial-gradient(circle at 50% 50%, rgba(255, 255, 255, 0.98) 0%, rgba(248, 251, 255, 0.96) 42%, rgba(182, 218, 255, 0.4) 100%),
            linear-gradient(135deg, rgba(106, 177, 255, 0.22), rgba(255, 255, 255, 0.12) 46%, rgba(118, 184, 255, 0.2));
        border-color: rgba(10, 132, 255, 0.24);
        color: #133d63;
        box-shadow:
            inset 0 0 0 1px rgba(255, 255, 255, 0.44),
            0 0 0 1px rgba(10, 132, 255, 0.1),
            0 12px 24px rgba(10, 132, 255, 0.14);
        backdrop-filter: blur(14px);
    }
}

.cookie-banner {
    position: fixed;
    bottom: 0;
    left: 0;
    right: 0;
    z-index: 200;
    padding: 16px;
    animation: cookie-slide-up 400ms ease both;
}

@keyframes cookie-slide-up {
    from { transform: translateY(100%); opacity: 0; }
    to { transform: translateY(0); opacity: 1; }
}

@keyframes cookie-slide-down {
    from { transform: translateY(0); opacity: 1; }
    to { transform: translateY(100%); opacity: 0; }
}

.cookie-banner-inner {
    max-width: 680px;
    margin: 0 auto;
    display: flex;
    align-items: center;
    gap: 20px;
    padding: 18px 24px;
    border-radius: var(--radius-xl);
    border: 1px solid rgba(15, 23, 42, 0.08);
    background: rgba(214, 226, 240, 0.9);
    backdrop-filter: blur(24px);
    box-shadow: 0 16px 40px rgba(17, 19, 24, 0.12);
}

.cookie-banner-text {
    margin: 0;
    font-size: 0.88rem;
    line-height: 1.5;
    color: var(--muted);
}

.cookie-banner-text a {
    color: var(--accent);
    font-weight: 600;
    text-decoration: underline;
    text-underline-offset: 2px;
}

.cookie-banner-actions {
    display: flex;
    gap: 10px;
    flex-shrink: 0;
}

.cookie-btn {
    padding: 10px 20px;
    border-radius: var(--radius-md);
    border: 1px solid transparent;
    font-weight: 700;
    font-size: 0.88rem;
    cursor: pointer;
    backdrop-filter: blur(8px);
    transition: transform 180ms ease, box-shadow 180ms ease, background 180ms ease;
}

.cookie-btn:hover {
    transform: translateY(-1px);
}

.cookie-btn-accept {
    color: #12825d;
    background: rgba(18, 130, 93, 0.08);
    border-color: rgba(18, 130, 93, 0.14);
}

.cookie-btn-accept:hover {
    background: rgba(18, 130, 93, 0.14);
    border-color: rgba(18, 130, 93, 0.22);
    box-shadow: 0 8px 20px rgba(18, 130, 93, 0.10);
}

.cookie-btn-reject {
    color: var(--danger);
    background: rgba(180, 35, 24, 0.06);
    border-color: rgba(180, 35, 24, 0.10);
}

.cookie-btn-reject:hover {
    background: rgba(180, 35, 24, 0.12);
    border-color: rgba(180, 35, 24, 0.18);
    box-shadow: 0 8px 20px rgba(180, 35, 24, 0.08);
}

@media (max-width: 640px) {
    .cookie-banner-inner {
        flex-direction: column;
        text-align: center;
        padding: 18px;
    }

    .cookie-banner-actions {
        width: 100%;
    }

    .cookie-btn {
        flex: 1;
    }
}

.cookie-prefs-section {
    margin-top: 12px;
    padding: 24px;
    border-radius: var(--radius-lg);
    background: rgba(255, 255, 255, 0.6);
    border: 1px solid var(--border);
    backdrop-filter: blur(12px);
}

.cookie-prefs-actions {
    display: flex;
    gap: 10px;
    margin-top: 14px;
}

#cookie-pref-status {
    font-size: 0.92rem;
    color: var(--muted);
}

.field-image-upload-mobile {
    display: none;
    margin-top: 12px;
}

@media (max-width: 768px) {
    .field-image-upload-mobile {
        display: block;
    }
}

/* Refine results sort dropdown: thinner height */

.results-sort-form select {
    min-height: 28px;
    height: 28px;
    padding: 0 36px 0 16px;
    border-radius: 999px;
    font-size: 13px;
    line-height: 28px;
}

/* Desktop refinement: keep store header on one line with a visually centered search */
@media (min-width: 980px) {
    .header-bar-store {
        --store-header-center-span: 31rem;
        display: grid;
        grid-template-columns: minmax(0, 1fr) var(--store-header-center-span) minmax(0, 1fr);
        align-items: center;
        gap: 6px;
        padding-top: 18px;
        padding-bottom: 6px;
        min-height: 0;
    }

    .header-bar-store .header-brand-group {
        grid-column: 1;
        justify-self: start;
        min-width: 0;
    }

    .header-bar-store .brand img {
        height: 54px;
        max-width: 230px;
    }

    .header-bar-store .brand-mark {
        width: 54px;
        height: 54px;
        border-radius: 18px;
    }

    .header-bar-store .brand-text {
        font-size: 1.22rem;
    }

    .header-bar-store .header-branch-link,
    .header-bar-store .header-store-link,
    .header-bar-store .header-nav > a:not(.nav-primary-link),
    .header-bar-store .header-nav .nav-link-button {
        display: inline-flex;
        align-items: center;
        justify-content: center;
        min-height: 40px;
    }

    .header-bar-store .header-branch-link,
    .header-bar-store .header-store-link {
        flex: 0 0 auto;
    }

    .store-tabs-toolbar {
        display: flex;
        flex-direction: column;
        align-items: center;
        gap: 6px;
        width: 100%;
    }

    .store-tabs-toolbar .store-tabs {
        top: 0;
        width: 100%;
        justify-content: center;
        margin: 0 auto;
        padding-top: 0;
        padding-bottom: 10px;
    }

    .header-bar-store .header-nav {
        grid-column: 3;
        justify-self: end;
    }

    .header-bar-store .store-global-search-form {
        grid-column: 2;
        justify-self: center;
        position: static;
        width: 100%;
        min-width: 0;
        margin: 0;
        flex: none;
    }

    .header-bar-store .store-global-search-form .search-input {
        top: 0;
        height: 40px;
        min-height: 40px;
        padding: 0 14px;
        border-radius: 14px 0 0 14px;
        font-size: 0.88rem;
    }

    .header-bar-store .store-global-search-form .btn {
        top: 0;
        height: 40px;
        min-height: 40px;
        padding: 0 14px;
        border-radius: 0 14px 14px 0;
    }
}

.store-global-search-form .search-input {
    font-size: 0.88rem;
}

@media (max-width: 1170px) {
    .store-tabs-toolbar {
        display: flex;
        flex-direction: column;
        align-items: center;
        gap: 10px;
    }

    .store-tabs {
        top: 0;
        width: 100%;
        justify-content: center;
        flex-wrap: wrap;
        gap: 10px;
        padding: 4px 0 16px;
        overflow: visible;
    }
}

@media (min-width: 861px) and (max-width: 1170px) {
    .header-bar-store {
        display: flex;
        flex-wrap: wrap;
        align-items: center;
        justify-content: space-between;
        gap: 10px 16px;
        padding-bottom: 10px;
    }

    .header-bar-store .header-brand-group {
        order: 1;
        flex: 1 1 auto;
        min-width: 0;
    }

    .header-bar-store .header-branch-link,
    .header-bar-store .header-store-link,
    .header-bar-store .header-nav > a:not(.nav-primary-link),
    .header-bar-store .header-nav .nav-link-button {
        display: inline-flex;
        align-items: center;
        justify-content: center;
        min-height: 40px;
    }

    .header-bar-store .header-nav {
        order: 2;
        flex: 0 0 auto;
        min-width: 0;
        margin-left: auto;
    }

    .header-bar-store .store-global-search-form {
        order: 3;
        flex: 1 1 100%;
        width: 100%;
        min-width: 0;
        margin: 0;
        top: 0;
        transform: none;
    }

    .header-bar-store .store-global-search-form .search-input,
    .header-bar-store .store-global-search-form .btn {
        top: 0;
    }

    .header-bar-store .store-global-search-form .search-input {
        height: 40px;
        min-height: 40px;
        padding: 0 14px;
        border-radius: 14px 0 0 14px;
    }

    .header-bar-store .store-global-search-form .btn {
        height: 40px;
        min-height: 40px;
        padding: 0 14px;
        border-radius: 0 14px 14px 0;
    }
}

.store-sidebar .field label,
.store-sidebar .field .label {
    font-size: 0.84rem;
}

.store-sidebar .field select,
.store-sidebar .field input,
.store-sidebar .field textarea {
    font-size: 0.88rem;
    padding: 9px 14px;
}
