body {
    background-color: #f0e68c;
    font-family: 'Courier New', Courier, monospace;
    color: #333;
    text-align: center;
    margin: 0px;
}

h1 {
    font-size: 3em;
    margin-bottom: 20px;
    text-shadow: 1px 1px 0 rgba(0, 0, 0, 0.15);
}

h2 {
    text-shadow: 1px 1px 0 rgba(0, 0, 0, 0.1);
}

.container {
    min-width: 500px;
    margin: 0 auto;
    padding-top: 20px;
}

.flex-items{
    max-width: 1400px;
    margin: 0 auto;
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
}

.item {
    width: 20%;
    margin: 8px;
    padding: 8px;
    border: 2px ridge #999;
    border-radius: 3px;
    background-color: #fff;
    box-shadow: 2px 2px 6px rgba(0, 0, 0, 0.4);
    text-wrap: no-wrap;
}

.item img {
    width: 100%;
    height: auto;
    border-radius: 3px;
}

.button {
    display: inline-block;
    margin-top: 10px;
    padding: 10px 20px;
    font-size: 1.2em;
    color: #fff;
    background-color: #007bff;
    border: 2px outset #4a9eff;
    border-radius: 2px;
    text-decoration: none;
    cursor: pointer;
    font-family: 'Courier New', Courier, monospace;
}

.button:hover {
    background-color: #0056b3;
}

.button:active {
    border-style: inset;
}

.button-secondary {
    background-color: #666;
    border-color: #999;
}

.button-secondary:hover {
    background-color: #444;
}

footer{
    padding: 20px 0px;
    border-top: 2px groove #ccc;
    margin-top: 30px;
}

/* Cart header */
.cart-header {
    margin-bottom: 20px;
}

/* Cart sidebar */
.cart-sidebar {
    position: fixed;
    top: 0;
    right: 0;
    width: 350px;
    height: 100%;
    background-color: #fff;
    border-left: 3px ridge #999;
    box-shadow: -4px 0 15px rgba(0, 0, 0, 0.3);
    z-index: 1000;
    overflow-y: auto;
}

.cart-sidebar.hidden {
    display: none;
}

.cart-sidebar-content {
    padding: 20px;
    text-align: left;
}

.cart-sidebar-content h2 {
    text-align: center;
    margin-bottom: 15px;
}

.cart-item {
    display: flex;
    gap: 10px;
    align-items: flex-start;
    padding: 10px 0;
    border-bottom: 1px solid #ccc;
    font-size: 0.85em;
}

.cart-item-thumb {
    width: 45px;
    height: 45px;
    object-fit: cover;
    border-radius: 5px;
    border: 1px solid #ddd;
    flex-shrink: 0;
}

.cart-item-info {
    flex: 1;
    min-width: 0;
    display: flex;
    flex-direction: column;
    gap: 3px;
}

.cart-item-name {
    font-weight: bold;
    font-size: 0.95em;
}

.cart-item-options {
    font-size: 0.85em;
    color: #666;
}

.cart-item-bottom {
    display: flex;
    align-items: center;
    gap: 8px;
    margin-top: 4px;
}

.cart-item-price {
    font-weight: bold;
    white-space: nowrap;
    flex-shrink: 0;
    align-self: center;
}

.cart-qty-controls {
    display: flex;
    align-items: center;
    gap: 4px;
}

.cart-qty-btn {
    width: 24px;
    height: 24px;
    font-size: 0.9em;
    font-weight: bold;
    border: 2px outset #ddd;
    border-radius: 1px;
    background: #c0c0c0;
    cursor: pointer;
    font-family: 'Courier New', Courier, monospace;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 0;
}

.cart-qty-btn:hover {
    background: #d0d0d0;
}

.cart-qty-btn:active {
    border-style: inset;
}

.cart-qty-value {
    min-width: 20px;
    text-align: center;
    font-weight: bold;
    font-size: 0.9em;
}

.cart-total {
    font-size: 1.2em;
    font-weight: bold;
    margin: 15px 0;
    text-align: center;
}

.remove-btn {
    background: #c0392b;
    color: #fff;
    border: 2px outset #e05545;
    padding: 3px 8px;
    border-radius: 1px;
    cursor: pointer;
    font-family: 'Courier New', Courier, monospace;
    font-size: 0.75em;
}

