:root {
    --store-primary: #0f766e;
    --store-accent: #d97706;
    --store-ink: #172026;
    --store-muted: #667085;
    --store-line: #e5e7eb;
    --store-bg: #f7f8fa;
}

* { box-sizing: border-box; }
body {
    margin: 0;
    font-family: "Tahoma", "Arial", sans-serif;
    color: var(--store-ink);
    background: var(--store-bg);
}

.store-nav {
    position: sticky;
    top: 0;
    z-index: 10;
    height: 64px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 0 28px;
    background: #fff;
    border-bottom: 1px solid var(--store-line);
}
.store-brand {
    color: var(--store-primary);
    text-decoration: none;
    font-weight: 800;
    font-size: 20px;
    display: inline-flex;
    align-items: center;
    gap: 10px;
}
.store-brand img {
    width: 38px;
    height: 38px;
    border-radius: 8px;
    object-fit: cover;
    border: 1px solid var(--store-line);
    background: #fff;
}
.store-nav-actions { display: flex; gap: 12px; align-items: center; }
.store-icon-link,
.store-cart-link {
    width: 42px;
    height: 42px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    color: var(--store-ink);
    background: #f3f4f6;
    border-radius: 8px;
    text-decoration: none;
    position: relative;
}
.store-cart-link span {
    position: absolute;
    top: -6px;
    left: -6px;
    min-width: 22px;
    height: 22px;
    padding: 0 6px;
    border-radius: 999px;
    background: var(--store-accent);
    color: #fff;
    font-size: 12px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
}

