/* Gateway additions to the c01_nav design: account corner, sign-in line, destination contents. */
.role-wrap[hidden] { display: none !important; }
.m1-auth { display: flex; align-items: center; gap: 10px; }
.m1-auth .m1-name { font-size: 11px; letter-spacing: .14em; color: #fff6e8; text-shadow: 0 1px 6px #2a1d12cc; }
.m1-auth form { margin: 0; }
.m1-auth button {
  font: inherit; font-size: 11px; letter-spacing: .16em; color: inherit; cursor: pointer;
  border: 1px solid #f7ebd780; border-radius: 999px; padding: 7px 14px; background: #2a211ab8; color: #fff6e8;
}
.m1-auth button:hover { background: #ac3e24; border-color: #ac3e24; }
.m1-auth button[aria-expanded="true"] { background: transparent; border-color: currentColor; }
/* Open, CLOSE sits on the line's mist: it takes the yard's ink (dark by day and dusk, light at night). */
html.m1-line-open .m1-auth button[aria-expanded="true"] { color: var(--ink); }
html.m1-line-open .m1-auth button[aria-expanded="true"]:hover { color: var(--seal); }
/* The homepage squares every focused button; the pills keep their round shape. */
.m1-auth button:focus-visible { outline: 1px solid currentColor; outline-offset: 3px; }

/* Sign-in line: SIGN IN unfolds, in place, into one line of the header's own type and takes the DAY·DUSK·NIGHT spot.
   No box: a breath of the yard's mist behind it. It moves by opacity and transform only; a clip would square the mist. */
.m1-line { position: relative; display: none; justify-self: end; margin: 0; pointer-events: auto; color: var(--ink); transition: color 1s; }
.m1-line::before { content: ""; position: absolute; z-index: -1; inset: -26px -48px; pointer-events: none; background: radial-gradient(closest-side, #eee8e0d0, #eee8e080 60%, transparent); }
#hero[data-mode="dusk"] .m1-line::before { background: radial-gradient(closest-side, #f0dccbd0, #f0dccb80 60%, transparent); }
#hero[data-mode="night"] .m1-line::before { background: radial-gradient(closest-side, #1c2028d0, #1c202880 60%, transparent); }
.m1-line.is-on { display: block; animation: m1-line-in .5s cubic-bezier(.2,.75,.2,1) backwards; }
@keyframes m1-line-in { from { opacity: 0; transform: translateX(14px); } }
html.m1-line-open .court-header .ink-times { display: none; }
html.m1-line-open .morph-switch { visibility: hidden; pointer-events: none; }
.m1-line-row { display: flex; align-items: center; gap: 18px; margin: 0; }
.m1-line-field { display: flex; align-items: baseline; gap: 10px; cursor: text; }
.m1-line-label, .m1-line-go { font: 400 10px/1 var(--serif); letter-spacing: .18em; white-space: nowrap; }
.m1-line-label { opacity: .78; }
.m1-line-field input {
  width: 150px; min-width: 0; margin: 0; padding: 4px 0 3px; border: 0; border-bottom: 1px solid color-mix(in srgb, currentColor 45%, transparent);
  border-radius: 0; background: transparent; color: inherit; font: 400 15px/1.2 var(--serif); letter-spacing: .04em;
  -webkit-tap-highlight-color: transparent; transition: border-color .25s;
}
/* The homepage boxes every focused input; in the line the underline darkens instead. */
.m1-line input:focus-visible { outline: none; }
.m1-line-field input:focus { border-bottom-color: currentColor; box-shadow: 0 1px 0 currentColor; }
.m1-line-field input[type="password"] { letter-spacing: .22em; }
.m1-line-cells { position: relative; display: flex; gap: .42em; font: 400 18px/1 var(--serif); font-variant-numeric: tabular-nums; }
.m1-line-cells i { position: relative; display: grid; place-items: end center; width: 1em; height: 1.35em; font-style: normal; }
.m1-line-cells i::after { content: ""; position: absolute; left: 0; right: 0; bottom: 0; height: 1px; background: currentColor; opacity: .45; }
.m1-line-cells i.is-next::after { opacity: 1; animation: m1-line-blink 1.05s steps(1) infinite; }
.m1-line-cells b { font-weight: 400; transform: translateY(-.12em); }
.m1-line-cells input {
  position: absolute; inset: 0; width: 100%; height: 100%; margin: 0; padding: 0; border: 0; background: transparent;
  color: transparent; caret-color: transparent; -webkit-text-fill-color: transparent; font-size: 16px; cursor: text; -webkit-tap-highlight-color: transparent;
}
.m1-line-cells input::selection { background: transparent; }
@keyframes m1-line-blink { 50% { opacity: .2; } }
.m1-line-hint { font: 11px "Apple SD Gothic Neo", "Pretendard", sans-serif; letter-spacing: .02em; opacity: .65; }
.m1-line-go { border: 0; padding: 6px 4px; background: transparent; color: inherit; cursor: pointer; }
.m1-line-go:hover { color: var(--seal); }
.m1-line-go:focus-visible { outline: none; text-decoration: underline; text-underline-offset: 4px; }
.m1-line-go:disabled { opacity: .6; cursor: wait; color: inherit; }
.m1-line-error { position: absolute; top: calc(100% + 8px); right: 4px; margin: 0; font: 11px "Apple SD Gothic Neo", "Pretendard", sans-serif; color: var(--seal); white-space: nowrap; }
/* Phones: the line is a band of mist under the header, the width of the screen. A fixed box in the header's grid must
   stretch: left at justify-self end it shrinks to its content and bares the eave. */
@media (max-width: 760px) {
  .court-header .m1-auth { grid-row: 1; grid-column: 2; }
  .m1-line {
    position: fixed; left: 0; right: 0; justify-self: stretch; top: calc(max(18px, env(safe-area-inset-top)) + 34px); padding: 22px 5% 30px;
    background: #eee8e0eb; color: #2b231d;
    -webkit-mask-image: linear-gradient(transparent, #000 20px, #000 72%, transparent); mask-image: linear-gradient(transparent, #000 20px, #000 72%, transparent);
  }
  .m1-line::before { display: none; }
  #hero[data-mode="dusk"] .m1-line { background: #f0dccbeb; color: #3a271d; }
  #hero[data-mode="night"] .m1-line { background: #1c2028eb; color: #efe7dc; }
  /* Here CLOSE straddles the dark eave and the light mist, so it wears the band's own colour to read on both. */
  html.m1-line-open .m1-auth button[aria-expanded="true"] { background: #eee8e0eb; border-color: transparent; }
  html.m1-line-open #hero[data-mode="dusk"] .m1-auth button[aria-expanded="true"] { background: #f0dccbeb; }
  html.m1-line-open #hero[data-mode="night"] .m1-auth button[aria-expanded="true"] { background: #1c2028eb; }
  .m1-line[data-step="account"] .m1-line-row { display: grid; grid-template-columns: 1fr auto; gap: 12px 16px; }
  .m1-line-id { grid-column: 1 / -1; }
  .m1-line-field { display: grid; grid-template-columns: 70px 1fr; }
  .m1-line-field input { width: 100%; font-size: 16px; }
  .m1-line[data-step="otp"] .m1-line-row { flex-wrap: wrap; gap: 10px 14px; }
  .m1-line-hint { order: 1; flex-basis: 100%; }
  .m1-line-error { position: static; margin-top: 10px; white-space: normal; font-size: 12px; }
}
.arrival-list [data-open-signin] { letter-spacing: .16em; }

/* Design annotations from the prototype are not part of the live page. */
#dest-stage .dest-tag, #dest-stage .dest-kv, #dest-stage .dest-replay, #dest-stage .dest-slot > span { display: none; }
#dest-stage .dest-slot { display: block; }
.m1-mount { width: 100%; }
.m1-enter p { margin: 0 0 18px; color: #554c40; font-size: 15px; line-height: 1.7; word-break: keep-all; }
.m1-enter button {
  font: inherit; font-size: 14px; font-weight: 700; letter-spacing: .12em; color: #f7f1e6; background: #1f1b17;
  border: 0; border-radius: 999px; padding: 15px 34px; cursor: pointer; transition: background .25s, transform .25s;
}
.m1-enter button:hover { background: #ac3e24; transform: translateY(-1px); }
.m1-enter button:disabled { opacity: .7; cursor: wait; }
.m1-mount h3 { margin: 30px 0 12px; font-size: 15px; letter-spacing: .04em; color: #3b3329; }
.m1-mount h3:first-child { margin-top: 0; }
.m1-grid { columns: 3 220px; column-gap: 12px; }
.m1-grid img {
  display: block; width: 100%; height: auto; margin: 0 0 12px; border-radius: 4px; cursor: zoom-in; break-inside: avoid;
  background: #e8ded0; box-shadow: 0 8px 22px #3b2a1a26; transition: transform .45s cubic-bezier(.2,.8,.2,1), box-shadow .45s;
  animation: m1-rise .8s cubic-bezier(.2,.8,.2,1) both;
}
.m1-grid img:hover { transform: translateY(-3px) scale(1.01); box-shadow: 0 16px 34px #3b2a1a3d; }
.m1-grid img:nth-child(3n+2) { animation-delay: .08s; }
.m1-grid img:nth-child(3n) { animation-delay: .16s; }
@keyframes m1-rise { from { opacity: 0; transform: translateY(16px); } to { opacity: 1; transform: none; } }
#m1-viewer { border: 0; padding: 0; background: transparent; width: 100vw; height: 100vh; max-width: 100vw; max-height: 100vh; color: #f7f1e6; }
#m1-viewer[open] { display: grid; place-items: center; }
#m1-viewer::backdrop { background: #120e0aee; backdrop-filter: blur(6px); }
#m1-viewer img { max-width: min(92vw, 1200px); max-height: 84vh; object-fit: contain; box-shadow: 0 30px 80px #000c; }
#m1-viewer p { position: fixed; bottom: 22px; left: 0; right: 0; margin: 0; text-align: center; font-size: 12px; letter-spacing: .14em; opacity: .8; }
#m1-viewer button { position: fixed; background: none; border: 0; color: inherit; font-size: 34px; padding: 12px 18px; cursor: pointer; opacity: .75; }
#m1-viewer button:hover { opacity: 1; }
#m1-viewer [data-close-viewer] { top: 12px; right: 14px; }
#m1-viewer [data-step="-1"] { left: 6px; top: 50%; transform: translateY(-50%); }
#m1-viewer [data-step="1"] { right: 6px; top: 50%; transform: translateY(-50%); }
@media (prefers-reduced-motion: reduce) { .m1-grid img { animation: none; transition: none; } }