.remove-btn:hover {
    background: #922b21;
}

.remove-btn:active {
    border-style: inset;
}

/* Checkout item bottom row */
.checkout-item-bottom {
    display: flex;
    align-items: center;
    gap: 8px;
    margin-top: 4px;
}

/* Stock info */
.stock-info {
    color: #27ae60;
    font-size: 0.85em;
}

.out-of-stock {
    color: #c0392b;
    font-weight: bold;
}

/* Add to cart button */
.add-to-cart-btn {
    display: inline-block;
    margin-top: 8px;
    padding: 8px 16px;
    font-size: 1em;
    color: #fff;
    background-color: #007bff;
    border: 2px outset #4a9eff;
    border-radius: 2px;
    cursor: pointer;
    font-family: 'Courier New', Courier, monospace;
}

.add-to-cart-btn:hover {
    background-color: #0056b3;
}

.add-to-cart-btn:active {
    border-style: inset;
}

/* Shipping form */
.shipping-form {
    max-width: 450px;
    margin: 30px auto;
    text-align: left;
}

.shipping-form input {
    width: 100%;
    padding: 10px;
    margin-bottom: 10px;
    border: 2px solid #333;
    border-radius: 5px;
    font-family: 'Courier New', Courier, monospace;
    font-size: 1em;
    box-sizing: border-box;
}

.shipping-form button {
    width: 100%;
    margin-top: 10px;
}

/* Checkout layout */
.checkout-layout {
    display: flex;
    gap: 30px;
    max-width: 900px;
    margin: 0 auto;
    text-align: left;
    align-items: flex-start;
}

.checkout-main {
    flex: 1;
    min-width: 0;
}

.checkout-main h2 {
    margin-bottom: 15px;
}

.checkout-main form input,
.checkout-main form select {
    width: 100%;
    padding: 10px;
    margin-bottom: 10px;
    border: 2px inset #ccc;
    border-radius: 1px;
    font-family: 'Courier New', Courier, monospace;
    font-size: 1em;
    box-sizing: border-box;
}

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

.shipping-row input,
.shipping-row select {
    flex: 1;
}

.checkout-sidebar {
    width: 340px;
    flex-shrink: 0;
    background: #fff;
    border: 2px ridge #999;
    border-radius: 3px;
    padding: 20px;
    position: sticky;
    top: 20px;
}

.checkout-sidebar h2 {
    text-align: center;
    margin-bottom: 15px;
}

.checkout-items {
    border-bottom: 1px solid #ddd;
    padding-bottom: 10px;
    margin-bottom: 10px;
}

.checkout-item {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 8px 0;
}

.checkout-item + .checkout-item {
    border-top: 1px solid #eee;
}

.checkout-thumb {
    width: 50px;
    height: 50px;
    object-fit: cover;
    border-radius: 5px;
    border: 1px solid #ddd;
}

.checkout-item-details {
    flex: 1;
    min-width: 0;
    display: flex;
    flex-direction: column;
    gap: 2px;
}

.checkout-item-name {
    font-weight: bold;
    font-size: 0.9em;
}

.checkout-item-qty {
    font-size: 0.8em;
    color: #666;
}

.checkout-item-price {
    font-weight: bold;
    white-space: nowrap;
}

.checkout-totals {
    padding: 5px 0 15px;
}

.checkout-line {
    display: flex;
    justify-content: space-between;
    padding: 4px 0;
    font-size: 0.95em;
}

.checkout-grand-total {
    border-top: 2px solid #333;
    margin-top: 6px;
    padding-top: 8px;
    font-weight: bold;
    font-size: 1.1em;
}

.checkout-sidebar .paypal-button {
    width: 100%;
    margin-top: 5px;
}

/* Cancel notice banner */
.cancel-notice {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 10px;
    max-width: 900px;
    margin: 0 auto 20px;
    padding: 12px 16px;
    background: #fff3cd;
    border: 2px solid #e6a800;
    border-radius: 2px;
    color: #664d03;
    font-size: 0.95em;
    text-align: left;
}

