/* rejoy：在 3.0 預設主題（Bootstrap 3）之上重現原站（OpenCart 1.5 default 主題改版）的外觀。
   顏色、字級取自原站 stylesheet.css；桌機內容寬 980px，手機沿用 Bootstrap 的自適應版面。 */

/* ---- 基本 ---- */
body {
	font-family: Arial, Helvetica, "Microsoft JhengHei", "PingFang TC", sans-serif;
	font-size: 12px;
	color: #000;
	background: #fff;
}
h1, h2, h3, h4, h5, h6 { font-family: Arial, Helvetica, "Microsoft JhengHei", "PingFang TC", sans-serif; color: #000; }
h1 { font-size: 32px; font-weight: normal; color: #636E75; margin: 0 0 20px; }
h2 { font-size: 16px; }
a, a:visited, a b { color: #38B0E3; }
a:hover, a:focus { color: #1a8fc4; }
@media (min-width: 1200px) { .container { width: 1010px; } }
@media (min-width: 992px) and (max-width: 1199px) { .container { width: 1010px; } }

/* ---- header ---- */
#rj-header { padding: 12px 0 6px; background: #fff; }
#rj-header #logo { margin: 8px 0 0 10px; }
#rj-header #logo img { max-height: 90px; }
.rj-header-tools { display: flex; justify-content: flex-end; align-items: flex-start; gap: 16px; }
.rj-cart { border-right: 1px solid #eee; padding-right: 16px; min-width: 120px; }
.rj-search { width: 300px; max-width: 100%; }

#cart { display: block; margin: 0; }
#cart .rj-cart-heading { font-size: 14px; font-weight: bold; color: #333; margin: 4px 0 2px; }
#cart > .btn { color: #38B0E3; padding: 0; font-size: 12px; background: none; border: 0; box-shadow: none; text-decoration: none; }
#cart > .btn .caret { color: #999; }
#cart .dropdown-menu { min-width: 360px; z-index: 1001; }
#cart .dropdown-menu table { margin-bottom: 10px; }

#search { margin: 0 0 6px; }
#search .form-control { height: 26px; padding: 3px 6px; font-size: 12px; border-color: #ccc; border-radius: 0 3px 3px 0; box-shadow: none; }
#search .btn { height: 26px; padding: 0 8px; font-size: 12px; border-color: #ccc; border-radius: 3px 0 0 3px; background: #fff; color: #333; }
#welcome { color: #999; font-size: 12px; text-align: left; }
#welcome a { text-decoration: underline; }

.rj-links { text-align: right; margin-top: 18px; padding-right: 10px; font-size: 12px; }
.rj-links a { display: inline-block; padding: 0 6px; border-left: 1px solid #ddd; text-decoration: none; }
.rj-links a:first-child { border-left: 0; }

/* ---- 選單（原站 #menu：白底、字 15px #3D2C2C；滑過 #4EDFF8；子選單滑過 #A5D9EC） ---- */
#menu.rj-menu {
	background: #fff;
	background-image: none;
	border: 0;
	border-radius: 5px;
	box-shadow: 0 2px 2px rgba(0, 0, 0, 0.2);
	min-height: 37px;
	padding: 0;
	margin-bottom: 14px;
	filter: none;
}
#menu.rj-menu .nav > li > a {
	color: #3D2C2C;
	font-size: 15px;
	font-weight: normal;
	line-height: 25px;
	padding: 6px 30px;
	text-shadow: none;
	background: transparent;
}
#menu.rj-menu .nav > li > a:hover,
#menu.rj-menu .nav > li.open > a,
#menu.rj-menu .nav > li:hover > a { background: #4EDFF8; color: #3D2C2C; }
#menu.rj-menu .dropdown-menu { padding: 4px 0; border-radius: 0 0 5px 5px; background: #fff; box-shadow: 0 4px 8px rgba(0, 0, 0, 0.15); }
#menu.rj-menu .dropdown-inner { display: table; }
#menu.rj-menu .dropdown-inner ul { display: table-cell; }
#menu.rj-menu .dropdown-inner a { min-width: 180px; display: block; padding: 6px 15px; color: #3D2C2C; font-size: 13px; }
#menu.rj-menu .dropdown-inner li a:hover { background: #A5D9EC; color: #000; }
@media (min-width: 768px) {
	#menu.rj-menu .nav { width: 100%; display: flex; }
	#menu.rj-menu .nav > li { flex: 1 1 auto; }
	#menu.rj-menu .nav > li > a { text-align: left; }
	#menu.rj-menu:not(.rj-js) .dropdown:hover > .dropdown-menu { display: block; } /* 有 JS 時由 menu.twig 以 slideDown 展開 */
}
@media (max-width: 767px) {
	#menu.rj-menu { background: #4EDFF8; }
	#menu.rj-menu #category { color: #3D2C2C; font-size: 15px; line-height: 40px; padding-left: 12px; text-shadow: none; }
	#menu.rj-menu .btn-navbar { background: #fff; border-color: #ccc; color: #3D2C2C; }
	#menu.rj-menu .nav > li > a { padding: 8px 15px; }
	#menu.rj-menu .dropdown-menu { display: block; position: static; float: none; box-shadow: none; background: transparent; }
	#menu.rj-menu .dropdown-inner { display: block; }
	#menu.rj-menu .dropdown-inner ul { display: block; }
	#menu.rj-menu .dropdown-inner a { padding-left: 30px; }
	.rj-header-tools { flex-direction: column; align-items: stretch; }
	.rj-cart { border-right: 0; }
	.rj-search { width: auto; }
	.rj-links { text-align: left; margin-top: 8px; }
}

/* ---- 方框（原站 .box：圓角、淺灰標題列） ---- */
.rj-box { border: 1px solid #DBDEE1; border-radius: 7px; margin-bottom: 20px; background: #fff; }
.rj-box > .rj-box-heading {
	border-bottom: 1px solid #DBDEE1;
	border-radius: 7px 7px 0 0;
	padding: 6px 10px;
	font-size: 14px;
	font-weight: bold;
	color: #333;
	background: linear-gradient(#FFFFFF, #F3F3F3);
	margin: 0;
}
.rj-box > .rj-box-content { padding: 10px; }

/* ---- 按鈕（原站 .button：藍底白字圓角） ---- */
.btn-primary, .rj-button {
	background: linear-gradient(#36B6E8, #1599D0);
	border: 0;
	border-radius: 7px;
	color: #fff !important;
	font-weight: bold;
	font-size: 12px;
	text-shadow: none;
	box-shadow: 0 2px 2px #ddd;
	padding: 6px 12px;
}
.btn-primary:hover, .btn-primary:focus, .rj-button:hover { background: #1599D0; color: #fff; }

/* ---- 價格（原站：特價時原價紅色刪除線） ---- */
.price-old, .product-thumb .price-old, .rj-product .price-old, .rj-featured .price-old { color: #F00; text-decoration: line-through; font-weight: normal; margin-left: 0; }
.price-new { font-weight: bold; }
.price { font-weight: bold; color: #333; }

/* ---- 麵包屑 ---- */
.breadcrumb { background: none; border: 0; padding: 4px 0; margin: 0 0 10px; font-size: 12px; }
.breadcrumb > li { text-shadow: none; padding: 0 6px 0 0; }
.breadcrumb > li:after { content: none; }
.breadcrumb > li + li:before { content: "> "; color: #999; padding: 0 4px 0 0; }
.breadcrumb a { text-decoration: underline; }

/* ---- footer（原站：淺灰底、連結以直線分隔、右側版權） ---- */
#rj-footer { margin-top: 30px; padding: 0; background: none; border: 0; color: #000; } /* 覆寫 3.0 預設的深色 footer */
#rj-footer .rj-footer-inner {
	background: #F8F8F8;
	border-top: 1px solid #ddd;
	border-bottom: 1px solid #ddd;
	padding: 28px 60px;
	display: flex;
	justify-content: space-between;
	align-items: center;
	flex-wrap: wrap;
	gap: 10px;
}
.rj-footer-links { list-style: none; margin: 0; padding: 0; }
.rj-footer-links li { display: inline-block; margin-right: 6px; padding-right: 10px; border-right: 1px solid #000; line-height: 14px; }
.rj-footer-links li.last { border-right: 0; }
#rj-footer .rj-footer-links a, #rj-footer .rj-footer-links a:visited { color: #38B0E3; text-decoration: underline; } /* 3.0 預設 footer a 是 #ccc */
#powered { color: #000; }
@media (max-width: 767px) { #rj-footer .rj-footer-inner { padding: 18px 15px; } }

/* ---- 首頁輪播（原站：無外框、圓點右下） ---- */
.rj-slideshow.swiper-viewport { border: 0; box-shadow: none; margin: 0 0 20px; background: none; }
.rj-slideshow .swiper-pagination { position: absolute; bottom: 8px; right: 12px; left: auto; width: auto; text-align: right; z-index: 10; }
.rj-slideshow .swiper-pagination-bullet { background: #fff; border: 2px solid #333; opacity: .8; width: 10px; height: 10px; }
.rj-slideshow .swiper-pagination-bullet-active { background: #333; }

/* ---- 推薦商品（原站 .box.featured：一列小圖） ---- */
.rj-featured-viewport { overflow: hidden; }
.rj-featured-viewport.rj-featured-manual { overflow-x: auto; }
.rj-featured-list { display: flex; flex-wrap: nowrap; padding-bottom: 6px; }
/* 間距用 margin（不用 gap），走馬燈以 outerWidth(true) 計算每格寬度 */
.rj-featured-item { flex: 0 0 180px; margin-right: 12px; } /* 原站每格 180px＋左右 6px＝192px，5 個剛好一列 */
.rj-featured-item .image { border: 1px solid #E7E7E7; padding: 3px; margin-bottom: 4px; text-align: center; }
.rj-featured-item .image img { margin: 0 auto; }
.rj-featured-item .name { font-weight: bold; margin-bottom: 4px; }
.rj-featured-item .name a { text-decoration: none; }
.rj-featured-item .price { margin-bottom: 6px; }
.rj-featured-item .rj-button { padding: 3px 10px; }

/* ---- 分類頁（原站：banner 全寬、左欄方框、圖文列表） ---- */
#content_description { margin: 0 0 20px; }
#content_description img { max-width: 100%; height: auto; }
#column-left .rj-category-box .list-group { margin: 0; padding: 0 0 6px; border: 0; }
#column-left .list-group-item { border: 0; border-bottom: 1px solid #EEE; margin: 0 8px; padding: 8px 2px; color: #333; background: none; border-radius: 0; }
#column-left .list-group-item.active, #column-left .list-group-item.active:hover { background: none; color: #000; font-weight: bold; text-shadow: none; }
#column-left .list-group-item:hover { color: #38B0E3; background: none; }
.rj-category-list { list-style: none; padding: 0; margin: 0 0 15px; display: flex; flex-wrap: wrap; gap: 10px 20px; }
.rj-category-list li { width: 90px; text-align: center; }
.rj-category-list .image { margin-bottom: 4px; }
.rj-product-filter { display: flex; justify-content: space-between; align-items: center; flex-wrap: wrap; gap: 8px; padding: 0 0 6px; border-bottom: 1px solid #E5E5E5; margin: 20px 0 6px; }
.rj-product-filter b, .rj-product-filter label { font-weight: bold; margin: 0 4px 0 12px; }
.rj-product-filter select { font-size: 12px; padding: 1px 2px; }
.rj-display a { cursor: pointer; }
.rj-compare { margin: 0 0 20px; font-weight: bold; }
.rj-product { border: 0; margin-bottom: 18px; }
.product-list .rj-product { display: flex; gap: 10px; padding-bottom: 18px; border-bottom: 1px solid #E5E5E5; }
.product-list .rj-product .image { flex: 0 0 236px; border: 1px solid #E7E7E7; padding: 10px; margin: 0; text-align: center; }
.product-list .rj-product-body { flex: 1; display: flex; gap: 10px; }
.product-list .rj-product .caption { flex: 1; padding: 0; min-height: 0; margin: 0; }
.rj-product .caption h4 { font-size: 12px; font-weight: bold; margin: 0 0 4px; }
.rj-product .caption h4 a { text-decoration: none; }
.rj-product .caption p { font-size: 12px; color: #333; }
.product-list .rj-product-side { flex: 0 0 190px; display: flex; gap: 10px; justify-content: flex-end; align-items: flex-start; }
.rj-product-side .price { margin: 0; white-space: nowrap; }
.rj-actions .rj-button { margin-bottom: 6px; }
.rj-text-links a { display: block; color: #333; cursor: pointer; padding-left: 14px; position: relative; text-decoration: none; }
.rj-text-links a:before { content: ""; position: absolute; left: 2px; top: 5px; width: 7px; height: 7px; border: 1px solid #999; }
.rj-text-links a:hover { color: #38B0E3; }
.product-grid .rj-product { border: 0; text-align: left; }
.product-grid .rj-product .image { border: 1px solid #E7E7E7; padding: 8px; }
.product-grid .rj-product-body { display: block; }
.product-grid .rj-product .caption { padding: 6px 0; min-height: 0; }
.product-grid .rj-product .caption p { display: none; }
.rj-pagination { overflow: hidden; padding: 10px 0; }
@media (max-width: 767px) {
	.product-list .rj-product, .product-list .rj-product-body { flex-direction: column; }
	.product-list .rj-product .image { flex: none; }
	.product-list .rj-product-side { flex: none; justify-content: flex-start; }
}
.rj-listing-option { margin: 4px 0 6px; font-size: 12px; } .rj-listing-option img { vertical-align: middle; margin: 2px 4px 2px 0; }

/* ---- 商品頁（原站：標題在上、左圖右資訊、分隔線區塊、頁籤全寬） ---- */
.rj-product-title { font-size: 32px; color: #636E75; margin: 4px 0 20px; }
.rj-product-image .thumbnails { margin: 0; }
.rj-product-image .thumbnail { border: 1px solid #E7E7E7; border-radius: 0; padding: 10px; }
.rj-product-info > .list-unstyled:first-of-type { border-top: 1px solid #E7E7E7; }
.rj-product-info > .list-unstyled { border-bottom: 1px solid #E7E7E7; padding: 10px 5px; margin: 0; }
.rj-product-info > .list-unstyled li { line-height: 20px; }
.rj-price { font-size: 14px; font-weight: bold; padding: 4px 0; }
.rj-price .price-new { font-size: 14px; }
#product { border-bottom: 1px solid #E7E7E7; padding: 10px 5px; }
#product hr { display: none; }
.rj-cart-line { display: flex; align-items: center; flex-wrap: wrap; gap: 8px; margin: 0; }
.rj-cart-line .control-label { margin: 0; font-weight: normal; }
.rj-cart-line #input-quantity { width: 30px; height: 22px; padding: 1px 3px; font-size: 12px; }
.rj-or { color: #666; font-size: 12px; }
.rj-cart-links a { display: block; text-decoration: underline; cursor: pointer; }
.rj-product-info .rating { border: 1px solid #E7E7E7; margin: 18px 0 0; padding: 8px 10px; }
.rj-product-info .rating p { margin: 0; }
.rj-product-tabs { margin-top: 40px; }
.rj-product-tabs .nav-tabs { border-bottom: 1px solid #DDD; margin: 0; }
.rj-product-tabs .nav-tabs > li > a { font-weight: bold; color: #000; border: 1px solid #DDD; background: #F7F7F7; border-radius: 7px 7px 0 0; margin-right: 4px; padding: 7px 15px; }
.rj-product-tabs .nav-tabs > li.active > a { background: #fff; border-bottom-color: #fff; }
.rj-product-tabs .tab-content { border: 1px solid #DDD; border-top: 0; padding: 15px 20px; overflow-x: auto; }

/* ---- 聯絡表單（原站：資訊頁內容外框、欄位上下排列） ---- */
.rj-contact-info { border: 1px solid #EEE; padding: 10px; margin-bottom: 30px; }
.rj-contact-info img { max-width: 100%; height: auto; }
.rj-contact-form h2 { font-size: 16px; font-weight: bold; margin: 0 0 6px; }
.rj-contact-form .form-group { margin-bottom: 12px; }
.rj-contact-form .control-label { font-weight: bold; font-size: 12px; margin-bottom: 2px; }
.rj-contact-form .form-control { border-radius: 0; background: #F8F8F8; box-shadow: none; }
.rj-contact-form .rj-input-short { max-width: 135px; height: 22px; padding: 1px 4px; }
.rj-buttons { border: 1px solid #EEE; padding: 6px; overflow: hidden; margin-top: 6px; }
.rj-vip { border: 1px solid #DBDEE1; border-radius: 7px; padding: 10px 15px; margin-bottom: 15px; } .rj-vip h2 { font-size: 16px; margin-top: 0; }

/* ---- 手機：後台編輯的內容（歡迎模組、分類說明、商品／資訊頁內容）常寫死 980px 寬的表格與圖片 → 限制在螢幕寬度內 ---- */
@media (max-width: 991px) {
	#content img, #content_description img, .rj-contact-info img { max-width: 100% !important; height: auto !important; }
	#content table:not(.table), #content_description table { width: 100% !important; max-width: 100%; table-layout: fixed; }
	#content table:not(.table) td { word-wrap: break-word; }
	#content iframe, #content video { max-width: 100%; }
	body { overflow-x: hidden; }
}

/* 分類本身的圖片（原站 .category-info .image） */
.rj-category-info { margin: 0 0 15px; }
.rj-category-info img { border: 1px solid #E7E7E7; padding: 5px; max-width: 100%; }
