/* ログイン画面の配色、フォーム、レスポンシブ表示を定義する共通スタイル。 */
:root {
  color-scheme: light;
  --background: #f4f0e8;
  --paper: #fffdf9;
  --ink: #332d29;
  --muted: #756c65;
  --accent: #76513f;
  --accent-dark: #5f4032;
  --gold: #b79a70;
  --line: #ddd3c4;
  --field: #fcfaf6;
  --error: #9c413b;
  --shadow: rgba(62, 46, 35, 0.11);
}

/* 画面全体とカードレイアウト */
* {
  box-sizing: border-box;
}

html {
  min-width: 320px;
  background: var(--background);
}

body {
  margin: 0;
  min-height: 100vh;
  color: var(--ink);
  background:
    radial-gradient(circle at 12% 8%, rgba(183, 154, 112, 0.14), transparent 25rem),
    radial-gradient(circle at 90% 92%, rgba(118, 81, 63, 0.1), transparent 23rem),
    var(--background);
  font-family: -apple-system, BlinkMacSystemFont, "Hiragino Sans", "Yu Gothic",
    "YuGothic", "Noto Sans JP", sans-serif;
  -webkit-font-smoothing: antialiased;
}

button,
input,
select {
  font: inherit;
}

button,
label,
select {
  -webkit-tap-highlight-color: transparent;
}

.page-shell {
  display: grid;
  min-height: 100vh;
  place-items: center;
  padding: 20px 14px;
}

.login-card {
  position: relative;
  width: min(100%, 520px);
  overflow: hidden;
  padding: clamp(32px, 8vw, 54px) clamp(20px, 6vw, 42px) 28px;
  border: 1px solid rgba(183, 154, 112, 0.58);
  border-radius: 18px;
  background:
    linear-gradient(rgba(255, 253, 249, 0.96), rgba(255, 253, 249, 0.96)),
    repeating-linear-gradient(0deg, transparent 0 3px, rgba(87, 67, 51, 0.018) 3px 4px),
    var(--paper);
  box-shadow: 0 22px 58px var(--shadow);
}

.login-card::before,
.login-card::after {
  position: absolute;
  width: 110px;
  height: 110px;
  border: 1px solid rgba(183, 154, 112, 0.22);
  border-radius: 50%;
  content: "";
  pointer-events: none;
}

.login-card::before {
  top: -64px;
  left: -56px;
}

.login-card::after {
  right: -60px;
  bottom: -68px;
}

.hero {
  text-align: center;
}

/* 結婚式らしい見出しと装飾 */
.eyebrow {
  margin: 0 0 10px;
  color: var(--gold);
  font-family: Georgia, "Times New Roman", serif;
  font-size: 11px;
  font-weight: 600;
  letter-spacing: 0.24em;
  text-transform: uppercase;
}

.couple-name {
  display: flex;
  align-items: baseline;
  justify-content: center;
  gap: 11px;
  margin: 0;
  color: var(--accent);
  font-family: Georgia, "Times New Roman", serif;
  font-size: clamp(29px, 9vw, 43px);
  line-height: 1.15;
}

.ampersand {
  color: var(--gold);
  font-size: 0.66em;
  font-style: italic;
}

.ornament {
  display: grid;
  width: 86px;
  height: 13px;
  margin: 19px auto 15px;
  place-items: center;
}

.ornament::before {
  width: 100%;
  height: 1px;
  background: var(--line);
  content: "";
}

.ornament::after {
  position: absolute;
  width: 7px;
  height: 7px;
  border: 1px solid var(--gold);
  background: var(--paper);
  content: "";
  transform: rotate(45deg);
}

h1 {
  margin: 0;
  font-family: "Yu Mincho", "Hiragino Mincho ProN", serif;
  font-size: clamp(22px, 6vw, 29px);
  font-weight: 600;
  letter-spacing: 0.06em;
  line-height: 1.45;
}

.introduction {
  margin: 15px auto 0;
  color: var(--muted);
  font-size: 13px;
  line-height: 1.9;
}

.login-form {
  display: grid;
  gap: 20px;
  margin-top: 32px;
}

/* 段階選択式のログインフォーム */
.form-field {
  min-width: 0;
  margin: 0;
  padding: 0;
  border: 0;
}

.form-field > label,
.form-field legend {
  display: block;
  margin: 0 0 9px;
  color: var(--ink);
  font-size: 13px;
  font-weight: 600;
  letter-spacing: 0.035em;
}

.side-options {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 10px;
}