.cancel-notice-dismiss {
    background: none;
    border: none;
    font-size: 1.4em;
    cursor: pointer;
    color: #664d03;
    padding: 0 4px;
    line-height: 1;
}

/* Success notice banner */
.success-notice {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 10px;
    max-width: 900px;
    margin: 0 auto 20px;
    padding: 12px 16px;
    background: #d4edda;
    border: 2px solid #27ae60;
    border-radius: 2px;
    color: #155724;
    font-size: 0.95em;
    text-align: left;
}

.success-notice-dismiss {
    background: none;
    border: none;
    font-size: 1.4em;
    cursor: pointer;
    color: #155724;
    padding: 0 4px;
    line-height: 1;
}

/* PayPal button */
.paypal-button {
    display: inline-block;
    padding: 12px 24px;
    font-size: 1.2em;
    color: #fff;
    background-color: #0070ba;
    border: 2px outset #3a9ad9;
    border-radius: 2px;
    cursor: pointer;
    font-family: 'Courier New', Courier, monospace;
}

.paypal-button:hover {
    background-color: #005a96;
}

.paypal-button:active {
    border-style: inset;
}

/* Spinner */
.spinner-wrap {
    padding: 40px;
    text-align: center;
}

.spinner {
    display: inline-block;
    width: 40px;
    height: 40px;
    border: 4px solid #ccc;
    border-top-color: #007bff;
    border-radius: 50%;
    animation: spin 0.8s linear infinite;
}

@keyframes spin {
    to { transform: rotate(360deg); }
}

/* Error messages */
.error-message {
    color: #c0392b;
    font-weight: bold;
    padding: 10px;
    margin: 10px 0;
}

/* Order lookup page */
.order-lookup-info {
    max-width: 600px;
    margin: 20px auto;
    text-align: left;
    padding: 20px;
    background: #fff;
    border: 2px ridge #999;
    border-radius: 3px;
    line-height: 1.6;
    font-size: 0.9em;
}

.order-lookup-info p {
    margin: 12px 0;
}

.order-lookup-form {
    max-width: 400px;
    margin: 25px auto;
    text-align: left;
}

.order-lookup-form label {
    display: block;
    font-weight: bold;
    margin-bottom: 6px;
    font-size: 1.1em;
}

.order-lookup-form input {
    width: 100%;
    padding: 10px;
    margin-bottom: 10px;
    border: 2px inset #ccc;
    border-radius: 1px;
    font-family: 'Courier New', Courier, monospace;
    font-size: 1em;
    box-sizing: border-box;
}

.order-lookup-form .button {
    width: 100%;
    margin-top: 5px;
}


.shipping-address, .order-summary {
    max-width: 500px;
    margin: 20px auto;
    text-align: left;
    padding: 15px;
    background: #fff;
    border: 2px ridge #999;
    border-radius: 3px;
}

.order-summary h2, .shipping-address h2 {
    text-align: center;
}

/* Checkout thumbnail */
.thumbnail {
    width: 80px;
    height: auto;
    border-radius: 5px;
}

/* Image thumbnails */
.image-thumbnails {
    display: flex;
    gap: 4px;
    justify-content: center;
    margin-top: 6px;
}

.thumb {
    width: 40px;
    height: 40px;
    object-fit: cover;
    border: 2px solid #ccc;
    border-radius: 4px;
    cursor: pointer;
}

.thumb-active {
    border-color: #007bff;
}

.primary-image {
    width: 100%;
    height: auto;
    border-radius: 10px;
}

/* Product option selectors */
.option-group {
    margin: 6px 0;
    text-align: left;
    padding: 0 10px;
}

.option-group label {
    font-size: 0.85em;
    font-weight: bold;
    text-transform: capitalize;
}

.option-select {
    width: 100%;
    padding: 6px;
    border: 2px inset #ccc;
    border-radius: 1px;
    font-family: 'Courier New', Courier, monospace;
    font-size: 0.9em;
    margin-top: 2px;
}

.item-options {
    font-size: 0.8em;
    color: #555;
    margin: 2px 0;
}

/* Tracking info */
.tracking-info {
    background: #eaf7ea;
    border: 1px solid #27ae60;
    border-radius: 5px;
    padding: 10px;
    margin: 10px auto;
    max-width: 500px;
}

