* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  --accent: #b88b70;
  --accent-dark: #765b4a;
  --accent-soft: #f8f3ef;
  --accent-line: #e5d8d0;

  margin: 0 !important;
  padding: 0 20px 70px !important;
  color: #514c47 !important;
  background: #faf9f6 !important;
  font-family:
    "Yu Gothic",
    "Hiragino Kaku Gothic ProN",
    "Meiryo",
    sans-serif !important;
  line-height: 1.75;
}

/* ===== シリーズカラー ===== */

body.series-mr {
  --accent: #d59648;
  --accent-dark: #936126;
  --accent-soft: #fff7e9;
  --accent-line: #efd7ad;
}

body.series-m {
  --accent: #6199cf;
  --accent-dark: #356b9f;
  --accent-soft: #f1f7fc;
  --accent-line: #cddfed;
}

body.series-l {
  --accent: #72a77d;
  --accent-dark: #477653;
  --accent-soft: #f2f8f3;
  --accent-line: #cfe2d2;
}

body.series-mrk {
  --accent: #b878a0;
  --accent-dark: #80516f;
  --accent-soft: #faf2f7;
  --accent-line: #e6cede;
}


/* ===== ヘッダー ===== */

.product-modern-header {
  max-width: 1080px;
  min-height: 88px;
  margin: 0 auto 48px;
  padding: 0 15px;
  border-bottom: 1px solid #e9e3dd;
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.product-brand {
  color: #e2959e !important;
  font-family: Arial, sans-serif !important;
  font-size: 30px;
  font-weight: 900;
  letter-spacing: -.04em;
  text-decoration: none !important;
}

.series-name {
  color: var(--accent-dark);
  font-size: 13px;
  font-weight: 700;
  letter-spacing: .18em;
}

.series-mr .series-name::after {
  content: "MR SERIES";
}

.series-m .series-name::after {
  content: "M SERIES";
}

.series-l .series-name::after {
  content: "L SERIES";
}

.series-mrk .series-name::after {
  content: "MRK SERIES";
}


/* ===== 基本リンク ===== */

a {
  color: var(--accent-dark) !important;
  text-decoration: none !important;
}

a:hover {
  color: var(--accent) !important;
}


/* ===== 商品ページ全体 ===== */

body > form,
body > table,
body > center,
body > div:not(.product-modern-header) {
  max-width: 1000px;
  margin-left: auto;
  margin-right: auto;
}

/* 古い固定幅を解除 */
table {
  max-width: 100% !important;
}

/* メイン商品表 */
table[border="5"] {
  width: min(100%, 920px) !important;
  margin: 0 auto 30px !important;
  border: 1px solid var(--accent-line) !important;
  border-collapse: separate !important;
  border-spacing: 0 !important;
  border-radius: 16px;
  overflow: hidden;
  background: #fff !important;
  box-shadow: 0 12px 36px rgba(80,65,55,.07);
}

table[border="5"] td {
  padding: 14px 18px !important;
  border-color: #eee8e3 !important;
  color: #57514c !important;
  vertical-align: middle !important;
}

/* 商品画像側 */
table[border="5"] td[rowspan] {
  padding: 25px !important;
  background: var(--accent-soft) !important;
  text-align: center !important;
}

/* 商品画像 */
table[border="5"] img {
  max-width: 100% !important;
  height: auto !important;
  border-radius: 8px;
  box-shadow: 0 7px 22px rgba(70,60,50,.10);
  transition: transform .2s ease;
}

table[border="5"] a:hover img {
  transform: translateY(-3px);
}


/* ===== 商品番号 ===== */

table[border="5"] td[rowspan] b {
  display: inline-block;
  margin-top: 12px;
  padding: 4px 15px;
  border-radius: 100px;
  background: var(--accent);
  color: #fff !important;
  font-size: 14px;
  letter-spacing: .08em;
}


/* ===== 価格 ===== */

font[size="4"] {
  color: #554e48 !important;
  font-size: 16px !important;
}

table[border="5"] td b {
  color: var(--accent-dark);
}


/* ===== 説明部分 ===== */

table[width="350"],
table[width="640"] {
  width: min(100%, 920px) !important;
  margin: 20px auto !important;
}

table[width="350"] td,
table[width="640"] td {
  color: #675f59 !important;
  font-size: 14px;
  line-height: 1.85;
}


/* ===== DVD画像 ===== */

img[width="240"][height="240"] {
  max-width: 240px !important;
  width: 100% !important;
  height: auto !important;
  border-radius: 10px;
}


/* ===== 購入欄 ===== */

input[type="text"] {
  width: 50px !important;
  margin: 0 6px;
  padding: 7px 8px;
  border: 1px solid var(--accent-line);
  border-radius: 6px;
  background: #fff;
  color: #504943;
  font-size: 14px;
  text-align: center;
}

input[type="submit"] {
  margin: 7px 4px !important;
  padding: 9px 19px !important;
  border: 0 !important;
  border-radius: 100px !important;
  background: var(--accent) !important;
  color: #fff !important;
  font-family: inherit;
  font-size: 13px;
  font-weight: 700;
  cursor: pointer;
  box-shadow: 0 5px 15px rgba(70,60,50,.10);
  transition: .2s ease;
}

input[type="submit"]:hover {
  background: var(--accent-dark) !important;
  transform: translateY(-2px);
}


/* 購入品確認ボタンを少し大きく */
body > form:last-of-type input[type="submit"] {
  padding: 11px 25px !important;
}


/* ===== 古いFONT属性を整理 ===== */

font {
  font-family: inherit !important;
}


/* ===== 下部ナビ ===== */

body > form:last-of-type,
body > table:last-of-type {
  margin-top: 45px !important;
  padding-top: 25px;
  border-top: 1px solid #ebe5df;
}

body > form:last-of-type img,
body > table:last-of-type img {
  vertical-align: middle;
}


/* ===== スマートフォン ===== */

@media (max-width: 720px) {

  body {
    padding: 0 10px 50px !important;
  }

  .product-modern-header {
    min-height: 76px;
    margin-bottom: 30px;
    padding: 0 5px;
  }

  .product-brand {
    font-size: 23px;
  }

  .series-name {
    font-size: 10px;
  }

  table[border="5"],
  table[border="5"] tbody,
  table[border="5"] tr,
  table[border="5"] td {
    display: block !important;
    width: 100% !important;
  }

  table[border="5"] td {
    border: 0 !important;
    border-bottom: 1px solid #eee8e3 !important;
  }

  table[border="5"] td:last-child {
    border-bottom: 0 !important;
  }

  table[border="5"] td[rowspan] {
    padding: 22px 15px !important;
  }

  table[border="5"] td[rowspan] img {
    width: auto !important;
    max-width: 100% !important;
  }

  table[width="350"],
  table[width="640"] {
    width: 100% !important;
  }

  table[width="350"] tbody,
  table[width="350"] tr,
  table[width="350"] td,
  table[width="640"] tbody,
  table[width="640"] tr,
  table[width="640"] td {
    max-width: 100% !important;
  }
}
