/* ダッシュボード（共通の部品は editor.css を利用） */
.dash-body { font-size: 14px; }
.dh { background: #fff; border-bottom: 1px solid var(--ui-line); position: sticky; top: 0; z-index: 20; }
.dh-in { max-width: 1120px; margin: 0 auto; height: 60px; padding: 0 24px; display: flex; align-items: center; gap: 28px; zoom: var(--zt, 1); }
.dh .brand { text-decoration: none; color: inherit; }
.dnav { display: flex; gap: 4px; align-self: stretch; }
.dnav a { display: flex; align-items: center; padding: 0 14px; text-decoration: none; color: var(--ui-sub); font-weight: 700; border-bottom: 2px solid transparent; }
.dnav a:hover { color: var(--ui-text); }
.dnav a.on { color: var(--ui-accent); border-bottom-color: var(--ui-accent); }
.duser { margin-left: auto; }
.duser-btn { display: flex; align-items: center; gap: 10px; border: 0; background: none; cursor: pointer; padding: 4px 6px 4px 10px; border-radius: 10px; }
.duser-btn:hover { background: var(--ui-bg); }
.duser-btn span { color: var(--ui-sub); font-size: 13px; }
.avatar { width: 32px; height: 32px; border-radius: 50%; background: var(--ui-accent); color: #fff; display: grid; place-items: center; font-weight: 800; font-size: 13px; font-style: normal; }
.dmain { max-width: 1120px; margin: 0 auto; padding: 32px 24px 80px; zoom: var(--z, 1); }
.dloading { color: var(--ui-sub); padding: 40px 0; text-align: center; }
.dhead { display: flex; align-items: flex-end; justify-content: space-between; gap: 16px; margin-bottom: 20px; flex-wrap: wrap; }
.dhead h1 { margin: 0; font-size: 24px; }
.dhead p { margin: 4px 0 0; color: var(--ui-sub); }
.btn.lg { height: 42px; padding: 0 18px; font-size: 14px; border-radius: 10px; }
.btn.lg svg { width: 18px; height: 18px; }

.usage { display: flex; align-items: center; gap: 14px; background: #fff; border: 1px solid var(--ui-line); border-radius: 12px; padding: 12px 16px; margin-bottom: 20px; flex-wrap: wrap; }
.usage-bar { flex: 1; height: 8px; background: var(--ui-bg); border-radius: 8px; overflow: hidden; max-width: 260px; min-width: 120px; }
.usage-bar i { display: block; height: 100%; background: var(--ui-accent); border-radius: 8px; }
.usage a { margin-left: auto; color: var(--ui-accent); font-weight: 700; text-decoration: none; }

.sgrid { display: grid; grid-template-columns: repeat(auto-fill, minmax(260px, 1fr)); gap: 18px; }
.scard { background: #fff; border: 1px solid var(--ui-line); border-radius: 14px; overflow: hidden; display: flex; flex-direction: column; transition: box-shadow .15s, border-color .15s; }
.scard:hover { border-color: #cfd2dc; box-shadow: 0 10px 30px rgba(20,20,40,.08); }
.sthumb { aspect-ratio: 16 / 10; position: relative; overflow: hidden; background: linear-gradient(135deg, #eef0ff, #e6f7f3); display: grid; place-items: center; text-decoration: none; border-bottom: 1px solid var(--ui-line); }
.sthumb iframe { position: absolute; top: 0; left: 0; width: 1280px; height: 800px; border: 0; transform-origin: 0 0; pointer-events: none; background: #fff; }
.sthumb .initial { font-size: 44px; font-weight: 800; color: #a5acf5; }
.sbody { padding: 14px 16px 4px; display: flex; flex-direction: column; gap: 6px; min-width: 0; }
.sbody b { font-size: 15px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.smeta { display: flex; align-items: center; gap: 8px; color: var(--ui-sub); font-size: 12px; }
.sfoot { display: flex; align-items: center; gap: 6px; padding: 10px 10px 14px 16px; margin-top: auto; }
.sfoot .grow { flex: 1; }
.dots { width: 32px; height: 32px; border: 0; background: none; border-radius: 8px; cursor: pointer; color: var(--ui-sub); font-size: 18px; line-height: 1; }
.dots:hover { background: var(--ui-bg); color: var(--ui-text); }
.pop { position: absolute; background: #fff; border: 1px solid var(--ui-line); border-radius: 10px; box-shadow: 0 12px 32px rgba(20,20,40,.14); padding: 6px; min-width: 190px; z-index: 60; }
.pop button, .pop a { display: block; width: 100%; text-align: left; background: none; border: 0; padding: 9px 10px; border-radius: 6px; cursor: pointer; color: inherit; text-decoration: none; font: inherit; font-size: 13px; }
.pop button:hover, .pop a:hover { background: var(--ui-bg); }
.pop .danger { color: var(--ui-danger); }
.dempty { background: #fff; border: 2px dashed var(--ui-line); border-radius: 16px; padding: 56px 24px; text-align: center; }
.dempty h2 { margin: 0 0 8px; }
.dempty p { color: var(--ui-sub); margin: 0 0 20px; line-height: 1.7; }

.dcard { background: #fff; border: 1px solid var(--ui-line); border-radius: 14px; padding: 20px 22px; margin-bottom: 18px; }
.dcard h2 { font-size: 16px; margin: 0 0 12px; }
.dcard p { line-height: 1.7; }
.dcard.danger { border-color: #fecaca; }
.dcard .pf { max-width: 440px; }
.cur-plan { display: flex; align-items: center; justify-content: space-between; gap: 16px; flex-wrap: wrap; }
.cur-plan .pname { font-size: 22px; font-weight: 800; }
.cur-plan p { margin: 4px 0 0; color: var(--ui-sub); }
.plans { display: grid; grid-template-columns: repeat(auto-fit, minmax(240px, 1fr)); gap: 16px; margin-bottom: 8px; }
.plan { background: #fff; border: 1px solid var(--ui-line); border-radius: 14px; padding: 20px; display: flex; flex-direction: column; gap: 10px; }
.plan.current { border: 2px solid var(--ui-accent); }
.plan h3 { margin: 0; font-size: 16px; }
.plan .price { font-size: 28px; font-weight: 800; }
.plan .price small { font-size: 13px; color: var(--ui-sub); font-weight: 600; margin-left: 2px; }
.plan ul { list-style: none; padding: 0; margin: 0 0 8px; display: flex; flex-direction: column; gap: 6px; font-size: 13px; }
.plan li::before { content: "✓"; color: var(--ui-accent); font-weight: 800; margin-right: 8px; }
.plan .btn { margin-top: auto; justify-content: center; }
.dnote { color: var(--ui-sub); font-size: 12px; margin: 0 0 18px; }
.dtable { width: 100%; border-collapse: collapse; font-size: 13px; }
.dtable th, .dtable td { text-align: left; padding: 10px 8px; border-bottom: 1px solid var(--ui-line); }
.dtable th { color: var(--ui-sub); font-weight: 700; font-size: 12px; }
.confirm-table { width: 100%; border-collapse: collapse; margin-bottom: 12px; }
.confirm-table th { width: 30%; text-align: left; vertical-align: top; padding: 10px; background: var(--ui-bg); font-size: 12.5px; border-bottom: 2px solid #fff; }
.confirm-table td { padding: 10px 12px; border-bottom: 1px solid var(--ui-line); font-size: 13px; line-height: 1.6; }
.legal { display: flex; gap: 18px; flex-wrap: wrap; font-size: 12px; color: var(--ui-sub); }

.auth-wrap { min-height: calc(100vh - 160px); display: grid; place-items: center; }
.auth-card { width: min(420px, 100%); background: #fff; border: 1px solid var(--ui-line); border-radius: 16px; padding: 28px; box-shadow: 0 20px 50px rgba(20,20,40,.08); }
.auth-card h1 { font-size: 20px; margin: 0 0 6px; }
.auth-back { display: inline-block; margin: -6px 0 14px; font-size: 13px; color: var(--ui-sub); text-decoration: none; }
.auth-back:hover { color: var(--ui-accent); text-decoration: underline; }
.auth-card > p { color: var(--ui-sub); margin: 0 0 18px; line-height: 1.7; }
.row { display: flex; gap: 8px; align-items: center; }
.row input { flex: 1; }
.dns { background: var(--ui-bg); border-radius: 8px; padding: 10px 12px; font: 12.5px ui-monospace, SFMono-Regular, Menlo, monospace; line-height: 1.9; margin: 8px 0; }
.lock { display: flex; gap: 12px; align-items: center; background: #f5f3ff; border-radius: 10px; padding: 12px 14px; }
.lock span { flex: 1; line-height: 1.6; }
.set-sec { border-top: 1px solid var(--ui-line); padding-top: 14px; margin-top: 14px; }
.set-sec:first-child { border-top: 0; padding-top: 0; margin-top: 0; }
.set-sec h3 { font-size: 13px; margin: 0 0 10px; }
.inline-msg { font-size: 12.5px; line-height: 1.6; margin-top: 8px; }
.inline-msg.err { color: var(--ui-danger); }
.inline-msg.ok { color: #15803d; }
/* サイトの見本（IMP-U05）：未公開のサイトは、保存した見本（見出し・最初の写真・色）で小さなトップページを描く */
.sthumb .mini { position: absolute; inset: 0; display: flex; flex-direction: column; background: var(--mbg); color: var(--mtx); }
.mini-bar { display: flex; align-items: center; justify-content: space-between; gap: 8px; padding: 7px 12px; font-size: 11px; border-bottom: 1px solid rgba(0,0,0,.06); }
.mini-bar b { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.mini-bar i { flex-shrink: 0; width: 34px; height: 12px; border-radius: 6px; background: var(--mp); }
.mini-hero { flex: 1; display: grid; place-items: center; padding: 12px 16px; text-align: center; background: linear-gradient(135deg, color-mix(in srgb, var(--mp) 18%, var(--mbg)), var(--mbg)); background-size: cover; background-position: center; }
.mini-hero span { font-weight: 800; font-size: 17px; line-height: 1.4; display: -webkit-box; -webkit-line-clamp: 3; -webkit-box-orient: vertical; overflow: hidden; }
.mini-hero.has-img { color: #fff; position: relative; }
.mini-hero.has-img::before { content: ""; position: absolute; inset: 0; background: rgba(0,0,0,.35); }
.mini-hero.has-img span { position: relative; text-shadow: 0 1px 3px rgba(0,0,0,.4); }
/* ごみ箱（IMP-U02） */
.trash { margin-top: 28px; border: 1px solid var(--ui-line); border-radius: 12px; background: #fff; padding: 12px 16px; }
.trash summary { cursor: pointer; font-weight: 700; }
.trash-row { display: flex; align-items: center; gap: 10px; padding: 10px 0; border-top: 1px solid var(--ui-line); }
.trash-row > div { flex: 1; min-width: 0; }
.trash-row small { display: block; color: var(--ui-sub); }
/* スマホ幅のヘッダー：メニューはヘッダーの中で横に動かせるようにし、アカウントのボタンは丸いアイコンだけにする（画面が横にはみ出さないように） */
@media (max-width: 720px) {
  .dh-in { gap: 10px; padding: 0 12px; }
  .dh .brand .brand-tag { display: none; }
  .dnav { flex: 1; min-width: 0; overflow-x: auto; scrollbar-width: none; }
  .dnav::-webkit-scrollbar { display: none; }
  .dnav a { padding: 0 8px; font-size: 13px; white-space: nowrap; }
  .duser { flex-shrink: 0; }
  .duser .badge, .duser-btn span { display: none; }
}
/* サイトを探す・並べ替える（IMP-U18） */
.site-tools { display: flex; flex-wrap: wrap; align-items: center; gap: 10px; margin: 0 0 16px; }
.site-tools input[type=search] { flex: 1; min-width: 180px; height: 36px; border: 1px solid var(--ui-line); border-radius: 8px; padding: 0 12px; background: #fff; }
.site-tools select { height: 36px; border: 1px solid var(--ui-line); border-radius: 8px; padding: 0 8px; background: #fff; }
.site-pub { display: flex; align-items: center; gap: 6px; font-size: 13px; color: var(--ui-sub); }
/* 公開数に応じたプラン（エンタープライズ） */
.plan-qty .qty-row { display: flex; align-items: center; gap: 8px; margin: 10px 0 6px; }
.plan-qty .qty-row label { font-size: 13px; color: var(--ui-sub); }
.plan-qty .qty-row input { width: 92px; }
.plan-qty input[type="range"] { width: 100%; }
.plan-qty .qty-per { margin: 6px 0 0; font-size: 12.5px; color: var(--ui-sub); line-height: 1.7; }
/* エンタープライズの専用ページ（公開数を選ぶ） */
.back-link { display: inline-block; margin-bottom: 10px; font-size: 13px; font-weight: 700; color: var(--ui-accent); text-decoration: none; }
.back-link:hover { text-decoration: underline; }
.ent-card { display: grid; grid-template-columns: minmax(0, 1fr) minmax(260px, 340px); gap: 28px; align-items: center; }
.ent-label { display: block; font-size: 13px; font-weight: 700; color: var(--ui-sub); margin-bottom: 6px; }
.ent-pick .qty-row { display: flex; align-items: baseline; gap: 8px; }
.ent-pick .qty-row input { width: 120px; font-size: 20px; font-weight: 800; padding: 8px 10px; }
.ent-pick input[type="range"] { width: 100%; margin-top: 12px; }
.ent-hint { margin-top: 6px; font-size: 12.5px; color: var(--ui-sub); }
.ent-sum { text-align: center; padding: 18px; border-radius: 12px; background: var(--ui-bg); }
.ent-price { font-size: 30px; font-weight: 800; letter-spacing: -.02em; }
.ent-price small { font-size: 13px; font-weight: 700; color: var(--ui-sub); margin-left: 4px; }
.ent-per { margin: 8px 0 14px; font-size: 12.5px; color: var(--ui-sub); line-height: 1.7; }
.ent-table .num { text-align: right; }
.ent-table tr.off { opacity: .45; }
.ent-table tr.total th, .ent-table tr.total td { font-weight: 800; background: var(--ui-bg); }
.ent-features { margin: 0; padding-left: 1.2em; line-height: 2; }
@media (max-width: 760px) { .ent-card { grid-template-columns: 1fr; gap: 18px; } }
/* 閲覧数（IMP-U10） */
.sviews { padding: 0 14px 6px; font-size: 12px; color: var(--ui-sub); }
.usage.warn .usage-bar i { background: var(--ui-danger); }
.badge.warn { background: #fef2f2; color: var(--ui-danger); }
.ent-contact { margin: 0; display: grid; gap: 8px; justify-items: center; }
.ent-contact b { font-size: 13.5px; }
.ent-contact span { font-size: 12.5px; color: var(--ui-sub); line-height: 1.7; }
.ent-contact[hidden] { display: none; }
/* 上限を超えて公開を止めているときのお知らせ（IMP-V20） */
.notice { display: grid; gap: 8px; justify-items: start; padding: 16px 18px; border-radius: 12px; margin-bottom: 16px; background: var(--ui-accent-soft); }
.notice.danger { background: #fef2f2; border: 1px solid #fecaca; }
.notice b { font-size: 15px; }
.notice p { margin: 0; font-size: 13px; line-height: 1.8; color: var(--ui-sub); }
.ent-hint.bad { color: var(--ui-danger); font-weight: 700; }
/* アクセス数の内訳（IMP-U10） */
.views-total { margin: 0 0 10px; font-size: 13px; color: var(--ui-sub); }
.views-total b { font-size: 22px; color: var(--ui-ink, #1d2030); }
.views-chart { display: flex; align-items: flex-end; gap: 3px; height: 90px; padding: 6px 0; overflow-x: auto; }
.views-bar { display: flex; flex-direction: column; justify-content: flex-end; align-items: center; gap: 3px; height: 100%; min-width: 14px; flex: 1; }
.views-bar i { display: block; width: 100%; background: var(--ui-accent); border-radius: 3px 3px 0 0; }
.views-bar small { font-size: 9px; color: var(--ui-sub); }