.status-shipped {
    color: #27ae60;
}

.status-confirmed {
    color: #2980b9;
}

.status-ready-to-ship {
    color: #e67e22;
}

.status-delivered {
    color: #27ae60;
}

.status-failed {
    color: #c0392b;
}

.status-refunded {
    color: #8e44ad;
}

/* Item card links */
.item-link {
    text-decoration: none;
    color: inherit;
    width: 20%;
    margin: 8px;
}

.item-link .item {
    width: auto;
    margin: 0;
    cursor: pointer;
}

.item-link .item:hover {
    border-color: #007bff;
    box-shadow: 3px 3px 8px rgba(0, 0, 0, 0.5);
}

/* Product detail page */
.product-page {
    display: flex;
    gap: 40px;
    max-width: 900px;
    margin: 0 auto;
    text-align: left;
}

.product-gallery {
    flex: 1;
    min-width: 0;
}

.product-info {
    flex: 1;
    min-width: 0;
}

.product-info h1 {
    font-size: 2em;
    margin-bottom: 10px;
    text-align: left;
}

.product-price {
    font-size: 1.8em;
    font-weight: bold;
    margin: 10px 0;
}

.product-description {
    font-size: 1em;
    line-height: 1.5;
    margin: 15px 0;
    color: #555;
}

/* Page header (back link, optionally cart button on right) */
.page-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    max-width: 900px;
    margin: 0 auto 20px;
}

.back-link {
    font-family: 'Courier New', Courier, monospace;
    font-size: 1em;
}

.page-header #cart-toggle:only-child {
    margin-left: auto;
}

#cart-toggle {
    background-color: #c0c0c0;
    color: #000;
    border: 2px outset #ddd;
    border-radius: 0;
    padding: 4px 12px;
    font-size: 0.9em;
    margin-top: 0;
}

#cart-toggle:hover {
    background-color: #d0d0d0;
}

#cart-toggle:active {
    border-style: inset;
}

/* Carousel */
.carousel {
    position: relative;
    background: #fff;
    border: 2px ridge #999;
    border-radius: 3px;
    overflow: hidden;
}

.carousel-main {
    display: block;
    width: 100%;
    height: auto;
}

.carousel-btn {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    background: rgba(0, 0, 0, 0.5);
    color: #fff;
    border: none;
    font-size: 1.5em;
    padding: 12px 14px;
    cursor: pointer;
    z-index: 2;
    line-height: 1;
}

.carousel-btn:hover {
    background: rgba(0, 0, 0, 0.8);
}

.carousel-prev {
    left: 0;
    border-radius: 0 5px 5px 0;
}

.carousel-next {
    right: 0;
    border-radius: 5px 0 0 5px;
}

.carousel-counter {
    position: absolute;
    bottom: 8px;
    right: 10px;
    background: rgba(0, 0, 0, 0.5);
    color: #fff;
    padding: 3px 8px;
    border-radius: 3px;
    font-size: 0.8em;
}

.carousel-thumbs {
    display: flex;
    gap: 6px;
    margin-top: 10px;
    justify-content: center;
    flex-wrap: wrap;
}

.carousel-thumb {
    width: 60px;
    height: 60px;
    object-fit: cover;
    border: 2px solid #ccc;
    border-radius: 6px;
    cursor: pointer;
}

.carousel-thumb-active {
    border-color: #007bff;
}

.carousel-placeholder {
    padding: 60px;
    background: #eee;
    border: 2px ridge #999;
    border-radius: 3px;
    color: #999;
}

/* Product options on detail page */
.product-options {
    margin: 15px 0;
}

.product-option-group {
    margin: 10px 0;
}

.product-option-group label {
    display: block;
    font-weight: bold;
    text-transform: capitalize;
    margin-bottom: 4px;
}

.product-option-select {
    width: 100%;
    padding: 8px;
    border: 2px inset #ccc;
    border-radius: 1px;
    font-family: 'Courier New', Courier, monospace;
    font-size: 1em;
}

.product-option-select option:disabled,
.variant-select option:disabled {
    color: #999;
}

/* Quantity selector */
.product-actions {
    margin-top: 20px;
}

