:root {
  --bg: #eaeded; --surface: #ffffff; --ink: #0f1111; --muted: #565959; --line: #d5d9d9; --link: #007185;
  --nav: #131a22; --nav2: #232f3e; --nav-hover: #ffffff; --orange: #ff9900; --yellow: #ffd814; --yellow-b: #fcd200;
  --orange-btn: #ffa41c; --orange-b: #ff8f00; --green: #007600; --red: #b12704; --star: #de7921;
}
* { box-sizing: border-box; }
[hidden] { display: none !important; }
html { scroll-behavior: smooth; }
body { margin: 0; background: var(--bg); color: var(--ink); font: 14px/1.45 "Amazon Ember", Arial, sans-serif; min-width: 1100px; }
a { color: var(--link); text-decoration: none; }
a:hover { color: #c7511f; text-decoration: underline; }
h1 { font-size: 28px; font-weight: 400; margin: 0 0 10px; }
h2 { font-size: 21px; font-weight: 700; margin: 0 0 12px; }
h3 { font-size: 17px; font-weight: 700; margin: 0 0 8px; }
hr { border: 0; border-top: 1px solid var(--line); margin: 12px 0; }
.muted { color: var(--muted); }
.small { font-size: 12px; }
.green { color: var(--green); }
.btn { display: inline-block; border: 1px solid transparent; border-radius: 8px; padding: 8px 14px; font: inherit; font-size: 13px; cursor: pointer; text-align: center; color: var(--ink); box-shadow: 0 2px 5px rgba(213,217,217,.5); }
.btn.yellow { background: var(--yellow); border-color: var(--yellow-b); }
.btn.yellow:hover { background: #f7ca00; text-decoration: none; }
.btn.orange { background: var(--orange-btn); border-color: var(--orange-b); }
.btn.orange:hover { background: #fa8900; text-decoration: none; }
.btn.white { background: #fff; border-color: var(--line); }
.btn.white:hover { background: #f7fafa; text-decoration: none; color: var(--ink); }
.btn.wide { display: block; width: 100%; margin-top: 8px; border-radius: 20px; }
.btn:disabled { opacity: .6; cursor: default; }
.link, .link-btn { border: 0; background: none; color: var(--link); font: inherit; cursor: pointer; padding: 0; }
.link:hover { color: #c7511f; text-decoration: underline; }

/* Header */
.nav { color: #fff; }
.nav-main { display: flex; align-items: center; gap: 8px; padding: 6px 16px; background: var(--nav); height: 60px; min-width: 0; }
.logo { display: flex; flex-direction: column; align-items: flex-start; padding: 4px 8px; border: 1px solid transparent; border-radius: 2px; color: #fff; }
.logo:hover { border-color: #fff; text-decoration: none; }
.logo-text { font-size: 22px; font-weight: 700; letter-spacing: -.5px; line-height: 1; }
.logo-dot { color: var(--orange); }
.logo-swoosh { width: 74px; height: 8px; margin-top: 1px; border-bottom: 3px solid var(--orange); border-radius: 0 0 60% 60% / 0 0 100% 100%; }
.nav-block { display: flex; flex-direction: column; padding: 6px 8px; border: 1px solid transparent; border-radius: 2px; color: #fff; line-height: 1.15; white-space: nowrap; }
.nav-block:hover { border-color: #fff; text-decoration: none; color: #fff; }
.nav-small { font-size: 12px; color: #ccc; }
.nav-bold { font-size: 14px; font-weight: 700; }
.search { display: flex; flex: 1 1 200px; min-width: 0; height: 40px; border-radius: 4px; overflow: hidden; margin: 0 8px; }
.search-cat { display: grid; place-items: center; background: #e6e6e6; color: #555; padding: 0 10px; font-size: 12px; border-right: 1px solid #ccc; }
.search input { flex: 1; min-width: 0; width: 100%; border: 0; padding: 0 10px; font: inherit; font-size: 15px; }
.search button { border: 0; background: #febd69; width: 45px; font-size: 18px; cursor: pointer; }
.search button:hover { background: #f3a847; }
.search:focus-within { outline: 3px solid var(--orange); }
.nav-right { display: flex; align-items: center; flex-shrink: 0; }
.cart { flex-direction: row; align-items: flex-end; gap: 2px; }
.cart-icon { position: relative; font-size: 26px; line-height: 1; }
.cart-count { position: absolute; top: -6px; left: 14px; color: #f08804; font-weight: 700; font-size: 15px; background: var(--nav); padding: 0 3px; border-radius: 6px; }
.nav-sub { display: flex; align-items: center; gap: 2px; padding: 0 10px; background: var(--nav2); height: 39px; font-size: 14px; }
.nav-sub a, .nav-sub .link-btn { color: #fff; padding: 6px 9px; border: 1px solid transparent; border-radius: 2px; font-size: 14px; }
.nav-sub a:hover, .nav-sub .link-btn:hover { border-color: #fff; text-decoration: none; }
.nav-sub .all { font-weight: 700; }
.nav-promo { margin-left: auto; color: #ffd814; font-weight: 700; padding-right: 8px; }

/* Home */
.page { max-width: 1500px; margin: 0 auto; padding: 0 20px 40px; }
.hero { margin: 0 -20px 0; height: 320px; background: linear-gradient(100deg, #1b2a41 0%, #3b2a2a 55%, #c2410c 100%); display: flex; align-items: flex-start; padding: 36px 60px 0; color: #fff; }
.hero-text h1 { font-size: 40px; font-weight: 700; margin-bottom: 6px; }
.hero-text p { font-size: 18px; margin: 0 0 18px; color: #f3e7dd; }
.tiles { display: grid; grid-template-columns: repeat(6, 1fr); gap: 16px; margin-top: -120px; position: relative; }
.tile-card { background: var(--surface); padding: 20px; color: var(--ink); display: flex; flex-direction: column; gap: 10px; box-shadow: 0 1px 3px rgba(0,0,0,.15); }
.tile-card:hover { text-decoration: none; }
.tile-card h3 { font-size: 18px; }
.tile-card img { width: 100%; aspect-ratio: 4 / 3; object-fit: cover; border-radius: 4px; }
.tile-card span { color: var(--link); font-size: 13px; }
.section-title { margin: 30px 0 12px; }
.results-bar { padding: 10px 0; font-size: 14px; }
.grid { display: grid; grid-template-columns: repeat(5, 1fr); gap: 16px; }
.card { background: var(--surface); border: 1px solid #e3e6e6; border-radius: 4px; overflow: hidden; display: flex; flex-direction: column; }
.card-img img { width: 100%; display: block; aspect-ratio: 4 / 3; background: #f7f7f7; }
.card-body { padding: 12px 14px 14px; display: flex; flex-direction: column; gap: 4px; }
.card-title { color: var(--ink); font-size: 15px; line-height: 1.3; }
.card-title:hover { color: #c7511f; }
.rating { display: flex; align-items: center; gap: 6px; font-size: 13px; }
.stars { font-size: 16px; letter-spacing: 1px; background: linear-gradient(90deg, var(--star) calc(var(--r) * 20%), #d9d9d9 0); -webkit-background-clip: text; background-clip: text; color: transparent; }
.count { color: var(--link); }
.price { font-size: 21px; font-weight: 500; }
.price.big { font-size: 28px; color: var(--red); }
.delivery { font-size: 12px; color: var(--ink); }
.oos { color: var(--red); font-size: 13px; }
.instock { color: var(--green); font-size: 18px; }

/* Product detail */
.crumbs { color: var(--muted); padding: 12px 0; font-size: 13px; }
.detail { display: grid; grid-template-columns: 520px 1fr 260px; gap: 28px; background: var(--surface); padding: 20px; border-radius: 4px; }
.detail-img img { width: 100%; border-radius: 4px; border: 1px solid #eee; }
.detail-info h1 { font-size: 24px; line-height: 1.3; }
.brand { font-size: 13px; }
.features { padding-left: 18px; margin: 0; }
.features li { margin-bottom: 4px; }
.buybox { border: 1px solid var(--line); border-radius: 8px; padding: 16px; display: flex; flex-direction: column; gap: 8px; align-self: start; }
.qty select { padding: 5px 8px; border: 1px solid var(--line); border-radius: 8px; background: #f0f2f2; font: inherit; }
.meta { font-size: 12px; margin-top: 8px; border-collapse: collapse; }
.meta td { padding: 2px 8px 2px 0; color: var(--muted); }
.meta td + td { color: var(--ink); }

/* Sign in */
.signin { max-width: 380px; margin: 30px auto; text-align: center; }
.signin-logo { font-size: 30px; font-weight: 700; margin-bottom: 14px; }
.signin-logo span { color: #c2410c; }
.signin-card { background: var(--surface); border: 1px solid var(--line); border-radius: 8px; padding: 20px 26px; text-align: left; }
.signin-card form { display: flex; flex-direction: column; gap: 12px; }
.signin-demo { margin-top: 18px; font-size: 13px; }
label { display: flex; flex-direction: column; gap: 4px; font-size: 13px; font-weight: 700; }
label input, label textarea { padding: 8px 10px; border: 1px solid #a6a6a6; border-radius: 4px; font: inherit; font-weight: 400; box-shadow: inset 0 1px 2px rgba(15,17,17,.15); }
label input:focus, label textarea:focus { outline: 0; border-color: #e77600; box-shadow: 0 0 0 3px #c8f3fa; }
.error { color: var(--red); margin: 0; }

/* Cart */
.cart-layout { display: grid; grid-template-columns: 1fr 300px; gap: 20px; margin-top: 16px; }
.cart-list { background: var(--surface); padding: 20px; }
.cart-head { text-align: right; color: var(--muted); font-size: 13px; border-bottom: 1px solid var(--line); padding-bottom: 4px; }
.cart-item { display: grid; grid-template-columns: 180px 1fr 110px; gap: 16px; padding: 14px 0; border-bottom: 1px solid var(--line); }
.cart-item img { width: 180px; border-radius: 4px; }
.cart-item-info { display: flex; flex-direction: column; gap: 4px; }
.cart-item-info .card-title { font-size: 18px; }
.cart-actions { display: flex; gap: 14px; align-items: center; margin-top: 6px; font-size: 13px; }
.cart-actions label { flex-direction: row; align-items: center; gap: 6px; font-weight: 400; }
.cart-actions select { padding: 4px 8px; border-radius: 8px; border: 1px solid var(--line); background: #f0f2f2; }
.cart-item-price { text-align: right; font-size: 18px; font-weight: 700; }
.cart-subtotal { text-align: right; font-size: 18px; padding: 12px 0; }
.checkout-box { background: var(--surface); padding: 20px; align-self: start; display: flex; flex-direction: column; gap: 10px; }
.checkout-box .cart-subtotal { text-align: left; padding: 0; }
.checkout-box form { display: flex; flex-direction: column; gap: 10px; }

/* Orders */
.order-card { background: var(--surface); border: 1px solid var(--line); border-radius: 8px; margin: 14px 0; overflow: hidden; }
.order-head { display: flex; gap: 40px; padding: 14px 20px; background: #f0f2f2; border-bottom: 1px solid var(--line); font-size: 12px; }
.order-head > div { display: flex; flex-direction: column; gap: 2px; }
.order-head .lab { color: var(--muted); text-transform: uppercase; font-size: 11px; }
.order-num { margin-left: auto; align-items: flex-end; }
.order-body { display: grid; grid-template-columns: 1fr 220px; gap: 20px; padding: 16px 20px; }
.order-body.block { display: block; }
.order-status { font-size: 18px; }
.order-status.cancelled { color: var(--red); }
.refund-note { font-size: 13px; margin-bottom: 8px; }
.refund-note.refunded { color: var(--green); }
.refund-note.pending_approval { color: #b7791f; }
.order-items { display: flex; flex-direction: column; gap: 10px; }
.order-item { display: flex; gap: 14px; align-items: center; }
.order-item img { width: 90px; border-radius: 4px; border: 1px solid #eee; }
.order-buttons { display: flex; flex-direction: column; gap: 8px; }
.order-buttons .btn { border-radius: 20px; }
.order-summary { display: grid; grid-template-columns: 1fr 1fr 1fr; gap: 20px; background: var(--surface); border: 1px solid var(--line); border-radius: 8px; padding: 16px 20px; margin-top: 12px; font-size: 13px; }
.order-summary h4 { margin: 0 0 6px; font-size: 14px; }
.summary { border-collapse: collapse; width: 100%; }
.summary td { padding: 2px 0; }
.summary td + td { text-align: right; }
.summary .total td { font-weight: 700; border-top: 1px solid var(--line); padding-top: 6px; }
.summary .refund td { color: var(--green); }
.summary .pending td { color: #b7791f; }
.table { width: 100%; border-collapse: collapse; }
.table th, .table td { text-align: left; padding: 8px 10px; border-bottom: 1px solid var(--line); font-size: 13px; }
.table thead th { background: #f0f2f2; color: var(--muted); font-size: 12px; }
.status { display: inline-block; padding: 2px 10px; border-radius: 12px; font-size: 12px; font-weight: 700; background: #eee; color: var(--muted); text-transform: capitalize; }
.status.refunded { background: #dff5e8; color: var(--green); }
.status.pending_approval { background: #fbf0d9; color: #b7791f; }

/* Footer */
.footer { background: var(--nav2); color: #ddd; margin-top: 40px; }
.back-top { display: block; background: #37475a; color: #fff; text-align: center; padding: 14px; font-size: 13px; }
.back-top:hover { background: #485769; text-decoration: none; color: #fff; }
.footer-cols { display: flex; justify-content: center; gap: 100px; padding: 40px 0 20px; }
.footer-cols h4 { color: #fff; margin: 0 0 8px; font-size: 16px; }
.footer-cols a { display: block; color: #ddd; font-size: 14px; margin-bottom: 6px; }
.footer-note { text-align: center; font-size: 12px; color: #999; padding: 16px; margin: 0; background: var(--nav); }

/* Support drawer */
.support-toggle { position: fixed; right: 28px; bottom: 28px; border: 0; background: var(--nav2); color: #fff; padding: 12px 18px; border-radius: 999px; font: inherit; font-weight: 700; cursor: pointer; box-shadow: 0 6px 20px rgba(0,0,0,.25); z-index: 20; }
.support-drawer { position: fixed; right: 28px; bottom: 28px; width: 420px; height: 600px; background: var(--surface); border: 1px solid var(--line); border-radius: 14px; display: flex; flex-direction: column; box-shadow: 0 16px 40px rgba(0,0,0,.25); z-index: 30; }
.support-head { display: flex; justify-content: space-between; align-items: center; padding: 14px 16px; border-bottom: 1px solid var(--line); background: var(--nav2); color: #fff; border-radius: 14px 14px 0 0; }
.support-head .muted { color: #ccc; }
.support-head .link { color: #fff; margin-left: 12px; }
.support-head .close { font-size: 20px; }
.support-log { flex: 1; overflow-y: auto; padding: 14px 16px; display: flex; flex-direction: column; gap: 10px; }
.msg { max-width: 88%; padding: 9px 12px; border-radius: 12px; white-space: pre-wrap; font-size: 14px; }
.msg.customer { align-self: flex-end; background: #232f3e; color: #fff; }
.msg.agent { align-self: flex-start; background: #f0f2f2; }
.msg.system { align-self: center; color: var(--muted); font-size: 12px; background: none; }
.support-form { display: flex; gap: 8px; padding: 12px; border-top: 1px solid var(--line); }
.support-form textarea { flex: 1; resize: none; padding: 8px 10px; border: 1px solid var(--line); border-radius: 8px; font: inherit; }
.support-form button { border: 0; background: var(--yellow); padding: 0 16px; border-radius: 8px; font: inherit; font-weight: 700; cursor: pointer; }
.support-form button:disabled { background: #eee; }
