/* Shop do retro (shop.php). Tema escuro com dourado, combinando com o skin dark. */
#shop-page { font-family: Verdana, Arial, Helvetica, sans-serif; font-size: 12px; color: #ddd; }
#shop-page a { color: #f0c25a; }
#shop-page *, .shop-modal * { box-sizing: border-box; }

.shop-btn {
	display: inline-block; cursor: pointer; padding: 7px 12px; border-radius: 4px;
	border: 1px solid #5a5a5a; background: #3a3a3a; color: #eee !important;
	font: bold 12px Verdana, Arial, sans-serif; text-decoration: none; text-align: center;
	transition: background .15s, border-color .15s;
}
.shop-btn:hover { background: #4a4a4a; border-color: #777; }
.shop-btn:disabled { opacity: .55; cursor: not-allowed; }
.shop-btn-gold { background: linear-gradient(#d9a53a, #a8741a); border-color: #6b4a0d; color: #1b1203 !important; text-shadow: 0 1px 0 rgba(255,255,255,.25); }
.shop-btn-gold:hover { background: linear-gradient(#ebb84a, #b9821f); border-color: #8a5f12; }

/* topo: saldo */
.shop-head {
	display: flex; align-items: center; justify-content: space-between; gap: 10px; flex-wrap: wrap;
	padding: 10px 12px; margin-bottom: 10px; border: 1px solid #5c4513; border-radius: 6px;
	background: linear-gradient(135deg, #2c2416, #1d1d1d);
}
.shop-balance { display: flex; flex-direction: column; }
.shop-balance-label { color: #aaa; font-size: 11px; }
.shop-balance-value { color: #fff; font-size: 14px; }
.shop-balance-value b { color: #f0c25a; font-size: 18px; }

.shop-alert { padding: 8px 10px; margin: 0 0 10px; border-radius: 4px; border: 1px solid; line-height: 1.4; }
.shop-alert-info { background: #1f2a36; border-color: #36516e; color: #cfe3f7; }
.shop-alert-err { background: #3a1d1d; border-color: #7a3030; color: #ffc9c9; }
.shop-alert-ok { background: #1d3320; border-color: #2f6b36; color: #c9f5cd; }

/* abas */
.shop-tabs { display: flex; flex-wrap: wrap; gap: 4px; margin-bottom: 10px; border-bottom: 1px solid #4a4a4a; padding-bottom: 6px; }
.shop-tab {
	padding: 5px 9px; border-radius: 4px; background: #2e2e2e; border: 1px solid #444;
	color: #ccc !important; text-decoration: none; font-size: 11px; font-weight: bold;
}
.shop-tab:hover { border-color: #8a6a24; color: #fff !important; }
.shop-tab.active { background: #5c4513; border-color: #a8741a; color: #fff !important; }
.shop-tab-orders { margin-left: auto; }

.shop-search input {
	width: 100%; padding: 7px 10px; margin-bottom: 10px; border-radius: 4px;
	border: 1px solid #555; background: #1e1e1e; color: #eee; font: 12px Verdana, Arial, sans-serif;
}
.shop-search input:focus { outline: none; border-color: #a8741a; }

.shop-cat-title { margin: 6px 0 8px; padding: 0 0 4px; font: bold 14px Georgia, serif; color: #f0c25a; border-bottom: 1px dashed #4a3a18; height: auto; }
.shop-cat-title small { font: normal 11px Verdana, Arial, sans-serif; color: #999; margin-left: 6px; }

/* cards: 4 por linha; icone num "slot" estilo inventario do Tibia, preco em destaque com a moeda */
.shop-grid { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 7px; margin-bottom: 14px; }
.shop-card {
	position: relative; display: flex; flex-direction: column; align-items: center; text-align: center;
	padding: 10px 6px 7px; border-radius: 7px; cursor: pointer; outline: none;
	background: linear-gradient(180deg, #312c24 0%, #24221e 55%, #1d1c1a 100%); border: 1px solid #4a4233;
	box-shadow: inset 0 1px 0 rgba(255,255,255,.05);
	transition: transform .12s, border-color .12s, box-shadow .12s;
}
.shop-card:hover, .shop-card:focus { transform: translateY(-2px); border-color: #c8912a; box-shadow: 0 6px 16px rgba(0,0,0,.55), 0 0 0 1px rgba(240,194,90,.25), inset 0 1px 0 rgba(255,255,255,.06); }
.shop-card-img {
	width: 78px; height: 78px; display: flex; align-items: center; justify-content: center; margin-bottom: 7px;
	border-radius: 9px; border: 1px solid #3d3527;
	background: radial-gradient(circle at 50% 45%, rgba(240,194,90,.24), rgba(240,194,90,0) 62%), #171512;
	box-shadow: inset 0 0 10px rgba(0,0,0,.7);
	transition: box-shadow .15s;
}
.shop-card:hover .shop-card-img { box-shadow: inset 0 0 10px rgba(0,0,0,.7), 0 0 12px rgba(240,194,90,.3); }
.shop-card-img img { width: 64px; height: 64px; object-fit: contain; image-rendering: pixelated; }
.shop-card-title { font-weight: bold; color: #fff; font-size: 11px; line-height: 1.25; min-height: 28px; display: flex; align-items: center; justify-content: center; word-break: break-word; }
.shop-card-voc { display: inline-block; margin: 2px 0 0; padding: 1px 7px; border-radius: 9px; background: #2f2a44; color: #c8bdf5; font-size: 9px; }
.shop-card-save { margin-top: 3px; color: #8fe08f; font-size: 10px; font-weight: bold; }
.shop-card-price { display: flex; align-items: center; justify-content: center; gap: 5px; margin: 7px 0 8px; line-height: 1; }
.shop-card-price img { width: 20px; height: 20px; image-rendering: pixelated; }
.shop-card-price b { color: #ffcf55; font-size: 22px; text-shadow: 0 1px 0 #000, 0 0 8px rgba(255,190,60,.25); }
.shop-card-price s { color: #8a8a8a; font-size: 12px; }
.shop-card .shop-btn-buy { margin-top: auto; width: 100%; padding: 5px 2px; font-size: 11px; border-radius: 5px; }
.shop-card:hover .shop-btn-buy { background: linear-gradient(#d9a53a, #a8741a); color: #1b1203 !important; border-color: #6b4a0d; }

.shop-badge { position: absolute; top: 5px; left: 5px; padding: 2px 5px; border-radius: 3px; font-size: 9px; z-index: 1; font-weight: bold; text-transform: uppercase; letter-spacing: .3px; }
.shop-badge-novo { background: #1f6f3a; color: #fff; }
.shop-badge-popular { background: #7a2a8a; color: #fff; }
.shop-badge-oferta { background: #c0392b; color: #fff; }

.shop-empty { color: #999; text-align: center; padding: 20px 0; }
.shop-foot { color: #999; font-size: 11px; line-height: 1.5; border-top: 1px solid #3a3a3a; padding-top: 8px; margin-top: 4px; }

/* meus pedidos */
.shop-table { width: 100%; border-collapse: collapse; }
.shop-table th { background: #3a2f17; color: #f0c25a; text-align: left; padding: 6px; font-size: 11px; }
.shop-table td { padding: 6px; border-bottom: 1px solid #3a3a3a; vertical-align: top; }
.shop-table small { color: #999; }
.shop-st { display: inline-block; padding: 2px 6px; border-radius: 3px; font-size: 10px; font-weight: bold; white-space: nowrap; }
.shop-st-ok { background: #1d3320; color: #8fe08f; }
.shop-st-wait { background: #3a311a; color: #f0c25a; }
.shop-st-info { background: #1f2a36; color: #9cc3ea; }

/* modal */
html.shop-modal-open, html.shop-modal-open body { overflow: hidden; }
.shop-modal[hidden] { display: none; }
.shop-modal {
	position: fixed; inset: 0; z-index: 9999; display: flex; align-items: center; justify-content: center;
	padding: 16px; background: rgba(0,0,0,.72); text-align: left;
	font-family: Verdana, Arial, Helvetica, sans-serif; font-size: 12px; color: #ddd;
}
.shop-modal-box {
	position: relative; width: 100%; max-width: 440px; max-height: calc(100vh - 32px); overflow-y: auto;
	padding: 16px; border-radius: 8px; background: #222; border: 1px solid #a8741a; box-shadow: 0 10px 40px rgba(0,0,0,.7);
}
.shop-modal-x { position: absolute; top: 6px; right: 8px; background: none; border: 0; color: #aaa; font-size: 22px; cursor: pointer; line-height: 1; }
.shop-modal-x:hover { color: #fff; }
.sm-top { display: flex; gap: 12px; align-items: center; margin-bottom: 8px; }
.sm-top img { width: 84px; height: 84px; padding: 6px; object-fit: contain; image-rendering: pixelated; flex: none; border-radius: 8px; border: 1px solid #3d3527; background: radial-gradient(circle at 50% 45%, rgba(240,194,90,.24), rgba(240,194,90,0) 62%), #171512; box-shadow: inset 0 0 10px rgba(0,0,0,.7); }
.sm-title { font: bold 16px Georgia, serif; color: #fff; }
.sm-price { margin-top: 3px; color: #bbb; }
.sm-price { display: flex; align-items: center; gap: 5px; flex-wrap: wrap; }
.sm-price img { width: 20px; height: 20px; image-rendering: pixelated; }
.sm-price b { color: #ffcf55; font-size: 24px; text-shadow: 0 1px 0 #000; }
.sm-price s { color: #888; }
.sm-price small { color: #e88; }
.sm-desc { line-height: 1.5; color: #ccc; margin: 6px 0 10px; white-space: pre-line; }
.sm-pack-title { font-weight: bold; color: #f0c25a; margin-bottom: 4px; }
.sm-pack ul { margin: 0 0 6px; padding: 0; list-style: none; display: flex; flex-wrap: wrap; gap: 4px; }
.sm-pack li img { width: 20px; height: 20px; vertical-align: middle; margin: -3px 4px -3px -3px; image-rendering: pixelated; }
.sm-pack li { padding: 3px 8px; border-radius: 9px; background: #333; border: 1px solid #4a4a4a; font-size: 11px; }
.sm-pack li.link { cursor: pointer; }
.sm-pack li.link:hover { border-color: #a8741a; color: #fff; }
.sm-pack-save { color: #8fe08f; font-size: 11px; margin-bottom: 8px; }
#sm-form { display: block; border-top: 1px solid #3a3a3a; padding-top: 10px; }
.sm-row { margin-bottom: 8px; }
.sm-row label { display: block; margin-bottom: 6px; color: #aaa; font-size: 11px; }
.sm-row input, .sm-row select {
	display: block; width: 100%; margin-top: 3px; padding: 7px 8px; border-radius: 4px;
	border: 1px solid #555; background: #1a1a1a; color: #eee; font: 13px Verdana, Arial, sans-serif;
}
.sm-row input:focus, .sm-row select:focus { outline: none; border-color: #a8741a; }
.sm-row small { color: #999; }
.sm-calc { margin-bottom: 8px; color: #aaa; }
.sm-calc b { color: #fff; }
.sm-calc b.neg { color: #f66; }
.sm-actions { display: flex; gap: 8px; justify-content: flex-end; margin-top: 4px; }

/* celular (html.is-phone vem do header.inc.php) */
html.is-phone .shop-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 7px; }
html.is-phone .shop-card { padding: 10px 6px 8px; }
html.is-phone .shop-card-img { width: 80px; height: 80px; }
html.is-phone .shop-card-title { font-size: 12px; }
html.is-phone .shop-tab-orders { margin-left: 0; }
html.is-phone .shop-head .shop-btn { width: 100%; }
html.is-phone .shop-modal { align-items: flex-end; padding: 0; }
html.is-phone .shop-modal-box { max-width: none; border-radius: 12px 12px 0 0; max-height: 92vh; }
html.is-phone .sm-actions .shop-btn { flex: 1; padding: 10px; }

/* admin (adminshop.php) */
.sa .shop-table td { font-size: 11px; }
.sa-table img { image-rendering: pixelated; }
.sa-off td { opacity: .5; }
.sa-actions { white-space: nowrap; }
.sa-actions form { display: inline; }
.sa-actions .shop-btn, .sa-refund .shop-btn { padding: 3px 6px; font-size: 10px; }
.sa-form { display: block; margin-bottom: 12px; }
.sa-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 6px 10px; }
.sa-grid label, .sa-filter label { display: block; color: #aaa; font-size: 11px; }
.sa-grid input, .sa-grid select, .sa-grid textarea, .sa-filter input, .sa-filter select, .sa-refund input {
	display: block; width: 100%; margin-top: 2px; padding: 5px 6px; border-radius: 3px;
	border: 1px solid #555; background: #1a1a1a; color: #eee; font: 12px Verdana, Arial, sans-serif;
}
.sa-refund input { display: inline-block; width: auto; padding: 3px 4px; }
.sa-grid .sa-wide { grid-column: 1 / -1; }
.sa-grid .sa-check input { display: inline; width: auto; }
.sa-filter { display: flex; flex-wrap: wrap; gap: 6px; align-items: flex-end; margin-bottom: 10px; }
.sa-filter label { flex: 1 1 100px; }
.sa-stats { display: flex; gap: 8px; margin-bottom: 10px; }
.sa-stats div { flex: 1; padding: 8px; text-align: center; border-radius: 5px; background: #2a2416; border: 1px solid #5c4513; }
.sa-stats b { display: block; font-size: 18px; color: #f0c25a; }
.sa-stats span { font-size: 10px; color: #aaa; }
html.is-phone .sa-grid { grid-template-columns: 1fr; }