.quantity-selector {
    display: flex;
    align-items: center;
    gap: 8px;
    margin-bottom: 15px;
}

.quantity-selector label {
    font-weight: bold;
    font-size: 1em;
}

.qty-btn {
    width: 36px;
    height: 36px;
    font-size: 1.2em;
    font-weight: bold;
    border: 2px outset #ddd;
    border-radius: 1px;
    background: #c0c0c0;
    cursor: pointer;
    font-family: 'Courier New', Courier, monospace;
    display: flex;
    align-items: center;
    justify-content: center;
}

.qty-btn:hover {
    background: #d0d0d0;
}

.qty-btn:active {
    border-style: inset;
}

#product-qty {
    width: 50px;
    text-align: center;
    padding: 6px;
    border: 2px inset #ccc;
    border-radius: 1px;
    font-family: 'Courier New', Courier, monospace;
    font-size: 1em;
    -moz-appearance: textfield;
}

#product-qty::-webkit-outer-spin-button,
#product-qty::-webkit-inner-spin-button {
    -webkit-appearance: none;
    margin: 0;
}

.product-add-btn {
    width: 100%;
    padding: 12px;
    font-size: 1.2em;
}

/* Status timeline */
.status-timeline {
    max-width: 500px;
    margin: 20px auto;
    text-align: left;
    padding: 15px;
    background: #fff;
    border: 2px ridge #999;
    border-radius: 3px;
}

.status-timeline h2 {
    text-align: center;
    margin-bottom: 15px;
}

.timeline-item {
    position: relative;
    padding-left: 30px;
    padding-bottom: 20px;
}

.timeline-item:last-child {
    padding-bottom: 0;
}

.timeline-item::before {
    content: '';
    position: absolute;
    left: 8px;
    top: 14px;
    bottom: 0;
    width: 2px;
    background: #ccc;
}

.timeline-item:last-child::before {
    display: none;
}

.timeline-dot {
    position: absolute;
    left: 2px;
    top: 5px;
    width: 14px;
    height: 14px;
    background: #ccc;
    border-radius: 50%;
    border: 2px solid #fff;
}

.timeline-item-active .timeline-dot {
    background: #007bff;
}

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

.timeline-status {
    font-weight: bold;
    text-transform: capitalize;
}

.timeline-date {
    font-size: 0.8em;
    color: #888;
    white-space: nowrap;
}

/* Refund info */
.refund-info {
    background: #f3e5f5;
    border: 1px solid #8e44ad;
    border-radius: 5px;
    padding: 10px;
    margin: 10px auto;
    max-width: 500px;
}

.tracking-info-standard {
    background: #fff3e0;
    border-color: #e67e22;
}

/* Review section */
.review-section {
    max-width: 500px;
    margin: 20px auto;
    text-align: left;
    padding: 15px;
    background: #fff;
    border: 2px ridge #999;
    border-radius: 3px;
}

.review-section h2 {
    text-align: center;
    margin-bottom: 15px;
}

.review-form .review-field {
    margin-bottom: 12px;
}

.review-form label {
    display: block;
    font-weight: bold;
    margin-bottom: 4px;
}

.review-form select,
.review-form textarea {
    width: 100%;
    padding: 8px;
    border: 2px inset #ccc;
    border-radius: 1px;
    font-family: 'Courier New', Courier, monospace;
    font-size: 1em;
    box-sizing: border-box;
}

.review-form textarea {
    resize: vertical;
}

.review-form .button {
    width: 100%;
}

.review-display {
    padding: 10px 0;
}

.star-rating {
    font-size: 1.5em;
    color: #f39c12;
    letter-spacing: 2px;
}

.review-comment {
    margin: 10px 0;
    line-height: 1.4;
}

.review-date {
    font-size: 0.8em;
    color: #888;
}

@media (max-width: 990px) {
    .item {
        width: 40%;
    }

    .item-link {
        width: 40%;
    }

    .product-page {
        flex-direction: column;
        padding: 0 10px;
    }

    .checkout-layout {
        flex-direction: column;
        padding: 0 10px;
    }

    .checkout-sidebar {
        width: auto;
        position: static;
    }

    .shipping-row {
        flex-direction: column;
        gap: 0;
    }
}