.side-option {
  position: relative;
  cursor: pointer;
}

.side-option input {
  position: absolute;
  width: 1px;
  height: 1px;
  opacity: 0;
}

.side-option span {
  display: grid;
  min-height: 50px;
  border: 1px solid var(--line);
  border-radius: 10px;
  background: var(--field);
  color: var(--muted);
  font-size: 15px;
  font-weight: 600;
  place-items: center;
  transition: border-color 160ms ease, background-color 160ms ease,
    color 160ms ease, box-shadow 160ms ease;
}

.side-option input:checked + span {
  border-color: var(--accent);
  background: var(--accent);
  color: #fff;
  box-shadow: 0 7px 18px rgba(118, 81, 63, 0.18);
}

.side-option input:focus-visible + span,
select:focus-visible,
input:focus-visible,
button:focus-visible {
  outline: 3px solid rgba(183, 154, 112, 0.38);
  outline-offset: 2px;
}

.select-wrap,
.password-wrap {
  position: relative;
}

.select-wrap::after {
  position: absolute;
  top: 50%;
  right: 17px;
  width: 8px;
  height: 8px;
  border-right: 1.5px solid var(--accent);
  border-bottom: 1.5px solid var(--accent);
  content: "";
  pointer-events: none;
  transform: translateY(-68%) rotate(45deg);
}

select,
input[type="password"],
input[type="text"] {
  width: 100%;
  min-height: 52px;
  border: 1px solid var(--line);
  border-radius: 10px;
  background: var(--field);
  color: var(--ink);
  font-size: 16px;
  transition: border-color 160ms ease, box-shadow 160ms ease;
}

select {
  padding: 0 46px 0 15px;
  appearance: none;
}

select:disabled {
  cursor: not-allowed;
  color: #a49d95;
  background: #f4f1ec;
}

input[type="password"],
input[type="text"] {
  padding: 0 74px 0 15px;
}

select:focus,
input:focus {
  border-color: var(--gold);
  box-shadow: 0 0 0 3px rgba(183, 154, 112, 0.11);
}

input::placeholder {
  color: #a49d95;
  font-size: 13px;
}

.password-toggle {
  position: absolute;
  top: 50%;
  right: 7px;
  min-width: 58px;
  min-height: 38px;
  padding: 0 8px;
  border: 0;
  border-radius: 7px;
  background: transparent;
  color: var(--accent);
  cursor: pointer;
  font-size: 13px;
  font-weight: 600;
  transform: translateY(-50%);
}

.form-message {
  display: none;
  margin: -4px 0 0;
  padding: 11px 13px;
  border-radius: 8px;
  background: rgba(156, 65, 59, 0.08);
  color: var(--error);
  font-size: 13px;
  line-height: 1.65;
}

.form-message.is-visible {
  display: block;
}

.submit-button {
  min-height: 54px;
  margin-top: 2px;
  border: 1px solid var(--accent);
  border-radius: 10px;
  background: var(--accent);
  color: #fff;
  cursor: pointer;
  font-size: 15px;
  font-weight: 700;
  letter-spacing: 0.08em;
  box-shadow: 0 9px 22px rgba(118, 81, 63, 0.2);
  transition: background-color 160ms ease, border-color 160ms ease,
    box-shadow 160ms ease, transform 160ms ease;
}

.submit-button:hover:not(:disabled) {
  border-color: var(--accent-dark);
  background: var(--accent-dark);
  box-shadow: 0 11px 26px rgba(95, 64, 50, 0.24);
}

.submit-button:active:not(:disabled) {
  transform: translateY(1px);
}

.submit-button:disabled {
  border-color: #d7d0c7;
  background: #d7d0c7;
  box-shadow: none;
  color: #f9f7f3;
  cursor: not-allowed;
}

.card-footer {
  margin-top: 28px;
  padding-top: 21px;
  border-top: 1px solid var(--line);
  color: var(--muted);
  text-align: center;
}

.card-footer p {
  margin: 0;
  font-size: 11px;
  line-height: 1.75;
}

.card-footer .period {
  margin-top: 8px;
  color: var(--accent);
  font-family: "Yu Mincho", "Hiragino Mincho ProN", serif;
  font-size: 12px;
  font-weight: 600;
}

@media (max-width: 380px) {
  .page-shell {
    padding: 10px;
  }

  .login-card {
    padding-right: 17px;
    padding-left: 17px;
    border-radius: 14px;
  }

  .couple-name {
    gap: 8px;
  }
}

@media (min-width: 700px) {
  .page-shell {
    padding: 42px 20px;
  }
}

