.hero {
    display: grid;
    gap: 32px;
}

.hero-card {
    padding: 28px;
    display: grid;
    gap: 20px;
}

.hero-media {
    background: linear-gradient(135deg, rgba(15, 118, 110, 0.25), rgba(17, 94, 89, 0.1));
    border-radius: var(--radius);
    min-height: 220px;
    display: grid;
    place-items: center;
    font-weight: 600;
    color: var(--accent);
    overflow: hidden;
}

.hero-media img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.product-grid {
    display: grid;
    gap: 24px;
}

.product-card {
    padding: 20px;
    display: grid;
    gap: 18px;
    transition: transform 0.2s ease, box-shadow 0.2s ease;
    height: 100%;
}

.product-card:hover {
    transform: translateY(-4px);
    box-shadow: 0 20px 40px rgba(16, 24, 40, 0.12);
}

.product-media {
    height: 160px;
    border-radius: var(--radius-sm);
    background: linear-gradient(135deg, #f1f5f9, #e2e8f0);
    display: grid;
    place-items: center;
    color: var(--muted);
    font-weight: 600;
    overflow: hidden;
}

.product-media img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.product-meta {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    gap: 10px;
    margin-top: auto;
}

.product-price {
    font-weight: 600;
}

.product-card .stack {
    display: flex;
    flex-direction: column;
    gap: 12px;
    height: 100%;
}

.product-meta .chip-row {
    width: 100%;
    justify-content: flex-start;
}


.cart-overlay {
    position: fixed;
    inset: 0;
    background: rgba(15, 23, 42, 0.4);
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.2s ease;
    z-index: 30;
}

.cart-drawer {
    position: fixed;
    top: 0;
    right: 0;
    width: min(100%, 420px);
    height: 100%;
    background: #ffffff;
    border-left: 1px solid rgba(28, 31, 36, 0.08);
    box-shadow: -18px 0 36px rgba(15, 23, 42, 0.12);
    transform: translateX(110%);
    transition: transform 0.25s ease;
    z-index: 40;
    display: grid;
    grid-template-rows: auto 1fr auto;
    gap: 18px;
    padding: 22px;
}

.cart-drawer.is-open {
    transform: translateX(0);
}

.cart-overlay.is-open {
    opacity: 1;
    pointer-events: auto;
}

.cart-header {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    border-bottom: 1px solid rgba(28, 31, 36, 0.08);
    padding-bottom: 12px;
}

.cart-items {
    display: flex;
    flex-direction: column;
    gap: 12px;
    align-content: flex-start;
    overflow-y: auto;
    scrollbar-width: none; /* Firefox */
    -ms-overflow-style: none; /* IE and Edge */
}

.cart-items::-webkit-scrollbar {
    display: none; /* Chrome, Safari and Opera */
}

.cart-item {
    display: grid;
    grid-template-columns: 64px 1fr;
    gap: 16px;
    padding: 16px 0;
    border-bottom: 1px solid rgba(28, 31, 36, 0.08);
    background: transparent;
    align-items: center;
}

.cart-item-image {
    width: 64px;
    height: 64px;
    object-fit: cover;
    border-radius: var(--radius-sm);
    background: var(--surface-alt);
}

.cart-item-image-placeholder {
    width: 64px;
    height: 64px;
    border-radius: var(--radius-sm);
    background: var(--surface-alt);
}

.cart-item-details {
    display: grid;
    gap: 8px;
}

.cart-item-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 10px;
}

.cart-item-row strong {
    font-weight: 600;
}

.quantity {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    border: 1px solid rgba(28, 31, 36, 0.12);
    border-radius: 999px;
    padding: 4px 8px;
    background: var(--surface);
}

.quantity button {
    border: none;
    background: none;
    font-size: 16px;
    cursor: pointer;
    padding: 0 4px;
}

.cart-footer {
    display: grid;
    gap: 12px;
    border-top: 1px solid rgba(28, 31, 36, 0.08);
    padding-top: 12px;
}

.cart-total {
    display: flex;
    justify-content: space-between;
    align-items: center;
    font-size: 18px;
}

.icon-button {
    width: 36px;
    height: 36px;
    border-radius: 50%;
    border: 1px solid var(--border);
    background: var(--surface-alt);
    display: grid;
    place-items: center;
    cursor: pointer;
}

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

.modal {
    position: fixed;
    inset: 0;
    display: grid;
    place-items: center;
    background: rgba(15, 23, 42, 0.4);
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.2s ease;
    z-index: 50;
}

.modal.is-open {
    opacity: 1;
    pointer-events: auto;
}

.modal-card {
    width: min(92%, 680px);
    background: var(--surface);
    border-radius: var(--radius);
    box-shadow: var(--shadow);
    display: grid;
    gap: 20px;
    padding: 28px;
    position: relative;
}

.modal-media {
    height: 200px;
    border-radius: var(--radius-sm);
    background: linear-gradient(135deg, #ede9fe, #e0f2fe);
}

.modal-close {
    position: absolute;
    top: 18px;
    right: 18px;
}

.form-grid {
    display: grid;
    gap: 16px;
}

.form-field {
    display: grid;
    gap: 8px;
    font-size: 14px;
}

.form-field input,
.form-field select,
.form-field textarea {
    padding: 12px 14px;
    border-radius: 12px;
    border: 1px solid var(--border);
    font-family: "Poppins", sans-serif;
}

.chip-row {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
}

.chip {
    padding: 8px 14px;
    border-radius: 999px;
    border: 1px solid var(--border);
    background: var(--surface);
    font-size: 13px;
}

@media (min-width: 900px) {
    .hero {
        grid-template-columns: 1.1fr 0.9fr;
        align-items: center;
    }

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