@import url("https://fonts.googleapis.com/css2?family=Nunito:wght@400;500;600;700;800&display=swap");
/* =========================================================
   1. GLOBAL STYLES
========================================================= */
*,
*::before,
*::after {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}
html {
    scroll-behavior: smooth;
}
body,
button,
input,
select,
textarea {
    font-family: "Nunito", sans-serif;
}
body {
    background: #f1f1f1;
    color: #111111;
    line-height: 1.6;
    font-weight: 400;
}
img {
    display: block;
    max-width: 100%;
}
a {
    text-decoration: none;
}
button {
    font-family: inherit;
}
/* =========================================================
   2. HEADER AND NAVIGATION
========================================================= */
header {
    position: relative;
    z-index: 1000;
    display: flex;
    justify-content: space-between;
    align-items: center;
    height: 130px;
    padding: 0 8%;
    background: #ffffff;
    box-shadow: 0 3px 10px rgba(0, 0, 0, 0.15);
}
.logo h2 {
    color: #ff6600;
}
.logo img {
    display: block;
    width: auto;
    height: 120px;
    max-width: 100%;
    object-fit: contain;
}
/* Desktop navigation */
header nav {
    display: block;
}
header nav ul {
    display: flex;
    align-items: center;
    gap: 12px;
    margin: 0;
    padding: 0;
    list-style: none;
}
header nav ul > li {
    margin: 0;
    padding: 0;
}
nav a {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    color: #070707;
    font-size: 18px;
    font-weight: 700;
    transition:
        transform 0.2s ease,
        color 0.2s ease;
}
nav a i {
    font-size: 18px;
}
nav a:hover {
    color: #ff6600;
    transform: translateY(-3px) scale(1.05);
}
.nav-link {
    padding: 6px 8px;
    border-radius: 4px;
}
.nav-link.active {
    background: #90b6f8;
    color: #111111;
}
/* Hamburger is hidden on desktop */
header .mobile-menu-button {
    display: none !important;
}
/* Account dropdown */
.account-area {
    position: relative;
    display: inline-block;
}
.account-button {
    padding: 8px;
    border: 0;
    background: transparent;
    color: inherit;
    cursor: pointer;
    font-size: 1.45rem;
}
.account-button:hover {
    opacity: 0.75;
}
.account-menu {
    position: absolute;
    top: calc(100% + 10px);
    right: 0;
    z-index: 1000;
    min-width: 180px;
    padding: 12px;
    background: #ffffff;
    border: 1px solid #dddddd;
    border-radius: 8px;
    box-shadow: 0 6px 20px rgba(0, 0, 0, 0.15);
}
.account-menu a,
.account-menu button {
    display: block;
    width: 100%;
    padding: 9px 10px;
    border: 0;
    background: transparent;
    color: #222222;
    cursor: pointer;
    font-size: 14px;
    text-align: left;
}
.account-menu a:hover,
.account-menu button:hover {
    background: #f1f1f1;
    border-radius: 5px;
}
#accountEmail {
    max-width: 160px;
    margin: 0 10px 8px;
    overflow: hidden;
    color: #666666;
    font-size: 12px;
    text-overflow: ellipsis;
    white-space: nowrap;
}
/* =========================================================
   3. PRODUCT LISTING PAGE
========================================================= */
.products {
    padding: 60px 8%;
    background: #f1f1f1;
}
.products h2 {
    margin-bottom: 30px;
    color: #000000;
    font-size: 35px;
    text-align: left;
}
.products-toolbar {
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
    gap: 20px;
    margin-bottom: 40px;
    padding-bottom: 20px;
    border-bottom: 1px solid #ffffff;
}
.toolbar-left,
.toolbar-right {
    display: flex;
    align-items: center;
    flex-wrap: wrap;
    gap: 18px;
}
.toolbar-left {
    gap: 10px;
}
.products-toolbar span {
    color: #060606;
    font-size: 16px;
    font-weight: bold;
}
.products-toolbar select,
.products-toolbar input[type="search"] {
    padding: 10px 14px;
    background: #fafafa;
    color: #111111;
    border: 1px solid #616161;
    border-radius: 10px;
    font-size: 15px;
    box-sizing: border-box;
}
.products-toolbar select {
    min-width: 165px;
    cursor: pointer;
}
.products-toolbar option {
    background: #f8f8f8;
    color: #080808;
}
/* Product description */
#productDescription {
    display: block;
    position: relative;
    color: #080808 !important;
    background-color: #fdfdfd;
    padding: 18px 20px;
    margin-top: 12px;
    border: 1px solid #bbbbbb;
    border-radius: 16px;
    font-size: 15px;
    line-height: 1.8;
    white-space: pre-line;
    overflow-wrap: anywhere;
    box-sizing: border-box;
    overflow: hidden;
    transition: max-height 0.35s ease;
}
/* Collapsed state */
#productDescription.is-collapsed {
    max-height: var(--description-collapsed-height, 146px);
}
/* Expanded state */
#productDescription.is-expanded {
    max-height: var(--description-expanded-height, 2000px);
}
/* Description ellipsis */
#productDescription.is-collapsed::after {
    content: "…";
    position: absolute;
    right: 20px;
    bottom: 18px;
    padding-left: 24px;
    color: #080808;
    background: linear-gradient(
        to right,
        rgba(112, 177, 214, 0),
        #5db6ee 55%
    );
    pointer-events: none;
}
/* Read More / Read Less */
.description-toggle {
    display: inline-block;
    margin-top: 8px;
    padding: 6px 0;
    background: transparent;
    color: #123e75;
    border: none;
    font-family: inherit;
    font-size: 14px;
    font-weight: 800;
    cursor: pointer;
    text-decoration: underline;
    text-underline-offset: 3px;
    transition: color 0.2s ease;
}
.description-toggle:hover {
    color: #ff6600;
}
.description-toggle:focus-visible {
    outline: 2px solid #123e75;
    outline-offset: 4px;
    border-radius: 3px;
}
.description-toggle[hidden] {
    display: none !important;
}
#productSearch {
    min-width: 275px;
    padding: 9px 12px;
    border: 1px solid #111111;
    border-radius: 8px;
    font-size: 14px;
}
#productSearch:focus {
    outline: 2px solid #111111;
    outline-offset: 1px;
}
.products-toolbar select:focus,
.products-toolbar input[type="search"]:focus {
    outline: 2px solid #111111;
    outline-offset: 1px;
}
.product-count {
    color: #555555;
}
/* Screen-reader-only content */
.visually-hidden {
    position: absolute;
    width: 1px;
    height: 1px;
    padding: 0;
    margin: -1px;
    overflow: hidden;
    clip: rect(0, 0, 0, 0);
    white-space: nowrap;
    border: 0;
}
/* General search */
#search {
    display: block;
    width: 100%;
    max-width: 450px;
    margin: 0 auto 35px;
    padding: 12px;
    border: 1px solid #cccccc;
    border-radius: 6px;
    font-size: 16px;
}
/* Product grid */
.product-grid {
    display: grid;
    grid-template-columns: repeat(
        auto-fill,
        minmax(min(100%, 220px), 1fr)
    );
    justify-content: start;
    align-items: stretch;
    gap: 20px;
}
.product-card {
    display: flex;
    flex-direction: column;
    width: 100%;
    max-width: 280px;
    height: 100%;
    padding: 15px;
    background: #fafafa;
    border-radius: 14px;
    box-shadow: 0 8px 22px rgba(0, 0, 0, 0.50);
    text-align: left;
    transition: transform 0.3s ease;
}
.product-card:hover {
    transform: translateY(-5px);
}
.product-card img {
    display: block;
    width: 100%;
    height: 220px;
    object-fit: cover;
    border-radius: 10px;
}
.product-card h3 {
    margin-top: 15px;
    margin-bottom: 5px;
    color: #090909;
}
.product-card h3 a {
    color: #0e0e0e;
    text-decoration: none;
}
.product-card h3 a:hover {
    color: #ff6600;
}
.product-card h4 {
    margin: 15px 0;
    color: #090909;
    font-size: 22px;
}
.product-card p {
    margin-bottom: 15px;
    color: #090909;
    font-size: 16px;
}
.product-card button {
    padding: 12px 28px;
    margin-top: auto;
    background: #1e3a8a;
    color: #ffffff;
    border: none;
    border-radius: 10px;
    font-size: 16px;
    font-weight: 600;
    cursor: pointer;
    transition: background 0.3s ease;
}
.product-card button:hover:not(:disabled) {
    background: #ff6600;
}
.product-card button:disabled {
    opacity: 0.55;
    cursor: not-allowed;
}
.product-id {
    margin: 8px 0 4px;
    color: #777777;
    font-size: 12px;
    font-weight: 600;
}
/* =========================================================
   4. WHY US SECTION
========================================================= */
.why {
    background: #4e7fbb;
}
.why h2 {
    margin-bottom: 40px;
    text-align: center;
}
.why-grid {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 20px;
}
.why-grid div {
    padding: 25px;
    background: #f8f8f8;
    border-radius: 8px;
    text-align: center;
}
.why-grid h3 {
    margin-bottom: 10px;
}
/* =========================================================
   5. FOOTER
========================================================= */
footer {
    padding: 60px 8% 20px;
    background: #111111;
    color: #ffffff;
}
.footer-container {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    align-items: start;
    gap: 40px;
}
.footer-column {
    min-width: 0;
    text-align: left;
}
.footer-column:nth-child(1) {
    justify-self: start;
}
.footer-column:nth-child(2) {
    justify-self: center;
    text-align: center;
}
.footer-column:nth-child(3) {
    justify-self: end;
}
.footer-column h2,
.footer-column h3 {
    margin-bottom: 20px;
    color: #ffffff;
    text-transform: uppercase;
}
.footer-column p {
    color: #c7c7c7;
    line-height: 1.8;
}
.footer-column ul {
    padding: 0;
    list-style: none;
}
.footer-column ul li {
    margin-bottom: 12px;
}
.footer-column ul li a {
    display: inline-block;
    color: #c7c7c7;
    transition:
        transform 0.2s ease,
        color 0.2s ease;
}
.footer-column ul li a:hover {
    color: #ff6600;
    transform: translateY(-3px) scale(1.05);
}
footer hr {
    margin: 40px 0 20px;
    border: none;
    border-top: 1px solid #333333;
}
.copyright {
    color: #999999;
    text-align: center;
}
.social-icons {
    display: flex;
    gap: 15px;
    margin-top: 10px;
}
.social-icons a {
    display: flex;
    justify-content: center;
    align-items: center;
    width: 45px;
    height: 45px;
    background: #222222;
    color: #ffffff;
    border-radius: 50%;
    font-size: 20px;
    transition:
        background 0.3s ease,
        transform 0.3s ease;
}
.social-icons a:hover {
    background: #ff6600;
    transform: translateY(-5px);
}
/* =========================================================
   6. SHOPPING CART
========================================================= */
.cart {
    min-height: 60vh;
    padding: 60px 8%;
    background: #686868;
    color: #f5f5f5;
}
.cart h1 {
    margin-bottom: 30px;
    color: #ffffff;
    text-align: center;
}
.cart-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
    gap: 20px;
    padding: 20px;
    background: #222222;
    border: 1px solid #333333;
    border-radius: 10px;
}
.cart-item img {
    width: 120px;
    height: 120px;
    object-fit: cover;
    border-radius: 8px;
}
.cart-details {
    flex: 1;
    min-width: 150px;
}
.cart-details h3 {
    margin-bottom: 10px;
    color: #ffffff;
}
.cart-details p {
    margin-bottom: 12px;
    color: #c7c7c7;
}
.quantity-controls {
    display: flex;
    align-items: center;
    gap: 12px;
}
.quantity-controls button {
    width: 35px;
    height: 35px;
    background: #ff6600;
    color: #ffffff;
    border: none;
    border-radius: 6px;
    font-size: 20px;
    cursor: pointer;
}
.quantity-controls span {
    color: #ffffff;
    font-size: 18px;
    font-weight: 700;
}
.cart-actions {
    text-align: right;
}
.cart-actions p {
    margin-bottom: 12px;
    color: #ffffff;
    font-weight: 700;
}
.delete-btn {
    padding: 10px 18px;
    background: #c62828;
    color: #ffffff;
    border: none;
    border-radius: 6px;
    cursor: pointer;
}
.delete-btn:hover {
    background: #e53935;
}
.cart-total {
    margin-top: 30px;
    text-align: right;
}
.cart-total h2 {
    margin-bottom: 15px;
    color: #ffffff;
}
.cart-total button {
    margin-top: 15px;
    padding: 12px 25px;
    background: #ff6600;
    color: #ffffff;
    border: none;
    border-radius: 5px;
    cursor: pointer;
}
.cart-total button:hover {
    background: #e65c00;
}
.empty-cart {
    padding: 40px 0;
    color: #c7c7c7;
    font-size: 20px;
    text-align: center;
}
/* =========================================================
   7. POLICY PAGES
========================================================= */
.policy-page {
    padding: 70px 8%;
    background: #0d0c0c;
}
.policy-container {
    max-width: 950px;
    margin: 0 auto;
    padding: 50px 40px;
    background: #faf9f9;
    border: 1px solid #2a2a2a;
    border-radius: 12px;
    box-shadow: 0 8px 30px rgba(0, 0, 0, 0.25);
}
.policy-eyebrow {
    margin-bottom: 14px;
    color: #0f0f0f;
    font-size: 20px;
    font-weight: 700;
    letter-spacing: 1px;
    text-transform: uppercase;
    text-align: center;
    text-decoration: underline;
    text-underline-offset: 6px;
}
.policy-container h1 {
    margin-top: 40px;
    margin-bottom: 20px;
    color: #080808;
    font-size: 20px;
    line-height: 1.2;
}
.policy-intro {
    margin-bottom: 35px;
    padding-bottom: 25px;
    color: #0f0f0f;
    font-size: 18px;
    line-height: 1.8;
    border-bottom: 1px solid #2f2f2f;
}
.policy-section {
    margin-bottom: 38px;
}
.policy-section h2 {
    margin-bottom: 16px;
    color: #141414;
    font-size: 20px;
}
.policy-section h3 {
    margin: 20px 0 12px;
    color: #0d0d0d;
    font-size: 18px;
}
.policy-section p {
    margin-bottom: 14px;
    color: #0c0c0c;
    font-size: 16px;
    line-height: 1.9;
}
.policy-section ul {
    margin: 10px 0 18px 20px;
    padding-left: 18px;
}
.policy-section ul li {
    margin-bottom: 4px;
    color: #141414;
    line-height: 1.5;
}
/* =========================================================
   8. SIGNUP AND AUTHENTICATION PAGES
========================================================= */
.auth-page {
    display: flex;
    justify-content: center;
    align-items: center;
    min-height: calc(100vh - 160px);
    padding: 40px 20px;
    background: #f1f1f1;
}
.auth-card {
    display: grid;
    grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
    align-items: stretch;
    width: 100%;
    max-width: 1100px;
    min-width: 0;
    overflow: hidden;
    background: #1d10d79d;
    border-radius: 18px;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.08);
}
.auth-left {
    display: flex;
    flex-direction: column;
    justify-content: center;
    min-width: 0;
    padding: 60px 50px;
}
.auth-left h2 {
    margin: 0 0 10px;
    color: #f8f8f8;
    font-size: 42px;
}
.auth-left p {
    margin-bottom: 30px;
    color: #fcfdfe;
}
.basic-login-form {
    display: flex;
    flex-direction: column;
    gap: 14px;
}
.basic-login-form label {
    color: #fcfdfe;
    font-size: 16px;
    font-weight: 600;
}
.basic-login-form input {
    width: 100%;
    padding: 14px 16px;
    background: #ffffff;
    color: #111111;
    border: 1px solid #d6dbe6;
    border-radius: 8px;
    outline: none;
}
.auth-btn {
    margin-top: 8px;
    padding: 14px 18px;
    background: #1d1c1c;
    color: #ffffff;
    border: none;
    border-radius: 8px;
    font-size: 14px;
    font-weight: 700;
    cursor: pointer;
}
.switch-link {
    margin-top: 16px;
    font-size: 14px;
}
.switch-link a {
    color: #dbf804;
    font-weight: 700;
}
/* Image container */
.auth-right {
    position: relative;
    display: block;
    width: 100%;
    height: auto;
    min-width: 0;
    min-height: 420px;
    padding: 0;
    margin: 0;
    overflow: hidden;
    background: #000000;
    box-sizing: border-box;
}
/* Image fills the complete container */
.auth-right img {
    position: absolute;
    inset: 0;
    display: block;
    width: 100%;
    height: 100%;
    min-width: 0;
    min-height: 0;
    max-width: none;
    padding: 0;
    margin: 0;
    border: 0;
    object-fit: cover;
    object-position: center;
}
/* Specific protection for the My Account page.
   Its inline CSS sets .auth-right min-height to 0. */
