
/* ウォッチリスト固定ページでは投稿日・更新日の表示を使用しない */
body.yra-wl-watchlist-page #yr-common-sidebar-wrap .yr-common-page-date-row {
    display: none !important;
}

.yra-wl-button-wrap {
    display: flex;
    align-items: center;
    flex-wrap: wrap;
    gap: 8px 12px;
    margin: 12px 0 18px;
}
.yra-wl-auto { display: none; }
.yra-wl-auto.is-mounted { display: flex; }
.yra-wl-add-button,
.yra-wl-view-button,
.yra-wl-primary {
    appearance: none;
    border: 1px solid #222;
    border-radius: 6px;
    background: #fff;
    color: #171717;
    min-height: 42px;
    padding: 9px 16px;
    font-size: 15px;
    font-weight: 700;
    line-height: 1.35;
    cursor: pointer;
    transition: background .15s ease, color .15s ease, border-color .15s ease, opacity .15s ease;
}
.yra-wl-add-button:hover,
.yra-wl-view-button:hover,
.yra-wl-primary:hover { background: #f4f4f4; }
.yra-wl-add-button:focus-visible,
.yra-wl-view-button:focus-visible,
.yra-wl-primary:focus-visible,
.yra-wl-tab:focus-visible,
.yra-wl-modal button:focus-visible,
.yra-wl-modal input:focus-visible,
.yra-wl-card-image:focus-visible,
.yra-wl-drag-handle:focus-visible,
.yra-wl-card-remove:focus-visible {
    outline: 3px solid #1d6fdc;
    outline-offset: 2px;
}
.yra-wl-add-button.is-watched {
    background: #171717;
    border-color: #171717;
    color: #fff;
}
.yra-wl-add-button.is-locked {
    background: #f1f1f1;
    border-color: #aaa;
    color: #555;
}
.yra-wl-add-button:disabled,
.yra-wl-primary:disabled { opacity: .55; cursor: wait; }
.yra-wl-view-button {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    box-sizing: border-box;
}
a.yra-wl-view-button,
a.yra-wl-view-button:link,
a.yra-wl-view-button:visited,
a.yra-wl-view-button:hover,
a.yra-wl-view-button:focus,
a.yra-wl-view-button:active {
    text-decoration: none !important;
}
.yra-wl-view-button[hidden] { display: none !important; }
.yra-wl-star { margin-right: 7px; font-size: 18px; }

.yra-wl-page { width: 100%; margin: 10px 0 30px; }
.yra-wl-account-box {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 18px;
    border: 1px solid #d5d5d5;
    border-radius: 8px;
    background: #fafafa;
    padding: 15px 17px;
    margin-bottom: 18px;
}
.yra-wl-account-box.is-saved { border-color: #829985; background: #f7fbf7; }
.yra-wl-account-box strong,
.yra-wl-account-box span { display: block; }
.yra-wl-account-box span { margin-top: 3px; color: #555; font-size: 13px; }
.yra-wl-account-actions { display: flex; gap: 8px; flex-wrap: wrap; }
.yra-wl-account-actions button,
.yra-wl-text-button,
.yra-wl-card-actions button {
    appearance: none;
    border: 0;
    background: transparent;
    color: #333;
    text-decoration: underline;
    cursor: pointer;
    padding: 5px;
    font-size: 13px;
}
.yra-wl-account-actions button.is-danger,
.yra-wl-card-actions button { color: #a11212; }
.yra-wl-tabs {
    display: grid;
    grid-template-columns: 1fr 1fr;
    border-bottom: 2px solid #222;
    margin-bottom: 20px;
}
.yra-wl-tab {
    appearance: none;
    border: 1px solid #ccc;
    border-bottom: 0;
    background: #f2f2f2;
    color: #333;
    padding: 13px 10px;
    font-weight: 700;
    cursor: pointer;
}
.yra-wl-tab:first-child { border-radius: 7px 0 0 0; }
.yra-wl-tab:last-child { border-radius: 0 7px 0 0; }
.yra-wl-tab.is-active { background: #222; border-color: #222; color: #fff; }
.yra-wl-sort-guide {
    margin: 0 0 11px;
    color: #666;
    font-size: 12px;
}
.yra-wl-sort-guide-mobile { display: none; }
.yra-wl-grid {
    display: flex;
    flex-wrap: wrap;
    align-items: flex-start;
    gap: 11px;
}
.yra-wl-card {
    position: relative;
    flex: 0 0 86px;
    width: 86px;
    min-width: 0;
    border: 0;
    border-radius: 5px;
    background: transparent;
    cursor: grab;
    transition: opacity .12s ease, transform .12s ease;
}
.yra-wl-card:active { cursor: grabbing; }
.yra-wl-card.is-dragging { opacity: .28; transform: scale(.96); }
.yra-wl-card.is-drag-target::after {
    content: '';
    position: absolute;
    inset: -4px;
    border: 2px dashed #1d6fdc;
    border-radius: 7px;
    pointer-events: none;
}
.yra-wl-card-image {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 86px;
    height: 124px;
    box-sizing: border-box;
    overflow: hidden;
    border: 1px solid #d7d7d7;
    border-radius: 5px;
    padding: 2px;
    background: #f5f5f5;
    text-decoration: none;
}
.yra-wl-card-image img {
    display: block;
    max-width: 100%;
    max-height: 100%;
    width: auto;
    height: auto;
    object-fit: contain;
    pointer-events: none;
    user-select: none;
}
.yra-wl-no-image {
    color: #888;
    font-size: 10px;
    letter-spacing: .05em;
}

.yra-wl-drag-handle {
    appearance: none;
    position: absolute;
    left: 50%;
    bottom: 4px;
    transform: translateX(-50%);
    z-index: 3;
    display: none;
    align-items: center;
    justify-content: center;
    width: 24px;
    height: 24px;
    min-width: 24px;
    padding: 0;
    border: 1px solid #fff;
    border-radius: 50%;
    background: rgba(23,23,23,.94);
    color: #fff;
    box-shadow: 0 1px 5px rgba(0,0,0,.28);
    font-size: 17px;
    line-height: 1;
    cursor: grab;
    touch-action: none;
    -webkit-touch-callout: none;
    -webkit-user-select: none;
    user-select: none;
}
.yra-wl-drag-handle:active { cursor: grabbing; }
body.yra-wl-touch-sorting {
    -webkit-user-select: none;
    user-select: none;
}

.yra-wl-card-remove {
    appearance: none;
    position: absolute;
    top: -7px;
    right: -7px;
    z-index: 2;
    display: flex;
    align-items: center;
    justify-content: center;
    width: 22px;
    height: 22px;
    min-width: 22px;
    padding: 0;
    border: 1px solid #fff;
    border-radius: 50%;
    background: #a11212;
    color: #fff;
    box-shadow: 0 1px 5px rgba(0,0,0,.28);
    font-size: 17px;
    line-height: 1;
    cursor: pointer;
    opacity: 0;
}
.yra-wl-card:hover .yra-wl-card-remove,
.yra-wl-card-remove:focus-visible { opacity: 1; }

.yra-wl-empty,
.yra-wl-locked-panel {
    border: 1px dashed #bbb;
    border-radius: 8px;
    padding: 34px 20px;
    text-align: center;
    background: #fafafa;
}
.yra-wl-empty p,
.yra-wl-locked-panel p { margin: 5px 0; }
.yra-wl-locked-panel h3 { margin: 8px 0; }
.yra-wl-lock-icon { font-size: 32px; }
.yra-wl-link-button { display: inline-flex; align-items: center; justify-content: center; text-decoration: none; margin-top: 16px; }

.yra-wl-modal { display: none; position: fixed; inset: 0; z-index: 999999; }
.yra-wl-modal.is-open { display: block; }
.yra-wl-modal-backdrop { position: absolute; inset: 0; background: rgba(0,0,0,.58); }
.yra-wl-modal-dialog {
    position: relative;
    width: min(92vw, 500px);
    max-height: 90vh;
    overflow: auto;
    margin: 7vh auto 0;
    background: #fff;
    border-radius: 10px;
    padding: 25px;
    box-shadow: 0 18px 60px rgba(0,0,0,.3);
}
.yra-wl-modal-dialog h2 { margin: 0 35px 12px 0; font-size: 21px; }
.yra-wl-modal-dialog p { line-height: 1.65; }
.yra-wl-modal-close { position: absolute; right: 12px; top: 9px; border: 0; background: transparent; font-size: 28px; cursor: pointer; color: #444; }
.yra-wl-label { display: block; margin: 17px 0 12px; font-size: 13px; font-weight: 700; }
.yra-wl-label input {
    display: block;
    width: 100%;
    box-sizing: border-box;
    margin-top: 6px;
    border: 1px solid #aaa;
    border-radius: 5px;
    padding: 11px 12px;
    font-size: 16px;
}
.yra-wl-modal .yra-wl-primary { width: 100%; background: #222; color: #fff; }
.yra-wl-modal .yra-wl-text-button { display: block; margin: 10px auto 0; }
.yra-wl-form-message { min-height: 22px; margin: 12px 0 0 !important; font-size: 13px; color: #315b36; }
.yra-wl-form-message.is-error { color: #a11212; }
body.yra-wl-modal-open { overflow: hidden; }

.yra-wl-toast {
    position: fixed;
    left: 50%;
    bottom: 24px;
    z-index: 1000000;
    transform: translate(-50%, 20px);
    opacity: 0;
    background: #222;
    color: #fff;
    border-radius: 6px;
    padding: 11px 16px;
    max-width: min(90vw, 520px);
    box-shadow: 0 7px 30px rgba(0,0,0,.24);
    transition: opacity .2s ease, transform .2s ease;
    font-size: 14px;
    text-align: center;
}
.yra-wl-toast.is-visible { opacity: 1; transform: translate(-50%, 0); }
.yra-wl-toast.is-error { background: #8c1515; }


@media (hover: none), (pointer: coarse) {
    .yra-wl-sort-guide-pc { display: none; }
    .yra-wl-sort-guide-mobile { display: inline; }
    .yra-wl-card { cursor: default; }
    .yra-wl-drag-handle { display: flex; }
    .yra-wl-card-remove { opacity: .9; }
}
@media (prefers-reduced-motion: reduce) {
    .yra-wl-add-button,
    .yra-wl-primary,
    .yra-wl-card,
    .yra-wl-toast { transition: none; }
}

@media (max-width: 900px) {
    .yra-wl-grid { gap: 10px; }
}
@media (max-width: 600px) {
    .yra-wl-button-wrap { align-items: flex-start; }
    .yra-wl-add-button,
    .yra-wl-view-button { width: 100%; }
    .yra-wl-view-button { flex-basis: 100%; }
    .yra-wl-account-box { align-items: stretch; flex-direction: column; }
    .yra-wl-account-box .yra-wl-primary { width: 100%; }
    .yra-wl-account-actions { justify-content: flex-start; }
    .yra-wl-tabs { grid-template-columns: 1fr; border-bottom: 0; gap: 5px; }
    .yra-wl-tab { border: 1px solid #ccc; border-radius: 6px !important; }
    .yra-wl-grid { gap: 9px; }
    .yra-wl-card { flex-basis: 74px; width: 74px; }
    .yra-wl-card-image { width: 74px; height: 107px; }
    .yra-wl-drag-handle { left: 50%; bottom: 4px; transform: translateX(-50%); width: 22px; height: 22px; min-width: 22px; font-size: 16px; }
    .yra-wl-card-remove { top: -6px; right: -6px; width: 20px; height: 20px; min-width: 20px; font-size: 15px; }
    .yra-wl-modal-dialog { padding: 22px 17px; margin-top: 4vh; }
}
