/* login.css */

/* =========================================
   login.css (cleaned)
   - レイアウト＆タイポ修正
   - 重複宣言の整理
   - メディアクエリの簡素化
   ========================================= */

@charset "UTF-8";

/* -------------------------------
   Base / Reset-ish
-------------------------------- */
:root {
  --text: #696969;
  --link: #0e8fe6;
  --muted: #808080;
  --error: red;
  --radius: 10px;
}

*,
*::before,
*::after {
  box-sizing: border-box;
}

html, body {
  margin: 0;
  padding: 0;
}

body {
  color: var(--text);
  font-family: 'Sawarabi Gothic', 'Lato', sans-serif;
  line-height: 1.6;
}

/* ベースのフォントスケール */
body, h1, h2, h3 {
  font-size: calc(1rem + ((0.5vw - 0.32rem) * 0.7143));
}

/* 見出しの整形 */
h1, h2, footer {
  text-align: center;
}
h1, h2, .right {
  margin-bottom: 1rem;
}
h2 {
  font-size: calc(1.0rem + ((0.5vw - 0.32rem) * 0.7143));
}

/* リンク */
a {
  color: var(--link);
  text-decoration: none;
}
a:hover {
  opacity: 0.7;
}

/* -------------------------------
   Form / Controls
-------------------------------- */
button,
html [type="button"],
[type="reset"],
[type="submit"] {
  -webkit-appearance: button;
}

button,
[type="button"],
[type="reset"],
[type="submit"],
[role="button"] {
  cursor: pointer;
}

button,
input,
select,
textarea {
  background-color: transparent;
  border: none;
  color: inherit;
  font: inherit;
}

/* -------------------------------
   Layout
-------------------------------- */
main {
  padding-bottom: 5rem;
}

header {
  padding: 5px;
  color: #fff;
  background: var(--muted);
}

/* 小さめ文字 */
header, .bambilink, .right, #wrap footer {
  font-size: 78%;
}

/* 全体コンテナ */
#wrap {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translateY(-50%) translateX(-50%);
  -webkit-transform: translateY(-50%) translateX(-50%);
  max-width: 320px;
  width: 320px; /* デフォルト幅（SPではメディアクエリで上書き） */
}

/* 上下余白 */
#wrap header,
#wrap footer {
  padding: 1rem 0;
  text-align: center;
}
#wrap header { margin-bottom: 2rem; }

/* バンビリンク（右寄せメニュー） */
.bambilink { display: inline-block; }
.bambilink li { list-style: none; }

/* 右サイド領域のテキスト微調整 */
#wrap .right div {
  line-height: 1.4;
  font-size: clamp(0.8rem, 0.9rem + 0.3vw, 1rem);
}

/* -------------------------------
   Form Block
-------------------------------- */
#wrap .formWrap dl dt,
#wrap .formWrap dl dd {
  width: 100%;
  padding-bottom: 0.5rem;
}

#wrap .formWrap dl dd {
  margin-bottom: 0.5rem;
  padding: 0;
  margin-left: 0;
}

#wrap .formWrap dl dd input {
  width: 100%;
  padding: 0.75rem;
  background: #eee;
  border-radius: 6px;
}

/* エラー表示 */
#wrap .formWrap .error {
  color: var(--error);
  font-size: 68%;
}

/* 送信ボタン */
#wrap .formWrap .subinput .hplogin {
  display: block;
  width: 50%;
  margin: 2rem auto;
  padding: 1rem 0;
  text-align: center;
  color: #fff;
  font-weight: 700;
  border-radius: 0.5rem;
  background: linear-gradient(45deg, #73d0bf 0%, #a4e6da 100%);
  cursor: pointer;
}
#wrap .formWrap .subinput:hover {
  opacity: .9;
  cursor: pointer;
}

/* -------------------------------
   Responsive
-------------------------------- */

/* <= 414px : スマホ幅 */
@media screen and (max-width: 414px) {
  header {
    margin-bottom: 0.3rem;
    text-align: center;
  }

  .bambilink {
    float: right;
    margin-right: 10px;
  }

  .bambilink li {
    float: left;
    margin-right: 10px;
    line-height: 1.8;
    font-size: 120%;
  }

  .bambilink li:after {
    content: '|';
    color: #80A1CD;
  }
  .bambilink li:last-child:after {
    content: '';
  }

  #wrap {
    width: 80%;
    max-width: 320px;
  }
}

/* 415px–767px : タブレット縦/小型端末 */
@media screen and (min-width: 415px) and (max-width: 767px) {
  header {
    margin-bottom: 0.3rem;
    text-align: center;
  }

  .bambilink {
    float: right;
    margin-right: 10px;
  }

  .bambilink li {
    float: left;
    margin-right: 10px;
    line-height: 1.8;
    font-size: 120%;
  }

  .bambilink li:after {
    content: '|';
    color: #80A1CD;
  }
  .bambilink li:last-child:after {
    content: '';
  }

  #wrap {
    width: 320px;
  }
}

/* >= 768px : タブレット横～PC */
@media screen and (min-width: 768px) {
  header { display: inline-block; float: left; }

  .bambilink {
    float: right;
    padding: 5px;
  }

  .bambilink li {
    float: left;
    margin-right: 10px;
    font-size: 78%;
  }
  .bambilink li:last-child { margin-right: 0; }

  .bambilink li a {
    display: block;
    padding: 5px 20px;
    color: #fff;
    background: #ffa60d;
    border-radius: var(--radius);
    text-decoration: none;
  }

  #wrap,
  #wrap .formWrap {
    width: 480px;
  }
}