.store-hero {
    min-height: 460px;
    display: grid;
    align-items: end;
    padding: 0;
    background:
        linear-gradient(135deg, rgba(15, 118, 110, .12), rgba(217, 119, 6, .10)),
        #fff;
    border-bottom: 1px solid var(--store-line);
    position: relative;
    overflow: hidden;
}
.hero-content {
    position: relative;
    z-index: 2;
    width: 100%;
    display: flex;
    align-items: end;
    justify-content: space-between;
    gap: 24px;
    padding: 44px 5vw;
    background: linear-gradient(180deg, rgba(255,255,255,.18), rgba(255,255,255,.92));
}
.hero-copy { max-width: 680px; }
.hero-kicker {
    display: inline-flex;
    align-items: center;
    min-height: 30px;
    padding: 0 12px;
    border-radius: 999px;
    color: var(--store-primary);
    background: rgba(15, 118, 110, .10);
    font-size: 13px;
    font-weight: 700;
    margin-bottom: 12px;
}
.store-hero h1 { margin: 0 0 10px; font-size: 38px; }
.store-hero p { margin: 0; color: var(--store-muted); max-width: 680px; }
.hero-actions { display: flex; flex-wrap: wrap; gap: 10px; margin-top: 22px; }
.store-search {
    width: min(440px, 100%);
    display: grid;
    grid-template-columns: 1fr 48px;
    border: 1px solid var(--store-line);
    background: #fff;
    border-radius: 8px;
    overflow: hidden;
    box-shadow: 0 18px 42px rgba(16, 24, 40, .08);
}
.store-search input,
.store-search button {
    border: 0;
    min-height: 48px;
    background: transparent;
}
.store-search input { padding: 0 14px; outline: 0; }
.store-search button { color: var(--store-primary); }
.hero-visual {
    position: absolute;
    inset: 0;
    width: 100%;
    overflow: hidden;
    background: #eef2f4;
}
.hero-visual img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
}
.hero-visual::after {
    content: "";
    position: absolute;
    inset: 0;
    background: linear-gradient(90deg, rgba(255,255,255,.88), rgba(255,255,255,.38), rgba(255,255,255,.86));
}
.hero-slide-caption {
    position: absolute;
    right: 5vw;
    bottom: 150px;
    z-index: 1;
    display: grid;
    gap: 4px;
    max-width: 420px;
}
.hero-slide-caption strong { font-size: 28px; color: var(--store-primary); }
.hero-slide-caption span { color: #475467; }

.store-metrics {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 1px;
    margin: 0 5vw;
    transform: translateY(-22px);
    background: var(--store-line);
    border: 1px solid var(--store-line);
    border-radius: 8px;
    overflow: hidden;
    box-shadow: 0 12px 28px rgba(16, 24, 40, .08);
}
.store-metrics div {
    background: #fff;
    padding: 18px 20px;
    display: grid;
    gap: 4px;
}
.store-metrics strong { font-size: 26px; color: var(--store-primary); line-height: 1; }
.store-metrics span { color: var(--store-muted); font-size: 13px; }

.store-layout {
    display: grid;
    grid-template-columns: 260px 1fr;
    gap: 22px;
    padding: 8px 5vw 54px;
}
.store-filter,
.cart-summary,
.account-panel,
.checkout-form {
    background: #fff;
    border: 1px solid var(--store-line);
    border-radius: 8px;
}
.store-filter { padding: 18px; align-self: start; }
.store-filter h2,
.store-section-head h2,
.store-page h1 { font-size: 22px; margin: 0 0 16px; }
.category-button {
    width: 100%;
    display: flex;
    justify-content: space-between;
    align-items: center;
    border: 0;
    border-bottom: 1px solid #f1f3f5;
    background: transparent;
    padding: 12px 0;
    text-align: right;
    color: var(--store-ink);
}
.category-button.active { color: var(--store-primary); font-weight: 700; }

.store-section-head {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 16px;
}
.store-section-head span { color: var(--store-muted); font-size: 13px; }
.view-tools { display: flex; gap: 8px; }
.tool-button {
    width: 38px;
    height: 38px;
    border: 1px solid var(--store-line);
    border-radius: 8px;
    background: #fff;
    color: var(--store-muted);
}
.tool-button.active {
    color: #fff;
    background: var(--store-primary);
    border-color: var(--store-primary);
}
.product-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(220px, 1fr));
    gap: 16px;
}
.product-grid.product-list { grid-template-columns: 1fr; }
.product-grid.product-list .product-card {
    min-height: 0;
    display: grid;
    grid-template-columns: 180px 1fr;
}
.product-grid.product-list .product-image-link img { height: 100%; aspect-ratio: auto; }
.product-card {
    background: #fff;
    border: 1px solid var(--store-line);
    border-radius: 8px;
    overflow: hidden;
    min-height: 345px;
    display: flex;
    flex-direction: column;
    transition: transform .18s ease, box-shadow .18s ease, border-color .18s ease;
}
.product-card:hover {
    transform: translateY(-3px);
    box-shadow: 0 16px 34px rgba(16, 24, 40, .10);
    border-color: rgba(15, 118, 110, .24);
}
.product-image-link {
    position: relative;
    display: block;
    color: inherit;
    text-decoration: none;
}
.product-card img {
    width: 100%;
    aspect-ratio: 4 / 3;
    object-fit: cover;
    background: #eef2f4;
}
.product-badge {
    position: absolute;
    top: 10px;
    right: 10px;
    border-radius: 999px;
    background: var(--store-accent);
    color: #fff;
    padding: 5px 10px;
    font-size: 12px;
    font-weight: 700;
}
.product-card-body { padding: 14px; display: flex; flex-direction: column; gap: 8px; flex: 1; }
.product-category {
    color: var(--store-primary);
    font-size: 12px;
    font-weight: 700;
}
.product-card h3 { font-size: 16px; margin: 0; line-height: 1.5; }
.product-card p { margin: 0; color: var(--store-muted); font-size: 13px; min-height: 38px; }
.price { font-weight: 800; color: var(--store-primary); }
.price del, .product-price del { color: #7b8490; font-size: .78em; font-weight: 500; margin-inline-start: 8px; }
.card-actions { margin-top: auto; display: grid; grid-template-columns: 1fr 42px; gap: 8px; }
.store-skeleton {
    height: 345px;
    border-radius: 8px;
    background: linear-gradient(90deg, #eef2f4, #f8fafc, #eef2f4);
    background-size: 200% 100%;
    animation: shimmer 1.2s infinite;
}
@keyframes shimmer {
    from { background-position: 200% 0; }
    to { background-position: -200% 0; }
}

.primary-action,
.secondary-action {
    min-height: 42px;
    border: 0;
    border-radius: 8px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    text-decoration: none;
    padding: 0 14px;
}
.primary-action { background: var(--store-primary); color: #fff; }
.primary-action:disabled { opacity: .65; cursor: wait; }
.secondary-action { background: #eef2f4; color: var(--store-ink); }
.text-link,
.back-link { color: var(--store-primary); text-decoration: none; }

.product-detail {
    display: grid;
    grid-template-columns: minmax(280px, 560px) 1fr;
    gap: 32px;
    padding: 32px 5vw 58px;
}
.product-media,
.product-info {
    background: #fff;
    border: 1px solid var(--store-line);
    border-radius: 8px;
    padding: 18px;
}
.product-media img {
    width: 100%;
    aspect-ratio: 1 / 1;
    object-fit: cover;
    border-radius: 8px;
    background: #eef2f4;
}
.product-gallery { display: flex; gap: 8px; margin-top: 12px; overflow-x: auto; }
.product-gallery img {
    width: 72px;
    height: 72px;
    cursor: pointer;
}
.product-info h1 { margin: 14px 0 8px; font-size: 30px; }
.product-code,
.product-description { color: var(--store-muted); }
.product-price { font-size: 26px; font-weight: 800; color: var(--store-primary); margin: 18px 0; }
.product-price small { display: block; color: #18864b; font-size: 13px; font-weight: 600; margin-top: 4px; }
.variant-box,
.qty-row { display: grid; gap: 8px; margin-bottom: 14px; }
select,
input,
textarea {
    border: 1px solid var(--store-line);
    border-radius: 8px;
    min-height: 44px;
    padding: 10px 12px;
}
textarea { min-height: 110px; resize: vertical; }

.store-page { padding: 28px 5vw 56px; }
.cart-shell,
.checkout-layout,
.account-layout {
    display: grid;
    grid-template-columns: 1fr 340px;
    gap: 20px;
    align-items: start;
}
.cart-line {
    display: grid;
    grid-template-columns: 82px 1fr 120px 110px 42px;
    gap: 12px;
    align-items: center;
    background: #fff;
    border: 1px solid var(--store-line);
    border-radius: 8px;
    padding: 12px;
    margin-bottom: 10px;
}
.cart-line img { width: 82px; height: 82px; object-fit: cover; border-radius: 8px; background: #eef2f4; }
.cart-line h3 { font-size: 16px; margin: 0 0 6px; }
.cart-line span { color: var(--store-muted); font-size: 13px; }
.cart-summary { padding: 18px; display: grid; gap: 14px; }
.cart-summary strong { font-size: 24px; color: var(--store-primary); }

.checkout-form { padding: 20px; display: grid; gap: 14px; }
.form-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
.payment-options { display: grid; gap: 8px; }
.payment-option {
    display: flex;
    align-items: center;
    gap: 10px;
    border: 1px solid var(--store-line);
    border-radius: 8px;
    padding: 12px;
}
.form-message { margin: 0; color: var(--store-primary); }
.form-message.is-error { color: #b42318; font-weight: 700; }
.account-panel { padding: 20px; }
.order-row {
    border: 1px solid var(--store-line);
    border-radius: 8px;
    padding: 12px;
    margin-bottom: 10px;
}
.order-detail-grid {
    display: grid;
    grid-template-columns: 1fr 340px;
    gap: 20px;
    align-items: start;
}
.order-line-row {
    display: grid;
    grid-template-columns: 1fr 80px 130px;
    gap: 12px;
    align-items: center;
    padding: 12px 0;
    border-bottom: 1px solid #edf0f3;
}
.order-line-row:last-child { border-bottom: 0; }
.order-line-row div { display: grid; gap: 3px; }
.order-line-row span { color: #667085; }
.order-line-row b { color: var(--store-primary); }

.store-admin-head {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
    margin-bottom: 18px;
    padding: 18px;
    border: 1px solid #dbe3ea;
    border-radius: 8px;
    background: #fff;
}
.store-admin-head h1 {
    margin: 0;
    font-size: 26px;
}
.store-admin-tabs {
    display: flex;
    gap: 8px;
    overflow-x: auto;
    margin-bottom: 16px;
    padding: 6px;
    border: 1px solid #dbe3ea;
    border-radius: 8px;
    background: #fff;
}
.store-admin-tabs button {
    min-height: 40px;
    border: 0;
    border-radius: 8px;
    padding: 0 14px;
    background: transparent;
    color: #475467;
    display: inline-flex;
    align-items: center;
    gap: 8px;
    white-space: nowrap;
}
.store-admin-tabs button.active {
    background: var(--store-primary);
    color: #fff;
}
.store-stat-card {
    border: 1px solid #dbe3ea;
    border-radius: 8px;
}
.store-stat-card .h3 { color: var(--store-primary); }
.top-product-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 12px;
    padding: 12px 0;
    border-bottom: 1px solid #edf0f3;
}
.top-product-row:last-child { border-bottom: 0; }
.top-product-row div { display: grid; gap: 3px; }
.top-product-row span { color: #667085; font-size: 12px; }
.top-product-row b { color: var(--store-primary); white-space: nowrap; }
.settings-summary-row,
.report-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 12px;
    padding: 11px 0;
    border-bottom: 1px solid #edf0f3;
}
.settings-summary-row:last-child,
.report-row:last-child { border-bottom: 0; }
.settings-summary-row span,
.report-row span { color: #667085; }
.report-row small { color: #98a2b3; }
.store-settings-form label {
    display: block;
    margin-bottom: 6px;
    color: #344054;
    font-size: 13px;
    font-weight: 700;
}
.settings-switches {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(210px, 1fr));
    gap: 10px;
    margin-top: 18px;
}
.settings-switches label {
    min-height: 44px;
    display: flex;
    align-items: center;
    gap: 9px;
    border: 1px solid #edf0f3;
    border-radius: 8px;
    padding: 8px 10px;
    margin: 0;
    background: #fbfcfd;
}
.hero-slide-list {
    display: grid;
    gap: 10px;
    margin-top: 14px;
}
.hero-slide-admin {
    display: grid;
    grid-template-columns: 96px 1fr auto;
    gap: 12px;
    align-items: center;
    padding: 10px;
    border: 1px solid #edf0f3;
    border-radius: 8px;
    background: #fbfcfd;
}
.hero-slide-admin img {
    width: 96px;
    height: 58px;
    object-fit: cover;
    border-radius: 6px;
}
.hero-slide-admin div { display: grid; gap: 4px; }
.hero-slide-admin span { color: #667085; font-size: 13px; }

@media (max-width: 900px) {
    .store-hero,
    .store-layout,
    .product-detail,
    .cart-shell,
    .checkout-layout,
    .account-layout {
        grid-template-columns: 1fr;
    }
    .store-hero { min-height: 520px; }
    .hero-content { display: grid; padding: 34px 5vw; }
    .store-metrics { grid-template-columns: 1fr; transform: none; margin-top: 14px; }
    .product-grid.product-list .product-card { grid-template-columns: 1fr; }
    .cart-line { grid-template-columns: 72px 1fr; }
    .cart-line input,
    .cart-line .price,
    .cart-line button { grid-column: 2; }
    .form-grid { grid-template-columns: 1fr; }
    .store-admin-head { display: grid; }
    .order-detail-grid { grid-template-columns: 1fr; }
    .order-line-row { grid-template-columns: 1fr; }
}