@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    scroll-behavior: auto !important;
    transition-duration: 0.01ms !important;
  }
}

/*
 * 参考サイトの大胆な分割構成と余白感を、写真なしでも成立する形へ翻訳した仮デザイン。
 * 認証部品の状態や操作性は変えず、視覚表現だけを上書きする。
 */
:root {
  --background: #deddd8;
  --paper: #f4f1e9;
  --ink: #292622;
  --muted: #77736c;
  --accent: #59473a;
  --accent-dark: #302923;
  --gold: #806958;
  --line: rgba(41, 38, 34, 0.22);
  --field: rgba(255, 255, 255, 0.28);
  --error: #94463f;
  --shadow: transparent;
}

html,
body {
  background: #deddd8;
}

body {
  font-family: "Helvetica Neue", "Hiragino Kaku Gothic ProN", "Yu Gothic",
    "YuGothic", sans-serif;
}

/* PCではビジュアル面と本文を左右に分ける。 */
.page-shell {
  display: grid;
  min-height: 100svh;
  grid-template-columns: minmax(360px, 47vw) minmax(440px, 1fr);
  padding: 0;
  place-items: stretch;
}

.editorial-panel {
  position: sticky;
  top: 0;
  display: grid;
  height: 100svh;
  min-height: 620px;
  overflow: hidden;
  padding: 32px 36px 30px;
  background:
    linear-gradient(135deg, rgba(48, 37, 30, 0.74), rgba(35, 31, 28, 0.38)),
    linear-gradient(180deg, rgba(30, 27, 24, 0.12), rgba(25, 22, 20, 0.64)),
    url("/assets/couple-hero.jpg") center / cover no-repeat;
  color: #f7f3ea;
  grid-template-columns: 1fr auto;
  grid-template-rows: auto 1fr auto;
}

.editorial-panel::before,
.editorial-panel::after {
  display: none;
}

.editorial-panel::before {
  top: 15%;
  left: 9%;
  width: 54%;
  height: 58%;
  transform: rotate(-7deg);
}

.editorial-panel::after {
  right: -12%;
  bottom: 4%;
  width: 50%;
  aspect-ratio: 1;
  border-radius: 50%;
}

.editorial-brand {
  position: relative;
  z-index: 1;
  margin: 0;
  font-family: Georgia, "Times New Roman", serif;
  font-size: 18px;
  letter-spacing: 0.1em;
  text-transform: uppercase;
}

.editorial-brand span {
  margin: 0 0.2em;
  font-size: 0.72em;
  font-style: italic;
}

.editorial-japanese {
  position: relative;
  z-index: 1;
  align-self: center;
  justify-self: end;
  margin: 0;
  font-family: "Yu Mincho", "Hiragino Mincho ProN", serif;
  font-size: clamp(19px, 2vw, 28px);
  letter-spacing: 0.18em;
  line-height: 1.8;
  writing-mode: vertical-rl;
}

.editorial-meta {
  position: relative;
  z-index: 1;
  display: flex;
  grid-column: 1 / -1;
  align-items: end;
  justify-content: space-between;
  padding-top: 0;
  font-size: 10px;
  letter-spacing: 0.18em;
  text-transform: uppercase;
}

.login-card {
  display: flex;
  width: 100%;
  max-width: 720px;
  min-height: 100svh;
  flex-direction: column;
  justify-content: center;
  overflow: visible;
  padding: clamp(54px, 8vw, 98px) clamp(30px, 7vw, 92px) 38px;
  border: 0;
  border-radius: 0;
  background: var(--paper);
  box-shadow: none;
}

.login-card::before,
.login-card::after {
  display: none;
}

.hero {
  text-align: left;
}

.eyebrow {
  margin: 0 0 22px;
  color: var(--muted);
  font-family: inherit;
  font-size: 9px;
  font-weight: 500;
  letter-spacing: 0.32em;
}

.couple-name {
  justify-content: flex-start;
  gap: 12px;
  color: var(--ink);
  font-size: clamp(34px, 5vw, 58px);
  font-weight: 400;
  letter-spacing: -0.035em;
  line-height: 1;
}

.ampersand {
  color: var(--accent);
  font-size: 0.55em;
}

.ornament {
  display: block;
  width: min(100%, 110px);
  height: 1px;
  margin: 30px 0 28px;
  background: var(--ink);
}

.ornament::before,
.ornament::after {
  display: none;
}

h1 {
  font-size: clamp(23px, 3vw, 34px);
  font-weight: 400;
  letter-spacing: 0.09em;
  line-height: 1.6;
}