.my-account-page .auth-right {
    min-height: 420px;
}
/* =========================================================
   9. PRODUCT DETAILS PAGE
========================================================= */
.product-page {
    width: 90%;
    max-width: 1180px;
    margin: 40px auto 60px;
}
.product-layout {
    display: grid;
    grid-template-columns: minmax(280px, 1fr) minmax(320px, 1fr);
    align-items: start;
    gap: clamp(30px, 6vw, 80px);
}
.product-gallery {
    min-width: 0;
}
.product-image {
    position: relative;
    display: flex;
    justify-content: center;
    align-items: center;
    width: 100%;
    height: 420px;
    padding: 24px;
    overflow: hidden;
    background: linear-gradient(145deg, #292929, #202020);
    border: 1px solid rgba(255, 255, 255, 0.12);
    border-radius: 16px;
}
.product-image img {
    width: 100%;
    height: 100%;
    object-fit: contain;
    border-radius: 12px;
    transition: transform 0.4s ease;
}
.product-info {
    min-width: 0;
}
.product-info h1 {
    margin: 0 0 10px;
    color: #080808;
    font-size: 2rem;
    line-height: 1.2;
}
.price {
    margin: 0 0 12px;
    color: #0f0d0d;
    font-size: 1.6rem;
    font-weight: 700;
}
#productPrice span:nth-child(2),
#productPrice span:nth-child(3) {
    font-size: 22px;
}
.stock-status {
    margin: 0 0 20px;
    color: #555555;
}
.stock-status.in-stock {
    color: #20b80c;
    font-size: 18px;
    font-weight: 700;
}
.stock-status.out-of-stock {
    color: #f46c3b;
}
.product-meta {
    margin: 20px 0;
    padding: 14px;
    background: #5db6ee;
    color: #111111;
    border: 1px solid rgba(255, 255, 255, 0.12);
    border-radius: 8px;
    line-height: 1.7;
}
.product-meta p {
    margin: 0;
}
#productMetaText {
    white-space: pre-line;
}
/* =========================================================
   10. PRODUCT OPTIONS AND QUANTITY
========================================================= */
.option-group {
    margin: 20px 0;
}
.option-label {
    display: block;
    margin-bottom: 8px;
    color: #111111;
    font-weight: 700;
}
/* Colour swatches */
.color-options {
    display: flex;
    flex-wrap: wrap;
    gap: 12px;
}
.color-option {
    width: 44px;
    height: 44px;
    padding: 0;
    background: #777777;
    border: 3px solid transparent;
    border-radius: 8px;
    box-shadow: 0 2px 6px rgba(0, 0, 0, 0.3);
    cursor: pointer;
    transition:
        transform 0.2s ease,
        border-color 0.2s ease,
        box-shadow 0.2s ease;
}
.color-option:hover {
    border-color: #ffffff;
    transform: scale(1.12);
}
.color-option.selected {
    border-color: #ffffff;
    transform: scale(1.08);
    box-shadow: 0 0 0 3px rgba(255, 147, 109, 0.3);
}
.color-option:focus-visible {
    outline: 3px solid #fa6e3b;
    outline-offset: 3px;
}
.selected-color-text {
    margin-top: 12px;
    color: #555555;
    font-size: 16px;
}
#selectedColor {
    color: #db5220;
    font-size: 16px;
    font-weight: 700;
}
/* Quantity control */
.quantity-control {
    display: inline-flex;
    align-items: center;
    overflow: hidden;
    background: #242424;
    border: 1px solid rgba(255, 255, 255, 0.12);
    border-radius: 8px;
}
.quantity-control button {
    width: 40px;
    height: 40px;
    background: #1e3a8a;
    color: #f5f5f5;
    border: 0;
    font-size: 18px;
    font-weight: 700;
    cursor: pointer;
}
.quantity-control button:hover:not(:disabled) {
    background: #ff6b35;
    color: #ffffff;
}
.quantity-control button:disabled {
    opacity: 0.5;
    cursor: not-allowed;
}
.quantity-control input {
    width: 48px;
    height: 40px;
    background: #1e3a8a;
    color: #f5f5f5;
    border: none;
    outline: 0;
    font-size: 18px;
    font-weight: 700;
    text-align: center;
}
#quantity::-webkit-outer-spin-button,
#quantity::-webkit-inner-spin-button {
    margin: 0;
    -webkit-appearance: none;
}
#quantity {
    -moz-appearance: textfield;
    appearance: textfield;
}
#productNotes {
    width: 100%;
    min-height: 100px;
    padding: 10px;
    background: #f9f7f7;
    color: #040404;
    border: 1px solid rgba(255, 255, 255, 0.12);
    border-radius: 8px;
    outline: 0;
    resize: vertical;
}
#productNotes:focus {
    border-color: #fa6e3b;
}
.add-to-cart-btn {
    width: 100%;
    margin-top: 14px;
    padding: 14px 22px;
    background: #1e3a8a;
    color: #fefbfb;
    border: 2px solid #2c2f5a;
    border-radius: 8px;
    font-size: 16px;
    font-weight: 800;
    cursor: pointer;
    transition:
        background-color 0.25s ease,
        border-color 0.25s ease,
        transform 0.25s ease,
        box-shadow 0.25s ease;
}
.add-to-cart-btn:hover:not(:disabled) {
    background: #fa6e3b;
    border-color: #fa6e3b;
    transform: translateY(-2px);
    box-shadow: 0 10px 24px rgba(255, 107, 53, 0.3);
}
.add-to-cart-btn:disabled {
    opacity: 0.55;
    cursor: not-allowed;
}
/* =========================================================
   11. PRODUCT IMAGE GALLERY
========================================================= */
.product-thumbnails {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    margin-top: 12px;
}
.product-thumbnail {
    width: 72px;
    height: 72px;
    padding: 0;
    overflow: hidden;
    background: #242424;
    border: 2px solid transparent;
    border-radius: 8px;
    cursor: pointer;
    transition:
        transform 0.2s ease,
        border-color 0.2s ease,
        box-shadow 0.2s ease;
}
.product-thumbnail img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}
.product-thumbnail:hover {
    border-color: #fa6e3b;
    transform: translateY(-2px);
}
.product-thumbnail.active {
    border-color: #ff6b35;
    box-shadow: 0 0 0 2px rgba(255, 147, 109, 0.3);
}
.zoom-image-button {
    position: absolute;
    top: 14px;
    right: 14px;
    display: inline-flex;
    justify-content: center;
    align-items: center;
    width: 42px;
    height: 42px;
    background: rgba(17, 17, 17, 0.78);
    color: #ffffff;
    border: 1px solid rgba(255, 255, 255, 0.45);
    border-radius: 8px;
    font-size: 17px;
    cursor: pointer;
    transition:
        background-color 0.2s ease,
        transform 0.2s ease,
        box-shadow 0.2s ease;
}
.zoom-image-button:hover {
    background: #ff6b35;
    transform: scale(1.08);
    box-shadow: 0 5px 14px rgba(0, 0, 0, 0.3);
}
#productImage:fullscreen {
    width: 100%;
    height: 100%;
    max-width: none;
    max-height: none;
    object-fit: contain;
    background: #111111;
    border-radius: 0;
}
/* =========================================================
   12. PRODUCT ERROR MESSAGES
========================================================= */
.product-error {
    grid-column: 1 / -1;
    padding: 30px;
    background: #242424;
    border: 1px solid rgba(255, 147, 109, 0.5);
    border-radius: 12px;
    text-align: center;
}
.product-error p {
    margin-bottom: 12px;
    color: #f5f5f5;
}
.product-error a {
    color: #fa6e3b;
}
/* =========================================================
   13. PRODUCT RATINGS AND REVIEWS
========================================================= */
.product-rating {
    display: flex;
    align-items: center;
    gap: 8px;
    margin: -4px 0 14px;
}
.rating-stars {
    color: #ffb400;
    font-size: 22px;
    letter-spacing: 1px;
    line-height: 1;
}
.rating-value,
.rating-review-count {
    color: #555555;
    font-size: 14px;
    font-weight: 600;
}
.reviews-section {
    margin-top: 34px;
    padding-top: 26px;
    border-top: 1px solid rgba(0, 0, 0, 0.12);
}
.reviews-heading {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 12px;
    margin-bottom: 16px;
}
.reviews-count {
    color: #555555;
    font-size: 14px;
    white-space: nowrap;
}
.review-form {
    margin: 18px 0 24px;
}
.review-form textarea {
    width: 100%;
    min-height: 110px;
    padding: 12px;
    background: #242424;
    color: #ffffff;
    border: 1px solid rgba(255, 255, 255, 0.18);
    border-radius: 8px;
    font: inherit;
    outline: 0;
    resize: vertical;
}
.review-form textarea:focus {
    border-color: #fa6e3b;
}
.submit-review-button {
    margin-top: 10px;
    padding: 10px 16px;
    background: #ff6600;
    color: #111111;
    border: 0;
    border-radius: 8px;
    font-size: 14px;
    font-weight: 800;
    cursor: pointer;
    transition:
        background 0.2s ease,
        transform 0.2s ease;
}
.submit-review-button:hover {
    background: #fa6e3b;
    transform: translateY(-2px);
}
.review-status {
    min-height: 20px;
    margin-top: 8px;
    color: #555555;
    font-size: 14px;
}
.review-login-message {
    margin: 16px 0;
    color: #555555;
}
.review-login-message a {
    color: #fa6e3b;
    font-weight: 700;
}
.reviews-list {
    display: grid;
    gap: 12px;
}
.review-card {
    padding: 14px;
    background: #f6f5f5;
    border: 1px solid #242424;
    border-radius: 10px;
}
.review-card-header {
    display: flex;
    align-items: center;
    flex-wrap: wrap;
    gap: 10px;
}
.review-card-name {
    margin: 0;
    color: #131313;
    font-size: 15px;
    font-weight: 800;
}
.review-card-stars {
    color: #f99b04;
    font-size: 24px;
    letter-spacing: 1px;
    line-height: 1;
}
.review-card-text {
    margin: 0;
    color: #080808;
    line-height: 1.6;
    white-space: pre-wrap;
    overflow-wrap: anywhere;
}
.reviews-empty {
    margin: 0;
    color: #555555;
}
/* =========================================================
   14. PRODUCT REVIEW MODAL
========================================================= */
.product-review-modal {
    position: fixed;
    inset: 0;
    z-index: 3000;
    display: none;
    justify-content: center;
    align-items: center;
    padding: 20px;
    background: rgba(0, 0, 0, 0.72);
}
.product-review-modal.show {
    display: flex;
}
.product-review-dialog {
    position: relative;
    width: min(100%, 480px);
    max-height: 90vh;
    padding: 24px;
    overflow-y: auto;
    background: #f8f8f8;
    color: #111111;
    border-radius: 14px;
    box-shadow: 0 12px 35px rgba(0, 0, 0, 0.4);
}
.product-review-dialog h3 {
    margin: 0 0 8px;
    color: #111111;
    font-size: 22px;
}
.product-review-product-name {
    margin: 0 0 18px;
    color: #555555;
    font-size: 14px;
    font-weight: 600;
}
.product-review-close {
    position: absolute;
    top: 10px;
    right: 12px;
    width: 34px;
    height: 34px;
    background: transparent;
    color: #333333;
    border: 0;
    border-radius: 50%;
    font-size: 28px;
    line-height: 1;
    cursor: pointer;
}
.product-review-close:hover {
    background: #e5e5e5;
}
#productReviewForm label {
    display: block;
    margin: 14px 0 7px;
    color: #222222;
    font-size: 14px;
    font-weight: 700;
}
.review-star-input {
    display: flex;
    gap: 4px;
}
.review-star {
    padding: 0;
    background: transparent;
    color: #c7c7c7;
    border: 0;
    font-size: 32px;
    line-height: 1;
    cursor: pointer;
    transition:
        color 0.2s ease,
        transform 0.2s ease;
}
.review-star:hover,
.review-star.selected {
    color: #ffb400;
    transform: scale(1.08);
}
.product-review-modal .review-star-input {
    position: relative;
    z-index: 1;
    display: flex;
    gap: 6px;
    pointer-events: auto;
}
.product-review-modal .review-star {
    display: inline-flex;
    justify-content: center;
    align-items: center;
    width: 42px;
    height: 42px;
    padding: 0;
    background: transparent;
    color: #c7c7c7;
    border: 0;
    font-size: 32px;
    line-height: 1;
    cursor: pointer;
    pointer-events: auto;
    -webkit-appearance: none;
    appearance: none;
    transition:
        color 0.2s ease,
        transform 0.2s ease;
}
.product-review-modal .review-star:hover,
.product-review-modal .review-star.selected {
    background: transparent;
    color: #ffb400;
    transform: scale(1.12);
    box-shadow: none;
}
.selected-review-rating {
    min-height: 20px;
    margin: 8px 0;
    color: #777777;
    font-size: 13px;
}
#reviewText {
    width: 100%;
    padding: 10px;
    background: #ffffff;
    color: #111111;
    border: 1px solid #cccccc;
    border-radius: 8px;
    font: inherit;
    resize: vertical;
}
#reviewText:focus {
    border-color: #ff6600;
    outline: 2px solid rgba(255, 102, 0, 0.18);
}
.product-review-status {
    min-height: 20px;
    margin: 8px 0;
    color: #b00020;
    font-size: 13px;
}
.save-product-review {
    width: 100%;
    margin-top: 10px;
    padding: 11px 16px;
    background: #111111;
    color: #ffffff;
    border: 0;
    border-radius: 8px;
    font-size: 14px;
    font-weight: 700;
    cursor: pointer;
}
.save-product-review:hover {
    background: #333333;
}
.save-product-review:disabled {
    opacity: 0.6;
    cursor: not-allowed;
}
.already-reviewed-message {
    margin-top: 18px;
    padding: 12px;
    background: #eeeeee;
    color: #333333;
    border-radius: 8px;
}
.already-reviewed-message p {
    margin: 0 0 8px;
    color: #333333;
}
.existing-review-content {
    color: #555555;
    font-size: 14px;
    line-height: 1.5;
}
.add-product-review-link {
    display: inline-block;
    margin-top: 12px;
    padding: 10px 16px;
    background: #1e3a8a;
    color: #ffffff;
    border: 0;
    border-radius: 8px;
    font-size: 14px;
    font-weight: 700;
    cursor: pointer;
    transition:
        background-color 0.2s ease,
        transform 0.2s ease;
}
.add-product-review-link:hover {
    background: #294aa8;
    transform: translateY(-2px);
}
.add-product-review-link:active {
    transform: translateY(0);
}
.add-product-review-link:focus-visible {
    outline: 3px solid #8fb3ff;
    outline-offset: 3px;
}
/* =========================================================
   15. NOTIFICATIONS AND TOAST MESSAGES
========================================================= */
/* General toast */
.toast {
    position: fixed;
    right: 30px;
    bottom: 30px;
    z-index: 9999;
    padding: 14px 20px;
    background: #369751;
    color: #ffffff;
    border: 1px solid #0b0b0b;
    border-radius: 8px;
    box-shadow: 0 10px 25px rgba(0, 0, 0, 0.25);
    opacity: 0;
    pointer-events: none;
    transform: translateY(20px);
    transition:
        opacity 0.3s ease,
        transform 0.3s ease;
}
.toast.show {
    opacity: 1;
    transform: translateY(0);
}
/* Error toast */
.toast-error {
    position: fixed;
    top: 20px;
    right: 20px;
    z-index: 9999;
    padding: 12px 18px;
    background: #d9534f;
    color: #ffffff;
    border-radius: 8px;
    font-weight: 600;
    opacity: 0;
    visibility: hidden;
    pointer-events: none;
    transform: translateY(-10px);
    transition:
        opacity 0.3s ease,
        transform 0.3s ease,
        visibility 0.3s ease;
}
.toast-error.show {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
}
/* =========================================================
   16. RESPONSIVE LAYOUTS - TABLET
========================================================= */
@media (max-width: 900px) {
    /* Authentication page */
    .auth-card {
        grid-template-columns: minmax(0, 1fr);
    }
    .auth-right {
        position: relative;
        width: 100%;
        height: auto;
        min-height: 320px;
        padding: 0;
        margin: 0;
        overflow: hidden;
        background: #000000;
    }
    .auth-right img {
        position: absolute;
        inset: 0;
        display: block;
        width: 100%;
        height: 100%;
        min-width: 0;
        min-height: 0;
        max-width: none;
        padding: 0;
        margin: 0;
        border: 0;
        object-fit: cover;
        object-position: center;
    }
    .auth-left {
        padding: 40px 25px;
    }
    .auth-left h2 {
        font-size: 36px;
    }
}
/* =========================================================
   17. RESPONSIVE LAYOUTS - MOBILE
========================================================= */
@media (max-width: 768px) {
    /* General header: final shared header layout is defined below */
    header {
        height: auto;
        min-height: 130px;
        flex-direction: column;
        justify-content: center;
        gap: 12px;
        padding: 16px 5%;
    }
    nav ul {
        flex-direction: column;
        align-items: center;
        margin-top: 15px;
        text-align: center;
    }
    /* General hero */
    .hero {
        flex-direction: column;
        text-align: center;
    }
    .hero-text {
        width: 100%;
    }
    .hero-image {
        width: 80%;
        margin-top: 30px;
    }
    /* General product grid: two products per row */
    .product-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }
    /* Product cards */
    .product-card h3 {
        font-size: 14px !important;
        line-height: 1.35 !important;
    }
    .product-card h4 {
        font-size: 16px !important;
        line-height: 1.3 !important;
    }
    /* Why us */
    .why-grid {
        grid-template-columns: 1fr;
    }
    /* Cart */
    .cart {
        padding: 40px 5%;
    }
    .cart-item {
        align-items: flex-start;
    }
    .cart-actions {
        width: 100%;
        text-align: left;
    }
    /* Policy page */
    .policy-page {
        padding: 40px 5%;
    }
    .policy-container {
        padding: 30px 20px;
    }
    .policy-container h1 {
        font-size: 30px;
    }
    .policy-section h2 {
        font-size: 22px;
    }
    .policy-section h3 {
        font-size: 17px;
    }
    .policy-section p,
    .policy-section ul li {
        font-size: 15px;
    }
    /* Product detail page */
    .product-page {
        width: 92%;
        margin-top: 20px;
    }
    .product-layout {
        grid-template-columns: 1fr;
    }
    .product-image {
        height: min(80vw, 360px);
        min-height: 260px;
        padding: 16px;
    }
    .product-info h1 {
        font-size: 2rem;
    }
    /* Reviews */
    .reviews-heading {
        align-items: flex-start;
        flex-wrap: wrap;
    }
    .reviews-count {
        white-space: normal;
    }
    /* Review modal */
    .product-review-dialog {
        width: 100%;
        max-height: 85vh;
        padding: 20px;
    }
    /* Toasts */
    .toast,
    .toast-error {
        left: 16px;
        right: 16px;
        width: auto;
        text-align: center;
    }
}
/* =========================================================
   18. HOMEPAGE MOBILE LAYOUT
   Scoped only to index.html (body.home-page)
========================================================= */
@media (max-width: 768px) {
    /* Prevent horizontal overflow on homepage */
    body.home-page {
        width: 100%;
        max-width: 100%;
        overflow-x: hidden;
    }
    /* Homepage hero */
    body.home-page .home-hero {
        padding: 16px 20px !important;
    }
    body.home-page .home-hero h1 {
        font-size: 27px !important;
        line-height: 1.22 !important;
    }
    body.home-page .home-hero p {
        font-size: 15px !important;
        line-height: 1.55 !important;
    }
    /* Homepage products section */
    body.home-page .products {
        padding: 34px 20px !important;
    }
    body.home-page .products h2 {
        margin-bottom: 22px !important;
        font-size: 28px !important;
    }
    /* Homepage filter and sort toolbar */
    body.home-page .products-toolbar {
        display: flex !important;
        flex-direction: row !important;
        justify-content: space-between !important;
        align-items: center !important;
        flex-wrap: nowrap !important;
        width: 100% !important;
        gap: 10px !important;
        margin-bottom: 26px;
    }
    body.home-page .toolbar-left,
    body.home-page .toolbar-right {
        display: flex !important;
        flex-direction: row !important;
        align-items: center !important;
        flex-wrap: nowrap !important;
        width: auto !important;
        min-width: 0;
        gap: 6px !important;
    }
    body.home-page .products-toolbar select {
        width: 125px !important;
        min-width: 125px !important;
        max-width: 125px !important;
    }
    /* Hide product search on mobile homepage */
    body.home-page #productSearch {
        display: none !important;
    }
    /* Two products per row on mobile homepage */
    body.home-page .product-grid {
        display: grid !important;
        grid-template-columns: repeat(2, minmax(0, 1fr)) !important;
        width: 100% !important;
        gap: 12px !important;
    }
    body.home-page .product-card {
        width: 100% !important;
        max-width: none !important;
        min-width: 0;
        margin: 0 !important;
        padding: 8px !important;
    }
    body.home-page .product-card img {
        width: 100% !important;
        height: auto !important;
        aspect-ratio: 1 / 1;
        object-fit: cover;
    }
    body.home-page .product-card button,
    body.home-page .add-to-cart-button {
        width: 100%;
        min-height: 46px;
        margin-top: auto;
        padding: 8px 4px !important;
        font-size: 12px !important;
    }
    /* Homepage why choose us */
    body.home-page .why-choose-us {
        padding: 30px 20px;
    }
    body.home-page .why-grid {
        grid-template-columns: 1fr !important;
        gap: 12px;
    }
    /* Homepage footer */
    body.home-page footer {
        padding: 40px 20px 20px;
    }
    body.home-page footer .footer-container {
        grid-template-columns: 1fr !important;
        gap: 28px;
    }
    body.home-page footer .footer-column,
    body.home-page .footer-column:nth-child(1),
    body.home-page .footer-column:nth-child(2),
    body.home-page .footer-column:nth-child(3) {
        justify-self: stretch !important;
        text-align: center !important;
    }
    body.home-page .social-icons {
        justify-content: center;
    }
    /* Homepage cart toast */
    body.home-page .cart-toast {
        left: 16px;
        right: 16px;
        bottom: 18px;
        width: auto;
        text-align: center;
    }
}
/* =========================================================
   19. SHARED MOBILE NAVIGATION
   Requires .mobile-menu-button and a nav inside header.
   JavaScript must toggle the .mobile-open class on nav.
========================================================= */
@media (max-width: 768px) {
    /* One-row mobile header */
    header:has(.mobile-menu-button) {
        position: relative !important;
        display: flex !important;
        flex-direction: row !important;
        justify-content: space-between !important;
        align-items: center !important;
        gap: 12px !important;
        width: 100% !important;
        height: 72px !important;
        min-height: 72px !important;
        padding: 0 16px !important;
        z-index: 1000;
    }
    header:has(.mobile-menu-button) .logo {
        display: flex !important;
        align-items: center !important;
        height: 72px !important;
        min-width: 0;
    }
    header:has(.mobile-menu-button) .logo a {
        display: flex !important;
        align-items: center !important;
        height: 100% !important;
    }
    header:has(.mobile-menu-button) .logo img {
        display: block;
        width: auto !important;
        height: 64px !important;
        max-width: min(165px, calc(100vw - 100px)) !important;
        object-fit: contain;
    }
    /* Show hamburger only on mobile */
    header:has(.mobile-menu-button) .mobile-menu-button {
        position: absolute !important;
        top: 50% !important;
        right: 16px !important;
        display: flex !important;
        justify-content: center !important;
        align-items: center !important;
        flex: 0 0 42px !important;
        width: 42px !important;
        height: 42px !important;
        padding: 0 !important;
        border: 0 !important;
        border-radius: 10px !important;
        background: #1e3a8a !important;
        color: #ffffff !important;
        font-size: 20px !important;
        line-height: 1 !important;
        cursor: pointer;
        transform: translateY(-50%) !important;
        -webkit-tap-highlight-color: transparent;
    }
    header:has(.mobile-menu-button) .mobile-menu-button:focus-visible {
        outline: 3px solid rgba(37, 99, 235, 0.45);
        outline-offset: 3px;
    }
    /* Mobile navigation: closed state */
    header:has(.mobile-menu-button) nav {
        position: absolute !important;
        top: calc(100% + 8px) !important;
        left: auto !important;
        right: 16px !important;
        display: block !important;
        width: 220px !important;
        max-width: calc(100vw - 32px) !important;
        max-height: calc(100vh - 100px) !important;
        max-height: calc(100dvh - 100px) !important;
        margin: 0 !important;
        padding: 0 !important;
        overflow-x: hidden !important;
        overflow-y: auto !important;
        box-sizing: border-box !important;
        background: #ffffff !important;
        border: 1px solid rgba(0, 0, 0, 0.08);
        border-radius: 10px;
        box-shadow: 0 8px 24px rgba(0, 0, 0, 0.16);
        z-index: 1001;
        visibility: hidden;
        opacity: 0;
        pointer-events: none;
        transform: translate3d(0, -10px, 0) scale(0.98);
        transform-origin: top right;
        transition:
            opacity 0.22s ease,
            transform 0.22s ease,
            visibility 0s linear 0.22s;
    }
    /* Mobile navigation: open state */
    header:has(.mobile-menu-button) nav.mobile-open {
        visibility: visible;
        opacity: 1;
        pointer-events: auto;
        transform: translate3d(0, 0, 0) scale(1);
        transition:
            opacity 0.22s ease,
            transform 0.22s ease,
            visibility 0s;
    }
    header:has(.mobile-menu-button) nav ul {
        display: flex !important;
        flex-direction: column !important;
        align-items: stretch !important;
        width: 100% !important;
        margin: 0 !important;
        padding: 7px 0 !important;
        gap: 0 !important;
        list-style: none !important;
        text-align: left !important;
    }
    header:has(.mobile-menu-button) nav ul > li {
        display: block !important;
        width: 100% !important;
        margin: 0 !important;
        padding: 0 !important;
    }
    header:has(.mobile-menu-button) nav ul > li > a {
        display: flex !important;
        justify-content: flex-start !important;
        align-items: center !important;
        width: 100% !important;
        min-height: 46px !important;
        padding: 10px 16px !important;
        border: 0 !important;
        border-radius: 0 !important;
        color: #111111 !important;
        font-size: 15px !important;
        font-weight: 700 !important;
        line-height: 1.35 !important;
        text-align: left !important;
        white-space: normal !important;
        transform: none !important;
        transition:
            background-color 0.18s ease,
            color 0.18s ease !important;
    }
    header:has(.mobile-menu-button) nav ul > li > a:hover,
    header:has(.mobile-menu-button) nav ul > li > a:focus-visible {
        background: #f3f5f8 !important;
        color: #ff6600 !important;
    }
    /* Mobile catalogue dropdown controls */
    .products-toolbar select,
    .category-filter-row select,
    #filterSelect,
    #sortSelect,
    #categorySelect {
        min-height: 44px;
        border-radius: 10px;
        -webkit-tap-highlight-color: transparent;
        touch-action: manipulation;
        transition:
            border-color 0.2s ease,
            box-shadow 0.2s ease,
            background-color 0.2s ease,
            transform 0.2s ease;
    }
    .products-toolbar select:focus,
    .category-filter-row select:focus,
    #filterSelect:focus,
    #sortSelect:focus,
    #categorySelect:focus {
        border-color: #2563eb !important;
        background-color: #ffffff;
        box-shadow: 0 0 0 3px rgba(37, 99, 235, 0.16);
        outline: none !important;
    }
    .products-toolbar select:active,
    .category-filter-row select:active,
    #filterSelect:active,
    #sortSelect:active,
    #categorySelect:active {
        transform: scale(0.995);
    }
}
/* =========================================================
   20. EXTRA SMALL MOBILE SCREENS
========================================================= */
@media (max-width: 400px) {
    body.home-page header {
        padding-left: 12px !important;
        padding-right: 12px !important;
    }
    body.home-page header .logo img {
        height: 60px !important;
        max-width: 150px;
    }
    body.home-page .home-hero {
        padding: 32px 16px !important;
    }
    body.home-page .home-hero h1 {
        font-size: 24px !important;
    }
    body.home-page .products {
        padding-left: 14px !important;
        padding-right: 14px !important;
    }
    /* Keep Filter and Sort compact */
    body.home-page .products-toolbar {
        gap: 4px !important;
    }
    body.home-page .toolbar-left,
    body.home-page .toolbar-right {
        gap: 4px !important;
    }
    body.home-page .products-toolbar span {
        font-size: 13px;
    }
    body.home-page .products-toolbar select {
        min-height: 44px !important;
        padding: 8px 6px !important;
        font-size: 13px !important;
    }
}
/* =========================================================
   21. MOBILE FILTER AND SORT - SIDE-BY-SIDE LAYOUT
========================================================= */
@media (max-width: 600px) {
    /* Two equal-width columns */
    body.home-page .products-toolbar {
        display: grid !important;
        grid-template-columns: repeat(2, minmax(0, 1fr)) !important;
        align-items: start !important;
        justify-content: stretch !important;
        width: 100% !important;
        gap: 10px !important;
        margin-bottom: 22px !important;
        padding-bottom: 16px !important;
    }
    /* Filter and Sort groups */
    body.home-page .toolbar-left,
    body.home-page .toolbar-right {
        display: flex !important;
        flex-direction: column !important;
        align-items: stretch !important;
        flex-wrap: nowrap !important;
        width: 100% !important;
        min-width: 0 !important;
        gap: 5px !important;
    }
    /* Filter and Sort labels */
    body.home-page .products-toolbar span {
        display: block !important;
        font-size: 13px !important;
        line-height: 1.3 !important;
        white-space: nowrap !important;
    }
    /* Filter and Sort dropdowns */
    body.home-page .products-toolbar select {
        display: block !important;
        width: 100% !important;
        min-width: 0 !important;
        max-width: 100% !important;
        min-height: 44px !important;
        padding: 8px 9px !important;
        font-size: 12px !important;
        box-sizing: border-box !important;
    }
    /* Hide search field on mobile */
    body.home-page #productSearch {
        display: none !important;
    }
    /* Category filter row */
    body.home-page .category-filter-row {
        display: grid !important;
        grid-template-columns: 72px minmax(0, 1fr) !important;
        align-items: center !important;
        width: 100% !important;
        gap: 8px !important;
        margin: -4px 0 22px !important;
    }
    body.home-page .category-filter-row label {
        font-size: 14px !important;
    }
    body.home-page .category-filter-row select {
        width: 100% !important;
        min-width: 0 !important;
        min-height: 44px !important;
        padding: 9px 11px !important;
        font-size: 14px !important;
    }
}
/* =========================================================
   22. ACCESSIBILITY - REDUCED MOTION
========================================================= */
@media (prefers-reduced-motion: reduce) {
    html {
        scroll-behavior: auto;
    }
    *,
    *::before,
    *::after {
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: 0.01ms !important;
    }
    header:has(.mobile-menu-button) nav,
    header:has(.mobile-menu-button) nav.mobile-open,
    .products-toolbar select,
    .category-filter-row select,
    #filterSelect,
    #sortSelect,
    #categorySelect {
        transition: none !important;
    }
}