.introduction {
  margin: 17px 0 0;
  font-family: "Yu Mincho", "Hiragino Mincho ProN", serif;
  font-size: 13px;
  line-height: 2;
}

.login-form {
  gap: 25px;
  margin-top: 44px;
}

.form-field > label,
.form-field legend {
  margin-bottom: 10px;
  font-size: 11px;
  font-weight: 500;
  letter-spacing: 0.14em;
}

.side-options {
  gap: 0;
  border-top: 1px solid var(--line);
  border-bottom: 1px solid var(--line);
}

.side-option:first-child {
  border-right: 1px solid var(--line);
}

.side-option span {
  min-height: 52px;
  border: 0;
  border-radius: 0;
  background: transparent;
  font-size: 13px;
  font-weight: 400;
  letter-spacing: 0.1em;
  transition: background-color 180ms ease, color 180ms ease;
}

.side-option input:checked + span {
  border: 0;
  background: var(--ink);
  color: var(--paper);
  box-shadow: none;
}

.side-option input:focus-visible + span,
select:focus-visible,
input:focus-visible,
button:focus-visible,
a:focus-visible {
  outline: 2px solid rgba(89, 71, 58, 0.7);
  outline-offset: 3px;
}

.select-wrap::after {
  right: 7px;
  border-color: var(--ink);
}

select,
input[type="password"],
input[type="text"] {
  min-height: 50px;
  border: 0;
  border-bottom: 1px solid var(--line);
  border-radius: 0;
  background: transparent;
  font-size: 15px;
  transition: border-color 180ms ease;
}

select {
  padding-left: 0;
}

select:disabled {
  background: transparent;
  color: #aaa59c;
}

input[type="password"],
input[type="text"] {
  padding-left: 0;
}

select:focus,
input:focus {
  border-color: var(--ink);
  box-shadow: none;
}

input::placeholder {
  color: #9b968e;
  font-size: 12px;
}

.password-toggle {
  right: 0;
  min-width: 52px;
  padding: 0;
  border-radius: 0;
  font-size: 11px;
  letter-spacing: 0.1em;
}

.form-message {
  border-left: 2px solid var(--error);
  border-radius: 0;
  font-size: 12px;
}

.submit-button {
  min-height: 58px;
  margin-top: 7px;
  border: 1px solid var(--ink);
  border-radius: 0;
  background: var(--ink);
  color: var(--paper);
  font-size: 12px;
  font-weight: 500;
  letter-spacing: 0.18em;
  box-shadow: none;
  transition: background-color 180ms ease, color 180ms ease;
}

.submit-button:hover:not(:disabled) {
  border-color: var(--ink);
  background: transparent;
  color: var(--ink);
  box-shadow: none;
}

.submit-button:disabled {
  border-color: rgba(41, 38, 34, 0.16);
  background: rgba(41, 38, 34, 0.12);
  color: rgba(41, 38, 34, 0.42);
}

.card-footer {
  margin-top: 38px;
  padding-top: 18px;
  text-align: left;
}

.card-footer p {
  font-size: 10px;
  letter-spacing: 0.04em;
  line-height: 1.9;
}

.card-footer .period {
  margin-top: 8px;
  color: var(--ink);
  font-size: 11px;
  font-weight: 400;
  letter-spacing: 0.1em;
}

@media (max-width: 820px) {
  .page-shell {
    display: block;
    padding: 0;
  }

  .editorial-panel {
    position: relative;
    height: 36svh;
    min-height: 280px;
    padding: 24px 22px 20px;
    background-position: center, center, 46% center;
  }

  .editorial-panel::before {
    top: 18%;
    left: 11%;
    width: 48%;
    height: 52%;
  }

  .editorial-brand {
    font-size: 14px;
  }

  .editorial-japanese {
    font-size: 17px;
  }

  .editorial-meta {
    font-size: 8px;
  }

  .login-card {
    max-width: none;
    min-height: 64svh;
    padding: 48px 24px 30px;
    border-radius: 0;
  }
}

@media (max-width: 380px) {
  .page-shell {
    padding: 0;
  }

  .editorial-panel {
    min-height: 250px;
    padding-right: 18px;
    padding-left: 18px;
  }

  .editorial-meta span:last-child {
    display: none;
  }

  .login-card {
    padding-right: 18px;
    padding-left: 18px;
    border-radius: 0;
  }

  .couple-name {
    gap: 8px;
    font-size: 31px;
  }
}
